Forum

> > CS2D > Scripts > HUD things in map
Forums overviewCS2D overview Scripts overviewLog in to reply

English HUD things in map

1 reply
To the start Previous 1 Next To the start

old HUD things in map

xSkyLordx
User Off Offline

Quote
Hello everybody, i cant speak english very well sorry for bad spelling..

i have no idea how can i script that hud thing..
for example HUDTxt in floor or hudimages in floor or hudtxt following players stuff like this, i want to create a roof thing when you enter house roof disappers only for me not for others this is what i want to do but im not asking for this im telling this because maybe u can understand what im really asking for thanks

see ya

OK GUYS SORRY I FIGURED IT OUT Actually i find it

1
2
3
4
5
function updatehud(id,pl)
	local x = player(pl,"x") - player(id,"x") + 320
	local y = player(pl,"y") - player(id,"y") + 200
	parse('hudtxt2 '..id..' '..pl..' "©170170250 '..player(pl,"name")..'" '..x..' '..y..' 1')
end

from show money lua
edited 1×, last 07.04.16 11:22:18 pm

Admin/mod comment

Code tag added! Use it next time if you attempt to post codes. /user GeoB99

old Re: HUD things in map

VADemon
User Off Offline

Quote
Read cs2d lua cmd image twice. Create personal images for each player and remove a player's roof image when he enters the house.
// ninja'd by topic starter?
@user xSkyLordx: it's told that updating the hud every frame will increase network usage, so be careful.
UPD: You should use cs2d cmd hudtxtmove to only move the image, it will reduce net overhead, particularly if you update the hud position every 2 or 3 frames.
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview