Raised This Month: $ Target: $400
 0% 

Compile warnings


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
amxxsean
Member
Join Date: Feb 2005
Old 03-29-2005 , 11:23   Compile warnings
Reply With Quote #1

I just made my second script (untested) and it compiles successfully but gives me some errors. The picture of the error is attached to this post and heres the code.
Code:
#include <amxmodx> public plugin_init() {     register_plugin("kickslay","0.2","amxxsean")     register_concmd("amx_kill","do_kill",ADMIN_KICK," user slays the specified user")     register_concmd("amx_boot","do_boot",ADMIN_KICK," user boots the specified user") } public do_kill(id) {     if (!(get_user_flags(id)&ADMIN_KICK)) {         console_print(id,"[AMXX] You do not have access to this command")         return PLUGIN_HANDLED     }     if (read_argc() == 0) {         console_print(id,"[AMXX] You must select a user to slay")         return PLUGIN_HANDLED     }     new user[32], uid     read_argv(1,user,32)     uid = find_player("bh",user)     if (uid == 0) {         console_print(id,"[AMXX] No such user")         return PLUGIN_HANDLED     }     client_cmd(uid,"kill")     client_print(uid,print_chat,"[AMXX] You have been slain by an admin!")     console_print(id,"[AMXX]Player was slain!")         return PLUGIN_HANDLED         }         public do_boot(id) {         if (!(get_user_flags(id)&ADMIN_KICK)) {         console_print(id,"[AMXX] You do not have access to this command")         return PLUGIN_HANDLED         }         if (read_argc() == 0) {         console_print(id,"[AMXX] You must select a user to boot")         return PLUGIN_HANDLED     }         new userboot[32], usid         read_argv(1,userboot,32)         usid = find_player("bh",userboot)         if (usid == 0) {             console_print(id,"[AMXX] No such user")         return PLUGIN_HANDLED         }         client_cmd(usid,"say","IMGAY!BUHBYENOW!")         client_cmd(usid,"disconnect")         console_print(usid,"[AMXX] ADMIN JUST BOOTED YOUR ASS!")         console_print(id,"[AMXX] User booted from server")         return PLUGIN_HANDLED     }

Dont try to steal my super cool kickslay script!
Attached Thumbnails
Click image for larger version

Name:	warnings.png
Views:	114
Size:	17.0 KB
ID:	2641  
__________________
DID SOMEBODY DIAL TEH AWPERAT0RZ?
www.awpz.tk
NOW ACCEPTING MEMBERS!
amxxsean is offline
Belsebub
Senior Member
Join Date: Feb 2005
Location: Sweden
Old 03-29-2005 , 11:25  
Reply With Quote #2

Code:
 #include <amxmodx>  public plugin_init() {     register_plugin("kickslay","0.2","amxxsean")     register_concmd("amx_kill","do_kill",ADMIN_KICK," user slays the specified user")     register_concmd("amx_boot","do_boot",ADMIN_KICK," user boots the specified user")  }  public do_kill(id) {     if (!(get_user_flags(id)&ADMIN_KICK)) {         console_print(id,"[AMXX] You do not have access to this command")         return PLUGIN_HANDLED     }     if (read_argc() == 0) {         console_print(id,"[AMXX] You must select a user to slay")         return PLUGIN_HANDLED     }     new user[32], uid     read_argv(1,user,32)     uid = find_player("bh",user)     if (uid == 0) {         console_print(id,"[AMXX] No such user")         return PLUGIN_HANDLED     }     client_cmd(uid,"kill")     client_print(uid,print_chat,"[AMXX] You have been slain by an admin!")     console_print(id,"[AMXX]Player was slain!")     return PLUGIN_HANDLED  }  public do_boot(id) {     if (!(get_user_flags(id)&ADMIN_KICK)) {         console_print(id,"[AMXX] You do not have access to this command")         return PLUGIN_HANDLED     }     if (read_argc() == 0) {         console_print(id,"[AMXX] You must select a user to boot")         return PLUGIN_HANDLED     }     new userboot[32], usid     read_argv(1,userboot,32)     usid = find_player("bh",userboot)     if (usid == 0) {         console_print(id,"[AMXX] No such user")         return PLUGIN_HANDLED     }     client_cmd(usid,"say","IMGAY!BUHBYENOW!")     client_cmd(usid,"disconnect")     console_print(usid,"[AMXX] ADMIN JUST BOOTED YOUR ASS!")     console_print(id,"[AMXX] User booted from server")     return PLUGIN_HANDLED  }
Belsebub is offline
amxxsean
Member
Join Date: Feb 2005
Old 03-29-2005 , 11:29  
Reply With Quote #3

Thanks.
__________________
DID SOMEBODY DIAL TEH AWPERAT0RZ?
www.awpz.tk
NOW ACCEPTING MEMBERS!
amxxsean is offline
Belsebub
Senior Member
Join Date: Feb 2005
Location: Sweden
Old 03-29-2005 , 11:36  
Reply With Quote #4

i used avalanche's auto indenter
Belsebub is offline
nightscreem
Veteran Member
Join Date: Jul 2004
Location: Belgium
Old 03-29-2005 , 11:40  
Reply With Quote #5

warnings are not bad sometimes they are to hard to fix just
try if it works
__________________
- Bye bye!
nightscreem is offline
amxxsean
Member
Join Date: Feb 2005
Old 03-29-2005 , 11:41  
Reply With Quote #6

Really? I'm using crimson editor, is his auto indenter a seperate program?
[EDIT] It works fine but did I do something incorrect with the say command? The user doesn't say "IMGAYBUHBYENOW!" when they get kicked.
__________________
DID SOMEBODY DIAL TEH AWPERAT0RZ?
www.awpz.tk
NOW ACCEPTING MEMBERS!
amxxsean is offline
nightscreem
Veteran Member
Join Date: Jul 2004
Location: Belgium
Old 03-29-2005 , 11:45  
Reply With Quote #7

when should it say that
__________________
- Bye bye!
nightscreem is offline
amxxsean
Member
Join Date: Feb 2005
Old 03-29-2005 , 11:47  
Reply With Quote #8

Right before the user disconnects from a kick.
(anyone on the server should see this message)
__________________
DID SOMEBODY DIAL TEH AWPERAT0RZ?
www.awpz.tk
NOW ACCEPTING MEMBERS!
amxxsean 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 09:49.


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