tgeorgemihai's Forum Posts

  • How do I make the 8-Direction behavior slide against walls ?

    I've found R0J0hound 's example (event_motion2.capx), and works great for what I need (slide on 45° objects), but I would like to keep the 8-Direction behavior for the acceleration and deceleration.

    How can I implement the following mechanics in the game:

    I've tried different ways with collision points but no success so far ... Can someone help me ?

  • I've added animations in the first post

  • Hello, I am using the "platform" behavior in the following game:

    https://dl.dropboxusercontent.com/u/187 ... index.html

    Sorry, but I can't share the .capx file since my engine is almost complete. The [player] has "platform" behavior, the moving blocks have 2 "sine" behaviors (horizontal and vertical), and the brown block is "solid", there is no extra events/code involved.

    I've encountered the following issues when the [player] is above a moving platform and collides with a [solid] object.

    1) In the layout "case1" when the object [player] stays on the moving [block] and is colliding with the solid [ground] the following happens:

    • on collision with the right solid [ground] -> the [player] is moved 1-2 pixels down
    • on collision with the left solid [ground] -> the [player] is moved 1-2 pixels up

    2) The layout "case2" is similar to "case1", but the [block] is moving on diagonal and is moved (wrong placed) away when colliding with solid [ground]

    3) In the layout "case3". How I can make the [player] to move/stay on the platform that is moving up (above the one that the [player] is standing)

    What can I do to fix these issues ?

  • This should help:

    https://www.scirra.com/tutorials/73/sup ... reen-sizes

    https://www.scirra.com/tutorials/1126/m ... le-devices

    Good luck <img src="{SMILIES_PATH}/icon_e_wink.gif" alt=";)" title="Wink">

  • My structure is the following:

    1 Sprite for the player (invisible, used only for collision) + 1 Sprite for the player's animations

    (since the player will have a lot of sprites + skins I will use a different sprite from the other objects)

    1 Sprite for the objects in the game and for enemies (invisible, used only for collision) + 1 Sprite for animations

    1 Sprite for the level's layout

    1 Sprite for the onscreen buttons/gamepad

    1 Sprite for HUD and other elements

    1 Sprite for the elements in the Main Menu

    ...etc

    While I still use several sprites for the animations, I grouped them and pick them using a variable named "ID".

    Just to make sure, draw calls are made every tick, not just only when a sprite changes frame/animation ?

  • rexrainbow

    Based on performance, which method would be better ?

  • jayderyu

    From what I understand, draw calls are made only for visible objects ... So I can make the logic of my game using more invisible objects and use only 1 sprite with all the animations for the visuals.

    Can you explain me more about "management of layering" ... How can I measure the draw calls to be sure I am in the "safe zone" ?

    Also can you answer me my other 2 questions:

    Creating and destroying objects (one at a time) can create junk memory or some slowness ?

    Creating the level object by object at the start of the layout from a .json file will have an impact over the performance ?

    Here is a very alpha version of the game: http://tinyurl.com/blocks191

    Thanks <img src="{SMILIES_PATH}/icon_e_smile.gif" alt=":)" title="Smile">

  • Anyone ?

  • From what I know, Google Play is available only on Android, like how Game Center is available only on iOS.

  • Which method is better to use ?

    • one single sprite with different animations and all the behaviors (activated only the needed ones)
    • multiple sprites (each with only one animation) and the behaviors needed

    In other words:

    Sprite 1 (animation 1 out of 4 // 1 behavior activated // 3 behaviors deactivated)

    Sprite 1 (animation 2 out of 4 // 2 behaviors activated // 2 behaviors deactivated)

    Sprite 1 (animation 3 out of 4 // 3 behaviors activated // 1 behavior deactivated)

    Sprite 1 (animation 4 out of 4 // 4 behaviors activated // 0 behaviors deactivated)

    VS

    Sprite 1 (1 animation // 1 behavior (activated))

    Sprite 2 (1 animation // 2 behaviors (all activated))

    Sprite 3 (1 animation // 3 behaviors (all activated))

    Sprite 4 (1 animation // 4 behaviors (all activated))

    The game will be for mobiles, so I want to squeeze all the performance I can get (and yeah, I know about https://www.scirra.com/blog/83/optimisa ... -your-time )

    I'm asking this because I noticed that the animations of a single object are exported in one image, while animations for different objects are exported in multiple image files.

    Also, I have another 2 small questions:

    Creating and destroying objects (one at a time) can create junk memory or some slowness ?

    Creating the level object by object at the start of the layout from a .json file will have an impact over the performance ?

  • > "On Jump" is triggered only in the first frame when the player starts to jump

    > "Is Jumping" is triggered every frame while the player is jumping

    >

    Then would "is jumping - trigger once" be the same as "on Jump"?

    Yes

  • "On Jump" is triggered only in the first frame when the player starts to jump

    "Is Jumping" is triggered every frame while the player is jumping

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You do not have permission to view this post

  • You do not have permission to view this post

  • You do not have permission to view this post