PDA

View Full Version : Placing an icon somewhere on your screen?


fang
04-24-2008, 17:00
Is there a way to specify the location of a sprite on the users screen?
Ex. Over the radar or in the middle of the screen

public fw_prethink(id)
{
if(is_user_alive(id))
{
message_begin(MSG_ONE,iconstatus,{0,0,0},id);
write_byte(1); // status (0=hide, 1=show, 2=flash)
write_string("smallskull"); // sprite name
write_byte(255); // red
write_byte(0); // green
write_byte(0); // blue
message_end();
}

}

Exolent[jNr]
04-24-2008, 17:15
IconStatus is an event that shows the icons on your HUD, not in the game.
To make sprites in-game, you will need to create an entity and set the model to the sprite, and then set rendering effects if transparency is wanted.

fang
04-24-2008, 18:00
Oops. my bad. Is there anyway to set the icon on a specific place on your screen?

hoboman
04-24-2008, 19:26
you can only use those predefined names like d_scout, etc...
other than those you cannot display any other sprites on the player's hud

fang
04-24-2008, 20:37
o.0 I meant like..


Player's Screen..
----------------------------------
(radar)




(normally where icon would be displayed)


HP
----------------------------------


I don't want a custom icon. I just want to know if it's possible to move the location of the icon to like over the radar or something instead of in the middle left of the screen.