• Flash Light Battery
    9 replies, posted
I am currently working on a gamemode for my 'Horror map' server which essentially makes horror maps like gm_ghosthunt scarier. I have gotten the base of the gamemode working but need to add a flashlight battery that recharges overtime, just like the one from Half Life. Thanks :)
Okay, thats a great help. Quick question, where abouts would I put this? Just making sure so I don't screw up my server :)
Okay, thanks :)
I finally got my gamemode playable and inserted the flashlight code into init.lua, when you join or load the gametype/new map you get this error: Hook 'DrainRegenBattery' Failed: [gamemodes\horrorventures\gamemode\init.lua:70] attempt to compare nil with number When you turn the flash light on you get this error: Hook 'DisableFlashlightOnNoBattery' Failed: [gamemodes\horrorventures\gamemode\init.lua:56] attempt to compare nil with number Any idea what the fix is? Well when I uploaded the code and played it on my server I didn't get the errors but the battery doesn't seem to work.
-Removed my super secret code-
Great :) [editline]19th May 2012[/editline] It worked, how would I add some sort of flashlight battery level to the hud?
Sorry, you need to Log In to post a reply to this thread.