Page 1 of 1

1st Mod: Bman v4.08: Help?!

Posted: Sun Feb 03, 2008 8:47 pm
by RasterOps
Well this is my first mod and I need help. Let me know if I've stepped on anyones toes. I'm going to keep on working but wanted to get this out there. First, the catch.

WARNING! This mod causes the loss of all currently hired soldiers... Until this is fixed, I recommend loading a game using Bman's v4.07, stripping all soldiers of their gear, saving a non-mission slot and then installing this mod. Now enable Coasty's Better Soldier Stats mod (at your discretion) then hire new soldiers.

Now what's new.
[ol]
[*] 99% of the grammar and typos have been corrected in ResourceBundle.dat and base\UFOpediaComments.dat. Hey I'm not perfect and I have no degree but I can't stand bad grammar.
[*] There is now a Helmet or Head inventory slot. This slot will only accept psi-helmets; no grenades, stimpacks, ammo, or cigarettes.
[*] The "In Hospital" warning position was adjusted when starting a mission and selecting a soldier that is in the Hospital. Hell, I might have caused this but it is fixed now.
[/ol]

Get it Here:
You can find Bman EoU v4.07 here. Refer to the installation method here.
You can get my mod, Bman EoU v4.08 here. If you have not already installed the multimedia pack refer to the installation method above.
If you're looking for a research tree, here are two older trees that fans created: Tech Tree 1, Tech Tree 2.

Help?!
I have tried numerous things to resolve the loss of existing soldiers. I have concentrated on the scripts\tests\config.xsv, config2.xsv, proplist.xsv and proplist2.xsv files. I have focused on the base\CreateandLoadVariables.xscr file in the LoadBaseValuesFromFactory() and LoadSaveGameFromFactory() methods. LoadBaseValuesFromFactory() seems to be working as expected. LoadSaveGameFromFactory() causes an error immediately upon creating the Strategic part, i.e.

Code: Select all

object StrategicPart = objectFactory.create( "StrategicPart" );
Error: StrategicPart.bases.0.units.0.helmet or Second path unused.helmet was found.


Any devs reading this or still around?
I believe the create method is finding the Helmet object doesn't exist for the soldiers in the save game and is terminating with this error thus causing the loss of all soldiers. The create method is compiled in the EXE and out of my control.

At this point it seems the only way to fix this is to modify the existing save game and to add the missing helmet slot per soldier. I do not know if this is even possible. I do not know the methods used to read the file contents.

RE: 1st Mod: Bman v4.08: Help?!

Posted: Tue Feb 05, 2008 3:30 am
by bman654
the way to make this work is:

Instead of modifying the soldier object (I don't know what it is called) in proplist and adding the helmet variable, make a copy of the soldier object in proplist and call it something like soldier2 and add your helmet variable to soldier2.  Now in the load soldier routine somewhere in createandloadvariables, put a test something like if !unit.hasProperty("helmet") then unit.addProperty("helmet", NULL).  In the save soldier code, always save the soldier as type == soldier2.

Basically what this does is allow you to load the old no-helmet soldiers and add the helmet slot to them on the fly.  The save code will always save the new soldier2 objects with the helmet slot.  I am probably not explaining it quite right but maybe you will "get it".  For an example, look at the saveGlobeAlienAI() and LoadAlienAI().  I had to add some swarm variables to this object and I used this method so that old savegames could be loaded properly.

Also, when you get it working, I suggest you go post at ufo-scene.com since that is where most modding is going on.

RE: 1st Mod: Bman v4.08: Help?!

Posted: Tue Feb 05, 2008 6:38 pm
by RasterOps
Hi Bman,
Thanks for the tip. It sounds clear enough. I'll also switch to ufo-scene.com; see you there.

RE: 1st Mod: Bman v4.08: Help?!

Posted: Sat Feb 23, 2008 1:22 am
by alflynn
Is there an alternate place to download the mod from? The links provided are broken.

RE: 1st Mod: Bman v4.08: Help?!

Posted: Sat Feb 23, 2008 5:22 pm
by MjH
ORIGINAL: al_flynn

Is there an alternate place to download the mod from? The links provided are broken.

Did you try http://ufo-scene.com?

RE: 1st Mod: Bman v4.08: Help?!

Posted: Tue Feb 26, 2008 7:18 pm
by alflynn
ORIGINAL: MjH

ORIGINAL: al_flynn

Is there an alternate place to download the mod from? The links provided are broken.

Did you try http://ufo-scene.com?
Yes. The Links there also do not work under this thread.
http://ufo-scene.com/plugins/forum/foru ... c.php?1576

RE: 1st Mod: Bman v4.08: Help?!

Posted: Wed Feb 27, 2008 3:18 am
by alflynn
Links are working now. Does the site have issues at times?

RE: 1st Mod: Bman v4.08: Help?!

Posted: Thu Feb 28, 2008 7:06 pm
by bman654
it's possible.  It is run by a fan with his own $$.