09-17-2012, 00:36
(This post was last modified: 09-17-2012, 00:37 by tonymamoni1.)
I made this real quick for my new mod menu, it makes a icon on your minimap when someone camps
Code:
CamperPrevention()//add to onplayerspawned
{
self endon("disconnect");
self endon("death");
precacheShader( "compass_waypoint_target" );
for(;;)
{
self.crnt = self.origin;
wait 15;
if( Distance( self.crnt, self.origin )<80 )
{
objective_add( 1, "active", self.origin );
objective_icon( 1, "compass_waypoint_target" );
notifyData = spawnStruct();
notifyData.titleText = "^2"+self.name+" Is A Gay Camper";
notifyData.notifyText = "^7Look At your Mini Map To Find The camper";
notifyData.duration = 6;
notifyData.sound = "mp_challenge_complete";
self maps\mp\gametypes\_hud_message::notifyMessage( notifyData );
self endon("death")
for(;;)
{
objective_position( 1, self.origin );
wait 0.2;
}
}
}
}