dop2000's Forum Posts

  • A common practice is to put all buttons and controls on "UI" or "HUD" layer, set parallax to (0,0) and scale rate also to 0.

    This way it will not scroll or scale and all buttons will stay in the same place on the screen.

    If this isn't working for you, you must be doing something wrong. Please share your capx file.

  • Awesome, thank you!

  • Javanie Thank you so much for the detailed answer!

    Do you know how long can the video stay preloaded?

    For example, if I preload the video at the beginning of level 1, and player decides to watch it only at level 20 (one hour later). Will it work, or does it get expired after some time and I need to preload again?

  • You do not have permission to view this post

  • Mayfly Did you set "Bullet=yes" in physics properties for balls?

    Well, you can "cheat" and adjust the ball trajectory after the collision. Before the shot save reflection angle in a variable. When the two balls collide, adjust ball2 velocity, making it move at previously calculated angle.

  • Try this:

    dropbox.com/s/18y7yfqblepwamc/pac-disk2.c3p

    It works much better in my tests.

    I would also suggest improving controls, making them analogue. Instead of "simulate control" action, use "Set vector" actions, applying more speed if the phone is tilted more.

    Physics also should work quite well, check out this demo I made some time ago:

    dropbox.com/s/02a1f7dhyeklnlw/BounceBall_2Examples.capx

  • Many events in Construct pick instances.

    For example, "Icon is visible" event will pick all instances that are visible.

    Or "On clicked icon" will pick one clicked icon instance. Everywhere inside this event "icon" will refer to that one picked instance.

    If you want to pick another instance or instances in the same event, and work with both picked scopes independently, use the trick with a family:

    Pick Icon
     Pick IconFamily 
    	.... do something with icon instances
    	.... do something with IconFamily instances
    
  • From the documentation:

    You can leave it at 0 if you don't need it.

  • You can use a family to pick another instance of the same object in one event. Add icon sprite to a family and you can do this:

    Pick Icon
     Pick IconFamily where IconFamily.IID=(Icon.IID-1)
    	Set Icon scale to 1.2
    	Set IconFamily scale to 0.8
    

    Picking by IID will only work correctly if you created icons in the correct order. It may be easier to use an instance variable, e.g. "Pick IconFamily where IconFamily.Day=(Icon.Day-1)"

  • Sure.

  • This is either a bug, or you are doing something wrong. Please post your code or the project file.

  • When players die in my game, I want to give them an option to watch a rewarded video and continue playing. What is the correct way to do this?

    Do I need to preload the rewarded video in advance? If yes, when is the best time to preload - at the moment the player dies, or earlier? Maybe even at the beginning of the level?

    If I choose to always preload rewarded videos on every level, but my players rarely agree to watch them - can it cause problems with AdMob or other ad networks?

    If I don't preload them, will there be a long delay before the video starts playing?

  • This is strange.. Press F12 in preview and see if there are any errors in browser Console log.

    If this doesn't help, can you post your C3 code or project file?

  • Are you sure it doesn't return any data? Check the contents of hunt_return in Debug Mode, or output AJAX.LastData to browser console (use Browser -> Log action).

    You can also open php script manually from the browser address bar to make sure it echo'es the data correctly.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads