Post tutorial RSS Making Units Amphibious: The Messy Method

This is how to make units capable of traversing Land and Sea, the lazy way.

Posted by on - Intermediate Client Side Coding

So for those of you who just want a Tank to be capable of traveling around unrestricted by Water or Land, and you don't much care about how fast other Tanks go in comparison to Jeeps, then here's how to do it. There are a few Textwalls that explain what does what and why, if you find these hard to read, scroll right down.

WARNING: THIS IS A MESSY METHOD FOR LAZY PROGRAMMERS AND NOVICES!

I'm going to assume you've got a Copy of the Rules.INI File, and you know where to place it for your MOD. I'm also assuming you have an extremely basic idea on how the game is going to read your MOD. I'm also going to assume that you've looked (or at least glanced at) the basics of making a MOD for this game.

If you haven't got a clue, then a basic checklist includes:
Create a 'ccmod.json' file
Create a Folder Called 'CCDATA'
Create a Folder Called 'DATA'
Create a File inside your DATA Folder and name it 'ModText.csv'

The 'ModText.csv' file is only needed for the Strings (the text the user sees), the game will expect to see this file, even if you choose to leave it completely empty.

Using a Text Editing Program (I'd recommend Notepad++), you will need to open your Rules.INI File and then save a Copy of that file in your [MOD]/CCDATA Folder. For the purposes of this exercise, we will call your MOD AmphibMOD.

So, with your Rules.INI file now in the 'AmphibMOD/CCDATA' folder, we can begin editing it. If you're using Notepad++ then this should be easy. First of all, you should be aware that all Units come under Movement Types. Movement Types in the game include:
Foot
Track
Wheel
Float
Buildable
Please note that Buildable is a FLAG that is listed with the Movement Type, and only applies to Structures. The Game expects to see either a 'YES' or 'NO' for this FLAG, and nothing else. The Movement Types are read as a Percentage (%), and the Game expects to see a Value between 0-100 followed by the '%' symbol. I personally haven't tested what a number over 100% will equate to, but we can presume that it means a Unit will be faster when moving across a Tile of that higher Value. For this, we are taking Wheeled Units and Tracked Units into account.

Search for the word 'Track' in your Rules.INI file. You will find there is the Value 'Tracked=YES' given for Units, and the Value 'Track=[NUMBER]%' for Terrain Types. Make every Unit you want to make Amphibious use the Value 'Tracked=YES' and the Units you don't want Amphibious use the Value 'Tracked=NO' then you can avoid Default-Code. Defaults for Tanks such as the Medium Tank are 'Tracked=YES' so these need to state that they are not Tracked Units if you don't want them to walk on water. Units whose Movement Type is not Tracked, for example the Jeep, will be Wheeled Vehicles and won't have a Tracked=? anything. The second bit is make Water allow Tracked Vehicles (now Amphibians) to travel. Find 'Water' and within it you will see 'Track=0%' meaning Tracked Units can't pass over it. To make them able to walk on Water, change this Value to a Value higher than 0% please note this Value must be a real number, no decimals.

Simple Version without Explanation:

Open Rules.INI using Notepad++
Find 'Tracked='<br />For units that you don't want being Amphibious, make the Values 'Tracked=NO'
For the Units you do want as Amphibious Units, Make sure they have 'Tracked=YES'
Once this is done, search for the Terrain Type by looking for 'Track='<br />Water will have a Value of 'Track=0%' change this value to a real number
Lower means Slower, Higher means Faster

Once this is done, save your Rules.INI File inside the following Directory:
C:\Users\[USER_ID]\Documents\CnCRemastered\Mods\Red_Alert\AmphibMOD\CCDATA

Make sure that you've got the 'ccmod.json' located inside the following Directory:
C:\Users\[USER_ID]\Documents\CnCRemastered\Mods\Red_Alert\AmphibMOD

Your 'ccmod.json' File should look like this:

{
	"name": "AMPHIBIOUS MOD",
	"description": "I CAN WALK ON WATER.",
	"author": "YOURNAME",
	"load_order": 2,
	"version_low": 0,
	"version_high": 1,
	"game_type": "RA"
}

and that should be it.


Yes it's Basic, yes it's Crude, and yes it's just asking for unexpected trouble. If you want Tesla Tanks to behave like normal Tanks, then you'll need to modify Aftermath.INI as well. Tesla Tanks are 'TTNK' and Chrono Tanks are 'CTNK' for those who are wondering.

FAQ:

Q1 - I want infantry to be able to swim, how do I do this?
A1 - This method will apply to Tracked Vehicles, just change the 'Foot=0%' Value for Water.
EX1 - Making Foot=[Number Higher that 0]% for Water will make all Infantry walk on Water
P1 - Since Men don't have Animations for Swimming, they will walk on top of the Water

Q2 - I just want my Transport Craft to be Amphibious, how do I do this?
A2a - This is from the Value 'Float=0%' on Land Types, change Land to allow Float
P2a - This will make all Sea Vessels Amphibious though
A2b - Make all units that Have 'Tracked=YES' use 'Tracked=NO' and Unit 'LST' use Tracked=YES
P2b(i) - The game may not allow you to do this, I haven't tried this yet for Navy Units
P2b(ii) - The previously Tracked Units will move like Wheeled units with their Values on Terrain

The FAQ will be updated on necessity.

Post a comment
Sign in or join with:

Only registered members can share their thoughts. So come on! Join the community today (totally free - or sign in with your social account on the right) and join in the conversation.

Tutorial
Browse
Tutorials
Share
Related Games
C&C: Red Alert: Remastered
C&C: Red Alert: Remastered Real Time Strategy
Command & Conquer: Remastered
Command & Conquer: Remastered Real Time Strategy
Related Groups