mirror of
https://github.com/edubart/otclient.git
synced 2025-10-15 20:14:54 +02:00
Partial 10.36 support, also fix #499
This commit is contained in:
@@ -186,7 +186,7 @@ CIPSOFT_RSA = "1321277432058722840622950990822933849527763264961655079678763618"
|
||||
"88792221429527047321331896351555606801473202394175817"
|
||||
|
||||
-- set to the latest Tibia.pic signature to make otclient compatible with official tibia
|
||||
PIC_SIGNATURE = 0x52131b61
|
||||
PIC_SIGNATURE = 0x52de78da
|
||||
|
||||
OsTypes = {
|
||||
Linux = 1,
|
||||
|
@@ -27,6 +27,12 @@ EmblemGreen = 1
|
||||
EmblemRed = 2
|
||||
EmblemBlue = 3
|
||||
|
||||
NpcIconNone = 0
|
||||
NpcIconChat = 1
|
||||
NpcIconTrade = 2
|
||||
NpcIconQuest = 3
|
||||
NpcIconTradeQuest = 4
|
||||
|
||||
-- @}
|
||||
|
||||
function getSkullImagePath(skullId)
|
||||
@@ -91,6 +97,20 @@ function getEmblemImagePath(emblemId)
|
||||
return path
|
||||
end
|
||||
|
||||
function getIconImagePath(iconId)
|
||||
local path
|
||||
if iconId == NpcIconChat then
|
||||
path = '/images/game/npcicons/icon_chat'
|
||||
elseif iconId == NpcIconTrade then
|
||||
path = '/images/game/npcicons/icon_trade'
|
||||
elseif iconId == NpcIconQuest then
|
||||
path = '/images/game/npcicons/icon_quest'
|
||||
elseif iconId == NpcIconTradeQuest then
|
||||
path = '/images/game/npcicons/icon_tradequest'
|
||||
end
|
||||
return path
|
||||
end
|
||||
|
||||
function Creature:onSkullChange(skullId)
|
||||
local imagePath = getSkullImagePath(skullId)
|
||||
if imagePath then
|
||||
@@ -111,3 +131,10 @@ function Creature:onEmblemChange(emblemId)
|
||||
self:setEmblemTexture(imagePath)
|
||||
end
|
||||
end
|
||||
|
||||
function Creature:onIconChange(iconId)
|
||||
local imagePath = getIconImagePath(iconId)
|
||||
if imagePath then
|
||||
self:setIconTexture(imagePath)
|
||||
end
|
||||
end
|
@@ -54,7 +54,7 @@ function g_game.getSupportedClients()
|
||||
940, 944, 953, 954, 960, 961, 963,
|
||||
970, 980, 981, 982, 983, 984, 985,
|
||||
986, 1001, 1002, 1010, 1020, 1021,
|
||||
1022, 1031, 1034, 1035
|
||||
1022, 1031, 1034, 1035, 1036
|
||||
}
|
||||
end
|
||||
|
||||
|
Reference in New Issue
Block a user