• 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!

Manarune

Aleh

Active Member
Joined
Jan 9, 2009
Messages
1,228
Reaction score
39
Location
Rzeszów
Urzywam tego skryptu na manarune
Code:
-- Mana Rune - by Killavus. --
-- Feel free to edit! --
function onUse(cid, item, frompos, item2, topos)
 
	local level = getPlayerLevel(cid)
	local mlevel = getPlayerMagLevel(cid)
 
	-- Exhausted Settings --
	local exhausted_seconds = 1 -- How many seconds manarune will be unavailible to use. --
	local exhausted_storagevalue = 7000 -- Storage Value to store exhaust. It MUST be unused! --
	-- Exhausted Settings END --
 
	-- Mana Formula Settings --
	-- You can use "level" and "mlevel" --
	local mana_minimum = (level * 2) + (mlevel * 2) - 50
	local mana_maximum = (level * 2) + (mlevel * 2)
	-- Mana Formula Settings END --
 
	local mana_add = math.random(mana_minimum, mana_maximum)
 
		-- We check the charges. --
		if(item.type > 1) then
			-- Exhausted check. --
			if(os.time() > getPlayerStorageValue(cid, exhausted_storagevalue)) then
				-- Entity is player? --
				if(isPlayer(item2.uid) == 1) then
					doSendMagicEffect(frompos, CONST_ME_MAGIC_RED)
					doSendMagicEffect(topos, CONST_ME_MAGIC_GREEN)
					doSendAnimatedText(topos, mana_add, TEXTCOLOR_LIGHTBLUE)
					doPlayerAddMana(item2.uid, mana_add)
					setPlayerStorageValue(cid, exhausted_storagevalue, os.time() + exhausted_seconds)
					doChangeTypeItem(item.uid, item.type - 1)
				else
					doSendMagicEffect(frompos, CONST_ME_POFF)
					doPlayerSendCancel(cid, "You can use this rune only on players.")
				end
			else
				doSendMagicEffect(frompos, CONST_ME_POFF)
				doPlayerSendCancel(cid, "You are exhausted.")
			end
		else
			if(os.time() < getPlayerStorageValue(cid, exhausted_storagevalue)) then
				doSendMagicEffect(frompos, CONST_ME_POFF)
				doPlayerSendCancel(cid, "You are exhausted.")
			else
				if(isPlayer(item2.uid) == 1) then
					doSendMagicEffect(frompos, CONST_ME_MAGIC_RED)
					doSendMagicEffect(topos, CONST_ME_MAGIC_GREEN)
					doSendAnimatedText(topos, mana_add, TEXTCOLOR_LIGHTBLUE)
					doPlayerAddMana(item2.uid, mana_add)
					setPlayerStorageValue(cid, exhausted_storagevalue, os.time() + exhausted_seconds)
					doRemoveItem(item.uid, 0)
				else
					doSendMagicEffect(frompos, CONST_ME_POFF)
					doPlayerSendCancel(cid, "You can use this rune only on players.")
				end
			end
		end
 
	return 1
end
Gdy chce jej użyć to pisze:
Code:
You can use this rune only on players.
Każdy tak ma i nie wiem o co lata.
Pomoże ktoś?
 
Last edited:
"You can use this rune only on players."

Tlumacze: MOZESZ UZYC TEJ RUNY TYLKO NA GRACZU ;P

Albo nie uzywaja na sobie, albo cos jest w skrypcie zepsute i nie pozwala na jej uzycie
 
Code:
local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_BLUE)
setCombatParam(combat, COMBAT_PARAM_TARGETCASTERORTOPMOST, 1)
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0)

function onCastSpell(cid, var)

local level = getPlayerLevel(cid)
local mlevel = getPlayerMagLevel(cid)
local pos = getPlayerPosition(cid)

-- Mana Formula Settings --
-- You can use "level" and "mlevel" --
local mana_minimum = (level * 3) + (mlevel * 3) - 50
local mana_maximum = (level * 4) + (mlevel * 3)
-- Mana Formula Settings END --
local mana_add = math.random(mana_minimum, mana_maximum)
doSendMagicEffect(pos,28)
doPlayerAddMana(cid, mana_add)
doSendAnimatedText(pos, mana_add, TEXTCOLOR_LIGHTBLUE)
return doCombat(cid, combat, var)
end
Tej Uzyj.
 
Wydaje mi sie ze to jest pod tipje 1.9 wiec nje powjino cj dzialac.
 
Back
Top