Raised This Month: $ Target: $400
 0% 

Change hud timer position ?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
firstride
Member
Join Date: Jun 2011
Old 06-15-2013 , 01:34   Change hud timer position ?
Reply With Quote #1

Hello allieds , i wan't to change the hud position of the round timer countdown ( that from the bottom of the screen).
How to do this ?

Thanks
firstride is offline
gamestar110
Member
Join Date: Sep 2011
Location: india
Old 06-15-2013 , 01:46   Re: Change hud timer position ?
Reply With Quote #2

Quote:
Originally Posted by firstride View Post
Hello allieds , i wan't to change the hud position of the round timer countdown ( that from the bottom of the screen).
How to do this ?

Thanks
Post the round timer countdown plugin code
__________________
Trying to learn coding for amxx plugins
gamestar110 is offline
Catastrophe
Veteran Member
Join Date: Jul 2012
Location: somewhere between narnia
Old 06-15-2013 , 01:47   Re: Change hud timer position ?
Reply With Quote #3

Post the code and where u exactly want it....
__________________
You will find everything u need :-
Catastrophe is offline
firstride
Member
Join Date: Jun 2011
Old 06-27-2013 , 12:54   Re: Change hud timer position ?
Reply With Quote #4

Sorry for the late response

It's not a plugin , it's that clock that appear at the bottom of the display and count the round to the end.
I wan't to change the position of it

Sorry for my english , and thanks
firstride is offline
Catastrophe
Veteran Member
Join Date: Jul 2012
Location: somewhere between narnia
Old 06-27-2013 , 12:57   Re: Change hud timer position ?
Reply With Quote #5

Ok, actually that's basic CS stuff so i dont know how can it be moved, or is it even possible... i dont think it is...
__________________
You will find everything u need :-
Catastrophe is offline
firstride
Member
Join Date: Jun 2011
Old 06-27-2013 , 13:07   Re: Change hud timer position ?
Reply With Quote #6

Ok , then let's think in another way

I used a plugin to hide it , ok.
Can pe possible to make a plugin with another count ? A permanent hud that count the round ....

