Computer Science Canada

Isometric Maze Generator

Author:  TheXploder [ Tue Jan 20, 2004 5:12 pm ]
Post subject:  Isometric Maze Generator

Here is the Iso Maze generator that I made.
* It has two parts to it 'IsoMaze.t' and 'figures.t' you just need to put both of them into the same folder and run 'IsoMaze.t'.

This can be updated to fit the newer version of turing, I think that way it could be spead up a bit... Wink

Author:  TheXploder [ Wed Jan 21, 2004 10:10 pm ]
Post subject: 

Crying or Very sad No Posts Crying or Very sad
any comments are welcome...

Author:  AsianSensation [ Wed Jan 21, 2004 10:28 pm ]
Post subject: 

nice....I like the isometric point, that was very cool, here, have some bits.

+50 bits

Author:  sport [ Wed Jan 21, 2004 10:28 pm ]
Post subject: 

Great stuff. The question is can you make some barriers and allow the user to walk through the maze to the exit and have the exits guarded and make a time limit. Basicly make a game out of it. Then it will be really awesome. Random generation kinda seems the same so far.

Author:  Tony [ Wed Jan 21, 2004 10:46 pm ]
Post subject: 

looks original Very Happy Maybe you should create an engine for various isometric displays or something 8)

Author:  DanShadow [ Thu Jan 22, 2004 12:28 am ]
Post subject: 

[EDIT] Deleted.
woops, double posted somehow

Author:  DanShadow [ Thu Jan 22, 2004 12:29 am ]
Post subject: 

wow! I am totally impressed....this is truly excellent work...my ISU this year is an RPG using isometric graphics....but this is ju st awesome! Seeing as I used nearly the same type of idea as you, I know kind of how its done (without looking at code)...but y ou did it the harder, more efficient way...good job!! Have some bits to round you off:
[+11 Bits]

(PS) Is there any point to your program?? Like...there was no precoded maze...and I couldnt find any key to move the yellow box.. Confused

Author:  TheXploder [ Thu Jan 22, 2004 9:06 am ]
Post subject: 

hey thanx for the generosity Smile

The point isn't clear beuse it's just an example but you could make something huge out of it.

The walls I just drew with a for loop.
I gotta figure out how to get the map array just from a text file
contaning code like thisif;

1111111111
1000000001
1000000001
1000000001
1000000001
1000000001
1000000001
1000000001
1000000001
1111111111

The yellow object is just testing out the collision.
The collision works already but it needs some tweaking.
Good thing about this isometric maze is that you can rezise it.
If you change the gridsize values, the maze scales down, or up.
You can also change the colour of the bricks, bacuase their not bitmap.

When I figure out a way to load text files and read them i'll make an updated version. Wink

Author:  agent_orange444 [ Thu Jan 22, 2004 6:24 pm ]
Post subject: 

nice job, it would certainly make a fun and great looking game!

Author:  DanShadow [ Thu Jan 22, 2004 10:25 pm ]
Post subject: 

here, try this:
code:

var mapx,mapy,mapt:array 1..9 of int
%Mapx,mapy = (x,y) co-ordinates, mapt= map tile type
for i:1..9
mapt(i):=1
end for
for i:1..3
mapx(i):=0 +(i*25)
mapy(i):=25
end for
for i:4..6
mapx(i):=25+(i*25)
mapy(i) :=50
end for
for i:7..9
mapx(i):=50+(i*25)
mapy(i):=75
end for

%Main Program
loop
end loop

%------------------------Saving to txt----------
var datafile:int
open:datafile,"savefile-name",put
for i:1..9
put:datafile,mapx(i)
put:datafile,mapy(i)
put:datafile,mapt(i)
end for
close:datafile
%------------------------Loading txt----------------
open:datafile,"savefile-name",g et
for i:1..9
get:datafile,mapx(i)
get:datafile,mapy(i)
get:datafile,mapt(i)
end for
close:datafile

Author:  TheXploder [ Fri Jan 23, 2004 2:10 pm ]
Post subject: 

thx Very Happy, could you please explain how this works:

code:
for i:1..9
mapt(i):=1
end for
for i:1..3
mapx(i):=0 +(i*25)
mapy(i):=25
end for
for i:4..6
mapx(i):=25+(i*25)
mapy(i) :=50
end for
for i:7..9
mapx(i):=50+(i*25)
mapy(i):=75
end for

Author:  TheXploder [ Thu Jan 29, 2004 1:04 pm ]
Post subject: 

Hey, I'm making an updated version of my last Isometric Generator, which was ok... Smile

I am completely recoding everything, and I'll try to keep an update on my progress.. But could someone please write a tutorial on how to include a text file, that would hold a map array, and how to implement it into the turing program with a loading proccess.. that would help a lot... I'm ready to support you, with bits... Very Happy

Anyway enjoy, It just generates an Iso plane (the right way Laughing )...

Author:  Thuged_Out_G [ Sun Feb 01, 2004 1:24 pm ]
Post subject: 

to write to a text file use this

code:

var stream:int
var words:array 1..1000
open:stream,"filename.txt",put
assert stream > 0

for i:1..1000
put:stream,words(i)
end for


reading from a file

code:

var stream:int
var words:array 1..1000
var count:=0

loop
count +=1
get:stream,skip %skips all the white space
exit when eof(stream) %exit when your at the end of the file
get:stream,words(count) %get each word, one at a time and store it in an array
end loop

Author:  TheXploder [ Tue Feb 17, 2004 10:06 pm ]
Post subject: 

Here a the newer version of of the Isometric Generator...

For the array the only numbers used are '1's and '0's but there are 13 tiles in total.

1 - bushy grass plane.
1 - flat grass planes.
8 - connections between bushy grass planes and flat grass planes.
3 - others.

This will achive a simplicity to modelling iso maps - I'm trying to achive a Warcraft III like map editor.

Author:  zylum [ Tue Feb 17, 2004 10:29 pm ]
Post subject: 

that's not really isometric but a good attempt non the less. by definition isometric means equal sided. for an accurate isometric view, you need to start off with your map looking at it from a birds eye view. then you rotate the map 45 degrees on the y axis and 30 degrees on the x axis. also when i run it, it doesnt really generate a maze. is it supposed to???

if you're going to make a game out of this i suggest you plan ahead... i tried to program an isometric game in one sit with out any planning and i ended up quiting... i got the depth sorting and stuff to work but when it came to collision detection it became way to complex...

anyways, good effort and good luck with it

-zylum

Author:  zylum [ Tue Feb 17, 2004 10:31 pm ]
Post subject: 

hmm, im getting an error when i try to run your new one

Author:  TheXploder [ Tue Feb 17, 2004 10:47 pm ]
Post subject: 

maybe you might wanna try extracting all the files within the zipfile...

Author:  zylum [ Tue Feb 17, 2004 11:27 pm ]
Post subject: 

all the files are exported -_-.. the error says that you're looking for a file located at "Exported Maps\\map.txt" notice the double backslash... is that the problem???

Author:  TheXploder [ Wed Feb 18, 2004 3:16 pm ]
Post subject: 

No... which file are you running? Try to run Isometric.t

Author:  zylum [ Wed Feb 18, 2004 9:27 pm ]
Post subject: 

hmm, i am trying to run isometric.exe... i also redownloaded it and it still doesnt work... can you post the .t??

did anyone else get it to work???

Author:  TheXploder [ Wed Feb 18, 2004 9:59 pm ]
Post subject: 

It works for me... hmm.. ok, I'll post it again...

Author:  the_short1 [ Sat Feb 21, 2004 5:03 pm ]
Post subject: 

DUDE: This program Kicks a$$.. it would ROCK in a Pac man... right now i only have one layout in mine.. i was planning on making more in future and adding as more .t file... cool i can learn off urs to import files... GJ!!!!!

but each extra layout for me is like another 1000 + lines of code seriously so far my program has 2300 lines of code

SWEET Program.....keep on working hard to read from a text file deal..


and yea... its the // deal taht makes it wrong..
try to fix that... eithger taht or u used the \ <<dont wokr>>

and i extracted to Folder using Folder names... so yea..

Author:  TheXploder [ Sat Feb 21, 2004 6:59 pm ]
Post subject: 

hmm, what turing version do you have? because for me '//' works....

[Edit] What? Both '/' and '//' work for me, gee... what is the difference?

Author:  the_short1 [ Sat Feb 21, 2004 10:42 pm ]
Post subject: 

i got new turing version.... (super new)

well...
please post the line of code taht says:

Open this file blah blah blah for map.txt
please and ty... then maybe we can fix dis

Author:  TheXploder [ Sat Feb 21, 2004 11:00 pm ]
Post subject: 

well go into the exported maps folder and there is a .t file that is the program that loads the map... it is included in the .exe though... so it runs it in the .exe and it has to find the map.txt file in this folder ('Exported Maps')...

Author:  the_short1 [ Sun Feb 22, 2004 12:14 am ]
Post subject: 

may workj for u... but give it a try please and only have one slash... also can you post line 8 of your code please...since that is the line with the error... i want to see it

Author:  TheXploder [ Sun Feb 22, 2004 2:26 pm ]
Post subject: 

what is the error message? I got this in line 8:
code:
include "Exported Maps\maploader.t"


Damn why doesn't the attachment work...

Author:  the_short1 [ Mon Feb 23, 2004 8:09 am ]
Post subject: 

Quote:
open : stremin, "Exported Maps//map.txt"

this is a line in ur program maploader.t

see the error...

slashes should be / for internet.... \for explorer ....
so maybe try fixing that....

Author:  the_short1 [ Mon Feb 23, 2004 4:33 pm ]
Post subject: 

and download this .zip file that you submited... then Extract to a folder on your hard drive... lets say c:\ISO TEST FOLDER\ and you run the program??

have u tried that before submiting file????

Author:  TheXploder [ Mon Feb 23, 2004 5:38 pm ]
Post subject: 

yes... I tryed that many times

Author:  the_short1 [ Mon Feb 23, 2004 8:51 pm ]
Post subject: 

then i cant help no further...

i am out of suggestions..


: