logo   login
right
Home Forums Downloads Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Forum Info
Forum Members: 18,644
Total Threads: 8,746
Posts: 95,530

Administrators:
DeeZire, Redemption

There are currently 25 users online.
Partner Links

Free Credit Repair

Learn the Ticket Broker Secrets
Advertisements


Generals & Zero Hour Editing Discuss any modding related issues to do with Generals and Zero Hour here.

Reply
 
LinkBack Thread Tools
Old 11-26-2004, 08:29 AM   #1 (permalink)
Senior Member
 
Join Date: Jan 2004
Location: London, UK
Posts: 390
Send a message via AIM to Slye_Fox Send a message via MSN to Slye_Fox Send a message via Yahoo to Slye_Fox
Default Deploying units only when theres room

Bassically MCVs
I know how to make the unit deploy,
my question is, how do I make them deploy only when there is room for the structure?

This is the code I got so far
Code:
;------------------------------------------------------------------------------
Object SovietVehicleMCV

  ; *** ART Parameters ***
  Draw = W3DTankDraw ModuleTag_01
    DefaultConditionState        
      Model               = Sov_V_MCV
    End
    ConditionState       = REALLYDAMAGED
      Model              = Sov_V_MCV
    End
    ConditionState       = RUBBLE
      Model              = Sov_V_MCV
    End

    TrackMarks           = EXTnkTrack.tga
    OkToChangeModelColor = Yes
  End

  ; ***DESIGN parameters ***
  DisplayName      = OBJECT:SovietVehicleMCV
  Side                   = Soviet
  EditorSorting          = VEHICLE
  ArmorSet
    Conditions           = None
    Armor                = TankArmor
    DamageFX             = TankDamageFX
  End
  BuildCost              = 1500
  BuildTime              = 45.0          ;in seconds    
  VisionRange            = 150
  ShroudClearingRange = 300
Prerequisites
    Object = SovietWarFactory
;    Object = SovietRepairPad
  End

  ExperienceValue        = 200 200 400 600 ;Experience point value at each level
  ExperienceRequired     = 0 200 300 600 ;Experience points needed to gain each level
  IsTrainable            = No  ;Can gain experience
  CrusherLevel           = 2  ;What can I crush?: 1 = infantry, 2 = trees, 3 = vehicles
  CrushableLevel         = 3  ;What am I?:        0 = for infantry, 1 = for trees, 2 = general vehicles
  CommandSet             = SovietMCVCommandSet
  
  ; *** AUDIO Parameters ***
  VoiceSelect         = DozerChinaVoiceSelect
  VoiceMove           = DozerChinaVoiceMove
  VoiceEnter          = DozerChinaVoiceMove
  VoiceTaskComplete   = DozerChinaVoiceBuildComplete
  SoundMoveStart      = DozerChinaMoveStart
  SoundMoveStartDamaged = DozerChinaMoveStart

  UnitSpecificSounds
    VoiceCreate       = DozerChinaVoiceCreate
    VoiceCrush        = DozerChinaVoiceCrush
    VoiceNoBuild      = DozerChinaVoiceBuildNot
    VoiceRepair       = DozerChinaVoiceRepair
    VoiceDisarm       = DozerChinaVoiceClearMine
    VoiceEnter        = DozerChinaVoiceMove
    VoiceBuildResponse = DozerChinaVoiceBuild
  End
  End

  ; *** ENGINEERING Parameters ***
  RadarPriority          = UNIT
  KindOf                 = PRELOAD SELECTABLE CAN_CAST_REFLECTIONS VEHICLE SCORE
  
  Body                   = ActiveBody ModuleTag_02
    MaxHealth       = 400
    InitialHealth   = 400
  End

  Locomotor            = SET_NORMAL MilitiaTankLocomotor
  Behavior = PhysicsBehavior ModuleTag_04
    Mass                 = 50.0
  End

  Behavior = ProductionUpdate ModuleTag_05
    ; nothing
  End

  ; Catch fire, and explode death
  Behavior = SlowDeathBehavior ModuleTag_07
    DeathTypes = ALL -CRUSHED -SPLATTED
    ProbabilityModifier  = 50
    DestructionDelay  = 2000
    DestructionDelayVariance  = 300
    FX  = INITIAL  FX_CrusaderCatchFire
    OCL = FINAL    OCL_MilitiaTankDeathEffect  
    FX  = FINAL    FX_GenericTankDeathExplosion 
  End

  Behavior                 = TransitionDamageFX ModuleTag_08
    ReallyDamagedParticleSystem1 = Bone:Smoke RandomBone:Yes PSys:SmallLightSmokeColumn
    ReallyDamagedFXList1 = Loc: X:0 Y:0 Z:0 FXList:FX_CrusaderDamageTransition
  End

  Behavior = DestroyDie ModuleTag_09
    DeathTypes = NONE +CRUSHED +SPLATTED
  End

  Behavior = ReplaceObjectUpgrade ModuleTag_101
    ReplaceObject = SovietCommandCenter
    TriggeredBy = Upgrade_BecomeSovietCommandCenter
  End

  ; A crushing defeat
  Behavior = FXListDie ModuleTag_10
    DeathTypes = NONE +CRUSHED +SPLATTED
    DeathFX = FX_CarCrush
  End

  Behavior = CreateCrateDie ModuleTag_CratesChange
   CrateData  = SalvageCrateData
  End

  Behavior = FlammableUpdate ModuleTag_21
    AflameDuration = 5000         ; If I catch fire, I'll burn for this long...
    AflameDamageAmount = 5       ; taking this much damage...
    AflameDamageDelay = 500       ; this often.
  End

  Geometry               = BOX
  GeometryMajorRadius    = 15.0
  GeometryMinorRadius    = 10.0
  GeometryHeight         = 10.0     
  GeometryIsSmall        = Yes    
  Shadow = SHADOW_VOLUME
  ShadowSizeX = 45  ; minimum elevation angle above horizon. Used to limit shadow length

