AI for SmashTV
I am currently programming a 3d version of Smash TV and am trying to give the enemies ai that cooresponds to the original game. Right now the enemies turn toward the player and follow him, but in the original game they do this and also go off on their own paths occaisionaly, giving their movement a more speradic look. I have not been able to find anything on AI to allow me to do something like this. If anyone knows a good way to do this please let me know.
The funny thing about driving a car over a cliff is, you still hit those breaks. Hey! Better try the emergency break!
You just said the answer yourself:
if (90%) {
go for the player
} else {
go somewhere random
}
if (90%) {
go for the player
} else {
go somewhere random
}
Not to answer your question since it seemed to of gotten a great answer already but, I am curious about this game project big time. You have a sight for it? Is it openGl? What else about it? I have thought for a long time smash tv would be cool in 3d, and bingo it seems your doing it
post a web site or something, so we (I) can track the development of this game...it interests me.
-Shane
post a web site or something, so we (I) can track the development of this game...it interests me.
-Shane
mmmm Smash3D. wanna play.... roy@voxelsoft.com
For AI, you might want to make some sort of system where most of the people will run straight at the person, while some hide away in corners, and other will go around in a loop and try to loop around the person and attack from the back...
What are the controls like? WSAD for moving, Arrows for shooting? Mouse for shooting? Lemme know...sounds like it rocks.
--SuperRoy
[ www.Google.com ][ FlipCode IOTD ]
[ Email Me ][ WhitespaceUnlimited ]
[edited by - SuperRoy on November 17, 2002 5:19:56 PM]
For AI, you might want to make some sort of system where most of the people will run straight at the person, while some hide away in corners, and other will go around in a loop and try to loop around the person and attack from the back...
What are the controls like? WSAD for moving, Arrows for shooting? Mouse for shooting? Lemme know...sounds like it rocks.
--SuperRoy
[ www.Google.com ][ FlipCode IOTD ]
[ Email Me ][ WhitespaceUnlimited ]
[edited by - SuperRoy on November 17, 2002 5:19:56 PM]
Sup guys?
Wow! I always thought this would be a great project, but it seems more people than i have thought are more interested than i thought. First of all the solution i was given will not work quite right for this, as the enemys position is updated every frame, so the enemy would just look jerky as it moved around, instead of actually moving all the way to a different location. Secondly the controls currently are esdf-movement ijkl-firing, i chose these because my keyboard has the little bumps on the f and j, and they are home row. I do plan on implimenting mouse as well as joystick support. Next i currently do not have a site up for it but will soon, i have webspace from my university, but can''t remember the address, if you leave your email i can email it to you, or i will try and post it here if i find it soon enough. Yes, the game is in OpenGL, I am using MD2 models for the player/enemies, and currently the level design is done simply by hard coding them using a few functions to draw different shapes. The game coding is almost all done, but the player/enemy models need a serious makeover, and alot of time needs put into level design(to make them look nice, they are just squares of course). I will put up the site ASAP and let you know the address. Until then ANY MORE IDEAS FOR AI. Once i get the ai done it will be all level/character design and some optimizing and i could release a demo.
The funny thing about driving a car over a cliff is, you still hit those breaks. Hey! Better try the emergency break!
ha, i found the website name. NOTE: there is no game content on there right now, check it though in 2 or 3 days.
http://php.indiana.edu/~rjlouie/
http://php.indiana.edu/~rjlouie/
The funny thing about driving a car over a cliff is, you still hit those breaks. Hey! Better try the emergency break!
Hmmm how about a state machine for the ai, it picks what to do (go for player 90% as given in above example 10% do something else) if the enemies position is updated everyframe then do it like this: If its the other 10% then randomly pick a target on the map and "Vector" twards it....(i have the code to do this in 2d but its some easy vector equations) and while its vectoring twards this radomly picked point u have a counter in ur enemy structure or class or whatever that holds the state (which would be "vector twards random point x,y,z") then after it either reaches the point or the counter counts down u then go through and fish for another state...
Wow you sounds like you are quite far on this game, that rocks! Are you going to release source to the game?
-Shane
Wow you sounds like you are quite far on this game, that rocks! Are you going to release source to the game?
-Shane
That is almost the idea i had, i realized it right after posting the message. Instead of 90 percent to player and 10 percent somewhere else each frame, it will follow the player until eventually(the 10%) it will pick a random spot, maybe not even random. Maybe a specific spot on the map based on the players direction to try and head them off and then go to that spot, once the enemy is at that spot, it goes back to following the player. As far as you vector towards point idea, if i understand what you are saying, i don''t even need it, my enemy already points toward and follows the player everywhere by passing in the x and y coords to the enemies AI function, so i would just have it choose different xy coords from the ones passed in, and then let it move there on its own.Then when it gets there, let it take the xy coords from the player''s position agian. As for releasing the source code i definantly will eventually, but first i am going to contact Xgames3D, the publishing company for 1 or 2 man game dev teams(run by one of the guys who helps with this site), and see if they might publish it. If so, it will be a while before source code is released, if not, it will be posted as soon as its done.
The funny thing about driving a car over a cliff is, you still hit those breaks. Hey! Better try the emergency break!
dah, i always think of stuff right after i post. Even if i do get the game published(not sure how likely that is, but i have a game they published and mine is way better), i could still maybe release the source, it would just be copyrighted. If not, i could email it to you right before i send it to xgames3d .
The funny thing about driving a car over a cliff is, you still hit those breaks. Hey! Better try the emergency break!
Better be careful about copyright infringement if you''re going to publish this.
Cool project though - for months I''ve been thinking about doing the same thing. Do you want any help with music/sounds? I''d love to contribute. I have some samples here: http://www.aisle4.com/music.php , though they''re not quite the high-energy stuff that should go in a Smash TV game.
Cool project though - for months I''ve been thinking about doing the same thing. Do you want any help with music/sounds? I''d love to contribute. I have some samples here: http://www.aisle4.com/music.php , though they''re not quite the high-energy stuff that should go in a Smash TV game.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement