Plotscripts w/ tags

Talk about things that are not making games here. But you should also make games!

Moderators: Bob the Hamster, marionline, SDHawk

Post Reply
AzureGames
Red Slime
Posts: 49
Joined: Thu Oct 29, 2015 8:18 pm

Plotscripts w/ tags

Post by AzureGames »

How do I end a plotscript with tags in it? And I mean LOTS of tags.


:???:
User avatar
Bob the Hamster
Lord of the Slimes
Posts: 7658
Joined: Tue Oct 16, 2007 2:34 pm
Location: Hamster Republic (Ontario Enclave)
Contact:

Post by Bob the Hamster »

I don't understand the question. You are asking how you end the plotscript? Are you getting an error message when you try to compile/import the plotscript?

If so, you can copy-paste the error message, or post a screenshot.

You can also post the text of the script here, or if it is too long, put it up on pastebin.com and put a link to it here.
AzureGames
Red Slime
Posts: 49
Joined: Thu Oct 29, 2015 8:18 pm

Sorry to confuse you.

Post by AzureGames »

...Well... I think I can provide you with a similar, shorter plotscript. The one I'm using, you see, would just be way too long.

Code: Select all

plotscript, script1, begin
if (check tag (tag: tag1)==on) then, begin
set tag (tag: tag2, off)
set tag (tag: tag3, on)
???

plotscript, script2, begin
Whenever I try to export my plotscript, it just says "declaration script2 is not permitted inside a script. Perhaps script1 has an extra begin or ("
TMC
Metal King Slime
Posts: 4308
Joined: Sun Apr 10, 2011 9:19 am

Post by TMC »

Every ( or begin (they're just two different ways of writing the same thing) needs a matching ) or end to show where the thing started by (/begin ends. So you need an 'end' to end the 'then' block, and a second one to end the 'script':

Code: Select all

plotscript, script1, begin
  if (check tag (tag: tag1)==on) then, begin
    set tag (tag: tag2, off)
    set tag (tag: tag3, on)
  end
end
Hint: indentation is very very helpful for keeping track of where you need to put the 'end's as your script gets longer. Not using indentation is a clinical indicator for madness.
Last edited by TMC on Thu Dec 21, 2017 8:52 pm, edited 1 time in total.
AzureGames
Red Slime
Posts: 49
Joined: Thu Oct 29, 2015 8:18 pm

Hmmmm...

Post by AzureGames »

Well, thanks I guess.
AzureGames
Red Slime
Posts: 49
Joined: Thu Oct 29, 2015 8:18 pm

Another Question...

Post by AzureGames »

What's the plotscripting command (or whatever it's called) for adding/removing heroes in/to the party?
Thanks in advance. :???:
User avatar
Bob the Hamster
Lord of the Slimes
Posts: 7658
Joined: Tue Oct 16, 2007 2:34 pm
Location: Hamster Republic (Ontario Enclave)
Contact:

Post by Bob the Hamster »

The commands you want are "add hero" and "delete hero"

You will find them here: http://hamsterrepublic.com/ohrrpgce/doc ... he%20Party
Post Reply