- Dołączył
- Sierpień 1, 2008
- Posty
- 128
- Liczba reakcji
- 34
- Wiek
- 32
sam kombionowa?em na tym ;d
skrypt ten uda?o mi sie zrobic w 1 min
testowa?em go na Evo by fronczek 1,2
Nie Skonczonce Sie Potiony A Wiec Robimy Potions.lua
Jesli ktos otrzebuje pod wieksza ver tibi napisz w temacie badz na gg "8741881
wklejamy do niego
----------------------------------------------
-------------------
do acions dodajemy
---------------------
/Dodano
skrypt ten uda?o mi sie zrobic w 1 min
testowa?em go na Evo by fronczek 1,2
Nie Skonczonce Sie Potiony A Wiec Robimy Potions.lua
Jesli ktos otrzebuje pod wieksza ver tibi napisz w temacie badz na gg "8741881
wklejamy do niego
----------------------------------------------
Kod:
local greatHealthPot = 7591
local greatManaPot = 7590
local strongHealthPot = 7588
local strongManaPot = 7589
local healthPot = 7618
local manaPot = 7620
function onUse(cid, item, frompos, item2, topos)
if(item.itemid == healthPot) then
doSendAnimatedText(getPlayerPosition(cid), "Aaaah...", TEXTCOLOR_ORANGE)
if(doTargetCombatHealth(0, cid, COMBAT_HEALING, 370, 530, CONST_ME_MAGIC_BLUE) == LUA_ERROR) then
return FALSE
end
elseif(item.itemid == manaPot) then
doSendAnimatedText(getPlayerPosition(cid), "Aaaah...", TEXTCOLOR_ORANGE)
if(doTargetCombatMana(0, cid, 380, 450, CONST_ME_MAGIC_BLUE) == LUA_ERROR) then
return FALSE
end
elseif(item.itemid == strongHealthPot) then
if getPlayerVocation(cid) == 3 or getPlayerVocation(cid) == 7 or getPlayerVocation(cid) == 4 or getPlayerVocation(cid) == 8 then
if getPlayerLevel(cid) > 50 then
doSendAnimatedText(getPlayerPosition(cid), "Aaaah...", TEXTCOLOR_ORANGE)
if(doTargetCombatHealth(0, cid, COMBAT_HEALING, 550, 850, CONST_ME_MAGIC_BLUE) == LUA_ERROR) then
return FALSE
end
else
doPlayerSendTextMessage(cid, 21, "Your level is too low.")
end
else
doPlayerSendTextMessage(cid, 21, "You do not have the required vocation.")
end
elseif(item.itemid == strongManaPot) then
if getPlayerVocation(cid) == 1 or getPlayerVocation(cid) == 2 or getPlayerVocation(cid) == 5 or getPlayerVocation(cid) == 6 or getPlayerVocation(cid) == 3 or getPlayerVocation(cid) == 7 then
if getPlayerLevel(cid) > 50 then
doSendAnimatedText(getPlayerPosition(cid), "Aaaah...", TEXTCOLOR_ORANGE)
if(doTargetCombatMana(0, cid, 6150, 7250, CONST_ME_MAGIC_BLUE) == LUA_ERROR) then
return FALSE
end
else
doPlayerSendTextMessage(cid, 21, "Your level is too low.")
end
else
doPlayerSendTextMessage(cid, 21, "You do not have the required vocation.")
end
elseif(item.itemid == greatHealthPot) then
if getPlayerVocation(cid) == 4 or getPlayerVocation(cid) == 8 then
if getPlayerLevel(cid) > 80 then
doSendAnimatedText(getPlayerPosition(cid), "Aaaah...", TEXTCOLOR_ORANGE)
if(doTargetCombatHealth(0, cid, COMBAT_HEALING, 1050, 1650, CONST_ME_MAGIC_BLUE) == LUA_ERROR) then
return FALSE
end
else
doPlayerSendTextMessage(cid, 21, "Your level is too low.")
end
else
doPlayerSendTextMessage(cid, 21, "You do not have the required vocation.")
end
elseif(item.itemid == greatManaPot) then
if getPlayerVocation(cid) == 1 or getPlayerVocation(cid) == 2 or getPlayerVocation(cid) == 5 or getPlayerVocation(cid) == 6 then
if getPlayerLevel(cid) > 80 then
doSendAnimatedText(getPlayerPosition(cid), "Aaaah...", TEXTCOLOR_ORANGE)
if(doTargetCombatMana(0, cid, 1250, 1350, CONST_ME_MAGIC_BLUE) == LUA_ERROR) then
return FALSE
end
else
doPlayerSendTextMessage(cid, 21, "Your level is too low.")
end
else
doPlayerSendTextMessage(cid, 21, "You do not have the required vocation.")
end
end
return TRUE
end
do acions dodajemy
Kod:
-- Potions
<action itemid="7588" script="potions.lua" />
<action itemid="7589" script="potions.lua" />
<action itemid="7590" script="potions.lua" />
<action itemid="7591" script="potions.lua" />
<action itemid="7618" script="potions.lua" />
<action itemid="7620" script="potions.lua" />
/Dodano
Kod:
[/color][/b]
Ostatnia edycja:
.Ale i tak spoko skrypt 

