problem with a plugin
hi.
Can anyone check this plugin and say whats wrong with it?? :D When i compile it, i get two errors: Code:
/home/groups/amxmodx/tmp3/textFLiayE.sma(38) : error 035: argument type mismatch (argument 2)Also helpful would be to make an array instead of string clantag. I know those could be stupid questions but im new with amxx scripting. I couldn't find any plugin that would do something like this, so I tried to make it ;D. I used to be only a webdeveloper ;P Here's what I made: (it should add a "[Freelancer]" tag in front of nick if u dont have "[RoD]" tag in it.) Code:
#include <amxmodx>Code:
new Array:clantags = {"[RoD]", "[SV]", "Cookies|"}Code:
public check_name(id,username[])i gives an error with argument type mismatch in if (contain(... but when I type clantags[i] it makes such errors: Code:
/home/groups/amxmodx/tmp3/textFcaKJe.sma(41) : error 028: invalid subscript (not an array or too many subscripts): "clantags" |
Re: problem with a plugin
#1
PHP Code:
#2 http://forums.alliedmods.net/showthread.php?t=6481 |
Re: problem with a plugin
clantags is a cellarray, not a simple array. Cellarray's are done differently. That is why you are getting an error.
|
Re: problem with a plugin
Quote:
|
Re: problem with a plugin
There is no String: data type. It is a simple array. This should help you understand how to do it, http://wiki.alliedmods.net/Pawn_Tutorial
|
Re: problem with a plugin
it works ;D thanks guys :)
only last question: is it posible to make a regular expression?? I've read about regex_amxx module, but it gives only 3 functions and in need something like: Code:
//PERL code:(compilation errors: ) Code:
/home/groups/amxmodx/tmp3/textce83a5.sma(38) : warning 211: possibly unintended assignment |
Re: problem with a plugin
|
Re: problem with a plugin
Thanks for url ;)
Does anyone knows why code below gives an error? It's something with this regular expression, but i dont know what exactly... Code:
new Regex:was_tag_found = regex_match(username, "^(\{|\[|\}|\]|\(|\)|\+|-|=|:|\.|\^|\*)*[A-Za-z0-9!@#$%&;:.]{2,}(\{|\[|\}|\]|\(|\)|\+|-|=|:|\.|\^|\*)*.*$", regex_num, regex_error, 127); |
| All times are GMT -4. The time now is 01:39. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.