forked from Mirrors/openclonk
FightForGidl: Added chippies.
parent
20c226dc18
commit
fe958f6d4e
|
@ -63,7 +63,7 @@ private func ExecuteBomber(fx)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// Not in range. Walk there.
|
// Not in range. Walk there.
|
||||||
if (!GetCommand() || !Random(3)) SetCommand("MoveTo", fx.target);
|
if (!GetCommand() || !Random(10)) SetCommand("MoveTo", fx.target);
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -102,7 +102,7 @@ private func ExecuteClub(fx)
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
// Not in range. Walk there.
|
// Not in range. Walk there.
|
||||||
if (!GetCommand() || !Random(3)) SetCommand("MoveTo", fx.target);
|
if (!GetCommand() || !Random(10)) SetCommand("MoveTo", fx.target);
|
||||||
//Message("Melee %s @ %s!!!", fx.weapon->GetName(), fx.target->GetName());
|
//Message("Melee %s @ %s!!!", fx.weapon->GetName(), fx.target->GetName());
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -137,6 +137,12 @@ func Execute(proplist fx, int time)
|
||||||
return inherited(fx, time, ...);
|
return inherited(fx, time, ...);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func ExecuteIdle(proplist fx)
|
||||||
|
{
|
||||||
|
// Idle execution overridden by Execute
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
//======================================================================
|
//======================================================================
|
||||||
/* Enemy creation */
|
/* Enemy creation */
|
||||||
|
@ -169,7 +175,7 @@ func Inventory_GetCarryTransform()
|
||||||
func LaunchEnemy(proplist enemy, int x, int y)
|
func LaunchEnemy(proplist enemy, int x, int y)
|
||||||
{
|
{
|
||||||
// Create enemy (usually a Clonk)
|
// Create enemy (usually a Clonk)
|
||||||
var obj = CreateObjectAbove(enemy.Type ?? Clonk, x,y), clonk;
|
var obj = CreateObjectAbove(enemy.Type ?? Clonk, x,y, ENEMY), clonk;
|
||||||
// Enemy visuals
|
// Enemy visuals
|
||||||
if (enemy.Skin)
|
if (enemy.Skin)
|
||||||
{
|
{
|
||||||
|
@ -259,4 +265,3 @@ global func ForceVal2Array(v) { if (GetType(v) != C4V_Array) return [v]; else r
|
||||||
// forward max contents count to property
|
// forward max contents count to property
|
||||||
func Clonk_MaxContentsCount() { return this.MaxContentsCountVal; }
|
func Clonk_MaxContentsCount() { return this.MaxContentsCountVal; }
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,15 @@
|
||||||
|
[PlayerInfoList]
|
||||||
|
LastPlayerID=1
|
||||||
|
|
||||||
|
[Client]
|
||||||
|
ID=0
|
||||||
|
Flags=Initial
|
||||||
|
|
||||||
|
[Player]
|
||||||
|
Name="$TeamAttackers$"
|
||||||
|
Type=Script
|
||||||
|
Flags=Joined|AttributesFixed|NoScenarioInit|NoEliminationCheck
|
||||||
|
ID=1
|
||||||
|
Color=4294901760
|
||||||
|
Team=2
|
||||||
|
GameNumber=10
|
|
@ -11,6 +11,7 @@ static g_spawned_enemies;
|
||||||
static g_relaunchs; // array of relaunch counts
|
static g_relaunchs; // array of relaunch counts
|
||||||
static g_scores; // array of player scores
|
static g_scores; // array of player scores
|
||||||
static g_ai; // derived from S2AI; contains changes for this scenario
|
static g_ai; // derived from S2AI; contains changes for this scenario
|
||||||
|
static const ENEMY = 10; // player number of enemy
|
||||||
|
|
||||||
static const MAX_RELAUNCH = 10;
|
static const MAX_RELAUNCH = 10;
|
||||||
|
|
||||||
|
@ -25,6 +26,7 @@ func Initialize()
|
||||||
|
|
||||||
func InitializePlayer(int plr, int iX, int iY, object pBase, int iTeam)
|
func InitializePlayer(int plr, int iX, int iY, object pBase, int iTeam)
|
||||||
{
|
{
|
||||||
|
if (GetPlayerType(plr) != C4PT_User) return;
|
||||||
if (!g_statue) { EliminatePlayer(plr); return; } // no post-elimination join
|
if (!g_statue) { EliminatePlayer(plr); return; } // no post-elimination join
|
||||||
if (!g_relaunchs)
|
if (!g_relaunchs)
|
||||||
{
|
{
|
||||||
|
@ -54,6 +56,8 @@ func RemovePlayer(int plr)
|
||||||
|
|
||||||
func RelaunchPlayer(int plr)
|
func RelaunchPlayer(int plr)
|
||||||
{
|
{
|
||||||
|
// Not for AI attackers
|
||||||
|
if (GetPlayerType(plr) != C4PT_User) return;
|
||||||
// Relaunch count
|
// Relaunch count
|
||||||
if (!g_relaunchs[plr])
|
if (!g_relaunchs[plr])
|
||||||
{
|
{
|
||||||
|
@ -310,12 +314,13 @@ func InitWaveData()
|
||||||
var ogre = { Name="$EnemyOgre$", Inventory=bigclub, Energy= 90, Bounty=100, Color=0xff00ffff, Skin=CSKIN_Ogre, Backpack=0, Scale=[1400,1200,1200], Speed=50 };
|
var ogre = { Name="$EnemyOgre$", Inventory=bigclub, Energy= 90, Bounty=100, Color=0xff00ffff, Skin=CSKIN_Ogre, Backpack=0, Scale=[1400,1200,1200], Speed=50 };
|
||||||
var swordogre = { Name="$EnemyOgre$", Inventory=ogresword, Energy= 90, Bounty=100, Color=0xff805000, Skin=CSKIN_Ogre, Backpack=0, Scale=[1400,1200,1200], Speed=50 };
|
var swordogre = { Name="$EnemyOgre$", Inventory=ogresword, Energy= 90, Bounty=100, Color=0xff805000, Skin=CSKIN_Ogre, Backpack=0, Scale=[1400,1200,1200], Speed=50 };
|
||||||
var nukeogre = { Name="$EnemyOgre$", Inventory=nukekeg, Energy=120, Bounty=100, Color=0xffff0000, Skin=CSKIN_Ogre, Backpack=0, Scale=[1400,1200,1200], Speed=40, Siege=true };
|
var nukeogre = { Name="$EnemyOgre$", Inventory=nukekeg, Energy=120, Bounty=100, Color=0xffff0000, Skin=CSKIN_Ogre, Backpack=0, Scale=[1400,1200,1200], Speed=40, Siege=true };
|
||||||
|
var chippie = { Type=Chippie };
|
||||||
//newbie = runner;
|
//newbie = runner;
|
||||||
//newbie = runner;
|
//newbie = runner;
|
||||||
|
|
||||||
// Define composition of waves
|
// Define composition of waves
|
||||||
ENEMY_WAVE_DATA = [nil,
|
ENEMY_WAVE_DATA = [nil,
|
||||||
{ Name = "$WaveNewbies$", Enemies = [
|
{ Name = "$WaveNewbies$", Enemies = [
|
||||||
new newbie { Num= 1, Interval=10, Side = WAVE_SIDE_LEFT }
|
new newbie { Num= 1, Interval=10, Side = WAVE_SIDE_LEFT }
|
||||||
]}, { Name = "$WaveBows$", Enemies = [
|
]}, { Name = "$WaveBows$", Enemies = [
|
||||||
new newbie { Num= 2, Interval=10 },
|
new newbie { Num= 2, Interval=10 },
|
||||||
|
@ -343,6 +348,10 @@ func InitWaveData()
|
||||||
new flintstone { Num=20, Interval=15 },
|
new flintstone { Num=20, Interval=15 },
|
||||||
new nukeogre { Num= 2, Interval=99 },
|
new nukeogre { Num= 2, Interval=99 },
|
||||||
new amazon { Delay= 50, Num= 6, Interval=10 }
|
new amazon { Delay= 50, Num= 6, Interval=10 }
|
||||||
|
]}, { Name = "Alien invasion", Enemies = [
|
||||||
|
new bowman { Delay=260, Num= 3, Interval= 5 },
|
||||||
|
new chippie { Num=10, Interval=10 },
|
||||||
|
new amazon { Delay=250, Num= 6, Interval=10 }
|
||||||
]}, { Name = "Two of each kind", Enemies = [
|
]}, { Name = "Two of each kind", Enemies = [
|
||||||
new newbie { Delay= 0 },
|
new newbie { Delay= 0 },
|
||||||
new ogre { Delay= 0 },
|
new ogre { Delay= 0 },
|
||||||
|
|
|
@ -16,3 +16,6 @@ EnemyRunner=Bekloppter
|
||||||
|
|
||||||
WaveNewbies=Nur zum Aufwärmen
|
WaveNewbies=Nur zum Aufwärmen
|
||||||
WaveBows=Fernkampfalarm!
|
WaveBows=Fernkampfalarm!
|
||||||
|
|
||||||
|
TeamAttackers=Angreifer
|
||||||
|
TeamDefenders=Verteidiger
|
||||||
|
|
|
@ -16,3 +16,6 @@ EnemyRunner=Crazy
|
||||||
|
|
||||||
WaveNewbies=Just warming up...
|
WaveNewbies=Just warming up...
|
||||||
WaveBows=Bowmen alarm!
|
WaveBows=Bowmen alarm!
|
||||||
|
|
||||||
|
TeamAttackers=Attackers
|
||||||
|
TeamDefenders=Defenders
|
||||||
|
|
|
@ -1,2 +1,11 @@
|
||||||
[Teams]
|
[Teams]
|
||||||
Active=false
|
TeamColors=false
|
||||||
|
|
||||||
|
[Team]
|
||||||
|
id=1
|
||||||
|
Name=$TeamDefenders$
|
||||||
|
|
||||||
|
[Team]
|
||||||
|
id=2
|
||||||
|
Name=$TeamAttackers$
|
||||||
|
MaxPlayer=1
|
||||||
|
|
Loading…
Reference in New Issue