Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
Offline SatchTFF  
#1 Posted : Wednesday, August 14, 2019 11:54:11 AM(UTC)
SatchTFF
Private
Joined: 2/19/2018(UTC)
Posts: 9
Philippines
Location: NCR

Thanks: 1 times
Hello, I wanted to have an Infantry in Shockwave Mod to behave like those of Wasp Hive in ROTR Mod. I've tried several methods like having the upgrades implemented in the Infantry via Map.ini and even resulting to copying the Behavior Module of the Wasp Hive in ROTR.

Here's what I have done so far:

Code:

;------------------------------------
;Create a new unit using Airborne Ranger
;------------------------------------
;Object Airf_AmericaInfantryAirborneRanger
;	AddModule ModuleTag_XX_Override
;		Behavior = GrantUpgradeCreate ModuleTag_XX
;			UpgradeToGrant = Upgrade_AmericaBattleDrone
;		End
;	End
;
;	Behavior = ObjectCreationUpgrade ModuleTag_08
;    	UpgradeObject = OCL_AmericanTechnicianDrones
;    	TriggeredBy   = Upgrade_AmericaBattleDrone
;  	End
;
;	Behavior = SpawnBehavior ModuleTag_Drones01
;    	SpawnNumber           = 3
;    	SpawnReplaceDelay     = 5000
;    	SpawnTemplateName     = AmericaVehicleBattleDrone
;    	ExitByBudding         = No
;    	InitialBurst          = 1
;    	OneShot               = No
;    	AggregateHealth       = No
;    	SlavesHaveFreeWill    = No
;    	SpawnedRequireSpawner = Yes
;  	End
;End


I commented them out since every time I tried opening the map with this code, the game crashes.

Are there any other ways to have an Infantry spawn drones overhead, like have 1 Battledrone, 1 Hellfire Drone and 1 Scout Drone tailing the Infantry? Or at the very least, have 3 Battledrones follow the Infantry?

SatchTFF attached the following image(s):
Screenshot (149).png
Sponsor
Offline AdrianeMapMaker  
#2 Posted : Friday, August 16, 2019 8:28:07 PM(UTC)
AdrianeMapMaker
General
C&C Labs Staff: Labs Staff MemberMaps Staff: Maps Staff Member
Joined: 3/8/2016(UTC)
Posts: 1,156
Philippines

Thanks: 312 times
Was thanked: 185 time(s) in 149 post(s)
are you creating this for a specific map only or a mod ?
A part of ZH worldbuilders map making community
https://discord.gg/tJ6zyGb

UserPostedImage





Offline SatchTFF  
#3 Posted : Saturday, August 17, 2019 3:08:10 AM(UTC)
SatchTFF
Private
Joined: 2/19/2018(UTC)
Posts: 9
Philippines
Location: NCR

Thanks: 1 times
Originally Posted by: adrianemapmaker Go to Quoted Post
are you creating this for a specific map only or a mod ?


It's for a Map.
Offline UTD^Force  
#4 Posted : Saturday, August 17, 2019 9:21:00 AM(UTC)
UTD^Force
Colonel
C&C Labs Staff: Labs Staff MemberMaps Staff: Maps Staff Member
Joined: 8/13/2013(UTC)
Posts: 817
Jordan
Location: Middle east

Thanks: 430 times
Was thanked: 184 time(s) in 168 post(s)
I've just checked what you want to do.
I did it for zero hour, so you will need to change some names to the ones from shockwave.
Code:
ObjectCreationList OCL_AmericanBattleDronePlusOP
  CreateObject
    Offset = X:0 Y:0 Z:10 
    ObjectNames = AmericaVehicleBattleDrone
    IgnorePrimaryObstacle = Yes
    Disposition = LIKE_EXISTING
    Count = 3
    RequiresLivePlayer = Yes
  End
End
;Make sure it is in this order, OCL then object or it will crash as the game reads the code line by line
Object AmericaInfantryRanger
 AddModule 
  Behavior = ObjectCreationUpgrade ModuleTag_90
    UpgradeObject = OCL_AmericanBattleDronePlusOP
    TriggeredBy   = Upgrade_AmericaBattleDrone
  End
 End
 AddModule 
  Behavior = GrantUpgradeCreate ModuleTag_89
    UpgradeToGrant = Upgrade_AmericaBattleDrone
  End
 End
End

You will need 'AddModule' and 'End' for each behaviour not just for one, that was causing the crash.
Proud Muslim

UTD^Force

Moderator and former map reviewer
CnC Labs
Users browsing this topic
Guest
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.