GMS2 Tutorial - Easy Particle Effects - No Art Required Copy Paste Code - GameMaker Studio 2
Hello everyone, in this GameMaker Studio 2 Tutorial video we learn how to make cool looking particle effects with very little effort. This video will walk you through all the steps required to make it work. First we create a couple new layers, a BottomParticleLayer and a TopParticleLayer, that way we can have particles play at different depths and show things below and above sprites. Then we create a new object that has two events, a create event and a Game End event. The create event will be where we type the code that creates a new particle system and a new particle type. The Game End event is where we destroy the particle system and particle type to prevent any potential memory leaks that come along with making particle systems. Then we create a simple script that we'll be using to call the particle effect. This method will give us much more flexibility on how and when we play the particle effects. Finally we take a look at a couple different ways we can call the script to play particles, first using the mouse clicks and mouse locations, and then to make it play when the player moves. You can basically play the particles at any point in time, just place the script call where you want it to show.
! Don't forget to drag and drop the new object we created onto the room you want to play the particle on, or it'll crash because it won't find the particle system you're referencing!
Here's the copy paste code:
Object: obj_DGparticleSystem1
Create event:
DGpartSystem1 = part_system_create_layer("BottomParticleLayer", false);
particle1 = part_type_create();
part_type_shape(particle1,pt_shape_ring);
part_type_size(particle1,0.10,0.38,-0.19,1);
part_type_scale(particle1,1.66,2.86);
part_type_color3(particle1,7147325,732674,10545510);
part_type_alpha3(particle1,0.81,0.31,0.09);
part_type_speed(particle1,1.36,2.68,-0.26,4);
part_type_direction(particle1,124,248,-1,0);
part_type_gravity(particle1,0,270);
part_type_orientation(particle1,28,219,0.40,4,0);
part_type_blend(particle1,1);
part_type_life(particle1,32,49);
Game End event:
///Destroy System Prevent leaks
part_system_destroy(DGpartSystem1);
part_type_destroy(particle1);
Script DG_particle1
///DG_particle1(x,y)
var xx = argument0;
var yy = argument1;
part_particles_create(obj_DGparticleSystem1.DGpartSystem1, xx, yy, obj_DGparticleSystem1.particle1, 1);
Calling the script:
DG_particle1(x,y);
to call it with the mouse:
if (mouse_check_button(mb_left)) DG_particle1(mouse_x,mouse_y);
If you've enjoyed this video please consider giving it a Like, Favorite and share. You could always Subscribe to the channel if you haven't already and as always, thanks for watching and we'll see you in the next video! :)
DG Discord Server:
https://discord.gg/YcxySsj
Website:
http://driftwoodgaming.com
Twitch:
http://www.twitch.tv/DriftwoodGaming
Twitter:
http://www.twitter.com/DriftwoodGaming
Patreon:
http://www.patreon.com/DriftwoodGaming
-------------------------------
Special thanks to all my Patrons:
Damian Floyd, Fun4theBrain, David Philips, Studio Blue, Battle Pisces Gaming, Michael Flynn, John Gibson, ChrAndGow, Scott Zarwell, Edwardo Santizo, NeoSoulGamer, Jai R Fisher, Rusty_Gears, Meteodros, R.A.M, Valryia, DarkKrow13, StalkerRoguen, Ervin Mcclure, Chris Van Essen, Mithrandir, Michael Noles and those of you who have supported me in the past.
Что делает видео по-настоящему запоминающимся? Наверное, та самая атмосфера, которая заставляет забыть о времени. Когда вы заходите на RUVIDEO, чтобы посмотреть онлайн «GMS2 Tutorial - Easy Particle Effects - No Art Required Copy Paste Code - GameMaker Studio 2», вы рассчитываете на нечто большее, чем просто загрузку плеера. И мы это понимаем. Контент такого уровня заслуживает того, чтобы его смотрели в HD 1080, без дрожания картинки и бесконечного буферизации.
Честно говоря, Rutube сегодня — это кладезь уникальных находок, которые часто теряются в общем шуме. Мы же вытаскиваем на поверхность самое интересное. Будь то динамичный экшн, глубокий разбор темы от любимого автора или просто уютное видео для настроения — всё это доступно здесь бесплатно и без лишних формальностей. Никаких «заполните анкету, чтобы продолжить». Только вы, ваш экран и качественный поток.
Если вас зацепило это видео, не забудьте взглянуть на похожие материалы в блоке справа. Мы откалибровали наши алгоритмы так, чтобы они подбирали контент не просто «по тегам», а по настроению и смыслу. Ведь в конечном итоге, онлайн-кинотеатр — это не склад файлов, а место, где каждый вечер можно найти свою историю. Приятного вам отдыха на RUVIDEO!
Видео взято из открытых источников Rutube. Если вы правообладатель, обратитесь к первоисточнику.