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

Set a piston to immediately start a period?

Archive: 23 posts


So this is really annoying the hell out of me. I'm working on a switch right now and it would work fine if only you could reset the period of a piston.
The situation: I have a button set to on/off, which is attached to a piston. The piston is at it's minimum length. Now when I push the button, I need the piston to IMMEDIATELY stretch out to it's maximum length. But I can't work out how to do that.
The following happens when you make a piston:
- You attach a piston to something, set it's timer, max/min length etc. all in create mode. You exit create mode and unpause. Now the piston does NOT immediately start to go through the period it's set to, but it will need to adjust itself at first.

Example:
Let's say the piston I just made is in this position: ---- (4)
Minimum length: -- (2)
Maximum length: ---------- (10)
Pause: 0.0 sec

What might happen, once unpaused:
1. ---- (pauses for a second)
2. ------ (goes from 4 to 6)
3. -- (goes back to min. length, before max is reached)
4. ---------- (start's to go through it's period)
Just as an example, you probably know what it's like.


Now let's say I created a piston at whatever position with pause set to 0.0 seconds. I used a button set to directional to make the piston go to it's minimum length. Then I hit pause and change the button to on/off.
Min length: -- (2)
Max length: ---------- (10)
Now I unpause. What I need to happen is this:

1. -- (2) I jump onto the button set to on/off
2. ---------- (10) The piston immediately streches out to it's full length without delay.
3. -- (2) It goes back to min length without delay
4. ---------- (10)
5- -- (2)
etc.

But this will never happen, as the piston always adjusts itself like in the previous example. I have not figured out a way to set the period to it's initial position. Directional "reset" does not work. Flipper does not work. I have no idea.
Of course I could go and estimate the initial position and hit pause, but I need it to be very precise, down to 0.1 seconds.
I really need help here D=
2008-12-27 23:38:00

Author:
Shiwayari
Posts: 167


Try dragging the object attatched to the piston to its minimum, usually works for me, just pull it down as far as you can, assuming the piston is straight, it should work
I don't really understand what you are trying to do, can you give a brief, but precise and easy to understand idea of what you're trying to do please?
2008-12-28 00:03:00

Author:
Pinchanzee
Posts: 805


Flipper motion- Out?2008-12-28 00:11:00

Author:
DrunkMiffy
Posts: 2758


Flipper motion- Out?

Yeah, this would make it immediately stretch out.
2008-12-28 00:14:00

Author:
Whalio Cappuccino
Posts: 5250


I think the title should be re-worded.

Flipper motion should work.
2008-12-28 00:17:00

Author:
moleynator
Posts: 2914


Sorry about the title, didn't really know how to sum it up. Oh, just noticed the word order is wrong ..

I think some of you misunderstood, but I didn't really tell what I wanted to do anyway. I have tried "resetting" the piston with flipper motion and then changing the piston back to non-flipper again. This did not work. I think you mean that I just let it be at flipper motion. Well, this does not work for me, as I want the piston to still take time to move.
I don't want to tell exactly what switch I'm making. Describing that would also not be brief and easy to understand xD. If you want to, you can see/get it in my switch level, that I'll update when I'm finished.

What I need for the switch is a piston that streches out a defined amount each time a button is pressed. So no flipper motion. For another reason I need the distance to be very precise, so the time the piston moves also needs to be. Even the slightest bit of the piston adjuting itself will throw off everything.

@Pinchanzee
I was just trying some things ingame when I also had that idea, but somehow I couldn't move the thing it was attached to. I know it worked in my other level though. I'll try again tomorrow.

I've now tried to solve this for 2 hours and have figured out an ugly workaround. I realized the adjustment comes from the synchronization and the synchronization only "disappears" if the same switch stays attached. I'm kind of abusing this, but it made my switch three times bigger and a little bit messy. The precision is acceptable, but not perfect. I won't bother explaining the workaround if noone asks. Need to go sleep now =o.

Anyway, I hope something other than a workaround will solve this problem.
And thanks for the help.
2008-12-28 01:20:00

Author:
Shiwayari
Posts: 167


If this is what your wanting... quote from your first post.
"1. -- (2) I jump onto the button set to on/off
2. ---------- (10) The piston immediately streches out to it's full length without delay.
3. -- (2) It goes back to min length without delay
4. ---------- (10)
5- -- (2) "

