Raised This Month: $ Target: $400
 0% 

Crosshair msg + AWP bug


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
xPaw
Retired AMX Mod X Moderator
Join Date: Jul 2008
Old 03-09-2009 , 10:11   Crosshair msg + AWP bug
Reply With Quote #1

hello, i'm having an bug, i'm removing from hud the money and roundtimer, and for bug fix i'm sending msg chrosshair to 0, but when i'm in awp, my chrosshair are changing, i'm getting lines, and my dot removes..

PHP Code:
public eResetHUDid ) {
    if( !
is_user_botid ) ) {
        
message_beginMSG_ALLg_msgHideWeapon_id );
        
write_byte( (1<<1<<5) );
        
message_end();
        
        if ( !(
CS_SET_FIRST_ZOOM <= cs_get_user_zoom(id) <= CS_SET_SECOND_ZOOM) ) {
            
message_beginMSG_ALLg_msgCrosshair_id );
            
write_byte);
            
message_end();
        }
    }

i'm tryed cs_get_user_zoom, but it didnt worked, maybe i'm did it wrong.
__________________
xPaw is offline
anakin_cstrike
Veteran Member
Join Date: Nov 2007
Location: Romania
Old 03-09-2009 , 10:20   Re: Crosshair msg + AWP bug
Reply With Quote #2

Have you trying checking player's weapons? and sending the message only if he doesn't holds an awp?
__________________

anakin_cstrike is offline
xPaw
Retired AMX Mod X Moderator
Join Date: Jul 2008
Old 03-09-2009 , 10:25   Re: Crosshair msg + AWP bug
Reply With Quote #3

maybe he holds awp, but he is not in zoom, resethud sended, and he got crosshair on awp? cheating
__________________
xPaw is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 03-09-2009 , 12:49   Re: Crosshair msg + AWP bug
Reply With Quote #4

MSG_ALL ?
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
xPaw
Retired AMX Mod X Moderator
Join Date: Jul 2008
Old 03-09-2009 , 13:16   Re: Crosshair msg + AWP bug
Reply With Quote #5

i know... i changed MSG_ONE_UNRELIABLE, but that doesnt change anything
__________________
xPaw is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 03-09-2009 , 13:43   Re: Crosshair msg + AWP bug
Reply With Quote #6

Try client_cmd(id, "crosshair 1"), it's really horrible but blended to your code it won't be noticable
Plus it could work.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
xPaw
Retired AMX Mod X Moderator
Join Date: Jul 2008
Old 03-09-2009 , 13:57   Re: Crosshair msg + AWP bug
Reply With Quote #7

maybe there better way ? or get that cs_Get_user_zoom to work

edit: also your way didnt worked, i just tested on server
__________________
xPaw is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 03-09-2009 , 14:12   Re: Crosshair msg + AWP bug
Reply With Quote #8

I used this without any bug with snipers :
PHP Code:
public Event_ResetHUD(id)
{
    
message_begin(MSG_ONE_UNRELIABLEget_user_msgid("HideWeapon"), _id)
    
write_byte((1<<4)|(1<<5))
    
message_end()
        
    
message_begin(MSG_ONE_UNRELIABLEget_user_msgid("Crosshair"), _id)
    
write_byte(0)
    
message_end()


Your bug should come from something else, make sure you type crosshair 1 in your game console.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
xPaw
Retired AMX Mod X Moderator
Join Date: Jul 2008
Old 03-09-2009 , 14:28   Re: Crosshair msg + AWP bug
Reply With Quote #9

i have smae code, just get_user_msgid in init, but i can make screenshot how it before and after...
__________________
xPaw is offline
Reply


Thread Tools
Display Modes

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 08:54.


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