Jump to content


Photo

Special Powers


  • Please log in to reply
6 replies to this topic

#1 AdmiralGT

AdmiralGT

    title available

  • Members
  • 1,702 posts
  • Location:Bristol, UK
  • Projects:Petrolution

Posted 12 July 2004 - 02:48 PM

Ok, sorted the Enum thing so rather than make a new topic i'll just edit this one. Is there anyway to make a special power have a cost. What im doing is instead of a building making vehicles, it calls in a Cargo Plane to drop one. Currently it uses a Special Power and the Paradrop Logic but this means it has no cost. Is there any way to add a cost to it?

Edited by AdmiralGT, 12 July 2004 - 03:19 PM.


#2 warlord

warlord
  • New Members
  • 5 posts
  • Projects:[C&C:ZH|UT2k4|Doom 3] Modding

Posted 12 July 2004 - 03:41 PM

hmm not sure. i would like to know as well just incase i ever decide to do a mod with special powers with a cost.

#3 NVShacker

NVShacker
  • New Members
  • 17 posts

Posted 30 July 2004 - 08:19 PM

Hmm... short of using Aircraft Carrier Logic (A major headache, trust me, though it may be better for this) this is what I'd do (A bit tedious though):

Make each unit's cost into an upgrade with the vehicles strings and icon. Have this upgrade referenced in a commandset upgrade in the vehicle plant like this:
 Behavior = CommandSetUpgrade ModuleTag_XX;Do the same for all vehicles. 
;The commandset would have the special power, which would have a reload time of 
;something like two seconds to keep from using multiple times.
    TriggeredBy = Upgrade_TankPlantDropBigTankCommandSet
    RemovesUpgrades = Upgrade_TankPlantBuyCommandSet
    CommandSet = TankPlantBigTankDropCommandSet
  End
  Behavior = CommandSetUpgrade ModuleTag_XX;This contains all the upgrades to be bought.
    TriggeredBy = Upgrade_TankPlantBuyCommandSet
    RemovesUpgrades = Upgrade_TankPlantBuyCommandSet;Add all vehicle upgrade ones here.
    CommandSet = TankPlantBuyCommandSet
  End

Finally, in the cargo plane give it a grantupgrade module that gives Upgrade_TankPlantBuyCommandSet. It would take some work, I imagine, to get build queues to not mess up, but I think this is a decent basis. As far as aircraft carrier logic, just give your vehicle a drone that is a kindof aircraftcarrier (I think, might want to look that up) and it purchases an object with the cost of the unit. I don't know that that would stop you from purchasing the object while in the negatives though...

#4 Mastermind

Mastermind

    Server Technician

  • Undead
  • 7,014 posts
  • Location:Cambridge, MA
  • Projects:MasterNews 3
  •  The Man Behind the Curtain

Posted 30 July 2004 - 09:00 PM

Just make your factory or whatever build a dummy object which calls an OCL which paradrops your unit. It's a lot of OCL's and such, but it can be done.
:p
Posted Image

Well, when it comes to writing an expository essay about counter-insurgent tactics, I'm of the old school. First you tell them how you're going to kill them. Then you kill them. Then you tell them how you just killed them.

Too cute! | Server Status: If you can read this, it's up |

#5 NVShacker

NVShacker
  • New Members
  • 17 posts

Posted 31 July 2004 - 01:28 AM

You can make an OCL that has a designation like CREATE_AT_EDGE_NEAR_SOURCE? Cool, I never knew that.

#6 AdmiralGT

AdmiralGT

    title available

  • Members
  • 1,702 posts
  • Location:Bristol, UK
  • Projects:Petrolution

Posted 31 July 2004 - 10:03 AM

Just make your factory or whatever build a dummy object which calls an OCL which paradrops your unit.  It's a lot of OCL's and such, but it can be done.
:p

<{POST_SNAPBACK}>


Im having some trouble getting this to work. I cant seem to get the Dummy Object to automate the production of the OCL. The object dies with the code

 Behavior = CreateObjectDie ModuleTag_15
    DeathTypes = ALL
    CreationList = SUPERWEAPON_CHALLENGERII
  End

But the paradrop never arrives. Also I cant seem to give the Dummy Object a Position on Creation other than the Rally Point but this adds more "clicks" while playing. Firstly selecting the Rally Point and then selecting the production of the Dummy Object. Is there any other Command Types that select a location other than NEED_TARGET_POS but works with a UNIT_BUILD Command. Or am I doing the OCL totally wrong?

#7 Mastermind

Mastermind

    Server Technician

  • Undead
  • 7,014 posts
  • Location:Cambridge, MA
  • Projects:MasterNews 3
  •  The Man Behind the Curtain

Posted 31 July 2004 - 04:15 PM

I'd try using the Create At Location for the OCL, or something similar to that. Try different things in the OCL code and see what works. I'll take a look at this when I get a chance.
:p
Posted Image

Well, when it comes to writing an expository essay about counter-insurgent tactics, I'm of the old school. First you tell them how you're going to kill them. Then you kill them. Then you tell them how you just killed them.

Too cute! | Server Status: If you can read this, it's up |




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users