Jump to content


Photo

Advanced Platform Shooter AI (Ragdoll Update)


  • Please log in to reply
103 replies to this topic

#1 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 17 December 2007 - 06:57 PM

Platform Shooter and AI engine


:thumbsup: Tutorial Description
After seeing countless people asking about this in the novice Q&A I decided I would make one. Probaly the most complete platform engine on the GMC. Also contains a fully working platform shooter engine.

This engine has been through many version and has really evolved over the past few years, and it has been years (started 2008). As a result of this evolution, old code artifacts from earlier versions are still in this game. So from time to time, you may come across some redundant objects or pieces of code. Also different styles of coding are present, mainly due to my own development.

I have recently update the engine again (15/09/2011) This adds many cool features, ragdoll and physics using the GMphysic's EXT which I have included in the new download. The GM physic's EXT is pretty limited, but it eliminates the need for DLL's, something I haven't learned to use yet.

I want to put the history of the engine in, so this is the earliest version I can find:
Download old Version 1
I actually prefer the way the AI works in this version, even though it's simpler, it feels more tidy. Also the melee attack was cool.

old Platform Shooter
This was a platform shooter engine I made. This engine was born when I decided to merge the 2 engines together.

The controls are:
WASD to move.
Left click to shoot.
Mouse wheel to cycle weapons.
Right mouse to throw grenades, hold down to build up more power.
Q adds a silencer to your gun (Dunno why this is in there, it does not affect gun stats).
Space goes in to a slow mo thing (I think I was playing Red Dead).
R restarts the game.

:whistle: Features Include:
  • 2 Different AI's
  • A friendly and an enemy
  • Patrol
  • Has line of sight
  • Metal gear style explanation mark !
  • Dodge things
  • Grenades
  • Also has cool partical effects
  • Has a platform shooter engine as well with lots of features
  • Ragdolls!
Also contains a pretty solid platform engine witch supports slopes, and includes a variety of easy to customize weapons and effects.

File Type - GMK
Game Maker version - GM.7 registered

::lmao:: Screens:

Posted Image

(This is actually 4 screenshot's combined in Photoshop!)

:wub: Download:

New:
Download platform shooter.zip from Host-A

Old:
Download platform_shooter.gmk from Host-A

:happy: Other Stuff
Sprites are now for use.
You need to install the GMphysics EXT, you do this by clicking 'Extension packages' at the bottom of the resources list. The GMphysics EXT is included in the new download link.

Programmed, Designed and Created By:
Crispy

With help from:
Paingiver
DarkSentinel
Ogeon
Mark13673
Spliter
FoxInABox
Obj_Control
Marinerfan
Arkano

Thanks to:
Mordi for some of the partical effects & instant bullets.
Krizto for the blood splatter sprites and some of the effects.
Torigara for shooting out of the tip of a gun.
zzKITKATz for the basic following example
RhysAndrews for GameCave effects and sprites
Quimp for movment tips

Sprites By:
Crispy

If you see your name here, but don't know why, you probably inadvertently gave me some code.

Enjoy

-Crispy

Edited by Crispy, 19 September 2011 - 07:24 PM.

  • 2

#2 kristian221

kristian221

    GMC Member

  • GMC Member
  • 680 posts
  • Version:GM8.1

Posted 19 December 2007 - 03:25 AM

no offence, but the AI wont aim at you unless your exactly even with him. But I think the moving on uneven ground is great! :P 5/10
  • 0

Want a simple and effective PLATFORM ENGINE with TONS of fun features? Try my SparkEngine!
Want to see a game made with it? Check out my work in prgress When The Mouse Rebels!
Did I help you? If I did, PLEASE press this link: I helped you!


#3 MapleGuru

MapleGuru

    GMC Member

  • New Member
  • 271 posts

Posted 19 December 2007 - 07:09 AM

Simple, but works great. Good Job buddy 10/10
  • 0

#4 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 19 December 2007 - 05:26 PM

Ok got rid of the shooting up thing. Instead he jumps over things.
-Crispy
  • 0

#5 jabelar

jabelar

    GMC Member

  • GMC Member
  • 3003 posts

Posted 19 December 2007 - 09:55 PM

You dont need registered for it.

<{POST_SNAPBACK}>

You do need registered, because it uses image_angle.
  • 0

#6 emporer_safor

emporer_safor

    Galaxy Games

  • New Member
  • 669 posts

Posted 21 December 2007 - 02:16 AM

Very cool indeed! 10/10. No problems. I find that this is great for beginers (who have Pro)
  • 0

UPDATE: I now am modding the above "Worms!" project. :)
Most people underestimate their capacity to withstand pain.

#7 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 21 December 2007 - 12:32 PM

Yes, in bullets step event. if you take it out it may work for unregistered to.
  • 0

#8 ravener

ravener

    SG menace

  • New Member
  • 965 posts

