Originally, the Crusader Tank was to be 'upgradeable' so that it could gain the ability to 'hover', which enabled it to cross water, effectively making it an amphibious unit. The image set for the original version of the unit can be found in the BETA files that shipped with the GMPT. The files themselves have been made available on several sites, so if you have those files you can follow this guide to making the original idea work. Just a point of historic interest here to stop you getting confused. The Crusader tank in the game is actually an older unit called the Leopard tank. When the hovering Crusader idea was dropped, the Leopard effectively replaced it and became the Crusader. This is why the Crusader in the game refers to the Leopard image set for its cameos. First off, you need to make a whole new object for your hovering Crusader tank. Im assuming that you are replacing the Crusader in the game to keep things simple and to make sure that object names and filenames dont get confused. Starting with the art parameters, heres what you need;- Object AmericaTankCrusader SelectPortrait = SALeopard_L ButtonImage = SALeopard UpgradeCameo1 = Upgrade_AmericaBattleDrone UpgradeCameo2 = Upgrade_AmericaScoutDrone UpgradeCameo3 = Upgrade_AmericaAdvancedTraining UpgradeCameo4 = Upgrade_AmericaCompositeArmor That lot simply ensures that our new object has the appropriate cameos when its going to be built and selected by the player. Again, I'm assuming that you are standardising this with all the other American tanks by allowing it the same upgrades, which is why the 'upgrade cameos' are there. Also, this new object is using the cameos for the current Crusader tank, not the original one. If you want the original one, then again you'll have to hunt that down from the beta files. Next, we're going to define all the drawing parameters for the model itself. This part will handle all the required images and animations for the Crusader tank in its various states. First things first, we have to open our drawing section with;- Draw = W3DModelDraw ModuleTag_01 OkToChangeModelColor = Yes That simply tells the game that we are starting to define the drawing parameters for the W3D model that this object uses, and that this model has at least one sub-object which can be remapped to the players chosen color. Theres an important point to note here - we are using the W3DModelDraw module for our Crusader rather than the normal W3DTankDraw - the reasons for this will become clearer later on. Now we have to do all the 'dirty work' - figuring out which bits of the model get displayed, when and under which conditions. This is done by defining what happens in various states and under various conditions, each of which is known coincidently enough as a ConditionState =. Our first one is like this;- ConditionState = NONE Model = AVCrusader Turret = Turret WeaponFireFXBone = PRIMARY TurretMS WeaponRecoilBone = PRIMARY Barrel WeaponMuzzleFlash = PRIMARY TurretFX WeaponLaunchBone = PRIMARY TurretMS TransitionKey = TRANS_Drive End That section does a few things. It basically says that when no special or particular condition is set for this object (in other words when its not doing anything) then the AVCrusader.W3D file should be used and displayed as the model. The next 4 lines tell the game which bones on that model are to be used as the base offsets to display the firing effect (from FXList.INI), the recoil of the barrel when it fires, the muzzle flash when it fires, and from where the projectile for the weapon first appears. All 4 lines also specify which weapon they relate to - in this case, they all point to PRIMARY (the first weapon) as in this example the Crusader will only have one weapon. We then give this ConditionState = a TransitionKey = which is used later - more on that when we come to it. Finally, we end the section with our End Statement. Next up, we have similar sections all taking a similar format which do the same job but define the same parameters for the tank when its moving, when its damaged, when its moving whilst damaged and when its been blown up (that is when it has become RUBBLE). This lot looks like this;- ConditionState = MOVING Model = AVCrusader Turret = Turret WeaponFireFXBone = PRIMARY TurretMS WeaponRecoilBone = PRIMARY Barrel WeaponMuzzleFlash = PRIMARY TurretFX WeaponLaunchBone = PRIMARY TurretMS TransitionKey = TRANS_Drive ParticleSysBone = TreadFX01 QuadCannonDust ParticleSysBone = TreadFX02 QuadCannonDust End ConditionState = REALLYDAMAGED Model = AVCrusader_D Turret = Turret WeaponFireFXBone = PRIMARY TurretMS WeaponRecoilBone = PRIMARY Barrel WeaponMuzzleFlash = PRIMARY TurretFX WeaponLaunchBone = PRIMARY TurretMS TransitionKey = TRANS_DriveDamaged End AliasConditionState = DAMAGED AliasConditionState = MOVING DAMAGED AliasConditionState = MOVING REALLYDAMAGED ConditionState = RUBBLE Model = AVCrusader_D Turret = Turret WeaponFireFXBone = PRIMARY TurretMS WeaponRecoilBone = PRIMARY Barrel WeaponMuzzleFlash = PRIMARY TurretFX WeaponLaunchBone = PRIMARY TurretMS End Note that we have also used another TransitionKey = in there, which means that so far we have assigned keys to let the game know (i) when its driving and (ii) when its driving whilst damaged. Another point to note there is that we have specified some particle systems to be used when the tank is moving - this is why we have used the W3DModelDraw module instead of the W3DTankDraw module. If we used the TankDraw module, we would get the default particle system displayed whenever the tank moved - even on water - and we dont want that, we only want the effect when it moves on ground. Next, we will deal with what the tank is going to look like and which models to use when it is hovering rather than driving. These sections look like this;- ConditionState = WEAPONSET_PLAYER_UPGRADE Model = AVCrusader_H Turret = Turret WeaponFireFXBone = PRIMARY TurretMS WeaponRecoilBone = PRIMARY Barrel WeaponMuzzleFlash = PRIMARY TurretFX WeaponLaunchBone = PRIMARY TurretMS TransitionKey = TRANS_Hover End ConditionState = WEAPONSET_PLAYER_UPGRADE MOVING Model = AVCrusader_H Turret = Turret WeaponFireFXBone = PRIMARY TurretMS WeaponRecoilBone = PRIMARY Barrel WeaponMuzzleFlash = PRIMARY TurretFX WeaponLaunchBone = PRIMARY TurretMS ParticleSysBone = TreadFX01 QuadCannonDust ParticleSysBone = TreadFX02 QuadCannonDust TransitionKey = TRANS_Hover End You will notice that those sections are practically the same as the first ones but with 2 important differences. First, the CondtionState = for each section is only applied when the tank has been upgraded with a new weapon. It doesnt really get a new weapon, this is just a 'trick' we are using to force the game to use a different model under a different condition (see later). Second, we are using a different model under those conditions, in this case its the AVCrusader_H model which is the image of the tank when its hovering. You will also notice that we have assigned another TransitionKey = to let the game know when the tank is hovering - so far we have assigned keys so we can tell when its driving (normal) and when its hovering (upgraded). Now for the neat trick - we can get the game to play a neat little animation sequence when the tank changes from its driving state to its hovering state. We do this with a TransitionState = which allows us to make use of the TransitionKey = things we defined. This section looks like this;- TransitionState = TRANS_Drive TRANS_Hover Model = AVCrusader_A HideSubObject = TurretFX01 Animation = AVCRUSADER_A.AVCRUSADER_A AnimationMode = ONCE End What that section says is 'when the object is changing from one condition to another, use the following as the display parameters in between them'. We use the TranstionKey = things we defined earlier to tell the game which states we are moving between - in this case, between 'driving' and 'hovering'. In this instance, we play the animation of the tank changing into its hovering state just the ONCE. Next, we do that lot again for when the tank is in the same states but damaged;- ConditionState = WEAPONSET_PLAYER_UPGRADE REALLYDAMAGED Model = AVCrusader_H Turret = Turret WeaponFireFXBone = PRIMARY TurretMS WeaponRecoilBone = PRIMARY Barrel WeaponMuzzleFlash = PRIMARY TurretFX WeaponLaunchBone = PRIMARY TurretMS TransitionKey = TRANS_HoverDamaged End AliasConditionState = WEAPONSET_PLAYER_UPGRADE DAMAGED AliasConditionState = WEAPONSET_PLAYER_UPGRADE MOVING DAMAGED AliasConditionState = WEAPONSET_PLAYER_UPGRADE MOVING REALLYDAMAGED ConditionState = WEAPONSET_PLAYER_UPGRADE RUBBLE Model = AVCrusader_H Turret = Turret WeaponFireFXBone = PRIMARY TurretMS WeaponRecoilBone = PRIMARY Barrel WeaponMuzzleFlash = PRIMARY TurretFX WeaponLaunchBone = PRIMARY TurretMS End TransitionState = TRANS_DriveDamaged TRANS_HoverDamaged Model = AVCrusader_A HideSubObject = TurretFX01 Animation = AVCRUSADER_A.AVCRUSADER_A AnimationMode = ONCE End Finally, we now need to tell the game how the unit looks when its travelling over water rather than on land. We do this with these sections;- ConditionState = WEAPONSET_PLAYER_UPGRADE OVER_WATER Model = AVCrusader_H Turret = Turret WeaponFireFXBone = PRIMARY TurretMS WeaponRecoilBone = PRIMARY Barrel WeaponMuzzleFlash = PRIMARY TurretFX WeaponLaunchBone = PRIMARY TurretMS End ConditionState = WEAPONSET_PLAYER_UPGRADE MOVING OVER_WATER Model = AVCrusader_H Turret = Turret WeaponFireFXBone = PRIMARY TurretMS WeaponRecoilBone = PRIMARY Barrel WeaponMuzzleFlash = PRIMARY TurretFX WeaponLaunchBone = PRIMARY TurretMS ParticleSysBone = TreadFX01 AmphibWave End AliasConditionState = WEAPONSET_PLAYER_UPGRADE MOVING OVER_WATER REALLYDAMAGED TrackMarks = EXTnkTrack.tga End A few things to note from that lot. First, we have added OVER_WATER to our conditions - this makes sure that the above image sets and W3D model files are only used when the object is over water. Second, we have changed the particle system here so that it displays some water splashing when it moves instead - remember, because we have used the ModelDraw module instead of the TankDraw module, we can do this, otherwise we would get the default dust used even on water. Finally, we have finished defining all of our conditions and art parameters, so we tell the game what to use for our 'tread marks' and then close the whole art section with an End statement. Now we need to create some event or trigger to make the tank 'upgrade' and change from a normal tank into a hovering one. As you saw earlier, this is done through a trick where we fool the game into thinking that the tank has a new weapon and thus should display a different model for it. The design and engineering parameters for your object will be unique to your mod so there is no point in me covering them here (if you have followed this from the start then you are probably still using the current Crusader as a template which is fine as you can just replace it with this). What you need to do is give the tank a normal weapon with no conditions applied, and then another weapon when it has been upgraded. You do this with these sections;- WeaponSet Conditions = None Weapon = PRIMARY CrusaderTankGun End WeaponSet Conditions = PLAYER_UPGRADE Weapon = PRIMARY CrusaderTankGun End That code does nothing more than to serve as a trigger for the game using the WEAPONSET_PLAYER_UPGRADE condition states that we have specified earlier. What you also need to do, is define 2 locomotors for the object - one for when its a normal tank, and one for when it has been upgraded and can hover over land or water. You can do this with this code;- Locomotor = SET_NORMAL CrusaderLocomotor Locomotor = SET_NORMAL_UPGRADED BasicAmphibiousLocomotor Again, that code just tells the game to use a normal locomotor, but when the object has been upgraded it uses a different one. Next, we need to define something thats going to trigger the upgrade. You need to tell the game that both the weapon and the locomotor are going to be upgraded. You do that with this code;- Behavior = WeaponSetUpgrade ModuleTag_10 TriggeredBy = Upgrade_AmericaAdvancedTraining End Behavior = LocomotorSetUpgrade ModuleTag_11 TriggeredBy = Upgrade_AmericaAdvancedTraining End Those 2 bits of code tell the game that when the player has 'built' the Advanced Training upgrade from the Strategy Center, the Crusader should get a weapon and locomotor upgrade - in other words, it will transform from a normal land based tank into a hovering amphibious one. You may have to change the numbers for those module tags depending on what else you have given your object and/or how you have configured it. There you go - you now have your Crusader able to act like a normal tank or turn into an amphibious hovering tank when you get the Advanced Training upgrade from your Strategy Center.
Thanks to who writed it!