1mrpaul1's Recent Forum Activity

  • I did a super smooth camera follow action

    Optimized the game, disabled all collisions on the level except obstacles near the player

    Decreased usage of the CPU and GPU by 40%

    And it works great

    But, the game is still extremely sensitive

    While there is always full FPS straight 60 fps, if something is working in the background, the motion becomes sluggish again

    I wonder, why it is happening

  • It still is jerky huh?

    To be completely smooth we’d want every frame to have the exact same frame time and no frames skipped. We have some control over that with how much logic and rendering we do per frame, but it can still vary per browser or machine. Btw I wasn’t really noticing much jerky motion with your game.

    It’s probably easier to notice the frame variance when moving things in straight lines with constant speeds.

    Anyways, only other suggestion besides using lerp like that to do an ease out, is you can give the camera velocity and do some math to do a damped spring to move the camera. Tune the two values from 0 to 1.

    Var vx=0

    Compare: dt > 0

    -- add -0.005*(scrollx-player.x)/dt-0.1*vx to vx

    -- set scrollx to scrollx+vx*dt

    thank you for the advice, but it is still not working, the issue is, sudden jumps, fps is stable, CPU stable at 4%, GPU at 9%, but sometimes some lags are happening and make drops in the motion

  • To make the ball motion smooth, just use the bullet behavior or "set x to self.x+1200*dt" instead of the tween every 0.5 seconds.

    Another thing to try is use lerp in a frame independent way.

    set scrollx to lerp(scrollx, ball.x, exp(-200*dt))

    or

    set scrollx to lerp(scrollx, ball.x, 1-0.001^dt)

    tried both options for camera and bullet for ball motion, jerky motion increased Probably an issue here, very fast motion and sharp clean graphics, which make the jerky motion even more noticeable

    btw on mobile, it looks better on full screen, but on the desktop, in iframe, very intermittent. especially when fps drops

  • For example, I did this game ru.y8.com/games/geometry_ball

    The camera motion is very jerky

    I did lerp motion between the current camera pos and animated through tween(expected position) over 0.5 sec, the motion should be smooth, but there are always some jumps in motion, while the game is working on full fps, even on 140 fps

  • Perhaps AI will end up changing the world but I have to say, at the moment, it doesn't seem to be that clever yet.

    AI helped me a lot with construct

    For example here, construct.net/en/forum/construct-3/general-discussion-7/holiday-gift-constructers-184729

    AI helped me to export google sheet tables into construct json string, which is very useful

    Another fresh example, AI helped to fix trail plugin, which did not work with high fps monitors. I just fed plugin code, tell the problem and maybe after a half day had a ready solution, I believe I can make my own plugins this way

    And the example I told already, Claude AI drew me a working scheme in construct 3 events, with whole logic and all formulas, for making on the virtual hexagon grid, it is not easy task for most users, with AI, available for everybody

    But if scirra makes some adaptation, or just tell, what to ask from AI, to make a proper JS code for construct JS block

    As for me, it is always fail, errors on the start of the game, AI doesn't know the difference between usual JS and construct JS, if to learn him, it will be just a superpower

  • It's useful for general scripting questions, but Construct-specific stuff it gets wrong.

    I can't say so, Claude helped me to solve one hard task with motion on the hexagon grid, and even drew a scheme for building the construct events, maybe there were some errors, but overall it helped a lot

    I can say there is a different problem

    For Unity, we can just copy past the AI code and test if it works

    In construct events we have to build blocks, and create many variables manually before we understand, will it work or not

    Also, for some reason AI can't handle Construct 3 JS code, it always works with errors

  • you can teach the AI a little, for example, ask to not use JS things when doing formulas for events. Inside one conversation, the AI will follow the context and give you the right answers

  • You do need to use right types of AI, ChatGPT, copilot, gemeny are useless

    Our models are Claude, and HTML5 code on poe.com

    They knows Construct 3 well, but you still need to ask them right

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Maybe the value is stored as string in the array? You can test this by printing Stats.AsJSON to console log. If the value is shown as "1.3", then it's a string.

    Yes, it is a string, but I'm wonder why I didn't experienced this situation before, in previous years

    Anyhow, I will always use float() now, to avoid this situations

  • Ok, I can use float() to convert this array value into a number, and the calculation becomes right

    but the strange thing, in another block Stats.at(Hardness,1) this value working as expected without float or anything

    as for me, it is not right when this basic things working different in the different places

  • It's not a bug, this is how strings are concatenated. Add round brackets:

    ... & "/" & (25*Stats.at(Hardness,1))

    added, nothing changed

    also, we can't use int in this case, because 1.3 will be rounded to 1, is it always like this? I never had such a problems

  • doing this code

    where Stats.At(Hardness,1) equal to 1.3

    which is shown in the print console

    but the result as you can see is equal to 25 instead of 32.5 which is right value of 25 * 1.3

    is it bug or feature of construct?

1mrpaul1's avatar

1mrpaul1

Member since 21 Feb, 2018

Twitter
1mrpaul1 has 6 followers

Trophy Case

  • 6-Year Club
  • Forum Contributor Made 100 posts in the forums
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • RTFM Read the fabulous manual
  • x3
    Quick Draw First 5 people to up-vote a new Construct 3 release
  • Email Verified

Progress

12/44
How to earn trophies