raorn
Member
Does ``import'' just "paste" other script, or it does something "clever"?
Let's say i have three scripts:
script1.ash
script2.ash
mainscript.ash
Can I:
I'm asking this because I have two useful relay override scripts (Disco Combos and Fight Buttons). For now I've just copypasted two scripts together, but it's not easy to support it and I want to use another script for Shimmering Portal punchcards action (not written yet, just planning). So I want to do something like:
fight.ash:
Let's say i have three scripts:
script1.ash
Code:
int var1;
int do_something1(...)
{
...
}
script2.ash
Code:
int var2;
int do_something2(...)
{
...
}
mainscript.ash
Code:
int mainvar1;
import <script1.ash>;
import <script2.ash>;
int mainvar2;
void main(...)
{
...
}
Can I:
[li]access var1 and var2 from mainscript?[/li]
[li]access mainvar1 from script1 and script2?[/li]
[li]access mainvar2 from script1 and script2?[/li]
[li]access var1 from script2?[/li]
[li]access var2 from script1?[/li]
I'm asking this because I have two useful relay override scripts (Disco Combos and Fight Buttons). For now I've just copypasted two scripts together, but it's not easy to support it and I want to use another script for Shimmering Portal punchcards action (not written yet, just planning). So I want to do something like:
fight.ash:
Code:
buffer page;
import <script1.ash>;
import <script2.ash>;
...
import <scriptN.ash>;
void main()
{
page = visit_url();
page = do_something1(page);
page = do_something2(page);
...
page = do_somethingN(page);
write(page);
}