dop2000's Forum Posts

  • Type this in Google:

    tetris site:construct.net
    
  • If you have multiple sprites for dunes, add them all to a family Dunes, and then in my code example replace "Hill" with "Dunes".

    What my code does - when a tank is hit, it checks if there is any hill/dune sprite in this point. And if this hill is on a layer higher than tank, or on the same layer with tank, but above the tank on z-axis, then the hit is cancelled. (because the tank is hidden by the hill)

  • Kyatric Unfortunately, new memory management actions in C3 don't provide the same functionality as MM_Preloader plugin. If you need to spawn many different graphics objects, with the plugin you can preload them into memory and then spawn from any layout without lags. With system actions you still need to dump all these objects on each layout..

  • Interestingly, the new Functions in C3 don't have this problem. You can use wait inside the function, call it multiple times and it will still remember its parameters.

  • That link is wrong (only you can access it).

    You need to share the file, copy link to shared file and post it here.

  • No, that's not what I meant. Tilemap is one object, you can't give behaviors to individual tiles. For example, if you add Fade behavior, it will apply to the whole TileMap, and all tiles will fade at once.

    If you need to control/move/animate individual tiles, you need to use Sprites instead.

  • You can add any behaviors to tilemaps, and you can use tilemaps for different things, not just decoration.

    For level design in sokoban game a Tilemap with Solid behavior is a good choice. However, it's better to use sprites for moving objects (boxes and character).

  • You mean typing mistake in your code? Is it working now? If not, please post your project file, because I don't see any errors in events, must be something else.

  • You can use variables if you need, just set them to correct values before adding to the list. You mean something like this?

    The code from your latest screenshot will not work, because the function is called on start of layout, when true=false. (Please don't name variables like this, it's really confusing)

  • Object compare X>Mouse.X -> Object set mirrored

    Object compare X<Mouse.X -> Object set not mirrored

  • See this demo and explanation of the principle used:

    dropbox.com/s/8zap7yuhwdb0pcb/Farming_TileSet.capx

    dropbox.com/s/r1em8npglbdsoeg/Tilemap_Bitwise.png

    (I didn't make it, found on this forum)

  • This code works, you don't need variables, arrays, or anything else, just this one event:

    If you want to add to the end of the list, replace "1" with a big number like "99999"

  • I don't quite understand your layers system. What you can do is check if there is any hill sprite in front of the tank at the moment of collision. With tanks and hills on different layers this can be tricky but you can try something like this:

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • aicreator I was talking about screenshot #1. You don't need any boolean variables and extra events.

    On button pressed -> Insert TextInput.text into the array, Insert TextInput.text into the list. That's it.

  • You need to insert TextInput.text into the array. Otherwise the code on your first screenshot is correct.