Event Extend - custom page conditions

● ARCHIVED · READ-ONLY
Started by Tsukihime 4 posts View original ↗
  1. Event Extend

    -Tsukihime

    Overview

    This script allows you to use conditional branches to act as an additional page condition.

    It only supports one conditional branch, but it allows you to specify more things and gives you a script box as well.

    Example

    You have an event that should only appear if Eric is a Monk, and another event that should appear in the same place if Eric is a Spellblade. And possibly a different event for each class.

    The easiest way would be to specify a page condition that checks whether Eric is a Monk, but unfortunately such a page condition doesn't exist.

    You can solve this problem by cleverly using a set of parallel events to check Eric's class, and then remotely set self-switches to show the proper event page.

    Or maybe using a bunch of "switch event location" with a bunch of other events, using a parallel process that checks Eric's class.

    ...or you can just specify a custom page condition using a conditional branch that checks "Eric is a Monk?"

    Usage

    If your page should have a custom page condition,

    1: create a comment as the first command and write "page-condition" (you can customize this string)

    2: create a conditional branch with the condition you want.

    dMAud.jpg

    (of course, you don't need a custom condition if you're just checking a switch...unless you're checking more than 2 switches)

    The branches themselves are not important. I only check the condition and determine whether the page should be selected.

    Download

    Script: http://db.tt/5Jd3a133

    Demo: http://db.tt/5e6hxd0o

    Notes

    An event is not refreshed automatically unless you explicitly tell it to refresh.

    I've added refresh calls to a lot of different methods throughout the classes but there may be some I didn't catch. Just report them.

    One conditional branch is definitely limited, and the only workarounds right now would be to write complex ruby statements to check different things (since it supports 10000 characters). I don't want to add too much to the event page though because when the actual event starts processing you're going to be evaluating all of those extra conditional branches as well for no particular reason.
  2. I want to have multiple custom page conditions but that can really only be done through a script call.

    Ideas?
  3. Wow, if I only found this yesterday. :)

    This is a very useful script for eventers, thank you much for posting!
  4. Updated since there was no check for whether the page was already executed if the custom condition was used.

    Actually now that I look at it there's a piece of code that isn't used at all for some reason...