PDA

View Full Version : easy variable question


mullwaden
12-01-2003, 07:45 PM
i wanted to make a variable that looks like this:


hittop = "gubbe.hitTest(game.walls.t1) || gubbe.hitTest(game.walls.t2) || gubbe.hitTest(game.walls.t3) || gubbe.hitTest(game.walls.t4) || gubbe.hitTest(game.walls.t5)";


i doesn't seem to work ... is i att all possible to do like this ? :D

cobo
12-02-2003, 08:16 AM
test it without the pipes

cobo

mullwaden
12-02-2003, 12:55 PM
whats a pipe ? :P

tg
12-02-2003, 12:59 PM
pipe=|

in flash the symbols || means 'or' so these 'pipes' may be messing you up.

tg
12-02-2003, 01:02 PM
hmm...

testing it i put in:

hittop = "gubbe.hitTest(game.walls.t1) || gubbe.hitTest(game.walls.t2) || gubbe.hitTest(game.walls.t3) || gubbe.hitTest(game.walls.t4) || gubbe.hitTest(game.walls.t5)";

trace(hittop);

my output was 'gubbe.hitTest(game.walls.t1) || gubbe.hitTest(game.walls.t2) || gubbe.hitTest(game.walls.t3) || gubbe.hitTest(game.walls.t4) || gubbe.hitTest(game.walls.t5)'

so it seams to work.

bassouma86
12-02-2003, 04:50 PM
it should.

the actionscript tag did colour it so it must be valid ;)

right ??