All you need is a piston in default mode.
Set a min/max length.
Hook a switch to it in directional mode.
At that time piston will either stay extended or retracted.
If its extended and you want retracted by default, reverse the piston or switch in tweak.
After than tweak length.
No delay.
Set your piston time, which is total travel time, to .01.
Now the piston will go out immediately when switched and back in immediately when released.
Increase that time for slower action.
2008-12-28 01:29:00

Author:
rz22g
Posts: 340


Guess I didn't explain too well. Note the "1. -- (2) I jump onto the button set to on/off". The following is supposed to happen in a certain amount of time while standing on the button. There's positions inbetween 1./2./3./.. just thought I'd explain it with min/max position to show that I don't want the initial delay. With delay I mean the adjustment or any kind of pause. What I want to achieve is this:

1. -- (2) Jump on one-shot button
2. --- (3) Jump on one-shot button again
3. ---- (4) again
4. ----- (5)
etc.

But that's not really the problem as I know how to do that and it works after the piston has adjusted itself to the synchronization. I just want to get rid of that adjustment.
2008-12-28 01:58:00

Author:
Shiwayari
Posts: 167


So you want the piston to slide out 5 notches with a pause between, then jump right back to start immeaditly?

If you set up multiple pistons in a row hoked upto a box inbtween, have min 0.1 and maxes all the same, then have them all with different delays, they'll all go out different but suck back in...
2008-12-28 04:00:00

Author:
lionhart180
Posts: 200


I think I get what you mean, but I don't see how this would solve my problem. Also I do not want pauses inbetween, I just want one piston to stretch out the same bit, each time a one-shot button is pressed. I don't need it to go back at all, though it would be a nice addition, but due to the nature of the switch, it would not make sense.

Please note that I do not want to know a way how to achieve this, I already have it set up. I just want to get rid of the adjustment I described in my first post.

I guess I need to explain the whole thing anyway:


I have set up the following:

|D-M|---|G-K| #1
_ _~~^
|D-M|---|G-K| #2
B1~~^