Posted 06 February 2008 - 03:23 PM

This is a great AI example 10/10 if you are going to make a new version make it so the AI has a gun arm that points toward the player!!
  • 0
Im back :o

#9 SunTzus

SunTzus

    Ying Yang Twinz

  • New Member
  • 1047 posts

Posted 06 February 2008 - 10:48 PM

This isn't that hard to program, but it was functional, 7/10

Btw: only function it uses that's registered is image_angle= direction, whichis easy to implement to unregistered...

Maybe you should make it a bit more intricate like it being able aim at you w/o jumping by aiming DIRECTLY at you, it's extremely simple but it will help it loadz
  • 0

#10 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 22 February 2008 - 05:32 PM

added AI sight line, and things that block the sight line. fixed a few gliches.
  • 0

#11 MJGamesInc

MJGamesInc

    GMC Member

  • New Member
  • 365 posts

Posted 13 March 2008 - 05:47 PM

hey man can you make this so he can aim up and shoot if your jumping high over him and up on a roof or somthing???? please great help but thats the onlhy prob. i have LOL
  • 0

#12 joshuarobillos

joshuarobillos

    GMC Member

  • GMC Member
  • 195 posts
  • Version:GM:Studio

Posted 13 March 2008 - 09:02 PM

This sounds great but can you make one for non pro users?
  • 0

#13 Ziphe

Ziphe

    GMC Member

  • New Member
  • 101 posts

Posted 27 April 2008 - 11:29 PM

How do i make it so it shoots diagonally, I already have sprites for it also i have it so the bullets shoot were im at but dont follow me
  • 0

#14 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 17 October 2008 - 10:01 PM

Updated, see first post.
  • 0

#15 blaketheawesomedude

blaketheawesomedude

    GMC Member

  • New Member
  • 295 posts

Posted 18 October 2008 - 05:19 AM

Please make an unreg version.
  • 0

#16 Hyper Break

Hyper Break

    GMC Member

  • New Member
  • 25 posts

Posted 18 October 2008 - 05:59 AM

can you make this .gm6 ?
  • 0


#17 Fede-lasse

Fede-lasse

    AI Programmer

  • GMC Member
  • 2009 posts
  • Version:Unknown

Posted 18 October 2008 - 09:05 AM

This is all glitchy; the player character turns upside down sometimes, the movement is glitchy, changing sprites is glitchy and the torso sprite of the AI is totally weird.

Except for that, it's good, I guess.
  • 0

Call me Fede.


#18 Hyper Break

Hyper Break

    GMC Member

  • New Member
  • 25 posts

Posted 18 October 2008 - 12:12 PM

broken link :) (the new one)
  • 0


#19 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 18 October 2008 - 12:25 PM

Fixed the broken Link, fixed some bugs, added smoother movement. Working on having multipul enemys in the same room and not to shoot each other (harder than it sounds)
  • 0

#20 harddrive

harddrive

    GMC Member

  • New Member
  • 2 posts

Posted 13 November 2008 - 10:11 PM

Hey guys!

If you want to add a sound for a weapon, what do you do?
And how do you make the sound play when the weapon fires?

What do i write in the script, etc.?

Please answer!
I'm quite a noob at GM so I need detailed instructions.
  • 0

#21 iforgotmyname

iforgotmyname

    GMC Member

  • GMC Member
  • 98 posts

Posted 14 November 2008 - 07:18 AM

___________________________________________
ERROR in
action number 1
of Step Event
for object obj_gore_body:

In script shooting:
Error in code at line 6:
bul=instance_create(obj_gore_arm.x,obj_gore_arm.y,
obj_bullet); // create a bullet

at position 35: Unknown variable x

No worries.

Anyway, another bug :

http://img235.images...mage=bagey8.png

Headless soldiers!

Edited by iforgotmyname, 14 November 2008 - 07:36 AM.

  • 0
I don't survive thebutton! Don't click because you can't click it!

#22 geoff95

geoff95

    GMC Member

  • New Member
  • 1 posts

Posted 23 November 2008 - 09:05 AM

lol another broken link? heres a new one that i found (PS for host-a.net u can just search the persons name then download the file)
http://host-a.net/cr...orm_shooter.gmk
  • 0

#23 1Koakuma1

1Koakuma1

    GMC Member

  • GMC Member
  • 129 posts
  • Version:GM8

Posted 14 January 2009 - 01:09 PM

i want pro!
  • 0

#24 Nelliosis

Nelliosis

    GMC Member

  • New Member
  • 100 posts

Posted 17 January 2009 - 04:46 PM

We can't use the halo sprites? :)
  • 0

#25 RandumBoi

RandumBoi

    GMC Member

  • New Member
  • 1 posts

Posted 18 January 2009 - 05:13 PM

The link's still broken :)
EDIT: OK, I found the other link. You should change the link in your first post though.

