Author Topic: Event_percentEventEnabled  (Read 1335 times)

This event is basically setEventEnabled but based on random chance. It will randomly set an event to enabled or disabled depending on a factor you set.

For example:

When the minigame restarts, there is a 40% chance this door will be unlocked.

Download

Has this been done before?

Has this been done before?
don't believe so
this could have very interesting uses i imagine

It actually is just a wrapper around setEventEnabled. So it's not "an event", but more like "events". I would like to suggest that you add an eventScriptLabels.txt file to your archive so it will support EventScript.

Code: (eventScriptLabels.txt) [Select]
percentEventEnabled 1 1

Note that those whitespaces are tabs, not spaces. Copy this and add to the file described and people using EventScript may be happier to use this.

Also, I may recommend using EventScript standard to show how the event is used.
Code: (EventScript) [Select]
toggle:
onActivate -> Self -> door("Toggle")
onMiniGameReset -> Self -> percentEventEnabled(40, [toggle])

This is just optional, though.
« Last Edit: March 21, 2019, 05:43:26 AM by mctwist »