当前位置: 首页>>代码示例>>C#>>正文


C# Chapter.getScenes方法代码示例

本文整理汇总了C#中Chapter.getScenes方法的典型用法代码示例。如果您正苦于以下问题:C# Chapter.getScenes方法的具体用法?C# Chapter.getScenes怎么用?C# Chapter.getScenes使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Chapter的用法示例。


在下文中一共展示了Chapter.getScenes方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: loadIdentifiers

    /**
     * Reloads the identifiers with the given chapter data.
     *
     * @param chapter
     *            Chapter data which will provide the identifiers
     */
    public void loadIdentifiers(Chapter chapter)
    {
        // Clear the lists
        globalIdentifiers.Clear();
        generalSceneIdentifiers.Clear();
        sceneIdentifiers.Clear();
        cutsceneIdentifiers.Clear();
        bookIdentifiers.Clear();
        itemIdentifiers.Clear();
        atrezzoIdentifiers.Clear();
        npcIdentifiers.Clear();
        conversationIdentifiers.Clear();
        globalStateIdentifiers.Clear();
        macroIdentifiers.Clear();
        activeAreaIdentifiers.Clear();
        assessmentIdentifiers.Clear();
        adaptationIdentifiers.Clear();

        // Add scene IDs
        foreach (Scene scene in chapter.getScenes())
        {
            addSceneId(scene.getId());
            foreach (ActiveArea activeArea in scene.getActiveAreas())
            {
                if (activeArea.getId() != null && !activeArea.getId().Equals(""))
                    addActiveAreaId(activeArea.getId());
            }
        }

        // Add cutscene IDs
        foreach (Cutscene cutscene in chapter.getCutscenes())
            addCutsceneId(cutscene.getId());

        // Add book IDs
        foreach (Book book in chapter.getBooks())
            addBookId(book.getId());

        // Add item IDs
        foreach (Item item in chapter.getItems())
            addItemId(item.getId());

        // Add atrezzo items IDs
        foreach (Atrezzo atrezzo in chapter.getAtrezzo())
            addAtrezzoId(atrezzo.getId());

        // Add NPC IDs
        foreach (NPC npc in chapter.getCharacters())
            addNPCId(npc.getId());

        // Add conversation IDs
        foreach (Conversation conversation in chapter.getConversations())
            addConversationId(conversation.getId());

        // Add global state IDs
        foreach (GlobalState globalState in chapter.getGlobalStates())
            addGlobalStateId(globalState.getId());

        // Add macro IDs
        foreach (Macro macro in chapter.getMacros())
            addMacroId(macro.getId());

        // Add assessment rules ids and asssessmnet profiles ids
        foreach (AssessmentProfile profile in chapter.getAssessmentProfiles())
        {
            string name = profile.getName();
            addAssessmentProfileId(name);
            foreach (AssessmentRule rule in profile.getRules())
                this.addAssessmentRuleId(rule.getId(), name);
        }

        // Add adaptation rules ids and asssessmnet profiles ids
        foreach (AdaptationProfile profile in chapter.getAdaptationProfiles())
        {
            string name = profile.getName();
            addAdaptationProfileId(name);
            foreach (AdaptationRule rule in profile.getRules())
                this.addAdaptationRuleId(rule.getId(), name);
        }
    }
开发者ID:Synpheros,项目名称:eAdventure4Unity,代码行数:85,代码来源:IdentifierSummary.cs


注:本文中的Chapter.getScenes方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。