Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- It's recommended to have everything local
- local function random_save(key, keyCode, modifierKeys, event)
- -- I didn't mention this, but event is 1 on keydown and 2 on keyup, we want the save to be viewed on keydown
- if key == "j" and event == 1 then
- local save_id = math.random(2000000)
- sim.loadSave(save_id)
- end
- end
- tpt.register_keypress(random_save)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement