Save-Point

Full Version: Copy Events XP
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Code:
  def command_end
    # Clear list of event commands
    @list = nil
    # If main map event and event ID are valid
    if @main and @event_id > 0
      # Unlock event
      $game_map.events[@event_id].unlock
    end
  end

OK, that means the event ID got copied by an internal variable but the event itself got... Skull deleted? Confused
Why it happened [some time] before reaching that point, remains a mystery. Detective
That's the only explanation I can think off the top of my head without getting more information on the issue.
Anyway, let Dog Wulfo help you fix it. Tongue sticking out
BUMP
to version 1.4

Okay...

Well, I looked into it further.  The command_end method in the Interpreter class contains the 'unlock' parameter, but more was that kyonides made mention of an internal variable.  A clue?  Indeed.

The events that were copied were very much exact copies of the original event.  Unfortunately, that was the problem.  The copies were TOO exact.  The duplicates themselves contained data claiming to reside at the x/y coordinates of the original event.  But moreso, they still retained within them the original ID.   If there were fifteen events on the current map, and you created a duplicate, this 16th event should have an ID of 16 within. 

This was sadly not the case... at that time. Events need that internal ID value to function. While messages worked, event erasure, custom graphic changes for a specific 'copy' event would not take place, or anything specific to the event as an individual was non-functional

But now, the new code re-defines the ID of the event as well as its x/y coordinates within its structure before it is actively created and placed upon the map.
Everything seems to work fine now. :)
Pages: 1 2