Post: [CODE]Hud Icons
02-07-2011, 10:42 PM #1
d7w7z
Bounty hunter
(adsbygoogle = window.adsbygoogle || []).push({}); This is completely useless but I have had it sitting in my patch for 3 or 4 weeks now.

Look at the bottom right. Sorry for the lag, Recorded on my laptop.



Here is the code. Smile
    
ModHud( C )
{
if (!self.HasHudMod) {
self.HasHudMod = true;
self.carryIcon = createIcon( C, 50, 50 );
self.carryIcon setPoint( "BOTTOM RIGHT", "BOTTOM RIGHT", -90, -65 );
self.carryIcon.alpha = 0.75;
self thread DestroyObjectOnDeath( self.carryIcon );
self thread DestroyHudMod( self.carryIcon );
self iPrintln("Hud Icon Modded");
} else {
self notify("HudMod");
self.HasHudMod = false;
} }
DestroyObjectOnDeath( object ) { self waittill("death"); object destroy(); }
DestroyHudMod( O ) { self waittill("HudMod"); O destroy(); }



How to use in menu
    
menu.name[menu.name.size] = "Hud Mod 1";
menu.function[menu.function.size+1] = ::ModHud;
menu.input[menu.input.size+1] = "hud_suitcase_bomb";

Just put the name of your icon in quotes for the input. This one would be the SnD Bomb Icon. Also dont forget to precache :bro:
Some dont work though Eek


Here is a list of icons and a link to change the position the icon. Credits to DEREKTROTTER for both of these.
You must login or register to view this content.
You must login or register to view this content.


To change the position of the icon to a new position just change the setPoint to a new setPoint from the click to generate position link.
    self.carryIcon setPoint( "BOTTOM RIGHT", "BOTTOM RIGHT", -90, -65 );
(adsbygoogle = window.adsbygoogle || []).push({});

The following user thanked d7w7z for this useful post:

icemantom95
02-07-2011, 10:49 PM #2
lol nice..
02-07-2011, 11:06 PM #3
CHAOZ
Banned
pointless yet nice :y:, i like, nice find if its yours.
02-07-2011, 11:09 PM #4
Originally posted by d7w7z View Post
]


LOL, thats easy.. get them to show over peoples heads and I'll be more impressed.. :420:
02-07-2011, 11:13 PM #5
Mr. Aimbot
¯\_(ツWinky Winky_/¯
Originally posted by RUFFINGUY View Post
pointless yet nice :y:, i like, nice find if its yours.


Fail advertising link is Fail :shh:
02-08-2011, 12:19 AM #6
d7w7z
Bounty hunter
Originally posted by x View Post
LOL, thats easy.. get them to show over peoples heads and I'll be more impressed.. :420:

Haha, Thats what I was trying to do when I found this. I cant really test it though because am a cfw no0b and my MW2 on the PC doesnt feel the need to show me the mini map lol /facepalm
02-08-2011, 12:27 AM #7
Amanda
Can’t trickshot me!
Originally posted by x View Post
LOL, thats easy.. get them to show over peoples heads and I'll be more impressed.. :420:


It might be possible... I found this in the S&Awesome face GSC

    onPickup( player )
{
player.isBombCarrier = true;
player incPlayerStat( "bombscarried", 1 );
player thread maps\mp\_matchdata::logGameEvent( "pickup", player.origin );

self maps\mp\gametypes\_gameobjects::set2DIcon( "friendly", "waypoint_escort" );
self maps\mp\gametypes\_gameobjects::set3DIcon( "friendly", "waypoint_escort" );

if ( !level.bombDefused )
{
teamPlayerCardSplash( "callout_bombtaken", player, player.team );
leaderDialog( "bomb_taken", player.pers["team"] );
}
maps\mp\_utility::playSoundOnPlayers( game["bomb_recovered_sound"], game["attackers"] );
}


Maybe if we call these functions for all players and with another icon we may be able to mark them Smile

    	self maps\mp\gametypes\_gameobjects::set2DIcon( "friendly", "waypoint_escort" );
self maps\mp\gametypes\_gameobjects::set3DIcon( "friendly", "waypoint_escort" );
02-08-2011, 12:28 AM #8
Originally posted by d7w7z View Post
Haha, Thats what I was trying to do when I found this. I cant really test it though because am a cfw no0b and my MW2 on the PC doesnt feel the need to show me the mini map lol /facepalm


No mine doesnt either, but i meant to actually put a spinning skull over someones head in the game .. Ive tried and failed a couple of times now :(

There's stuff in there for the deathskull icon etc when you die but I cant get it to work with anything else ..
02-08-2011, 01:06 AM #9
d7w7z
Bounty hunter
Originally posted by x View Post
No mine doesnt either, but i meant to actually put a spinning skull over someones head in the game .. Ive tried and failed a couple of times now :(

There's stuff in there for the deathskull icon etc when you die but I cant get it to work with anything else ..

I have seen it the deathskull coding and I have messed about with the icons for claymores but that was only changing which team it displayed. The spinning skull would be very hard to get working as a head icon though.

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo