21. Mai 2024, 13:48 Hallo Gast.
Willkommen Gast. Bitte einloggen oder registrieren. Haben Sie Ihre Aktivierungs E-Mail übersehen?

Einloggen mit Benutzername, Passwort und Sitzungslänge. Hierbei werden gemäß Datenschutzerklärung Benutzername und Passwort verschlüsselt für die gewählte Dauer in einem Cookie abgelegt.


Select Boards:
 
Language:
 


Autor Thema: Formation-Code?¿  (Gelesen 2409 mal)

Tipppfehler

  • Gastwirt zu Bree
  • **
  • Beiträge: 133
Formation-Code?¿
« am: 30. Apr 2009, 18:51 »
Also ich bin gerade dabei in Aragorns Totenarmespell die untoten-Reiter zu intigrieren. Allerdings sollen sie in einer Formation laufen; 5 Reiter nebeneinander!

Die Reiter sind nebeneinander (auch 5 stück)! Allerdings (ich schreibe eine map.ini!) können die Reiter nicht angreifen und werden auch nicht angegriffen..... da ich mich mit dem formationcode nicht so gut auskenne, könnte mir bitte jemand helfen?
Außerdem verschwinden sie nicht nachdem die "Lebenszeit" abgelaufen ist!?

Hier der Code von den Reitern:
Object RohanOathbreakersCavalryNew

SelectPortrait         = UPOathBreakers

; *** ART Parameters ***

AddModule
Draw = W3DScriptedModelDraw ModuleTag_01
StaticModelLODMode = yes ; Will append M or L to the skin name depending on GameLOD


DefaultModelConditionState
Model = RUOthHrse_SKN
End


IdleAnimationState
Animation = IdleA
AnimationName = RURohrm_SKL.RURohrm_IDLA
AnimationPriority = 20
AnimationMode = ONCE
AnimationBlendTime = 15
End
Animation = IdleB
AnimationName = RURohrm_SKL.RURohrm_IDLB
AnimationMode = ONCE
AnimationBlendTime = 15
End
End

AnimationState = PASSENGER
Animation = grabbed
AnimationName = RURohrm_SKL.RURohrm_GBDA
AnimationMode = LOOP
End
Flags = RANDOMSTART
End

; --- stunned anims
AnimationState = FREEFALL
Animation = free fall
AnimationName = RURohrm_SKL.RURohrm_FLYB
AnimationMode = LOOP
End
Flags = RANDOMSTART
End

AnimationState = STUNNED_FLAILING
Animation = JustDie
AnimationName = RURohrm_SKL.RURohrm_FLYC
AnimationMode = LOOP
End
Flags = RANDOMSTART
End

AnimationState = STUNNED
Animation = Land
AnimationName = RURohrm_SKL.RURohrm_LNDA
AnimationMode = ONCE
End
End

AnimationState = STUNNED_STANDING_UP
Animation = StandUp
AnimationName = RURohrm_SKL.RURohrm_GTPA
AnimationMode = ONCE
End
End

; This is the no-spawn-horse type of death
AnimationState = DYING     ; DEATH_2 Normally has DEATH_2, but just as a backup don't insist
Animation = JustDie
AnimationName = RURohrm_SKL.RURohrm_DIEA

AnimationMode = ONCE
End
End

; When the rider is killed, we call this animation even though the unit hasn't officially died yet.
AnimationState = DEATH_2
Animation = JustDie
AnimationName       = RURohrm_SKL.RURohrm_DIEB
AnimationMode       = ONCE
End
End

AnimationState = MOVING ENGAGED
Animation = Moving_Engaged
AnimationName = RURohrm_SKL.RURohrm_RUNC
AnimationMode = LOOP
End
Flags               = RANDOMSTART
End

AnimationState = TURN_LEFT_HIGH_SPEED
Animation = TurnLeft
AnimationName = RURohrm_SKL.RURohrm_TNL1
AnimationMode = LOOP
; AnimationSpeedFactorRange= 1.8 1.8
AnimationBlendTime = 20
End
End

AnimationState = TURN_RIGHT_HIGH_SPEED
Animation = TurnLeft
AnimationName = RURohrm_SKL.RURohrm_TNR1
AnimationMode = LOOP
; AnimationSpeedFactorRange= 1.8 1.8
AnimationBlendTime = 20
End
End

AnimationState = MOVING WANDER
Animation = WLKA
AnimationName = RURohrm_SKL.RURohrm_WLKA
AnimationMode = LOOP
End
End

AnimationState = MOVING TURN_LEFT
Animation = TurnLeft
AnimationName = RURohrm_SKL.RURohrm_TRNL
AnimationMode = LOOP
End
End

AnimationState = MOVING TURN_RIGHT
Animation = TurnRight
AnimationName = RURohrm_SKL.RURohrm_TRNR
AnimationMode = LOOP
End
End

AnimationState = MOVING ACCELERATE
Animation = Accelerate
AnimationName = RURohrm_SKL.RURohrm_ACCL
AnimationMode = LOOP
End
End

AnimationState = MOVING DECELERATE
Animation = Decelerate
AnimationName = RURohrm_SKL.RURohrm_DECL
AnimationMode = ONCE
End
End

AnimationState = MOVING
Animation = RunA
AnimationName = RURohrm_SKL.RURohrm_RUNA
AnimationMode = LOOP
End
Flags = RANDOMSTART
End

AnimationState = SELECTED
SimilarRestart =   Yes
Animation = AtAttention
AnimationName = RURohrm_SKL.RURohrm_ATNA
AnimationMode = ONCE
End
End
End
End
ShockwaveResistance = SHOCKWAVE_RESISTANCE_IMMUNE


; ***DESIGN parameters ***
Side = Men
EditorSorting = UNIT
ThreatLevel = 2.0
TransportSlotCount = TRANSPORTSLOTCOUNT_UNIT
CommandPoints = 0

WeaponSet
Conditions = None
Weapon = PRIMARY    OathbreakerSword
AutoChooseSources = PRIMARY FROM_PLAYER FROM_SCRIPT FROM_AI
End

ArmorSet
Conditions      = None
Armor           = OathBreakerArmor
DamageFX        = NormalDamageFX
End

VisionRange = 280.0
DisplayName = OBJECT:Oathbreaker
CrushableLevel = 4  //What am I?:        0 = for infantry, 1 = for trees, 2 = general vehicles
CrusherLevel = 5
MinCrushVelocityPercent = 0% // Always crushes
CrushDecelerationPercent = 0% // Lose 0 percent of max velocity when crushing.
CrushKnockback = 10  // Don't knock back.
CrushZFactor = 10.0  // How much we knock upwards.

; *** AUDIO Parameters ***;



VoiceAttack = OathbreakerVoxSelect
; VoiceCreated = OathbreakerVoxSelect
; VoiceFullyCreated = OathbreakerVoxSelect
VoiceMove = OathbreakerVoxSelect
VoicePriority = 16
VoiceSelect = OathbreakerVoxSelect
;VoiceSelect2 = RohirrimAttention

SoundCrushing = RohirrimCrushing ; Sound made when crushing another unit underhoof
SoundImpact = ImpactHorse
SoundMoveStart = GondorHorseMoveStart

UnitSpecificSounds
VoiceGarrison = OathbreakerVoxSelect
VoiceEnterUnitElvenTransportShip = OathbreakerVoxSelect
VoiceEnterUnitEvilMenTransportShip = OathbreakerVoxSelect
VoiceEnterUnitMordorMumakil = OathbreakerVoxSelect
VoiceEnterUnitSlaughterHouse = OathbreakerVoxSelect
VoiceInitiateCaptureBuilding = OathbreakerVoxSelect
End

; Tie into LargeGroupAudio system
AddModule
Behavior = LargeGroupAudioUpdate ModuleTag_LGAU
Key = Oathbreaker
End
End
    ; Warn the player when the enemy gets a unit. Override the normal sighting event from StandardUnitEvaEvents.inc
    EvaEnemyObjectSightedEvent = DiscoveredEnemyOathbreaker ;GenericEnemyUnitSighted ; Normal response to enemy units

