From f83fd142cdb597eee3bdae2ad0646fe037230449 Mon Sep 17 00:00:00 2001 From: Syndamia Date: Thu, 30 Apr 2020 10:41:33 +0300 Subject: Implimented mob fighting. Implimented wooden longsword and stone longsword weapons. MobTiles now have a defence property. MobTiles health property setter is now private, use TakeDamage and Heal methods to change it's value. Cows now temporarerly drop grass after being killed. Updated executable. --- Mundus Build 29-04-2020 No4.exe | Bin 1573888 -> 0 bytes Mundus Build 30-04-2020 No1.exe | Bin 0 -> 1584640 bytes Mundus/Data/Crafting/RI.cs | 20 +++--- Mundus/Data/SuperLayers/Mobs/MI.cs | 2 +- Mundus/Data/Tiles/ToolTypes.cs | 1 + Mundus/Data/Windows/WI.cs | 2 +- Mundus/Icons/Land/Tools/rock_longsword.png | Bin 0 -> 4339 bytes Mundus/Icons/Land/Tools/wooden_longsword.png | Bin 0 -> 4339 bytes Mundus/Icons/Project files/rock_longsword.xcf | Bin 0 -> 3125 bytes Mundus/Icons/Project files/wooden_longsword.xcf | Bin 0 -> 3103 bytes Mundus/Mundus.csproj | 2 + Mundus/Service/Mobs/Controllers/MobFighting.cs | 72 ++++++++++++++++++++- .../Service/Mobs/Controllers/MobStatsController.cs | 14 ++-- Mundus/Service/Mobs/Controllers/MobTerraforming.cs | 2 +- Mundus/Service/Mobs/LandMobs/LandMobsPresets.cs | 3 +- Mundus/Service/Mobs/LandMobs/Player.cs | 4 +- Mundus/Service/Mobs/MobTile.cs | 28 +++++++- .../Generators/LandSuperLayerGenerator.cs | 4 +- Mundus/Service/Tiles/ItemPresets/ToolPresets.cs | 8 +++ Mundus/Service/Tiles/Items/Structure.cs | 2 +- Mundus/Views/Windows/LargeGameWindow.cs | 8 ++- Mundus/Views/Windows/MediumGameWindow.cs | 8 ++- Mundus/Views/Windows/SmallGameWindow.cs | 10 ++- Mundus/gtk-gui/generated.cs | 4 ++ Mundus/gtk-gui/gui.stetic | 10 +++ 25 files changed, 165 insertions(+), 39 deletions(-) delete mode 100644 Mundus Build 29-04-2020 No4.exe create mode 100644 Mundus Build 30-04-2020 No1.exe create mode 100644 Mundus/Icons/Land/Tools/rock_longsword.png create mode 100644 Mundus/Icons/Land/Tools/wooden_longsword.png create mode 100644 Mundus/Icons/Project files/rock_longsword.xcf create mode 100644 Mundus/Icons/Project files/wooden_longsword.xcf diff --git a/Mundus Build 29-04-2020 No4.exe b/Mundus Build 29-04-2020 No4.exe deleted file mode 100644 index 998663c..0000000 Binary files a/Mundus Build 29-04-2020 No4.exe and /dev/null differ diff --git a/Mundus Build 30-04-2020 No1.exe b/Mundus Build 30-04-2020 No1.exe new file mode 100644 index 0000000..33be0ef Binary files /dev/null and b/Mundus Build 30-04-2020 No1.exe differ diff --git a/Mundus/Data/Crafting/RI.cs b/Mundus/Data/Crafting/RI.cs index c040cef..b24eea5 100644 --- a/Mundus/Data/Crafting/RI.cs +++ b/Mundus/Data/Crafting/RI.cs @@ -9,10 +9,12 @@ namespace Mundus.Data.Crafting { public static CraftingRecipe WoodenShovel { get; private set; } public static CraftingRecipe WoodenPickaxe { get; private set; } public static CraftingRecipe WoodenAxe { get; private set; } + public static CraftingRecipe WoodenLongsword { get; private set; } - public static CraftingRecipe StoneShovel { get; private set; } - public static CraftingRecipe StonePickAxe { get; private set; } - public static CraftingRecipe StoneAxe { get; private set; } + public static CraftingRecipe RockShovel { get; private set; } + public static CraftingRecipe RockPickaxe { get; private set; } + public static CraftingRecipe RockAxe { get; private set; } + public static CraftingRecipe RockLongsword { get; private set; } public static CraftingRecipe WoodenLadder { get; private set; } @@ -20,16 +22,18 @@ namespace Mundus.Data.Crafting { WoodenShovel = new CraftingRecipe(ToolPresets.GetAWoodenShovel(), 5, MaterialPresets.GetAStick()); WoodenPickaxe = new CraftingRecipe(ToolPresets.GetAWoodenPickaxe(), 4, MaterialPresets.GetAStick()); WoodenAxe = new CraftingRecipe(ToolPresets.GetAWoodenAxe(), 3, MaterialPresets.GetAStick()); + WoodenLongsword = new CraftingRecipe(ToolPresets.GetAWoodenLongsword(), 4, MaterialPresets.GetAStick()); - StoneShovel = new CraftingRecipe(ToolPresets.GetARockShovel(), 4, MaterialPresets.GetALandRock(), 2, MaterialPresets.GetAStick()); - StonePickAxe = new CraftingRecipe(ToolPresets.GetARockPickaxe(), 4, MaterialPresets.GetALandRock(), 2, MaterialPresets.GetAStick()); - StoneAxe = new CraftingRecipe(ToolPresets.GetARockAxe(), 3, MaterialPresets.GetALandRock(), 2, MaterialPresets.GetAStick()); + RockShovel = new CraftingRecipe(ToolPresets.GetARockShovel(), 4, MaterialPresets.GetALandRock(), 2, MaterialPresets.GetAStick()); + RockPickaxe = new CraftingRecipe(ToolPresets.GetARockPickaxe(), 4, MaterialPresets.GetALandRock(), 2, MaterialPresets.GetAStick()); + RockAxe = new CraftingRecipe(ToolPresets.GetARockAxe(), 3, MaterialPresets.GetALandRock(), 2, MaterialPresets.GetAStick()); + RockLongsword = new CraftingRecipe(ToolPresets.GetARockLongsword(), 5, MaterialPresets.GetALandRock(), 2, MaterialPresets.GetAStick()); WoodenLadder = new CraftingRecipe(StructurePresets.GetAWoodenLadder(), 6, MaterialPresets.GetAStick()); AllRecipies = new List { - WoodenShovel, WoodenPickaxe, WoodenAxe, - StoneShovel, StonePickAxe, StoneAxe, + WoodenShovel, WoodenPickaxe, WoodenAxe, WoodenLongsword, + RockShovel, RockPickaxe, RockAxe, RockLongsword, WoodenLadder }; } diff --git a/Mundus/Data/SuperLayers/Mobs/MI.cs b/Mundus/Data/SuperLayers/Mobs/MI.cs index bc725a6..fa498a9 100644 --- a/Mundus/Data/SuperLayers/Mobs/MI.cs +++ b/Mundus/Data/SuperLayers/Mobs/MI.cs @@ -11,7 +11,7 @@ namespace Mundus.Data.Superlayers.Mobs { /// Note: player has a health of 4 * inventorySize /// public static void CreateInstances(int inventorySize) { - Player = new Player("player", 4 * inventorySize, LI.Land, inventorySize); + Player = new Player("player", 4 * inventorySize, 5, LI.Land, inventorySize); Player.Inventory.AppendToHotbar(ToolPresets.GetAWoodenAxe()); Player.Inventory.AppendToHotbar(ToolPresets.GetAWoodenPickaxe()); } diff --git a/Mundus/Data/Tiles/ToolTypes.cs b/Mundus/Data/Tiles/ToolTypes.cs index 1acbb9d..1329061 100644 --- a/Mundus/Data/Tiles/ToolTypes.cs +++ b/Mundus/Data/Tiles/ToolTypes.cs @@ -3,5 +3,6 @@ public const int Shovel = 0; public const int Axe = 1; public const int Pickaxe = 2; + public const int Sword = 3; } } diff --git a/Mundus/Data/Windows/WI.cs b/Mundus/Data/Windows/WI.cs index cd0046e..3a25b94 100644 --- a/Mundus/Data/Windows/WI.cs +++ b/Mundus/Data/Windows/WI.cs @@ -2,7 +2,7 @@ namespace Mundus.Data.Windows { public static class WI { //stands for Window Instances - public const string BuildName = "Build 29-04-2020 No4"; + public const string BuildName = "Build 30-04-2020 No1"; public static IGameWindow SelWin { get; set; } diff --git a/Mundus/Icons/Land/Tools/rock_longsword.png b/Mundus/Icons/Land/Tools/rock_longsword.png new file mode 100644 index 0000000..9c5f102 Binary files /dev/null and b/Mundus/Icons/Land/Tools/rock_longsword.png differ diff --git a/Mundus/Icons/Land/Tools/wooden_longsword.png b/Mundus/Icons/Land/Tools/wooden_longsword.png new file mode 100644 index 0000000..3f021de Binary files /dev/null and b/Mundus/Icons/Land/Tools/wooden_longsword.png differ diff --git a/Mundus/Icons/Project files/rock_longsword.xcf b/Mundus/Icons/Project files/rock_longsword.xcf new file mode 100644 index 0000000..ff21766 Binary files /dev/null and b/Mundus/Icons/Project files/rock_longsword.xcf differ diff --git a/Mundus/Icons/Project files/wooden_longsword.xcf b/Mundus/Icons/Project files/wooden_longsword.xcf new file mode 100644 index 0000000..422cf5f Binary files /dev/null and b/Mundus/Icons/Project files/wooden_longsword.xcf differ diff --git a/Mundus/Mundus.csproj b/Mundus/Mundus.csproj index 60df41e..d99ec96 100644 --- a/Mundus/Mundus.csproj +++ b/Mundus/Mundus.csproj @@ -82,6 +82,8 @@ + + diff --git a/Mundus/Service/Mobs/Controllers/MobFighting.cs b/Mundus/Service/Mobs/Controllers/MobFighting.cs index 31742d1..92b3f64 100644 --- a/Mundus/Service/Mobs/Controllers/MobFighting.cs +++ b/Mundus/Service/Mobs/Controllers/MobFighting.cs @@ -1,7 +1,73 @@ -using System; +using System.Linq; +using Mundus.Data.Superlayers.Mobs; +using Mundus.Data.Tiles; +using Mundus.Service.Tiles; +using Mundus.Service.Tiles.Items; + namespace Mundus.Service.Mobs.Controllers { - public class MobFighting { - public MobFighting() { + public static class MobFighting { + /// + /// Returns if for the specified position in the superlayer the payer is in, there exists a mob + /// + /// YPos of target mob + /// XPos of target mob + public static bool ExistsFightTargetForPlayer(int mapYPos, int mapXPos) { + return ExistsFightTargetForMob(MI.Player, mapYPos, mapXPos); + } + + /// + /// Returns if for the specified position in the superlayer the given mob is in, there exists a mob + /// + /// YPos of target mob + /// XPos of target mob + public static bool ExistsFightTargetForMob(MobTile mob, int mapYPos, int mapXPos) { + return mob.CurrSuperLayer.GetMobLayerTile(mapYPos, mapXPos) != null; + } + + + /// + /// The player tries to damage (or kill) mob on the specified map position + /// Note: will fail of the player uses an invalid item + /// + /// Inventory place of the selected item (item will be checked if its a valid tool) + /// Inventory index of the selected item place (item will be checked if its a valid tool) + /// YPos of target mob + /// XPos of target mob + public static void PlayerTryFight(string selPlace, int selIndex, int mapYPos, int mapXPos) { + MobTryFight(MI.Player, selPlace, selIndex, mapYPos, mapXPos); + } + + // Checks if the mob has a proper fighting item selected + private static bool MobCanFight(MobTile mob, string selPlace, int selIndex, int mapYPos, int mapXPos) { + return Inventory.GetPlayerItem(selPlace, selIndex).GetType() == typeof(Tool) && + ((Tool)Inventory.GetPlayerItem(selPlace, selIndex)).Type == ToolTypes.Sword && + mob.CurrSuperLayer.GetMobLayerTile(mapYPos, mapXPos) != null; + } + + /// + /// The given mob tries to damage (or kill) mob on the specified map position + /// Note: will fail of the given mob uses an invalid item + /// + /// Mob that will fight + /// Inventory place of the selected item (item will be checked if its a valid tool) + /// Inventory index of the selected item place (item will be checked if its a valid tool) + /// YPos of target mob + /// XPos of target mob + public static void MobTryFight(MobTile mob, string selPlace, int selIndex, int mapYPos, int mapXPos) { + if (MobCanFight(mob, selPlace, selIndex, mapYPos, mapXPos)) { + Tool selTool = (Tool)Inventory.GetPlayerItem(selPlace, selIndex); + MobTile targetMob = mob.CurrSuperLayer.GetMobLayerTile(mapYPos, mapXPos); + + if (selTool.Class >= targetMob.Defense) { + if (!targetMob.TakeDamage(1 + (selTool.Class - targetMob.Defense))) { + mob.CurrSuperLayer.SetMobAtPosition(null, mapYPos, mapXPos); + + if (mob.Inventory.Items.Contains(null)) { + mob.Inventory.AppendToItems(targetMob.DroppedUponDeath); + } + } + } + } } } } diff --git a/Mundus/Service/Mobs/Controllers/MobStatsController.cs b/Mundus/Service/Mobs/Controllers/MobStatsController.cs index d02d65a..c8f37d1 100644 --- a/Mundus/Service/Mobs/Controllers/MobStatsController.cs +++ b/Mundus/Service/Mobs/Controllers/MobStatsController.cs @@ -26,10 +26,8 @@ namespace Mundus.Service.Mob.Controllers { return stock_id; } - public static void DamagePlayer(int healthPoints) { - MI.Player.Health -= healthPoints; - - if (MI.Player.Health <= 0) { + public static void DamagePlayer(int damagePoints) { + if (!MI.Player.TakeDamage(damagePoints)) { //do smth } } @@ -38,12 +36,8 @@ namespace Mundus.Service.Mob.Controllers { /// Heals the player (unless/until he has full health) /// /// Health points to heal with - public static void TryHealPlayer(int healthPoints) { - MI.Player.Health += healthPoints; - - if (MI.Player.Health > MapSizes.CurrSize / 5 * 4) { - MI.Player.Health = MapSizes.CurrSize / 5 * 4; - } + public static void HealPlayer(int healthPoints) { + MI.Player.Heal(healthPoints); } /// diff --git a/Mundus/Service/Mobs/Controllers/MobTerraforming.cs b/Mundus/Service/Mobs/Controllers/MobTerraforming.cs index 41ae9cf..589818e 100644 --- a/Mundus/Service/Mobs/Controllers/MobTerraforming.cs +++ b/Mundus/Service/Mobs/Controllers/MobTerraforming.cs @@ -91,7 +91,7 @@ namespace Mundus.Service.Mobs.Controllers { } // Damage to the structure is done after adding the dropped item/items. - if (!selStructure.Damage(damagePoints)) { + if (!selStructure.TakeDamage(damagePoints)) { MI.Player.CurrSuperLayer.SetStructureAtPosition(null, mapYPos, mapXPos); } } diff --git a/Mundus/Service/Mobs/LandMobs/LandMobsPresets.cs b/Mundus/Service/Mobs/LandMobs/LandMobsPresets.cs index 0641a1d..bb3882b 100644 --- a/Mundus/Service/Mobs/LandMobs/LandMobsPresets.cs +++ b/Mundus/Service/Mobs/LandMobs/LandMobsPresets.cs @@ -1,6 +1,7 @@ using System; using Mundus.Data.SuperLayers; using Mundus.Service.Tiles; +using Mundus.Service.Tiles.ItemPresets; namespace Mundus.Service.Mobs.LandMobs { public static class LandMobsPresets { @@ -8,7 +9,7 @@ namespace Mundus.Service.Mobs.LandMobs { /// Returns a new instance of the cow mob tile /// public static MobTile GetACow() { - return new MobTile("L_cow", 10, LI.Land); + return new MobTile("L_cow", 10, 1, LI.Land, 1, MaterialPresets.GetAGrass()); } } } diff --git a/Mundus/Service/Mobs/LandMobs/Player.cs b/Mundus/Service/Mobs/LandMobs/Player.cs index 7262429..d7c8e06 100644 --- a/Mundus/Service/Mobs/LandMobs/Player.cs +++ b/Mundus/Service/Mobs/LandMobs/Player.cs @@ -8,8 +8,8 @@ namespace Mundus.Service.Mobs.LandMobs { /// /// Note: player has an rndMovementQualifier of -1 and drops first item in the hotbar /// - public Player(string stock_id, int health, ISuperLayer currentSuperLayer, int inventorySize) - : base(stock_id, health, currentSuperLayer, inventorySize, null, -1) + public Player(string stock_id, int health, int defence, ISuperLayer currentSuperLayer, int inventorySize) + : base(stock_id, health, defence, currentSuperLayer, inventorySize, null, -1) { this.DroppedUponDeath = (Material)this.Inventory.Hotbar[0]; } diff --git a/Mundus/Service/Mobs/MobTile.cs b/Mundus/Service/Mobs/MobTile.cs index 697b2ec..6167a40 100644 --- a/Mundus/Service/Mobs/MobTile.cs +++ b/Mundus/Service/Mobs/MobTile.cs @@ -1,5 +1,6 @@ using System; using Gtk; +using Mundus.Data; using Mundus.Data.SuperLayers; using Mundus.Service.Mobs; using Mundus.Service.Mobs.Controllers; @@ -13,7 +14,8 @@ namespace Mundus.Service.Tiles { public ISuperLayer CurrSuperLayer { get; set; } public int YPos { get; set; } public int XPos { get; set; } - public int Health { get; set; } + public int Health { get; private set; } + public int Defense { get; set; } public Material DroppedUponDeath { get; protected set; } public Inventory Inventory { get; set; } @@ -23,14 +25,36 @@ namespace Mundus.Service.Tiles { /// public int RndMovementRate { get; protected set; } - public MobTile(string stock_id, int health, ISuperLayer currentSuperLayer, int inventorySize = 5, Material droppedUponDeath = null, int rndMovementQualifier = 3) { + public MobTile(string stock_id, int health, int defence, ISuperLayer currentSuperLayer, int inventorySize = 5, Material droppedUponDeath = null, int rndMovementQualifier = 3) { this.stock_id = stock_id; this.Texture = new Image(stock_id, IconSize.Dnd); this.Health = health; + this.Defense = defence; this.CurrSuperLayer = currentSuperLayer; this.RndMovementRate = rndMovementQualifier; this.DroppedUponDeath = droppedUponDeath; this.Inventory = new Inventory(inventorySize); + } + + /// + /// Removes health from structure + /// + /// Whether the mobtile can still be damaged + public bool TakeDamage(int damagePoints) { + this.Health -= damagePoints; + return this.Health > 0; + } + + /// + /// Heals the mobtile (unless/until it has full health (4 * inventorySize)) + /// + /// Health points to heal with + public void Heal(int healthPoints) { + this.Health += healthPoints; + + if (this.Health > MapSizes.CurrSize / 5 * 4) { + this.Health = MapSizes.CurrSize / 5 * 4; + } } } } \ No newline at end of file diff --git a/Mundus/Service/SuperLayers/Generators/LandSuperLayerGenerator.cs b/Mundus/Service/SuperLayers/Generators/LandSuperLayerGenerator.cs index c1ad310..b073fb3 100644 --- a/Mundus/Service/SuperLayers/Generators/LandSuperLayerGenerator.cs +++ b/Mundus/Service/SuperLayers/Generators/LandSuperLayerGenerator.cs @@ -26,8 +26,8 @@ namespace Mundus.Service.SuperLayers.Generators { LI.Land.GetStructureLayerTile(y, x) == null) { if (y == size / 2 && x == size / 2) { - MI.Player.YPos = x; - MI.Player.XPos = y; + MI.Player.YPos = y; + MI.Player.XPos = x; tiles[y, x] = MI.Player; } else if (rnd.Next(0, 20 + Difficulty.SelDifficulty) == 1) { diff --git a/Mundus/Service/Tiles/ItemPresets/ToolPresets.cs b/Mundus/Service/Tiles/ItemPresets/ToolPresets.cs index 4979646..af9abfe 100644 --- a/Mundus/Service/Tiles/ItemPresets/ToolPresets.cs +++ b/Mundus/Service/Tiles/ItemPresets/ToolPresets.cs @@ -16,6 +16,10 @@ namespace Mundus.Service.Tiles.ItemPresets { return new Tool("wooden_shovel", ToolTypes.Shovel, 1); } + public static Tool GetAWoodenLongsword() { + return new Tool("wooden_longsword", ToolTypes.Sword, 2); + } + public static Tool GetARockPickaxe() { return new Tool("rock_pickaxe", ToolTypes.Pickaxe, 2); } @@ -27,5 +31,9 @@ namespace Mundus.Service.Tiles.ItemPresets { public static Tool GetARockShovel() { return new Tool("rock_shovel", ToolTypes.Shovel, 2); } + + public static Tool GetARockLongsword() { + return new Tool("rock_longsword", ToolTypes.Sword, 4); + } } } diff --git a/Mundus/Service/Tiles/Items/Structure.cs b/Mundus/Service/Tiles/Items/Structure.cs index 8423966..b5d7747 100644 --- a/Mundus/Service/Tiles/Items/Structure.cs +++ b/Mundus/Service/Tiles/Items/Structure.cs @@ -54,7 +54,7 @@ /// Removes health from structure /// /// Whether the structure can still be damaged - public bool Damage(int damagePoints) { + public bool TakeDamage(int damagePoints) { this.Health -= damagePoints; return this.Health > 0; } diff --git a/Mundus/Views/Windows/LargeGameWindow.cs b/Mundus/Views/Windows/LargeGameWindow.cs index 1b40f3e..a3e0da8 100644 --- a/Mundus/Views/Windows/LargeGameWindow.cs +++ b/Mundus/Views/Windows/LargeGameWindow.cs @@ -52,8 +52,12 @@ namespace Mundus.Views.Windows { } else { if (Inventory.GetPlayerItem(selPlace, selIndex) != null) { - //try to do MobFighting - MobTerraforming.PlayerTerraformAt(mapYPos, mapXPos, selPlace, selIndex); + if (MobFighting.ExistsFightTargetForPlayer(mapYPos, mapXPos)) { + MobFighting.PlayerTryFight(selPlace, selIndex, mapYPos, mapXPos); + } + else { + MobTerraforming.PlayerTerraformAt(mapYPos, mapXPos, selPlace, selIndex); + } } ResetSelection(); } diff --git a/Mundus/Views/Windows/MediumGameWindow.cs b/Mundus/Views/Windows/MediumGameWindow.cs index a4c6321..fde50c8 100644 --- a/Mundus/Views/Windows/MediumGameWindow.cs +++ b/Mundus/Views/Windows/MediumGameWindow.cs @@ -53,8 +53,12 @@ namespace Mundus.Views.Windows { } else { if (Inventory.GetPlayerItem(selPlace, selIndex) != null) { - //try to do MobFighting - MobTerraforming.PlayerTerraformAt(mapYPos, mapXPos, selPlace, selIndex); + if (MobFighting.ExistsFightTargetForPlayer(mapYPos, mapXPos)) { + MobFighting.PlayerTryFight(selPlace, selIndex, mapYPos, mapXPos); + } + else { + MobTerraforming.PlayerTerraformAt(mapYPos, mapXPos, selPlace, selIndex); + } } ResetSelection(); } diff --git a/Mundus/Views/Windows/SmallGameWindow.cs b/Mundus/Views/Windows/SmallGameWindow.cs index 41c7bdd..2a551cf 100644 --- a/Mundus/Views/Windows/SmallGameWindow.cs +++ b/Mundus/Views/Windows/SmallGameWindow.cs @@ -72,8 +72,12 @@ namespace Mundus.Views.Windows { } else { if (Inventory.GetPlayerItem(selPlace, selIndex) != null) { - //try to do MobFighting - MobTerraforming.PlayerTerraformAt(mapYPos, mapXPos, selPlace, selIndex); + if (MobFighting.ExistsFightTargetForPlayer(mapYPos, mapXPos)) { + MobFighting.PlayerTryFight(selPlace, selIndex, mapYPos, mapXPos); + } + else { + MobTerraforming.PlayerTerraformAt(mapYPos, mapXPos, selPlace, selIndex); + } } ResetSelection(); } @@ -361,7 +365,7 @@ namespace Mundus.Views.Windows { //Mundus.Data.Superlayers.Mobs.LMI.Player.Inventory.Hotbar[1] = new Service.Tiles.Items.Tool("blank_hand", Mundus.Data.Tiles.ToolTypes.Pickaxe, 1); //Mundus.Data.Superlayers.Mobs.LMI.Player.Inventory.Hotbar[0] = new Service.Tiles.Items.Tool("blank_hand", Mundus.Data.Tiles.ToolTypes.Axe, 1); - MobStatsController.TryHealPlayer(1); + MobStatsController.HealPlayer(1); PrintMainMenu(); } diff --git a/Mundus/gtk-gui/generated.cs b/Mundus/gtk-gui/generated.cs index 32efb52..9bf48c2 100644 --- a/Mundus/gtk-gui/generated.cs +++ b/Mundus/gtk-gui/generated.cs @@ -74,6 +74,10 @@ namespace Stetic w1.Add("S_sky", w31); global::Gtk.IconSet w32 = new global::Gtk.IconSet(global::Gdk.Pixbuf.LoadFromResource("Mundus.Icons.Land.Mobs.L_cow.png")); w1.Add("L_cow", w32); + global::Gtk.IconSet w33 = new global::Gtk.IconSet(global::Gdk.Pixbuf.LoadFromResource("Mundus.Icons.Land.Tools.wooden_longsword.png")); + w1.Add("wooden_longsword", w33); + global::Gtk.IconSet w34 = new global::Gtk.IconSet(global::Gdk.Pixbuf.LoadFromResource("Mundus.Icons.Land.Tools.rock_longsword.png")); + w1.Add("rock_longsword", w34); w1.AddDefault(); } } diff --git a/Mundus/gtk-gui/gui.stetic b/Mundus/gtk-gui/gui.stetic index b154b9e..0b91a2b 100644 --- a/Mundus/gtk-gui/gui.stetic +++ b/Mundus/gtk-gui/gui.stetic @@ -162,6 +162,16 @@ resource:Mundus.Icons.Land.Mobs.L_cow.png + + + resource:Mundus.Icons.Land.Tools.wooden_longsword.png + + + + + resource:Mundus.Icons.Land.Tools.rock_longsword.png + + -- cgit v1.2.3