I think a count down set by the round timer..( My round timer it's set with 3 minutes) it woud be enough
Soo if my round timer it's 3 minutes (for example) we can make a hud timer that count from 180 seconds to 0 ?

Last edited by firstride; 06-27-2013 at 13:07.
firstride is offline
Catastrophe
Veteran Member
Join Date: Jul 2012
Location: somewhere between narnia
Old 06-28-2013 , 00:36   Re: Change hud timer position ?
Reply With Quote #7

Yeah, that's possible, Tell me where do u want the HUD to appear, that one is really easy to make....

Also can u give me the plugin u used to hide the Timer, post it here in PHP form maybe i cud use sm useful code frm that
__________________
You will find everything u need :-
Catastrophe is offline
firstride
Member
Join Date: Jun 2011
Old 07-05-2013 , 04:16   Re: Change hud timer position ?
Reply With Quote #8

Sorry for delay , i was in vacantion 7 days.

This is the code to hide radar , hp , etc

PHP Code:
#include <amxmodx> 
#include <amxmisc> 

#define PLUGIN "HUD Customizer 0.4" 
#define VERSION "0.4" 
#define AUTHOR "Igoreso" 


// Hides Crosshair, Ammo, Weapons List ( CAL in code ). Players won't be able to switch weapons using list so it's not recommended
#define HUD_HIDE_CAL (1<<0)

// Hides Flashlight, but adds Crosshair ( Flash in code )
#define HUD_HIDE_FLASH (1<<1)

// Hides all. Equal to "hud_draw 0", it removes everything (amx's menus TOO), so it's hardly not recommended.
//#define HUD_HIDE_ALL (1<<2)

// Hides Radar, Health & Armor, but adds Crosshair ( RHA in code )    
#define HUD_HIDE_RHA (1<<3)

// Hides Timer    
#define HUD_HIDE_TIMER (1<<4)

// Hides Money
#define HUD_HIDE_MONEY (1<<5)

// Hides Crosshair ( Cross in code )
#define HUD_HIDE_CROSS (1<<6)

// Draws additional Crosshair, NOT tested.
//#define HUD_DRAW_CROSS (1<<7)



new g_msgHideWeapon
new bool:g_bHideCAL
new bool:g_bHideFlash
//new bool:g_bHideAll
new bool:g_bHideRHA
new bool:g_bHideTimer
new bool:g_bHideMoney
new bool:g_bHideCross
//new bool:g_bDrawCross

new g_cvarHideCAL
new g_cvarHideFlash
//new g_cvarHideAll
new g_cvarHideRHA
new g_cvarHideTimer
new g_cvarHideMoney
new g_cvarHideCross
//new g_cvarDrawCross

public plugin_init() 

    
register_plugin(PLUGINVERSIONAUTHOR
    
g_msgHideWeapon get_user_msgid("HideWeapon")
    
register_event("ResetHUD""onResetHUD""b")
    
register_message(g_msgHideWeapon"msgHideWeapon")
    
    
g_cvarHideCAL register_cvar("amx_hud_hide_cross_ammo_weaponlist""0")
    
g_cvarHideFlash register_cvar("amx_hud_hide_flashlight""1")
//    g_cvarHideAll = register_cvar("amx_hud_hide_all", "0")    // NOT RECOMMENDED
    
g_cvarHideRHA register_cvar("amx_hud_hide_radar_health_armor""1")
    
g_cvarHideTimer register_cvar("amx_hud_hide_timer""1")
    
g_cvarHideMoney register_cvar("amx_hud_hide_money""0")
    
g_cvarHideCross register_cvar("amx_hud_hide_crosshair""0")
//    g_cvarDrawCross = register_cvar("amx_hud_draw_newcross", "0")

    
HudApplyCVars()


public 
onResetHUD(id)
{
    
HudApplyCVars()
    new 
iHideFlags GetHudHideFlags()
    if(
iHideFlags)
    {
        
message_begin(MSG_ONEg_msgHideWeapon_id)
        
write_byte(iHideFlags)
        
message_end()
    }    
}

public 
msgHideWeapon()
{
    new 
iHideFlags GetHudHideFlags()
    if(
iHideFlags)
        
set_msg_arg_int(1ARG_BYTEget_msg_arg_int(1) | iHideFlags)
}

GetHudHideFlags()
{
    new 
iFlags

    
if( g_bHideCAL )
        
iFlags |= HUD_HIDE_CAL
    
if( g_bHideFlash )
        
iFlags |= HUD_HIDE_FLASH
//    if( g_bHideAll )
//        iFlags |= HUD_HIDE_ALL
    
if( g_bHideRHA )
        
iFlags |= HUD_HIDE_RHA
    
if( g_bHideTimer )
        
iFlags |= HUD_HIDE_TIMER
    
if( g_bHideMoney )
        
iFlags |= HUD_HIDE_MONEY 
    
if( g_bHideCross )
        
iFlags |= HUD_HIDE_CROSS
//    if( g_bDrawCross )
//        iFlags |= HUD_DRAW_CROSS


    
return iFlags
}

HudApplyCVars()
{
    
g_bHideCAL bool:get_pcvar_num(g_cvarHideCAL)
    
g_bHideFlash bool:get_pcvar_num(g_cvarHideFlash)
//    g_bHideAll = bool:get_pcvar_num(g_cvarHideAll)
    
g_bHideRHA bool:get_pcvar_num(g_cvarHideRHA)
    
g_bHideTimer bool:get_pcvar_num(g_cvarHideTimer)
    
g_bHideMoney bool:get_pcvar_num(g_cvarHideMoney)
    
g_bHideCross bool:get_pcvar_num(g_cvarHideCross)
//    g_bDrawCross = bool:get_pcvar_num(g_cvarDrawCross)

And i wan't the timer to appear in the upper left corner of the screen
Thank you
firstride is offline
Catastrophe
Veteran Member
Join Date: Jul 2012
Location: somewhere between narnia
Old 07-05-2013 , 11:31   Re: Change hud timer position ?
Reply With Quote #9

Try this:-

PHP Code:
#include <amxmodx>

new mp_roundtime

public plugin_init()
{
       
register_plugin("blabla""1.0""Catastrophe"

       
mp_roundtime get_cvar_pointer("mp_roundtime")   
}

public 
client_connect(id)
{
       
set_task(2.0"checkhud"id+673)
}

public 
client_disconnect(id)
{
       
remove_task(id+673)
}

public 
checkhud(id)
{
       
id -= 673
 
       set_hudmessage
(851702550.00.006.02.0)
       
show_hudmessage(id"Round Time: %.f", (mp_roundtime*60) - get_gametime())

       
set_task(1.0"checkhud"id+673

__________________
You will find everything u need :-
Catastrophe is offline
firstride
Member
Join Date: Jun 2011
Old 07-05-2013 , 13:27   Re: Change hud timer position ?
Reply With Quote #10

No compile errors but it's not functional.

It appears: "Round Time: 2010086912"
firstride is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 12:04.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode