Change actor zoom/scale and speed according to Y axis?

Status
Not open for further replies.

Jonath4nC

Kiwi
Veteran
Joined
Aug 13, 2013
Messages
54
Reaction score
45
First Language
English
Primarily Uses
Hi all,

So there's a really cool script here that allows you to scale actor's and event's size. I want to see if I can give my game a depth perspective, so I'm wondering, is there a way to alter the actor's scale depending on his/her y axis along individual pixels (not by grid)? So the further up the actor is on the map, the smaller he/she gets and the lower the actor is, the larger he/she gets.

Again, the script is found here - Aramis Sprite Zoom

I was also thinking that the speed of the actor would appear slower the further away he/she is (take longer to get from one side to the other on the x axis), so I'm wondering if there is also a way to change the actor's speed according to their y axis as well? (I did notice though, when you did this through events, the animation is slower which is not what I want haha. So if the actor could be slower, but keep the same frame-rate?)

Thanks!
 

p0_boy

anti-kumbaya
Veteran
Joined
Mar 26, 2019
Messages
64
Reaction score
29
First Language
English
Primarily Uses
RMMV
@Jonath4nC - I was just pondering this and came across @Aramis-IX 's great plug-in too.

I wrote this script, which runs in a parallel process (you need a switch to trigger it):

Code:
var gp_id = ($gamePlayer._realY + 1) / $dataMap.height;
if ($gameVariables.value(10) != gp_id) {
    SpriteZoom.zoom(0,gp_id);
    $gamePlayer.setMoveSpeed(Math.round(($gamePlayer._realY + 1) * (6/$dataMap.height)));
    $gameVariables.setValue(10,gp_id);
};
It needs to be adjusted and tweaked though, depending on the application.

Animated GIF Example [gfycat.com]

Ideally, I think it should run within the process that checks if the Up or Down buttons are being pressed. I have no idea though what that is.

Also, normal size/speed should be in the middle of the map, large/fast on the bottom, and tiny/small at the top (right now it is just normal/fast at the top, medium/average in the middle, small/slow on the bottom). This can be done with adjustments to the equations but I just woke up and need to eat before I tackle this.

Hope this helps. LMK if you think of any improvements.
 
Last edited:

slimmmeiske2

Little Red Riding Hood
Global Mod
Joined
Sep 6, 2012
Messages
8,010
Reaction score
5,317
First Language
Dutch
Primarily Uses
RMXP
@p0_boy While it's nice of you to help, the OP hasn't been on here for nearly a year. So I'm going ahead and close this.

Closing this now. OP, if you want this reopened, please report this post, thanks.

 
Status
Not open for further replies.

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Profile Posts

Oh wow, just got word the police are looking for an armed suspect within a 2 block radius of my office. Super glad I'm not there right now. :kaoswt:
Sheila Nagase

same caption as before. :3
"Be as honest as you possibly can as often as you can. It makes your lies much easier to believe."
Each new game means new ways to survive and you need to adapt when you have 10 different stores with lots of items for your adventure

Forum statistics

Threads
107,373
Messages
1,029,192
Members
139,471
Latest member
phslprj
Top