Skip to content

Commit

Permalink
closes #353: rebalances beasts by removing half the magical set
Browse files Browse the repository at this point in the history
  • Loading branch information
loothero committed May 31, 2023
1 parent b7b0c5d commit ed1b2fb
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 99 deletions.
20 changes: 0 additions & 20 deletions contracts/loot/adventurer/metadata.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -117,11 +117,6 @@ namespace AdventurerUriUtils {
const Minotaur = 'Minotaur';
const Basilisk = 'Basilisk';
const Gnome = 'Gnome';
const Wraith = 'Wraith';
const Ghoul = 'Ghoul';
const Goblin = 'Goblin';
const Skeleton = 'Skeleton';
const Golem = 'Golem';
const Giant = 'Giant';
const Yeti = 'Yeti';
const Orc = 'Orc';
Expand Down Expand Up @@ -981,21 +976,6 @@ namespace AdventurerUri {
if (beast == BeastIds.Gnome) {
assert values[values_index + 2] = AdventurerUriUtils.Beast.Gnome;
}
if (beast == BeastIds.Wraith) {
assert values[values_index + 2] = AdventurerUriUtils.Beast.Wraith;
}
if (beast == BeastIds.Ghoul) {
assert values[values_index + 2] = AdventurerUriUtils.Beast.Ghoul;
}
if (beast == BeastIds.Goblin) {
assert values[values_index + 2] = AdventurerUriUtils.Beast.Goblin;
}
if (beast == BeastIds.Skeleton) {
assert values[values_index + 2] = AdventurerUriUtils.Beast.Skeleton;
}
if (beast == BeastIds.Golem) {
assert values[values_index + 2] = AdventurerUriUtils.Beast.Golem;
}
if (beast == BeastIds.Giant) {
assert values[values_index + 2] = AdventurerUriUtils.Beast.Giant;
}
Expand Down
27 changes: 6 additions & 21 deletions contracts/loot/beast/stats/beast.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,12 @@ from starkware.cairo.common.bool import TRUE, FALSE
from starkware.cairo.common.math_cmp import is_le, is_not_zero
from starkware.cairo.common.registers import get_label_location

from contracts.loot.constants.beast import BeastAttackType, BeastArmorType, BeastRank, BeastAttackLocation
from contracts.loot.constants.beast import (
BeastAttackType,
BeastArmorType,
BeastRank,
BeastAttackLocation,
)
from contracts.loot.constants.rankings import ItemRank
from contracts.loot.constants.physics import MaterialDensity

Expand All @@ -31,11 +36,6 @@ namespace BeastStats {
dw BeastAttackType.Minotaur;
dw BeastAttackType.Basilisk;
dw BeastAttackType.Gnome;
dw BeastAttackType.Wraith;
dw BeastAttackType.Ghoul;
dw BeastAttackType.Goblin;
dw BeastAttackType.Skeleton;
dw BeastAttackType.Golem;
dw BeastAttackType.Giant;
dw BeastAttackType.Yeti;
dw BeastAttackType.Orc;
Expand All @@ -62,11 +62,6 @@ namespace BeastStats {
dw BeastArmorType.Minotaur;
dw BeastArmorType.Basilisk;
dw BeastArmorType.Gnome;
dw BeastArmorType.Wraith;
dw BeastArmorType.Ghoul;
dw BeastArmorType.Goblin;
dw BeastArmorType.Skeleton;
dw BeastArmorType.Golem;
dw BeastArmorType.Giant;
dw BeastArmorType.Yeti;
dw BeastArmorType.Orc;
Expand All @@ -91,11 +86,6 @@ namespace BeastStats {
dw BeastRank.Minotaur;
dw BeastRank.Basilisk;
dw BeastRank.Gnome;
dw BeastRank.Wraith;
dw BeastRank.Ghoul;
dw BeastRank.Goblin;
dw BeastRank.Skeleton;
dw BeastRank.Golem;
dw BeastRank.Giant;
dw BeastRank.Yeti;
dw BeastRank.Orc;
Expand All @@ -122,11 +112,6 @@ namespace BeastStats {
dw BeastAttackLocation.Minotaur;
dw BeastAttackLocation.Basilisk;
dw BeastAttackLocation.Gnome;
dw BeastAttackLocation.Wraith;
dw BeastAttackLocation.Ghoul;
dw BeastAttackLocation.Goblin;
dw BeastAttackLocation.Skeleton;
dw BeastAttackLocation.Golem;
dw BeastAttackLocation.Giant;
dw BeastAttackLocation.Yeti;
dw BeastAttackLocation.Orc;
Expand Down
54 changes: 12 additions & 42 deletions contracts/loot/constants/beast.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -55,26 +55,20 @@ namespace BeastIds {
const Basilisk = 4;
const Gnome = 5;

const Wraith = 6;
const Ghoul = 7;
const Goblin = 8;
const Skeleton = 9;
const Golem = 10;

const Giant = 11;
const Yeti = 12;
const Orc = 13;
const Beserker = 14;
const Ogre = 15;

const Dragon = 16;
const Vampire = 17;
const Werewolf = 18;
const Spider = 19;
const Rat = 20;
const Giant = 6;
const Yeti = 7;
const Orc = 8;
const Beserker = 9;
const Ogre = 10;

const Dragon = 11;
const Vampire = 12;
const Werewolf = 13;
const Spider = 14;
const Rat = 15;

// If you add beasts, make sure to update MAX_ID below
const MAX_ID = 20;
const MAX_ID = 15;
}

namespace BeastRank {
Expand All @@ -84,12 +78,6 @@ namespace BeastRank {
const Basilisk = 4;
const Gnome = 5;

const Wraith = 1;
const Ghoul = 2;
const Goblin = 3;
const Skeleton = 4;
const Golem = 5;

const Giant = 1;
const Yeti = 2;
const Orc = 3;
Expand All @@ -110,12 +98,6 @@ namespace BeastAttackType {
const Basilisk = Type.Weapon.magic;
const Gnome = Type.Weapon.magic;

const Wraith = Type.Weapon.magic;
const Ghoul = Type.Weapon.magic;
const Goblin = Type.Weapon.magic;
const Skeleton = Type.Weapon.magic;
const Golem = Type.Weapon.magic;

const Giant = Type.Weapon.bludgeon;
const Yeti = Type.Weapon.bludgeon;
const Orc = Type.Weapon.bludgeon;
Expand All @@ -136,12 +118,6 @@ namespace BeastArmorType {
const Basilisk = Type.Armor.cloth;
const Gnome = Type.Armor.cloth;

const Wraith = Type.Armor.cloth;
const Ghoul = Type.Armor.cloth;
const Goblin = Type.Armor.cloth;
const Skeleton = Type.Armor.cloth;
const Golem = Type.Armor.cloth;

const Giant = Type.Armor.metal;
const Yeti = Type.Armor.metal;
const Orc = Type.Armor.metal;
Expand Down Expand Up @@ -170,12 +146,6 @@ namespace BeastAttackLocation {
const Basilisk = Slot.Waist;
const Gnome = Slot.Foot;

const Wraith = Slot.Chest;
const Ghoul = Slot.Hand;
const Goblin = Slot.Waist;
const Skeleton = Slot.Foot;
const Golem = Slot.Head;

const Giant = Slot.Hand;
const Yeti = Slot.Waist;
const Orc = Slot.Foot;
Expand Down
28 changes: 12 additions & 16 deletions realms_cli/realms_cli/loot/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,16 @@
"3": "Minotaur",
"4": "Basilisk",
"5": "Gnome",
"6": "Wraith",
"7": "Ghoul",
"8": "Goblin",
"9": "Skeleton",
"10": "Golem",
"11": "Giant",
"12": "Yeti",
"13": "Orc",
"14": "Beserker",
"15": "Ogre",
"16": "Dragon",
"17": "Vampire",
"18": "Werewolf",
"19": "Spider",
"20": "Rat",
"6": "Giant",
"7": "Yeti",
"8": "Orc",
"9": "Beserker",
"10": "Ogre",
"11": "Dragon",
"12": "Vampire",
"13": "Werewolf",
"14": "Spider",
"15": "Rat",
}

ITEMS = {
Expand Down Expand Up @@ -185,6 +180,7 @@
15: "Hidden Arrow",
}

DISCOVERY_TYPES = {0: "Nothing", 1: "Beast", 2: "Obstacle", 3: "Item", 4: "Adventurer"}
DISCOVERY_TYPES = {0: "Nothing", 1: "Beast",
2: "Obstacle", 3: "Item", 4: "Adventurer"}

ITEM_DISCOVERY_TYPES = {0: "Gold", 1: "Loot", 2: "Health"}

0 comments on commit ed1b2fb

Please sign in to comment.