Home LittleBigPlanet 2 - 3 - Vita - Karting LittleBigPlanet 2 [LBP2] Help!
#1
Advanced 4-way goal logic
Archive: 18 posts
Hey all. I have seen a few different help and tutorial posts regarding goals and I wanted to open a discussion regarding advanced 4-way goals. what I mean by that is... I have been working on my first VS level and I am having some issues with the scoring. Think soccer, meets air hockey, meets shooter and you will kind of get the idea. I don't want to divulge too much info because it is an ambitious idea and I am hoping that it will also be an original idea as well. I am very close to finshing the beta version and the only thing that is holding me back is the score giving. Basically I have 4 goals set up, 4 vehicles, and one "puck" or object that is to be knocked into any goal. I also want it set up so that the players or vehicles will also give score when they are knocked into a goal. I have tried various combinations of score givers and sensors but I just can't seem to differentiate between who gets the points and who loses points. Please help. Anyone who offers up useful information will be added to the credits of my level and I can assure that once this is finished it is going to be a MM pick. I have pulled all the stops on this project and have actually spent about 1500 minutes on this level alone. So I can assure that your assistance in this matter will not go over-looked. Thanks in advance. | 2011-03-11 20:28:00 Author: tru3_skitz0 Posts: 114 |
If the vehicles are controlled by controlinators, just put the score giver in that. it will go straight to the person inside of it. | 2011-03-11 21:20:00 Author: comishguy67 Posts: 849 |
Awesome, one more thing to try. I will be giving it a shot in a few. If this makes the difference then I will surely add your name to the credits. I should be able to update this by this evening. Anyone else who has any input on this type of logic system, please keep replying. LBPC is the greatest, thanks so much. | 2011-03-11 21:39:00 Author: tru3_skitz0 Posts: 114 |
Giving the points to people that shove a car into he goal is an interesting one. What you need to know is which vehicle last hit the one in the goal. So here's a way that may work. On each vehicle have a tag that is unique to that vehicle. I would use the same color tags, but have different labels for vehicle_1, vehicle_2, etc. On each vehicle place a selector with four inputs. The first input (default) should have nothing connected to its output. On the other three inputs have impact sensors that are set to detect the tags of each of the other vehicles. This gives you a way to keep track of which vehicle last hit you. On the three outputs of the selector have AND gates. On the other input of that AND gate, attach your "I just crossed the line" logic signal. On the output of each AND gate have a correlating tag that is specific to the other vehicle represented by that selector. When the vehicle crosses the line it will pulse the AND gates, giving only the tag related to the active selector output the pulse. Now just have a tag sensor on each vehicle that waits for that tag to be active, and let it activate a score giver. Now only the last vehicle to hit one will get points. To make it more robust you could connect the three outputs of the selector with tag sensors to start a timer counting up. attach the output of that timer to your "default" selector input. Have the output of the "default" selection go into the reset input of the timer to have it ready for the next hit. Now, if after a certain interval the vehicle hasn't gone past the goal line, it no longer counts as a point for anyone else if the driver does it on his own. Also run the "I just crossed the line" pulse into the default selector input. What this all does? Let's say your timer is 1 second. I'm in my vehicle and you hit me. Now both of our selectors count each other as our last contact and start the timer. If you then bounce off and cross the goal, I get a point, and if I cross it, you do. However, once either of us crosses the goal, our "last hit" system is reset so that if we drive back across before another impact, no points re given. If we are hit in the middle of the play field the timer starts. If we have not been hit again in the past second, this also resets our system and there's no points given for an accidental crossing until you hit someone else, or are hit by them. I suppose the only down side to this is that people already inside the goal could just keep nailing each other to give points, so you would probably want to set up your logic that activates when entering the scoring circle as a single pulse to avoid that. I hope i explained that right. | 2011-03-11 22:10:00 Author: tdarb Posts: 689 |
Thank you so much for the input as I have been working with the first suggestion and am having some trouble still, This sounds like it may very well be what I was looking for. As stated above, I will add your name to the credits. I think it is great that I have been getting so much help between my friends and LBPC. I can't wait for the beta version to be finished and I hope it is received well by the community. Thanks again and I will add another reply once I have had time to work with these ideas. Thanks a million! | 2011-03-12 02:24:00 Author: tru3_skitz0 Posts: 114 |
Okay Tdarb, I gave it some more thought this morning and I feel silly for not realizing this last night. The only problem with your idea is that, in my level, it doesn't matter who hit last. There are four goals and four colors so no matter who hits the puck or player into the red goal, red player gets the points. SO far the biggest issue that I am having is getting the goal to give or take points away from its respective players color only, and to differentiate between the puck, the other players and self. So back to the drawing board and keep the ideas coming please. Don't let this thread die as it is obviously something that can be very useful. Thanks. | 2011-03-12 12:45:00 Author: tru3_skitz0 Posts: 114 |
ahh, I was thinking that you were setting it up so players could score in any goal. yeah, that makes a difference if players have their own goals. | 2011-03-12 20:08:00 Author: tdarb Posts: 689 |
I have not played extensively with score givers, but from what I have worked with them and from all that I've read in these forums, I would think you could put a score giver on each player's controlinator (assuming that's how these are being moved) set to award points only to that player, and wired up to a tag sensor, each having a unique tag color/name combo (maybe... all 4 blue, but named player1, player 2, etc). Now you'll also want a tag of the same color/name combo on it (don't worry, a corresponding tag cannot trigger a tag sensor that is on the same chip). As well as a general score tag (same color/name for all 5 of these) that goes on all four vehicles as well as the puck. On each goal, place two tag sensors: one for the general scoring goal, and another for this player's tag name/color combo. Using a NOT gate / AND gate combination, set up logic so that if the goal is crossed at all (the general score tag) AND is NOT this player (I'm assuming you want to prevent a player from just running in and out of their own goal to rack up their score), then trigger a tag on the goal that is set to that player's tag color/name combo. This will trigger the tag on the correct player's controlinator and should register the points only to that player (the owner of that goal). You may need to add a one-shot counter pulser (counter set to max 1, with the output wired to the reset) to make sure the score only gets registered once. So to review... Each vehicle's controlinator: 1 Tag Sensor, set to tag name (Player # - or whatever), and wired to... 1 Points Giver (set to award only to the single player) 1 Tag Sensor, set to tag name (Player # Penalty), and wired to... 1 Points Giver (set to SUBTRACT from a single player) 1 Tag (Player #) 1 Tag (General Score) - same color and name for all players on this [Possibly need a pulser between the Tag Sensor and the Points Giver...] Each Goal: 1 Tag Sensor (Player #) 1 Tag Sensor (General Score) 1 Tag (Player #) - wired to trigger only if General Score is on AND the Player # is NOT 1 Tag (Player # Penalty) - wired to trigger only if General Score is on AND the Player # is ON Puck: 1 Tag (General Score) I hope this helps. I won't have a chance to wire this one up for you (at least for a day or two), so I hope it was clear enough. | 2011-03-12 22:30:00 Author: v0rtex Posts: 1878 |
Thanks so far v0rtex, just out of curiosity, does this logic set up include the ability to subtract points for a player who was knocked into their own goal? So far everything looks good and yes I want to make sure that no one can enter their own goal to gain points but I also want to make sure that if a player is knocked into their own goal, then that player will lose points. This has been a big help already. Thanks so much. | 2011-03-13 17:11:00 Author: tru3_skitz0 Posts: 114 |
Thanks so far v0rtex, just out of curiosity, does this logic set up include the ability to subtract points for a player who was knocked into their own goal? So far everything looks good and yes I want to make sure that no one can enter their own goal to gain points but I also want to make sure that if a player is knocked into their own goal, then that player will lose points. This has been a big help already. Thanks so much. I've edited the parts list at the bottom of my previous post to account for a penalty if the player enters their own goal. Also, FWIW... I am wondering how you are triggering goals. Because there are two ways to approach it. The first is just as I've already described, with tags and tag sensors. Using this method the tag sensors on the goals have to be tweaked to just the perfect angle/radius. But another very effective way to do this is to glue invisible holo in the same shape as both goal and vehicle (and puck too, actually), and use impact sensors. The impact sensors must be attached to the holo for this to work, but it can make the logic a bit more streamlined. Anyway... just throwing that out there. Good luck! | 2011-03-13 19:14:00 Author: v0rtex Posts: 1878 |
Ya know what? I think the best thing to do would be to add me as a friend and we can join up in my pod and work together. What do you think? | 2011-03-13 22:09:00 Author: tru3_skitz0 Posts: 114 |
Ya know what? I think the best thing to do would be to add me as a friend and we can join up in my pod and work together. What do you think? Well we could, but it's unlikely that I would respond to your invites. And that's nothing personal... I almost never respond to invites. I tend to be kind of a loner in create mode. If you really, really get stuck I may be willing to pop by for a while, but it's just not my style. I suppose most folks think that's weird, but that's just who I am. Give what I've described a try and see what you can do with it. | 2011-03-14 02:17:00 Author: v0rtex Posts: 1878 |
That's kool mang, I totally understand that. I really do. I just thought I would throw it out there. I will give your suggestions a try and let you know how it goes. I have very little time lately and pretty much just pop on to LBPC every once in a while throughout the day but I will be getting back into my level very soon. Stay tuned to see how the level progresses from here. Thanks again. | 2011-03-14 02:37:00 Author: tru3_skitz0 Posts: 114 |
Thanks to v0rtex, a beta version of this level will be available soon. I spent a couple hours rewiring and setting up the score logic. Just a couple more things to tweak and it will be ready for testing. YAYYY!! | 2011-03-21 22:58:00 Author: tru3_skitz0 Posts: 114 |
you could setup a negative score giver for everytime a player goes into his corresponding goal...setup via tag sensor or impact sensor on a holo material set to touching....not sure if you had that solved yet. | 2011-03-21 23:31:00 Author: Unknown User |
If the vehicles are controlled by controlinators, just put the score giver in that. it will go straight to the person inside of it. This is not necessarily true; if the signal that triggers this score giver carries ownership data from another player (for instance, a projectile sensor) then it will award the score to that player regardless of where the SG is located. When no ownership is present, then the SG's context becomes important. If this becomes a problem (i.e., you want a player getting hit by someone else's projectile to get a score penalty deduction), there are ways to make a signal anonymous. One way I know is using the signal to activate a microchip which contains a battery; that battery is then hooked to the score giver. | 2011-03-22 09:59:00 Author: Antikris Posts: 1340 |
Okay, I have set up everything as well as I can tell but I am confused about the and/not gate logic because I need the and to connect to something or nothing will be triggered correct? If I wire it to the corresponding player vehicle, will I still be able to emit it? I need the vehicles to emitted so that if there is no player 3 or 4 then there will be no vehicle 3 or 4. This is where I am stuck at this point. I have some other logic to rewire so I can do a few test runs but until then, if you have any further input please post. | 2011-03-22 17:36:00 Author: tru3_skitz0 Posts: 114 |
Okay, scratch that last post. Everything is working except for the tag system on the goal itself. I need to figure out a better way to trigger the penalty. The way it is now, it only works if you are in the right spot inside the goal. I will experiment more but the good news is that the score system is working. Stay tuned for more updates, this is gonna be neat. | 2011-03-22 17:54:00 Author: tru3_skitz0 Posts: 114 |
LBPCentral Archive Statistics
Posts: 1077139
Threads: 69970
Members: 9661
Archive-Date: 2019-01-19
Datenschutz
Aus dem Archiv wurden alle persönlichen Daten wie Name, Anschrift, Email etc. - aber auch sämtliche Inhalte wie z.B. persönliche Nachrichten - entfernt.
Die Nutzung dieser Webseite erfolgt ohne Speicherung personenbezogener Daten. Es werden keinerlei Cookies, Logs, 3rd-Party-Plugins etc. verwendet.
Die Nutzung dieser Webseite erfolgt ohne Speicherung personenbezogener Daten. Es werden keinerlei Cookies, Logs, 3rd-Party-Plugins etc. verwendet.