End
Slye_Fox is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-26-2004, 10:13 AM   #2 (permalink)
Senior Member
 
Join Date: Mar 2003
Location: Rep. of Ireland
Posts: 373
Default

I know, I got the same problem with TD MCVs in TFTW, it seems it cannot be done, atleast code-wise, but I've been thinking maybe it could be scripted on a map, define trigger areas where the 'upgrade' only works?
Waraddict is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-26-2004, 11:15 AM   #3 (permalink)
Senior Member
 
Join Date: May 2004
Posts: 229
Default

you could try your idea with an combination of the gla´s attack tunnel logic ...
juLLe is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 11-27-2004, 10:11 AM   #4 (permalink)
Senior Member
 
Join Date: May 2003
Location: Eindhoven, Netherlands
Posts: 2,278
Send a message via ICQ to CodeCat Send a message via MSN to CodeCat
Default

I'm having the exact same problem (not surprisingly ). Right now it uses ReplaceObjectUpgrade but that's obviously only half a solution.

We thought about the sneak attack ourselves, but the main problem with that is that it just creates an OCL, it doesn't affect the owner of the special power in any way. So you can create the CY without problems, but you could create it anywhere on the map, and the MCV would stay. But if someone knows of a brilliant way to make it work, then I'm all ears!
CodeCat is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Manually Deploying Units AntiSocialKindaGuy Generals & Zero Hour Editing 0 11-11-2004 08:09 AM
Deploying Units Slye_Fox Generals & Zero Hour Editing 12 07-09-2004 12:19 PM
Deploying units / converting them to other units CodeCat Generals & Zero Hour Editing 4 11-17-2003 10:59 AM
Deploying lee Generals & Zero Hour Editing 1 11-16-2003 05:02 AM
deploying Cartman Red Alert 2 & Yuri's Revenge Editing 18 02-25-2003 04:16 PM


All times are GMT -4. The time now is 06:28 PM.


Design By: Miner Skinz.com
Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.