Page 1 of 1

ambush troubles and tips and tricks questions

Posted: Sun Nov 15, 2009 7:44 pm
by YaNkFaN
I'm having trouble getting both ambushers to spawn in a map

i keep getting this error

Message Severity: 2
.\Source\Character.cpp(1217)
Trying to spawn a character with no class. Skipping this character. Perhaps the UnitClassCounts are too low?
WARNING: could not spawn all the ambushers...team is too small or there are too many dudes running around alive

here is the relevant parts of my script
Hidden/Spoiler:
[code]--Objective 1--
--OBJECTIVE 1 TDM - Kill all the Sith.

Objective1 = Objective:New{teamATT = ATT, teamDEF = DEF, text ="level.IC1.obj.1", popupText = "level.IC1.obj.pop.1"}

Objective1.OnStart = function (self)
objectiveSequence.delayNextSetTime = 0.5


ATTKillAllJedi = AddAIGoal (ATT, "deathmatch",100)
DEFKillAllJedi = AddAIGoal (DEF, "deathmatch",100)

BossGoal = AddAIGoal(STH, "Deathmatch", 100)


Ambush("darkjedispawn", 2, STH)
MapAddClassMarker("kor_inf_darkjedi", "hud_objective_icon_circle", 3.5, ATT, "YELLOW", true)

boss_count = 2
Objective1KillSith = OnObjectKillTeam(
function(object, killer)
if boss_count > 0 then
boss_count = boss_count - 1
end
if boss_count == 1 then
ShowMessageText ("level.IC1.obj.count.1", ATT)
elseif boss_count == 0 then
ShowMessageText ("level.IC1.obj1.count.0", ATT)
Objective1:Complete(ATT)
ReleaseObjectKill(Objective1KillSith)
end
end,
STH
)
end

Objective1.OnComplete = function(self)
DeleteAIGoal(ATTKillAllJedi)
DeleteAIGoal(DEFKillAllJedi)
DeleteAIGoal(BossGoal)
ShowMessageText("game.objectives.complete", ATT)
if self.winningTeam == DEF then
ScriptCB_SndPlaySound("MYG_obj_15")
else
ScriptCB_SndPlaySound("MYG_obj_03")
end
ATT_ReinforcementCount = GetReinforcementCount(ATT)
SetReinforcementCount(ATT, ATT_ReinforcementCount + 10)
end

--End Objective1--[/code]
and
Hidden/Spoiler:
[code]sth = {
team = STH,
units = 2,
reinforcements = -1,
soldier = {"kor_inf_darkjedi", 2, 2},

},

}

--ambush again team alliances
SetTeamName(STH, CIS)
SetTeamAsFriend(STH, CIS)
SetTeamAsEnemy(STH, REP)
SetTeamAsFriend(CIS, STH)
SetTeamAsEnemy(REP, STH)
ClearAIGoals(STH)[/code]
I have 2 nodes in the specific layer in ZE in a path named darkjedispawn (only one dude spawns)
also is it possible for tips and tricks to be removed from the load screen?