Models always show as errors

Hey guys, I’m having problems with downloading and using SetModel for players. The models are all downloading correctly and going to my garrysmod/models folder, although the .vvd file ends up in garrysmod/downloads/models folder instead of just the root models folder.

Anyways, the problem I’m having is when I do:



usr:SetModel("models/MOwneZ/gnome.mdl")
usr:SetMaterial("materials/models/MOwneZ/gnome")


I get “Error” models. It doesn’t make sense to me, the only thing that makes sense is that because the .vvd (for whatever reason) decided to goto the downloads/models directory, but even so it should still be able to load the error models.

All the models/materials are in the root garrysmod folder as well for my server.

Here’s a link to my FastDL as well: http://suicide-survival.googlecode.com/svn/trunk/

Please help me solve this problem, it’s been really annoying trying to figure this out, and I’ve been trying to fix this problem for some time now…

OH! And one more thing, here’s my precache.lua file that I have in “lua/autorun”. It works and I don’t think there are any problems with it… that I’m aware of.



local Models={
	"models/a_shrubbery.mdl",
	"models/a_shrubbery.vdd",
	"models/a_shrubbery.phy",
	"models/a_shrubbery.dx80.vtx",
	"models/a_shrubbery.dx90.vtx",
	"models/a_shrubbery.sw.vtx",
	"models/a_shrubbery.xbox.vtx",
	
	"models/combine_soldier_anims.mdl",
	"models/francois_animations.mdl",
	
	"models/knowledge_ammo.mdl",
	"models/knowledge_ammo.vvd",
	"models/knowledge_ammo.phy",
	"models/knowledge_ammo.dx80.vtx",
	"models/knowledge_ammo.dx90.vtx",
	"models/knowledge_ammo.sw.vtx",
	"models/knowledge_ammo.xbox.vtx",
	
	"models/KnowledgeBolt.mdl",
	"models/KnowledgeBolt.vvd",
	"models/KnowledgeBolt.phy",
	"models/KnowledgeBolt.dx80.vtx",
	"models/KnowledgeBolt.dx90.vtx",
	"models/KnowledgeBolt.sw.vtx",
	"models/KnowledgeBolt.xbox.vtx",
	
	"models/pappel.mdl",
	"models/pappel.vvd",
	"models/pappel.phy",
	"models/pappel.dx80.vtx",
	"models/pappel.dx90.vtx",
	"models/pappel.sw.vtx",
	"models/pappel.xbox.vtx",
	
	"models/Police_animations.mdl",
	
	"models/round_bush.mdl",
	"models/round_bush.vvd",
	"models/round_bush.phy",
	"models/round_bush.dx80.vtx",
	"models/round_bush.dx90.vtx",
	"models/round_bush.sw.vtx",
	"models/round_bush.xbox.vtx",
	
	"models/v_weapon_knowledge.mdl",
	"models/v_weapon_knowledge.vvd",
	"models/v_weapon_knowledge.dx80.vtx",
	"models/v_weapon_knowledge.dx90.vtx",
	"models/v_weapon_knowledge.sw.vtx",
	"models/v_weapon_knowledge.xbox.vtx",
	
	"models/w_weapon_knowledge.mdl",
	"models/w_weapon_knowledge.vvd",
	"models/w_weapon_knowledge.phy",
	"models/w_weapon_knowledge.dx80.vtx",
	"models/w_weapon_knowledge.dx90.vtx",
	"models/w_weapon_knowledge.sw.vtx",
	"models/w_weapon_knowledge.xbox.vtx",
	
	"models/weapons/dummy_weapon.mdl",
	"models/weapons/dummy_weapon.phy",
	"models/weapons/dummy_weapon.vvd",
	"models/weapons/dummy_weapon.dx80.vtx",
	"models/weapons/dummy_weapon.dx90.vtx",
	"models/weapons/dummy_weapon.sw.vtx",
	"models/weapons/dummy_weapon.xbox.vtx",
	
	"models/player/female_anims.mdl",
	"models/player/male_anims.mdl",
	"models/humans/female_gestures.mdl",
	"models/humans/female_postures.mdl",
	"models/humans/female_shared.mdl",
	"models/humans/female_ss.mdl",
	"models/humans/male_gestures.mdl",
	"models/humans/male_postures.mdl",
	"models/humans/male_shared.mdl",
	"models/humans/male_ss.mdl",
	
	"models/francois/francois.mdl",
	"models/francois/francois.phy",
	"models/francois/francois.vvd",
	"models/francois/francois.dx80.vtx",
	"models/francois/francois.dx90.vtx",
	"models/francois/francois.sw.vtx",
	"models/francois/francois.xbox.vtx",
	
	"models/MOwneZ/gnome.mdl",
	"models/MOwneZ/gnome.vvd",
	"models/MOwneZ/gnome.sw.vtx",
	"models/MOwneZ/gnome.phy",
	"models/MOwneZ/gnome.dx90.vtx",
	"models/MOwneZ/gnome.dx80.vtx"
}
local Sounds={
	"sound/explosion1.wav",
	"sound/explosion2.wav",
	"sound/taunts_suicider/behindyou01.wav",
	"sound/taunts_suicider/behindyou02.wav",
	"sound/taunts_suicider/overhere01.wav",
	"sound/taunts_suicider/overthere01.wav",
	"sound/taunts_suicider/overthere02.wav",
	"sound/taunts_suicider/yalala.wav",
	"sound/taunts_survivor/ecky.wav",
	"sound/taunts_survivor/ni.wav",
	"sound/taunts_survivor/notseen.wav",
	"sound/taunts_survivor/shrub.wav",
	"sound/taunts_survivor/shrub2.wav",
	"sound/weapons/bolt_smack2.wav"
}
local Materials={
	"materials/ferret_grass1.vmt",
	"materials/ferret_grass1.vtf",
	"materials/ferret_mark.vmt",
	"materials/ferret_mark.vtf",
	"materials/ferret_stones.vmt",
	"materials/ferret_stones.vtf",
	"materials/ferret_wall1.vmt",
	"materials/ferret_wall1.vtf",
	"materials/glasswindow041b.vmt",
	"materials/glasswindow041b.vtf",
	"materials/ss_garden_layout.vmt",
	"materials/ss_garden_layout.vtf",
	"materials/ss_glasswindow.vmt",
	"materials/ss_glasswindow.vtf",
	"materials/ss_grassground.vmt",
	"materials/ss_grassground.vtf",
	"materials/ss_grassground_normal.vtf",
	"materials/ss_ground_green.vmt",
	"materials/ss_ground_green.vtf",
	"materials/ss_hedge_green.vmt",
	"materials/ss_hedge_green.vtf",
	"materials/ss_hedge_wall.vmt",
	"materials/ss_hedge_wall.vtf",
	"materials/ss_hedge_wall_normal.vtf",
	"materials/ss_hedge_wall02.vmt",
	"materials/ss_hedge_wall02_normal.vtf",
	"materials/ss_sky_fake_blue.vmt",
	"materials/ss_sky_fake_blue.vtf",
	"materials/ss_stone.vmt",
	"materials/ss_stone.vtf",
	"materials/ss_stone_normal.vtf",
	"materials/ss_tree_green.vmt",
	"materials/ss_tree_green.vtf",
	"materials/wooddoor022a.vmt",
	"materials/wooddoor022a.vtf",
	
	"materials/skybox/mpa48bk.vmt",
	"materials/skybox/mpa48dn.vmt",
	"materials/skybox/mpa48ft.vmt",
	"materials/skybox/mpa48lf.vmt",
	"materials/skybox/mpa48rt.vmt",
	"materials/skybox/mpa48up.vmt",
	"materials/skybox/mpa48bk.vtf",
	"materials/skybox/mpa48dn.vtf",
	"materials/skybox/mpa48ft.vtf",
	"materials/skybox/mpa48lf.vtf",
	"materials/skybox/mpa48rt.vtf",
	"materials/skybox/mpa48up.vtf",
	"materials/skybox/sky_tf2_04_hdrbk.vmt",
	"materials/skybox/sky_tf2_04_hdrdn.vmt",
	"materials/skybox/sky_tf2_04_hdrft.vmt",
	"materials/skybox/sky_tf2_04_hdrlf.vmt",
	"materials/skybox/sky_tf2_04_hdrrt.vmt",
	"materials/skybox/sky_tf2_04_hdrup.vmt",
	"materials/skybox/sky_tf2_04_hdrside.vtf",
	"materials/skybox/sky_tf2_04_hdrup.vtf",
	"materials/skybox/sky_tf2_04_hdrdn.vtf",
	"materials/skybox/sky_tf2_04bk.vmt",
	"materials/skybox/sky_tf2_04dn.vmt",
	"materials/skybox/sky_tf2_04ft.vmt",
	"materials/skybox/sky_tf2_04lf.vmt",
	"materials/skybox/sky_tf2_04rt.vmt",
	"materials/skybox/sky_tf2_04up.vmt",
	"materials/skybox/sky_tf2_04side.vtf",
	"materials/skybox/sky_tf2_04up.vtf",
	"materials/skybox/sky_tf2_04dn.vtf",
	
	"materials/fancois/fireLayeredSlowTiled512.vtf",
	"materials/fancois/francois.vmt",
	"materials/fancois/francois.vtf",
	"materials/fancois/francois_normal.vtf",
	"materials/fancois/Kopie von francois.vmt",
	
	"materials/models/a_shrubbery.vmt",
	"materials/models/a_shrubbery_lightwarp.vtf",
	"materials/models/a_shrubbery_normal.vtf",
	"materials/models/a_shrubbery_normal_old.vtf",
	"materials/models/a_shrubbery_old.vtf",
	"materials/models/a_shrubbery.vtf",
	"materials/models/knowledge_ammo.vmt",
	"materials/models/knowledge_ammo.vtf",
	"materials/models/KnowledgeBolt.vmt",
	"materials/models/KnowledgeBolt.vtf",
	"materials/models/KnowledgeBolt_normal.vtf",
	"materials/models/pappel.vmt",
	"materials/models/pappel.vtf",
	"materials/models/pappel_normal.vtf",
	"materials/models/round_bush.vmt",
	"materials/models/round_bush.vtf",
	"materials/models/round_bush_normal.vtf",
	"materials/models/weapon_knowledge_selected.vmt",
	"materials/models/weapon_knowledge_selected.vtf",
	"materials/models/weapon_knowledge_unselected.vmt",
	"materials/models/weapon_knowledge_unselected.vtf",
	
	"materials/models/MOwneZ/gnome_normal.vtf",
	"materials/models/MOwneZ/gnome.vtf",
	"materials/models/MOwneZ/gnome.vmt"
}


local function AddPrecacheResources()
	for i=1, #Models do
		local File = Models*		
		local ext = string.GetExtensionFromFilename(File)
		resource.AddFile(File)
		if(ext=="mdl")then
			util.PrecacheModel( File )
		end
	end
	for ii=1, #Sounds do
		local File = Sounds[ii]			
		resource.AddFile(File)
		util.PrecacheSound( File )
	end
	for iii=1, #Materials do
		local File = Materials[iii]			
		resource.AddFile(File)
	end
	

end

AddPrecacheResources( )