AddModule
ClientUpdate = EvaAnnounceClientCreate ModuleTag_CreateAnnounce
AnnouncementEventEnemy = DiscoveredEnemyOathbreaker
AnnouncementEventAlly = None
AnnouncementEventOwner = None

OnlyIfVisible = Yes ; Don't announce if hidden in the shroud
CountAsFirstSightedAnnoucement = Yes ; Don't re-annouce if going into shroud & back
UseObjectsPosition = No ; Play from central Fortress, not at unit's position
CreateFakeRadarEvent = Yes ; Allow player to jump to unit after hearing annoucement
End
End
; *** ENGINEERING Parameters ***

CommandSet = RohanOathbreakerHordeCommandSet


RadarPriority = UNIT
ThingClass = CAVALRY_UNIT
KindOf = PRELOAD SELECTABLE CAN_CAST_REFLECTIONS INFANTRY PATH_THROUGH_EACH_OTHER SCORE THROWN_OBJECT ARMY_OF_DEAD


AddModule
Body = ActiveBody ModuleTag_02
MaxHealth         = 500                ;BALANCE Man at Arms Health
MaxHealthDamaged  = 5
RecoveryTime      = 5000
End
End
AddModule
Behavior = AIUpdateInterface ModuleTag_03
AutoAcquireEnemiesWhenIdle = Yes ATTACK_BUILDINGS
AILuaEventsList = RohirrimFunctions
AttackPriority = AttackPriorityCavalry
End
End
LocomotorSet
Locomotor = HorseLocomotor
Condition = SET_NORMAL
Speed     = 100

End
AddModule
Behavior = PhysicsBehavior ModuleTag_04
GravityMult = 1.0
ShockStunnedTimeLow = 1400
ShockStunnedTimeHigh = 2400
ShockStandingTime = 2400
End
End
AddModule
Behavior = OathbreakersFadeAwayBehavior ModuleTag_05
FadeOutTime   = 3500 ;  Fade time in ms - 4000 == 4 seconds.
End
End
AddModule
Behavior = LifetimeUpdate ModuleTag_LifetimeUpdate
MinLifetime = 26000
MaxLifetime = 26000
End
End
AddModule
Behavior = AODCrushCollide ModuleTag_06
SmallFXList = FX_AODHitSmall; FXList for small objects.
MediumFXList = FX_AODHitMedium; FXList for medium objects.
        ;LargeFXList = FX_AODHitLarge; FXList for medium objects.

; Normal damage delivered.
Damage = 99999.0  ; normally really lethal
DamageType = CRUSH
DeathType = CRUSHED

SpecialObject = NONE +MordorBalrog -SELECTABLE -CAVALRY -INFANTRY -HERO -MONSTER; Special objects receive and dish out special damage.
SpecialDamage = 100.0  ; not as lethal
SpecialDamageType = CRUSH
SpecialDeathType = CRUSHED

SelfDamage = 9999.0  ; Damaging a special object inflicts damage on self.
SelfDamageType = FLAME
SelfDeathType = BURNED
End
End
AddModule
Behavior = SlowDeathBehavior ModuleTag_08
DeathTypes = ALL
SinkDelay = 1000
SinkRate = 1.40     ; in Dist/Sec
DestructionDelay = 10000
;ProbabilityModifier = 33
DeathFlags = DEATH_2 ; Tell model which death animation to play. Sets BOTH model condition and object status bits.
;Sound = INITIAL OathbreakerDie
End
End
Geometry = CYLINDER
GeometryMajorRadius = 10.4
GeometryMinorRadius = 10.4
GeometryHeight = 20.0
GeometryIsSmall = No
;Shadow = SHADOW_DECAL
;ShadowSizeX = 30;
;ShadowSizeY = 21;
;ShadowTexture = ShadowI;

End


Und hier der Foramtion-Code:
Object OathbreakerHorseRiderBatNew

SelectPortrait         = UPOathBreakers
ButtonImage = UPOathBreakers

AddModule
Draw = W3DScriptedModelDraw ModuleTag_W3DModelDraw
    DependencySharedModelFlags = EMOTION_ALERT EMOTION_MORALE_HIGH EMOTION_MORALE_LOW EMOTION_AFRAID EMOTION_COWER SELECTED EMOTION_TERROR
DefaultModelConditionState
Model = None //InvisHrdeTmp
End
ModelConditionState = HORDE_EMPTY
Model = None
End
ModelConditionState = WORLD_BUILDER
Model = HordeMarkRUOat
End
End
ENd

Side = Men
EditorSorting = UNIT
EmotionRange = 240

WeaponSet
Conditions = None
Weapon = PRIMARY    OathbreakerSword
AutoChooseSources = PRIMARY FROM_PLAYER FROM_SCRIPT FROM_AI
End


CommandSet = RohanOathbreakerHordeCommandSet

// *** AUDIO Parameters ***//
// Note: Don't put voice parameters here -- they will be ignored. Voice play requests
// are always passed through to members

BuildCost = 0 //not build just spawned
BuildTime = 0       
VisionRange = 500
VisionSide = 50%
VisionRear = 25%
VisionBonusPercentPerFoot = 1.0%
CommandPoints = 0

VisionRange = 280.0
DisplayName = OBJECT:Oathbreaker
CrushableLevel = 4  //What am I?:        0 = for infantry, 1 = for trees, 2 = general vehicles
CrusherLevel = 5
MinCrushVelocityPercent = 0% // Always crushes
CrushDecelerationPercent = 0% // Lose 0 percent of max velocity when crushing.
CrushKnockback = 10  // Don't knock back.
CrushZFactor = 10.0  // How much we knock upwards.

    TransportSlotCount = TRANSPORTSLOTCOUNT_SMALL_HORDE

KindOf = HERO SELECTABLE CAN_ATTACK INFANTRY HORDE MELEE_HORDE ARMY_OF_DEAD SCARY SUMMONED

AddModule
Body = ImmortalBody ModuleTag_ImmortalBody
MaxHealth = 1
End
End

AddModule
Behavior = HordeAIUpdate ModuleTag_HordeAIUpdate
AutoAcquireEnemiesWhenIdle = Yes ATTACK_BUILDINGS
MoodAttackCheckRate        = 500
MaxCowerTime = 5000
MinCowerTime = 3000
AttackPriority = AttackPriorityCavalry
End
End


AddModule
Behavior = LifetimeUpdate ModuleTag_LifetimeUpdate
MinLifetime = 26000
MaxLifetime = 26000
DeathType       = FADED
End
End
AddModule
Behavior = AODHordeContain ModuleTag_HordeContain
ObjectStatusOfContained =
InitialPayload = RohanOathbreakersCavalryNew OATHBREAKER_HORDE_SIZE
Slots = 3
PassengerFilter = ANY +INFANTRY +CAVALRY
ShowPips = No
ThisFormationIsTheMainFormation = Yes //Used to determine which armorset to use (and anything else we want!)
RandomOffset = X:0 Y:0 // X:25 Y:25

// AOD sine wave movement.
FrequencyScale = 0.3// // how fast they move left to right.
FrequencyRandomness = 0.3// how random - 0==no randomness, 1.0 = very random.
AmplitudeScale = 10// how far they move left to right.
AmplitudeRandomness = 0.4// how random - 0==no randomness, 1.0 = very random.
StillAmplitude = 0.10// // how much they move left to right when not moving. 0==none, 1.0==full movement.

// z movement.
FrequencyScaleZ = 0.2// // how fast they move up&down.
FrequencyRandomnessZ = 0.4// how random - 0==no randomness, 1.0 = very random.
AmplitudeScaleZ = 4// how far they up and down.
AmplitudeRandomnessZ = 0.2// how random - 0==no randomness, 1.0 = very random.
StillAmplitudeZ = 0.15// // how much they move up & down when not moving. 0==none, 1.0==full movement.

// Horde flowing up over large units it kills.
LargeUnitHeightFactor = 0.85 // Start with this * the object's geometry height.
LargeUnitMinHeight = 20.0// Go up at least this amount.
LargeUnitMaxHeight = 300.0// Go up at no more than amount.
LargeUnitTimeout = 12000// How long the horde flows up over the unit, ms.  4000==4 seconds.
LargeUnitTailOff = 2.0f// How quickly the units drop back to the ground.

