Posted by: AdrianeMapMaker - Saturday, September 30, 2017 1:38:40 AM
I want a normal structure to be added into a another structure via [b]upgrade[/b]:
That can:
died if the placeholder structure died - like overlord did into its upgrade
NeededModule that i think i need:
Draw = W3DModelDraw
GrantUpgradeCreate (i want this upgrade created already - with exception - in construction
-is there any needed
Note: this is my Unfinished work ; fusing pure bone model to another model and wanna try it using how upgrade works - logic.
Posted by: SkyMix_RMT - Saturday, September 30, 2017 7:01:11 AM
Is this for a map.ini or a mod?
Posted by: AdrianeMapMaker - Saturday, September 30, 2017 8:04:44 AM
mod
Posted by: SkyMix_RMT - Saturday, September 30, 2017 6:31:37 PM
You can merge two structures together by using 2 draw modules. I have no ideia how to make it an upgrade though.
Posted by: acidbrain - Saturday, September 30, 2017 7:32:49 PM
You could use the POWER_PLANT_UPGRADED condition for the upgrade, here is an example, it is a helibase i made some time ago and i upgraded it with a patriotbattery, i didnt attach the patriotbattery to a bone, i placed it on the right coordinates in gmax/renx so it pops up at the side of the main building...
[img]http://www.sleipnirstuff.com/forum/files/america_helipad_day_209.jpg[/img]
[img]http://www.sleipnirstuff.com/forum/files/upgraded_798.jpg[/img]
[b]Upgrade.ini, CommandButton.ini, CommandSet.ini & DrawModule for PatriotBattery[/b]
[code=plain]
;--- Upgrade.ini ---
Upgrade Tnk_Upgrade_AmericaHeliPadDefense
DisplayName = UPGRADE:HeliPadDefense
Type = OBJECT
BuildTime = 10.0
BuildCost = 800
ButtonImage = Tnk_AmericaHeliPadDef
UnitSpecificSound = OverlordExpansion
End
;--- CommandButton.ini ---
CommandButton Tnk_Command_UpgradeAmericaHeliPadDefense
Command = OBJECT_UPGRADE
Upgrade = Tnk_Upgrade_AmericaHeliPadDefense
TextLabel = CONTROLBAR:UpgradeTnk_AmericaHeliPadDefense
ButtonImage = Tnk_AmericaHeliPadDef
ButtonBorderType = UPGRADE ; Identifier for the User as to what kind of button this is
DescriptLabel = CONTROLBAR:ToolTipTnk_AmericaUpgradeHeliPadDefense
End
;--- CommandSet.ini ---
CommandSet Tnk_AmericaHeliPadCommandSet
1 = Tnk_Command_ConstructAmericaVehicleComanche
3 = Tnk_Command_ConstructAmericaVehicleBlackhawk
7 = Command_UpgradeComancheRocketPods
11 = Tnk_Command_UpgradeAmericaHeliPadDefense
13 = Command_SetRallyPoint
14 = Command_Sell
End
;--- DrawModule for PatriotBattery ---
;--------------Patriot Defense Upgrade--------------
Draw = W3DModelDraw ModuleTag_Defense
OkToChangeModelColor = Yes
DefaultConditionState
Model = ABHeliPad_DEF
Turret = TURRET01
TurretPitch = TURRETEL
WeaponLaunchBone = PRIMARY WeaponA
WeaponLaunchBone = SECONDARY WeaponA
WeaponLaunchBone = TERTIARY WeaponA
WeaponFireFXBone = PRIMARY WeaponA
WeaponFireFXBone = SECONDARY WeaponA
WeaponFireFXBone = TERTIARY WeaponA
HideSubObject = CHASSIS HOUSECOLOR01 HOUSECOLOR02 TURRET01 TURRETEL OBJECT01
End
AliasConditionState = DAMAGED
AliasConditionState = REALLYDAMAGED
AliasConditionState = NIGHT
AliasConditionState = NIGHT DAMAGED
AliasConditionState = NIGHT REALLYDAMAGED
AliasConditionState = SNOW
AliasConditionState = SNOW DAMAGED
AliasConditionState = SNOW REALLYDAMAGED
AliasConditionState = NIGHT SNOW
AliasConditionState = NIGHT SNOW DAMAGED
AliasConditionState = NIGHT SNOW REALLYDAMAGED
ConditionState = POWER_PLANT_UPGRADED
Model = ABHeliPad_DEF
ShowSubObject = CHASSIS HOUSECOLOR01 HOUSECOLOR02 TURRET01 TURRETEL
End
AliasConditionState = POWER_PLANT_UPGRADED NIGHT
ConditionState = POWER_PLANT_UPGRADED DAMAGED
Model = ABHeliPad_DEFD
ShowSubObject = CHASSIS HOUSECOLOR01 HOUSECOLOR02 TURRET01 TURRETEL
ParticleSysBone = SmokeS01 SmolderingSmoke
ParticleSysBone = SmokeS02 SmolderingSmoke
ParticleSysBone = FireS01 SmolderingFire
ParticleSysBone = FireS02 SmolderingFire
End
AliasConditionState = POWER_PLANT_UPGRADED NIGHT DAMAGED
ConditionState = POWER_PLANT_UPGRADED REALLYDAMAGED
Model = ABHeliPad_DEFE
ShowSubObject = CHASSIS HOUSECOLOR01 HOUSECOLOR02 TURRET01 TURRETEL
ParticleSysBone = SmokeS01 SmolderingSmoke
ParticleSysBone = SmokeM01 SmokeFactionMedium
ParticleSysBone = FireS01 SmolderingFire
ParticleSysBone = FireM01 FireFactionMedium
End
AliasConditionState = POWER_PLANT_UPGRADED NIGHT REALLYDAMAGED
ConditionState = POWER_PLANT_UPGRADED SNOW
Model = ABHeliPad_DEFS
ShowSubObject = CHASSIS HOUSECOLOR01 HOUSECOLOR02 TURRET01 TURRETEL OBJECT01
End
AliasConditionState = POWER_PLANT_UPGRADED NIGHT SNOW
ConditionState = POWER_PLANT_UPGRADED SNOW DAMAGED
Model = ABHeliPad_DEFDS
ShowSubObject = CHASSIS HOUSECOLOR01 HOUSECOLOR02 TURRET01 TURRETEL OBJECT01
ParticleSysBone = SmokeS01 SmolderingSmoke
ParticleSysBone = SmokeS02 SmolderingSmoke
ParticleSysBone = FireS01 SmolderingFire
ParticleSysBone = FireS02 SmolderingFire
End
AliasConditionState = POWER_PLANT_UPGRADED SNOW NIGHT DAMAGED
ConditionState = POWER_PLANT_UPGRADED SNOW REALLYDAMAGED
Model = ABHeliPad_DEFES
ShowSubObject = CHASSIS HOUSECOLOR01 HOUSECOLOR02 TURRET01 TURRETEL OBJECT01
ParticleSysBone = SmokeS01 SmolderingSmoke
ParticleSysBone = SmokeM01 SmokeFactionMedium
ParticleSysBone = FireS01 SmolderingFire
ParticleSysBone = FireM01 FireFactionMedium
End
AliasConditionState = POWER_PLANT_UPGRADED SNOW NIGHT REALLYDAMAGED
End
;---------------------------------
;Normal energy consumption
EnergyProduction = -1
;Energy consumption when upgraded
EnergyBonus = -3
;---------------------------------
;PowerPlantUpgrade module
Behavior = PowerPlantUpgrade ModuleTag_Def02
TriggeredBy = Tnk_Upgrade_AmericaHeliPadDefense
End
;allows this object to act as an (upgradeable) power supply,
;this enables the POWER_PLANT_UPGRADED conditionstate
Behavior = PowerPlantUpdate ModuleTag_Def03
;RodsExtendTime = integer -> milliseconds e.g. 5000 for 5 seconds
End
[/code]
What is handy about the POWER_PLANT_UPGRADED conditionstate is that you can increase the power consumption if you ugrade the main model with an object that uses power, also used it for a transformator upgrade for a gattling bunker but for power supply instead, the gattling bunker becomes independent of powerplants when it is upgraded with a transformator...
It is possible to make the upgrade model rise from the ground or roof or whatever if you use the RodsExtendTime parameter in the PowerPlantUpdate module and make an animation in gmax/renx, you can use the POWER_PLANT_UPGRADING conditionstate.
[img]http://www.sleipnirstuff.com/forum/files/trafo_upgrade_390.jpg[/img]
Cheers and have fun
Posted by: SkyMix_RMT - Saturday, September 30, 2017 9:10:09 PM
That was very helpful acidbrain, thank you very much, this gave me ideias!
Posted by: AdrianeMapMaker - Sunday, October 1, 2017 6:04:16 AM
Btw Thankssssssssssssssss!!!! - is there any like the overlord portable structure logic can i use it in building?