C&C Labs Forums
»
C&C Maps and Modding
»
Generals: Modding
»
Is it possible to have vehicles produce infantry?
Private Joined: 9/28/2015(UTC) Posts: 4
|
Can a vehicle produce infantry, or at least deploy into a building/factory unit and then produce infantry? I tried a few dozen ways that have resulted in some fun things but not in what I was after..
|
|
|
|
Major Joined: 3/27/2015(UTC) Posts: 490
Thanks: 5 times Was thanked: 213 time(s) in 155 post(s)
|
Yes you can, its just you can't set rally points(?) If you want it to deploy before producing infantry you can use GLA Combat Bike Logic-- assuming you want it to be stationary and it to switch commandsets. Or. You can have it just straight up make units. You also have to make sure it has STRUCTURE and FS_BARRACKS(?) KindOfs. (?)citation needed. ALSO -I bet you're expecting codes... So, I'll be posting/editing this post when I have an example of it. Edited by user Saturday, October 10, 2015 2:03:36 PM(UTC)
| Reason: Not specified |
|
|
|
|
Private Joined: 9/28/2015(UTC) Posts: 4
|
A week of testing later and I still haven't managed to make a vehicle produce infantry, I would love to make something similar to the command center vehicle in RA2- it drives somewhere I turn it into a building and it produces infantry, I tried a few different methods (all of the ones you mentioned included) and I still cannot make any headway.
|
|
|
|
Major Joined: 3/27/2015(UTC) Posts: 490
Thanks: 5 times Was thanked: 213 time(s) in 155 post(s)
|
well, this might not be what you're hoping for but this is a less complicated solution. Points: I'm not going to go in-detail on how I make such monstrosities. But I'm just going to put down the important bits.
1. Code:
; *** ENGINEERING Parameters ***
RadarPriority = STRUCTURE
KindOf = PRELOAD STRUCTURE SELECTABLE SCORE FS_FACTORY REPAIR_PAD FS_WARFACTORY MP_COUNT_FOR_VICTORY IMMUNE_TO_CAPTURE VEHICLE HUGE_VEHICLE CAN_CAST_REFLECTIONS EMP_HARDENED CAN_ATTACK ATTACK_NEEDS_LINE_OF_SIGHT SPAWNS_ARE_THE_WEAPONS GARRISONABLE_UNTIL_DESTROYED;AUTO_RALLYPOINT IMMOBILE
This is important. You can remove things such as "SPAWNS_ARE_THE_WEAPONS", "EMP_HARDENED", "GARRISONABLE_UNTIL_DESTROYED" and any other KindOf that you don't need. Just don't remove "STRUCTURE"(I think), "FS_FACTORY" and "FS_WARFACTORY"("FS_BARRACKS" if it trains infantry) 2. Code:
Behavior = ProductionUpdate ModuleTag_05
NumDoorAnimations = 1
DoorOpeningTime = 4000 ;in mSeconds
DoorWaitOpenTime = 2000 ;in mSeconds
DoorCloseTime = 5000 ;in mSeconds
ConstructionCompleteDuration = 1500 ;in mSeconds
End
Behavior = DefaultProductionExitUpdate ModuleTag_06
UnitCreatePoint = X: 0.0 Y:0.0 Z:0.0
NaturalRallyPoint = X: 50.0 Y:0.0 Z:0.0;NaturalRallyPointX must always match GeometryMajorRadius! -ML
End
Behavior = RepairDockUpdate ModuleTag_07
TimeForFullHeal = 5000 ;(in milliseconds)
NumberApproachPositions = 5
End
This is important. ProductionUpdate alone makes it make units. You don't need DoorAnimation shenanigans, actually. DefaultProductionExitUpdate is where the unit is spawned from in relation to wear the unit is facing. RepairDockUpdate is optional. Replace it with the appropriate Module to heal infantry-- otherwise, if you don't want units being repaired/healed by this unit, remove the module. <3> Code:
CommandButton RS_BuildRevenger
Command = UNIT_BUILD
Option = MUST_BE_STOPPED ;this makes its so that it can only be clicked/used once its not moving.
Object = RS_Revenger
TextLabel = CzAM:Tank_MBT
ButtonImage = CzAM_RS_MBT
ButtonBorderType = BUILD ; Identifier for the User as to what kind of button this is
DescriptLabel = CzAM:Tank_MBTToolTip
End
This is optional, this is on the side of CommandButtons. If you want the unit to stop before making units. Otherwise, you can still make this work with Bike Logic. Its complicated tho.
Edited by user Friday, October 23, 2015 12:18:24 PM(UTC)
| Reason: Not specified |
|
1 user thanked Zatsupachi for this useful post.
|
|
|
Private Joined: 9/28/2015(UTC) Posts: 4
|
Oh production update, now that I look again it should've been painfully obvious I needed that. Thanks alot!
|
|
|
|
Major Joined: 11/6/2015(UTC) Posts: 152
Thanks: 8 times Was thanked: 4 time(s) in 4 post(s)
|
question somewhere around the topic: can somebody help me with code for instant infantry "exchange"? like for example i click on Rebel ability and next moment he's gone, but on his place Tunnel Defender appears. basically it's fast kill this infantry, create new on his position, even without any animations.
|
|
|
|
Major Joined: 3/27/2015(UTC) Posts: 490
Thanks: 5 times Was thanked: 213 time(s) in 155 post(s)
|
see Combat Bike Logic...
Look around the forums-- methinks. |
|
|
|
|
Major Joined: 11/6/2015(UTC) Posts: 152
Thanks: 8 times Was thanked: 4 time(s) in 4 post(s)
|
Combat Bike changes rider not unit. i specifically mad example with too different units -it's not about switching weapon but about kill+create. so far i found nothing similar..
|
|
|
|
Major Joined: 3/27/2015(UTC) Posts: 490
Thanks: 5 times Was thanked: 213 time(s) in 155 post(s)
|
If you want unit switching to different modes. combat bike IS what you want. Each Rider can have a different model since riders are ConditionStates.
The other option is using the ReplaceObjectUpgrade Module. Which However, DOES NOT carry over Health and rank. |
|
|
|
|
Major Joined: 11/6/2015(UTC) Posts: 152
Thanks: 8 times Was thanked: 4 time(s) in 4 post(s)
|
switching modes is not what i'm after. can you please provide some examples about Replace? i mean upgrdae modules, i'm still bad about properly stating them in units body-code.. i just need the easiest code-wise way to make one unit disappear and another appear on his place. like if i'd select Rebel push a button and got Burton. Edited by user Monday, November 9, 2015 1:41:10 PM(UTC)
| Reason: Not specified
|
|
|
|
Major Joined: 3/27/2015(UTC) Posts: 490
Thanks: 5 times Was thanked: 213 time(s) in 155 post(s)
|
Code:
Behavior = ReplaceObjectUpgrade ModuleTag_xx
TriggeredBy = [Entry(S) from upgrade.ini]
FXListUpgrade = [entry from FXList.INI]
ConflictsWith = [entry(s) from Upgrade.INI]
RequiresAllTriggers = [Yes/No]
ReplaceObject = [Object name]
End
|
|
|
|
|
Major Joined: 5/21/2015(UTC) Posts: 107 Thanks: 6 times Was thanked: 19 time(s) in 16 post(s)
|
Why don't you check ROTR codes of the Russian Supply Tuck.. After an upgrade, it produces infantry after an upgrade. |
3D/2D Artist |
|
|
|
Major Joined: 11/6/2015(UTC) Posts: 152
Thanks: 8 times Was thanked: 4 time(s) in 4 post(s)
|
Originally Posted by: Oliver Why don't you check ROTR codes of the Russian Supply Tuck.. After an upgrade, it produces infantry after an upgrade. actually i'm exactly trying to modify ROTR and looking at Russian Supply Truck code = after upgrade it disappears and Field Quoter appears(totally other unit from another file) -that's what i'm after! but sadly i can't figure everything out %( lots of file to modify, at least= CommandSet, CommandButton, ObjectCreationList, RussianUpgradeObjects, and files of infantry i'm trying to make this all about..
|
|
|
|
Users browsing this topic |
Guest
|
C&C Labs Forums
»
C&C Maps and Modding
»
Generals: Modding
»
Is it possible to have vehicles produce infantry?
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.