Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #Expand PS Window for some goodies
- $pshost = get-host
- $pswindow = $pshost.ui.rawui
- $newsize = $pswindow.buffersize
- $newsize.height = 3000
- $newsize.width = 150
- $pswindow.buffersize = $newsize
- $newsize = $pswindow.windowsize
- $newsize.height = 50
- $newsize.width = 150
- $pswindow.windowsize = $newsize
- # Make PowerShell Pretty!
- $host.UI.RawUI.ForegroundColor = "DarkGreen"
- $host.UI.RawUI.BackgroundColor = "Black"
- $pswwidth = (get-host).UI.RawUI.MaxWindowSize.Width
- function Centralize()
- {
- param(
- [Parameter(Position=0,Mandatory=$true)]
- [string]$S
- )
- $sLength = $S.Length
- $padamt = "{0:N0}" -f (($pswwidth-$sLength)/2)
- $PadNum = $padamt/1 + $sLength
- $CS = $S.PadLeft($PadNum," ").PadRight($PadNum," ") #Padding
- Write-Host $CS
- }
- function CakeTime # Written using ASCII Art :D
- {
- clear
- Centralize(" * * ")
- Centralize(" * ")
- Centralize(" * ")
- Centralize(" * ")
- Centralize(" * ")
- Centralize(" * ")
- Centralize(" * ")
- Centralize(" * ")
- Centralize(" * * ")
- Centralize(" * ")
- Centralize(" * * ")
- Centralize(" * ")
- Centralize(" ( ) ")
- Centralize(" ) (*) (*) ( ")
- Centralize(" * (*) | | (*) ")
- Centralize(" | |~| |~| | * ")
- Centralize(" |~| | | | | |~| ")
- Centralize(" | | | | | | | | ")
- Centralize(" ,| |a@@@@| |@@@@@@@@@@@| |@@@@a| |. ")
- Centralize(" .,a@@@| |@@@@@| |@@@@@@@@@@@| |@@@@@| |@@@@a,. ")
- Centralize(" ,a@@@@@@| |@@@@@@@@@@@@.@@@@@@@@@@@@@@| |@@@@@@@a, ")
- Centralize(" a@@@@@@@@@@@@@@@@@@@@@' . `@@@@@@@@@@@@@@@@@@@@@@@@a ")
- Centralize(" ;`@@@@@@@@@@@@@@@@@@' . `@@@@@@@@@@@@@@@@@@@@@'; ")
- Centralize(" ;@@@`@@@@@@@@@@@@@' . `@@@@@@@@@@@@@@@@'@@@; ")
- Centralize(" ;@@@;,.aaaaaaaaaa . aaaaa,,aaaaaaa,;@@@; ")
- Centralize(" ;;@;;;;@@@@@@@@;@ @.@ ;@@@;;;@@@@@@;;;;@@; ")
- Centralize(" ;;;;;;;@@@@;@@;;@ @@ . @@ ;;@;;;;@@;@@@;;;;;;; ")
- Centralize(" ;;;;;;;;@@;;;;;;; @@ . @@ ;;;;;;;;;;;@@;;;;@;; ")
- Centralize(" ;;;;;;;;;;;;;;;;;@@ . @@;;;;;;;;;;;;;;;;@@@; ")
- Centralize(" ,%%%;;;;;;;;@;;;;;;;; . ;;;;;;;;;;;;;;;;@@;;%%%, ")
- Centralize(" .%%%%%%;;;;;;;@@;;;;;;;; ,%%%, ;;;;;;;;;;;;;;;;;;;;%%%%%%, ")
- Centralize(".%%%%%%%;;;;;;;@@;;;;;;;; ,%%%%%%%, ;;;;;;;;;;;;;;;;;;;;%%%%%%%,")
- Centralize("%%%%%%%%`;;;;;;;;;;;;;;;; %%%%%%%%%%% ;;;;;;;;;;;;;;;;;;;'%%%%%%%%")
- Centralize("%%%%%%%%%%%%`;;;;;;;;;;;;,%%%%%%%%%%%%%,;;;;;;;;;;;;;;;'%%%%%%%%%%%%")
- Centralize("`%%%%%%%%%%%%%%%%%,,,,,,,%%%%%%%%%%%%%%%,,,,,,,%%%%%%%%%%%%%%%%%%%%'")
- Centralize(" `%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%' ")
- Centralize(" `%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%' ")
- Centralize(" --------------`,,,,,,,,,'------------------ ")
- Centralize(" `%%%%%%%' ")
- Centralize(" `%%%%%' ")
- Centralize(" %%% ")
- Centralize(" %%%%% ")
- Centralize(" .,%%%%%%%,. ")
- Centralize(" ,%%%%%%%%%%%%%%%%%%%, ")
- Centralize(" ")
- Centralize(" ")
- Centralize("Happy Birthday!")
- }
- function Beeper # Happy Birthday song with Beep tones in Powershell Script - Credit to u/hackoofr in r/Powershell for the main beep code.
- {
- #cls
- $BeepList = @(
- @{ Pitch = 37; Length = 300; };
- @{ Pitch = 1059.274; Length = 300; };
- @{ Pitch = 1059.274; Length = 200; };
- @{ Pitch = 1188.995; Length = 500; };
- @{ Pitch = 1059.274; Length = 500; };
- @{ Pitch = 1413.961; Length = 500; };
- @{ Pitch = 1334.601; Length = 1000; };
- @{ Pitch = 1059.274; Length = 300; };
- @{ Pitch = 1059.274; Length = 200; };
- @{ Pitch = 1188.995; Length = 500; };
- @{ Pitch = 1059.274; Length = 500; };
- @{ Pitch = 1587.117; Length = 500; };
- @{ Pitch = 1413.961; Length = 1000; };
- @{ Pitch = 1059.274; Length = 300; };
- @{ Pitch = 1059.274; Length = 200; };
- @{ Pitch = 2118.547; Length = 500; };
- @{ Pitch = 1781.479; Length = 500; };
- @{ Pitch = 1413.961; Length = 500; };
- @{ Pitch = 1334.601; Length = 500; };
- @{ Pitch = 1188.995; Length = 800; };
- @{ Pitch = 1887.411; Length = 300; };
- @{ Pitch = 1887.411; Length = 200; };
- @{ Pitch = 1781.479; Length = 500; };
- @{ Pitch = 1413.961; Length = 500; };
- @{ Pitch = 1587.117; Length = 500; };
- @{ Pitch = 1413.961; Length = 900; };
- );
- # I Just added this For..loop in order to listen the beep tones twice (-_°)
- For ($i=1; $i -le 2; $i++) {
- foreach ($Beep in $BeepList) {
- [System.Console]::Beep($Beep['Pitch'], $Beep['Length']);
- }
- }
- }
- caketime
- beeper
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement