package gameEngine;

import gameplayer.GameEventManager;

import java.util.Arrays;
import java.util.List;

public abstract class GameEvent {
	protected int sourceObjectId;
	protected List<Integer> recipientObjectIds;
	protected List<GameEventAction> actions;
	protected List<String> paramaters;
	protected boolean activated;

	public GameEvent(int sourceObjectId, List<Integer> recipientObjectIds,
			List<String> parameters) throws InvalidEventException {
		this.sourceObjectId = sourceObjectId;
		this.recipientObjectIds.addAll(recipientObjectIds);
		this.activated = false;
	}

	public boolean check(GameEventManager manager) {
		if (!activated && eventHappened()) {
			trigger(manager);
			activated = true;
			return true;
		}
		return false;
	}

	public void addAction(GameEventAction... actions) {
		this.actions.addAll(Arrays.asList(actions));
	}

	protected void trigger(GameEventManager manager) {
		for (GameEventAction action : actions) {
			action.act();
		}
	}

	protected abstract boolean eventHappened();
}

@@ -958,16 +958,23 @@
 ion.act(
+manager
 );%0A%09%09%7D%0A%09

Fix GameEvent#trigger()