1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Bug GUI problems

Discussion in 'Developer Support' started by bia10, Nov 19, 2020.

  1. bia10

    Joined:
    Feb 24, 2020
    Messages:
    33
    Likes Received:
    4
    Constantly i experience two problems:

    1. When resizing the runmate window while in developer mode i get this weird stuff:
    Code (Text):
    1. java.lang.OutOfMemoryError
    2. java.lang.OutOfMemoryError
    3.     at sun.misc.Unsafe.allocateMemory(Native Method)
    4.     at java.nio.DirectByteBuffer.<init>(Unknown Source)
    5.     at java.nio.ByteBuffer.allocateDirect(Unknown Source)
    6.     at com.sun.prism.impl.BufferUtil.newByteBuffer(BufferUtil.java:90)
    7.     at com.sun.prism.impl.BufferUtil.newIntBuffer(BufferUtil.java:121)
    8.     at com.sun.prism.impl.QueuedPixelSource.getUnusedPixels(QueuedPixelSource.java:153)
    9.     at com.sun.javafx.tk.quantum.UploadingPainter.run(UploadingPainter.java:147)
    10.     at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
    11.     at java.util.concurrent.FutureTask.runAndReset(Unknown Source)
    12.     at com.sun.javafx.tk.RenderJob.run(RenderJob.java:58)
    13.     at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    14.     at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    15.     at com.sun.javafx.tk.quantum.QuantumRenderer$PipelineRunnable.run(QuantumRenderer.java:125)
    16.     at java.lang.Thread.run(Unknown Source)
    this occurs when my system has about 8Gb of ram left.

    2. Why does it happen that bots GUI showing statistics(exp/hr etc...) gets often polluted with random data/negative values, this happens often with many different bots its not problem of one bot per se.
     
  2. CuppaJava

    CuppaJava cuppa.drink(java);

    Joined:
    Mar 13, 2018
    Messages:
    6,113
    Likes Received:
    1,371
    I'm not sure about the error you're seeing but,

    This can be for a few different reasons. There's not a standard way to track this type of stuff in a bot, so a lot of methods people use are just kinda flawed and prone to breaking. Also a lot of bots just haven't been updated in a long time, so while the bot works fine which is why the bot is still up, the gui might be buggy.
     
  3. bia10

    Joined:
    Feb 24, 2020
    Messages:
    33
    Likes Received:
    4
    yeah that doesn't say much, what are the technical details surround this problem?

    lets image we have something like:
    Code (Text):
    1.    
    2. public void onExperienceGained(SkillEvent event) {
    3.         if (event.getSkill() == Skill.STRENGTH){
    4.             GUIcontroller.strengthXP = Skill.STRENGTH.getExperienceAsPercent();
    5.             GUIcontroller.strengthXPgained = GUIcontroller.strengthXPgained + event.getChange();
    6.  
    7.             Platform.runLater(() -> GUIcontroller.strengthBar.setProgress(GUIcontroller.strengthXP/100.0));
    8.             Platform.runLater(() -> GUIcontroller.strengthPercent.setText(GUIcontroller.strengthXP + "%"));
    9.         }
    10.  
    so how does the variable GUIcontroller.strengthXPgained gets polluted with random data so easily? Is this some kind of thread separation problem or wtf is going on here? Sometimes it happens on initialization otherwise it just happens randomly.

    I don't know java even less so javaFX so just asking as its quite annoting.
     

Share This Page

Loading...