Page 1 of 1

Combo Memory Utapau - No Damage [Solved]

Posted: Fri Jul 23, 2010 9:15 pm
by kinetosimpetus
Stock Utapau map, custom sides/script.

Only 1 of the 4 (used to be 5, no difference in the problem) melee units can do damage.

I did remember to copy combo memory pools to increase memory, without this, it would crash, or glitch in other ways, so the lua partially works, but it isn't loading memory for Combo::DamageSample. I also seem to have a small combo problem, but it should be unrelated and doesn't crash.
Hidden/Spoiler:
[code]
Message Severity: 2
.\Source\SoldierAnimationData.cpp(249)
SoldierAnimationData[7cc19223]::Animation[stand_attacklightb]::BlendTimeTo: unknown anim 'stand_attack1b_end_upper' [79fbec9e]

Message Severity: 2
.\Source\SoldierAnimationData.cpp(249)
SoldierAnimationData[7cc19223]::Animation[stand_attacklightb]::BlendTimeTo: unknown anim 'stand_attack1c_upper' [c877aedf]


...


Message Severity: 2
.\Source\Combo.cpp(1662)
Combo::Attack: failed to add Combo::DamageSample (1335 needed)
[/code]
The last one shows up a whole lot, most of the log. It counts up by ones.

The lua.
Hidden/Spoiler:
[code]--
-- Copyright (c) 2005 Pandemic Studios, LLC. All rights reserved.
--
ScriptCB_DoFile("setup_teams")
-- load the gametype script
ScriptCB_DoFile("ObjectiveConquest")

local CIS = 2
local REP = 1
-- These variables do not change
local ATT = 1
local DEF = 2
----------------------------------------------------------------------
-- FUNCTION: ScriptInit
-- PURPOSE: This function is only run once
-- INPUT:
-- OUTPUT:
-- NOTES: The name, 'ScriptInit' is a chosen convention, and each
-- mission script must contain a version of this function, as
-- it is called from C to start the mission.
---------------------------------------------------------------------------
function ScriptPostLoad()

-- EnableSPHeroRules()

--CP SETUP for CONQUEST

cp1 = CommandPost:New{name = "CON_CP1"}
cp2 = CommandPost:New{name = "con_CP1a"}
cp3 = CommandPost:New{name = "CON_CP2"}
cp4 = CommandPost:New{name = "CON_CP5"}
cp5 = CommandPost:New{name = "CON_CP6"}
cp6 = CommandPost:New{name = "CON_CP7"}

conquest = ObjectiveConquest:New{teamATT = ATT, teamDEF = DEF, textATT = "game.modes.con", textDEF = "game.modes.con2", multiplayerRules = true}

conquest:AddCommandPost(cp1)
conquest:AddCommandPost(cp2)
conquest:AddCommandPost(cp3)
conquest:AddCommandPost(cp4)
conquest:AddCommandPost(cp5)
conquest:AddCommandPost(cp6)

conquest:Start()
DisableBarriers("Barrier445");
end
function ScriptInit()

-- Designers, these two lines *MUST* be first!
StealArtistHeap(1228*1024)
SetPS2ModelMemory(4380000)
ReadDataFile("dc:SIDE\\effects153effects.lvl")
ReadDataFile("ingame.lvl")


SetMemoryPoolSize ("ClothData",20)

SetMemoryPoolSize ("SoldierAnimation",1000)

SetMemoryPoolSize ("ParticleTransformer::ColorTrans",2000)

SetMemoryPoolSize ("ParticleTransformer::SizeTransf",2000)

SetMemoryPoolSize ("ParticleTransformer::PositionTr",2000)


SetMemoryPoolSize ("ClothData",20)
SetMemoryPoolSize ("Combo",50) -- should be ~ 2x number of jedi classes
SetMemoryPoolSize ("Combo::State",700) -- should be ~12x #Combo
SetMemoryPoolSize ("Combo::Transition",700) -- should be a bit bigger than #Combo::State
SetMemoryPoolSize ("Combo::Condition",700) -- should be a bit bigger than #Combo::State
SetMemoryPoolSize ("Combo::Attack",700) -- should be ~8-12x #Combo
SetMemoryPoolSize ("Combo::DamageSample",7000) -- should be ~8-12x #Combo::Attack
SetMemoryPoolSize ("Combo::Deflect",100) -- should be ~1x #combo



SetTeamAggressiveness(REP, 0.95)
SetTeamAggressiveness(CIS, 0.95)

ReadDataFile("sound\\uta.lvl;uta1cw")
ReadDataFile("dc:sound\\153.lvl;153cw")


ReadDataFile("dc:SIDE\\tjo.lvl",
"tjo_inf_qeldroma")

ReadDataFile("dc:SIDE\\bx.lvl",
"bx_inf_rifleman")

