I've been having a problem with this function for a long time. Where if you set it to false then switch weapons it resets it, I thought I found a fix but it turns out I was wrong...Most likely because I didn't know that Deploy was a stupid hook, heres what I tried.
[lua]
cloakweaponfix = true
timer.Create( "Fixingthisfuckingcloaking", 0.5, 0, Cloakingweaponsonswitch, ply )
function Cloakingweaponsonswitch(ply)
if IsCloak == true and cloakweaponfix == false then
ply:DrawViewModel(false)
ply:DrawWorldModel(false)
cloakweaponfix = true
end
end
hook.Add("Deploy","cloakingsuitshit",function(ply,key)
if IsCloak == true and cloakweaponfix == true then
cloakweaponfix = false
end
end) [/lua]
Anyone know a way to do this so it will actually do what I want it to do?
[editline]01:11AM[/editline]
Oh and also, there was no errors since everything is correctly done.
Deploy is not an existing gamemode hook. So it doesn't error but it doesn't error either.
[QUOTE=Crazy Quebec;21871037]Deploy is not an existing gamemode hook. So it doesn't error but it doesn't error either.[/QUOTE]
Its not a gamemode, but still I get what you mean. Do you know any alternatives to get the same effect?
Sorry, you need to Log In to post a reply to this thread.