GameMaker Touhou Engine   Home   Downloads   Documentation

_BULLET_CREATE_LASER_S()


A script that creates an anchored/stationary laser.


Returns: id of the generator that's going to create the laser. (Reference to Object)


Syntax:


_BULLET_CREATE_LASER(bx, by, angle, len, gir, delay_am, duration, delay_fanim, delay_sanim, spr, obj, att, deff, aeff)

Arguments:


Name Type Significance
bx Integer The X-coordinate to fire the laser from.
by Integer The Y-coordinate to fire the laser from.
angle Integer The direction to fire the laser in.
len* Integer The length of the laser.
gir* Integer The girth of the laser.
delay_am Float The delay before firing the laser (accepts negative values).
duration Non-negative Integer The laser's lifetime.
delay_fanim Reference to Sprite The appearing animation of the delay cloud.
delay_sanim Reference to Sprite The disappearing animation of the delay cloud.
spr Reference to Sprite The sprite to use for the laser.
obj** Reference to Object The bullet to fire. (Should inherit from _LASER_PARENT to avoid memory leaks)
att Reference to Object The object that the generator (and by extension the laser) should anchor itself to.
deff Reference to Sprite The sprite of the particle to create when the laser is destroyed. (this sprite should have the same width, height and origin as the base sprite of the laser)
aeff Reference to Sprite The laser's appearing animation. (this sprite should have the same width, height and origin as the base sprite of the laser)

*It is not recommended to have these deviate too much from the sprite's height and width, as that can cause severe artifacting.

**Can be set to noone in order to just create an instance of _LASER_PARENT instead.