OpenXcom Forum

Modding => Help => Topic started by: Nirran on February 07, 2021, 07:34:50 am

Title: soldier ezperience
Post by: Nirran on February 07, 2021, 07:34:50 am
hello :)

first off this openxcom engine is awesome !!

i am trying to limit how much stats are added at end of missions,please dirrect me to the rellavent  topics
Title: Re: soldier ezperience
Post by: Meridian on February 07, 2021, 09:04:49 am
At exp gain time, by ruleset: https://openxcom.org/forum/index.php/topic,4230.0.html

At exp gain time, by script: https://openxcom.org/forum/index.php/topic,4230.msg93690.html#msg93690

At mission end (exp conversion to stats), by script: https://openxcom.org/forum/index.php/topic,6619.msg104686.html#msg104686
Title: Re: soldier ezperience
Post by: Nirran on February 07, 2021, 05:49:05 pm
tyvm !
Title: Re: soldier ezperience
Post by: Nirran on February 07, 2021, 07:25:23 pm
is this the correct get/set stat functions in scripts?

Code: [Select]
          soldier.Stats.setTimeUnits
         
          soldier.Stats.setStamina

          soldier.Stats.setStamina

          soldier.Stats.setHealth

          soldier.Stats.setBravery

          soldier.Stats.setReactions

          soldier.Stats.setFiring

          soldier.Stats.setThrowing

          soldier.Stats.setStrength

          soldier.Stats.setPsiSkill

          soldier.Stats.setMelee
Title: Re: soldier ezperience
Post by: Yankes on February 08, 2021, 01:18:49 am
Yes, but you need remember that `soldier` is name of variable that have solider data of given unit.
In some scripts your code could look like:

Code: [Select]
s.Stats.getStamina temp;
add temp 10; #add some point to current unit stat value
s.Stats.setStamina temp;
Title: Re: soldier ezperience
Post by: Nirran on February 08, 2021, 03:51:16 am
okie dokie thank you mang
Title: Re: soldier ezperience
Post by: Nirran on February 08, 2021, 11:21:15 am
ok got it mostly,now need to disable engine stat gains