Action Manarune TFS 0.3.5

LuckyM

Ett är Ett
Joined
Jun 13, 2009
Messages
1,385
Best answers
0
Reaction score
145
Location
Sweden
Hello OTLanders ;)

Go in data file then action.xml put this there
<action itemid="2270" event="script" value="liquids/manarune.lua"/>
Then Go in Script and make new file, change name to manarune and put this there
local MIN = 500
local MAX = 600
local EMPTY_POTION = 2270

local exhaust = createConditionObject(CONDITION_EXHAUST)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, (getConfigInfo('timeBetweenExActions' - 2000))

function onUse(cid, item, fromPosition, itemEx, toPosition)
if isPlayer(itemEx.uid) == FALSE then
return FALSE
end

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



if doPlayerAddMana(itemEx.uid, math.random(MIN, MAX)) == LUA_ERROR then
return FALSE
end

doAddCondition(cid, exhaust)
doSendMagicEffect(getThingPos(itemEx.uid), CONST_ME_MAGIC_BLUE)
doCreatureSay(itemEx.uid, "Manarune...", TALKTYPE_ORANGE_1)
doTransformItem(item.uid, EMPTY_POTION)
return TRUE
end
I have seen many search after manarune here you got a good manarune script :)
Give me a rep <3
 

Ertica

OMG OMG OMG
Joined
Mar 27, 2009
Messages
60
Best answers
0
Reaction score
1
Location
Sweden
Ohh Nice :) Thanks..
I think many players will like it Ty Aearar :)


Rep For you :D
 

Erikas Kontenis

Well-Known Member
Joined
Jul 3, 2009
Messages
1,446
Best answers
0
Reaction score
78
Location
Lithuania
First of all script not working :D

Code:
[24/12/2009 16:52:14] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/liquids/manarune.lua)
[24/12/2009 16:52:14] data/actions/scripts/liquids/manarune.lua:8: ')' expected (to close '(' at line 6) near 'function'
Second wtf you need

Code:
local EMPTY_POTION = 2270
is that mana rune or potion :D :D :D

third why its action ? :D wtf u retarted? :D

Fourth here is a pure working mana Rune In Spells :D

Code:
local MIN = 500
local MAX = 600

local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_GREEN)
setCombatParam(combat, COMBAT_PARAM_TARGETCASTERORTOPMOST, 1)
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0)

function onCastSpell(cid, var)
doPlayerAddMana(cid, math.random(MIN, MAX))
return doCombat(cid, combat, var)
end
 
OP
LuckyM

LuckyM

Ett är Ett
Joined
Jun 13, 2009
Messages
1,385
Best answers
0
Reaction score
145
Location
Sweden
First of all script not working :D

Code:
[24/12/2009 16:52:14] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/liquids/manarune.lua)
[24/12/2009 16:52:14] data/actions/scripts/liquids/manarune.lua:8: ')' expected (to close '(' at line 6) near 'function'
Second wtf you need

Code:
local EMPTY_POTION = 2270
is that mana rune or potion :D :D :D

third why its action ? :D wtf u retarted? :D

Fourth here is a pure working mana Rune In Spells :D

Code:
local MIN = 500
local MAX = 600

local combat = createCombatObject()
setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_MAGIC_GREEN)
setCombatParam(combat, COMBAT_PARAM_TARGETCASTERORTOPMOST, 1)
setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 0)

function onCastSpell(cid, var)
doPlayerAddMana(cid, math.random(MIN, MAX))
return doCombat(cid, combat, var)
end
if you dont like it why you comment? Stupid
 

Maniucza

~Lua~ Noob
Joined
Aug 2, 2009
Messages
86
Best answers
0
Reaction score
6
Location
Poland / Rzeszów
Not bugs :D?

PHP:
local MIN = 500
local MAX = 600
local EMPTY_POTION = 2270

local exhaust = createConditionObject(CONDITION_EXHAUST)
setConditionParam(exhaust, CONDITION_PARAM_TICKS, (getConfigInfo('timeBetweenExActions' - 2000))

function onUse(cid, item, fromPosition, itemEx, toPosition)
	if isPlayer(itemEx.uid) == FALSE then
return FALSE
end

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



if doPlayerAddMana(itemEx.uid, math.random(MIN, MAX)) == LUA_ERROR then
	return FALSE
end

		doAddCondition(cid, exhaust)
		doSendMagicEffect(getThingPos(itemEx.uid), CONST_ME_MAGIC_BLUE)
		doCreatureSay(itemEx.uid, "Manarune...", TALKTYPE_ORANGE_1)
		doTransformItem(item.uid, EMPTY_POTION)
	return TRUE
end
 

Erikas Kontenis

Well-Known Member
Joined
Jul 3, 2009
Messages
1,446
Best answers
0
Reaction score
78
Location
Lithuania
@up Aearar

I gues you stupid becouse releasing not working script and very buggy one... and the funny thing is you saying rep me :D
 

Scootakid

New Member
Joined
Jun 6, 2009
Messages
32
Best answers
0
Reaction score
0
how is he retarded for posting an action script? spell scripts for a manarune suck. if it is an action, you can use healing spells at the same time giving the vocations an advantage. i like this idea.
 

Hiighwon

New Member
Joined
Mar 2, 2011
Messages
30
Best answers
0
Reaction score
0
it is not working for mee :( i got TFS 0.3.6, is it cuz off that???
 
Top