Textured Rect [surface]

Erre :
[lua]

if (input.IsKeyDown(KEY_Q)) then

print(surface.GetTextureID(“gui/map”))

surface.SetTexture( surface.GetTextureID(“gui/map”) )
surface.DrawTexturedRect(ScrW()/8,ScrH()/8,ScrW()/86,ScrH()/86)

end

[/lua]

ezt kapom :




-- Missing Vgui material gui/map
--- Missing Vgui material gui/map
2175
--- Missing Vgui material gui/map
--- Missing Vgui material gui/map
2177
--- Missing Vgui material gui/map
--- Missing Vgui material gui/map
2179
--- Missing Vgui material gui/map
--- Missing Vgui material gui/map
2181
--- Missing Vgui material gui/map
--- Missing Vgui material gui/map
2183
--- Missing Vgui material gui/map
--- Missing Vgui material gui/map
2185
--- Missing Vgui material gui/map




[editline]5th July 2011[/editline]

I don’t really like this design part of lua. Please help

The material obviously does not exist.

Also for gods sakes cache the id and the screen height.

it does, I checked it

Post the vmt file.

“LightmappedGeneric”
{
“$basetexture” “gui/map”
}

[editline]5th July 2011[/editline]

oh shit
wait

[editline]5th July 2011[/editline]

now it is a bit buggy

[editline]5th July 2011[/editline]

sometimes I can see sometimes I can’t

http://img220.imageshack.us/img220/502/hl22011070622284198.jpg

Try caching surface.GetTextureID(“gui/map”), it causes lag which could be causing that

Try using UnlitGeneric with
$nolod 1