IS4Code / PawnPlus

A SA-MP plugin enhancing the capabilities of the Pawn programming language

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Declaring Map on the global scope?

Ino-Bagaric opened this issue · comments

How am I supposed to declare global map?

new Map:myMap = map_new(); // throws an error on global scope
commented

You need to declare the variable and assign it in the entry function in the script, main or OnFilterScriptInit.

new Map:myMap;

public OnFilterScriptInit()
{
    myMap = map_new();
}