mirror of
https://github.com/fleschutz/PowerShell.git
synced 2024-12-28 01:28:50 +01:00
165 lines
4.6 KiB
Markdown
165 lines
4.6 KiB
Markdown
*play-tetris-melody.ps1*
|
|
================
|
|
|
|
This PowerShell script plays the Tetris melody.
|
|
|
|
Parameters
|
|
----------
|
|
```powershell
|
|
PS> ./play-tetris-melody.ps1 [<CommonParameters>]
|
|
|
|
[<CommonParameters>]
|
|
This script supports the common parameters: Verbose, Debug, ErrorAction, ErrorVariable, WarningAction,
|
|
WarningVariable, OutBuffer, PipelineVariable, and OutVariable.
|
|
```
|
|
|
|
Example
|
|
-------
|
|
```powershell
|
|
PS> ./play-tetris-melody
|
|
|
|
```
|
|
|
|
Notes
|
|
-----
|
|
Author: Markus Fleschutz | License: CC0
|
|
|
|
Related Links
|
|
-------------
|
|
https://github.com/fleschutz/PowerShell
|
|
|
|
Script Content
|
|
--------------
|
|
```powershell
|
|
<#
|
|
.SYNOPSIS
|
|
Plays the Tetris melody
|
|
.DESCRIPTION
|
|
This PowerShell script plays the Tetris melody.
|
|
.EXAMPLE
|
|
PS> ./play-tetris-melody
|
|
.LINK
|
|
https://github.com/fleschutz/PowerShell
|
|
.NOTES
|
|
Author: Markus Fleschutz | License: CC0
|
|
#>
|
|
|
|
[System.Console]::Beep(1320,500)
|
|
[System.Console]::Beep(990,250)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(1188,250)
|
|
[System.Console]::Beep(1320,125)
|
|
[System.Console]::Beep(1188,125)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(990,250)
|
|
[System.Console]::Beep(880,500)
|
|
[System.Console]::Beep(880,250)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(1320,500)
|
|
[System.Console]::Beep(1188,250)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(990,750)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(1188,500)
|
|
[System.Console]::Beep(1320,500)
|
|
[System.Console]::Beep(1056,500)
|
|
[System.Console]::Beep(880,500)
|
|
[System.Console]::Beep(880,500)
|
|
Start-Sleep -milliseconds 250
|
|
[System.Console]::Beep(1188,500)
|
|
[System.Console]::Beep(1408,250)
|
|
[System.Console]::Beep(1760,500)
|
|
[System.Console]::Beep(1584,250)
|
|
[System.Console]::Beep(1408,250)
|
|
[System.Console]::Beep(1320,750)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(1320,500)
|
|
[System.Console]::Beep(1188,250)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(990,500)
|
|
[System.Console]::Beep(990,250)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(1188,500)
|
|
[System.Console]::Beep(1320,500)
|
|
[System.Console]::Beep(1056,500)
|
|
[System.Console]::Beep(880,500)
|
|
[System.Console]::Beep(880,500)
|
|
Start-Sleep -milliseconds 500
|
|
[System.Console]::Beep(1320,500)
|
|
[System.Console]::Beep(990,250)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(1188,250)
|
|
[System.Console]::Beep(1320,125)
|
|
[System.Console]::Beep(1188,125)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(990,250)
|
|
[System.Console]::Beep(880,500)
|
|
[System.Console]::Beep(880,250)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(1320,500)
|
|
[System.Console]::Beep(1188,250)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(990,750)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(1188,500)
|
|
[System.Console]::Beep(1320,500)
|
|
[System.Console]::Beep(1056,500)
|
|
[System.Console]::Beep(880,500)
|
|
[System.Console]::Beep(880,500)
|
|
Start-Sleep -milliseconds 250
|
|
[System.Console]::Beep(1188,500)
|
|
[System.Console]::Beep(1408,250)
|
|
[System.Console]::Beep(1760,500)
|
|
[System.Console]::Beep(1584,250)
|
|
[System.Console]::Beep(1408,250)
|
|
[System.Console]::Beep(1320,750)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(1320,500)
|
|
[System.Console]::Beep(1188,250)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(990,500)
|
|
[System.Console]::Beep(990,250)
|
|
[System.Console]::Beep(1056,250)
|
|
[System.Console]::Beep(1188,500)
|
|
[System.Console]::Beep(1320,500)
|
|
[System.Console]::Beep(1056,500)
|
|
[System.Console]::Beep(880,500)
|
|
[System.Console]::Beep(880,500)
|
|
Start-Sleep -milliseconds 500
|
|
[System.Console]::Beep(660,1000)
|
|
[System.Console]::Beep(528,1000)
|
|
[System.Console]::Beep(594,1000)
|
|
[System.Console]::Beep(495,1000)
|
|
[System.Console]::Beep(528,1000)
|
|
[System.Console]::Beep(440,1000)
|
|
[System.Console]::Beep(419,1000)
|
|
[System.Console]::Beep(495,1000)
|
|
[System.Console]::Beep(660,1000)
|
|
[System.Console]::Beep(528,1000)
|
|
[System.Console]::Beep(594,1000)
|
|
[System.Console]::Beep(495,1000)
|
|
[System.Console]::Beep(528,500)
|
|
[System.Console]::Beep(660,500)
|
|
[System.Console]::Beep(880,1000)
|
|
[System.Console]::Beep(838,2000)
|
|
[System.Console]::Beep(660,1000)
|
|
[System.Console]::Beep(528,1000)
|
|
[System.Console]::Beep(594,1000)
|
|
[System.Console]::Beep(495,1000)
|
|
[System.Console]::Beep(528,1000)
|
|
[System.Console]::Beep(440,1000)
|
|
[System.Console]::Beep(419,1000)
|
|
[System.Console]::Beep(495,1000)
|
|
[System.Console]::Beep(660,1000)
|
|
[System.Console]::Beep(528,1000)
|
|
[System.Console]::Beep(594,1000)
|
|
[System.Console]::Beep(495,1000)
|
|
[System.Console]::Beep(528,500)
|
|
[System.Console]::Beep(660,500)
|
|
[System.Console]::Beep(880,1000)
|
|
[System.Console]::Beep(838,2000)
|
|
exit 0 # success
|
|
```
|
|
|
|
*(generated by convert-ps2md.ps1 using the comment-based help of play-tetris-melody.ps1 as of 09/20/2023 17:04:43)*
|