• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Avesta and mana fluid problem

chaosb

www.originaltibia.com
Joined
Sep 14, 2008
Messages
267
Reaction score
0
Location
Poland
I am using avesta 7.6
When i host it 24H+ its getting crash
crash i mean that console is not offline and players can't log in
someone can help me ?:thumbup:

Mana fluid:
i got error in console like this:

Lua Script Error: [Action interface]
data/actions/scripts/fluids.lua:onUse

LuaScriptInterface::LuaDoCreateItem<>. Tile not found

my fluids.lua

PHP:
local exhaust = createConditionObject(CONDITION_EXHAUSTED)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, 500)

function onUse(cid, item, frompos, item2, topos)
        if(hasCondition(cid, CONDITION_EXHAUSTED) == TRUE) then
		doPlayerSendDefaultCancel(cid, RETURNVALUE_YOUAREEXHAUSTED)
		return TRUE
	end
	if item2.itemid == 1 then
		if item.type == 0 then
			doPlayerSendCancel(cid, "It is empty.")
		else
			if item2.uid == cid then
				doChangeTypeItem(item.uid, 0)
				if item.type == 7 then
					new_mana = math.random(80, 160)
					doPlayerAddMana(cid, new_mana)
					doSendMagicEffect(topos, 12)
					doPlayerSay(cid, "Aaaah...", 1)
                                        doAddCondition(cid, exhaust)
				elseif item.type == 10 then
					new_life = math.random(40, 80)
					doPlayerAddHealth(cid, new_life)
					doSendMagicEffect(topos, 12)
					doPlayerSay(cid, "Aaaah...", 1)
				else
					doPlayerSay(cid, "Gulp.", 1)
				end
			else
				doChangeTypeItem(item.uid, 0)
				splash = doCreateItem(2025, item.type, topos)
				doDecayItem(splash)
			end
		end
	elseif item2.itemid >= 490 and item2.itemid <= 517 
	or item2.itemid >= 618 and item2.itemid <= 629 
	or item2.itemid == 1368 or item2.itemid == 1369 
	or item2.itemid >= 4820 and item2.itemid <= 4825 
	or item2.itemid >= 4828 and item2.itemid <= 4831 
	or item2.itemid >= 4608 and item2.itemid <= 4666 then
		doChangeTypeItem(item.uid, 1)
	elseif item2.itemid == 103 then
		doChangeTypeItem(item.uid, 19)
	elseif item2.itemid >= 598 and item2.itemid < 601 
	or item2.itemid == 1509 
	or item2.itemid >= 518 and item2.itemid <= 529 then
		doChangeTypeItem(item.uid, 26)
	elseif item2.itemid >= 351 and item2.itemid <= 355 then
		doChangeTypeItem(item.uid, 19)
	elseif item2.itemid >= 602 and item2.itemid <= 605 
	or item2.itemid >= 4691 and item2.itemid <= 4755 
	or item2.itemid == 4758 then
		doChangeTypeItem(item.uid, 28)
	elseif item2.itemid == 1771 then
		doChangeTypeItem(item.uid, 1)
	elseif item2.itemid == 1772 then
		doChangeTypeItem(item.uid, 3)
	elseif item2.itemid == 1773 then
		doChangeTypeItem(item.uid, 15)
	elseif item2.itemid > 2806 and item2.itemid < 3132 
	or item2.itemid >= 4251 and item2.itemid <= 4327 then
		doChangeTypeItem(item.uid, 2)
	else
		if item.type == 0 then
			doPlayerSendCancel(cid, "It is empty.")
		else
			doChangeTypeItem(item.uid, 0)
			splash = doCreateItem(2025, item.type, topos)
			doDecayItem(splash)
		end
	end
	return 1
end

Thanks. :)
 
Code:
local exhaust = createConditionObject(CONDITION_EXHAUSTED)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, 1000)

function onUse(cid, item, fromPosition, itemEx, toPosition)
	if getCreatureCondition(cid, CONDITION_EXHAUSTED) == TRUE then
		doPlayerSendDefaultCancel(cid, RETURNVALUE_YOUAREEXHAUSTED)
		return TRUE
	end
	if itemEx.itemid == 1 then
		if item.type == 0 then
			return 0
		else
			if itemEx.uid == cid then
				if item.type == 7 then
					doPlayerAddMana(cid, math.random(80, 160))
					doSendMagicEffect(toPosition, 12)
					doCreatureSay(cid, "Aaaah...", 1)
					doAddCondition(cid, exhaust)
				elseif item.type == 10 then
					doPlayerAddHealth(cid, math.random(40, 80))
					doSendMagicEffect(toPosition, 12)
					doCreatureSay(cid, "Aaaah...", 1)
				else
					doCreatureSay(cid, "Gulp.", 1)
				end
				doChangeTypeItem(item.uid, 0)
			else
				doDecayItem(doCreateItem(2025, item.type, toPosition.x ~= 65535 and toPosition.x ~= 0 and toPosition.y ~= 0 and toPosition.z ~= 0 and toPosition or getPlayerPosition(cid)))
				doChangeTypeItem(item.uid, 0)
			end
		end
	elseif itemEx.itemid >= 490 and itemEx.itemid <= 517 
	or itemEx.itemid >= 618 and itemEx.itemid <= 629 
	or itemEx.itemid == 1368 or itemEx.itemid == 1369 
	or itemEx.itemid >= 4820 and itemEx.itemid <= 4825 
	or itemEx.itemid >= 4828 and itemEx.itemid <= 4831 
	or itemEx.itemid >= 4608 and itemEx.itemid <= 4666 then
		doChangeTypeItem(item.uid, 1)
	elseif itemEx.itemid == 103 then
		doChangeTypeItem(item.uid, 19)
	elseif itemEx.itemid >= 598 and itemEx.itemid < 601 
	or itemEx.itemid == 1509 
	or itemEx.itemid >= 518 and itemEx.itemid <= 529 then
		doChangeTypeItem(item.uid, 26)
	elseif itemEx.itemid >= 351 and itemEx.itemid <= 355 then
		doChangeTypeItem(item.uid, 19)
	elseif itemEx.itemid >= 602 and itemEx.itemid <= 605 
	or itemEx.itemid >= 4691 and itemEx.itemid <= 4755 
	or itemEx.itemid == 4758 then
		doChangeTypeItem(item.uid, 28)
	elseif itemEx.itemid == 1771 then
		doChangeTypeItem(item.uid, 1)
	elseif itemEx.itemid == 1772 then
		doChangeTypeItem(item.uid, 3)
	elseif itemEx.itemid == 1773 then
		doChangeTypeItem(item.uid, 15)
	elseif itemEx.itemid > 2806 and itemEx.itemid < 3132 
	or itemEx.itemid >= 4251 and itemEx.itemid <= 4327 then
		doChangeTypeItem(item.uid, 2)
	else
		if item.type == 0 then
			return 0
		else
			doDecayItem(doCreateItem(2025, item.type, toPosition.x ~= 65535 and toPosition.x ~= 0 and toPosition.y ~= 0 and toPosition.z ~= 0 and toPosition or getPlayerPosition(cid)))
			doChangeTypeItem(item.uid, 0)
		end
	end
	return 1
end
 
Code:
local exhaust = createConditionObject(CONDITION_EXHAUSTED)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, 1000)

