aboutsummaryrefslogtreecommitdiff
path: root/ShiftOS.WinForms/Applications
diff options
context:
space:
mode:
authorMichael <[email protected]>2017-02-08 16:33:01 -0500
committerMichael <[email protected]>2017-02-08 16:33:01 -0500
commitbeb2bb27d7cd957a43c26ec73ad96a8241a34008 (patch)
tree929be56b2facd56d2d2fff7fecafd37b214079a0 /ShiftOS.WinForms/Applications
parentd8eb2d79e07b63fa350ac01848f9ea51ea1ea705 (diff)
downloadshiftos_thereturn-beb2bb27d7cd957a43c26ec73ad96a8241a34008.tar.gz
shiftos_thereturn-beb2bb27d7cd957a43c26ec73ad96a8241a34008.tar.bz2
shiftos_thereturn-beb2bb27d7cd957a43c26ec73ad96a8241a34008.zip
"My Shop" menu item works.
Diffstat (limited to 'ShiftOS.WinForms/Applications')
-rw-r--r--ShiftOS.WinForms/Applications/MUDControlCentre.Designer.cs1
-rw-r--r--ShiftOS.WinForms/Applications/MUDControlCentre.cs19
2 files changed, 20 insertions, 0 deletions
diff --git a/ShiftOS.WinForms/Applications/MUDControlCentre.Designer.cs b/ShiftOS.WinForms/Applications/MUDControlCentre.Designer.cs
index 40a7f56..220f061 100644
--- a/ShiftOS.WinForms/Applications/MUDControlCentre.Designer.cs
+++ b/ShiftOS.WinForms/Applications/MUDControlCentre.Designer.cs
@@ -244,6 +244,7 @@ namespace ShiftOS.WinForms.Applications
this.myShopToolStripMenuItem.Name = "myShopToolStripMenuItem";
this.myShopToolStripMenuItem.Size = new System.Drawing.Size(152, 22);
this.myShopToolStripMenuItem.Text = "My Shop";
+ this.myShopToolStripMenuItem.Click += new System.EventHandler(this.myShopToolStripMenuItem_Click);
//
// openAShopToolStripMenuItem
//
diff --git a/ShiftOS.WinForms/Applications/MUDControlCentre.cs b/ShiftOS.WinForms/Applications/MUDControlCentre.cs
index 90c0021..3fa5984 100644
--- a/ShiftOS.WinForms/Applications/MUDControlCentre.cs
+++ b/ShiftOS.WinForms/Applications/MUDControlCentre.cs
@@ -133,6 +133,20 @@ namespace ShiftOS.WinForms.Applications
{
PopulateJoinLegion(JsonConvert.DeserializeObject<List<Legion>>(msg.Contents));
}
+ else if(msg.Name == "user_shop")
+ {
+ this.Invoke(new Action(() =>
+ {
+ ShowShop(JsonConvert.DeserializeObject<Shop>(msg.Contents));
+ }));
+ }
+ else if(msg.Name == "user_noshop")
+ {
+ this.Invoke(new Action(() =>
+ {
+ Infobox.Show("No shop.", "You do not currently own any shops. You must open one to use this screen.");
+ }));
+ }
else if (msg.Name == "shop_allshops")
{
this.Invoke(new Action(() =>
@@ -720,5 +734,10 @@ Current legions: {legionname}";
}
}
+
+ private void myShopToolStripMenuItem_Click(object sender, EventArgs e)
+ {
+ ServerManager.SendMessage("user_get_shop", SaveSystem.CurrentSave.Username);
+ }
}
}