// Oath fulfilled behavior.
//E3 No up OathFulfilledZFactor = 0.5 // How fast they rise up after oath is fulfilled.
ScatterSpeedFactor = 0.4// How fast they scatter.
ScatterRandomness = 0.1// How random the scatter speed is.

RankInfo = RankNumber:1 UnitType:RohanOathbreakersCavalryNew Position:X:50 Y:0 Position:X:50 Y:20 Position:X:50 Y:-20 Position:X:50 Y:40 Position:X:50 Y:-40
RankInfo = RankNumber:2 UnitType:RohanOathbreakersCavalryNew Position:X:30 Y:0 Leader 1 0 Position:X:30 Y:20 Leader 1 1 Position:X:30 Y:-20 Leader 1 2 Position:X:30 Y:40 Leader 1 3 Position:X:30 Y:-40 Leader 1 4
RankInfo = RankNumber:3 UnitType:RohanOathbreakersCavalryNew Position:X:10 Y:0 Leader 2 0 Position:X:10 Y:20 Leader 2 1 Position:X:10 Y:-20 Leader 2 2 Position:X:10 Y:40 Leader 2 3 Position:X:10 Y:-40 Leader 2 4

RanksToReleaseWhenAttacking = 1

End
End
AddModule
Behavior = PhysicsBehavior ModuleTag_PhysicsBehavior
GravityMult = 1.0
End
End
AddModule
Behavior = OathbreakersFadeAwayBehavior ModuleTag_05
FadeOutTime   = 9 // Hordes don't fade out, members do.
End
End
AddModule
  Behavior = CommandButtonHuntUpdate ModuleTag_CommandButtonHuntUpdate
  End
End
AddModule
Behavior = HordeNotifyTargetsOfImminentProbableCrushingUpdate ModuleTag_NotifyCrushScan
ScanWidth = 30.0 ; A little less than the width of the horde (which is 2 * 20 = 40)
End
End

LocomotorSet
Locomotor = HorseLocomotor
Condition = SET_NORMAL
Speed     = 100

End

Geometry = BOX
GeometryMajorRadius = 20.0
GeometryMinorRadius = 20.0
GeometryHeight = 10.0
GeometryIsSmall = No
End




Vielen Dank im Voraus!

MFG
Tipppfehler

Tipppfehler

  • Gastwirt zu Bree
  • **
  • Beiträge: 133
Re: Formation-Code?¿
« Antwort #1 am: 4. Mai 2009, 23:08 »
Ich möchte ja niemanden stressen oder so, aber ich fände es echt toll wenn sich jemand meiner anehmen würde!

Wenn mein Problem nicht klar genug ist dann frag doch bitte einfach nochmal nach!

MFG
Tipppfehler


Rimli

  • Galadhrim
  • **
  • Beiträge: 716
Re: Formation-Code?¿
« Antwort #2 am: 10. Mai 2009, 22:54 »
Hallo!

Mit dem angreifen:

Du hast ein paar Fehler in der Horde, änder mal so ab:
ObjectStatusOfContained =
InitialPayload = RohanOathbreakersCavalryNew 15 ;OATHBREAKER_HORDE_SIZE
Slots = 15   ;3
PassengerFilter = ANY +INFANTRY +CAVALRY
ShowPips = No
ThisFormationIsTheMainFormation = Yes //Used to determine which armorset to use (and anything else we want!)
RandomOffset = X:0 Y:0 // X:25 Y:25
Bei InitialPayload und Slots muss immer die Anzahl stehen, für die du auch Koordinaten vergibst. Wenn es dann immer noch nicht geht, kann ich dir nur den Tipp geben, die Geometries zu überprüfen (kenn mich da selber nicht so aus) und den Weapon-Range testweise zu erhöhen.

Wegen der Lifetime: In der Horde die Lifetime dient nur zur Visualisierung. Du musst auch eine Lifetime in die Ini der Unit machen, sonst sterben deine Untoten nicht.
« Letzte Änderung: 10. Mai 2009, 23:02 von Rimli »