Page 1 of 1

Issues with the unit randomizer

Posted: Wed Jan 19, 2011 6:02 pm
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...
---------------------------------------------------------------------

Re: Issues with the unit randomizer

Posted: Wed Jan 19, 2011 6:18 pm
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.

Re: Issues with the unit randomizer

Posted: Wed Jan 19, 2011 6:26 pm
by wishihadaname
ohh thanks.