Page 1 of 1

Teleporter help

Posted: Tue Jun 06, 2006 10:08 pm
by BradW
Here's someone else asking for teleporter help.

I've seen example maps with 2 teleporters like this:




teleporter
position -288.5 35 0
rotation 0
size 0.125 10 10
border 1
end

teleporter
position 246.5 -29.5 0
rotation 0
size 0.125 10 10
border 1
end

link
#!name Link
from 0
to 2
end

link
#!name Link
from 1
to 3
end


I'm confused... there are 2 teleporters but 4 numbers used in links, do they refer to the two faces of the teleporters? i.e. 0 and 1 are the faces of the first, and 2 and 3 are the faces of the second?

thanks for any help.

Posted: Tue Jun 06, 2006 11:55 pm
by JeffM
links point to sides,

link sides 0 and 1 are on teleporter 1, sides 2 and 3 are on TP 2.

every teleporter has 2 sides.

Posted: Wed Jun 07, 2006 7:49 am
by optic delusion
might be easier for you if you give each tele a name, too.

Posted: Wed Jun 07, 2006 7:57 am
by trepan
Read the "teleporter object" and "link object" sections:
http://my.bzflag.org/bzfman.cgi?bzw.5.in

Posted: Fri Jun 09, 2006 8:39 pm
by BradW
The names are a bit unclear to me as well.

For example in this code:

# or, to link between known teleporters examp_tele1(front) and
examp_tele2(back)

link
name example_realLink
from examp_tele1:f
to examp_tele2:b
end



are f and b 0 and 1? or are they dependent on what order the teleporters are specified in the file?

Thanks for the help, I've been fiddling with some teleporters for hours trying to get them to work and the results are very confusing. These docs often aren't terribly clear to me.

Posted: Fri Jun 09, 2006 9:05 pm
by optic delusion
f is front, b is back

the numbers will depend on the order specified in the map, unless you give them names, in which case the numbers should be removed and replaced by names.

Trial and error is the only real solution, I've never heard of anybody that can get more than three teleporters to link correctly, the first time.
Just wait until you try to rotate a teleporter, then you'll really be confused.

Posted: Mon Jun 12, 2006 11:41 pm
by BradW
Got it, thanks guys.

I was confused about names because there seem to 2 name entries in the teleporter field. Sorted out now though.