brk Posted November 8, 2013 Share Posted November 8, 2013 I want to limit the amount of hp for a medic because I think that with the amount of hp is a rambo medic: (Complain to the players from my server, it's hard to kill him (before I nq server and make the game more fair.) Skryp I who limits the amount of hp for medic but also reduces the hp other classes. and I want everyone to have equal, how to do? function et_InitGame(levelTime,randomSeed,restart) hp = 140endfunction et_ClientSpawn(playerID, revived) if revived == 1 or et.gentity_get(playerID, "sess.playerType") == 0 then return end local weapon = et.gentity_get(playerID, "s.weapon") et.gentity_set(playerID, "ps.stats", 0, hp) et.gentity_set(playerID, "ps.ammo", weapon, ammo)end Quote Link to comment Share on other sites More sharing options...
Subscriber JohnDory Posted November 9, 2013 Subscriber Share Posted November 9, 2013 a quick way to slow them down is to stop them picking up their own med packs and reset the xp every now and again. Quote Link to comment Share on other sites More sharing options...
brk Posted November 9, 2013 Author Share Posted November 9, 2013 It will be easier to set dmg weapons Quote Link to comment Share on other sites More sharing options...
Management gaoesa Posted November 9, 2013 Management Share Posted November 9, 2013 Wiki has the possible fields you can read and sometimes write with player entities. http://mygamingtalk.com/wiki/index.php/Silent_Lua#gentity_get Not all of the fields can be written with gentity_set. EDIT:Notice that your G_ClientSpawn is missing parameters. http://mygamingtalk.com/wiki/index.php/Silent_Lua#et_ClientSpawn Quote Link to comment Share on other sites More sharing options...
brk Posted November 9, 2013 Author Share Posted November 9, 2013 Formedic I managed to get 140 hp but for the other classes have not: (where I'm doing wrong? function et_InitGame(levelTime,randomSeed,restart) hp = 140endfunction et_ClientSpawn( clientNum, revived, teamChange, restoreHealth )cno_class = et.gentity_get(playerID, "sess.playerType")et.gentity_set(playerID, "ps.stats", 0, hp)hp = et.gentity_get(playerID, "ps.stats", 0) end Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.