Pumpkin Lord
Greetings Forge,
There should be like ten different ways to achieve the same goal. And, this is just one of those. I took a different approach for each existing cheat in WB and still doing the same. These codes will be useful for mods which aims hardcore gaming experience, hopefully.
I am going to update this thread as soon as I bury another cheat beneath the ground till all is done.
Here are the currently available anti-cheat systems
Cheat: Kills any random agent in any mission.
Solution: Player agent dies even before player can kill one of those agents.
Cheat: Refilling HP.
Solution: Player agent dies instantly whenever the cheat is launched.
Regards,
There should be like ten different ways to achieve the same goal. And, this is just one of those. I took a different approach for each existing cheat in WB and still doing the same. These codes will be useful for mods which aims hardcore gaming experience, hopefully.
I am going to update this thread as soon as I bury another cheat beneath the ground till all is done.
Here are the currently available anti-cheat systems
Cheat: Kills any random agent in any mission.
Solution: Player agent dies even before player can kill one of those agents.
Code:
common_anti_cheat_kill = (
0,0,0,
[ (this_or_next|key_is_down, key_right_control),
(key_is_down, key_left_control),
(key_clicked, key_f4),
],
[ (get_player_agent_no, ":playeragent"),
(agent_is_alive,":playeragent"),
(display_message, "@Cheating is bad, ya know."),
(try_begin),
(store_agent_hit_points,":hp",":playeragent",1),
(val_sub,":hp",100),
(try_begin),
(le, ":hp", 0),
(agent_set_hit_points,":playeragent",0,0),
(try_end),
(play_sound,"snd_man_die"),
(agent_deliver_damage_to_agent,":playeragent",":playeragent"),
(finish_mission),
(try_end),
(try_end),
]
)
Cheat: Refilling HP.
Solution: Player agent dies instantly whenever the cheat is launched.
Code:
common_anti_cheat_heal = (
0,0,0,
[ (this_or_next|key_is_down, key_right_control),
(key_is_down, key_left_control),
(key_clicked, key_h),
],
[ (get_player_agent_no, ":playeragent"),
(agent_is_alive,":playeragent"),
(display_message, "@Cheating is bad, ya know."),
(try_begin),
(store_agent_hit_points,":hp",":playeragent",1),
(val_sub,":hp",100),
(try_begin),
(le, ":hp", 0),
(agent_set_hit_points,":playeragent",0,0),
(try_end),
(play_sound,"snd_man_die"),
(agent_deliver_damage_to_agent,":playeragent",":playeragent"),
(finish_mission),
(try_end),
(try_end),
]
)
Regards,