//:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: // PROTECTED FUNCTION //:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: // @Brief : Add resource // @Param : pReader => Stream reader // : pScript => Script container // : pStr => String of one line protected override void Add(StreamReader pReader, KrCharagekiScript pScript, string pStr) { pStr = pScript.ConvertConstVariable(pStr); KrDebug.Log("Add resource path => " + pStr, typeof(KrCharagekiResource)); m_pResourceFilePaths.Add(pStr); }
//:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: // PUBLIC FUNCTION //:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: // @Brief : Load command // @Param : pScript => Script container // : pCommand => String of command public void Load(KrCharagekiScript pScript, string pCommand) { string[] pSplit = pCommand.Split(new char[] { ' ' }, System.StringSplitOptions.RemoveEmptyEntries); KrDebug.Log("Add command => " + pSplit[0], typeof(KrCharagekiCommand)); // Since array 0 is the command name, it starts from the first for (int sIndex = 1; sIndex < pSplit.Length; sIndex++) { KrDebug.Log(" option => " + pSplit[sIndex], typeof(KrCharagekiCommand)); string[] pKeyValue = pSplit[sIndex].Split(new char[] { '=' }); KrCharagekiCommandOption pOption = new KrCharagekiCommandOption(pKeyValue[0], pScript.ConvertConstVariable(pKeyValue[1])); m_pOptions.Add(pOption); } }