Navigation

    CreatiCode Scratch Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • CreatiCode

    Position bugs near the edge on a larger box than normal

    Feedback
    3
    4
    366
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • 白刃の亡霊
      白刃の亡霊 Best Forum Helpers last edited by 白刃の亡霊

      b4ad4bea-3aaa-4cd4-9b02-b4b523166369-image.png

      It also happens like this:

      37c2dc7c-575b-4ce7-9c41-63624748ad4b-image.png
      (The smaller red box is supposed to go on top of the zombie (bot))

      Can you explain why this happens?

      Ghost of the White Blade

      Tyller_ 1 Reply Last reply Reply Quote 0
      • Tyller_
        Tyller_ Best Forum Helpers @白刃の亡霊 last edited by

        @011830-0a42ef84 idk what this exact issue is, but an issue to note with doing viewport stuff is when you’re near the edge the direction stuff is gong to stay relative to teh center of the screen (even if you do offset stuff, the viewport x and viewport y blocks report semi arbitrarily relative values, put simply they put values that are randomly but consistently offset from the actual x y of the viewport, divided/multiplied relative)

        <div component="post/signature" data-uid="255" class="post-signature">Check out my chat room project so you ppl can not use forums as chat rooms! https://play.creaticode.com/projects/66f2e1dcd1be43d82b886fbd?version=1 <p dir="auto">
        </div>

        白刃の亡霊 1 Reply Last reply Reply Quote 0
        • 白刃の亡霊
          白刃の亡霊 Best Forum Helpers @Tyller_ last edited by

          @tyller_ Is there a way to fix this?

          Ghost of the White Blade

          info-creaticode 1 Reply Last reply Reply Quote 0
          • info-creaticode
            CreatiCode @白刃の亡霊 last edited by

            @011830-0a42ef84

            The issue might be that the current code is highly “inefficient”. It is repeatedly erasing the bar and redrawing it, even if the health has not changed. Usually, you only need to redraw it when the health has changed.

            1 Reply Last reply Reply Quote 0
            • First post
              Last post