void PerformActionWithEventInfo(Event_Type eventType, EventInfo info)
 {
     GameEventSystem.DoEvent(
         eventType,
         info
         );
 }
Exemplo n.º 2
0
    public override void PerformAction()
    {
        ColorChangeInfo valueChangeAction = new ColorChangeInfo();

        valueChangeAction.newColor = color;
        GameEventSystem.DoEvent(
            thisEvent_Type,
            valueChangeAction
            );
    }
Exemplo n.º 3
0
    static void createOnJobRegisterCall(Job job)
    {
        JobRegisterInfo jobInfo = new JobRegisterInfo();

        jobInfo.job = job;
        GameEventSystem.DoEvent(
            Event_Type.JOB_REGISTERED_TO_PLAYER,
            jobInfo
            );
    }
Exemplo n.º 4
0
    //public PlayerStat stats;

    public override void PerformAction()
    {
        StatChangeInfo valueChangeAction = new StatChangeInfo();

        //valueChangeAction.playerStat = stats;
        GameEventSystem.DoEvent(
            thisEvent_Type,
            valueChangeAction
            );
    }
    public override void PerformAction()
    {
        WelfareApplyFormInfo form = new WelfareApplyFormInfo();

        form.typeofWelfare = typeofWelfare;
        thisEvent_Type     = Event_Type.PLAYER_WANTS_WELFARE;
        GameEventSystem.DoEvent(
            thisEvent_Type,
            form
            );
    }
    public override void PerformAction()
    {
        EventRegisterInfo eventRegister = new EventRegisterInfo();
        GameEvent         @event        = new GameEvent(eventToRise, true, eventFireTime);

        eventRegister.Event = @event;
        thisEvent_Type      = Event_Type.EVENT_REGISTER;
        GameEventSystem.DoEvent(
            thisEvent_Type,
            eventRegister
            );
    }
    public override void PerformAction()
    {
        FloatChangeInfo valueChangeAction = new FloatChangeInfo();

        valueChangeAction.changeofFloat = amount;
        thisEvent_Type = Event_Type.FLOAT_CHANGE;

        GameEventSystem.DoEvent(
            thisEvent_Type,
            valueChangeAction
            );
    }
Exemplo n.º 8
0
    public void FireFlag()
    {
        FlagFireInfo flagInfo = new FlagFireInfo();

        flagInfo.flag = this;
        Debug.Log("FLAG FIRE: " + FlagName);
        GameEventSystem.DoEvent(
            Event_Type.FLAG_FIRE,
            flagInfo
            );
        OnFlagFire.Invoke(this);
    }
Exemplo n.º 9
0
    public static void changePlayerMoney(float amount)
    {
        FloatChangeInfo valueChangeAction = new FloatChangeInfo();

        valueChangeAction.changeofFloat = amount;

        Debug.Log("Pelaajalle tapahtui rahamuutos: määrä on " + valueChangeAction.changeofFloat);
        GameEventSystem.DoEvent(
            Event_Type.FLOAT_CHANGE,
            valueChangeAction
            );
    }
Exemplo n.º 10
0
    public override void PerformAction()
    {
        CameraAngleChangeInfo valueChangeAction = new CameraAngleChangeInfo();

        valueChangeAction.changeofFloat = angle();
        valueChangeAction.increments    = Turns;
        thisEvent_Type = Event_Type.CAMERA_TURN;
        GameEventSystem.DoEvent(
            thisEvent_Type,
            valueChangeAction
            );
    }
Exemplo n.º 11
0
    public void CallElement() //Kutsutaan ui-elementti x peliin jossakin click eventissä esim.
    {
        UiElementCall uiCall = new UiElementCall();

        uiCall.elementToCall = OnClickResourceToCall;
        uiCall.elementParent = OnClickResourceParent;

        GameEventSystem.DoEvent(
            Event_Type.UI_ELEMENT_CALL,
            uiCall
            );
    }
    public override void PerformAction()
    {
        ExtraIncomeInfo valueChangeAction = new ExtraIncomeInfo();

        valueChangeAction.extraIncomeAmount = amount;
        valueChangeAction.isAnExtra         = true;
        thisEvent_Type = Event_Type.EXTRA_INCOME;

        GameEventSystem.DoEvent(
            thisEvent_Type,
            valueChangeAction
            );
    }
    public override void PerformAction()
    {
        SimStatInfo SimChangeAction = new SimStatInfo();

        SimChangeAction.SimStatName = simStatType;
        SimChangeAction.StatChange  = StatChangeAmount;
        thisEvent_Type = Event_Type.SIMSTAT_CHANGE;

        GameEventSystem.DoEvent(
            thisEvent_Type,
            SimChangeAction
            );
    }
Exemplo n.º 14
0
    static void comfortChange(float change)
    {
        SimStatInfo SimChangeAction = new SimStatInfo();

        SimChangeAction.SimStatName = SimStatType.Comfortableness;
        SimChangeAction.StatChange  = change;


        GameEventSystem.DoEvent(
            Event_Type.SIMSTAT_CHANGE,
            SimChangeAction
            );
    }
    public override void PerformAction()
    {
        EventRaise eventRaise = new EventRaise();

        eventRaise.InCaseSpecificEvent = eventToRise;
        if (eventToRise == null)
        {
            eventRaise.SpecificEventRaise = false;
        }
        thisEvent_Type = Event_Type.TRIGGER_EVENT;
        GameEventSystem.DoEvent(
            thisEvent_Type,
            eventRaise
            );
    }
Exemplo n.º 16
0
    public static void RaiseAnEvent(RandomEventScriptable raise = null)
    {
        EventRaise randomEvent = new EventRaise
        {
            InCaseSpecificEvent = raise
        };

        if (raise != null)
        {
            randomEvent.SpecificEventRaise = true;
        }
        GameEventSystem.DoEvent(
            Event_Type.TRIGGER_EVENT,
            randomEvent
            );
    }
Exemplo n.º 17
0
    public void applyForJob()
    {
        if (GlobalGameFlags.GetFlag("TUTORIAL_FIRSTJOB") == null)
        {
            Flag flag = new Flag("TUTORIAL_FIRSTJOB", 0, true);
            flag.FireFlag();
        }

        JobInfo jobInfo = new JobInfo();

        jobInfo.jobNotice = _jobNotice;

        GameEventSystem.DoEvent(
            Event_Type.JOB_APPLY,
            jobInfo
            );
    }