Edited by RandumBoi, 18 January 2009 - 05:17 PM.

  • 0

#26 Kaptain_Kohl

Kaptain_Kohl

    GMC Member

  • New Member
  • 63 posts

Posted 05 March 2009 - 12:21 AM

your not able to add more than one AI ... if you do .... one is perfict and the others have no head or body, only legs
  • 0

#27 BretHudson

BretHudson

    indie(Function);

  • GMC Member
  • 373 posts
  • Version:GM8

Posted 05 March 2009 - 06:59 PM

cool! ive always wanted to make one of these!

thx!
  • 0

#28 Mattdraw

Mattdraw

    GMC Member

  • GMC Member
  • 163 posts
  • Version:GM8

Posted 06 March 2009 - 02:11 AM

gm6?
  • 0

sig.png


#29 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 09 May 2009 - 11:31 AM

I know you can only have one AI, i never got around to fixing it. working on an update though

Edited by Crispy, 15 May 2009 - 06:50 PM.

  • 0

#30 Vile Smile

Vile Smile

    Oh, Outrageous!

  • GMC Member
  • 553 posts
  • Version:GM7

Posted 13 May 2009 - 05:45 AM

Nice job! :D

EDIT: I noticed that the "bullets going through the ground" was just part of the bullet collision effect. My bad! :D
Still good job. :D

Edited by Vile Smile, 13 May 2009 - 08:45 PM.

  • 0

banner-1.png


#31 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 15 May 2009 - 07:20 PM

Updated!
  • 15th May:
  • You can now add more than 1 enemy to the room.
  • The AI cant float.
  • Patroling AI
  • Fixed more bugs
    16th May:
  • Added some nice blood effects (look at screenshots)
  • Some other minnor things, such as smooth turning.
    17th May:
  • Better vision (cone vision)
  • Enemys have muzzel flash

Edited by Crispy, 17 May 2009 - 11:17 AM.

  • 0

#32 iPH360

iPH360

    GMC Member

  • New Member
  • 126 posts

Posted 18 May 2009 - 11:35 AM

the sprites look like the ODST troopers from the halo series thats cool ;)
  • 0

#33 King Chubbles

King Chubbles

    GMC Member

  • New Member
  • 1052 posts

Posted 18 May 2009 - 11:04 PM

You need to zip it up with gmphisics
  • 0
Posted Image

#34 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 19 May 2009 - 03:59 PM

I want to add GMphysics, but I dont really have enough time right now. Im trying to put in Pathfinding so the AI can jump over mutliple objects to get to you. Also more gore, and get the AI to stop shooting each other. Maybe also grenades.
  • 0

#35 amberyoukai

amberyoukai

    GMC Member

  • New Member
  • 300 posts

Posted 20 May 2009 - 01:15 AM

Nice example, but you should make a reload example, instead of waiting for a certain amount of time and then have all your bullets back.
Also, you have infinite munition :)
And make the munition beside the weapon's name and not infront of it.
I give it a 7.75/10
  • 0
<a href="http://gmc.yoyogames...owtopic=425413" target="_blank"><img src="http://i234.photobuc.../RedGuysig.jpg" border="0" class="linked-sig-image" /></a>
<b><!--coloro:#FF0000--><span style="color:#FF0000"><!--/coloro-->LINK NOT WORKING/Great game feauring cuztomizable character!(too busy)<!--colorc--></span><!--/colorc--></b>
See topic if you want to help(click the image)

#36 bombshell

bombshell

    GMC Member

  • GMC Member
  • 1607 posts

Posted 20 May 2009 - 03:08 PM

well done.
I love it!
10/10
  • 0
http://bombshell93.deviantart.com/

Our emotions each take the form of a Demon. These Demons roam our mind looking for little quirks they can take advantage of. It is up to us to control out Demons. Or they will consume us and control us. You need to find your angel before your Demons do. Or the devine hero saving the memories and thoughts that keep you going will fall.

#37 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 21 May 2009 - 09:05 PM

Thanks very much bombshell.
I will put in a better ammo system, but the main feature of the example is the AI <_<
  • 0

#38 GangsterAngel

GangsterAngel

    GMC Member

  • New Member
  • 47 posts

Posted 21 May 2009 - 11:31 PM

Played for like.. 1 min. But think its awsome, kida a odd lag to it sometimes, player dosent rotate on slope. but its cool.
mabye use a grid for floors, not lots of objs. Like use the objs but on create make them set values on a grid then destroy.
ud just need a picture background..

but yeh i like it
  • 0
Posted Image

#39 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 25 May 2009 - 09:38 PM

Added grenades, the player throws them and AI dodges them. simple. added some cool blood!
  • 0

#40 amberyoukai

amberyoukai

    GMC Member

  • New Member
  • 300 posts