ReadDataFile("dc:SIDE\\rep.lvl",
"rep_inf_ep2_rifleman",
"rep_inf_ep2_engineer",
"rep_inf_ep2_sniper",
"rep_inf_ep2_rocketeer",
"rep_inf_ep2_officer",
"rep_inf_ep2_recon",
"rep_inf_ep2_jettrooper",
"rep_hero_obiwan",
"rep_walk_oneman_atst")

ReadDataFile("dc:SIDE\\cis.lvl",
"cis_inf_rifleman",
"cis_inf_rocketeer",
"cis_inf_pilot",
"cis_inf_sniper",
"cis_inf_marine",
"cis_hero_grievous",
"cis_inf_rocket_droid",
"cis_inf_recon",
"cis_inf_officer_hunt",
"cis_hover_aat")

ReadDataFile("dc:SIDE\\delta.lvl",
"delta_88_scorch")


ReadDataFile("dc:SIDE\\tur.lvl",
"tur_bldg_laser",
"tur_bldg_tower")
--SetUberMode(1)

SetupTeams{
rep = {
team = REP,
units = 100,
reinforcements = 200, --200,
soldier = { "rep_inf_ep2_rifleman",25, 50},
assault = { "rep_inf_ep2_sniper",5, 10},
engineer = { "rep_inf_ep2_engineer",5, 10},
sniper = { "rep_inf_ep2_rocketeer",5, 10},
officer = {"rep_inf_ep2_recon",5, 10},
special = { "rep_inf_ep2_officer",5, 10},

},
cis = {
team = CIS,
units = 100,
reinforcements = 200, --300,
soldier = { "cis_inf_rifleman",50, 100},
assault = { "cis_inf_rocketeer",5, 10},
engineer = { "cis_inf_pilot",5, 10},
sniper = { "cis_inf_sniper",5, 10},
officer = {"cis_inf_recon",5, 10},
special = { "cis_inf_marine",5, 10},
}
}

-- SetHeroClass(CIS, "")
-- SetHeroClass(REP, "")

--Map Specific units here now.

--Special

AddUnitClass(CIS,"cis_inf_rocket_droid",1,10) --12
AddUnitClass(REP,"rep_inf_ep2_jettrooper",1,10) --12

--Commando

AddUnitClass(CIS,"bx_inf_rifleman",1,5) --16
AddUnitClass(REP,"delta_88_scorch",1,1) --16

--Minor Hero

AddUnitClass(CIS,"cis_inf_officer_hunt",1,5) --20
AddUnitClass(REP,"tjo_inf_qeldroma",1,1) --20

--Hero

AddUnitClass(CIS,"cis_hero_grievous",1,1) --24
AddUnitClass(REP,"rep_hero_obiwan",1,1) --24

-- Level Stats
ClearWalkers()
AddWalkerType(0, 2) -- droidekas
AddWalkerType(1, 5) -- ATRTa (special case: 0 leg pairs)
local weaponCnt = 220
SetMemoryPoolSize("Aimer", 36)
SetMemoryPoolSize("AmmoCounter", weaponCnt)
SetMemoryPoolSize("BaseHint", 200)
SetMemoryPoolSize("Combo::DamageSample", 610)
SetMemoryPoolSize("EnergyBar", weaponCnt)
SetMemoryPoolSize("EntityHover",6)
SetMemoryPoolSize("EntityLight", 60)
SetMemoryPoolSize("EntityFlyer", 8)
SetMemoryPoolSize("EntitySoundStream", 8)
SetMemoryPoolSize("EntitySoundStatic", 27)
SetMemoryPoolSize("MountedTurret", 2)
SetMemoryPoolSize("Navigator", 40)
SetMemoryPoolSize("Obstacle", 400)
SetMemoryPoolSize("PathFollower", 40)
SetMemoryPoolSize("PathNode", 150)
SetMemoryPoolSize("TentacleSimulator", 0)
SetMemoryPoolSize("TreeGridStack", 225)
SetMemoryPoolSize("UnitAgent", 40)
SetMemoryPoolSize("UnitController", 40)
SetMemoryPoolSize("Weapon", weaponCnt)

SetSpawnDelay(10.0, 0.25)
ReadDataFile("uta\\uta1.lvl", "uta1_Conquest")
AddDeathRegion("deathregion")
SetDenseEnvironment("false")
SetMaxFlyHeight(29.5)
SetMaxPlayerFlyHeight(29.5)


-- Sound Stats

voiceSlow = OpenAudioStream("sound\\global.lvl", "rep_unit_vo_slow")
AudioStreamAppendSegments("sound\\global.lvl", "cis_unit_vo_slow", voiceSlow)
AudioStreamAppendSegments("sound\\global.lvl", "global_vo_slow", voiceSlow)

