2 Replies - 8078 Views - Last Post: 08 November 2011 - 06:32 AM

#1 wight faux   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 2
  • Joined: 06-October 11

C# coding help/XNA Game 4.0

Posted 02 November 2011 - 03:32 PM

Hi all,

I am trying to make a simple game using Visual Studion 2010, with a XNA Game 4.0 project. What i am trying to do is once my avatar moves close to the edge of the screen (top, bottom, left and right) i would like the background to change ( so that it is a new location, as well as the avatar's X/Y coordinates change as well when it crosses/enters into the new location. I have a base background picture already ( using simple 2D pics for this game) so how would i go about doing this? Any help is greatly appreciated!!!

Thanks!!!

Is This A Good Question/Topic? 0
  • +

Replies To: C# coding help/XNA Game 4.0

#2 Fib   User is offline

  • D.I.C Addict
  • member icon

Reputation: 163
  • View blog
  • Posts: 554
  • Joined: 12-March 09

Re: C# coding help/XNA Game 4.0

Posted 03 November 2011 - 11:39 AM

Hello wight faux,

So do you want the map to scroll when the player gets to the edges like 2D mario games? Or something like the first Legend of Zelda where the map moves over to a different screen when you touch the edge? Or do you just want the player to teleport to a different map once the player touches the edges?

Please clarify exactly what you want so that we can help you.

This post has been edited by Fib: 03 November 2011 - 11:40 AM

Was This Post Helpful? 0
  • +
  • -

#3 Kilorn   User is offline

  • XNArchitect
  • member icon



Reputation: 1361
  • View blog
  • Posts: 3,534
  • Joined: 03-May 10

Re: C# coding help/XNA Game 4.0

Posted 08 November 2011 - 06:32 AM

Well, since the original poster hasn't posted, I'm going to assume that they want a Legend of Zelda style system where you move into a different "room" when you reach the edge of the screen. I think I would set it up to have a Room class where each "room" on the entire map was an instance of this class and had fields that would keep track of a "zone" point that would send the character into the appropriate room based on the data for that "zone" point. I'd show an example, but it would require several different classes to use for the example and I'm not sure the original poster is going to come back, so maybe I'll wait on that.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1