Posted 25 May 2009 - 10:11 PM

Nice nades, but they blow up way to slow(easy to fix though)
And the idea of dead bodies is cool, but if the player dies colliding a wall, the body will float randomly.
  • 0
<a href="http://gmc.yoyogames...owtopic=425413" target="_blank"><img src="http://i234.photobuc.../RedGuysig.jpg" border="0" class="linked-sig-image" /></a>
<b><!--coloro:#FF0000--><span style="color:#FF0000"><!--/coloro-->LINK NOT WORKING/Great game feauring cuztomizable character!(too busy)<!--colorc--></span><!--/colorc--></b>
See topic if you want to help(click the image)

#41 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 25 May 2009 - 10:24 PM

hmm like a bad ps2 game. the only way to fix that would to be adding ragdoll physics.
  • 0

#42 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 27 May 2009 - 03:26 PM

Bump:
Update:
  • Added Friendly AI that follows you and shoots other AI
  • Added head shots and head decapitaion
  • fixed some bugs

There is a bug with bullet collisions Im having trouble fixing, collisions work fine for players gun but not for other.
-Crispy

Edited by Crispy, 29 May 2009 - 07:04 PM.

  • 0

#43 bombshell

bombshell

    GMC Member

  • GMC Member
  • 1607 posts

Posted 27 May 2009 - 03:41 PM

truly amazing though the friendly AI does occasionally get stuck in corners of walls,
you inspired me to make my TDS Engine.
(don't wuz I made everything from scratch and didn't copy anything.) its in my sig if you want a look ::lmao::
I love the blood :) and the decapitation could you possibly make it so their head flies off rather than disappears?

EDIT: turn on interpolate colors between pixels and it looks absolutly amazing!

Edited by bombshell, 27 May 2009 - 03:43 PM.

  • 0
http://bombshell93.deviantart.com/

Our emotions each take the form of a Demon. These Demons roam our mind looking for little quirks they can take advantage of. It is up to us to control out Demons. Or they will consume us and control us. You need to find your angel before your Demons do. Or the devine hero saving the memories and thoughts that keep you going will fall.

#44 amberyoukai

amberyoukai

    GMC Member

  • New Member
  • 300 posts

Posted 27 May 2009 - 08:34 PM

Nice new features man!!!!
I just found that the blood spills way to long and makes the game super bloody LOL
And something that kinda bugs me but its not important is the fact that you can point exactly up.
Any ways nice 8/10
  • 0
<a href="http://gmc.yoyogames...owtopic=425413" target="_blank"><img src="http://i234.photobuc.../RedGuysig.jpg" border="0" class="linked-sig-image" /></a>
<b><!--coloro:#FF0000--><span style="color:#FF0000"><!--/coloro-->LINK NOT WORKING/Great game feauring cuztomizable character!(too busy)<!--colorc--></span><!--/colorc--></b>
See topic if you want to help(click the image)

#45 beatson

beatson

    GMC Member

  • GMC Member
  • 319 posts
  • Version:GM8

Posted 29 May 2009 - 12:57 PM

The friendly AI only moves to the players x and not y, so sometimes hes stuck on an above/below platform to the player - can this be fixed?
  • 0

VIS Design - Quality Web Design & Development


#46 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 29 May 2009 - 07:00 PM

This dosent really fix the problem, but I have made it so the enemy warps to the player if he gets to far away. enjoy, and thanks for all the positive feedback :P

Edited by Crispy, 29 May 2009 - 07:03 PM.

  • 0

#47 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 06 June 2009 - 07:40 PM

Bump, update
probally my last update on this.
Whats new?
  • a new ammo clips system
  • Enemys drop guns
  • Changed the bullets, now less glitchy
  • added a metal gear style explantion mark
  • guns make noise (that the AI can hear)
  • AI now reload

  • 0

#48 orange08

orange08

    Art Game Movement

  • GMC Member
  • 2258 posts
  • Version:GM:HTML5

Posted 10 June 2009 - 12:02 AM

Ill download this again and try out the update. :rolleyes:

Edit: Wow! Really nice!
Did you make that explosion sprite, though?

Edited by orange08, 10 June 2009 - 01:22 PM.

  • 0

Z8vrE7W.png WRhLqHy.png
"I'm just glad Off-topic isn't being removed. Otherwise I risk actually doing something productive." -RoyTheShort


#49 haconkerlo

haconkerlo

    GMC Member

  • New Member
  • 1 posts

Posted 24 June 2009 - 10:35 PM

Mine wouldn't work because of like 50 unknown variables

help
  • 0

#50 Crispy

Crispy

    Black Sun Empire

  • GMC Member
  • 1217 posts
  • Version:GM8

Posted 27 June 2009 - 05:00 PM

Oh, that may be because you have to set all unknown variables to 0, its one of gamemakers options Im sure you can find it somwhere.
  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users