Jump to content
Sign in to follow this  
Spaceboy

Some Mod problems

Recommended Posts

hello everyone :)

 

im trying to mod my zh, I have given Inf units from other factions , changed weapons....

 

But I still have some problems. At the moment I try to create an Upgrade for inf who should stealth all my infantry. I wanna use the gla upgrade for these project. But im only able to create the Button. The upgrade should cost 5000 and be made at the internet center. How i can do that?? :)

 

BTW: thanks alot

http://forums.cncnz.com/topic/14852-making-unusable-units-playable-in-cc-zh/

Share this post


Link to post

Here I will give you code to do that:

 

in CommandSet.ini you will need to find the InternetCenter for your faction there are 4 command sets for each china faction associated with the Internet Center. You will need to edit all of them (for your faction).

 

Add on a line of your choosing (11 and 13 are available, I will use 11.)

  11 = Command_UpgradeChinaInfantryStealth

 

Replace the "Command_UpgradeChinaInfantryStealth" with whatever your button is named. Do this for all 4 Internet Center Command Sets for your given faction.

 

In Upgrade.ini, add at the bottom of the ini:

 

Upgrade Upgrade_ChinaInfantryStealth
 DisplayName		= UPGRADE:ChinaInfantryStealth
 BuildTime		  = 60.0
 BuildCost		  = 5000
 ButtonImage		= SSNationalism
End

 

The BuildTime is in seconds. You will need to add the DisplayName to generals.csf (same with the button). The ButtonImage can be found in MappedImages folder in any of the ini's there. You do not want the "_L" images because they are large images and you want smaller images. Download Cameo Mapper and you can view the actual images (the ini files tell you which image file hosts the image and it's coordinates in the file, Cameo Mapper will help you find the coordinates).

 

Change your button to purchase the new upgrade you just created instead of the GLA one (also change the .csf references if you so choose).

 

In the Object folder find ChinaInfantry (or whichever faction you are using).

For each of the Infantry there (except BlackLotus), on the first commented out UpgradeCameo spot, uncomment it out and change "None" to Upgrade_ChinaInfantryStealth

Then near the bottom of each infantry (before the "End" with no spaces in front of it) add this code:

 

  Behavior = StealthUpdate ModuleTag_Stealth
StealthDelay				= 2500 ; msec
StealthForbiddenConditions  = ATTACKING USING_ABILITY
MoveThresholdSpeed		  = 3
InnateStealth			   = No ;Requires upgrade first
OrderIdleEnemiesToAttackMeUponReveal  = Yes
 End



 Behavior = StealthUpgrade ModuleTag_StealthUpgrade
TriggeredBy = Upgrade_ChinaInfantryStealth
 End

 

There are 2 spaces before "Behavior" and "End" and 4 spaces before each of the other lines. Make sure you add this code directly after a line with "End" with 2 spaces in front of it.

Do this for each infantry (except BlackLotus who already has stealth) and you will be done.

Edited by freak4twenty

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×