pipbrit

Villager
Member
Joined
Oct 1, 2015
Messages
14
Reaction score
1
First Language
English
Primarily Uses
Hello,
Hopefully I'm in the right place. I'm trying to use the Victory Aftermath Plugin and am trying to add in my own lines. I've added a new line, but can't figure out how to call a variable using the return function. I'm sure it's simple, I just can't figure out what it is.
Thanks!
 

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
42,509
Reaction score
14,850
First Language
English
Primarily Uses
RMMV

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



YEP Victory Aftermath is also an MV plugin, not MZ.

So if you are using MZ you probably won't be able to use this plugin at all.

If you are using MV, please explain what exactly you're trying to do, because you don't "call" variables using any function. What is the new line you added, and where did you add it? Keep in mind if this is a paid plugin you will not be able to share its code.
 

Restart

Veteran
Veteran
Joined
Mar 15, 2019
Messages
797
Reaction score
642
First Language
English
Primarily Uses
RMMV
Basically 'return' ends your function, and hands out whatever the value is on that line.

if I have a function

Code:
myFunction = function (foo,bar)
{
return foo * bar;
}

then if I say

Code:
asdf = myFunction(3,6)

then asdf now equals 18

if I just said

Code:
myFunction(3,6)
it would multiply the numbers, but since nothing catches it it's kind of useless.

Since return ends the function, if I put in
Code:
myFunction = function (foo,bar)
{
return foo * bar;
doSomethingElse()
}
it would never get to the doSomethingElse(), since the return ends the function.

Does that make sense?
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
1,159
Reaction score
636
First Language
English
Primarily Uses
RMMV
Also, not so pertinent to your question, but related to your title - RPG Maker MV and MZ are both driven by JavaScript, not Java. They're different languages.
 

Latest Threads

Latest Profile Posts

Quite the versatile cast so far :p

chars.PNG

Edit: Sprites are made by Alexdraws and TheMightyPalm. I just edited them.
Degica Games Turn Komodo | RPG Maker News #77

Well, rats. Was really looking forward to trying out FPS Creator, but trying to install and set it up was pretty much impossible for my tiny brain to comprehend. So much for that, then.
Ah, home once more! I think I can safely work on my games now.

Forum statistics

Threads
112,421
Messages
1,068,173
Members
146,076
Latest member
flowermuncher77
Top