playMaker

Author Topic: How to generate the stairs to climb on Playmaker[SLOVED]  (Read 2343 times)

playmakertester

  • Full Member
  • ***
  • Posts: 211
How to generate the stairs to climb on Playmaker[SLOVED]
« on: September 17, 2020, 02:12:34 AM »
Hi,

I am trying to make a copy of this app.
When I tap on it, the player climbs up and a staircase is generated, but I have no idea how to implement this.
If you have any good implementation ideas, please let me know.

https://apps.apple.com/jp/app/id1531006893?ign-mpt=uo%3D4
« Last Edit: September 18, 2020, 02:12:11 PM by playmakertester »

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7615
    • jinxtergames
Re: How to generate the stairs to climb on Playmaker
« Reply #1 on: September 17, 2020, 03:55:31 AM »
Hi.
i checked some youtube videos and it looks like when hes placing the stairs it gets a upward velocity or force (velocity would theoretically be better to handle)

playmakertester

  • Full Member
  • ***
  • Posts: 211
Re: How to generate the stairs to climb on Playmaker
« Reply #2 on: September 17, 2020, 02:31:28 PM »
Thanks! Let me try!

playmakertester

  • Full Member
  • ***
  • Posts: 211
Re: How to generate the stairs to climb on Playmaker
« Reply #3 on: September 17, 2020, 03:08:17 PM »
Yes, sir!

It mostly worked.
The next step is to limit the number of scaffolding to the number of blocks you pick up. If you have any good ideas, I'd appreciate it if you could let me know.


djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7615
    • jinxtergames
Re: How to generate the stairs to climb on Playmaker
« Reply #4 on: September 17, 2020, 03:56:01 PM »
Hi.
Int add (or Fsm Int Add) on pickup
and int subtract on placing, but before you place each one you do a int compare.
if 0 stop 'up velocity' and 'placing blocks'.


rizwanash

  • Junior Playmaker
  • **
  • Posts: 61
Re: How to generate the stairs to climb on Playmaker
« Reply #5 on: September 17, 2020, 08:28:16 PM »
I would also like to know about it a little more detailed. Thanks

playmakertester

  • Full Member
  • ***
  • Posts: 211
Re: How to generate the stairs to climb on Playmaker
« Reply #6 on: September 18, 2020, 12:37:50 AM »
Hi djaydino,

It worked!
Thanks for the idea.

Next, I need to reduce the number of blocks I have one by one after building the scaffolding, but I can't quite come up with how to control it.

If you have any good ideas, I would appreciate it.

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7615
    • jinxtergames
Re: How to generate the stairs to climb on Playmaker
« Reply #7 on: September 18, 2020, 02:30:23 AM »
Hi.
Probably with a preset array.

Pre make the maximum blocks allowed or possible (you can always add more later)

As an array starts @ 0 i would suggest to set the plate the player is holding on item 0 (on the array list)

Now when adding, 1st do Int Add, then use the result on a Array Get (on the index)
store the game object.
Then enable the stored game object (block on that index)

When Subtracting, first do Array Get (current count on the index)
store the game object and disable the game object.
Then do Int Subtract.

playmakertester

  • Full Member
  • ***
  • Posts: 211
Re: How to generate the stairs to climb on Playmaker
« Reply #8 on: September 18, 2020, 05:17:34 AM »
Thank you!

I understood that you stack the maximum number of blocks that can be stacked and put them in an array, and after making them all inactive, you can make them active or inactive according to the number of blocks you picked up, is that correct?
« Last Edit: September 18, 2020, 05:39:42 AM by playmakertester »

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7615
    • jinxtergames
Re: How to generate the stairs to climb on Playmaker
« Reply #9 on: September 18, 2020, 05:37:52 AM »
hi
You are already doing the Int Add/Subtract from my previous post.

that's the same one, but you need to add the array stuff there as well.

playmakertester

  • Full Member
  • ***
  • Posts: 211
Re: How to generate the stairs to climb on Playmaker
« Reply #10 on: September 18, 2020, 05:49:17 AM »
Thank you for that!

I understood that you stack the maximum number of blocks that can be stacked and put them in an array, and after making them all inactive, you can make them active or inactive according to the number of blocks you picked up, is that correct?

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7615
    • jinxtergames
Re: How to generate the stairs to climb on Playmaker
« Reply #11 on: September 18, 2020, 09:50:33 AM »
Hi.
Yes.

@ start if you want player to start with a certain amount you can use a 'Iterate' (Ecosystem) action.

playmakertester

  • Full Member
  • ***
  • Posts: 211
Re: How to generate the stairs to climb on Playmaker
« Reply #12 on: September 18, 2020, 12:43:03 PM »
Great!
Thanks for advice, let me try!

playmakertester

  • Full Member
  • ***
  • Posts: 211
Re: How to generate the stairs to climb on Playmaker
« Reply #13 on: September 18, 2020, 01:06:17 PM »
I've assembled what I'm imagining in the FSM as a test.
When I ran it, the number of int's increased, but the FSM was unable to create a cost-active block once, and the FSM was responsible for Disable. I'd appreciate any advice on how to fix this.


djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7615
    • jinxtergames
Re: How to generate the stairs to climb on Playmaker
« Reply #14 on: September 18, 2020, 02:03:54 PM »
Hi.
This should give a infinite loop error.

Also you do not need to do a send event to finish.

You should turn of every frame on array get.


on state 2 you have Reset on exit enabled so if it goes to another state the object is turned off again.