Home    LittleBigPlanet 1 - PSP - Tearaway -Run Sackboy Run    LittleBigPlanet 1    [LBP1] Help! [Archive]
#1

Make an object change layers

Archive: 11 posts


I've been working on-and-off on a pinball level. One thing I want to try to add is a ramp that will make the ball move into the front layer. Well that's not too difficult to accomplish: stick an emitter on the ball and set it to emit another ball in the front layer without any velocity settings and it will be emitted with the same velocity as the original one. I did a few tests last night and that part worked fine. Then you can either demit or crush the original one and you're good to go. Emitting the new one with the same direction/velocity as the original is important since the ball won't necessarily hit the ramp in the exact same way every time.

There's a couple problems, though. First, the new ball can't re-emit the old one--that whole chicken and the egg thing--so when it comes time to come back down from the ramp, the lower layer ball will have to be emitted fresh from another emitter, which means the direction and velocity of the upper layer one won't translate to it. Second, since the upper layer ball was emitted from the now-destroyed lower layer ball, it can't be demitted normally. Also setting its lifetime is no good since it won't necessarily move through the upper level at the same speed each time.

So my questions: what's the best workaround for the ball paradox that will best keep the illusion that it's only one ball? How can I destroy the upper level ball?
2010-04-12 19:11:00

Author:
Sehven
Posts: 2188


Is the ball dissolvable? If so, heres a solution for the destruction issue: create two balls, and put a mag key switch of a different color on each. Hook up the switch so that the ball will dissolve when the key switch is activated. When you emit the other layered ball, use another emitter to shoot out a small piece of material with the corresponding key to the switch. The switch will dissolve the old one, as the new one is emitted. Switching the keys will give you the same effect.

As to the illusion... perhaps the ball could land in a hole, instead of going up a ramp. The same speed and angle can be used every time when the new ball is launched from the hole, and the illusion that this is the same ball remains.
2010-04-12 19:54:00

Author:
Burnvictim42
Posts: 3322


It's not dissolvable, unfortunately. It's a fairy light, though I'm probably going to overlap some invisible metal into it to make it more sturdy. Getting rid of the first ball is easy enough though: it will be emitted from outside the table and will roll into the plunger thing, so all I have to do is set the max at once to one and trigger the emitter (though that might get more complicated if I decided to add a multi-ball function...which I probably won't due to camera restrictions) to make the first one disappear. The trouble is getting rid of the second one. Since it's being emitted from the first one, which is subsequently destroyed, I can't get rid of it by simply emitting another one.

The thing is I want the ball to go up the ramp with the regular physics: if it's been pushed hard enough, it'll make it through to the other end; if not, then it'll roll back down. I can kind of "fudge" the exiting by just emitting a new ball at approximately the speed and direction that a ball would exit the ramp, but it still leaves the problem of getting rid of the upper level one.

The ultimate solution would be a perfect 4 direction tracker to follow the ball and handle all emitting, but even the best trackers I've seen don't come anywhere near perfectly matching direction and speed.

I suppose instead of destroying the original ball, it could be pushed outside the table through a sort of hidden shunt. That way its emitter could be re-triggered once it's time for the upper level ball to exit the ramp. I'll have to give some thought to that and maybe do some experiments to see if it's practical.
2010-04-12 21:35:00

Author:
Sehven
Posts: 2188


Don't destroy the back layer ball. Have it shoot up the ramp and trigger the front layer ball, then have it caught in some sort of box or slot. When the front layer ball falls back down, have that fall into another hidden slot, which then triggers the first slot to open and the first ball falls back to the plunger. The cycle then repeats as the second ball disappears when the first ball reaches its slot. The only problem with this method is lack of continuity when the second ball falls down and triggers the first ball - the movements won't exactly match. You could slow the second ball's movement, as if it's engaging some sort of mechanism - that might help to conserve the illusion.2010-04-13 11:30:00

Author:
Holguin86
Posts: 875


The ball isn't meant to exit back out of the ramp the same way it came in. It goes in, shifts up a layer, follows a track that leads above the table, and comes out the other side. That is, if it has enough momentum: if it doesn't have enough momentum, then it'll fall back out through the entrance. There wouldn't be a way of moving the low ball to the new spot since the ball needs to be free to move under the ramp: otherwise, I wouldn't need to bother with the layer-shifting.

It may be that there's just no way to do exactly what I want. Seems kind of silly that such a small thing--moving a ball up and down a ramp--is so difficult/impossible in a pretty complicated physics based game.

