r/PowerShell 5d ago

Question Prank script

We have a culture of pranks here at the office. I’d like to create a PowerShell script that, when executed via a .bat file, rotates the Windows screen to portrait mode, zooms in, increases the cursor scale, inverts the colors, and installs the Egyptian Arabic language pack—all without requiring a reboot or anything like that. Is this possible?

0 Upvotes

23 comments sorted by

View all comments

1

u/Tachaeon 1d ago

1

u/TotallyNotACorpAcct 12h ago

This is fucking diabolical!

# Hashtable of cursor settings

`$cursorSettings = @{

    'AppStarting' = "%SystemRoot%\cursors\aero_working.ani"

    'Arrow'       = "%SystemRoot%\cursors\aero_arrow.cur"

    'Crosshair'   = ""

    'Hand'        = "%SystemRoot%\cursors\aero_link.cur"

    'Help'        = "%SystemRoot%\cursors\aero_helpsel.cur"

    'Ibeam'       = ""

    'No'          = "%SystemRoot%\cursors\aero_unavail.cur"

    'NWPen'       = "%SystemRoot%\cursors\aero_pen.cur"

    'SizeAll'     = "%SystemRoot%\cursors\aero_move.cur"

    'SizeNESW'    = "%SystemRoot%\cursors\aero_nesw.cur"

    'SizeNS'      = "%SystemRoot%\cursors\aero_ns.cur"

    'SizeNWSE'    = "%SystemRoot%\cursors\aero_nwse.cur"

    'SizeWE'      = "%SystemRoot%\cursors\aero_ew.cur"

    'UpArrow'     = "%SystemRoot%\cursors\aero_up.cur"

    'Wait'        = "%SystemRoot%\cursors\aero_busy.ani"

}



# Apply each cursor setting

foreach (`$cursor in `$cursorSettings.GetEnumerator()) {

    Set-Cursor -CursorName `$cursor.Key -FileName `$cursor.Value

}