function onUse(cid, item, fromPosition, itemEx, toPosition)
    if itemEx.itemid == 1 then
        if item.type == 0 then
            return 0
        else
            if itemEx.uid == cid then
                if item.type == 7 then
                    doPlayerAddMana(cid, math.random(80, 160))
                    doSendMagicEffect(toPosition, 12)
                    doCreatureSay(cid, "Aaaah...", 1)
                    doAddCondition(cid, exhaust)
                elseif item.type == 10 then
                    doPlayerAddHealth(cid, math.random(40, 80))
                    doSendMagicEffect(toPosition, 12)
                    doCreatureSay(cid, "Aaaah...", 1)
                else
                    doCreatureSay(cid, "Gulp.", 1)
                end
                doChangeTypeItem(item.uid, 0)
            else
                doDecayItem(doCreateItem(2025, item.type, toPosition.x ~= 65535 and toPosition.x ~= 0 and toPosition.y ~= 0 and toPosition.z ~= 0 and toPosition or getPlayerPosition(cid)))
                doChangeTypeItem(item.uid, 0)
            end
        end
    elseif itemEx.itemid >= 490 and itemEx.itemid <= 517
    or itemEx.itemid >= 618 and itemEx.itemid <= 629
    or itemEx.itemid == 1368 or itemEx.itemid == 1369
    or itemEx.itemid >= 4820 and itemEx.itemid <= 4825
    or itemEx.itemid >= 4828 and itemEx.itemid <= 4831
    or itemEx.itemid >= 4608 and itemEx.itemid <= 4666 then
        doChangeTypeItem(item.uid, 1)
    elseif itemEx.itemid == 103 then
        doChangeTypeItem(item.uid, 19)
    elseif itemEx.itemid >= 598 and itemEx.itemid < 601
    or itemEx.itemid == 1509
    or itemEx.itemid >= 518 and itemEx.itemid <= 529 then
        doChangeTypeItem(item.uid, 26)
    elseif itemEx.itemid >= 351 and itemEx.itemid <= 355 then
        doChangeTypeItem(item.uid, 19)
    elseif itemEx.itemid >= 602 and itemEx.itemid <= 605
    or itemEx.itemid >= 4691 and itemEx.itemid <= 4755
    or itemEx.itemid == 4758 then
        doChangeTypeItem(item.uid, 28)
    elseif itemEx.itemid == 1771 then
        doChangeTypeItem(item.uid, 1)
    elseif itemEx.itemid == 1772 then
        doChangeTypeItem(item.uid, 3)
    elseif itemEx.itemid == 1773 then
        doChangeTypeItem(item.uid, 15)
    elseif itemEx.itemid > 2806 and itemEx.itemid < 3132
    or itemEx.itemid >= 4251 and itemEx.itemid <= 4327 then
        doChangeTypeItem(item.uid, 2)
    else
        if item.type == 0 then
            return 0
        else
            doDecayItem(doCreateItem(2025, item.type, toPosition.x ~= 65535 and toPosition.x ~= 0 and toPosition.y ~= 0 and toPosition.z ~= 0 and toPosition or getPlayerPosition(cid)))
            doChangeTypeItem(item.uid, 0)
        end
    end
    return 1
end
 
Last edited:
I'm having the same problem and I tried to use @Cykotitan 's script but I still have errors. Using avesta 0.6.3

Code:
Lua Script Error: [Action Interface]
data/actions/scripts/fluids.lua:onUse

LuaScriptInterface::luaDoCreateItem(). Tile not found

Lua Script Error: [Action Interface]
data/actions/scripts/fluids.lua:onUse

LuaScriptInterface::luaDoDecayItem(). Item not found
My fluids.lua is exactly like the second one @Cykotitan posted.
 
maybe this helps you absorc:

PHP:
local exhaust_heal = createConditionObject(CONDITION_EXHAUST_HEAL)
setConditionParam(exhaust_heal, CONDITION_PARAM_TICKS, 1000)

local poison = createConditionObject(CONDITION_POISON)
setConditionParam(poison, CONDITION_PARAM_DELAYED, 1)

local drunk = createConditionObject(CONDITION_DRUNK)
setConditionParam(drunk, CONDITION_PARAM_TICKS, 60000)
addDamageCondition(poison, 4, 6000, -5)
addDamageCondition(poison, 5, 6000, -4)
addDamageCondition(poison, 6, 6000, -3)
addDamageCondition(poison, 10, 6000, -2)
addDamageCondition(poison, 36, 6000, -1)

local TYPE_EMPTY = 0
local TYPE_WATER = 1
local TYPE_BLOOD = 2
local TYPE_BEER = 3
local TYPE_SLIME = 4
local TYPE_LEMONADE = 5
local TYPE_MANA_FLUID = 7
local TYPE_LIFE_FLUID = 10
local TYPE_OIL = 11
local TYPE_URINE = 13
local TYPE_WINE = 15
local TYPE_MUD = 19
local TYPE_LAVA = 26
local TYPE_RUM = 27
local TYPE_SWAMP = 28

