Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Renegade Discussions » Mod Forum » Learn me good!
Re: Learn me good! [message #411265 is a reply to message #411245] Wed, 18 November 2009 07:26 Go to previous messageGo to previous message
reborn is currently offline  reborn
Messages: 3231
Registered: September 2004
Location: uk - london
Karma:
General (3 Stars)
Oh yeah, sure. I'm not too worried about how to implement the change for the preset itself. There's a function for that anyway, Set_Damage_Points(GameObject *obj) or something like that. I would just call that on the object created hook, no big deal there...

What I am struggling with really is creating an ini file that has a vector list, something like:

[Presets]
01=CnC_Nod_RocketSoldier_1Off
02=CnC_something_else
03=another_cnc_preset

But then each element creates it's own key...

So then in the same ini file I could have:

CnC_Nod_RocketSoldier_10ff = 0.05
CnC_something_else = 0.01
another_cnc_preset = 0.2

So when the ini file loads the list, it then loads each element in that list as another key in the ini file.

I'm trying to allow the server owners to define the presets they want to edit the damage points for themselves in the ini file, without me having to create a long ass list. It would just be a little bit more dynamic...

However, I don't think the method I just posted is possible. Because that would mean declaring and initialising the variables inside the settings loader itself.

I was thinking possibly it might work if there was such thing as Load2dList, where the ini file would look like this:

[Presets]
01 = CnC_Nod_RocketSoldier_10ff, 0.05
02 =

However, I am not sure you can create such a thing. I am just looking for any possiblity or anyway to explore making it a reality. I do not like the idea of one long static list in the ini file, much of which will not be needed to change the default values, and therefore casuing un-neccessary over-head.



 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: request - Nod Rocket Soldier bug
Next Topic: music not working for map
Goto Forum:
  


Current Time: Mon Dec 23 13:51:24 MST 2024

Total time taken to generate the page: 0.00690 seconds