Pandy's Recent Forum Activity

  • What does your debug read in terms of collision count. I'm sure you can make the game without the need for collision checks. Try using the overlapping event and disable collisions for everything. The particles object is known to reduce fps count. Test test test in debug.

    Honestly it's easier to read an event sheet from a capx file. You can pm the capx if you want, i have some free time atm

  • Aphrodite

    Ah thanks a lot, i didn't think about looking at project settings, i just mucked about project properties and thought the option wasn't there. Thanks again.

  • Ok my games got 3 layouts and one of them is a splash screen and as with splash screens i want it to be the first layout shown on mobile. After i compiled my project with Ludei cloud compile service and previewed on my phone, the game starts of with Ludei's splash screen and then goes to my game layout, completely skipping my splash screen.

    How do i make sure my splash screen is the first layout of my game when exported to cocoonjs and previewed on my phone?. I did create my splash screen layout last, not sure if that has anything to do wit it.

    Anyone?.

  • Using events that disable the drag and drop behavior of the object, stops the object. But it'll also make it immovable afterwards. So you have to add events that will re-enable the drag and drop again.

    Not sure if this will work but try this anyways.

    Make an event where the conditions are

    -Gold bar is above the brick bar(that is gold.Y is less than brick.Y as Y decreases as you go up)

    -Brick is overlapping gold(brick comes in contact with gold, similar to collision)

    Make an action where it disables brick drag and drop.

    Now this will stop the brick in it's tracks but you'll notice you cant move it anymore.

    Now this might only work if you have preview over lan to your phone cause you'll have to use the touch objects accelerometer option. By seeing if you swipe up or down you'll get positive or negative values for the accelerometer value.

    So say if you swipe up you get a negative Y accelerometer value (i'm not sure if it's negative or posotive, you'll have to find it out) So what you can do is add the condition(to the one i already mentioned) 'touch Y accelerometer value is less than 0 i.e negative. So now if it works it'll still disable movement if you swipe up and the gold is above brick

    Now to reenable movement , you make another action where conditions are

    -Gold above brick or Gold is not right below brick

    -Brick is overlapping gold ( if it is already overlapping )

    -touch Y accelerometer is greater than zero i.e positive

    And the event is, enable drag and drop for brick

    So now if this method actually works, when you swipe down and the gold bar is not below the brick, it should re-enable movement.

    Touch accelerometer does not work on desktop. So i'm not sure if this will work at all. Sorry

    Obviously putting Gold above brick conditions is not the only one, if the gold is to the far right and the brick is to the far left , it'll still disable movement even tho gold is not right above brick, so you have to add other conditions like comparing distance between the two.

    Please look around the tutorials, search for keywords, cause there will definitely be a more simpler and working answer.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hmm mind uploading a capx?. Checked the debug to see if the objects are pinned while running the game?.

  • Did you try using the pin behavior. Pin object1 to object2 , position and angle.

  • Thanks for the help guys,

    Aleq I mostly have a ball bat collision thing happening, i've got the bat to a basic rectangle, tho i want the ball's physics to be exact, so i guess i need the balls's polygon to be as it is with it's multiple points

    nimos100 I tried out replacing my on collision events with overlapping and loops such as your example, tho it's not triggering the variables that used to trigger on collision events, i'll try it out again later and get back.

    Thanks again.

  • At first i had about 45 sprites, then i transferred some sprites as an animation frame to another sprite and deleted them, that brought it down to about 35, then i did the create when needed and delete otherwise stuff and that made it come down to 29 min and 31 max sprites at any given time.

    I use about 12 physics based objects, and i guess that takes up most of the resources. Imagine a ball(physics for bounce, twist etc) popping into the screen , i have setup parameters for the ball to disable and enable physics collisions at certain places in the layout. When the collisions get enabled, the collision check count shoots up, so i was wondering if reducing the number of objects (that are off screen) will reduce the collision count. Thing is the collision check count are extremely varied and i can't tell if it helped at all during debugging.

    I get about 60 fps on mobile but it reduces slightly when the collision checks happen, i was wondering if creating objects would take up more resources for a mobile device.

  • Hey all,

    I was wondering if it is better to destroy objects that are not needed temporarily and spawn them when needed, or better to move them away from screen?

    I was thinking of reducing the object count at any given time during game play and was wondering if it helps to keep it at a minimum or will it not make a difference. Will the device end up using more resources to create objects than rendering them off screen?.

  • Search C2 forums for litetween , its a behavior which might help you in what you want to achieve.

  • Hey all,

    I've got the new cocoonjs plugin in C2, but i don't really know how to test the features, i get an error when i try to run the demp cocoonjs capx on preview over lan on my android phone.Tho i see how it's done, i don't know how to test it on my project.

    Should i test only on the apk files i get from cocoonjs after i exported the project to them?, should the app be on the google play market?, or should it work on normal preview over lan without the need to export the project?.

    Do i need to add other objects such as browser, intel XDK or anything else for it to work?.

    Do i need C2's own Facebook object and IAP object?, since cocoonjs already has options for these do i need the C2 objects as well for fb or IAP to work?.

  • You can put all your physics objects in a 'family', name it Allphysics for example, then you can add events where you disable physics collision of object1 with Allphysics, object2 with Allphysics,... and so on.

    You might try and an action saying disable physics collision of Allphysics with Allphysics, but it didn't work for me that way, you can still try tho.

    But since you only got 12 objects , it shouldn't be a problem to write 12 actions.

Pandy's avatar

Pandy

Member since 1 Mar, 2014

Twitter
Pandy has 1 followers

Trophy Case

  • 10-Year Club
  • Email Verified

Progress

11/44
How to earn trophies