Quantcast
Channel: OpenRA
Viewing all articles
Browse latest Browse all 147

Mapping and Modding • Dune2k Aircraft Modding

$
0
0
Hi. I have been modifying some d2k files and have added a selectable ornithopter bomber that drops two bombs and lands and reloads back to the silo buildings (the spice silos). It works fine (reloads & repairs) but when I have more than one bomber they don't land correctly.

I describe the problem:

-I build two silos, then one bomber.

-Select the bomber and right click on silo 1
-The bomber lands on silo 1 and stays there.

-I select the bomber and right click on silo 2
-The bomber moves and lands on silo 2.

-I build a 2nd bomber and order it to land in the free silo (the 1st)
-The 2nd bomber tries to land (lines up) but keeps circling around the silo repeatedly trying to land without success.

I think the silo keeps a reference to the first bomber so it is blocked for other bombers. I cant asign other bombers unless the 1st is destroyed
What am I doing wrong, is there a trait missing in the silo or in the bomber?
There is some way to unassign the bomber to the previous pad if is assigned or ordered to land in another? Or unassign the bomber when it takeoff?

This is the silo/landing pad code:

CODE:

silo:Inherits: ^BuildingBuildable:Prerequisites: refineryQueue: BuildingBuildPaletteOrder: 130BuildDuration: 375BuildDurationModifier: 100Description: Repairs air units & stores excess harvested SpiceSelectable:Bounds: 32,32Valued:Cost: 250Tooltip:Name: Pad-SiloRequiresBuildableArea:Adjacent: 4-GivesBuildableArea:Health:HP: 80000Armor:Type: buildingRevealsShroud:Range: 2c768RenderSprites:Image: silo.ordosFactionImages:atreides: silo.atreidesfremen: silo.atreidesharkonnen: silo.harkonnencorrino: silo.harkonnen-WithSpriteBody:WithResourceLevelSpriteBody:Sequence: stagesStoresResources:Capacity: 2000-SpawnActorsOnSell:Power:Amount: -10Reservable:RepairsUnits:Interval: 125HpPerStep: 1000StartRepairingNotification: RepairingFinishRepairingNotification: UnitRepairedPlayerExperience: 5MustBeDestroyed:RequiredForShortGame: falseThrowsShrapnel:Weapons: Debris, Debris2, Debris3, Debris4Pieces: 3, 5Range: 2c0, 5c0RevealOnDeath:Radius: 2c768WithResourceStoragePipsDecoration:Position: BottomLeftMargin: 1, 4RequiresSelection: truePipCount: 5
This is the default plane code:

CODE:

^Plane:Inherits@1: ^ExistsInWorldInherits@2: ^SpriteActorInherits@handicaps: ^PlayerHandicapsInteractable:Tooltip:GenericName: UnitHuntable:OwnerLostAction:Action: KillAppearsOnRadar:UseLocation: trueHiddenUnderFog:Type: GroundPositionAlwaysVisibleRelationships: NoneActorLostNotification:AttackMove:WithFacingSpriteBody:WithShadow:HitShape:Type: CircleRadius: 16MapEditorData:Categories: Aircraft
This is the ornithopter base code where the bomber inherits some traits:

CODE:

^orni_controlable:Inherits: ^PlaneInherits@GAINSEXPERIENCE: ^GainsExperienceInherits@AUTOTARGET: ^AutoTargetAllAssaultMove-Interactable:Inherits@selection: ^SelectableCombatUnitSelectable:Class: ornithopterBounds: 32,32Buildable:Queue: AircraftBuildDuration: 750Health:HP: 10000Armor:Type: lightAircraft:Repulsable: trueCruiseAltitude: 1600VTOL: trueTakeOffOnResupply: falseTurnToLand: falseLandAltitude: 150IdleTurnSpeed: 10UpdatesPlayerStatistics:AddToArmyValue: trueTargetable:TargetTypes: Ground, Vehicle, Infantry, Air, DefenseHiddenUnderFog:AlwaysVisibleRelationships: AllyRevealsShroud:ValidRelationships: AllyType: GroundPositionRevealGeneratedShroud: trueRange: 8c768RevealOnFire:SpawnActorOnDeath:Actor: ornithopter.huskRenderSprites:Image: ornithopter
This is the bomber code:

CODE:

ornithopter_light_bomber:Inherits: ^orni_controlableBuildable:BuildPaletteOrder: 160Description: Light Bomber Ornithopter\n Bombs Bays InstalledPrerequisites: research_centre, ~techlevel.mediumTooltip:Name: Ornithopter Light BomberValued:Cost: 400AttackAircraft:FacingTolerance: 80PersistentTargeting: falseOpportunityFire: FalseAircraft:Speed: 140TurnSpeed: 16IdleBehavior: ReturnToBaseCanForceLand: falseArmament:Weapon: OrniBombLocalOffset: -128,128,171, -128,-128,171PauseOnCondition: !ammoAutoTarget:InitialStanceAI: HoldFireAmmoPool:Ammo: 2ReloadDelay: 100AmmoCondition: ammoRearmable:RearmActors: siloRepairable:RepairActors: siloWithAmmoPipsDecoration:Position: BottomLeftMargin: 4, 3RequiresSelection: truePipCount: 2

Statistics: Posted by diegonv40 — Thu Apr 18, 2024 6:33 pm — Replies 0 — Views 11



Viewing all articles
Browse latest Browse all 147

Trending Articles