dcsimg
A Flash Developer Resource Site

Results 1 to 5 of 5

Thread: [cs3] Help! Rpg Game Problems

  1. #1
    Junior Member
    Join Date
    Oct 2008
    Posts
    23

    [cs3] Help! Rpg Game Problems

    Hello, i am making an RPG game and i am making different layers to amke the world
    like right now i have a layer that goes over top of the player for roofs and stuff and then i have one that goes under for floors, and now i just need one for walls. is there any way i can make a layer a boundary layer? so that anything i draw on that layer my character cannot walk through?

    if anyone can help me that would be really great! thanx

    Also, i am look for a way to make it so when my character moves around its not actually moving him but its moving the stage.. is this possible?

  2. #2
    Trainee coder Viza's Avatar
    Join Date
    Sep 2006
    Location
    Melbourne, Down under
    Posts
    513
    First of all, these are pretty simple problems. I'm assuming you're new to Flash, and therefore maybe you wanna start with something easier other than an rpg game. What about Pong?!.. Everybody loves Pong! .... right guys?

    Seriously though, make a mouse avoider game, with your own original twist, or even a SIMPLE side scrolling shooter?

    Anyway, nobody likes being told what to do, so if you wanna carry on with this and are willing to put up with running into these simple problems every hour or so here's what you can do to fix your current problems:
    1. Check out a function called 'hitTest()'. Use Flash's help files (they're always handy), and a must-read is the knowledgebase at the top of the games forum as a sticky.. Here's a relevant link from the Knowledgebase sticky that should get you started.
    2. Change your current code from this:
    PHP Code:
    if (Key.isDown(Key.RIGHT)) {
      
    this.character._x += 5;

    to this:
    PHP Code:
    if (Key.isDown(Key.RIGHT)) {
      
    this.floor._x += 5;

    As you can see, in the second example the character will remain in the same spot, but it will appear as though it's moving because the background is moving underneath it

    Good luck!

    Viza.

  3. #3
    Junior Member
    Join Date
    Oct 2008
    Posts
    23

    fixed it!

    i was experimenting and i found it out myself but thanks anyways
    Attached Files Attached Files

  4. #4
    Junior Member
    Join Date
    Oct 2008
    Posts
    23

    new

    this is my newer version
    i need some input though... what should i have the scene look like?
    Attached Files Attached Files

  5. #5
    Intermediate Game Dev pseudobot's Avatar
    Join Date
    May 2008
    Location
    New Zealand
    Posts
    561
    Don't mix isometric environment with a top-down player. Chose one or the other.
    Needs an update...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center