You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: data/games/maddog/game.lua
+5-1Lines changed: 5 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -19,6 +19,7 @@ local show_hitboxes = false -- if true, draw a rectangle around where you can s
19
19
localshow_crosshairs=true-- if false, don't draw the crosshairs (useful if you have a real lightgun instead of a mouse).
20
20
localreload_on_action2=false-- if true, right mouse clicks will reload; the Sinden Lightgun sends a right click when pointing offscreen and firing.
21
21
localinfinite_bullets=false-- if true, firing the gun doesn't cost a bullet, so you never need to reload.
22
+
localshow_gun_flash=true-- if true, we clear the screen to white for one frame when the player fires his gun.
22
23
23
24
DirkSimple.cvars= {
24
25
{ name="starting_lives", desc="Number of lives player starts with", values="5|4|3|2|1", setter=function(name, value) starting_lives=DirkSimple.to_int(value) end },
{ name="show_hitboxes", desc="Show hitboxes", values="false|true", setter=function(name, value) show_hitboxes=DirkSimple.to_bool(value) end },
30
31
{ name="show_crosshairs", desc="Show crosshairs (turn off for real lightguns)", values="true|false", setter=function(name, value) show_crosshairs=DirkSimple.to_bool(value) end },
32
+
{ name="show_gun_flash", desc="Flash the screen white when player fires gun", values="true|false", setter=function(name, value) show_gun_flash=DirkSimple.to_bool(value) end },
31
33
{ name="reload_on_action2", desc="Reload with right mouse click (turn on for Sinden lightgun, etc)", values="false|true", setter=function(name, value) reload_on_action2=DirkSimple.to_bool(value) end },
32
34
{ name="infinite_bullets", desc="Shooting the gun doesn't cost a bullet, so no reloads needed", values="false|true", setter=function(name, value) infinite_bullets=DirkSimple.to_bool(value) end },
33
35
}
@@ -578,7 +580,9 @@ local function check_actions(inputs)
578
580
gunsound="empty"
579
581
else
580
582
-- flash the screen white for one frame when firing to give some weight to it. I learned this trick from The Fablemans, lol.
0 commit comments