Merge pull request #7664 from penev92/bleed_harvesterInsurance

Implement Carryall edge spawn, harvester delivery by carryall and harvester insurance for D2k
This commit is contained in:
Oliver Brakmann
2015-03-25 20:03:00 +01:00
17 changed files with 615 additions and 296 deletions

View File

@@ -111,7 +111,6 @@ Actors:
AtreidesSpiceRefinery: refinery
Location: 57,58
Owner: Atreides
FreeActor: false
Smudges:
@@ -127,14 +126,6 @@ Rules:
Maximum: 1
LuaScript:
Scripts: shellmap.lua
carryall.scripted:
Helicopter:
LandWhenIdle: True
Cargo:
Types: Vehicle
WithCargo:
DisplayTypes: Vehicle
LocalOffset: 0,0,-256
rockettower:
Power:
Amount: 100

View File

@@ -1,20 +1,3 @@
InitializeHarvester = function(harvester)
harvester.FindResources()
Trigger.OnRemovedFromWorld(harvester, InsertHarvester)
end
InsertHarvester = function()
local harvesters = Reinforcements.ReinforceWithTransport(atreides, "carryall.scripted", { "harvester" },
{ Entry.Location, AtreidesSpiceRefinery.Location + CVec.New(2, 3) }, { Entry.Location })[2]
Utils.Do(harvesters, function(harvester)
Trigger.OnAddedToWorld(harvester, function() InitializeHarvester(harvester) end)
end)
end
WorldLoaded = function()
atreides = Player.GetPlayer("Atreides")
InsertHarvester()
Media.PlayMusic("score")
end
end

View File

@@ -1,4 +1,4 @@
carryall.scripted:
carryall.reinforce:
Inherits: ^Helicopter
Valued:
Cost: 1200
@@ -10,7 +10,7 @@ carryall.scripted:
Armor:
Type: Light
Helicopter:
CruiseAltitude: 2048
CruiseAltitude: 2100
InitialFacing: 0
ROT: 4
Speed: 160
@@ -18,7 +18,7 @@ carryall.scripted:
RepairBuildings: repair
RearmBuildings:
Repulsable: False
LandAltitude: 512
LandAltitude: 100
LandWhenIdle: False
RenderUnit:
Image: carryall
@@ -26,16 +26,17 @@ carryall.scripted:
LeavesHusk:
HuskActor: carryall.husk
-Selectable:
-TargetableAircraft:
Carryall:
Automatic: False
carryall:
Inherits: carryall.scripted
AutoCarryall:
Inherits: carryall.reinforce
Carryall:
Automatic: True
Buildable:
Queue: Aircraft
BuildPaletteOrder: 120
Helicopter:
CruiseAltitude: 2100
LandAltitude: 100
carryall.infantry:
Inherits: ^Plane
@@ -61,6 +62,7 @@ carryall.infantry:
MaxWeight: 5
Types: Infantry
-Selectable:
-TargetableAircraft:
-GainsExperience:
Tooltip:
Name: Carryall

View File

@@ -73,3 +73,4 @@ Player:
Name: Unrestricted
Prerequisites: techlevel.low, techlevel.medium, techlevel.high, techlevel.superweapons
EnemyWatcher:
HarvesterInsurance:

View File

@@ -194,10 +194,11 @@ refinery:
Capacity: 2000
CustomSellValue:
Value: 500
FreeActor:
FreeActorWithDelivery:
Actor: harvester
InitialActivity: FindResources
SpawnOffset: 2,1
DeliveryOffset: 2,2
DeliveringActor: carryall.reinforce
Facing: 160
-RenderBuilding:
RenderBuildingWarFactory:
@@ -668,7 +669,7 @@ hightech:
Tooltip:
Name: High Tech Facility
Description: Unlocks advanced technology
Production:
ProductionFromMapEdge:
Produces: Aircraft
Exit:
SpawnOffset: 0,0,728