How would I check a script boxes data in my plugin?

GibzFGC

20+ Year RPG Maker Veteran
Veteran
Joined
Apr 26, 2012
Messages
46
Reaction score
17
First Language
English
Primarily Uses
RMMV
Hi everyone, I'm confusing myself by trying to check what the user is entering into the script box. I need a way to check because of a plugin I'm updating.

I'd like to do something like the following and gather the information between the square brackets.

[MechaGS_Function]param1 = valueparam2 = valueparam3 = value[/MechaGS_Function]Any help with understanding how to approach this would be greatly appreciated.
 

GibzFGC

20+ Year RPG Maker Veteran
Veteran
Joined
Apr 26, 2012
Messages
46
Reaction score
17
First Language
English
Primarily Uses
RMMV
Yep, I've been releasing scripts and using the debug console to get around everything.

The only reason I asked was because I'm interested in cleaning a function up because in the Plugin Command window it looks really long right now.

I just haven't figured out how to read from the script area.
 
Last edited by a moderator:

Jeremy Cannady

Coldfire
Veteran
Joined
Oct 25, 2015
Messages
449
Reaction score
268
First Language
English
What do you mean exactly? Read data from note tags? Read data from the plugin menu where you can specify parameters?

Find out what a value of your function in your script is?
 

GibzFGC

20+ Year RPG Maker Veteran
Veteran
Joined
Apr 26, 2012
Messages
46
Reaction score
17
First Language
English
Primarily Uses
RMMV
I want to read the script area, but I haven't found a way. I can read from the plugin command area but it looks really messy.

Here's my plugin. you'll see that the command is quite long, I'd like to tidy it up by using a more readable method like posted in the main topic above.
 

Iavra

Veteran
Veteran
Joined
Apr 9, 2015
Messages
1,797
Reaction score
866
First Language
German
Primarily Uses
The content of the "Script" event command is executed via eval(), so you should just call one of your functions and pass the parameters.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
32,162
Reaction score
8,017
First Language
German
Primarily Uses
RMMV
I want to read the script area, but I haven't found a way.
You need to specify what you mean, because you're not using the correct nomenclature.


Are you talking about the note box in the database where most scripts and plugins place additional data?


Are you talking about the script command in the event commands?


Are you talking about the old script editor from Ace that does not exist in MV anymore?


Because there is nothing named "script area" or "Script Box" in the entire editor...
 
Last edited by a moderator:

GibzFGC

20+ Year RPG Maker Veteran
Veteran
Joined
Apr 26, 2012
Messages
46
Reaction score
17
First Language
English
Primarily Uses
RMMV
You need to specify what you mean, because you're not using the correct nomenclature.

Are you talking about the note box in the database where most scripts and plugins place additional data?

Are you talking about the script command in the event commands?

Are you talking about the old script editor from Ace that does not exist in MV anymore?

Because there is nothing named "script area" or "Script Box" in the entire editor...
Sorry if I'm not clear enough, I mean the script command area.

Capture.JPG
 
Last edited by a moderator:

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
32,162
Reaction score
8,017
First Language
German
Primarily Uses
RMMV
In the script command, you can only place commands - your original post was formatted like a notetag, that will never work in a script command.


To transfer data by script command, you need to write a function in your plugin that will be used to receive that data as arguments.


This function needs to store the data into the script variables that you want to use that.


Then you call that function inside the script command, giving the data you want as arguments of that function.
 

GibzFGC

20+ Year RPG Maker Veteran
Veteran
Joined
Apr 26, 2012
Messages
46
Reaction score
17
First Language
English
Primarily Uses
RMMV
Hmm, unfortunate. I'll leave it with the Plugin Command style then.

I was just looking to see if there was a better way of handling it.
 

Latest Threads

Latest Profile Posts

zomboars.jpg

Concept art

Zomboars- main enemies in my story
mutant pigs addicted to beer
SF_People1_3 added!
index.php

I haven't been on here in forever wow(missed my forum birthday T-T). Anyways, I'm dabbling in BGMs, here's something I'm actually willing to share.

Binge-watched 6 episodes of the Erased anime... And that means I've watched half of it?! Sigh...

Forum statistics

Threads
109,201
Messages
1,043,001
Members
141,709
Latest member
chonkycat
Top