Lua questions

Started by Anyder, November 18, 2014, 01:00:27 PM

Previous topic - Next topic
November 18, 2014, 01:00:27 PM Last Edit: November 21, 2014, 06:16:47 PM by Anyder
Does anyone know what is this for ?

SetProperty("whatwever", "CurHealth", *A number goes here*) ?
I know about MaxHealth, AddHealth, .. but what is this for ?
Anyder | Talent, Ops & Culture | SWBF & Player Engagement
Email: communityambassador@swbfgamers.com
SWBFSpy Discord: http://discord.swbfspy.com
SWBFSpy Info: http://info.swbfspy.com

Looks like it's going to be your current health whenever you aren't taking damage or etc.
I'd assume it's static, and the value changes depending on if you recieve more health or take damage.

Perhaps if you were to set a game with a high max health, you could spawn everything in at a lower health than max.

Example: Max Health 3000, Current Health 1500; All troops spawn at 1500 and can gain or lose health.
The value must have to differ constantly assuming, well I'm sure you understand now.

*All this is just a theory of mine. I'm not a modder, yet! Ha
Formerly:
{Alpha}Gen.Ultimo
[212]Cpl.Ultimo
WUSi.Whisper

November 18, 2014, 01:48:17 PM #2 Last Edit: November 18, 2014, 01:51:46 PM by Anyder
Quote from: ևltimσ on November 18, 2014, 01:43:26 PM
Looks like it's going to be your current health whenever you aren't taking damage or etc.
I'd assume it's static, and the value changes depending on if you recieve more health or take damage.

Perhaps if you were to set a game with a high max health, you could spawn everything in at a lower health than max.

Example: Max Health 3000, Current Health 1500; All troops spawn at 1500 and can gain or lose health.
The value must have to differ constantly assuming, well I'm sure you understand now.

*All this is just a theory of mine. I'm not a modder, yet! Ha

Yeah I see that theory of urs, however talking with some more people it might be current health but we dont know what it is for yet.

I'll try it once I finish with my fairsides anyway :)
Anyder | Talent, Ops & Culture | SWBF & Player Engagement
Email: communityambassador@swbfgamers.com
SWBFSpy Discord: http://discord.swbfspy.com
SWBFSpy Info: http://info.swbfspy.com

After a test I just made, it looks like the CurHealth thing wasn't for whenever u spawn.

AutoHealing worked (and maxhealth idk, cause i've set the same health the sniper had)

This is how the lua looks

     SetClassProperty("imp_inf_sniper", "MaxHealth", 300.0)
     SetClassProperty("imp_inf_sniper", "CurHealth", 200.0)
     SetClassProperty("imp_inf_sniper", "AddHealth", 10.0)
     
     SetSpawnDelay(1.0, 0.25)
     ReadDataFile("mus\\mus1.lvl", "mus1_ctf")
     SetDenseEnvironment("false")
     --SetStayInTurrets(1)
   SetMaxFlyHeight(840000000)
    SetMaxPlayerFlyHeight(8400000000)
Anyder | Talent, Ops & Culture | SWBF & Player Engagement
Email: communityambassador@swbfgamers.com
SWBFSpy Discord: http://discord.swbfspy.com
SWBFSpy Info: http://info.swbfspy.com