• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Pawn] How to solve this !? (Difficulty: Expert)
#1
I want to clear all the elements of an enumerator in an automatic manner using a stock so i won't need to update this stock everytime i add a new variable/element to the enum. But there is a problem, it works only if there are integer variables in the enum.?How can i make it work which?arrays and integers both :



Code:
enum player_data

{

? ? password [26],



? ? player_mode,



? ? spawned,



? ? kills,

? ? deaths

};





stock ClearPlayerData (playerid)

{

? ??for (new i = 0; i < sizeof (PlayerInfo []); i)

? ? {

? ? ? ? PlayerInfo [playerid][player_data : i] = 0;

? ? }

? ? return 1;

}
  Reply


Messages In This Thread
How to solve this !? (Difficulty: Expert) - by mouiz - 2019-07-07, 06:05 PM

Forum Jump: