Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / Yay! I did it.

Author
Message
Dark Dragon
16
Years of Service
User Offline
Joined: 22nd Jun 2007
Location: In the ring, Kickin\' *donkeybutt*.
Posted: 18th Feb 2010 03:35
I Finally built a TileMap system with layers. Its only taken me about...............a good year or two to understand them.

Well, i thought i might post this out here before I get into somthing else..................*Attaches zip*

(\__/) HHAHAHAHAHAH!
(O.o ) / WORLD DOMINATION!!!!!!!!!!
(> < )

Attachments

Login to view attachments
Latch
17
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 20th Feb 2010 08:29
Not bad DD.

It scrolls very smoothly. It's only one screen, right?

Enjoy your day.
29 games
18
Years of Service
User Offline
Joined: 23rd Nov 2005
Location: not entirely sure
Posted: 21st Feb 2010 19:50
That works really well.

Is it done in 2D? It looks as if it has been. I've not done much with 2D. I've never really got 2D to work the way I want it to.
Dark Dragon
16
Years of Service
User Offline
Joined: 22nd Jun 2007
Location: In the ring, Kickin\' *donkeybutt*.
Posted: 28th Feb 2010 04:31
Yes, it is completely done in 2d. I have source code for any one who wants it........

Quote: "It's only one screen, right?"


I dont understand your question.....?

(\__/) HHAHAHAHAHAH!
(O.o ) / WORLD DOMINATION!!!!!!!!!!
(> < )
Latch
17
Years of Service
User Offline
Joined: 23rd Jul 2006
Location:
Posted: 28th Feb 2010 08:04
What I mean is, how large is the map?

Enjoy your day.
Dark Dragon
16
Years of Service
User Offline
Joined: 22nd Jun 2007
Location: In the ring, Kickin\' *donkeybutt*.
Posted: 23rd Mar 2010 01:09
its a 8x8 (uh, i think i used 64x64 tiles??)map, 5 layers(only 3 have stuff on it)

(\__/) HHAHAHAHAHAH!
(O.o ) / WORLD DOMINATION!!!!!!!!!!
(> < )
Ashingda 27
16
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 23rd Mar 2010 20:21
Good work and yes if you don't mind showing the source I'd like to see it . Can always learn a thing or two.
Dark Dragon
16
Years of Service
User Offline
Joined: 22nd Jun 2007
Location: In the ring, Kickin\' *donkeybutt*.
Posted: 23rd Mar 2010 23:44
k, ashingda. here ya go.
Comments are semi-tutorial like, because i had to explain to a coding buddy.



Quote: "Can always learn a thing or two. "

Wow,lol, I'd never thought I could come up with somthing that the DBprofessionals would learn from......

(\__/) HHAHAHAHAHAH!
(O.o ) / WORLD DOMINATION!!!!!!!!!!
(> < )
seppgirty
FPSC Developer
14
Years of Service
User Offline
Joined: 3rd Jul 2009
Location: pittsburgh, pa.
Posted: 24th Mar 2010 00:10
really cool DD. thanks for sharing

gamer, lover, filmmaker
Dark Dragon
16
Years of Service
User Offline
Joined: 22nd Jun 2007
Location: In the ring, Kickin\' *donkeybutt*.
Posted: 24th Mar 2010 00:14
Quote: "really cool DD. thanks for sharing "


No Prob, at all. Glad to help, For once.

(\__/) HHAHAHAHAHAH!
(O.o ) / WORLD DOMINATION!!!!!!!!!!
(> < )
Ashingda 27
16
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 24th Mar 2010 00:38
Ahh the thought of using floats for the scroll values totally escaped my mind, I'll have to try it.

Only one piece of advice, when saving loading the map array use WORD instead of STRING because strings have a limit of 256 or so characters.
Dark Dragon
16
Years of Service
User Offline
Joined: 22nd Jun 2007
Location: In the ring, Kickin\' *donkeybutt*.
Posted: 24th Mar 2010 04:38
Thanks for the advice! Say, you gonna use something simular for Fruit Warz? That be cool.

(\__/) HHAHAHAHAHAH!
(O.o ) / WORLD DOMINATION!!!!!!!!!!
(> < )
Ashingda 27
16
Years of Service
User Offline
Joined: 15th Feb 2008
Location:
Posted: 24th Mar 2010 05:02
Actually yes, seeing your smooth looking scrolling makes me want to use it for Fruit Wars too as a lot of the time that's what the player would be able to do -_^.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 24th Mar 2010 17:30
Very nice work DD! It scrolls very smoothly. Also, it was easy for me to change the scrolling speed on a layer to create a depth perspective.

I would suggest making the file loading into a subroutine.

O G Money
14
Years of Service
User Offline
Joined: 26th Mar 2010
Location: Arlington
Posted: 26th Mar 2010 14:54
nice

$Money$
Dark Dragon
16
Years of Service
User Offline
Joined: 22nd Jun 2007
Location: In the ring, Kickin\' *donkeybutt*.
Posted: 27th Mar 2010 16:17
Quote: "
I would suggest making the file loading into a subroutine."


might I ask why? my buddy said the same thing and i dont understand why?

(\__/) HHAHAHAHAHAH!
(O.o ) / WORLD DOMINATION!!!!!!!!!!
(> < )
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 27th Mar 2010 16:45
DD

Since you repeat practically the exact same code twice, it would be more efficient to put it into a subroutine and call it. Some of the main ideas behind using subroutines are that they will provide efficiency and clarity of code.

Let's say that you have four different worlds in which the player can explore and you use all three layers with each; that's 12 files to load. Without a subroutine, you would have to write the same thing 12 times.

Dark Dragon
16
Years of Service
User Offline
Joined: 22nd Jun 2007
Location: In the ring, Kickin\' *donkeybutt*.
Posted: 30th Mar 2010 03:51
Quote: " that's 12 files to load. Without a subroutine, you would have to write the same thing 12 times."


ahh.....i see. now i understand. ok. thanks for pointing that out. now i feel like a noob.

(\__/) HHAHAHAHAHAH!
(O.o ) / WORLD DOMINATION!!!!!!!!!!
(> < )

Login to post a reply

Server time is: 2024-04-27 02:48:36
Your offset time is: 2024-04-27 02:48:36