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.

Newcomers DBPro Corner / 2d mapping and storing information in a file

Author
Message
Dc GameMaker
21
Years of Service
User Offline
Joined: 24th Oct 2003
Location: Somewhere in the midsts of Canada
Posted: 24th Oct 2003 08:23
hey im really new to dark basic and im having some trouble. How do you create 2d maps and sprites?(kinda like in ff4.) If you could tell me or know of a tutorial, that would be great. and i was also wondering.. well im working on a simple project where the user inputs some informaion and I want that info to be stored in a file that can be accessed through my program. If someone could please help me I would greatly appreciate it
y!Ck
21
Years of Service
User Offline
Joined: 2nd Jul 2003
Location: Europe - Netherland
Posted: 24th Oct 2003 14:17
you create a bitmap map and make from all things in the map where you aren't supposed to walk trough:bitmap you load the map bitmap as a big sprite, you load all the extra bitmaps where yoe aren't supposed to walk troough as sprite's and then you make your object
and people and stuff sprites too and then you use sprite hit or collision one by one like:
lets say sprite 2 is a little bystander and one is a player

hope this helps

do
rem first store your old sprite position
oldspriteposx=sprite x(1)
oldspriteposy=sprite y(1)

rem here comes your movement code

rem now you position your sprite

rem now store new sprite position's
newspritex=sprite x(1)
newspritey=sprite y(1)

rem now the sprite collision
if sprite collision(1,2)
newspritex=oldspriteposx
newspritey=oldspriteposy
endif
rem and this you do with all of your sprite's you don't want to
rem walk trough.

rem and now you reposition you're sprite

Why live life if you die anyway.
Dc GameMaker
21
Years of Service
User Offline
Joined: 24th Oct 2003
Location: Somewhere in the midsts of Canada
Posted: 24th Oct 2003 23:37
thanks y!ck, that helps alot

Login to post a reply

Server time is: 2024-11-25 14:33:37
Your offset time is: 2024-11-25 14:33:37