how to set one id
hi, i have one problem...
i have this: Code:
in = Code:
and i have the problem of the ID of the class and the problem in Cname[Cid] = class_name i want to do this = Cname[Cid][] = "here the text of class_name in the native" |
Re: how to set one id
Either you hardcode it.
Code:
Or you look into dynamic arrays. |
Re: how to set one id
For strings, use param_convert
PHP Code:
|
Re: how to set one id
eh...
Code:
and the last i dont understend xD |
Re: how to set one id
When using register_native() with style set to 1, you have to use param_convert() to be able to read the strings.
I don't know the technical reason of it. You need to index all of the variables. Cexpe, Cvida, Cchal as well assuming they are unique to each class. However you don't have to create a second dimension of 33 since they're not arrays. |
Re: how to set one id
Code:
like this? |
Re: how to set one id
Re-add the [33] to Cname and Cdec since those are strings.
You have to define which class index of Cname and Cdesc that has to be written to. MAX_CLASSES-1 will always remain the same meaning you will overwrite every time you use this native. I'm guessing you don't want that. You need global/static variable that is increasing at the end of this native. |
Re: how to set one id
yes... i want do the same than Cod-Mod and ZP...
1) get all .amxx in "classes.ini" 2) with one menu open the .amxx etc... but i donw know how... maybe... this? Code:
|
Re: how to set one id
That code looks good. Didn't understand 1 & 2.
|
Re: how to set one id
i want do the same than Cod-Mod ...
its register the plugin whitout add it in plugins.ini this will works? Code:
|
| All times are GMT -4. The time now is 21:07. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.