Exemplo n.º 1
0
        public void load_events(BinaryReader reader)
        {
            if (reader != null)
            {
                Finished_Events.read(reader);
                if (!Global.LOADED_VERSION.older_than(0, 4, 5, 1)) // This is a suspend load, so this isn't needed for public release //Debug
                {
                    Repeated_Events.read(reader);
                }
                else
                {
                    Repeated_Events.Clear();
                }
            }
            else
            {
                Finished_Events.Clear();
                Repeated_Events.Clear();
            }

            Event_Data = new Map_Event_Data();
            add_events(GLOBAL_EVENT);
            //if (Name != "")
            //{
            foreach (string name in Name.Split(Config.EVENT_NAME_DELIMITER, StringSplitOptions.RemoveEmptyEntries))
            {
                add_events(name);
            }
            //}
            refresh_events();
        }
Exemplo n.º 2
0
 public void load_events(Map_Event_Data event_data)
 {
     Finished_Events.Clear();
     Repeated_Events.Clear();
     Event_Data = event_data;
     refresh_events();
 }
Exemplo n.º 3
0
        private Event_Data GetWorldmapEvent()
        {
            Map_Event_Data events =
                Global.Content.Load <Map_Event_Data>(@"Data/Map Data/Event Data/Worldmap");

            for (int event_index = 0; event_index < events.Events.Count; event_index++)
            {
                if (events.Events[event_index].name == MenuData.ChapterId + "Worldmap")
                {
                    return(events.Events[event_index]);
                }
            }

            return(null);
        }