Interface ScriptedEventFactory<G extends GameObject<G,​A,​R>,​A extends MapArchObject<A>,​R extends Archetype<G,​A,​R>>

    • Method Detail

      • newScriptedEvent

        @NotNull
        @NotNull ScriptedEvent<G,​A,​R> newScriptedEvent​(int eventType,
                                                                   @NotNull
                                                                   @NotNull java.lang.String pluginName,
                                                                   @NotNull
                                                                   @NotNull java.lang.String scriptPath,
                                                                   @NotNull
                                                                   @NotNull java.lang.String options)
                                                            throws UndefinedEventArchetypeException
        Creates a new ScriptedEvent instance.
        Parameters:
        eventType - type of the event
        pluginName - name of the plugin
        scriptPath - path to the file for this event
        options - the options for this event
        Returns:
        the new instance
        Throws:
        UndefinedEventArchetypeException - In case there is no Archetype to create a ScriptedEvent.
      • newScriptedEvent

        @NotNull
        @NotNull ScriptedEvent<G,​A,​R> newScriptedEvent​(G event)
        Creates a new ScriptedEvent instance.
        Parameters:
        event - the event game object
        Returns:
        the new instance
      • newEventGameObject

        @NotNull
        G newEventGameObject​(int eventType)
                      throws UndefinedEventArchetypeException
        Return a new event game object for a given event type.
        Parameters:
        eventType - the event type
        Returns:
        the new event game object
        Throws:
        UndefinedEventArchetypeException - if the event game object cannot be created