function onUse(cid, item, frompos, item2, topos)

        if (item.type == 0) then
                  doPlayerSendCancel(cid,"You can not use this object. ")
        elseif (item2.uid ~= cid) and (topos.stackpos > 0) and (isMoveable(item2.uid) ~= TRUE) and (isCreature(item2.uid) ~= 1) then
                  doPlayerSendCancel(cid,"There is not enough room.")
    elseif (isInArray(FLUID_CONTAINERS,item2.itemid) == TRUE) and (item2.type == TYPE_EMPTY) then
          doChangeTypeItem(item.uid, TYPE_EMPTY)
                  doChangeTypeItem(item2.uid, item.type)

            elseif (topos.x == 65535) and (item2.uid ~= cid) and (isPlayer(item2.uid) ~= cid) then
                if(isInArray(DIRT_WALL,item2.itemid) ~= TRUE) then
          doChangeTypeItem(item.uid, 0)
                  splash = doCreateItem(2025, item.type, getThingPos(cid))
          doDecayItem(splash)
                else
                  doPlayerSendCancel(cid,"There is not enough room.")
                end
            elseif (item2.itemid > 0) and (item2.uid ~= cid) and (isPlayer(item2.uid) ~= cid) then
                if(isInArray(DIRT_WALL,item2.itemid) ~= TRUE) then
          doChangeTypeItem(item.uid, 0)
                  splash = doCreateItem(2025, item.type, topos)
                  if(isInArray(WATER_LAVA_SWAMP,item2.itemid) ~= TRUE) then
                  doDecayItem(splash)
                  end
                else
                  doPlayerSendCancel(cid,"There is not enough room.")
                end
            elseif (frompos.x == 65535) and (item2.uid ~= cid) and (isPlayer(item2.uid) ~= cid) then
                if(isInArray(DIRT_WALL,item2.itemid) ~= TRUE) then
          doChangeTypeItem(item.uid, 0)
                  splash = doCreateItem(2025, item.type, getThingPos(cid))
          doDecayItem(splash)
                else
                  doPlayerSendCancel(cid,"There is not enough room.")
                end
        else
        if (item2.uid == cid) and (isPlayer(item2.uid) == 1) then
              doChangeTypeItem(item.uid, 0)
              if (item.type == TYPE_MANA_FLUID) then
          new_mana = math.random(60, 120)
          doPlayerAddMana(cid, new_mana)
          doSendMagicEffect(topos, 12)
          doPlayerSay(cid, "Aaaah...", 1)
                  doAddCondition(cid, exhaust_heal)
              elseif (item.type == TYPE_LIFE_FLUID) then
          new_life = math.random(20, 50)
          doPlayerAddHealth(cid, new_life)
              doSendMagicEffect(topos, 12)
          doPlayerSay(cid, "Aaaah...", 1)
                  doAddCondition(cid, exhaust_heal)
          elseif (item.type == TYPE_BEER or item.type == TYPE_WINE or item.type == TYPE_RUM) then
                  doTargetCombatCondition(0, cid, drunk, CONST_ME_NONE)
              doPlayerSay(cid, "Aah...", 1)
          elseif (item.type == TYPE_LEMONADE) then
              doPlayerSay(cid, "Mmmh.", 1)
              elseif (item.type == TYPE_SLIME or item.type == TYPE_SWAMP) then
                  doTargetCombatCondition(0, cid, poison, CONST_ME_NONE)
          doPlayerSay(cid, "Urgh!", 1)
              elseif (item.type == TYPE_OIL or item.type == TYPE_URINE) then
          doPlayerSay(cid, "Urgh!", 1)
          else
          doPlayerSay(cid, "Gulp.", 1)
              end
            end
        end
    if (item.type == 0) then
    if item2.itemid >= 490 and item2.itemid <= 517
    or item2.itemid >= 618 and item2.itemid <= 629
    or item2.itemid == 1368 or item2.itemid == 1369
    or item2.itemid >= 4820 and item2.itemid <= 4825
    or item2.itemid >= 4828 and item2.itemid <= 4831
    or item2.itemid >= 4608 and item2.itemid <= 4666 then
        doChangeTypeItem(item.uid, TYPE_WATER)
    elseif item2.itemid == 103 then
        doChangeTypeItem(item.uid, TYPE_MUD)
    elseif item2.itemid >= 598 and item2.itemid < 601
    or item2.itemid == 1509
    or item2.itemid >= 518 and item2.itemid <= 529 then
        doChangeTypeItem(item.uid, TYPE_LAVA)
    elseif item2.itemid >= 351 and item2.itemid <= 355 then
        doChangeTypeItem(item.uid, TYPE_MUD)
    elseif item2.itemid >= 602 and item2.itemid <= 605
    or item2.itemid >= 4691 and item2.itemid <= 4755
    or item2.itemid == 4758 then
        doChangeTypeItem(item.uid, TYPE_SWAMP)
    elseif item2.itemid == 1771 then
        doChangeTypeItem(item.uid, TYPE_WATER)
    elseif item2.itemid == 1772 then
        doChangeTypeItem(item.uid, TYPE_BEER)
    elseif item2.itemid == 1773 then
        doChangeTypeItem(item.uid, TYPE_WINE)
    elseif item2.itemid == 1776 then
        doChangeTypeItem(item.uid, TYPE_LEMONADE)
        elseif(isInArray(NORMAL_CORPSE_STAGE_I,item2.itemid) == TRUE) then
        doChangeTypeItem(item.uid, TYPE_BLOOD)
        elseif(isInArray(SLIME_CORPSES,item2.itemid) == TRUE) then
        doChangeTypeItem(item.uid, TYPE_SLIME)
    elseif item2.itemid >= 371 and item2.itemid <= 382
            or item2.itemid >= 356 and item2.itemid <= 367 then
            doPlayerSendCancel(cid, "You cannot use this object.")
        end
    end
  return TRUE
