Giter Club home page Giter Club logo

keep-moving's Introduction

StayActiveBot

Introduction

Are you often so engrossed in finding solutions that you forget to move your mouse and inadvertently go "inactive" on Slack? StayActiveBot to the rescue! This PowerShell script ensures you're always seen as active by subtly moving your cursor at regular intervals. It's fun, a bit cheeky, and keeps you "online"!

How It Works

The script periodically changes your cursor's position on the screen. This movement is minimal but enough to maintain your active status on Slack. Just run it, and forget about manually nudging your mouse!

Features

  • Automatic Cursor Movement: Keeps your cursor moving without your input.
  • Customizable Intervals: Currently set to move every 3 seconds, but easily adjustable.
  • Logging: Outputs a fun message with each move, so you can see the script in action.

Requirements

  • PowerShell
  • Windows Operating System

Usage

  1. Open PowerShell.
  2. Copy and paste the script.
  3. Hit Enter and watch your cursor dance!

Code

Add-Type -AssemblyName System.Windows.Forms

function Write-Log {
    param([string]$message)
    $timestamp = Get-Date -Format "yyyy-MM-dd HH:mm:ss"
    Write-Host "${timestamp}: $message"
}

while ($true) {
  $Pos = [System.Windows.Forms.Cursor]::Position
  $x = ($pos.X % 500) + 10
  $y = ($pos.Y % 500) + 10
  [System.Windows.Forms.Cursor]::Position = New-Object System.Drawing.Point($x, $y)

  Write-Log "Cursor moved to X: $x Y: $y ๐Ÿš€"

  Start-Sleep -Seconds 3
}

keep-moving's People

Contributors

moetazbrayek1 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.