Fix broken scripted attacks in some missions

In all three cases, the failure came down to the targets not being declared as enemies to the attackers.

Recent changes to the attack code made it impossible to attack friendly or neutral things with the Lua API's Attack() method. Changing the allegiance of affected parties fixed it, or, in the case of Soviet 02a, using force-attack.
This commit is contained in:
Oliver Brakmann
2015-10-24 00:30:15 +02:00
parent 6420a6ec8a
commit 42d2e016ed
3 changed files with 4 additions and 4 deletions

View File

@@ -91,9 +91,9 @@ WorldLoaded = function()
-- Don't "shoot" at the barrels if there is noone to shoot -- Don't "shoot" at the barrels if there is noone to shoot
if not FleeingUnits[1].IsDead then if not FleeingUnits[1].IsDead then
FleeingUnits[1].Attack(Barrel) FleeingUnits[1].Attack(Barrel, true, true)
elseif not FleeingUnits[2].IsDead then elseif not FleeingUnits[2].IsDead then
FleeingUnits[2].Attack(Barrel) FleeingUnits[2].Attack(Barrel, true, true)
end end
end end
end) end)

View File

@@ -60,7 +60,7 @@ Players:
Faction: allies Faction: allies
ColorRamp: 161,134,236 ColorRamp: 161,134,236
Allies: England, Soviet Allies: England, Soviet
Enemies: USSR Enemies: USSR, Creeps
PlayerReference@USSR: PlayerReference@USSR:
Name: USSR Name: USSR
AllowBots: False AllowBots: False

View File

@@ -50,7 +50,7 @@ Players:
Faction: allies Faction: allies
ColorRamp: 161,134,236 ColorRamp: 161,134,236
Allies: Soviet Allies: Soviet
Enemies: USSR Enemies: USSR, Creeps
PlayerReference@USSR: PlayerReference@USSR:
Name: USSR Name: USSR
AllowBots: False AllowBots: False