![]() This is the inverse of `_integer_pair_to_natural`. _natural_to_integer_pair() -Maps a natural number to a unique ordered pair of integers (by composing _nautral_to_integer() on _natural_to_natural_pair()).This is the inverse of _integer_to_natural(). _natural_to_integer() - Maps a natural number to a unique integer using the zig-zagging bijection from (0, 1, 2, 3, 4._k_tuples() - Generates an array of all possible base- b k-tuples, in ascending (or descending) order.This is the inverse of _natural_to_integer(). _integer_to_natural() - Maps an integer to a unique natural number using the zig-zagging bijection from (0, 1, -1, 2, -2.This is the inverse of _natural_to_integer_pair(). _integer_pair_to_natural() - Maps an ordered pair of integers to a unique natural number (by composing _nautral_pair_to_natural() on _integer_to_natural())._frac() - Generalized fractional part function which accepts a step size argument._floor() - Generalized floor function which accepts a step size argument._factorial() - Calculates the factorial ( n!) of a nonnegative integer._decimal_to_base() - Converts a number from decimal to an array of base- b digits._ceil() - Generalized ceiling function which accepts a step size argument._base_to_decimal() - Converts a number from an array of base- b digits to decimal.For example, the various pairing and inverse pairing functions can be used to store pairs of numbers as single numbers in data structures (like stacks and queues) and then recovered. The following is a brief description of the included functions, divided into rough categories.Ī variety of scripts dealing with sequences, functions, and sets, which may have some uses for managing data structures. The scripts included in the package are reasonably well-documented within the source code. Some include methods, which are always defined in the object's Create event. All object names begin with the obj_ prefix. All function names begin with an underscore in order to distinguish them from built-in functions. Most functions are standalone and are meant to be taken à la carte, but some of the more mathematically complicated functions depend on other scripts, indicated in a tag. I encourage you to download it, use it in your own projects, and modify the source code as much as you like.Įach script in this package defines a single function. I've written these functions for my own use over the years, and I expect to add more over time.Īll source code is available for free at my GitHub page, released under the MIT license. Show_debug_message(tile_map_id) // no matter which variable is placed here, it is undefined.This is collection of general utility and mathematical objects and functions for GameMaker Studio 2 (Version 2.3) in the form of a local asset package. ![]() In my script I have the following, no matter whether I make the variables local or not, the script cannot seem to detect the params. ![]() I'm new to Game Maker Studio 2, whenever I try to call my script with scr_tile_collision(collision_tile_map_id, 16, velocity_), it states that the arguments are undefined. ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |