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

MoveEvent Firewalker boots

zakius

Enter the Ninja!
Joined
Apr 30, 2009
Messages
2,635
Reaction score
65
Location
with Taiga
Not tested with many players, kito2 says that it crashes his serv, noone more told so, but it is possible that movements are too slow and thats the reason


Based on script written by Cykotitan (I guess...)
No link cause some days ago was small rollback or sth on otland and that script(and some my posts that I didnt removed) disappeared)


So lets start:
Lua:
local condition = {}
for i = 1, 4 do
	table.insert(condition, createConditionObject(CONDITION_FIRE))
	addDamageCondition(condition[i], 1, 0, -(i == 1 and 20 or i==2 and 2 or i == 3 and 10 or i == 4 and 1))
	addDamageCondition(condition[i], isInArray({1,3},i)==TRUE and 7 or 2, 9000, -(isInArray({1,3},i)==TRUE and 10 or 1))
end

function onStepIn(cid, item, position, fromPosition)
	if isPlayer(cid) == TRUE and getPlayerFlagValue(cid, PlayerFlag_CannotBeAttacked) == FALSE then
		return doRemoveCondition(cid, CONDITION_FIRE), doAddCondition(cid, isInArray({1487,1492},item.itemid) == TRUE and condition[getPlayerSlotItem(cid, CONST_SLOT_FEET).itemid == 9932 and 2 or 1] or condition[getPlayerSlotItem(cid, CONST_SLOT_FEET).itemid == 9932 and 4 or 3])
	elseif isMonster(cid) then
		return doRemoveCondition(cid, CONDITION_FIRE), doAddCondition(cid, isInArray({1487,1492},item.itemid) == TRUE and condition[1 or 3])
	else	
	doSendMagicEffect(position, CONST_ME_POFF)
	end
end
Save it as firewalker.lua in your movements/scripts dir

in movements.xml delete all StepIn lines for ids:
Code:
1487
1488
1492
1493
and paste
Code:
<movevent type="StepIn" fromid="1487" toid="1488" event="script" value="firewalker.lua"/>
<movevent type="StepIn" fromid="1492" toid="1493" event="script" value="firewalker.lua"/>
in this file.

Not tested with many players online, but I deleted all console errors, monsters nor receiving damage and so on.
Should be 100% stable, fire immune monsters gets spark when walking on fire field, fire weak monsters like gs gets more dmg, and so on.
Only that if you have full magma set(umm, tested with dragon robe only but...) it reduces 100% dmg, but I think its tfs reduction system


posted it on torg also today, writing it here to prevent blaming me on torg^^
 
Last edited:
Code:
local condition = {}
for i = 1, 4 do
	table.insert(condition, createConditionObject(CONDITION_FIRE))
	addDamageCondition(condition[i], 1, 0, -(i == 1 and 20 or i==2 and 2 or i == 3 and 10 or i == 4 and 1))
	addDamageCondition(condition[i], isInArray({1,3},i)==TRUE and 7 or 2, 9000, -(isInArray({1,3},i)==TRUE and 10 or 1))
end

function onStepIn(cid, item, position, fromPosition)
	if isPlayer(cid) == FALSE or getPlayerFlagValue(cid, PlayerFlag_CannotBeAttacked) == FALSE then
		return doRemoveCondition(cid, CONDITION_FIRE), doAddCondition(cid, isInArray({1487,1492},item.itemid) == TRUE and condition[isPlayer(cid) == TRUE and getPlayerSlotItem(cid, CONST_SLOT_FEET).itemid == 9932 and 2 or 1] or condition[isPlayer(cid) == TRUE and getPlayerSlotItem(cid, CONST_SLOT_FEET).itemid == 9932 and 4 or 3])
	else
		doSendMagicEffect(position, CONST_ME_POFF)
	end
end
You also need to remove bold red lines from items.xml:
Code:
	<item id="1487" article="a" name="fire field">
		<attribute key="type" value="magicfield"/>
		<attribute key="replaceable" value="0"/>
[B][COLOR="Red"]		<attribute key="field" value="fire">
			<attribute key="damage" value="20"/>
			<attribute key="ticks" value="10000"/>
			<attribute key="count" value="7"/>
			<attribute key="damage" value="10"/>
		</attribute>[/COLOR][/B]
	</item>
	<item id="1488" article="a" name="fire field">
		<attribute key="type" value="magicfield"/>
		<attribute key="replaceable" value="0"/>
[B][COLOR="Red"]		<attribute key="field" value="fire">
			<attribute key="ticks" value="10000"/>
			<attribute key="count" value="7"/>
			<attribute key="damage" value="10"/>
		</attribute>[/COLOR][/B]
	</item>

	<item id="1492" article="a" name="fire field">
		<attribute key="type" value="magicfield"/>
		<attribute key="decayTo" value="1493"/>
		<attribute key="duration" value="120"/>
[B][COLOR="Red"]		<attribute key="field" value="fire">
			<attribute key="damage" value="20"/>
			<attribute key="ticks" value="10000"/>
			<attribute key="count" value="7"/>
			<attribute key="damage" value="10"/>
		</attribute>[/COLOR][/B]
	</item>
	<item id="1493" article="a" name="fire field">
		<attribute key="type" value="magicfield"/>
		<attribute key="decayTo" value="1494"/>
		<attribute key="duration" value="120"/>
[B][COLOR="Red"]		<attribute key="field" value="fire">
			<attribute key="ticks" value="10000"/>
			<attribute key="count" value="7"/>
			<attribute key="damage" value="10"/>
		</attribute>[/COLOR][/B]
	</item>
 
Yeah, I edited this script, it was really bugged, when monster walks on fire field shows error in console+ no effect, just nothing, appears on monster, no dmg, no magic effect
 
[22/12/2009 16:20:22] [Error - MoveEvents Interface]
[22/12/2009 16:20:22] data/movements/scripts/firewalker.lua:eek:nStepIn
[22/12/2009 16:20:22] Description:
[22/12/2009 16:20:22] (luaDoAddCondition) Condition not found

What is wrong :S

It was appearing all times and lagging the ot and also crashing it.
 
Last edited:
For me (my script) is working good...
I can test it maybe tommorow for longer time with more players(I dont have serv, still making one, so most times I'm the only tester)
Ok found the bug, the smaller fire fields dont works for monsters now.
Will fix soon(I hope so...)

Edited first post, this one should work good
 
Last edited:
I tested it with 150 players... and bugged, tested with 2 players and no bugs...

Should I remove what Cykotitan said from items.xml?
Maybe is that :S
 
I tested it with 150 players... and bugged, tested with 2 players and no bugs...

Should I remove what Cykotitan said from items.xml?
Maybe is that :S
If you haven't did so before, of course you should.
 
@up: dunno, maybe just movement is too slow
script itself makes what it have to make without errors in console
 
hey guys, can anyone more test it with many players? I wanna know if its script or just kito's server ;d
 
this script work like the firewalker boots of global?
in the same way, just reducing the fire fields damage? or reduces all fire basead damages?
 
Code:
[16/02/2010 04:49:33] [Error - MoveEvents Interface] 
[16/02/2010 04:49:33] data/movements/scripts/firewalker.lua:onStepIn
[16/02/2010 04:49:33] Description: 
[16/02/2010 04:49:33] (luaDoAddCondition) Condition not found

keep having problems, but not crashing.
 
hmm, for me was working without any console errors, but I can check again(bit later, going for exam soon :D)
 
Back
Top