If you're just adding a shipped(unmodified) side to your map then you only need to add some lines of code to your LUA.
Have a look at end1g_con.lua to get the code you need to make your ewoks a local team.
Add this to the ReadDataFile section:
Code: Select all
ReadDataFile("SIDE\\ewk.lvl",
"ewk_inf_basic")
Also add this further down, this sets up the ewok team:
Code: Select all
---[[ Ewoks
SetTeamName(3, "locals")
AddUnitClass(3, "ewk_inf_trooper", 3)
AddUnitClass(3, "ewk_inf_repair", 3)
SetUnitCount(3, 6)
SetTeamAsFriend(3,ATT)
SetTeamAsEnemy(3,DEF)
SetTeamAsFriend(ATT, 3)
SetTeamAsEnemy(DEF, 3)
--]]
They need an AI goal too, so you'll need to add this:
If you don't want to add ewoks as locals but playables then just load them in the ReadDataFile section and then add the class names where you want them in the main SetupTeams section.
The class names are:
and you'll add them for example like this to replace a class:
Code: Select all
SetupTeams{
all = {
team = ALL,
units = 29,
reinforcements = 150,
soldier = { "ewk_inf_trooper",10, 25},
assault = { "all_inf_rocketeer_jungle",1,4},
engineer = { "ewk_inf_repair",1,4},
sniper = { "all_inf_sniper_jungle",1,4},
officer = {"all_inf_officer_jungle",1,4},
special = { "all_inf_wookiee",1,4},
},
imp = {
team = IMP,
units = 29,
reinforcements = 150,
soldier = { "imp_inf_rifleman",10, 25},
assault = { "imp_inf_rocketeer",1,4},
engineer = { "imp_inf_engineer",1,4},
sniper = { "imp_inf_sniper",1,4},
officer = {"imp_inf_officer",1,4},
special = { "imp_inf_dark_trooper",1,4},
}
}
or you can use the AddUnitClass code to add new units to the existing team setup without replacing units like this for example:
Code: Select all
AddUnitClass(ALL, "ewk_inf_trooper", 1,10),
AddUnitClass(ALL, "ewk_inf_repair", 1,10),
You can also create your own class types in the setup_teams.lua.
Have a look at end1g_con.lua along with the other shipped scripts and you'll get an idea of where certain stuff goes and what you'll need.