end
 
I get this error
LuaScriptInterface::luaCreateConditionObject(). Condition not found

-----
Sry for double posting

I'm not so experienced but is the first line the problem maybe?

Code:
local exhaust_heal = createConditionObject(CONDITION_EXHAUST_HEAL)
setConditionParam(exhaust_heal, CONDITION_PARAM_TICKS, 1000)
Maybe it should look like this
Code:
local exhaust_heal = createConditionObject(CONDITION_EXHAUSTED)
setConditionParam(exhaust_heal, CONDITION_PARAM_TICKS, 1000)

-------------
I edited it and it worked, thx @53701688 :)


 
Last edited:
Try this one instead:)
PHP:
local exhaust = createConditionObject(CONDITION_EXHAUST_COMBAT)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, 1000)

local poison = createConditionObject(CONDITION_POISON)
setConditionParam(poison, CONDITION_PARAM_DELAYED, 1)

local drunk = createConditionObject(CONDITION_DRUNK)
setConditionParam(drunk, CONDITION_PARAM_TICKS, 60000)
addDamageCondition(poison, 4, 6000, -5)
addDamageCondition(poison, 5, 6000, -4)
addDamageCondition(poison, 6, 6000, -3)
addDamageCondition(poison, 10, 6000, -2)
addDamageCondition(poison, 36, 6000, -1)

local TYPE_EMPTY = 0
local TYPE_WATER = 1
local TYPE_BLOOD = 2
local TYPE_BEER = 3
local TYPE_SLIME = 4
local TYPE_LEMONADE = 5
local TYPE_MANA_FLUID = 7
local TYPE_LIFE_FLUID = 10
local TYPE_OIL = 11
local TYPE_URINE = 13
local TYPE_WINE = 15
local TYPE_MUD = 19
local TYPE_LAVA = 26
local TYPE_RUM = 27
local TYPE_SWAMP = 28

