Quote:
Originally Posted by Aluta
Hi guys
I want to delete one of the blocks from the plugin but i get every time a error. Plz Help
Original Plugin
PHP Code:
new const gszBlockNames[gBlockMax][32] = { "Platform", "Bunnyhop", "Damage", "Healer", "No Fall Damage", "Ice", "Trampoline", "Speed Boost", "Invincibility", "Stealth", "Death", "Nuke", "Camouflage", "Low Gravity", "Fire", "Slap", "Random", "Honey", "CT Barrier", "T Barrier", "Boots Of Speed", "Glass", "Bunnyhop (No slow down)", "Auto Bunnyhop" };[/code]Error Plugin (without "Invincibility")
I deleted all of the "Invincibility" things out of the plugin [code]new const gszBlockNames[gBlockMax][32] = { "Platform", "Bunnyhop", "Damage", "Healer", "No Fall Damage", "Ice", "Trampoline", "Speed Boost", "Stealth", "Death", "Nuke", "Camouflage", "Low Gravity", "Fire", "Slap", "Random", "Honey", "CT Barrier", "T Barrier", "Boots Of Speed", "Glass", "Bunnyhop (No slow down)", "Auto Bunnyhop" };
If i try "new const gszBlockNames[gBlockMax][32] =" i get "error 052: multi-dimensional arrays must be fully initialized"
& if i try "new const gszBlockNames[gBlockMax][32] =" then i get "error 018 initialization data exceeds declared size"
Whats wrong?
I have no idea more.
Plz Help
Sry, for the bad english.
|
Now when you start changing plugins, then it's very important that you first learn about PAWN's basics...i've been there, dont that and regretted that i even started changing something.
Anyways, new const gszBlockNames[gBlockMax]
[32]
As you can see, then gszBlockNames is two dimensional array, and the number 32 represents the ammount of data in the array. If you remove "Invincibility", then there will be only 31 items in array and that means that you get error, because compiler is told that there MUST be 32 items in array.
Mean that you need to change:
gszBlockNames[gBlockMax][32]
to
gszBlockNames[gBlockMax][31]
This thread will get trashed soon, but i hope that you get the point i was trying to explain.
Edit:
sh*t i think i totally failed, but you can try.
__________________