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

    bitter-family-72722

    05/22/2019, 7:07 PM
    yeah
  • b

    bright-gpu-74537

    05/22/2019, 7:07 PM
    cool
  • b

    bright-gpu-74537

    05/22/2019, 7:51 PM
    ok, so flixel question... just trying to understand some things
  • b

    bright-gpu-74537

    05/22/2019, 7:53 PM
    why does this happen with flixel group
  • b

    bright-gpu-74537

    05/22/2019, 7:53 PM
    but with flixel sprite its "all good"
  • b

    bright-gpu-74537

    05/22/2019, 7:53 PM
    Copy code
    haxe
            var surface = new FlxSprite();
            surface.makeGraphic(20, 20, FlxColor.YELLOW, true);
            
            var group = new FlxSpriteGroup();
            group.add(surface);
            
            return group;
  • b

    bright-gpu-74537

    05/22/2019, 7:54 PM
    if i return just the surface there, everything works as expected
  • b

    bright-gpu-74537

    05/22/2019, 7:55 PM
    also, whats the use of FlxSpriteGroup? Is there magic happening? I mean, ComponentImpl in haxeui-flixel is FlxSpriteGroup... that contains a FlxSrpite as the surface, i think its a group because it also has the ability to display text and image (ie, buttons, labels, etc)
  • b

    bright-gpu-74537

    05/22/2019, 7:56 PM
    however, if everything is screen coords whats the use in that? I mean, why not:
  • b

    bright-gpu-74537

    05/22/2019, 7:57 PM
    Copy code
    haxe
    ComponentImpl extends FlxSprite {
        var _text:Text;
        var _image:Image;
    
        handlePosition(x, y) {
            _text.x = x;
            _text.y = y;
        }
    }
  • b

    bitter-family-72722

    05/22/2019, 8:00 PM
    I think @brave-kangaroo-30399 said he'd basically need to reimplement FlxSpriteGroup stuff? not sure what exactly haxeui needs / expects
  • b

    brave-kangaroo-30399

    05/22/2019, 8:12 PM
    The group is out of convenience, and the sprite group for super convenience since positioning is already dealt with
  • b

    brave-kangaroo-30399

    05/22/2019, 8:13 PM
    Realistically yeah it could just be a flat structure per component
  • b

    bright-gpu-74537

    05/22/2019, 8:13 PM
    fair enough... with the collision sample, if you replace the create with a FlxSpriteGroup (instead of FlxSprite)... it behaves, strange
  • b

    brave-kangaroo-30399

    05/22/2019, 8:13 PM
    There are children involved but I’d have to think about that for a sec
  • b

    bright-gpu-74537

    05/22/2019, 8:13 PM
    no haxeui, just flixel stuff
  • b

    brave-kangaroo-30399

    05/22/2019, 8:14 PM
    Oh
  • b

    brave-kangaroo-30399

    05/22/2019, 8:14 PM
    It was to have something extremely similar to flash.display.Sprite
  • b

    brave-kangaroo-30399

    05/22/2019, 8:15 PM
    As opposed to a more kha way
  • b

    brave-kangaroo-30399

    05/22/2019, 8:15 PM
    Which is why Jens said it was kind of a hack class
  • b

    brave-kangaroo-30399

    05/22/2019, 8:16 PM
    That class is on the list of big things we want to change, but... there’s a lot on that list
  • b

    bright-gpu-74537

    05/22/2019, 8:18 PM
    just a mess around at the moment, but seems like its working more "correct"
  • b

    bright-gpu-74537

    05/22/2019, 8:19 PM
    just hacking things about, destorying code to understand really
  • b

    bright-gpu-74537

    05/22/2019, 8:19 PM
    main thing that seemed to be a big improvement is:
  • b

    bright-gpu-74537

    05/22/2019, 8:19 PM
    typedef ComponentSurface = flixel.FlxSprite;
  • b

    bright-gpu-74537

    05/22/2019, 8:19 PM
    ie, not the sprite group
  • b

    brave-kangaroo-30399

    05/22/2019, 8:20 PM
    Oh yeah that doesn’t need to be a sprite group
  • b

    brave-kangaroo-30399

    05/22/2019, 8:20 PM
    I haven’t gone through all your changes
  • b

    bright-gpu-74537

    05/22/2019, 8:21 PM
    well, that is just for extends
  • b

    bright-gpu-74537

    05/22/2019, 8:21 PM
    basically its
    Component extends ComponenentImpl extends BlahBlah extends ComponentSurface
1...353637...1687Latest