This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
learn Unreal Engine 5 (UE5 https://www.unrealengine.com) - free pro software, this is what the industry uses now | |
get it from the Epic Games Launcher https://store.epicgames.com/ | |
do projects alone at first. take time to learn the basics. multiplayer is always more complicated. | |
buying asset store projects is an unreasonably effective way to learn https://www.unrealengine.com/marketplace | |
learning projects should be simple enough to finish. | |
blueprints is a programming language for games used by UE5. Many games are possible using only blueprints code. start by searching for “beginner blueprint tutorials ue5” | |
find a good place to ask questions, like a Discord community or https://forums.unrealengine.com/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This will register a new job that removes itself from Get-ScheduledJob when finished | |
$Trigger = New-JobTrigger -Once -At (Get-Date).AddSeconds(3) | |
$TaskName = "SelfDestructingJob" | |
Register-ScheduledJob -Trigger $Trigger -Name $TaskName ` | |
-ScriptBlock ([scriptblock]::Create(@" | |
("Started job at " + (Get-Date) + ", waiting...") | Out-File -FilePath 'C:\ProofThatItWorks.txt' | |
Start-Sleep 3 | |
("Finished at " + (Get-Date)) | Out-File -Append -FilePath 'C:\ProofThatItWorks.txt' | |
Unregister-ScheduledJob -Name '$TaskName' -Force |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$Trigger = New-JobTrigger -Once -At (get-date).AddSeconds(5) | |
$JobOptions = New-ScheduledJobOption -StartIfOnBattery -RunElevated | |
$Job = Register-ScheduledJob -Name "TaskName" -Trigger $Trigger -ScheduledJobOption $JobOptions ` | |
-ScriptBlock { | |
Sleep 5 | |
} | |
# From https://docs.microsoft.com/en-us/windows/win32/taskschd/task-scheduler-error-and-success-constants?redirectedfrom=MSDN | |
Set-Variable -Name "SCHED_S_TASK_HAS_NOT_RUN" -Value 0x00041303 -Option Constant |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$JobName = "RunAtLoginExample" | |
$Enabled = $True # set to $False and run to remove the job | |
# https://stackoverflow.com/questions/40569045/register-scheduledjob-as-the-system-account-without-having-to-pass-in-credentia | |
# Output: %LOCALAPPDATA%\Microsoft\Windows\PowerShell\ScheduledJobs\$JobName | |
$accountId = ((Get-WMIObject -class Win32_ComputerSystem | Select-Object -ExpandProperty username)) | |
$Trigger = New-JobTrigger -AtLogOn | |
$JobOptions = New-ScheduledJobOption -StartIfOnBattery -RunElevated |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if (-not (Test-Path $Path)) { New-Item $Path -ItemType Directory | Out-Null } | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ZipFilePath = "" | |
$FileNameInZip = "" | |
Add-Type -AssemblyName System.IO.Compression.FileSystem | |
$Zip = [System.IO.Compression.ZipFile]::OpenRead($ZipFilePath) | |
$Zip.Entries | | |
Where-Object { $_.Name -eq $FileNameInZip } | | |
ForEach-Object { | |
[System.IO.Compression.ZipFileExtensions]::ExtractToFile($_, $_.Name, $true) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Fill these in with your own values | |
$Username = "your_username" | |
$Branch = "main" | |
$PathToFile = "README.md" | |
# Go to [https://github.com/settings/tokens] and add a Personal Access Token with two scopes: "repo" and "read:org" | |
$GitHubAuthToken = "ghp_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" | |
Invoke-WebRequest -Method Get -Uri "https://raw.githubusercontent.com/$Username/$Repository/$Branch/$PathToFile" -Headers @{Authorization="token $GitHubAuthToken"; 'Cache-Control'='no-cache'} | ForEach-Object { $_.Content } | Write-Host |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[console]::beep(260,200) | |
[console]::beep(320,200) | |
[console]::beep(380,150) | |
[console]::beep(520,200) | |
Start-Sleep -Milliseconds 200 | |
[console]::beep(520,150) | |
[console]::beep(700,800) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Copyright 2018 Karl Gluck | |
// | |
// Permission is hereby granted, free of charge, to any person obtaining a copy | |
// of this software and associated documentation files (the "Software"), to | |
// deal in the Software without restriction, including without limitation the | |
// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or | |
// sell copies of the Software, and to permit persons to whom the Software is | |
// furnished to do so, subject to the following conditions: | |
// | |
// The above copyright notice and this permission notice shall be included in |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static Vector3 ViewportToWorldPointUnity (Vector3 point, float fieldOfView, float aspect, Vector3 from, Vector3 to, Vector3 up) | |
{ | |
// The zNear / zFar magic numbers are what Unity's viewport always uses regardless of camera settings | |
var matP = Matrix4x4.Perspective (fieldOfView, aspect, 0.6f /* zNear */, 1000f /* zFar */); | |
// For some reason we have to reverse these coordinates | |
from = -from; | |
to = -to; |
NewerOlder