Easy Image Trail - After Image Effect
A downloadable asset pack
Easy Image Trail or After Image
This script is designed to make adding graphical effects like image trails (also known as after images) as easy as possible to implement into your game.
This asset contains 1 script. Yes you read that right 1 self contained script. In order to add that awesome after image your after all you have to do is call the following script in your draw event.
scr_after_image()
This script expects 4 arguments.
- Max Length
- Spacing
- Fade Length
- Colour (default c_white)
Script is commented thoroughly with example.
Max length is exactly how it sounds. How many sprites should comprise the length of your trail? higher number means longer after image and smaller numbers mean a shorter after image.
Spacing is also as it sounds. How much space is between each image in the image trail. So if you provide the number 2 then it will wait 2 steps before updating the next image position. If you set this to 0 then all the images will be bunched closer together. Higher means farther apart lower means closer together. I recommend a minimum of 2.
Fade length is how long it takes for a after image to fade out.
Note having the ability to set fade length means you need to be careful with the number of after images. If the fade_Length is to short it will not display all of the images. A good setting is scr_after_image(5, 4, 0.05, c_white).
Colour is pretty self explanatory. If you use the default c_white then the after image will be of the same sprite of lower alpha values. If you decide to use something like c_aqua or make_colour_rgb then the sprite will be coloured in the after image.
Status | Released |
Category | Assets |
Rating | Rated 4.0 out of 5 stars (2 total ratings) |
Author | SyntheticPixel |
Made with | GameMaker |
Tags | after-image, gamedev-asset, GameMaker, gamemaker-studio, gamemaker-studio-2, gms, gms2, image-trail, synthetic-pixel, synthetic-pixel-games |
Average session | A few minutes |
Languages | English |
Download
Click download now to get access to the following files:
Development log
- Update/bug fixesAug 18, 2018
Comments
Log in with itch.io to leave a comment.
is there a way to make this toggleable? like, i only want this to be active during a specific state of my player object
probably, just put the function within an "if" statement so the effect only happens if that statement is true
I return to apologize and say that putting it in an "if" statement did not in fact work and creates weird cutting in/out of the afterimage effect. My bad homie