$gameMap.events() is a default function in rpgmaker to return an array of events for the current map. You should be able to access it.
Also when wanting to access $dataMap.events, you can access from the event object returned from that $gameMap.events() array with the event() function.
eg. the function in the event is:
Game_Event.prototype.event = function() {
return $dataMap.events[this._eventId];
};
So you can reference the events that have been created in the $gameMap object and still get the $dataMap.events info (as my spawn plugin changes this function to be able to access the correct map for this data).
Hope this makes sense and helps.
Also when wanting to access $dataMap.events, you can access from the event object returned from that $gameMap.events() array with the event() function.
eg. the function in the event is:
Game_Event.prototype.event = function() {
return $dataMap.events[this._eventId];
};
So you can reference the events that have been created in the $gameMap object and still get the $dataMap.events info (as my spawn plugin changes this function to be able to access the correct map for this data).
Hope this makes sense and helps.
So, what should I do to make my game work fine?