WaitFor + Chances Object

From FusionWiki

Jump to: navigation, search
WaitFor + Chances Object
General Information
Author: RickyRombo
Release Date: 2010
Status: Released
Last updated: 09/04/10
Version: 1.0
Build: 249
Developer-only: No
Website: http://rickyrombo.co.nr
Download: Download Link
Runtime Versions
HWA: Yes
Flash: No
Java: No
Java Mobile: No
Vitalize!: No
Unicode: No


WaitFor + Chances Object is an extension for Multimedia Fusion 2.

This extension by RickyRombo allows you to generate chances, and wait a certain amount of loops after an action is called.


Forum Post

Usage

The following example shows how to use the Fractional Chance:

1Generate a number from 0 to 10
2
  • Start of Frame
  •  : Generate Chance from 0 to 10

3If the chance generated is 5 or less
4
  • : 5 chances
  • : Set Alterable Value A to 5

5If the chance generated is greater than 5 but less than or equal to 8
6
  • : 3 chances
  • : Set Alterable Value B to 4

7If the chance generated is greater than 8 but less than or equal to 10
8
  • : 2 chances
  • : Set Alterable String to "hi"


The following example shows how to use WaitFor events

1The following code will trigger right away, then wait 5 loops before triggering again, then 5 more loops and trigger again... etc
2
  • Repeat while left mouse key is pressed
  • Wait for 5 loops after (ID = 0)
  •  : Shoot an object

3The following code will trigger after 5 loops, then after 5 more... etc
4
  • Repeat while left mouse key is pressed
  • Wait for 5 loops before (ID = 0)
  •  : Shoot an object

5The following code will wait 10 loops and then trigger every loop
6
  • Delay 10 loops before allowing (ID = 0)
  • Set X position to X( " " )+1

    Loop the Delay (ID = 0)


The following example shows how to use the "Limit to X Loops"

1Limits the event to 5 loops
2
  • Limit to 5 loops (ID = 0)
  • Set Y position to Y( " " )+1

3When the user clicks, the number of times the above event triggered will be reset to 0, allowing it to be triggered again another 5 times
4
  • User clicks with left button
  • Set loop limit 0 to 0

Personal tools