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

when adding 7 fields, doors opens

Kramer infernal

I work alone =/
Joined
Jun 18, 2008
Messages
225
Reaction score
0
Hi, I'm using TFS 0.2.20 and I wanna know how I do this...

When a player puts 6 fire fields and one energy field on strategical points

-------
-------
-------
-------
-------
-------
-------


Red=fire fields
turquoise=energy fields...

Then a wall located at the bottom dissappears...

IF some of the 7 fields dissapear, the wall reappear...

I had an Idea but it doesn't worked... some of you can help me?

Edit: Of being necessary, move this topic to his correct board... sorry, my bad.
 
Last edited:
Yeah, but I deleted it because I tried to fix it but no way :S

Edit:

I readed in search functions about a

onAddItem function on movements scripts...

also I tried to combine item.actionid and item.itemid in this function, but I didn't have answers at adding the fields.
 
But, thats the problem, how I check IF there are fields on it, I mean for example this

function onAddItem(moveitem, tilepos)

if item.itemid == 1492 and floor.actionid == 1000 then

ok, as you can see here, I'm not specifying if the floor.actionid is the floor, and I'm not specifying the location, that is my problem, according to search engine on this forum, the script goes by this, but I cannot understand how I use location and checking if the floor have an action id.

Thanks in advance.
 
This is my script, it still doesn't work (IT WORKED ON ACTIONS.XML)
I want this script works on movements, because in movements when field dissappears, wall appears, in action doesn't do that.

Code:
function onAddItem(moveitem, tileitem, pos)

local fire = 1492
local energy = 1495

local firefield1 = {x=1369, y=766, z=8, stackpos=1}
local getfire1 = getThingfromPos(firefield1)

local firefield2 = {x=1373, y=766, z=8, stackpos=1}
local getfire2 = getThingfromPos(firefield2)

local firefield3 = {x=1371, y=767, z=8, stackpos=1}
local getfire3 = getThingfromPos(firefield3)

local energyfield4 = {x=1371, y=769, z=8, stackpos=1}
local getenergy4 = getThingfromPos(energyfield4)

local firefield5 = {x=1371, y=771, z=8, stackpos=1}
local getfire5 = getThingfromPos(firefield5)

local firefield6 = {x=1369, y=772, z=8, stackpos=1}
local getfire6 = getThingfromPos(firefield6)

local firefield7 = {x=1373, y=772, z=8, stackpos=1}
local getfire7 = getThingfromPos(firefield7)

local wall = {x=1368, y=791, z=8, stackpos=1}
local getwall = getThingfromPos(wall)

if getfire1.itemid == fire and 
getfire2.itemid == fire and 
getfire3.itemid == fire and 
getenergy4.itemid == energy 
and getfire5.itemid == fire 
and getfire6.itemid == fire 
and getfire7.itemid == fire 
then

doSendMagicEffect(cid,22)
doRemoveItem(getwall.uid,1)
doPlayerSendTextMessage(cid,19,'You inserted the right combination to open Kaldok\'s chamber. Enter before fields runs out of time!')
else
doCreateItem(1196,1,wall)
end
end
 
It should be used in action. I will try to fix it for you. but atm i dont got time. Send me a pm on thursday/friday and i will make it for you then. DONT send before ;p
 
It should be used in action. I will try to fix it for you. but atm i dont got time. Send me a pm on thursday/friday and i will make it for you then. DONT send before ;p

There's no problem brother, I figured it out...

I used on actions a lever, if you put the fields correctly, you are teleported to the chamber... and the fields are gone. Then the same action summons you a creature, that creature if you beat him you will automatically teleported into the 2nd island :p

Anyways thank you.
 
There's no problem brother, I figured it out...

I used on actions a lever, if you put the fields correctly, you are teleported to the chamber... and the fields are gone. Then the same action summons you a creature, that creature if you beat him you will automatically teleported into the 2nd island :p

Anyways thank you.


Np. Just send me a PM if you get into any other problems.

/Elaney
 
Back
Top