Example #1
0
    public void LoadNewFighter(FighterInfo fInfo)
    {
        FighterDirName = fInfo.directory_name;

        loadedFighter    = fInfo;
        loadedActionFile = ActionFile.LoadActionsFromFile(FighterDirName, fInfo.actionFilePath);
        currentAction    = loadedActionFile.GetFirst();
        loadedSpriteInfo = SpriteInfo.LoadSpritesFromFile(FighterDirName, fInfo.spriteInfoPath);
        loadedSpriteInfo.LoadDirectory(FighterDirName, loadedFighter);

        FireModelChange();
    }
Example #2
0
    /// <summary>
    /// Fire all the changes to things that were modified in the editor
    /// </summary>
    private void Start()
    {
        Application.targetFrameRate = 60;

        //Load the fighter, then initialize it. We need to call the changed event here once the directory loads before we do the rest
        loadedFighter.LoadDirectory(FighterDirName);
        FighterInfoChangedEvent(loadedFighter);

        loadedActionFile = ActionFile.LoadActionsFromFile(FighterDirName, loadedFighter.actionFilePath);
        currentAction    = loadedActionFile.GetFirst();
        loadedSpriteInfo = SpriteInfo.LoadSpritesFromFile(FighterDirName, loadedFighter.spriteInfoPath);
        loadedSpriteInfo.LoadDirectory(FighterDirName, loadedFighter);
        FireModelChange();
    }