https://linen.dev logo
Join Discord
Powered by
# flixel
  • w

    witty-island-52596

    02/20/2023, 10:45 PM
    could you create a tilemap to render this array of ints, and put them on a camera with a shader?
  • w

    witty-island-52596

    02/20/2023, 10:46 PM
    im making a lot of assumptions about your end goal there
  • w

    witty-island-52596

    02/20/2023, 10:46 PM
    because you said minimap
  • b

    busy-librarian-41101

    02/20/2023, 10:47 PM
    so I've got this overworld, looks like this. it's just perlin noise generated with 'planetary systems' generated procedurally throughout
  • w

    witty-island-52596

    02/20/2023, 10:48 PM
    looks neat
  • b

    busy-librarian-41101

    02/20/2023, 10:48 PM
    I want basically a minimap GUI that renders a highly zoomed-out version of this, with little clickable icons for each system that you've visited (for fast travel, info, etc)
  • b

    busy-librarian-41101

    02/20/2023, 10:50 PM
    I'm curious what you mean about a tilemap with a shader - I suppose I kinda see it? Like, you're suggesting inputting the values to the tilemap, then applying a shader to a camera to perform effects like smoothing/etc
  • w

    witty-island-52596

    02/20/2023, 10:51 PM
    yeah basically
  • b

    busy-librarian-41101

    02/20/2023, 10:51 PM
    (and I assume you suggest a seperate flxCamera because applying a shader to a tilemap applies the shader to each individual tile, rather than the tilemap as a whole?)
  • w

    witty-island-52596

    02/20/2023, 10:52 PM
    in my older game I used the world map to generate the minimap, which just used much smaller tiles
  • w

    witty-island-52596

    02/20/2023, 10:52 PM
    I've never tried that, actually, I don't think tilemaps can have shaders
  • w

    witty-island-52596

    02/20/2023, 10:53 PM
    Whether you can use a camera shader on a tilemap obviously depends on the effect you want, but could be doable in circumstances
  • b

    busy-librarian-41101

    02/20/2023, 10:54 PM
    they can, I use a ripple shader for my water tilemaps - but again, it applies it to the base tilesheet sprite, rather than on the entire tilemap object
  • w

    witty-island-52596

    02/20/2023, 10:54 PM
    ah
  • b

    busy-librarian-41101

    02/20/2023, 10:55 PM
    yeah, right now I'm more interested in finding something performant/technically feasible than something wildly aesthetically pleasing - it's not a massive part of the gameplay so it can look a little chunky
  • b

    busy-librarian-41101

    02/20/2023, 10:55 PM
    I will definitely play around with that idea though
  • w

    witty-island-52596

    02/20/2023, 10:55 PM
    tbh I'm not seeing what the shader is for, except maybe some sonar effect
  • w

    witty-island-52596

    02/20/2023, 10:56 PM
    I didn't use a shader in mine, I just had 2 tilemaps, the level recreated, and a fog of war tilemap on top
  • w

    witty-island-52596

    02/20/2023, 10:57 PM
    good luck, tho
  • b

    busy-librarian-41101

    02/20/2023, 10:57 PM
    right - my only thought was some sort of shader-based hq2x smoothing
  • l

    little-intern-64840

    02/20/2023, 11:44 PM
    been having a bit of trouble implementing
    FlxRes
    , nothing seems to happen whatsoever i put this code right before the game child is added
    Copy code
    haxe
    if (returnWidth)
      game.width = FlxRes.getOtherDimension(game.height, returnWidth);
    else
      game.height = FlxRes.getOtherDimension(game.width);
    the
    game
    in question
    Copy code
    haxe
    var game = {
        width: 1280, // Game Width
        height: 720, // Game Height
        initialState: states.menus.TitleState, // The State when the game starts
        framerate: 60, // Default Framerate of the Game
        zoom: -1.0, // Zoom automatically calculates if -1
        skipSplash: true, // Skipping Flixel's Splash Screen
        startFullscreen: false // If the game should start fullscreen
    };
  • s

    square-angle-35096

    02/21/2023, 12:53 AM
    yo i also did that with my flixel template lmao
  • l

    little-intern-64840

    02/21/2023, 12:54 AM
    it's useful
  • l

    little-intern-64840

    02/21/2023, 12:54 AM
    don't have to create so many variables
  • s

    square-angle-35096

    02/21/2023, 12:55 AM
    lol
  • a

    ambitious-knife-25690

    02/21/2023, 1:04 AM
    we don't really support libraries here
  • a

    ambitious-knife-25690

    02/21/2023, 1:05 AM
    but i'd recommend you read the readme
  • a

    ambitious-knife-25690

    02/21/2023, 1:05 AM
    it is super indepth and likely has instructions for how to use it
  • l

    little-intern-64840

    02/21/2023, 1:05 AM
    alr
  • a

    ambitious-knife-25690

    02/21/2023, 1:06 AM
    I have used the flxres code in a non flixel project and it worked fine
1...946294639464...9809Latest