Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

8-direction movement + graphics

Hello, everybody. I might be a newbie with scripting, but at least I'm trying to learn. I found out that with SDK, it's easy to make player move in eight directions by doing this:

def update_player_movement
# Move player in the direction the directional button is being pressed
    case Input.dir8
    when 1
      move_lower_left
    when 2
      move_down
    when 3
      move_lower_right
    when 4
      move_left
    when 6
      move_right
    when 7
      move_upper_left
    when 8
      move_up
    when 9
      move_upper_right
    end
  end

I would like to know how to make player use different graphic file when moving in the NE NW SE SW directinons.

The graphic file would look like this:
http://www.univelka.net/rmxp_res/001-Fighter01B.png
 
You would need to rewrite Sprite_Character, so it would change the sprite as needed.
Check F0tz PixelMovement Script, it has 8 dir, and you can see what he has done in the Sprite_Character.

Also there are alot of 8 dirs scripts around just search around a little.
 
That's right, there are a lot of that kind of scripts. But there's a problem, that almost every script I've tried to download from this forum lately, doesn't work. There's no actual script, only the demo that can't be downloaded (I don't know why. It just throws the 404).

I have actually managed to dowload one, but it's so complicated that I have no use for that. It makes player and npc:s use eight directions and more frames, and I'm not good enough to cut non-needed things out from the script or actually draw more frames and directions for every single characterset (because if I don't do that with the script I've tried, the normal style characters lose head). I'm using RTP graphics, and all I want is to make main character move in eight directions. If I do that, I need only one extra charset for the NE SE NW SW directions. I don't want to change the whole charset system...

I really try to search working script for this. It's just so depressing to get those 404:s with almost every single thing I try to download.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top