dop2000's Forum Posts

  • No, I'm sure the problem is in your code. Browser Log can help to find which events are triggering and which not, and why are they not triggered.

  • Well, I don't know why browser event doesn't work, I suggest you log a bug report.

    I would test on several devices and if they all show ConnectionType="none", use this method.

  • Well, that's your problem. Try to find why none of the conditions are triggered - put Browser Log Player.angle in parent event.

  • Try this - create a big Text object and On Network Change put:

    Text set text PlatformInfo.ConnectionEffectiveType & ", " & PlatformInfo.ConnectionRTT & ", " & PlatformInfo.ConnectionType

    See what values do you get. On my phone when I disable wifi and data, connectionType shows "none" and RTT=0, but you need to test.

  • Add debug output to your events, for example in event 40 add Browser Log "Not mirrored, frame 0" and so on. If you have other events which change player appearance, add logging there too.

    Run the game, open browser console (F12) and see what happens.

  • The behavior doesn't place the sprite correctly when it's disabled. And the floor/walls checks also don't work correctly when it's disabled.

    So if you need Platform behavior to be disabled, then your only real option here is to use Is overlapping and On collision events.

    You can use "On collision with floor" and then move the sprite in a loop 1px up until it stops overlapping the floor. And this will position the sprite correctly on the floor.

  • Try Platform Info object, it has "On network change" events and you can check these expressions:

    PlatformInfo.ConnectionEffectiveType

    PlatformInfo.ConnectionRTT

    PlatformInfo.ConnectionType

    construct.net/en/make-games/manuals/construct-3/plugin-reference/platform-info

  • It's possible to call new functions by string name, see "Function maps" template. In this particular case it's not necessary though.

  • No, you need to use a variable (global or instance). Then do something like this:

    Keyboard "D" is down
    	Add 0.1 to effectVariable
    	Sprite set effect "AdjustHSL" parameter 0 to effectVariable
    

    .

  • Are you doing this with events or with Javascript?

    With events you can use "Object -> Is on layer" condition, but you'll need to repeat this with all objects, or add them to families, for example SpritesFamily, TiledBackgroundsFamily etc.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • The link you posted is SDK reference (for writing plugins). What exactly are you trying to achieve?

  • Why don't you simply use "Is overlapping" or "On collision"?

  • Up: set frame to (Obj.AnimationFrame+1)%Obj.AnimationFrameCount

    Down: set frame to (Obj.AnimationFrameCount+Obj.AnimationFrame-1) %Obj.AnimationFrameCount

  • I can explain why this happens. When Platform behavior is enabled and you control the character only with Platform actions, it prevents it from falling through solids and always keeps it about 0.5px above the floor.

    When you move the character with actions like "Set Y", on some ticks it may move a little further and actually overlap the floor. (even a fraction of a pixel is still considered overlapping)

    "Is on floor" condition moves the character 1px down to check if it will overlap a solid floor. However, if it's already stuck in solid, this condition returns false. That's why it doesn't trigger and your character continues falling down.

    .

    If you need to disable the Platform behavior for some reason, you shouldn't use its conditions to check for floors and walls, use "Sprite Is overlapping" and "Sprite On collisions" instead.