https://linen.dev logo
Join Discord
Powered by
# haxe-ui
  • l

    late-engine-8731

    01/25/2023, 11:15 PM
    Godot's scenegraph is an exclusive club, you need to be invited to access it
  • l

    late-engine-8731

    01/25/2023, 11:16 PM
    Your Haxeui code starts in a node that is added to the tree, so you should be able to inject this node into haxe-ui
  • l

    late-engine-8731

    01/25/2023, 11:16 PM
    and work from there
  • b

    bright-gpu-74537

    01/25/2023, 11:17 PM
    right, so the code starts in a node, and then from there its fine to add subnodes?
  • l

    late-engine-8731

    01/25/2023, 11:18 PM
    sure
  • e

    elegant-twilight-61392

    01/25/2023, 11:18 PM
    yeah, but the thing with haxeui is that it "leaves" the scene tree
  • e

    elegant-twilight-61392

    01/25/2023, 11:19 PM
    so with
    HaxeUIApp
    , unless i give it an instance of a node on the scene tree, it cannot access it, and thus cannot add its nodes to it
  • b

    bright-gpu-74537

    01/25/2023, 11:19 PM
    just ignore haxeuiapp for now... its a helper, and you arent there yet
  • e

    elegant-twilight-61392

    01/25/2023, 11:19 PM
    well i didnt know a better way to explain that
  • b

    bright-gpu-74537

    01/25/2023, 11:20 PM
    so whats wrong with this?
    Copy code
    haxe
    var c = new Component();
    c.width = c.height = 100;
    c.backgroundColor = 0xFF0000;
    c.ready(); // call it manually for now, we can fix this later
    theGodotNodeThisCodeRunsOn.addChildNode(c._myGodotCanvasItem); // <--- i have no idea about any of the calls :)
  • e

    elegant-twilight-61392

    01/25/2023, 11:24 PM
    uhhhhhhhhhhhhhhhh
  • e

    elegant-twilight-61392

    01/25/2023, 11:24 PM
    i mean, i guess its not a haxeui issue
  • l

    late-engine-8731

    01/25/2023, 11:25 PM
    hmm
  • l

    late-engine-8731

    01/25/2023, 11:25 PM
    pass a
    0
    for internal
  • l

    late-engine-8731

    01/25/2023, 11:26 PM
    it didnt process the last arg type correctly
  • l

    late-engine-8731

    01/25/2023, 11:26 PM
    filing an issue
  • e

    elegant-twilight-61392

    01/25/2023, 11:27 PM
    well i guess it works
  • e

    elegant-twilight-61392

    01/25/2023, 11:28 PM
    and it is on the scene tree ofc (the
    @@2
    thing is the component)
  • b

    bright-gpu-74537

    01/25/2023, 11:30 PM
    progress! Just keep it really simple for now, build it up slowly and before you know it godot will explode when haxeui tries to create 100s of items on on the scene graph 😄
  • l

    late-engine-8731

    01/25/2023, 11:30 PM
    it wont xD
  • l

    late-engine-8731

    01/25/2023, 11:30 PM
    and if it does I'd love to hear the number
  • e

    elegant-twilight-61392

    01/26/2023, 1:24 AM
    oh dear
  • m

    melodic-advantage-23638

    01/26/2023, 1:25 AM
    oh dear...
  • e

    elegant-twilight-61392

    01/26/2023, 1:25 AM
    wait
  • e

    elegant-twilight-61392

    01/26/2023, 1:26 AM
    the drawing methods of CanvasItem are only available in its
    _draw
    method, or a method connected to the draw signal
  • e

    elegant-twilight-61392

    01/26/2023, 1:29 AM
    im not sure what to do other than implement a queue for drawing which seems like a very ineffective way to do relatively simple drawing
  • e

    elegant-twilight-61392

    01/26/2023, 1:30 AM
    theres probably a better way that i cant think of though
  • a

    ambitious-knife-25690

    01/26/2023, 1:32 AM
    don't worry about efficiency
  • m

    melodic-advantage-23638

    01/26/2023, 1:32 AM
    Can't you override the draw method and just perform the drawing necessary the
  • a

    ambitious-knife-25690

    01/26/2023, 1:32 AM
    get it working first
1...141214131414...1687Latest