Maze Generation Fail
#7

Ok, well anyways strings don't work in ternary do they? I get errors on the following lines of you script:

pawn Код:
strcat(grid, (CELL[X/2+1][Y/2+1][in] ? "M" : "_"));//(184) : error 001: expected token: "-string end-", but found "-identifier-"
strcat(grid, (CELL[X/2+1][Y/2+1][left] ? "M" : "_"));//(194) : error 001: expected token: "-string end-", but found "-identifier-"
strcat(grid, (CELL[X/2+1][Y/2+1][up] ? "M" : "_"));//(199) : error 001: expected token: "-string end-", but found "-identifier-"
You just forgot to wrap the strings in parenthesis.



Your code also runs into an infinite loop when using:
pawn Код:
#define xsize 64
#define ysize 48
It's not 'Index[1]' or 'Index[2]'.
Reply


Messages In This Thread
Maze Generation Fail - by Crayder - 08.03.2015, 06:45
Re: Maze Generation Fail - by Misiur - 08.03.2015, 13:48
Re: Maze Generation Fail - by Crayder - 08.03.2015, 16:46
Re: Maze Generation Fail - by Misiur - 08.03.2015, 17:01
Re: Maze Generation Fail - by Crayder - 08.03.2015, 17:39
Re: Maze Generation Fail - by Misiur - 08.03.2015, 17:58
Re: Maze Generation Fail - by Crayder - 08.03.2015, 18:02
Re: Maze Generation Fail - by Crayder - 09.03.2015, 17:10
Re: Maze Generation Fail - by Misiur - 09.03.2015, 18:49
Re: Maze Generation Fail - by Crayder - 09.03.2015, 18:58

Forum Jump:


Users browsing this thread: 3 Guest(s)