Karai17 wrote:You need to download bump separately, yes. The plugin is simply an interface.
In Tiled, you can set custom properties of basically anything. Layers, tiles, objects, etc. If you set a property called "collidable" and give it the value "true", then when you initialize your physics world, in your case Map:bump_init(), it should detect all of those collidable flags and convert them into physics objects.
Thats what i'm trying. I've added an object layer with the option collidable true and also on a tile itself. But the count keeps giving 1.
There a way to draw all the objects with a border or a block itself so you can see them?
Karai17 wrote:I'm not terribly familiar with the bump plugin, I didn't write that one. You'll have the check the source to see if there is a draw function.
But why does it only return 1 on count? Shouldn't the sti plugin have added the collidable tile layers and tiles?
As I said, I am not really familiar enough with that plugin to say one way or the other. It might be a bug in the plugin, it might be a bug in your code.
STI - An awesome Tiled library LÖVE3D - A 3D library for LÖVE 0.10+
Karai17 wrote:As I said, I am not really familiar enough with that plugin to say one way or the other. It might be a bug in the plugin, it might be a bug in your code.
There is a method :bump_draw. And what do you mean count returns 1?
Edit: nvm, I see what you mean. The objects should be added to the world if you use the correct flag. I have tested it previously and should work. If you need an example on how I use this plugin(that I wrote) follow the link below.
I don't use an object layer in the maps provided but you can add it in yourself and it will just work. It's a bit old but it's still relevant. I actually should update my codes lol.
bobbyjones wrote:There is a method :bump_draw. And what do you mean count returns 1?
Edit: nvm, I see what you mean. The objects should be added to the world if you use the correct flag. I have tested it previously and should work. If you need an example on how I use this plugin(that I wrote) follow the link below.
I don't use an object layer in the maps provided but you can add it in yourself and it will just work. It's a bit old but it's still relevant. I actually should update my codes lol.
I was actually using code form that example.
I just can't seem to add the tiles from my tiled map to be object loaded into bump
I should add that it only works with rectangles. So if you add a circle it won't work. Other than that I can't think of what can be the issue. If you want you can post the map file and I will get to it tomorrow.
bobbyjones wrote:I should add that it only works with rectangles. So if you add a circle it won't work. Other than that I can't think of what can be the issue. If you want you can post the map file and I will get to it tomorrow.
I'm just trying to get the tiles from tiled to be object in bump so they are all squares by itself?
* Now compatible with Tiled 0.16.0 (0.16.1)
* Custom Properties now use proper boolean types instead of strings, so if you use the Box2D or Bump plugins you will need to update this one way or another.
STI - An awesome Tiled library LÖVE3D - A 3D library for LÖVE 0.10+