Box picking and placing

0 favourites
  • 13 posts
From the Asset Store
Over 2700 files with all the colour combinations from a 15 colours palette!
  • Hi.

    I've managed to make the player pick or drop boxes but I can't make it place the box in the energy plug.

    I've tried a couple of ways to achieve this but with no success. This is what I have so far :

    https://www.dropbox.com/s/wor81hgzx84rr ... .capx?dl=0

  • You have to disable the Plattform-Behavior or at least set the gravity to 0 in event 94 when the EnergyBox is put in the EnergyPlug . Then it should work.

  • Hmm, I tried this but seems that this is not the issue ... or maybe I have to add some events somewhere.

    Disabling platform behavior helps a bit , yes.

  • What effect do you want to achieve? After disabling the platform-behavior the box snaps to imagepoint1 and the sin-behavior started. Isn't that what you want?

  • Yes. This is what I want but it doesn't work.

    https://www.dropbox.com/s/jah9mw7abp3hg ... .capx?dl=0

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Yes. This is what I want but it doesn't work.

    https://www.dropbox.com/s/jah9mw7abp3hg ... .capx?dl=0

    anty21ro is it this what are you trying to do?

    Capx: https://www.dropbox.com/s/l7e4j82dbi7j0ay/BoxEnergyPick%26Drop.capx?dl=0

  • Hi tarek2 and thanks !

    Yes , something like this, but it still not working right .

    I mean, If I take the EnergyBox from the EnemyPlug, I can't put it back there again, and I don't know why is vibrating

  • Hi tarek2 and thanks !

    Yes , something like this, but it still not working right .

    I mean, If I take the EnergyBox from the EnemyPlug, I can't put it back there again, and I don't know why is vibrating

    I see, to be honest, I didn't have time I was just curious to see what was the problem when I saw all the mess I got Pulled in and just did a quick Fix, didn't check 100% if it was working everything ok but I fixed it for you now,

    Still, you can do it a lot better if you take the time and think the logic and change things lol

    https://www.dropbox.com/s/w0ikremle241b8d/BoxEnergyPick%26Drop2.capx?dl=0

  • Thanks a lot tarek2 for taking your time to do this for me . It works fine. I am going to look more carefully to the event sheet so I can better understand what you done there

  • Thanks a lot tarek2 for taking your time to do this for me . It works fine. I am going to look more carefully to the event sheet so I can better understand what you done there

    Cool, your Welcome sir, Glad you fixed

    Out of curiosity why you have the controllers all of then working by (On released) and not by (On Clicked)

    Example

    -On E Pressed

    -On (Mouse) Left button Pressed

    -Etc........

    Did you realize that if the player is overlapping any "EnergyBoxPickable" and presses the button but the Player keeps moving without release the button it will not Pickup up the box if he is not overlapping anymore when released

    But if you use "button Pressed" it will Pick up or Leave boxes straight away, this is just an observation it's your Game and you can do anything you wish of course

  • Yes, you are right, is better like that . I've changed the event to "on pressed".

    I remember that a long time ago I used "On Pressed" for several times and it didn't worked right for me in that situation and after I changed to "On released", than it had. So I guess that's why I avoided using it since then .

  • Yes, you are right, is better like that . I've changed the event to "on pressed".

    I remember that a long time ago I used "On Pressed" for several times and it didn't worked right for me in that situation and after I changed to "On released", than it had. So I guess that's why I avoided using it since then .

    lol I understand now

    Important Note: I forgot to Remove the Boolean "PlugTheBox" from the object (EnergyBoxPickable) as a result you have one more action on Event 90 referencing to that Boolean that is not needed, you can delete the Boolean and automatically the Action from event 90 it will be deleted swell

    Good luck with the Game

  • Thank you !

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)