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

I need help for editing a plugin


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Watch.Me.Win
Junior Member
Join Date: May 2019
Old 05-28-2019 , 13:49   I need help for editing a plugin
Reply With Quote #1

Hello, i need help with "zp_extra_nemesis" it works fine it shows a hudmessage that the player bought nemesis but it's not too much visible for all players so i want it to show a chat message with red color to all players in the server that (the player) has bought nemesis. Thank you for your help
Attached Files
File Type: sma Get Plugin or Get Source (zp_extra_nemesis.sma - 215 views - 1.1 KB)

Last edited by Watch.Me.Win; 05-28-2019 at 14:50.
Watch.Me.Win is offline
gabuch2
AlliedModders Donor
Join Date: Mar 2011
Location: Chile
Old 05-28-2019 , 13:57   Re: I need help for editing a plugin
Reply With Quote #2

Line 29
Code:
new idname[33] get_user_name(player, idname, charsmax(idname)) set_hudmessage(200, 0, 0, 0.06, 0.39, 1, 6.0, 5.0) show_hudmessage(0, "%s Bought Nemesis !!!", idname)

>>

Code:
new idname[33], message[32] get_user_name(player, idname, charsmax(idname)) formatex(message, charsmax(message), "%s Bought Nemesis !!!", idname) for(new x = 1, x<=MaxClients;x++) {     if(is_user_connected(x))     {         set_hudmessage(200, 0, 0, 0.06, 0.39, 1, 6.0, 5.0)         show_hudmessage(x, message)     } }
Untested

Also this is the wrong section, if you need further help use the Suggestion / Requests or Scripting Help forums.
__________________

Last edited by gabuch2; 05-28-2019 at 14:03. Reason: Added a check to prevent sending to not-connected players
gabuch2 is offline
Watch.Me.Win
Junior Member
Join Date: May 2019
Old 05-28-2019 , 14:15   Re: I need help for editing a plugin
Reply With Quote #3

Quote:
Originally Posted by Gabe Iggy View Post
Line 29
Code:
new idname[33] get_user_name(player, idname, charsmax(idname)) set_hudmessage(200, 0, 0, 0.06, 0.39, 1, 6.0, 5.0) show_hudmessage(0, "%s Bought Nemesis !!!", idname)

>>

Code:
new idname[33], message[32] get_user_name(player, idname, charsmax(idname)) formatex(message, charsmax(message), "%s Bought Nemesis !!!", idname) for(new x = 1, x<=MaxClients;x++) {     if(is_user_connected(x))     {         set_hudmessage(200, 0, 0, 0.06, 0.39, 1, 6.0, 5.0)         show_hudmessage(x, message)     } }
Untested

Also this is the wrong section, if you need further help use the Suggestion / Requests or Scripting Help forums.
Hello thank you for your help but i guess it doesn't work (see the picture) "https://ibb.co/FbMwHvb"
Watch.Me.Win is offline
CrazY.
Veteran Member
Join Date: May 2015
Location: SP, Brazil
Old 05-28-2019 , 14:23   Re: I need help for editing a plugin
Reply With Quote #4

Quote:
Originally Posted by Gabe Iggy View Post
Line 29
Code:
new idname[33] get_user_name(player, idname, charsmax(idname)) set_hudmessage(200, 0, 0, 0.06, 0.39, 1, 6.0, 5.0) show_hudmessage(0, "%s Bought Nemesis !!!", idname)
There's nothing wrong with this part of the code. He said that want to show a red message in chat, not in hud. @OP, you need colorchat for that.

https://forums.alliedmods.net/showth...89#post1989389
Code:
#include <colorchat>

Code:
client_print_color(0, Red, "!t%s Bought Nemesis !!!", idname);

Besides, remove the .amxx file from post attachments.
__________________









Last edited by CrazY.; 05-28-2019 at 14:26.
CrazY. is offline
Old 05-28-2019, 14:25
Fuck For Fun
This message has been deleted by Fuck For Fun. Reason: MaxClient wrong way
Watch.Me.Win
Junior Member
Join Date: May 2019
Old 05-28-2019 , 14:47   Re: I need help for editing a plugin
Reply With Quote #5

Quote:
Originally Posted by CrazY. View Post
There's nothing wrong with this part of the code. He said that want to show a red message in chat, not in hud. @OP, you need colorchat for that.

https://forums.alliedmods.net/showth...89#post1989389
Code:
#include <colorchat>

Code:
client_print_color(0, Red, "!t%s Bought Nemesis !!!", idname);

Besides, remove the .amxx file from post attachments.
It shows me this (see the picture) "https://ibb.co/q5wr1ks" and btw i want to make it visible for all players not only the one who buy nemesis , and thank you already for your help

Last edited by Watch.Me.Win; 05-28-2019 at 14:48.
Watch.Me.Win is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 05-28-2019 , 14:51   Re: I need help for editing a plugin
Reply With Quote #6

Please make everyone's lives easier by NOT putting quotes around links, so people can actually click the link instead of manually copying it.
__________________

Last edited by OciXCrom; 05-28-2019 at 14:52.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
CrazY.
Veteran Member
Join Date: May 2015
Location: SP, Brazil
Old 05-28-2019 , 14:56   Re: I need help for editing a plugin
Reply With Quote #7

You've to download the include file and put it in amxmodx/scripting/include.
https://forums.alliedmods.net/showth...89#post1989389

It's already set to show to all players.
__________________









Last edited by CrazY.; 05-28-2019 at 14:57.
CrazY. is offline
Watch.Me.Win
Junior Member
Join Date: May 2019
Old 05-28-2019 , 15:16   Re: I need help for editing a plugin
Reply With Quote #8

Thank you so much it's working but the color is yellow
Watch.Me.Win is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 05-28-2019 , 15:20   Re: I need help for editing a plugin
Reply With Quote #9

If you're using AMXX 1.8.3 or higher, it will use "client_print_color" from AMXX, not from the include file. Either use ColorChat or even better - CromChat to make sure it will work for any AMXX version. Or try using ^3 directly instead of !t.
__________________

Last edited by OciXCrom; 05-28-2019 at 15:21.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
Watch.Me.Win
Junior Member
Join Date: May 2019
Old 05-28-2019 , 15:33   Re: I need help for editing a plugin
Reply With Quote #10

Thank you man ^3 is working good i got what i need and thank you all for your help (one last thing : what symbole for blue color)
Watch.Me.Win 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 22:19.


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