Creating a complicated AI
Eastbound
Member, BASIC Posts: 1,074
Is there any way in GameSalad to do actual coding, as to make a complicated AI? Like for a fighting game or an overhead shooter?
And if you can't code what is the best method for going about this?
And if you can't code what is the best method for going about this?
Comments
For my upcoming shmup game, my enemies were gonna fly straight, but with some sines and math, they swerve and move in a pattern, just to make things more interesting for the user.
Additionally, I personally believe that what you really need to do is make your opponents give the illusion of being smart.
For example, in one of my upcoming games, the enemies fly straight then randomly pick up or down and move forward in that direction.
When you shoot at them, and they avoid your bullet, it looks as though they've done it on purpose when in fact they're just following the very basic rule I described.
It's a bit like the SWAT guys in the original Half Life. They weren't doing anything special, but the comm chatter you could hear gave the illusion that they were really smart!
Of course, if you actually wanted to give them 'proper' AI you could use a whole list of conditions that would dictate their behaviour.
If their health was low, for example, move away from player. If it's high, move towards player. If player has no ammo, or is reloading, move in. If player is not visible, move in random direction.
Or you could put put in invisible waypoints. This way, enemies could patrol along paths.
Move enemy towards waypoint 1.
When waypoint 1 is reached, stop for 2 seconds. Then move to waypoint 2 etc etc
Within those rules you could have 'If enemy spots player, move towards player and shoot every 3 seconds'.
It really depends on what you want. But using logic and a little imagination, you could pretty much do anything with the behaviours we have at the moment.
Or not! YOU BE THE JUDGE!
Hope that helps,
QS
Dr. Sam Beckett never returned home...
Twitter: https://twitter.com/Quantum_Sheep
Web: https://quantumsheep.itch.io
To answer my original question forwardly: No, you cannot make complicated AIs. I don't consider enemies moving in arcs and such as complicated AI.
For instance if you wanted to make a 2D fighter (such as Street Fighter) with a somewhat believable AI it would be nearly impossible.
Dr. Sam Beckett never returned home...
Twitter: https://twitter.com/Quantum_Sheep
Web: https://quantumsheep.itch.io
Dr. Sam Beckett never returned home...
Twitter: https://twitter.com/Quantum_Sheep
Web: https://quantumsheep.itch.io
Yeah, but how COOL would that look?
Dr. Sam Beckett never returned home...
Twitter: https://twitter.com/Quantum_Sheep
Web: https://quantumsheep.itch.io
http://shop.lego.com/product/Default.aspx?p=10181&LangId=2057
Dr. Sam Beckett never returned home...
Twitter: https://twitter.com/Quantum_Sheep
Web: https://quantumsheep.itch.io
Bah, who kidding.
It IS the size that matters.
And that Lego Tower is SMALL
I even tried throwing the whole collision rule in a timer & that did not work either. Maybe it was a bug, I don't know. Have you had any luck thus far with it? I put that game on hold for a while, b/c of many issues, but the range thing was one. Now that I know about the whole magnitude thing, I reckon that could solve the range attack issue.... I haven't tried it again yet.
So it probably won't change non-coders.