Home    LittleBigPlanet 2 - 3 - Vita - Karting    LittleBigPlanet 2    [LBP2] Help!
#1

Help! I need to create a fast, powerful ball that can be thrown.

Archive: 7 posts


I am new at the create portion of this game. I want to create a ball that can be thrown with some speed and power. I have been working on trying to create one for the past eight hours. I have had some close calls, but nothing that really meets my needs. I love the game, but man, creating levels is far more difficult than I thought. To the people that are creating wonderful levels online, thanks. Once I started to create some of my own, it makes me appreciate your work even more.2011-02-18 09:13:00

Author:
peerenboom77
Posts: 2


What do you mean by speed and power? Do you want to throw it fast and hard? Or did you want to throw multiple things really fast? It sounds like you're making a kind of game where you bounce a ball and catch it.2011-02-18 09:17:00

Author:
Devious_Oatmeal
Posts: 1799


Fast and hard. I am making a dodgeball game with a LBP spin on it.2011-02-18 09:21:00

Author:
peerenboom77
Posts: 2


Are you using grabinators? If so, I don't think you'll be able to achieve the fast and hard effect you're looking for. You could always fake it. Have the players in sackbots and have the balls emit out of their hands...? Though, not sure how you'll catch the ball then.

...Just brainstorming.
2011-02-18 09:46:00

Author:
Ninja_Gnome23
Posts: 198


Just go with gnome's idea and have them wear grabinators. Then destroy the ball when it's thrown. It'll take some tweaking, but it sounds plausible.

You could also use movers. When the ball is grabbed no movers activated. Depending what side the ball is thrown from, it shoots to the other side when the player lets go.
2011-02-18 10:00:00

Author:
Devious_Oatmeal
Posts: 1799


movers are your unit here.

The best way i can think to do it off the top of my head is:

Have the ball in question have a chip on the direct center. On this chip have a tag sensor attached to an advanced mover's left right up and down inputs.

(The only real way you can do this next bit is to use sackbots in your level instead of players. You can have each of the 4 sackbots look exactly the same as the players entering the level and have it so everything is set up that the players don't even know they're sackbots, have them enter the bots in the beggining automatically e.t.c., there are many tutorials on how to do all that, just look about on here.)

In each sackbot have a tag and an emitter.

Next get 4 pieces of hollo, place a chip on the center of each piece of holo and in that chip place a follower unit set to follow the tag on 'that' sackbot', Also place a tag in the chip, these tags must be the same (same label is best), and capture each piece, set each of the emitters on the sackbots to emit 1 of these pieces of hollo on the sackbot.

What you should have so far is:

- 4 sackbots > on each sackbots chipboard> 1 unique tag (by colour or label)
- 4 pieces of holo > on each holo a chip, in each chip a follower unit set to follow 1 of the tags in each sackbot. so you have 1 piece of hollo following each bot.
- 4 identical tags. 1 in each chip on the 4 pieces of hollo.

Now, set the sensor in the chip on the ball (thats plugged into the advanced mover) to 'signal strength'. To find this, scroll down to 'output' on the sensors options and change 'closeness' to 'signal strength'.

Next place a grab sensor in the chip on the ball. Have the grab seonsor linked to a tag, so the tag turns 'on' when the ball is touched.
Place a sensor on each sackbot with a very small radius, slightly bigger than the bots physical body size, set the sensor to the same frequency (colour) as the tag hooked up to the grab sensor. (you want it so when a single bot grabs the ball, it turns on the tag and the sensor in 'only' that bot turns on. this why you want small ranges on these sensors, so this mechanism doesn't effect other bots)

Next hook up the output of the sensor on the bot to the input of the emitter that emits the holo.

Set the emmited holo to be destroyed when the ball is grabbed, To do this, link a tag up to the grabswitch on the balls chip, now put a sensor in the chip on each holo linked up to a destroyer. Make the sensors range maximum. Also make the input of the tag in the ball triggering these sensors a 1 shot. To do this use a counter set to one, with tt eoutput linked to its input.

This means when the ball is grabbed, the first instance its grabbed it will 'pulse' the tag instructing the sensors to destroy any of the holo pieces currently in the game.

Next put a .1 second delay between the grab sensor and the tag telling the sensor on the bot to emit the holo (to do this simply put a timer set to .1 routed into its own reset between the grab sensor and the tag). This will ensure all holo is destroyed, then .1 seconds later, the 'correct' holo is emmited and will therefor be the only possible input to the balls advanced mover. The next time the ball is grabbed, this process repeats, destroying all holo, then emitting only the correct holo from the correct bot.

What this should all do:

First i'll explain the ball.
- The sensor picks up a signal from the tags emitted on the holo when the ball is grabbed, The sensor will then input an analogue signal to the advanced mover corresponding to the closeness of the ball to the tag (sackbot).
- the closer to the tag, the higher the 'strength', the larger the signal inputting into the ball, the 'faster' the ball will move (e.i. the closer to its 'movement speed' setting, at 100% signal, it will move at 40, if set to 40, at half way between the tag and the range's outer radius, it will move at 20... e.t.c.).
- This will emulate a 'throwing strength', the ball will decrease in speed the further it traverses away from the bot as its thrown.

Now the bots:
When the ball is grabbed, a tag is emitted on a piece of hollo that follows that bot (you can't emit tags 'into' the bots chipboard). When the bot lets go of the ball, the tags influence on the mover in the ball will send it flying off away from the bot. at a rate linearly decreasing the further it gets.

Thinking about it. To get the mover to act 'properly' you may need to attach a look at rotator to the balls chip aswell, set the look at rotator to look at the tag emitted on the chip in the holo, set speed and range to max.

Now 'invert' the signal coming from the sensor into the advanced mover. You only need to plug the sensor into the 'up/down' input on the advanced mover. To invert the signal, Plug the sensor output into a direction splitter, then plug the NEGATIVE output of the direction splitter into the advanced mover.

Also MAKE SURE you set 'local space' to 'yes' (tick) in the advanced mover.

Doing all of this will always ensure that the ball is moving directly away from the bot that has just thrown the ball.

There may be glitches in this system and you'll have to tweak about with allot of the settings and such to get it exactly how you want. But this is deffinately the route you want to be heading down.

Good luck!

BTW, use grabinators for the grab mechanic.
2011-02-18 11:38:00

Author:
Epicurean Dreamer
Posts: 224


Yep, just tested it out, works perfectly. Ive tweaked bout with the idea a bit though. If you're interested i'll go into it a bit more. Just tested it out in game and its fine.

Heres a quick pick of the logic see if you can decipher it. If not i'de be happy to meet you in game and pass it over to you. orry i've not gone into it more right now i'm in a rush.

heres a pic:

http://i2.lbp.me/img/ft/4328c133f9b450b2da0cb5bfcadb9b20df75321e.jpg

p.s. you'll havew to addapt it a bit for 4 players. But the ball FLIES away very fast. I set the cam to maxed out zoom and offset to one side and threw it that way, it wen't pretty far pretty fast

It works in either direction too, had to add a bit of logic to sort the directional thing out, but works fine now.
2011-02-18 13:05:00

Author:
Epicurean Dreamer
Posts: 224


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.