コード例 #1
0
ファイル: ProgressScript.cs プロジェクト: TAPeri/WordsMatter
    private void activateQuestBar(EventSlot selectedEvent)
    {
        questBar.gameObject.SetActive(true);
        QuestBarScript qBarScript = questBar.gameObject.AddComponent<QuestBarScript>();
        qBarScript.init(selectedEvent.getQuestGiverCharID(),selectedEvent.getQuestReceiverCharID(),selectedEvent.getApplicationID());//selectedEvent.getApplicationID()

        showQuestBar = true;

        showGBIcon = false;
        ghostbookIcon.gameObject.SetActive(showGBIcon);

        //if(showNarrativeIcon){
            //narrativeIcon.gameObject.SetActive(false);
        //}

        worldView.clearUnclickable();
        worldView.addUnclickable(questBarUiBounds);
        worldView.addUnclickable(questBarAbortBtnUiBounds);
    }
コード例 #2
0
ファイル: ProgressScript.cs プロジェクト: TAPeri/WordsMatter
    public void launchQuest(EventSlot e,string source,Mode m)
    {
        //Debug.Log("LA: "+e.getEncounter().getLanguageArea()+" DF:"+e.getEncounter().getDifficulty());

        gbDisp.closeGhostbook();
        GBOpen = false;
        activateWVInterface();

        if(checkLevelCorrectness(e.getEncounter().getLevel(),e.getApplicationID(),e.getEncounter().getLanguageArea())){

            launcherMode = m;
            launcherDetails = source;
            selectedEvent = e;

            acServCom.setActivityParameters(selectedEvent.getEncounter().getLocation(),
                                            selectedEvent.getEncounter().getDifficulty(),
                                            selectedEvent.getEncounter().getLanguageArea(),
                                            wvServCom.getUserID(),
                                            0,
                                            selectedEvent.getEncounter().getLevel(),
                                            launcherMode);

            acServCom.load();

            if(m ==Mode.ADVENTURE){//walk
                activateQuestBar(selectedEvent);
                worldView.sendQuestGiverToCharacter(selectedEvent.getQuestGiverCharID(),selectedEvent.getQuestReceiverCharID());
                worldView.moveToCharacter(selectedEvent.getQuestReceiverCharID());
            }else{//start immediate

                deactivateWVInterface();
                worldView.setLoadingIconVisibility(true);
                startRequested = true;

            }

        }else{
            WorldViewServerCommunication.setError("Problem on difficulty ("+e.getEncounter().getLanguageArea()+","+e.getEncounter().getDifficulty()+")\nLevel "+e.getEncounter().getLevel()+" no supported");

        }
    }