Exemplo n.º 1
0
    public InGameBaseObj AddSkill(int skill, enMSCamp camp)
    {
        gameObjInstanceId++;
        SkillConf  conf = ConfigManager.skillConfManager.dataMap[skill];
        GameObject obj  = Resources.Load(conf.filepath) as GameObject;

        obj = InGameManager.Instantiate(obj);
        InGameBaseObj objscript = obj.GetComponent <InGameBaseObj>();

        objscript.Init(gameObjInstanceId, skill, camp);
        addList.Add(objscript);
        return(objscript);
    }