AnD4D's Recent Forum Activity

  • Sorry, figured I'd tag you into the post

    GameeApp

    Also, I should point out that I'm using Construct 2, not 3.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Sorry if this has already been answered. I tried to look through some of the pages here, but didn't see it answered anywhere.

    Is anyone having any luck uploading a project to the emulator? I have uploaded my game to my website:

    http://emulator.gameeapp.com/

    then pasted the link into the emulator.

    The game then loads, but ends up just showing the following:

    I thought it may have been a plugin that I had used or something, so made a new project with just one sprite and the Gamee plugin and uploaded that.

    I get the same result.

    I do note that the site says "New to Gamee? Check our Dev Portal first" but the provided link just refreshes the page, with the link URL pointing to http://emulator.gameeapp.com/index.html#

    Any ideas?

  • You do not have permission to view this post

  • You do not have permission to view this post

  • You do not have permission to view this post

  • > It's likely I won't be using tilemap anymore, so it won't be as easy as snap. I want to be able to create the walls at runtime, so the layout can be different, and the walls are automatically placed. It'll mean combining either normal sprites or tiled backgrounds with tilemap offset.

    >

    I would still use a Tilemap (or several). You can make them invisible and put sprites over the tiles. Use tilemaps as solid obstacles for other behaviors, for collision detection, pathfinding, LoS etc. You can create different tilemap layouts and load them from JSON string for each ship. Tilemap basically works as an array, so it will make many things easier.

    Tilemap would work quite well, but while trying to do it, I found that corridors require 2 collision polygons, as the square pixel is open on 2 sides, while closed on the other 2.

    Tilemap would allow me to store the positions quickly, but I would then likely have similar issues with doors. If I build it using sprites instead, then store the positions and have the system rebuild it from an array, I can edit the tilemap quickly without issues. Say I suddenly want a different floor colour, or my doors to change. Rather than changing the tilemap, I could just change the frame on the individual sprites. Also, FTL tracks oxygen, so giving each sprite a variable also allows me to make this easier.

  • Why not

    X=int(mouse.x/64)*64

    Y=...

    I usually use int, but didn't think it would matter in this case. Wouldn't it still create an issue when trying to shift the snap position to either the left or right? Say I want to place a 64x64 tile, then surround it with walls, I still ideally want to work with a 64x64 snap, but shifted 32px so that I'm now working on the edges?

  • Just in case anyone stumbles across this, the place on grid code is:

    Create object

    x=round(Mouse.X/64)*64

    y=round(Mouse.Y/64)*64

    This should make it easier to produce a level editor. Manually placing walls and doors.

    *UPDATE*

    Having tested this, the above code is perfect for placing a sprite in the centre of a grid, but it's not superb for placing objects on the edges of the grid. Simply altering the code to:

    (round(Mouse.X/64)*64)-32

    puts the sprites in the correct location, but the mouse cursor is very much to the side of where you expect it to be. Of course, you can change the code so that instead of 64 it reads at 32, but that allows you to place walls in the middle of tiles as well as the edges. Very frustrating.

  • >

    > Now I just need to figure out how to set the destination to a grid, rather than the mouse X & Y. If I recall correctly, it's something like: X % 2) * 32... but I honestly don't remember. Will need to search around again.

    >

    Use TileMap expressions: SnapX, SnapY, PositionToTileX, PositionToTileY, TileToPositionX, TileToPositionY

    It's likely I won't be using tilemap anymore, so it won't be as easy as snap. I want to be able to create the walls at runtime, so the layout can be different, and the walls are automatically placed. It'll mean combining either normal sprites or tiled backgrounds with tilemap offset.

    It'll be tricky. I think I'll be able to save the positions of said items in an array so that multiple ships could be called on demand.

    I like to do things tough at the start so it'll be easier later on.

  • AnD4D

    Even that it sounds like you looking for something very specific and I'm sure that this is not what you want I couldn't resist to try it

    https://www.dropbox.com/s/pgvuvd0ijtwy1tp/SpaceShip%20PathFinder2.capx?dl=0

    To avoid the collisions checks you can use MoveTo >>>On Hit Target >>Pick Nearest selected Tile >> set selected to False and so on

    And on this two Places, I'm not sure if you needed to move on diagonals or to avoid those Grey pictures so I add one Blue square Tile on each to stop the diagonals, you can remove them if you don't need them

    This is With the MoveTo Behaviour

    https://www.dropbox.com/s/ou6o7jppmwk1vua/SpaceShip%20PathFinder%28MoveTo%29%20Behaivor.capx?dl=0

    Wow! Amazingly, I had just finished doing something similar. Mine doesn't use line of sight, nor 'nearest', but rather it will create sprites on the pathfinding node and will move toward the lowest node.

    It's pretty much perfect for what I need.

    Now I just need to figure out how to set the destination to a grid, rather than the mouse X & Y. If I recall correctly, it's something like: X % 2) * 32... but I honestly don't remember. Will need to search around again.

  • Guys, I don't understand - what's wrong with using a tilemap and the default pathfinding (as in the link I posted above)?

    It doesn't require any external plugins or any complex programming. And the character is moving more naturally, not like a robot in square angles. Or you can use pathfinding just to generate path and move the character from node to node with MoveTo or some other method.

    I think if I combine the default pathfinding plugin with Rex's MoveTo plugin, I can use the generated nodes to create the movement I'm looking for. I don't mind the snappy turns.

  • I think the problem I'm having is that my wall needs to be only about 5 pixels across, while the floor tiles need to be approximately 32x32.

    This possible with this plugin, or do all tiles need to be the same size?

AnD4D's avatar

AnD4D

Member since 4 Nov, 2011

Twitter
AnD4D has 3 followers

Connect with AnD4D

Trophy Case

  • 13-Year Club
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Forum Hero Made 1,000 posts in the forums
  • Coach One of your tutorials has over 1,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

20/44
How to earn trophies