I suppose shunting the ball off of the table and using it to demit the new ball is probably the only option. Then I'll just have emitters on both ends of the ramp to emit a new low level ball in whichever end the high level one exits. I really wish there was a way to make a paradox emitter setup: A emits B, B emits A.
2010-04-13 19:59:00

Author:
Sehven
Posts: 2188


I really wish there was a way to make a paradox emitter setup: A emits B, B emits A.

You can kinda do this, but only a finite number of times.
2010-04-13 21:43:00

Author:
Aya042
Posts: 2870


I did a pinball level that has a forward track, and a little area off to the left that the ball also had to change layers. The best solution that worked for me was to crush the ball. I came up with a crusher that worked flawlessly, so it was a good solution for me. I was thinking if you could make your ramp a tunnel you could hide the crusher, and emit just before the ball exits the tunnel. I don't know if I fully grasp your problem though. Also my biggest problem I had when switching layers with the ball was the "jump" you get from the camera. I never did get it totally smooth. Good luck! 2010-04-13 21:55:00

Author:
smasher
Posts: 641


You can kinda do this, but only a finite number of times.

I know, but finite just isn't good enough. Sure I could set it up so that the ball could go through the ramp ten times but the player who's good enough to hit it eleven times gets gypped. Unless there's another way of making an emitted object match direction and speed to another object, then I'll probably just have to do like I said earlier and fudge the exit emitter.


I was thinking if you could make your ramp a tunnel you could hide the crusher, and emit just before the ball exits the tunnel.

Ah, but that's how everybody else does it and doing things just like everybody else just isn't my style. The only reason for me to do a pinball level is if I can do it better than everybody else... or at least do some parts of it better. I've already worked in a system for "bumping" the table, though I'll need to fine tune the controls a bit before I'm happy with it, and I've got a multi-player system where two players can take turns and two other players can sit in a spectator box (though, really, you'd probably be better off not having more than two players in a level like this due to connection lag). I'm also planning on having at least two tables (maybe three if my ambition holds out that long) that you play through with a sort of mini-table that goes between them (you get to rack up points in the mini-table but you can't actually lose).

I suppose the ramp thing is minor, but it's just one of those extra bits of polish that I think really makes a level shine. Plus there's the whole novelty factor.
2010-04-14 08:58:00

Author:
Sehven
Posts: 2188


So you want the change in layers to be visible? Weeeeell ... one way is alright, the other way ... well, why don't you just block off the tunnel so the ball can't roll back down to the plunger after it's been launched?2010-04-14 22:54:00

Author:
Holguin86
Posts: 875


Is it possible to pre-determine the maximum speed at which the ball could be moving as it travels down the ramp?2010-04-15 00:59:00

Author:
IStwisted
Posts: 428


Holguin, I don't think I understand what you're saying. The plunger happens at the beginning: there's no layer changing there. There's just going to be a ramp on the table that the ball can roll up, which leads to a track that runs above the table and then it comes out the other end. While other pinball levels have just had the ball disappear into a pocket and then rolled another one along the ramp, my goal is to make it so that the player actually hits it up the ramp so that if it doesn't hit at the right angle/speed, it'll end up rolling back out rather than making it all the way through.

Twisted, it's not possible to pre-determine exactly because it will vary depending on the ball's speed and direction when it enters the ramp. That's what I meant by fudging it: I can sort of guesstimate what speed it'll be going if it rolls back out through the entrance, and I can just have it get caught if it makes it to the other end, have some lights flash and points awarded, and then have it release. It's not as cool as a perfect, physics based move from one end to the other, but it may be the best I can do. I suppose I'll have to build a test rig and see if it works. I'm also not sure I can make the transition between layers look good, so that may be a problem, too. Really, this hasn't actually moved past the "wouldn't it be cool" phase, except for the one quick test I did to make sure that one ball could emit another with matching speed/direction.

If there were a way to emit something so that it would be glued to another object that wasn't emitted, I could use a fake ball under the table and just have it emit both the normal level and upper level balls, but that's impossible (unless somebody finds a glitch that can glue objects together in play mode) and any sort of grabber mechanism to attach them would be too easy to break. The only other option would be to use my smokeless demitting trick, but it wouldn't look good at all with a fast moving ball. Also, if it were possible to make a tracker that could perfectly match the ball's movements, it could emit both the normal and upper level balls, but I'm pretty sure that's impossible.
2010-04-15 04:37:00

Author:
Sehven
Posts: 2188


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.