voiceQuick = OpenAudioStream("sound\\global.lvl", "rep_unit_vo_quick")
AudioStreamAppendSegments("sound\\global.lvl", "cis_unit_vo_quick", voiceQuick)

OpenAudioStream("sound\\global.lvl", "cw_music")
OpenAudioStream("sound\\uta.lvl", "uta1")
OpenAudioStream("sound\\uta.lvl", "uta1")
-- OpenAudioStream("sound\\global.lvl", "global_vo_quick")
-- OpenAudioStream("sound\\global.lvl", "global_vo_slow")
-- OpenAudioStream("sound\\uta.lvl", "uta1_emt")

SetBleedingVoiceOver(REP, REP, "rep_off_com_report_us_overwhelmed", 1)
SetBleedingVoiceOver(REP, CIS, "rep_off_com_report_enemy_losing", 1)
SetBleedingVoiceOver(CIS, REP, "cis_off_com_report_enemy_losing", 1)
SetBleedingVoiceOver(CIS, CIS, "cis_off_com_report_us_overwhelmed", 1)

SetLowReinforcementsVoiceOver(REP, REP, "rep_off_defeat_im", .1, 1)
SetLowReinforcementsVoiceOver(REP, CIS, "rep_off_victory_im", .1, 1)
SetLowReinforcementsVoiceOver(CIS, CIS, "cis_off_defeat_im", .1, 1)
SetLowReinforcementsVoiceOver(CIS, REP, "cis_off_victory_im", .1, 1)

SetOutOfBoundsVoiceOver(2, "Repleaving")
SetOutOfBoundsVoiceOver(1, "Cisleaving")

SetAmbientMusic(REP, 1.0, "rep_uta_amb_start", 0,1)
SetAmbientMusic(REP, 0.8, "rep_uta_amb_middle", 1,1)
SetAmbientMusic(REP, 0.2, "rep_uta_amb_end", 2,1)
SetAmbientMusic(CIS, 1.0, "cis_uta_amb_start", 0,1)
SetAmbientMusic(CIS, 0.8, "cis_uta_amb_middle", 1,1)
SetAmbientMusic(CIS, 0.2, "cis_uta_amb_end", 2,1)

SetVictoryMusic(REP, "rep_uta_amb_victory")
SetDefeatMusic (REP, "rep_uta_amb_defeat")
SetVictoryMusic(CIS, "cis_uta_amb_victory")
SetDefeatMusic (CIS, "cis_uta_amb_defeat")

SetSoundEffect("ScopeDisplayZoomIn", "binocularzoomin")
SetSoundEffect("ScopeDisplayZoomOut", "binocularzoomout")
--SetSoundEffect("WeaponUnableSelect", "com_weap_inf_weaponchange_null")
--SetSoundEffect("WeaponModeUnableSelect", "com_weap_inf_modechange_null")
SetSoundEffect("SpawnDisplayUnitChange", "shell_select_unit")
SetSoundEffect("SpawnDisplayUnitAccept", "shell_menu_enter")
SetSoundEffect("SpawnDisplaySpawnPointChange", "shell_select_change")
SetSoundEffect("SpawnDisplaySpawnPointAccept", "shell_menu_enter")
SetSoundEffect("SpawnDisplayBack", "shell_menu_exit")

-- Camera Stats - Utapau: Sinkhole
AddCameraShot(-0.428091, 0.045649, -0.897494, -0.095703, 162.714951, 45.857063, 40.647118)
AddCameraShot(-0.194861, -0.001600, -0.980796, 0.008055, -126.179787, 16.113789, 70.012894);
AddCameraShot(-0.462548, -0.020922, -0.885442, 0.040050, -16.947638, 4.561796, 156.926956);
AddCameraShot(0.995310, 0.024582, -0.093535, 0.002310, 38.288612, 4.561796, 243.298508);
AddCameraShot(0.827070, 0.017093, 0.561719, -0.011609, -24.457638, 8.834146, 296.544586);
AddCameraShot(0.998875, 0.004912, -0.047174, 0.000232, -45.868237, 2.978215, 216.217880);


end


[/code]
Every unit involved does work normally on other maps, some with more meleer's than this map.

Re: Combo Memory - No Damage

Posted: Fri Jul 23, 2010 9:18 pm
by lucasfart
Have you tried a manual clean first? Because you have the memory pool showing up in the lua, but your log is saying that you haven't.

Re: Combo Memory - No Damage

Posted: Fri Jul 23, 2010 9:21 pm
by kinetosimpetus
i deleted any file starting with uta* in the munged folder, the mission.lvl in the _lvl_pc folder and remunged.

Doh, solved.

There was a call to the same memory pool lower down in the code setting it to 610.