Description

PRAction is a GameMaker Studio 2 (GMS) module created by Prismatic Realms, Inc. It is an action/animation system that is similar to a tweening system, but is so much more than that. At its very basic level, PRAction allows you to modify an object's properties from one value to another over time, but it takes this concept several steps further. The idea is that you create "action" objects, each of which represent a specific object property changing from one value to another over a given amount of time. Then you can package any number of these actions together into complex groups and sequences that, when played by a object, will be executed like an action script from a movie. Actions, and groups of actions, can be played in a loop and repeated any number of times. Furthermore, actions are reusable. So when you create an action, you can keep it around to use over and over on any number of your game objects.

Any of your object's properties can be animated in this way. PRAction gives you many functions that allow you to animate their x/y positions, alpha value, rotation angle, scaling factors and much more. You can also animate your object's colour properties to transition from one colour to another smoothly. On top of that, you can also animate any of your own custom variables that you've added to your objects.

It doesn't end there. Properties can be animated "absolutely", meaning that you specify the "to" value that the property will animate to from it's current value. But you can also animate properties "relatively" so that rather than animating those properties TO any given value, you animate they BY a given value instead. PRAction includes a bunch of animation curve functions, also known as easing functions, that will animate those properties using a variety of different smoothing effects.

And if that isn't enough, there's more! Actions don't only have to involve modifying properties over time. There is an action that allows you to insert a "wait" command into your "movie script" to add pauses in between your actions. Actions can also be one-shot instant triggers! Such as running a script function, object method or user event, or playing a sound effect, destroying an object, running a room, changing an object's draw layer, or even instructing another object's actions to start playing at key points in your action sequence.

As a bonus, this extension includes several common and useful compound actions, ready to use in your project. These include floating, shaking, blinking, flashing, flipping, wobbling and more. Use them as is, or as examples to create your own compound actions.

PRAction will save you tons of time when coding your animations. There is nothing to it: First, you define the actions and then you instruct an object to play those actions. That's it! There is no messing about with alarms, or tracking frame counts or anything else. Just play it, and then forget it.

The sky's the limit with this extension. Animate anything to your heart's desire.

This package contains a parent object that implements PRAction that your objects can derive from as well as several script assets that contain the functions you use to create actions and animate your object properties. The package also contains documentation on how to use the module and example code that you can learn from.

Friendly support is just an email away and you can expect a quick turn-around to answer your questions and resolve issues. As always, comments and suggestions are welcome!

The included examples feature artwork by Penusbmic (used with permission.)​

End User Licence Agreement (EULA).

Age Rating: 4+

Versions

GMS2 - Version 1.3.0. Published May 9, 2019

-Added PRActionDestroyObject function. Creates an action that will destroy the current object. -Added PRActionGotoRoom function. Creates an action that runs the given room. -Minor changes to JDOC descriptions.

GMS2.3 - Version 2.3.0. Published January 30, 2024

CURRENT VERSION : 2.3.0 RELEASE DATE : Jan 30, 2024

NEW FEATURES * Added new action type PRACTION_TYPE_WAIT_SPRITE_ANIM_FINISH and related function PRActionCreateWaitSpriteAnimFinish(). * Can now use PRActionCreateCustomVarTo() and PRActionCreateCustomVarBy() fuctions to create actions that affect global variables.

IMPROVEMENTS * None

BUG FIXES * Fixed bug in PRStopAction() method that wasn't decrementing the playingActionsCount variable. * Changed how stopped actions are handled to prevent issues when one action is stopped and another action is played in the same game frame. * Each time an instant action played, it allowed a game frame to go by before playing the next action. That was wrong and is now fixed (under most circumstances). * Now checks the possibility that the object running an action might have been destroyed prior to running its Step event.

NOTES * None

PREVIOUS VERSION : 2.1.4 RELEASE DATE : Dec 22, 2023

NEW FEATURES * None

IMPROVEMENTS * Replaced PRModuleRegistry function call with global._PRModuleRegistryInit assignment. * Removed previous modifications regarding "only referenced once" syntax errors. Doesn't seem to happen anymore.

BUG FIXES * None

NOTES * None

Loading, please wait

Package contents

Loading, please wait

What is the issue?

Loading, please wait