* Open Client.cpp
* Search For The Following Part
// HUD Message
char gHudMessage[256]="";
StopTimer gHudTimer;
* The Add This Part Under It
char gHudMessage5[4][256] = { "","","","" }; //allow up to four messages
StopTimer gHudTimer5;
int indexRedirect[4] = { 0,1,2,3 }; // a "hack" way to scroll list without copying strings
int duration;
void gSetHudMessage5(const char* message)
{
int dest = indexRedirect[0];
indexRedirect[0] = indexRedirect[1];
indexRedirect[1] = indexRedirect[2];
indexRedirect[2] = indexRedirect[3];
indexRedirect[3] = dest;
strcpy(gHudMessage5[dest],message);
gHudTimer5.countdown(duration);
}
* So You Get
// HUD Message
char gHudMessage[256]="";
StopTimer gHudTimer;
char gHudMessage5[4][256] = { "","","","" }; //allow up to four messages
StopTimer gHudTimer5;
int indexRedirect[4] = { 0,1,2,3 }; // a "hack" way to scroll list without copying strings
int duration;
void gSetHudMessage5(const char* message)
{
int dest = indexRedirect[0];
indexRedirect[0] = indexRedirect[1];
indexRedirect[1] = indexRedirect[2];
indexRedirect[2] = indexRedirect[3];
indexRedirect[3] = dest;
strcpy(gHudMessage5[dest],message);
gHudTimer5.countdown(duration);
}
* Ok Next Thing You Need To Add in Hud_Redraw
//Draw HudString Queue
int line_a = 20;
int line_b = 440;
if(cvar.scrollhud)
{
DrawHudString(line_a - 2, line_b , 0, 0, 255, "-][ Hit Info ][-" );
DrawHudString(line_a + 2, line_b , 0, 0, 255, "-][ Hit Info ][-" );
DrawHudString(line_a , line_b + 2, 0, 0, 255, "-][ Hit Info ][-" );
DrawHudString(line_a , line_b - 2, 0, 0, 255, "-][ Hit Info ][-" );
DrawHudString(line_a - 1, line_b - 1, 0, 0, 255, "-][ Hit Info ][-" );
DrawHudString(line_a + 1, line_b + 1, 0, 0, 255, "-][ Hit Info ][-" );
DrawHudString(line_a + 1, line_b - 1, 0, 0, 255, "-][ Hit Info ][-" );
DrawHudString(line_a - 1, line_b + 1, 0, 0, 255, "-][ Hit Info ][-" );
DrawHudString(line_a , line_b , 255, 255, 255, "-][ Hit Info ][-" );
DrawHudString(20,460,0,100,255,gHudMessage5[indexRedirect[0]]);
DrawHudString(20,480,0,150,255,gHudMessage5[indexRedirect[1]]);
DrawHudString(20,500,0,200,255,gHudMessage5[indexRedirect[2]]);
DrawHudString(20,520,0,255,255,gHudMessage5[indexRedirect[3]]);
}
* Dont Forget To Register The Cvar Scrollhud
* Then You Go To void PreS_DynamicSound And Add This
string theMessage;
if(b>0 && b<=36)
{
theMessage = vPlayers.entinfo.name;
ref.team = vPlayers.team;
}
//player death detection 1
if(strstr(sample,"player/die1"))
{
theMessage+=" Got Owned";
gSetHudMessage5(theMessage.c_str());
}
//player death detection 2
if(strstr(sample,"player/die2"))
{
theMessage+=" Got Wasted";
gSetHudMessage5(theMessage.c_str());
}
//player death detection 3
if(strstr(sample,"player/die3"))
{
theMessage+=" Was Send To Heaven";
gSetHudMessage5(theMessage.c_str());
}
//player hit detection (kevlar)
if(strstr(sample,"player/bhit_kevlar-1"))
{
theMessage+=" Got Hit In Chest (Wearing Kevlar)";
gSetHudMessage5(theMessage.c_str());
}
//player hit detection (helmet)
if(strstr(sample,"player/bhit_helmet-1"))
{
theMessage+=" Got Hit In Head (Wearing Helmet)";
gSetHudMessage5(theMessage.c_str());
}
//player hit detection (no kevlar)
if(strstr(sample,"player/bhit_flesh"))
{
theMessage+=" Got Hit Not Critical (Maybe Not Wearing Kevlar)";
gSetHudMessage5(theMessage.c_str());
}
void hudDrawInfoTexts()
{
int line_y = cvar.line_y-18;
int line_x = cvar.line_x;
#define DECREMENT_LINE_Y { line_y-=16; }
int centerX = displayCenterX;
int centerY = displayCenterY;
ColorEntry* clr = colorList.get(0);
int r=clr->r, g=clr->g, b=clr->b, a=clr->a;
if (cvar.info)
{
ColorEntry* clr=colorList.get(13);
if(gHudTimer.running())
{
DrawGlowHudString(line_x,line_y,clr->r,clr->g,clr->b, gHudMessage );
DECREMENT_LINE_Y
}
if( gHudTimer2.running() )
{
DrawGlowHudString(line_x,line_y,clr->r,clr->g,clr->b, gHudMessage2 );
DECREMENT_LINE_Y
}
//============================================================================================
for (vector<aimvec>::iterator sa = gAimbot.AimVecsD.begin(); sa != gAimbot.AimVecsD.end();++sa) //by araz and faggot who owns ya
{
oglSubtractive=true;
gEngfuncs.pfnFillRGBA(line_x,line_y, 200, 16,0,0,0,130);
oglSubtractive=false;
DrawHudString(line_x,line_y,255,255,255,"%1.5f | %1.5f | %1.5f\n",sa->h,sa->f,sa->r);
DECREMENT_LINE_Y
}
oglSubtractive=true;
gEngfuncs.pfnFillRGBA(line_x,line_y, 200, 16,0,0,255,50);
oglSubtractive=false;
DrawHudString(line_x,line_y,255,255,255,"Duck:");
DECREMENT_LINE_Y
for (vector<aimvec>::iterator si = gAimbot.AimVecsS.begin(); si != gAimbot.AimVecsS.end();++si)
{
oglSubtractive=true;
gEngfuncs.pfnFillRGBA(line_x,line_y, 200, 16,0,0,0,130);
oglSubtractive=false;
DrawHudString(line_x,line_y,255,255,255,"%1.5f | %1.5f | %1.5f\n",si->h,si->f,si->r);
DECREMENT_LINE_Y
}
oglSubtractive=true;
gEngfuncs.pfnFillRGBA(line_x,line_y, 200, 16,0,0,255,50);
oglSubtractive=false;
DrawHudString(line_x,line_y,255,255,255,"Stand:");
DECREMENT_LINE_Y
//============================================================================================
//if(gHudTimer.running())
//{
// DrawHudString(line_x,line_y, 255, 0, 0, gHudMessage );
// DECREMENT_LINE_Y
//}
//if( gHudTimer2.running() )
//{
// DrawHudString(line_x,line_y,255,0,0,gHudMessage2 );
// DECREMENT_LINE_Y
//}
//================================================================================================================================================================00
if(cvar.bullshit)
{
gEngfuncs.pfnFillRGBA(cvar.bullshit_x,cvar.bullshit_y,me.iHealth,16,0,0,255,128);
gEngfuncs.pfnFillRGBA(cvar.bullshit_x,cvar.bullshit_y,1,16,255,255,255,255);
gEngfuncs.pfnFillRGBA(cvar.bullshit_x,cvar.bullshit_y,100,1,255,255,255,255);
gEngfuncs.pfnFillRGBA(cvar.bullshit_x+100,cvar.bullshit_y,1,16,255,255,255,255);
gEngfuncs.pfnFillRGBA(cvar.bullshit_x,cvar.bullshit_y+16,100,1,255,255,255,255);
oglSubtractive=false;
DrawHudString(cvar.hbart_x,cvar.hbart_y,255,255,255,"Health");
DrawHudString(cvar.hbart_x+92,cvar.hbart_y,255,255,255,"%d", me.iHealth);
}
// Infobox hud_redraw:
if (cvar.infobox)
{
oglSubtractive=true;
gEngfuncs.pfnFillRGBA(cvar.infobox_x,cvar.infobox_y, 200, 16,0,0,255,50);
gEngfuncs.pfnFillRGBA(cvar.infobox_x,cvar.infobox_y+17, 200, 16,0,0,0,130);
gEngfuncs.pfnFillRGBA(cvar.infobox_x,cvar.infobox_y+34, 200, 16,0,0,0,130);
gEngfuncs.pfnFillRGBA(cvar.infobox_x,cvar.infobox_y+51, 200, 16,0,0,0,130);
gEngfuncs.pfnFillRGBA(cvar.infobox_x,cvar.infobox_y+68, 200, 16,0,0,0,130);
gEngfuncs.pfnFillRGBA(cvar.infobox_x,cvar.infobox_y+85, 200, 16,0,0,0,130);
gEngfuncs.pfnFillRGBA(cvar.infobox_x,cvar.infobox_y+102, 200, 16,0,0,0,130);
oglSubtractive=false;
DrawHudString(cvar.infobox_x,cvar.infobox_y ,255,255,255, "Information Box");
DrawHudString(cvar.infobox_x,cvar.infobox_y+17 ,120,120,255, "AimVec: %s",VecName);
DrawHudString(cvar.infobox_x,cvar.infobox_y+34 ,120,120,255, "Spread: %f",me.spread.spreadvar);
DrawHudString(cvar.infobox_x,cvar.infobox_y+51 ,120,120,255, "Primary: %s - %d/%d",playerItems.getName1(),playerItems.weaponList[playerItems.slot1Index].iClip,playerItems.ammo[playerItems.weaponList[playerItems.slot1Index].iAmmoType]);
DrawHudString(cvar.infobox_x,cvar.infobox_y+68 ,120,120,255, "Secondary: %s - %d/%d",playerItems.getName2(),playerItems.weaponList[playerItems.slot2Index].iClip,playerItems.ammo[playerItems.weaponList[playerItems.slot2Index].iAmmoType]);
DrawHudString(cvar.infobox_x,cvar.infobox_y+85 ,120,120,255, "Access: %d",playerItems.money);
DrawHudString(cvar.infobox_x,cvar.infobox_y+102 ,120,120,255, "Health: %d", me.iHealth);
}
if (cvar.araz_stats)
{
PlayerInfo& r = vPlayers[me.ent->index];
int& stat_x = cvar.stat_x;
int& stat_y = cvar.stat_y;
ColorEntry* clrx = colorList.get(40);
oglSubtractive=true;
gEngfuncs.pfnFillRGBA(stat_x, stat_y+32,100,1,255,0,0,255);
gEngfuncs.pfnFillRGBA(stat_x, stat_y+64,100,1,255,0,0,255);
gEngfuncs.pfnFillRGBA(stat_x, stat_y+16,100,1,255,0,0,255);
gEngfuncs.pfnFillRGBA(stat_x, stat_y+48,100,1,255,0,0,255);
oglSubtractive=false;
DrawHudString(stat_x, stat_y+32, clrx->r, clrx->g, clrx->b, "Deaths: %d", r.deaths);
DrawHudString(stat_x, stat_y+64, clrx->r, clrx->g, clrx->b, "Percent: %4.1f", me.hspercent);
ColorEntry* clry = colorList.get(41);
DrawHudString(stat_x, stat_y+16, clry->r, clry->g, clry->b, "Kills %d", r.frags);
DrawHudString(stat_x, stat_y+48, clry->r, clry->g, clry->b, "Headshots: %d", me.headshots);
}
if (cvar.armormeter) // made by w00t.nl ^_^ displays a small bar with the
{
// coordinates
int xa = 20;
int xb = 75;
int ya = displayCenterY*2-180-38;
int yb = displayCenterY*2-180-38;
// hud thing
DrawGlowHudString(xa, yb, 255, 0, 0, "Armor: ");
// lines around meter
gEngfuncs.pfnFillRGBA(xb,displayCenterY*2-180-39,100,1,200,200,200,255);
gEngfuncs.pfnFillRGBA(xb,ya,1,14,200,200,200,255);
gEngfuncs.pfnFillRGBA(175,displayCenterY*2-180-39,1,16,200,200,200,255);
gEngfuncs.pfnFillRGBA(xb,displayCenterY*2-180-24,100,1,200,200,200,255);
// lines every 25 points
gEngfuncs.pfnFillRGBA(100,displayCenterY*2-180-38,1,14,100,100,100,255);
gEngfuncs.pfnFillRGBA(125,displayCenterY*2-180-38,1,14,100,100,100,255);
gEngfuncs.pfnFillRGBA(150,displayCenterY*2-180-38,1,14,100,100,100,255);
// bar itself
gEngfuncs.pfnFillRGBA(xb,ya,playerItems.armor,14,255,0,0,255);
}
if (cvar.healthmeter) // made by w00t.nl ^_^ displays a small bar with the
{
// coordinates
int xa = 20;
int xb = 75;
int ya = displayCenterY*2-180-58;
int yb = displayCenterY*2-180-58;
// hud thing
DrawGlowHudString(xa, yb, 255, 0, 0, "Health: ");
// lines around meter
gEngfuncs.pfnFillRGBA(xb,displayCenterY*2-180-59,100,1,200,200,200,255);
gEngfuncs.pfnFillRGBA(xb,ya,1,14,200,200,200,255);
gEngfuncs.pfnFillRGBA(175,displayCenterY*2-180-59,1,16,200,200,200,255);
gEngfuncs.pfnFillRGBA(xb,displayCenterY*2-180-44,100,1,200,200,200,255);
// lines every 25 points
gEngfuncs.pfnFillRGBA(100,displayCenterY*2-180-58,1,14,100,100,100,255);
gEngfuncs.pfnFillRGBA(125,displayCenterY*2-180-58,1,14,100,100,100,255);
gEngfuncs.pfnFillRGBA(150,displayCenterY*2-180-58,1,14,100,100,100,255);
// bar itself
gEngfuncs.pfnFillRGBA(xb,ya,me.iHealth,14,255,0,0,255);
}
}
if ( cvar.speed>1 )
{
extern DWORD speed_ticks_left;
extern DWORD phase_ticks_left;
int speedbar_x = displayCenterX*2 - 100;
int speedbar_y = displayCenterY*2 - 195;
ColorEntry* clr=colorList.get(13);
if(cvar.speedoff == 0 )
{
DrawHudString(cvar.speedbar_x-11,cvar.speedbar_y, 0, 0, 0, "SpeeD: NoLimiT");
}
else
{
if(speed_ticks_left) DrawHudString(cvar.speedbar_x,cvar.speedbar_y ,clr->r,clr->g,clr->b, "speed: %d",speed_ticks_left );
else DrawHudString(cvar.speedbar_x,cvar.speedbar_y-20,clr->r,clr->g,clr->b, "wait.. %d",phase_ticks_left );
}
if(cvar.speedbar == 1)
{
gEngfuncs.pfnFillRGBA(cvar.speedbar_x,cvar.speedbar_y,100,20,30,30,30,12);//background
if(speed_ticks_left)
{
gEngfuncs.pfnFillRGBA(cvar.speedbar_x,cvar.speedbar_y,speed_ticks_left/(cvar.speedon/100),20,255,0,0,255);
}
else
{
gEngfuncs.pfnFillRGBA(cvar.speedbar_x,cvar.speedbar_y,phase_ticks_left/(cvar.speedoff/100),20,255,50,0,255);
}
if(speed_ticks_left)
{
DrawHudString(cvar.speedbar_x,cvar.speedbar_y,clr->r,clr->g,clr->b, "speed: %d",speed_ticks_left );
}
else
{
DrawHudString(cvar.speedbar_x,cvar.speedbar_y-20,clr->r,clr->g,clr->b, "wait.. %d",phase_ticks_left );
}
}
}
}