Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Top Scrolling RPG
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
B-MAN




PostPosted: Thu May 29, 2003 8:46 am   Post subject: Top Scrolling RPG

i'm working on an rpg for my culminating activity, i've got the battle procedures worked out(quite exhausting) but i need a way to make the map scroll on an overhead map, it's due in 2 weeks so please try to help asap!!!
Sponsor
Sponsor
Sponsor
sponsor
Tony




PostPosted: Thu May 29, 2003 9:47 am   Post subject: (No subject)

you should draw the map in relation to player's position, so the player is always seen in the middle of the screen.

So basically when player goes down by 1, map moves up by 1.
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
B-MAN




PostPosted: Thu May 29, 2003 11:46 am   Post subject: (No subject)

oOo, ok, but how would you redraw the map with each move so that the character would still be in the center but in a different position overall on the map?
Homer_simpson




PostPosted: Thu May 29, 2003 1:39 pm   Post subject: (No subject)

well let's see:
player.x
player.y
map.x
map.y

player.x+1 results in map.x+1
player.x-1 results in map.x-1
player.y-1 results in map.y+1
player.y+1 results in map.y+1
drawmap(map.x,map.y)
drawplayer(320,200)
B-MAN




PostPosted: Fri May 30, 2003 12:15 pm   Post subject: (No subject)

Thanks, now it's working i'll put it up when i'm finished
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 5 Posts ]
Jump to:   


Style:  
Search: