The annoying teleporter [Game Maker Studio 2 | Enemy Ai]

Channel:
Subscribers:
11,800
Published on ● Video Link: https://www.youtube.com/watch?v=Z-3rlAfYEWc



Category:
Tutorial
Duration: 9:16
1,731 views
74


This enemy ai video tutorial shows you how to make a randomly teleporting enemy that that doesn't spawn on walls in GameMaker Studio.

The idea is quite simple. You need to define at the start a radial spawn circle and save the first x,y coordinates where the instance has been placed. This area defines possible spawn locations. Now run down a timer and when that reaches zero we try to teleport the enemy in a random x,y coordinate in that possible range. Here we check multiple times if that spot is not blocked by a wall instance and if no, we set the x,y coordinate to the random new positon. That's it!



๐Ÿ‘‘ Support me and get fresh game art and game maker projects every month:
https://www.patreon.com/1upindie

Follow me on:
๐Ÿ“ธ Instangram: https://www.instagram.com/1upindie
๐Ÿฆ Twitter: https://twitter.com/1upIndie
๐Ÿ’ฌ Discord: https://discord.gg/gvr98nb
๐Ÿ“œ Udemy: https://www.udemy.com/course/become-a-video-game-developer-with-gms-23/ (See youtube about page for discount)


--------------------------------------------------------------
0:00 What we will do
0:44 Subscribe
0:55 Theory of how it is done
2:15 Coding part
9:05 Game shown - Batbarian







Tags:
game maker tutorial
game maker studio tutorial
gamemaker studio 2 tutorial
game dev
game developer
gamemaker studio arch tutorial
gamemaker enemy ai
gamemaker studio 2 enemy ai
gamemaker enemies
gamemaker enemies tutorial
gamemaker enemy telepo
gamemaker enemies teleport
gamemaker enemies teleporting
How to make enemies teleport gamemaker
gamemaker random teleportation