|D-M| = Dark matter block with Magnetic Switch on it.
|G-K| = Glass block with Magnetic Key on it.
--- = Piston
~~~ = Wire
^ = connection Wire/Piston
B1 = Button set to one-shot.
(_ _ = Forum place holder, spaces don't work)

Pause of Piston #1 and #2: 0.0 Seconds
Invert of Piston #1 and #2: No
Flipper of Piston #1: Off
Flipper of Piston #2: Out (away from mag. switch, to the right in the diagram)

Magnetic Switch #1:
Output: Anything
Invert: No

Magnetic Switch #2:
Output: On/Off
Invert: Yes

How it works:
The one-shot button is pressed.
Piston #2 will flip outwards, activating Magnetic Switch #2. Piston #2 needs some time to go back.
As long as Mag. Switch. #2 is active, Piston #1 will retract.
Piston #2 reaches it's minimum length, deactivating Mag. S. #2. Piston #1 stops.

Let's say I've set it up, so that the button has to be pressed 3 times for Mag.S. #1 to activate. At the beginning Piston #1 is fully streched. Now what happens when the one-shot button is pressed?
Piston #1 does not start to retract immediately, it pauses for a little time, until it starts. That is, because it adjusts itself to the synchronization of the level, even though a wire is attached. So in the end the one shot-button needs to be pressed more than 3 times to activate Mag.S. #1. Thus, I want to get rid of this adjustment.

Now I already created another switch, which does the same, using an emitter. It has disadvantages though, one being the emitter, another being that it's hard to customize. I wanted to make a simple, emitterless version, that's easy to customize. So I do not want to add more pistons, blocks or anything than neccessary.

@lionhart180
Maybe you can see now that your suggestion won't solve the problem. There will just be more pistons, which need to adjusts their synch. .

Again, I'm not looking for advice on how to set up the switch, just how to get rid of the piston synch. .
Thanks for the help so far. I'll go try Pinchanzee's suggestion again now.


Edit:
Uhm, seeing as I just explained the whole setup of my switch, and what it does; I'd like to copyright the idea here =o. If you're going to use the exact same concept, please credit.


Edit2:
Streching out the piston by dragging the block it's attached to also didn't get rid of the synchronization.

I noticed that what I mean with snychronization might cause misunderstandings.. I mean the setting of a piston that has an hourglass with a globe behind it as icon. Directly translated it's synchronization in the german version. Don't know if it's called that in the english version..

I guess the workaround will have to do for now, but I think it will make the switch unshareable.. Can you remove Magnetic Switches from shareable/unshareable community objects and replace them, without deleting the whole object?
2008-12-28 11:28:00

Author:
Shiwayari
Posts: 167


What about if you save the switch as an object.
Place it in another level and then press play.
Now just stand on it a few times or whatever it is that you have to do to get it re adjusted and working at normal speed back and forth. And then when the piston gets to it's minimum press pause and save the object again.
Now if you use this object back in the original level, DOES IT WORK STRAIGHT AWAY????????
Don't know if this will work but I was trying to think of something for you.

I'm guessing just getting it to normal working order in your original level with it in play, messes up other things in your level so that's why you just don't play it and then pause it again in the original level.

Also doesn't the adjustments of speed and pause work when the piston is set to directional. Does it just go straight from one setting to another regardless of the speed ?????
As the piston set to directional seems like the best way to do this.
Especially if you only need it to work once and the piston to stay fully extended???
2008-12-28 13:11:00

Author:
dorien
Posts: 2767


Thank you very much for trying to help me.

Setting the piston to directional does not work, as it would go back inbetween.
Your first suggestion does not work for two reasons:
- Hitting pause when it's fully retracted is kind of estimating where the minimum position is, and as I said this will make the switch unprecise.
- If I go to another level (or even the same level, using directional temporary) and let it fully retract, and then start it again, then it will adjust itself to the synchronization in the current level, meaning it has to pause again.

Example:

I'm in pause mode and have following identical pistons:
#1: ----- (5)
#2: ----- (5)
Now I temporarily attach a directional button to #1 and hit unpause to let it fully retract:
#1: -- (2 min position)
#2: -------- (8 max position)

Hit pause again, and detach the switch from the piston. Both are now not linked to any switch. I hit unpause:

#1: -- (2) It pauses until #2 is in min position, because both are set to Synchronization 0.0 seconds
#2: ------ (6) retracts

#1: -- (2 min pos)
#2: -- (2 min pos)
Now both will start a new period and strech.

#1: -----
#2: -----

So no matter what I do, a piston always adjusts itself to the "time" of the level. The only way to "turn off" the synch. is to let the same on/off switch stay attached all the time, without changing it to directional or anything else. I did use this in my workaround, but I'm not really satisfied with this.

I request an "Ignore Synchronization" Option from MM.
"Reset time of the Level" would also be useful.
2008-12-28 16:19:00

Author:
Shiwayari
Posts: 167


You are trying to make a pusher, Similiar to those used in Meerkat Bounce, Correct?

If so then here it is Short and sweet:

2 problems:
#1. You need to set the switch mode to One Shot (which will cause the flipper to go up and back down once everytime you hit the button)
#2. (i can not remember if there is a Flipper Motion or not), if there is not you can set the full cycle time to 0.1 seconds thus making it go up in 0.05, and back down in 0.05, essentially a flipper motion which is what you need

General tip: If you want to set the height sackboy goes, use the strength settings, and use distance the piston has to go (0-10 will be stronger than 0-5).


Have fun

Cheers!




EDIT: OOOOooohh, you are trying to make the first piston activate another, Correct, please just give use the simple idea

ok so you want to press a button to make #2 work, which will activate a switch, which will make #1 work, QUESTIONS: Are you trying to make #1 activate as in going up, then down once? or do you want it to permanently work?
If so then you are going the longest way i have ever seen. Just attach the switch (Proximity) to #1 and set to one shot, OR put a block of dissolving on top of a block of dark matter, key on dissolve, and key switch on dark matter, set switch to inverse, make the switch (button) that you press dissolve the dissolve material, and your piston will work permanently.



The real problem is that we do not know what you are trying to do, do not go more complex just say it plain and simple, such as "I want to make Piston one push my sackboy in to the air, and i do not know how to do it, can you guys help me" thats it, just tell us wha you want to happen in the end, and give us a scenario you want it in (the part of your level, and what it is to accomplish in that level)


Cheers!
2008-12-28 17:47:00

Author:
RAINFIRE
Posts: 1101


**** this is really not easy to explain. I'm kind of amused with what you guys come up with from my explanations xD.
To say it in the simplest way possible: I want a counter, which counts how many times a Button is pressed. After let's say 5 presses, it should make for example a piston activate. I want this switch to be small, simple and not use any emitter.
However, again, i already know how to do this and that's why I didn't explain it. Another reason is that I just love making those switches and don't really want others to come up with switches for me ^^. All I want now is the synching to be gone.

Regarding the explanation of the switch setup: Piston #1 is the "timer" which let's Piston #2 strech out a bit each time the one-shot button is pressed.
If the counter counts to 5, then Piston #1 is fully streched after 5 presses of the button. The Mag. Switch activates and does something else.


I just finished remaking my Level Shiwa's Devices, which is now called Shiwa's Devices V2. At the end you can see the switch I'm trying to make, it's Counter V2. However, the level is not uploaded yet, as I can't get online right now (403 error?). I'll publish and update my thread in Showcase as soon as I notice I can get back on.

Edit:
Restarted PS3 and got online. Published Level. So you can go look at what the hell I want to make ^^.
2008-12-28 22:02:00

Author:
Shiwayari
Posts: 167


Hmmm... I can't quite wrap my head around everything said in this thread. But let me try and think about some of what's said.

I think you are misunderstanding what the setting of "one shot" on things like buttons are for. The "one shot" setting is basically only used on emitters. If you have a button hooked up to an emitter, with the button set to the default on/off, and step on it, the emitter will just keep spawning stuff.

If you change it to "one shot", then you step on the button and the emitter will emit once. You stay on the button, and it won't refire. You have to physically get off the button and back on again to make a second emitted object.

For things like pistons, "one shot" won't work, the wire will go red and the whole connect will not function. That's because a piston is not an emitter, they work in a different way with middle points rather than absolutes. So you have the on/off setting which will make a piston move while you are on the button to the settings it is set to, which would include having it stop mid movement.

If you change a red button to directional this will make a piston move to it's maximum length, and then if pressed again go to minimum, then maximum, then minimum...

But with a default step on red button, the piston will keep moving while you step on it, going back and forth. The difference is that if you step off it, it won't just stop mid way but instead will move to either the maximum or minimum point before it stops.

As you have said, you need a middle system to make it "count" the number of times a button is pressed. I normally use an emitted key paired to a magnetic switch to do this, which can move a piston which has keys and switches at it's ends to create the counting.

The button the player interracts with is set to "one shot", but it's going through an emitter to do this counting trick. Because of the nature of the red button switch, that being a player can stand on it or just move on and off it, and keep doing so as much as they want in variable ways, there is no simple way to count presses without a middle system. :blush:
2008-12-29 06:25:00

Author:
Elbee23
Posts: 1280


That's not all true, Elbee. One shot switches can be set to pistons. However, they can't be set to the pistons unless the piston has the flipper enabIed. I had to use this effect today in my level, and it can be quite useful.

And to the OP: Are you saying you do know how to do this without emitters? Because I've figured out a way to do it.
2008-12-29 06:46:00

Author:
BassDeluxe
Posts: 984


I was not aware of this. I normally leave flipper to off and just make a short timed piston with a sensor on directional to simulate flipper like movement.

But as you commented in my blog, maybe I've just overlooked the flipper option. I've just never really tried it.
2008-12-29 07:08:00

Author:
Elbee23
Posts: 1280


I too noticed only recently that one shot was possible with flipper motion on. That's why I started to redesign some switches.

And yes, I do know of a way to make a counter without emitters and it already works. I even know of another way than the one I'm talking about here, which would definitely work perfectly precise. The thing is, that one would be quite complex with a lot of logic gates and that would miss the point of not using an emitter. The simplest way I came up with is the one I described some posts ago (in the spoiler tag), but it's not 100% precise, because of the piston adjusting itself to the "level time".

If you go try my level "Shiwa's Devices V2", get the Counter V2, and try it in create mode. Then you will probably see what my problem is.
2008-12-29 11:14:00

Author:
Shiwayari
Posts: 167


what I did (since imho that flipper motion is crappy),
was create something like a permaswitch,
1 piston at bottom,
1 pistom at top.
one float at place material with key.
bottom piston has switch.
make the top piston slowely push the floater down,
and make the bottom one push the floater with key back up in 0,1 second.

another way is to use an emitter:
create a piston, and just when its full lenght let it dissapear and start over again.
if done right, it should be near flawless!
2008-12-30 02:58:00

Author:
Luos_83
Posts: 2136


I already have a different working emitter version, though the one you described might be customizable easier. I don't know why you don't like flipper motion, but it works very well with custom switches. I'm not a fan of making things that have to be tweaked over and over to work perfectly. The setup you described seems a little uncontrollable. But again, I don't see how it would solve the problem, as one piston would still need an on/off Input, thus adjusting itself at the beginning.


Edit:
I'll tell you how I solved the problem for myself, also as an answer to this (https://lbpcentral.lbp-hub.com/index.php?t=p=107608) thread. I'm still looking for a solution that will require no workaround and make the switch shareable though..

The idea: As soon as you attach an on/off switch to a piston/winch/bolt it will be given it's own synchronization. Meaning, it will start to adjust itself to the leveltime the first time you turn the piston to on and then it will always immediately start to move as soon as the on/off switch is activated. This means that you can use the magnetic switch, which is attached to the piston in on/off mode, to reset the piston to it's max/min position.

How to do it: Place a Magnetic Key at the end of the piston and place a Magnetic Switch at a position where it will only activate if the piston is fully streched/retraced (depending on what you need). Adjust the radius precisely! Now connect the Magnetic Switch to the piston, set it to on/off and invert it. The piston will now strech/retract until it activates Magnetic Switch, which will make the piston stop at max/min position. Now hit pause. Take the Magnetic switch which is attached to the piston, uncheck the invert option, and place it where you actually need it. Now the piston will immediately start to move if the Switch is activated, without adjusting itself to the leveltime.
This will make the object unshareable, because Magnetic Switches cannot be relocated on community objects, so I'm still looking for a better solution, if there even is one.
2008-12-30 08:45:00

Author:
Shiwayari
Posts: 167


As far as I have been able to determine, you cannot do away with how game objects synchronize to the "global clock". So a slowly creeping piston just is not doable. But a slowly creeping motor bolt might do it.

Alternatively, self-destructing dissolve blocks could be used to count. Hook up a magnetic switch to the block itself, stack up five duplicates, and have a quick piston push a key in and out of range. Hopefully each one would disappear allowing the others to fall in range. You'd need another key of another color on each block, and a switch with a large enough radius to detect them all. Set to inverted, that switch would then kick on when all the blocks had been dissolved.
2008-12-31 16:11:00

Author:
Trystian
Posts: 59


Now that I think about it, I've set up slow moving pistons as timers and counters but have not had trouble with global time settings. I always build the piston and attach the relevant switch, let it do all it's global sync wobbling out of the way, and THEN build the relevant activation systems around it.

So... I don't see what the problem is on reflection. Why don't you build a piston and then the system after that, so it's not breaking whatever system you are trying to set up when it tries to snap into position, because it's already done all that?

Just a thought... :blush:
2008-12-31 16:16:00

Author:
Elbee23
Posts: 1280


@Trystian
That's a pretty nice idea there, though I don't see why you would need different colors and a big radius. The only bad thing, my counter currently has 20 corners, 2 pistons, 2 magnetic keys and 2 magnetic switches. Using one block and one magnetic switch for each single count would result in a lot of corners and switches, which would eat up the thermometer. I don't want to imagine how much one that counts to 100 eats up. Also, it would get quite big. Thinking about it, in that way, it's similar to my first version of the Counter.

@Elbee23
The problem is not that it "breaks the system". The problem is that I need it to be very precise. And just estimating where the max/min length might be and then hitting pause doesn't turn out too precise.
I could just put a Direction Splitter (See my switch Level, signature) between magnetic switch and piston, then it would work perfectly precise, but that would be 8 corners and one three-way switch more. The problem is not how to make it work, it's how to make it work as simple as possible.
It's not even that important, I just don't see why they didn't include such an obvious option as resetting the sync.
2008-12-31 16:48:00

Author:
Shiwayari
Posts: 167


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.