8-Directional movement

Discussion in 'RGSS3 Script Requests' started by mrbud420, Feb 24, 2018.

  1. mrbud420

    mrbud420 Warper Member

    Likes Received:
    First Language:
    Primarily Uses:
    I am trying to use the PVgames Wildsteam pack assets from the Steam store. I understand a basic character sheet with 4-directions up,down,left,right,idle and but I really want to learn how to use the character sheets from PVgames resources as I like their style a lot. I know VXAce does not use 8 directional movement and I would need a script to use those assets. I have multiple character sheets for 1 character there is an up,down,left,right walking sheet a diagonal walking sheet, two more of those sheets but with running animations instead of walking plus they have their own idle sheet for when they are not moving at all.

    That's 5 different sprite sheets for one character and I want my character to be able to walk and run in all directions. I know I will probably need a script or two and wanted to see if anyone could point me in a good direction to start looking. I know how to use gimp and I made a few characters just don't understand how to implement them into VXAce.
  2. Kes

    Kes Global Moderators Global Mod

    Likes Received:
    First Language:
    Primarily Uses:
    'Scripts' is where people who have written complete scripts and want to share them with others can post them.

    I've moved this thread to RGSS3 Script Requests. Please be sure to post your threads in the correct forum next time. Thank you.

    PV Games has a script which can be used with their sprites. I suggest you check out their web site.
    Wavelength likes this.
  3. gstv87

    gstv87 Veteran Veteran

    Likes Received:
    First Language:
    Primarily Uses:
    you can condense all 8 directions into one sheet, but you'll need to edit the scripts that load those sheets (simple as changing the size and the number of rows), and the script that controls the direction (harder to do, because it's several different functions)

    look into these functions
    class Sprite_Character
      set_bitmap                     #<<< load the sheet itself
      set_dimensions             #<<< resize, rows by colums
      set_character_bitmap   #<<< set sub-sheet, if applicable, for individual characters or extras
      update_src_rect            #<<< update the frame being drawn (X out of Y, out of sprite sheet)
    class Game_CharacterBase
      init_private_members   #<<< init max frames per sheet, max rows, initial frame, etc
      update_animation         #<<< reset frame (X == Y? -> X = initframe)
      update_anime_count    #<<< increase frame while standing (X+1 out of Y, out of sprite sheet)
      update_anime_pattern #<<< increase frame while moving

    you can link update_anime_pattern, update_anime_count, and set_character_bitmap if you have a walking cycle and a standing cycle: while walking, set bitmap, update at walking speed; while standing, set another bitmap, update at different speed.
    Last edited: Feb 24, 2018

Share This Page