Entity Finder

Posts 1–5 of 5 · Page 1 of 1
Entity Finder
This is my first gmod script. I was trying to find an entity finder for gmod but i couldnt so i decided to make my own.
Code:
Code:
	Msg("Entity Finder by end360 Loaded.")
	concommand.Add( "entityfind", function( ply, cmd, args )
	Class=args[1]
	CreateClientConVar( "entity_finder_on", 1, true, false )
	function EntityFinder()
		if GetConVarNumber( "entity_finder_on" ) >= 1 and Class then
			for k, v in pairs( ents.FindByClass( Class ) ) do
							DrugPos = v:GetPos():ToScreen()
							draw.SimpleText( Class, "EntityFont", DrugPos.x, DrugPos.y, Color( 0, 200, 255, 255 ), TEXT_ALIGN_CENTER, TEXT_ALIGN_CENTER )
						end
				
			end
		end

	hook.Add( "HUDPaint", "EntityFinder", EntityFinder )
	local tblFonts = { }
	tblFonts["EntityFont"] = {
		font = "Tahoma",
		size = 11,
		weight = 0,
		shadow = true,
	}
	for k,v in SortedPairs( tblFonts ) do
		surface.CreateFont( k, tblFonts[k] );
	end
	end)
Screenshots:


Have fun.

Edit:
Almost forgot the commands:
entityfind entity_name

entity_finder_on 0-1
4000_screenshots_2013-12-25_00001.jpg198 KB · 277 downloads
Nice job man, I will indeed try it out
Nice!


Is there any way to tell how far away the entity is?



This works great for Clockwork RP.
Quote Originally Posted by Evanp857 View Post
Nice!
Is there any way to tell how far away the entity is?

This works great for Clockwork RP.
Check this thread on the wiki, modify this to your needs.
Posts 1–5 of 5 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

Talk with us