New to modding -- file controls cargo items

More
17 years 3 months ago #19013 by qiaoyech
Hey guys, I'm new to modding the IW2EoC. I'm trying to add new cargos into the game, but I only found the text. Although it has number in excel, it does not match the number in FutureTrader. So my assumption is that there must be somewhere that has a list of cargo with its index number.

Anyone care to tell me which file it is? I'm trying to add new blueprints to the game so that the base can build weapons as well as ammos :-). Maybe later I'll add making food and water. It's just fun to do it!:p

The problem is, after I added new items to the cfg list in FutureTrader, (starting index #901), and changed the package file.
from
Code:
if ( cargo_int < 700 )
to
Code:
if ( cargo_int < 700 || cargo_int > 800 )
in 2 or 3 places, then changed
Code:
if ( cint < 700 )
to
Code:
if ( cint < 700 || cint > 800 )

It works well, but when you load up the cargo screen in the menu, the blueprints I just purchased erased automatically.

Anyone knows how to prevent it from removing if we cannot add new cargos to the game?

Any help would be appreciated :-)

Also I looked into the IFF mod's "Leaf Tabacco" bug, I'm really started wondering why don't they just add a new cargo? Is that because of the game's engine limition?

Please Log in or Create an account to join the conversation.

More
17 years 3 months ago #16557 by qiaoyech
It has "VB Runtime Error" here when I try to edit the topic, so I'll start a reply here.

I think I figured out how to "stay" in inventory, and keep the blueprint. But I'm curious why it won't show in the "inventory" or "recycling" menu.

I added these after
Code:
//UniGUI.PayPlayer( 100000000 );
in futuretrade.pkg
Code:
iCargo.Create( 612, "Cargo_AssultCannonBlueprint", true, 10000, false, 10000, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/assault_cannon.html", true ); iCargo.Create( 613, "Cargo_AMPBCBlueprint", true, 9500, false, 9500, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/antimatter_pbc.html", true ); iCargo.Create( 614, "Cargo_NeutronPBCBlueprint", true, 8000, false, 8000, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/neutron_pbc.html", true ); iCargo.Create( 615, "Cargo_CommLaserBlueprint", true, 100, false, 100, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/comms_laser.html", true ); iCargo.Create( 616, "Cargo_PBCBlueprint", true, 1200, false, 1200, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/pbc.html", true ); iCargo.Create( 617, "Cargo_MiningLaserBlueprint", true, 1875, false, 1875, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/mining_laser.html", true ); iCargo.Create( 618, "Cargo_GatlingCannonBlueprint", true, 4750, false, 4750, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/gatling_cannon.html", true ); iCargo.Create( 619, "Cargo_LightPBCBlueprint", true, 25, false, 25, true, 5, "", "/html/encyclopedia/technology/weapons/energy_weapons/light_pbc.html", true ); iCargo.Create( 620, "Cargo_CryoPBCBlueprint", true, 900, false, 900, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/pbc_cryo.html", true ); iCargo.Create( 621, "Cargo_RapidfirePBCBlueprint", true, 2000, false, 2000, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/pbc_rapid_fire.html", true ); iCargo.Create( 622, "Cargo_SniperCannonBlueprint", true, 4000, false, 4000, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/long_range_cannon.html", true ); iCargo.Create( 623, "Cargo_CuttingBeamBlueprint", true, 3750, false, 3750, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/cutting_beam.html", true ); iCargo.Create( 624, "Cargo_WidArcPBCBlueprint", true, 1350, false, 1000, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/pbc_wide_arc.html", true ); iCargo.Create( 625, "Cargo_QuadLightPBCBlueprint", true, 1500, false, 1500, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/quad_pbc.html", true ); iCargo.Create( 626, "Cargo_HeavyPBCBlueprint", true, 4000, false, 4000, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/heavy_pbc.html", true ); iCargo.Create( 627, "Cargo_RecoilDampedPBCBlueprint", true, 1350, false, 1350, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/pbc_recoil_damped.html", true ); iCargo.Create( 628, "Cargo_PulseAccPBCBlueprint", true, 2750, false, 2750, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/pbc.html", true ); iCargo.Create( 629, "Cargo_AMStreamBlueprint", true, 10000, false, 10000, true, 50, "", "/html/encyclopedia/technology/weapons/energy_weapons/antimatter_stream.html",true ); iCargo.Create( 630, "Cargo_TwinPackLauncherBlueprint", true, 1125, false, 1125, true, 50, "", "/html/encyclopedia/technology/weapons/missiles/TwinPackMissileLauncher.html", true ); iCargo.Create( 631, "Cargo_TriPackLauncherBlueprint", true, 1875, false, 1875, true, 50, "", "/html/encyclopedia/technology/weapons/missiles/TripackMissileLauncher.html", true ); iCargo.Create( 632, "Cargo_QuadPackLauncherBlueprint", true, 2500, false, 2500, true, 50, "", "/html/encyclopedia/technology/weapons/missiles/QuadpackMissileLauncher.html", true );

I also changed the cfg file in futuretrader, copied 2 text files about cargos to futuretrader mod's zip file in text folder, and added those names and comments in there.

I'm also curious about where the index is, so that I can add water and food blueprints there. Futuretrader has no description on those normal cargos.

Please Log in or Create an account to join the conversation.

More
17 years 3 months ago #16560 by qiaoyech
Okay... Now that I knew the last problem was NOT SOLVED. And I know exactly where the code is: I see that in icargoscript.h header file. Is there a way to plug the header in the executable? Or can I plug the header in one of the packages?

Please Log in or Create an account to join the conversation.