Esempio n. 1
0
    public void SetContext(Object target)
    {
        GameObj = ((Transform)target).gameObject;

        if (GameObjectSetting == null) {
            GameObjectSetting = GetStoredGameObjectSetting();
        }
    }
Esempio n. 2
0
    public void SetContext(Object target)
    {
        GameObj = ((Transform)target).gameObject;

        if (GameObjectSetting == null)
        {
            GameObjectSetting = GetStoredGameObjectSetting();
        }
    }
Esempio n. 3
0
    private MAGOSetting GetStoredGameObjectSetting()
    {
        MAGOSetting setting;

        if (PersistentSettings.ContainsKey(GameObj)) {
            setting = PersistentSettings[GameObj];
        } else {
            setting = new MAGOSetting(GameObj);
            PersistentSettings.Add(GameObj, setting);
        }

        return setting;
    }
Esempio n. 4
0
    private MAGOSetting GetStoredGameObjectSetting()
    {
        MAGOSetting setting;

        if (PersistentSettings.ContainsKey(GameObj))
        {
            setting = PersistentSettings[GameObj];
        }
        else
        {
            setting = new MAGOSetting(GameObj);
            PersistentSettings.Add(GameObj, setting);
        }

        return(setting);
    }