Ejemplo n.º 1
0
        /// <summary>
        /// Load a single file
        /// </summary>
        /// <param name="path">Path of the file</param>
        /// <returns></returns>
        private CinematicScript LoadFile(string path)
        {
            Lua lua = new Lua();

            Thread.Sleep(50); // this bug is really weird, we need to put a delay between each load (see KeraLua.dll & Lua.dll) ?
            lua.DoFile(path);
            CinematicScript script = new CinematicScript(lua);

            return(script);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Play the CinematicScript async
        /// </summary>
        /// <param name="character"></param>
        /// <param name="spawnId"></param>
        public void TalkToNpc(Character character, long spawnId)
        {
            CinematicScript script = GetScript(character.Map.Id, spawnId);

            script.TalkToNpc(character);
        }
Ejemplo n.º 3
0
 public CinematicEnvironment(Character character, CinematicScript script)
 {
     this.Character = character;
     this.Script    = script;
     this.Npc       = character.Map.Instance.GetNpc((int)script.NpcId);
 }