Setting Parallax's X and Y Origin Point

Discussion in 'RGSS3 Script Requests' started by Sophism, Aug 1, 2014.

  1. Sophism

    Sophism Veteran Veteran

    Messages:
    36
    Likes Received:
    6
    First Language:
    English
    So here's the scenario:

    My project has a pretty large map as its main hub  - 180 x 120 - and as one of its landmarks, I have this relatively small pond that I wish to have animated, transparent water and reflect sprites. I've already created a layered version from various snapshots, and separated them all into their appropriate files. I can even make it all work exactly as I want it to using overlaid images and animating the topmost layer through the use of a loop event with a conditional variable check.

    The problem lies with the script solution I have for reflections: It draws the reflected sprites on the parallax. With that limitation in mind, I created a hole where the water would be, so that the parallax becomes visible through the map, and overlaid the photoshopped edges of the pond over the gap to cover the square edges. I've then reinserted the layers as parallaxes, animated them through a script, and tile-locked them in place. The problem is, the parallax image underneath isn't aligned with the gap I created.

    Now, I'm aware that I wouldn't even be having this issue if I made sure my parallax images were the exact same size of my map. But 5 quickly cycling frames of PNG animation at 5760 x 3840 would probably bring most systems to their knees. As such, I'm in dire need of a script to set a parallax's X and Y origin point coordinates. (Preferably tied to a map id as well.) I've only been working with RPG Maker for two weeks, and although I'm a fast learner, scripting something from scratch isn't really feasible. (I did attempt to create one to do what I'm requesting, but it's clear after a couple of hours that I have no idea how to write a proper RGSS3 script.)

    While I'm not 100% sure that it's even possible to accomplish this, it definitely seemed like it from the way the Game_Map script has to determine a parallax's origin point before scrolling it.

    Any help would be greatly appreciated! Thanks beforehand!
     
    #1
  2. monkeyintartan

    monkeyintartan TartanMonkey Veteran

    Messages:
    195
    Likes Received:
    121
    Location:
    Stockport
    First Language:
    english
    I achieve this effect myself. What I have done is to maker the water tiles on my tile set slightly transparent so that you can see through them, I use Galv's Character effects to make the reflection in the water which is on the parallax layer, I found that with the water transparent rather than completely gone you still get the auto tile animation effect and see the reflection of the sprite underneath. that way you don't need to animate the parallax.

    As you can see in the picture you can see the reflection and the clouds effect of the parallax as well as the actual water

    Untitled-1.png
     
    #2
  3. Sophism

    Sophism Veteran Veteran

    Messages:
    36
    Likes Received:
    6
    First Language:
    English
    Hi! Thanks for taking the time to post one possible solution. Unfortunately, using animated tiles isn't really ideal for me, simply because I actually animated the entire body of water trying to get it to look a bit more striking. I'm currently forced to animate images over the map anyway, and the result isn't terrible looking:

    [​IMG]

    The problem is, since the parallax is being drawn under the 225 opacity image, it makes it look extremely washed out. Here's what I'd like to accomplish:

    1. First, I create this gap in the map so the parallax is visible.

    [​IMG]

    2. I then add the parallaxed water and animate it via Modern Algebra's script, while tile-locking it with Yanfly's.

    [​IMG]

    3. And finally I overlay the topmost layer to make it look seamless, fixing the picture in place with another Modern Algebra script.

    [​IMG]

    Notice how the parallax water would look more vibrant. It would look even better animated, whereas the animation is barely noticeable when I have the BlueSky parallax underneath a transparent picture. I just can't seem to make step 2 work because I can't shift the parallax layer's X and Y origin. If I can't find a way to do so, then I won't have any choice other than using the first method. I'd rather not give up hope yet though!
     
    #3
  4. Tsukihime

    Tsukihime Veteran Veteran

    Messages:
    8,230
    Likes Received:
    3,053
    Location:
    Toronto
    First Language:
    English
    Does yanfly allow you to specify where it gets tile locked?
     
    #4
  5. Sophism

    Sophism Veteran Veteran

    Messages:
    36
    Likes Received:
    6
    First Language:
    English
    It doesn't sadly. Both that script and Game_Map define and refer to a "parallax_ox" and "parallax_oy" though, which seem to be the origin points for the parallax. I tried to define their values, but I simply don't know enough about scripting to do it myself.
     
    #5

Share This Page