Skip to content

Commit

Permalink
[Enhancement] adjust of monster (and others) speed multiplication (op…
Browse files Browse the repository at this point in the history
…entibiabr#485)

With this modification, we will no longer need to send the speed of monsters, items and other things, doubled.

Several bugs have already been caused because sometimes when updating a new system, we don't realize that it needs to be sent folded to make the division in the protocol. We removed this once and for all, thus making development easier. There is a script to convert your monsters (divide the speed) to the new system, we understand that the rest is not necessary, mount, items, etc., for being few things.

Conversor is here: https://github.com/opentibiabr/canary/files/10147673/creature.speed.conversion.zip
It can also be found in the pull request description.
  • Loading branch information
dudantas authored Dec 8, 2022
1 parent 81cf1f5 commit 50d3235
Show file tree
Hide file tree
Showing 1,402 changed files with 1,909 additions and 1,658 deletions.
2 changes: 1 addition & 1 deletion data-canary/monster/amphibics/azure_frog.lua
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ monster.health = 60
monster.maxHealth = 60
monster.race = "blood"
monster.corpse = 6079
monster.speed = 320
monster.speed = 160
monster.manaCost = 305

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/amphibics/bog_frog.lua
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ monster.health = 25
monster.maxHealth = 25
monster.race = "blood"
monster.corpse = 6079
monster.speed = 320
monster.speed = 160
monster.manaCost = 305

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/amphibics/coral_frog.lua
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ monster.health = 60
monster.maxHealth = 60
monster.race = "blood"
monster.corpse = 6079
monster.speed = 320
monster.speed = 160
monster.manaCost = 305

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/amphibics/crimson_frog.lua
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ monster.health = 60
monster.maxHealth = 60
monster.race = "blood"
monster.corpse = 6079
monster.speed = 320
monster.speed = 160
monster.manaCost = 305

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/amphibics/deathspawn.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ monster.health = 225
monster.maxHealth = 225
monster.race = "blood"
monster.corpse = 3105
monster.speed = 102
monster.speed = 51
monster.manaCost = 305

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/amphibics/filth_toad.lua
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ monster.health = 185
monster.maxHealth = 185
monster.race = "blood"
monster.corpse = 6077
monster.speed = 210
monster.speed = 105
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/amphibics/green_frog.lua
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ monster.health = 25
monster.maxHealth = 25
monster.race = "venom"
monster.corpse = 6079
monster.speed = 320
monster.speed = 160
monster.manaCost = 250

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/amphibics/infernal_frog.lua
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ monster.health = 655
monster.maxHealth = 655
monster.race = "blood"
monster.corpse = 6079
monster.speed = 200
monster.speed = 100
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/amphibics/orchid_frog.lua
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ monster.health = 60
monster.maxHealth = 60
monster.race = "blood"
monster.corpse = 6079
monster.speed = 320
monster.speed = 160
monster.manaCost = 305

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/amphibics/salamander.lua
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ monster.health = 70
monster.maxHealth = 70
monster.race = "blood"
monster.corpse = 17427
monster.speed = 120
monster.speed = 60
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/amphibics/toad.lua
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ monster.health = 135
monster.maxHealth = 135
monster.race = "blood"
monster.corpse = 6077
monster.speed = 210
monster.speed = 105
monster.manaCost = 400

monster.summon = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/bosses/apocalypse.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ monster.health = 160000
monster.maxHealth = 160000
monster.race = "fire"
monster.corpse = 6068
monster.speed = 380
monster.speed = 350
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/bosses/apprentice_sheng.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ monster.health = 95
monster.maxHealth = 95
monster.race = "blood"
monster.corpse = 5981
monster.speed = 170
monster.speed = 85
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/bosses/bazir.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ monster.health = 110000
monster.maxHealth = 110000
monster.race = "fire"
monster.corpse = 4097
monster.speed = 530
monster.speed = 265
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/demons/demon.lua
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ monster.health = 8200
monster.maxHealth = 8200
monster.race = "fire"
monster.corpse = 5995
monster.speed = 256
monster.speed = 128
monster.manaCost = 0
monster.maxSummons = 1

Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/demons/destroyer.lua
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ monster.health = 3700
monster.maxHealth = 3700
monster.race = "undead"
monster.corpse = 6319
monster.speed = 300
monster.speed = 150
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/demons/fury.lua
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ monster.health = 4100
monster.maxHealth = 4100
monster.race = "blood"
monster.corpse = 18118
monster.speed = 400
monster.speed = 200
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/demons/hellhound.lua
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ monster.health = 7500
monster.maxHealth = 7500
monster.race = "blood"
monster.corpse = 6331
monster.speed = 360
monster.speed = 180
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/demons/hellspawn.lua
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ monster.health = 3500
monster.maxHealth = 3500
monster.race = "fire"
monster.corpse = 9009
monster.speed = 344
monster.speed = 172
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/demons/juggernaut.lua
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ monster.health = 20000
monster.maxHealth = 20000
monster.race = "blood"
monster.corpse = 6335
monster.speed = 340
monster.speed = 170
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/dragons/dragon.lua
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ monster.health = 1000
monster.maxHealth = 1000
monster.race = "blood"
monster.corpse = 4025
monster.speed = 172
monster.speed = 86
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/dragons/dragon_lord.lua
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ monster.health = 1900
monster.maxHealth = 1900
monster.race = "blood"
monster.corpse = 5984
monster.speed = 200
monster.speed = 100
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/dragons/hydra.lua
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ monster.health = 2350
monster.maxHealth = 2350
monster.race = "blood"
monster.corpse = 6048
monster.speed = 250
monster.speed = 180
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/dragons/ice_dragon.lua
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ monster.health = 2500
monster.maxHealth = 2500
monster.race = "undead"
monster.corpse = 25185
monster.speed = 212
monster.speed = 106
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/dragons/wyrm.lua
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ monster.health = 1825
monster.maxHealth = 1825
monster.race = "blood"
monster.corpse = 8113
monster.speed = 280
monster.speed = 140
monster.manaCost = 0

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/familiars/druid_familiar.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ monster.health = 20000
monster.maxHealth = 20000
monster.race = "undead"
monster.corpse = 0
monster.speed = 309
monster.speed = 154
monster.manaCost = 3000

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/familiars/knight_familiar.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ monster.health = 10000
monster.maxHealth = 10000
monster.race = "undead"
monster.corpse = 0
monster.speed = 309
monster.speed = 154
monster.manaCost = 1000

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/familiars/paladin_familiar.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ monster.health = 15000
monster.maxHealth = 15000
monster.race = "undead"
monster.corpse = 0
monster.speed = 309
monster.speed = 154
monster.manaCost = 2000

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/familiars/sorcerer_familiar.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ monster.health = 20000
monster.maxHealth = 20000
monster.race = "undead"
monster.corpse = 0
monster.speed = 309
monster.speed = 154
monster.manaCost = 3000

monster.changeTarget = {
Expand Down
2 changes: 1 addition & 1 deletion data-canary/monster/giants/behemoth.lua
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ monster.health = 4000
monster.maxHealth = 4000
monster.race = "blood"
monster.corpse = 5999
monster.speed = 340
monster.speed = 170
monster.manaCost = 0

monster.changeTarget = {
Expand Down
128 changes: 128 additions & 0 deletions data-canary/monster/giants/cyclops.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,128 @@
local mType = Game.createMonsterType("Cyclops")
local monster = {}

monster.description = "a cyclops"
monster.experience = 150
monster.outfit = {
lookType = 22,
lookHead = 0,
lookBody = 0,
lookLegs = 0,
lookFeet = 0,
lookAddons = 0,
lookMount = 0
}

monster.raceId = 22
monster.Bestiary = {
class = "Giant",
race = BESTY_RACE_GIANT,
toKill = 500,
FirstUnlock = 25,
SecondUnlock = 250,
CharmsPoints = 15,
Stars = 2,
Occurrence = 0,
Locations = "Ab'Dendriel Underground, Cyclopolis, Femor Hills, Kazordoon Prison, Kazordoon Surroundings, \z
Maze of the Lost Souls, Mistrock, Mount Sternum, Outlaw Camp, Plains of Havoc, Shadowthorn, \z
Thais Northern Dungeon, Thais Surroundings, Thais Underground, Ulderek's Rock, Yalahar Foreigner Quarter."
}

monster.health = 260
monster.maxHealth = 260
monster.race = "blood"
monster.corpse = 5962
monster.speed = 95
monster.manaCost = 490

monster.changeTarget = {
interval = 4000,
chance = 10
}

monster.strategiesTarget = {
nearest = 70,
damage = 30,
}

monster.flags = {
summonable = true,
attackable = true,
hostile = true,
convinceable = true,
pushable = false,
rewardBoss = false,
illusionable = true,
canPushItems = true,
canPushCreatures = true,
staticAttackChance = 90,
targetDistance = 1,
runHealth = 0,
healthHidden = false,
isBlockable = false,
canWalkOnEnergy = false,
canWalkOnFire = false,
canWalkOnPoison = false
}

monster.light = {
level = 0,
color = 0
}

monster.voices = {
interval = 5000,
chance = 10,
{text = "Il lorstok human!", yell = false},
{text = "Toks utat.", yell = false},
{text = "Human, uh whil dyh!", yell = false},
{text = "Youh ah trak!", yell = false},
{text = "Let da mashing begin!", yell = false}
}

monster.loot = {
{id = 3012, chance = 190}, -- wolf tooth chain
{name = "gold coin", chance = 82000, maxCount = 47},
{id = 3093, chance = 90}, -- club ring
{name = "halberd", chance = 1003},
{name = "short sword", chance = 8000},
{name = "dark helmet", chance = 220},
{name = "plate shield", chance = 2500},
{name = "battle shield", chance = 1400},
{name = "meat", chance = 30070},
{id = 7398, chance = 80}, -- cyclops trophy
{name = "health potion", chance = 210},
{name = "cyclops toe", chance = 4930},
{id = 23986, chance = 1000} -- heavy old tome
}

monster.attacks = {
{name ="melee", interval = 2000, chance = 100, minDamage = 0, maxDamage = -105}
}

monster.defenses = {
defense = 20,
armor = 20
}

monster.elements = {
{type = COMBAT_PHYSICALDAMAGE, percent = 0},
{type = COMBAT_ENERGYDAMAGE, percent = 25},
{type = COMBAT_EARTHDAMAGE, percent = -10},
{type = COMBAT_FIREDAMAGE, percent = 0},
{type = COMBAT_LIFEDRAIN, percent = 0},
{type = COMBAT_MANADRAIN, percent = 0},
{type = COMBAT_DROWNDAMAGE, percent = 0},
{type = COMBAT_ICEDAMAGE, percent = 0},
{type = COMBAT_HOLYDAMAGE , percent = 20},
{type = COMBAT_DEATHDAMAGE , percent = -10}
}

monster.immunities = {
{type = "paralyze", condition = false},
{type = "outfit", condition = false},
{type = "invisible", condition = false},
{type = "bleed", condition = false}
}

mType:register(monster)
Loading

0 comments on commit 50d3235

Please sign in to comment.