

More info about this function on the draw.DrawText page.ĭraw.DrawText ( v:Name ( ), "MenuLarge", Position.x, Position.y, Color ( 255, 255, 255, 255 ), 1 ) The sixth and the last one is just the Xalign, you can just leave it.
Gmod hacks free#
The fifth is the color, feel free to change it. The third and the fourth are the texts position X, and Y. The second argument is the font, feel free to find a suitable for you from the Working with Fonts page. I'll explain about the function, The first argument is the text to draw, in this case it would be the players.

This is the most important function on this, it will draw the players name above his head. Now we'll just need to implement this into the script you made. Local Position = ( v:GetPos ( ) + Vector ( 0, 0, 80 ) ):ToScreen ( ) The vector addition is because we don't want to have the name on the players feet, do we. With this we are getting the players position, and converting it into a position on our screen. Now that we have got all the players, we just need the text above their head. Hook.Add ( "HUDPaint", "Wallhack", function ( ) for k,v in pairs ( player.GetAll ( ) ) do - This is a loop going across all players. Because it's an wallhack, we'll have to go through the players of course. Hook.Add ( "HUDPaint", "Wallhack", function ( ) end )īut of course, that's not the wallhack itself, we'll still need to add something to it.

This is the main part, it will make a hook, which will draw our text to the screen. And when you want to test it, just type lua_openscript_cl a Wallhack tutorial We'll start by creating the lua file, just create "a" to the lua directory of Garry's Mod.
