New account registration is temporarily disabled.

DOES ANYONE KNOW OF A WAY TO DISPLACE SPRITES BASED OFF COORIDINATES?

Posts

Pages: 1
This is for RMMV - sorry i forgot to specify that!

I know that using '!' before a sprite name indicates it should ignore the displacement effect meant for characters, but is there any other way to displace sprites in the default editor?

For instance, If Event1 is at cooridinates X,Y, then displace the sprite so many pixels up, down, left or right?


When you first arrive in Dali Village in FF IX the game has a low camera angle, and you can see the children running into the background. I'm attempting to recreate this type of effect using hand drawn maps, but I need to be able to displace sprites to the left/right and up/down as they move into the background of the image, so even though their position is at the top of the map, on camera their sprite is displaced to the proper position.

I'm pretty sure it's not a default function and I'd need a script for it, but I can't find anything. Did find one thing about screen effects which I think'll come in handy though. Pixi Filter Controller to be specific.
Marrend
Guardian of the Description Thread
21806
Dunno how much this helps, but, I gave a look at...

class Sprite_Character < Sprite_Base
  #--------------------------------------------------------------------------
  # * Update Position
  #--------------------------------------------------------------------------
  def update_position
    move_animation(@character.screen_x - x, @character.screen_y - y)
    self.x = @character.screen_x
    self.y = @character.screen_y
    self.z = @character.screen_z
  end
end

...this function, in VX Ace. The idea being that we might be able to use self.zoom_x and/or self.zoom_y as the sprite moves further from the center from the screen. The exact zoom factor would probably need to be figured out later, but, whatever. I was assuming @character.screen_x and/or @character.screen_y would be constant when idle...

class Sprite_Character < Sprite_Base
  #--------------------------------------------------------------------------
  # * Update Position
  #--------------------------------------------------------------------------
  def update_position
    move_animation(@character.screen_x - x, @character.screen_y - y)
    self.x = @character.screen_x
    self.y = @character.screen_y
    self.z = @character.screen_z
    puts(@character.screen_x)
  end
end

...but the console output proved otherwise. Which baffles me to no end!

*Edit: ...Until I realize that this function is being called by all events on the map. So, it probably is static, but, the way it's written, it was running to display the x-coordinate for both events on the test-map.
Oh, I forgot to mention I'm using MV for this, I'm sorry!

I could probably look into the games code and try to find where the pixel displacement for certain characters is and try and use that, but I don't know how...
Yanfly has a Sprite Offset plugin, that might do what you're looking for. I've never used it myself though.
Event Sprite Offset
Pages: 1