Fangames > Game Design

Post your Code Snippets

(1/5) > >>

Sudnep:
Since this forum is now mostly dead because of the separation of Gamemaker Questions and Game Design I figured this would probably be a useful thread for posting interesting/easy to implement code.

Alternative way to post: https://klazen.com/gm/

I'll start:

parShooterBoss - A simple parent that can be assigned to an object to give it the attributes of a generic shooter boss.

klazen108:
irandom_excluding script to pick a random number from 0 to some upper limit, skipping one number in the range

blast_shape script to blast a shape in cherries, including triangles, squares and stars

Triple Jump how to add triple jump to your game (shows exact edits for YoYoYo Engine, but the concept applies to all engines)

array_shuffle script to take an array and shuffle its elements

draw_rotated draw any sprite as if it were rotated into/out of the screen.

Zurai:
Move and Stop - Maybe more a beginner thingy but always useful.

Derf:

--- Quote from: Zurai on October 08, 2015, 11:20:08 AM ---Move and Stop - Maybe more a beginner thingy but always useful.

--- End quote ---
Boy I'm gonna need to see some indenting and semi-colon line termination or else it's gonna be a ticket.

(srs though it's a nice simple code that pretty much anyone can benefit from)

lawatson:
Rainbowness!
(click to show/hide)In draw event:

col=make_color_hsv(hue,255,255);
image_blend=col;
hue+=1;

end draw event

Make sure to use it on black and white sprites for the most effect.

Navigation

[0] Message Index

[#] Next page

Go to full version