Simple code not working... I suck at Lua

Hi guys,
I am having an issue with my code. I am creating a gamemode and a small chunk doesn’t work.
The player models, even when I do the precache, don’t load, and i want to make it so that you are forced to use that model.
Here is the code:

function GM:PlayerLoadout( ply )

if ply:Team() == 1 then

   ply:Give( "weapon_fiveseven" ) --Give the player the fiveseven
   util.PrecacheModel( "models\player\male_06.mdl" )
   ply:SetModel( "models\player\male_06" ) --Set the players model 

elseif ply:Team() == 2 then

   ply:Give( "weapon_glock" )
   util.PrecacheModel( "models\player\phoenix.mdl" )
   ply:SetModel( "models\player\phoenix.mdl" )

elseif ply:Team() == 3 then

   ply:Give( "weapon_deagle" )
   util.PrecacheModel( "models\player\riot.mdl" )
   ply:SetModel( "models\player\riot.mdl" ) --this and phoenix are CSS models, but you probably know that :)
     
end

end

[editline]29th July 2012[/editline]

Thanks guys!

Assuming you have the model name correct, you are missing.mdl at the end of models\player\male_06

I really haven’t used precache model in my script, Seems fine though.

Also, you may want to put that in GM:PlayerSpawn( ply ) and see if it works (after you add .mdl)

Thanks for the reply!
It seems to work, but it claims that the models don’t exist, even though i think my paths are correct
What could be the problem?

If Im correct, the file path should be

models/player/Group01/male_06.mdl

Thanks, It works!
Where can i get the path’s and names of the player models?

You can browse for most models inside of Garry’s mod.
There might be a list of playermodels etc on the old wiki too, But I’m not certain.
There’s also addons to browse for files inside of the game.

Another thing to do would be to do it in either Hammer or open op the gcf in gcfscape or something.

Hey i think i got most of them working, but the Cstrike Phoenix model doesnt have animations. Is my path wrong?

You used \

Should it be /?

No I tried that and it didnt work. I hate to ask, but could someone check for me?
I know I sound like a total sourpus :frowning: