Skip to content

Commit

Permalink
feat: add new liquids 13.40 (opentibiabr#2814)
Browse files Browse the repository at this point in the history
  • Loading branch information
phacUFPE authored Aug 16, 2024
1 parent 645237b commit bc852f2
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 28 deletions.
42 changes: 22 additions & 20 deletions data/items/items.xml
Original file line number Diff line number Diff line change
@@ -1,26 +1,28 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<items>
<!-- Liquids -->
<!-- Fluid type 0 is same as water (id="1") -->
<item id="1" name="water"/>
<item id="2" name="wine"/>
<item id="3" name="beer"/>
<item id="4" name="mud"/>
<item id="5" name="blood"/>
<item id="6" name="slime"/>
<item id="7" name="oil"/>
<item id="8" name="urine"/>
<item id="9" name="milk"/>
<item id="10" name="manafluid"/>
<item id="11" name="lifefluid"/>
<item id="12" name="lemonade"/>
<item id="13" name="rum"/>
<item id="14" name="fruit juice"/>
<item id="15" name="coconut milk"/>
<item id="16" name="mead"/>
<item id="17" name="tea"/>
<item id="18" name="ink"/>
<!-- 12.85 last fluid is 18, 19+ is a loop from 0 to 18 over and over again -->
<!-- Fluid type 0 is same as water (id="1") -->
<item id="1" name="water"/>
<item id="2" name="wine"/>
<item id="3" name="beer"/>
<item id="4" name="mud"/>
<item id="5" name="blood"/>
<item id="6" name="slime"/>
<item id="7" name="oil"/>
<item id="8" name="urine"/>
<item id="9" name="milk"/>
<item id="10" name="manafluid"/>
<item id="11" name="lifefluid"/>
<item id="12" name="lemonade"/>
<item id="13" name="rum"/>
<item id="14" name="fruit juice"/>
<item id="15" name="coconut milk"/>
<item id="16" name="mead"/>
<item id="17" name="tea"/>
<item id="18" name="ink"/>
<item id="19" name="candyfluid"/>
<item id="20" name="chocolate"/>
<!-- 13.40 last fluid is 20, 21+ is a loop from 0 to 20 over and over again -->

<item id="100" name="void"/>
<item id="101" name="earth"/>
Expand Down
2 changes: 2 additions & 0 deletions src/items/functions/item/item_parse.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,8 @@ const phmap::flat_hash_map<std::string, Fluids_t> FluidTypesMap = {
{ "tea", FLUID_TEA },
{ "mead", FLUID_MEAD },
{ "ink", FLUID_INK },
{ "candyfluid", FLUID_CANDY },
{ "chocolate", FLUID_CHOCOLATE },
};

const phmap::flat_hash_map<std::string, WeaponType_t> WeaponTypesMap = {
Expand Down
18 changes: 10 additions & 8 deletions src/utils/utils_definitions.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -348,23 +348,25 @@ enum Fluids_t : uint8_t {
FLUID_NONE = 0, /* Blue */
FLUID_WATER = 1, /* Blue */
FLUID_WINE = 2, /* Purple */
FLUID_BEER = 3, /* Brown */
FLUID_MUD = 4, /* Brown */
FLUID_BEER = 3, /* Orange */
FLUID_MUD = 4, /* Orange */
FLUID_BLOOD = 5, /* Red */
FLUID_SLIME = 6, /* Green */
FLUID_OIL = 7, /* Brown */
FLUID_OIL = 7, /* Orange */
FLUID_URINE = 8, /* Yellow */
FLUID_MILK = 9, /* White */
FLUID_MANA = 10, /* Purple */
FLUID_LIFE = 11, /* Red */
FLUID_LEMONADE = 12, /* Yellow */
FLUID_RUM = 13, /* Brown */
FLUID_RUM = 13, /* Orange */
FLUID_FRUITJUICE = 14, /* Yellow */
FLUID_COCONUTMILK = 15, /* White */
FLUID_MEAD = 16, /* Brown */
FLUID_TEA = 17, /* Brown */
FLUID_INK = 18 /* Black */
// 12.85 last fluid is 18, 19+ is a loop from 0 to 18 over and over again
FLUID_MEAD = 16, /* Orange */
FLUID_TEA = 17, /* Orange */
FLUID_INK = 18, /* Black */
FLUID_CANDY = 19, /* Red with white pieces */
FLUID_CHOCOLATE = 20, /* Brown */
// 13.40 last fluid is 20, 21+ is a loop from 0 to 20 over and over again
};

enum SquareColor_t : uint8_t {
Expand Down

0 comments on commit bc852f2

Please sign in to comment.