function onUse(cid, item, frompos, item2, topos)

    if(hasCondition(cid, CONDITION_EXHAUST_COMBAT) == TRUE) then
        doPlayerSendDefaultCancel(cid, RETURNVALUE_YOUAREEXHAUSTED)
        return TRUE
    end

        if (item.type == 0) then
                  doPlayerSendCancel(cid,"You can not use this object. ")
        elseif (item2.uid ~= cid) and (topos.stackpos > 0) and (isMoveable(item2.uid) ~= TRUE) and (isCreature(item2.uid) ~= 1) then
                  doPlayerSendCancel(cid,"There is not enough room.")
    elseif (isInArray(FLUID_CONTAINERS,item2.itemid) == TRUE) and (item2.type == TYPE_EMPTY) then
          doChangeTypeItem(item.uid, TYPE_EMPTY)
                  doChangeTypeItem(item2.uid, item.type)

            elseif (topos.x == 65535) and (item2.uid ~= cid) and (isPlayer(item2.uid) ~= cid) then
                if(isInArray(DIRT_WALL,item2.itemid) ~= TRUE) then
          doChangeTypeItem(item.uid, 0)
                  splash = doCreateItem(2025, item.type, getThingPos(cid))
          doDecayItem(splash)
                else
                  doPlayerSendCancel(cid,"There is not enough room.")
                end
            elseif (item2.itemid > 0) and (item2.uid ~= cid) and (isPlayer(item2.uid) ~= cid) then
                if(isInArray(DIRT_WALL,item2.itemid) ~= TRUE) then
          doChangeTypeItem(item.uid, 0)
                  splash = doCreateItem(2025, item.type, topos)
                  if(isInArray(WATER_LAVA_SWAMP,item2.itemid) ~= TRUE) then
                  doDecayItem(splash)
                  end
                else
                  doPlayerSendCancel(cid,"There is not enough room.")
                end
            elseif (frompos.x == 65535) and (item2.uid ~= cid) and (isPlayer(item2.uid) ~= cid) then
                if(isInArray(DIRT_WALL,item2.itemid) ~= TRUE) then
          doChangeTypeItem(item.uid, 0)
                  splash = doCreateItem(2025, item.type, getThingPos(cid))
          doDecayItem(splash)
                else
                  doPlayerSendCancel(cid,"There is not enough room.")
                end
        else
        if (item2.uid == cid) and (isPlayer(item2.uid) == 1) then
              doChangeTypeItem(item.uid, 0)
              if (item.type == TYPE_MANA_FLUID) then
          new_mana = math.random(60, 120)
          doPlayerAddMana(cid, new_mana)
          doSendMagicEffect(topos, 12)
          doPlayerSay(cid, "Aaaah...", 1)
                  doAddCondition(cid, exhaust)
              elseif (item.type == TYPE_LIFE_FLUID) then
          new_life = math.random(20, 50)
          doPlayerAddHealth(cid, new_life)
              doSendMagicEffect(topos, 12)
          doPlayerSay(cid, "Aaaah...", 1)
                  doAddCondition(cid, exhaust)
          elseif (item.type == TYPE_BEER or item.type == TYPE_WINE or item.type == TYPE_RUM) then
                  doTargetCombatCondition(0, cid, drunk, CONST_ME_NONE)
              doPlayerSay(cid, "Aah...", 1)
          elseif (item.type == TYPE_LEMONADE) then
              doPlayerSay(cid, "Mmmh.", 1)
              elseif (item.type == TYPE_SLIME or item.type == TYPE_SWAMP) then
                  doTargetCombatCondition(0, cid, poison, CONST_ME_NONE)
          doPlayerSay(cid, "Urgh!", 1)
              elseif (item.type == TYPE_OIL or item.type == TYPE_URINE) then
          doPlayerSay(cid, "Urgh!", 1)
          else
          doPlayerSay(cid, "Gulp.", 1)
              end
            end
        end
    if (item.type == 0) then
    if item2.itemid >= 490 and item2.itemid <= 517
    or item2.itemid >= 618 and item2.itemid <= 629
    or item2.itemid == 1368 or item2.itemid == 1369
    or item2.itemid >= 4820 and item2.itemid <= 4825
    or item2.itemid >= 4828 and item2.itemid <= 4831
    or item2.itemid >= 4608 and item2.itemid <= 4666 then
        doChangeTypeItem(item.uid, TYPE_WATER)
    elseif item2.itemid == 103 then
        doChangeTypeItem(item.uid, TYPE_MUD)
    elseif item2.itemid >= 598 and item2.itemid < 601
    or item2.itemid == 1509
    or item2.itemid >= 518 and item2.itemid <= 529 then
        doChangeTypeItem(item.uid, TYPE_LAVA)
    elseif item2.itemid >= 351 and item2.itemid <= 355 then
        doChangeTypeItem(item.uid, TYPE_MUD)
    elseif item2.itemid >= 602 and item2.itemid <= 605
    or item2.itemid >= 4691 and item2.itemid <= 4755
    or item2.itemid == 4758 then
        doChangeTypeItem(item.uid, TYPE_SWAMP)
    elseif item2.itemid == 1771 then
        doChangeTypeItem(item.uid, TYPE_WATER)
    elseif item2.itemid == 1772 then
        doChangeTypeItem(item.uid, TYPE_BEER)
    elseif item2.itemid == 1773 then
        doChangeTypeItem(item.uid, TYPE_WINE)
    elseif item2.itemid == 1776 then
        doChangeTypeItem(item.uid, TYPE_LEMONADE)
        elseif(isInArray(NORMAL_CORPSE_STAGE_I,item2.itemid) == TRUE) then
        doChangeTypeItem(item.uid, TYPE_BLOOD)
        elseif(isInArray(SLIME_CORPSES,item2.itemid) == TRUE) then
        doChangeTypeItem(item.uid, TYPE_SLIME)
    elseif item2.itemid >= 371 and item2.itemid <= 382
            or item2.itemid >= 356 and item2.itemid <= 367 then
            doPlayerSendCancel(cid, "You cannot use this object.")
        end
    end
  return TRUE
end
 
Back
Top