Lorin

Villager
Member
Joined
Aug 23, 2013
Messages
5
Reaction score
0
First Language
Polish
Primarily Uses
Hello,

Here is my first post on this forum and i want to ask you what can i do to move npc of unknown position to the place which i have set for him. His position isn't unknown but rather unspecified in the moment of starting the event(cutscene) because he and the others npcs have their fixed route(custom). I know i can use branches and variables(X,Y) to check their positions. And it can be done that way but for me it create too many branches and too much work for every npc(you can talk with these npc).  So i am asking you whether it is possible to do this shorter.

Ps. My english may be bad so forgive me any errors. Be welcome.
 
Last edited by a moderator:

YoraeRasante

Veteran
Veteran
Joined
Jun 6, 2014
Messages
1,658
Reaction score
439
First Language
Portuguese
Primarily Uses
RMMV
I believe that you'll need two variables, one for the even't x and one for it's y, a loop and four conditions.

Choose a position for the event to be when you want the true movement to begin.

Start a loop.

First thing first, set the variables to the event's X and Y.

Put four conditions, one inside the other's else.

>If the event's X is smaller than the position you want's X, make it move right.

>>Else, if it is bigger make it go left.

>>>Else when Y is smaller than the position's Y make it go down.

>>>>Else when it if bigger make it go up

>>>>.Inside the last else, put a Break Loop.
 
Last edited by a moderator:

Lorin

Villager
Member
Joined
Aug 23, 2013
Messages
5
Reaction score
0
First Language
Polish
Primarily Uses
Thanks for the reply. I think these answers will be very useful.
 

Latest Threads

Latest Posts

Latest Profile Posts

ok hear me out here: if the only way my brain can describe things is like with colors is this normal? Like I've described a smell as "dark green and fuzzy" and a taste as "dark blue" like is this a normal thing that happens to people or am I just going insane?? o.0
I'm sitting here, programming, when suddenly, in the distance, I hear a deep booming shout, "Dovahkiin". In an instant, my mind and body is pulling me away, my fingers twitch and notepad++, almost by itself, turns off. The Steam starts to rise and a big green play button appers and I am teleported to Skyrim, because, I am, the Dragonborn! 200 hours played last three weeks, omg o_O
Shora Lighting Plugin version 1.5 are out! Wanna add more features to it, but just fixing the bugs is already a pain :kaocry: .

スクリーンショット 2022-01-19 002122.png
I wonder how one goes about picking a good font for a game. I find the default kinda lacking, but you gotta pick a font that's legible ya know.

Forum statistics

Threads
118,483
Messages
1,116,284
Members
155,466
Latest member
clblakej
Top