Mr. Potatobadger Posted July 18, 2013 Report Share Posted July 18, 2013 Hello there. I'm trying to create a partner system, i.e. Sonic 3, advance 3, chaotix, adventure, etc. I have no clue where to start or how it would work. I'm looking for someone to tell me how and where to start, so I can figure out the rest and gain some experience from this. Thank you Link to comment Share on other sites More sharing options...
Zeritar Posted July 18, 2013 Report Share Posted July 18, 2013 This might not be a suffecient way, but it's the only thing I can come up with. I would make a clone of the player object, but add a short delay to all the actions like jumping, ducking and such. I'm guessing this would take a lot of resources though. Link to comment Share on other sites More sharing options...
Mr. Potatobadger Posted July 18, 2013 Author Report Share Posted July 18, 2013 I have indeed thought of this, but I need something like knuckles chaotix, or sonic advance 3, where you can physically grab the character. That comes later on obviously, and I know how I would do that. But the main focus as of now is to actually get the partner on the ground. I'm not necessarily sure how you would even clone the player and put him in the level. I already have tons of values and a character selection screen and such, but now I just need said partner in the game, whether he moves or not. I could figure that out later. I hope that made sense. Link to comment Share on other sites More sharing options...
Highwire4 Posted July 19, 2013 Report Share Posted July 19, 2013 Wait, are you having trouble putting in a player clone that follows the player or are you trying to get the menu to work to where it chooses and spawns different clones? Link to comment Share on other sites More sharing options...
ZigZaX Posted July 19, 2013 Report Share Posted July 19, 2013 We have a theory on how to get the second one to work, but we havent even been able to get the "seccond" player(a.i. partner) to appear in the frame, so we cant test out how to get it to move yet. Link to comment Share on other sites More sharing options...
Highwire4 Posted July 19, 2013 Report Share Posted July 19, 2013 Ah. Well you have the physics and the hitboxes for the player right? Why not just duplicate the code that keeps the player in the world and have it mimic the x co-ordinate global values of the player after a slight delay? Link to comment Share on other sites More sharing options...
Mr. Potatobadger Posted July 19, 2013 Author Report Share Posted July 19, 2013 That's the theory, but I'm not sure where to start or where to put the code. Link to comment Share on other sites More sharing options...
Mr. Potatobadger Posted July 19, 2013 Author Report Share Posted July 19, 2013 Copied from sonic retro, http://info.sonicretro.org/Sonic_the_Hedgehog_2_(Simon_Wai_prototype "The concept for a partner is still a work in progress as Tails can lose rings for the player when hit, just like in the Nick Arcade prototype. Tails' AI is much simpler: he simply copies the moves that Sonic makes, and makes no attempt to keep up with Sonic." That's exactly what I don't want, But I think I may have to start that way, but I don't know how. Link to comment Share on other sites More sharing options...
Highwire4 Posted July 19, 2013 Report Share Posted July 19, 2013 Well first things first, set up the new hitboxes for the AI and make sure those go to where they're supposed to. Analyzing the code of Sonic Worlds will tell you that info. Link to comment Share on other sites More sharing options...
Mr. Potatobadger Posted July 19, 2013 Author Report Share Posted July 19, 2013 alright, makes sense Link to comment Share on other sites More sharing options...
Zeritar Posted July 19, 2013 Report Share Posted July 19, 2013 Refering to the Simon Wai prototype, you could make the partner clone the movement for a start. Then add the function of "finding" the player if the partner gets too far away. This is all beyond me though, since I would have no idea how to do that. Link to comment Share on other sites More sharing options...
StealthyMC Posted July 19, 2013 Report Share Posted July 19, 2013 I'd say use finite state machines to program the AI, so you should look into that. From what I know, state machines are VERY useful for programming AI. Link to comment Share on other sites More sharing options...
Mr. Potatobadger Posted July 19, 2013 Author Report Share Posted July 19, 2013 What is a finite state machine? Also, I tried doing the sensor thing. I created dupes for all the sensors, and even created a new value called Partner_MovementValues. I had a screenshot, but I dunno what I did with it. I did everything I could and the only thing I managed to do was make sonic not be able to collect rings. Anyways... The point is What is a finite state machine? Link to comment Share on other sites More sharing options...
StealthyMC Posted July 20, 2013 Report Share Posted July 20, 2013 Actually scratch the last thing I said, I'm not sure if finite state machines can be used in MMF2. Unless you have a good sense of how to code in MMF2, I'm not sure how you could implement them. I only said finite state machines because I know that Game Maker can do it since many games run off of scripts. I never really understood how to use MMF2, but there might be some kind of partner system tutorial on the net. Link to comment Share on other sites More sharing options...
Mr. Potatobadger Posted July 20, 2013 Author Report Share Posted July 20, 2013 I actually did look up what you said and it would work perfectly. I searched for extensions and there isn't any, and mmf2 doesn't really have that kind of thing. Link to comment Share on other sites More sharing options...
Mr. Potatobadger Posted July 20, 2013 Author Report Share Posted July 20, 2013 Hey there I played sonic axiom for the first time, and it has an ai partner system. And it's powered by worlds. so Who made sonic axiom? I wish to seek his advice Link to comment Share on other sites More sharing options...
Mr. Potatobadger Posted July 22, 2013 Author Report Share Posted July 22, 2013 Hey all who care. I have a long car trip tomorrow, and I have a theory. I'm going to study the coding of tails super flickies, and see what that can tell me. Hopefully a lot. Link to comment Share on other sites More sharing options...
vexer Posted July 31, 2013 Report Share Posted July 31, 2013 Hi I am the one who made Sonic Axiom. I made my ai system from Streak Thunderstorm's "good tails follow engine", which can be found in these forums. Here's the link to the page with the download. http://www.sonicfangameshq.com/forum/showthread.php?t=5176&highlight=tails+follow Link to comment Share on other sites More sharing options...
Serephim Posted July 31, 2013 Report Share Posted July 31, 2013 If the physics of the partner is identical to the player, in order to mimic realistic movement you can just make some events to copy the inputs of the player and delay them by a second or so. As long as the partner starts from a similar position as the one he's following, it should pretty much work perfectly. The only actual AI you'd need would be to deal with things that desync you. I think the genesis games just made an attempt to get tails back to sonic's neutral position. If it was made too hopeless he'd just fly back and reset the sync by landing near you. The Ice Climbers in Smash Brothers follow a similar principle. Nana mimics the player input with a small delay until she's desynced, at which point she becomes one-track minded on getting close to Popo to be resync'd. Link to comment Share on other sites More sharing options...
Mr. Potatobadger Posted July 31, 2013 Author Report Share Posted July 31, 2013 Thanks for the help serephim, But I forgot to mention that I dropped the ai partner for this game. It was slowing me down trying to figure out how to do it, but I'm going to make a game in the future that revolves around it. Thanks again for the help. Edit: Well hey, I didn't notice that post you made vexer. I will definitely keep that for the future. I also decided that I wouldn't do the ai partner system because I want to keep level design based around the characters and there abilities. There's also 9 characters in my game. Yea. Thanks again for the help, guys. Link to comment Share on other sites More sharing options...
TailsSena Posted August 1, 2013 Report Share Posted August 1, 2013 Oh, wow. Sorry I didn't find this thread earlier... But in case anyone else needs a partner AI, I salvaged the remnants of my old custom Worlds engine. It includes the AI and some unfinished code for the basic five characters. (Sonic and Amy are relatively complete) So here it is. EDIT: The AI does attempt to keep up with you, but it's not terribly smart and struggles on complex terrain. Feel free to modify it to suit your needs. Link to comment Share on other sites More sharing options...
Mr. Potatobadger Posted August 1, 2013 Author Report Share Posted August 1, 2013 Don't worry about it, it's fine. I really appreciate it though, and I will implement the system in a future game. Thanks a lot everyone, I appreciate the help. Link to comment Share on other sites More sharing options...
Recommended Posts