Uses ast-grep to apply some parts of bevy 0.10 to 0.11 migration that can be automated.
You should review any changes this makes.
cargo install ast-grep
sg -p 'Clicked' --rewrite 'Pressed' -U
sg -p 'LAlt' --rewrite 'AltLeft' -U
Uses ast-grep to apply some parts of bevy 0.10 to 0.11 migration that can be automated.
You should review any changes this makes.
cargo install ast-grep
sg -p 'Clicked' --rewrite 'Pressed' -U
sg -p 'LAlt' --rewrite 'AltLeft' -U
/// Everthing below this comment block was generated by ChatGPT from the prompt: | |
/// "write a hangman game in the rust language without comments" | |
/// (with comments it was too long and cut off the end) | |
use std::collections::HashSet; | |
use std::io; | |
const MAX_GUESSES: i32 = 6; | |
fn main() { | |
println!("Enter a word for the other player to guess: "); |
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases. | |
; #Warn ; Enable warnings to assist with detecting common errors. | |
SendMode Input ; Recommended for new scripts due to its superior speed and reliability. | |
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory. | |
Up:: | |
; Wait for time to see if it is still pressed | |
KeyWait, Up, T0.07 | |
if (ErrorLevel){ | |
; Still being pressed, treat as shift | |
Send {Shift Down} |