Raised This Month: $12 Target: $400
 3% 

weird problem


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Plut0
Junior Member
Join Date: Mar 2021
Location: United States
Old 01-15-2022 , 20:20   weird problem
Reply With Quote #1

Im using a respawn menu with this buymenu from https://forums.alliedmods.net/showthread.php?t=87776
im pretty sure they use natives from cstrike.inc but in game when i try to buy respawn it says i dont have the money and shows $0 in the respawn menu mean while i have like 20k in the bottom right
Attached Thumbnails
Click image for larger version

Name:	Capture.PNG
Views:	37
Size:	66.1 KB
ID:	193133  
Attached Files
File Type: sma Get Plugin or Get Source (1zp_res.sma - 52 views - 4.7 KB)
File Type: sma Get Plugin or Get Source (zp_cs_buymenu (2).sma - 34 views - 58.7 KB)
__________________

Last edited by Plut0; 01-16-2022 at 12:00. Reason: lol uploaded config for buymenu and not sma
Plut0 is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 01-16-2022 , 08:17   Re: weird problem
Reply With Quote #2

The plugin from the link sets the player's money to 0 and uses a fake message to display a different amount in the bottom-right corner that cannot be retrieved with cstrike.inc's money functions.

Try replacing every instance of sending the "g_MsgMoney" message in the .sma like this:

Code:
message_begin(MSG_ONE_UNRELIABLE, g_MsgMoney, _, id) write_long(zp_cs_player_money[id]); write_byte(1); message_end();

To:

Code:
emessage_begin(MSG_ONE_UNRELIABLE, g_MsgMoney, _, id) ewrite_long(zp_cs_player_money[id]); ewrite_byte(1); emessage_end();

Just add "e" in front of every function between "message_begin" and "message_end".

The difference between "message" and "emessage" is that the latter can be detected by other plugins.
__________________

Last edited by OciXCrom; 01-16-2022 at 08:21.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
Plut0
Junior Member
Join Date: Mar 2021
Location: United States
Old 01-16-2022 , 10:21   Re: weird problem
Reply With Quote #3

Quote:
Originally Posted by OciXCrom View Post
The plugin from the link sets the player's money to 0 and uses a fake message to display a different amount in the bottom-right corner that cannot be retrieved with cstrike.inc's money functions.

Try replacing every instance of sending the "g_MsgMoney" message in the .sma like this:

Code:
message_begin(MSG_ONE_UNRELIABLE, g_MsgMoney, _, id) write_long(zp_cs_player_money[id]); write_byte(1); message_end();

To:

Code:
emessage_begin(MSG_ONE_UNRELIABLE, g_MsgMoney, _, id) ewrite_long(zp_cs_player_money[id]); ewrite_byte(1); emessage_end();

Just add "e" in front of every function between "message_begin" and "message_end".

The difference between "message" and "emessage" is that the latter can be detected by other plugins.
I dont know if im blind but I cant find it in neither .sma even tried ctrl + f to search
__________________
Plut0 is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 01-16-2022 , 10:54   Re: weird problem
Reply With Quote #4

I'm talking about the buymenu from the link.
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
Plut0
Junior Member
Join Date: Mar 2021
Location: United States
Old 01-16-2022 , 12:05   Re: weird problem
Reply With Quote #5

tried it still the same..
__________________
Plut0 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 20:12.


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