public override void Load(BinaryReader BR)
 {
     RouteName = BR.ReadString();
     RoadA     = new RouteMenu.RouteParams(BR.ReadString(), BR.ReadString(), BR.ReadString());
     RoadB     = new RouteMenu.RouteParams(BR.ReadString(), BR.ReadString(), BR.ReadString());
     RoadC     = new RouteMenu.RouteParams(BR.ReadString(), BR.ReadString(), BR.ReadString());
     RoadD     = new RouteMenu.RouteParams(BR.ReadString(), BR.ReadString(), BR.ReadString());
 }
 public ScriptRoadSelection(BattleMap Map)
     : base(Map, 140, 80, "Road Selection", new string[] { "Open Selection" }, new string[] { "Road A", "Road B", "Road C", "Road D" })
 {
     _RouteName = "";
     _RoadA     = new RouteMenu.RouteParams("", "", "");
     _RoadB     = new RouteMenu.RouteParams("", "", "");
     _RoadC     = new RouteMenu.RouteParams("", "", "");
     _RoadD     = new RouteMenu.RouteParams("", "", "");
 }
 public ScriptRoadSelection()
     : this(null)
 {
     _RouteName = "";
     _RoadA     = new RouteMenu.RouteParams("", "", "");
     _RoadB     = new RouteMenu.RouteParams("", "", "");
     _RoadC     = new RouteMenu.RouteParams("", "", "");
     _RoadD     = new RouteMenu.RouteParams("", "", "");
 }
Beispiel #4
0
        public override object EditValue(ITypeDescriptorContext context, IServiceProvider provider, object value)
        {
            IWindowsFormsEditorService svc = (IWindowsFormsEditorService)
                                             provider.GetService(typeof(IWindowsFormsEditorService));

            if (svc != null)
            {
                RouteMenu.RouteParams ActiveParams = (RouteMenu.RouteParams)value;
                RouteEditor           NewEditor    = new RouteEditor(ActiveParams.Title, ActiveParams.Summary, ActiveParams.Description);
                NewEditor.ShowDialog();
                value = new RouteMenu.RouteParams(NewEditor.txtTitle.Text, NewEditor.txtSummary.Text, NewEditor.txtDescription.Text);
            }
            return(value);
        }