Issues with the unit randomizer

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
User avatar
wishihadaname
Captain
Captain
Posts: 493
Joined: Fri Dec 28, 2007 2:10 pm
Projects :: The Corellian Resistance
Games I'm Playing :: Halo Reach and LOTRO
Location: Look to your left.... no, your other left....

Issues with the unit randomizer

Post by wishihadaname »

I am using KinetosImpetus's unit randomizer script but i'm having a problem getting it to work. The game doesn't seem to want to recognize that it has the required mesh, when the models rotate I get this message

Message Severity: 3
.\Source\EntityGeometry.cpp(619)
Entity "all_inf_rifleman" missing geometry "rep_inf_trooper"

But the .msh and the .tga for the republic trooper are present in the alliance custom side folder. If i understand correctly, this script is adjusting the unit ODF's meaning I shouldn't have any missing callbacks, its the same as me writing in a different geometry name for the unit odf. Here is the randomization code for referance, what am I missing here?
Hidden/Spoiler:
------------------------------------------------------------
--This is code for cycling rifleman models
------------------------------------------------------------
--KinetosImpetus

SetClassProperty("all_inf_rifleman", "GeometryName", "all_inf_rebel_saboteur")
SetClassProperty("all_inf_rifleman", "GeometryLowRes", "all_inf_soldier_low1")
--this little part ^ was for debugging really, it isn't necessary

-- Timer for skins--

--interval is the number of seconds between model changes
--maxskin is the number of versions to use

interval = 10 --i had been testing this at 10 second waves, but it could be changed
--in MP, it will probably cause each 15 second spawn-wave to be the same model
skintimer = CreateTimer("timeout") -- i don't know what significance "timeout" has, copied from hoth campaign this way
SetTimerValue(skintimer , interval )
--ShowTimer(skintimer ) --uncomment this line to see the timer onscreen
skin = 1
maxskin = 3

OnTimerElapse(
function(timer)


if (skin == 1) then
SetClassProperty("all_inf_rifleman", "GeometryName", "all_inf_rebel_saboteur")
SetClassProperty("all_inf_rifleman", "GeometryLowRes", "all_inf_soldier_low1")
end
if (skin == 3) then
SetClassProperty("all_inf_rifleman", "GeometryName", "rep_inf_hlclone")
SetClassProperty("all_inf_rifleman", "GeometryLowRes", "rep_inf_trooper_low1")
end
if (skin == 2) then
SetClassProperty("all_inf_rifleman", "GeometryName", "rep_inf_trooper")
SetClassProperty("all_inf_rifleman", "GeometryLowRes", "rep_inf_trooper_low1")
end




skin = skin + 1

if (skin > maxskin) then
skin = 1
end

--ShowTimer(nil)
--DestroyTimer(timer)



SetTimerValue(skintimer , interval )
StartTimer(skintimer)


end,
skintimer
)

-------------------------------------------------------------------------
--resume normal conquest script, or whatever gamemode...
--------------------------------------------------------------------------

StartTimer(skintimer) --starts the timer the first time, after it starts, it will restart itself one ending.

--------------wait start the timer first! ok, now go...
---------------------------------------------------------------------
kinetosimpetus
Imperial Systems Expert
Imperial Systems Expert
Posts: 2381
Joined: Wed Mar 25, 2009 4:15 pm
Projects :: A secret project
Games I'm Playing :: Warframe STO

Re: Issues with the unit randomizer

Post by kinetosimpetus »

Add a "model" and "texture" section to either the rifleman's req or the side req, with the names of the tag's and msh's. Otherwise they aren't munged into the .lvl.
User avatar
wishihadaname
Captain
Captain
Posts: 493
Joined: Fri Dec 28, 2007 2:10 pm
Projects :: The Corellian Resistance
Games I'm Playing :: Halo Reach and LOTRO
Location: Look to your left.... no, your other left....

Re: Issues with the unit randomizer

Post by wishihadaname »

ohh thanks.
Post Reply