Page 1 of 1

Isometric Depth is not Working Properly

Posted: Mon Oct 07, 2013 6:43 pm
by dsteve
Dear Rob,

I am confused about how to create an isometric depth in isoislands example,
hereby I include the picture of my problem,


Screen Shot 2013-10-08 at 1.53.21 AM.png

Steven

Re: Isometric Depth is not Working Properly

Posted: Mon Oct 07, 2013 6:49 pm
by coolbloke1324
dsteve wrote:Dear Rob,

I am confused about how to create an isometric depth in isoislands example,
hereby I include the picture of my problem,


Screen Shot 2013-10-08 at 1.53.21 AM.png

Steven
Hey ya!

So there is some info on the isometric sorting system avaiable here: http://www.isogenicengine.com/documenta ... nd-images/

The basics of it is that you have one entity that acts as a 3d-positioned cuboid and inside that entity you have your image which can be positioned as you wish to provide the correct location to line up with the iso grid

Let me know if you need more help!

Re: Isometric Depth is not Working Properly

Posted: Mon Oct 07, 2013 7:08 pm
by dsteve
Dear Rob,

Oh, I finally understand,
Well then, thank you very much Rob

Steven

Re: Isometric Depth is not Working Properly

Posted: Mon Oct 07, 2013 7:33 pm
by coolbloke1324
A new video tutorial on how to create isometric entities will be online within 30 minutes, I made it just for you! :) Will post the link here when it has finished encoding and uploading.

Cheers,

Rob

Re: Isometric Depth is not Working Properly

Posted: Mon Oct 07, 2013 8:08 pm
by dsteve
Dear All,

I finally managed to overcome this, by using
.depthSortMode(1)

Thanks

Re: Isometric Depth is not Working Properly

Posted: Mon Oct 07, 2013 8:47 pm
by coolbloke1324
The isometric tutorial is now available at: http://youtu.be/7eKZM8uevNU

Re: Isometric Depth is not Working Properly

Posted: Tue Oct 08, 2013 4:11 am
by dsteve
Dear Rob,

I am really sorry,
I didn't see your last reply,
That is fantastic, thank you very much Rob

Best Regards,
Steven

Re: Isometric Depth is not Working Properly

Posted: Tue Oct 08, 2013 6:44 am
by dsteve
Dear Rob,

Eventually I am facing this problem,
The image entity is not mergin with the red spot,
actually I expand the size3d parameters,
but it didn't achieve what I really want,
Screen Shot 2013-10-08 at 1.32.41 PM.png
Also, here's my code :

Code: Select all

	Airport: ClientItem.extend({
		classId: 'Airport',

		init: function (parent, tileX, tileY) {
			ClientItem.prototype.init.call(this, tileX, tileY, 8, 8);
			console.log("std tilex "+tileX+"tiley "+tileY);
			var self = this;

			// Setup the 3d bounds container (this)
			this.isometric(true)
				.mount(parent)
				.size3d(8 * parent._tileWidth, 8 * parent._tileHeight, parent._tileHeight *2.9)
				.translateToTile((tileX) + 0, (tileY) + 0, 0)
				.mouseOver(function () { this.drawBounds(true); this.drawBoundsData(true); })
				.mouseOut(function () { this.drawBounds(false); this.drawBoundsData(false); })
				.drawBounds(false)
				.drawBoundsData(false)
				.occupyTile(tileX, tileY, 8, 8);

			// Create the "image" entity
			this.imageEntity = new IgeEntity()
				.texture(ige.client.gameTexture.airport)
				.dimensionsFromCell()
				.drawBounds(true)
				.drawBoundsData(false)
				.mount(this);
		}
	}),
Thanks

Re: Isometric Depth is not Working Properly

Posted: Wed Oct 09, 2013 9:26 am
by dsteve
Dear Rob,


Apparently, the problem is in the cursor position,
where it located directly at the center of the "ghost item"
Screen Shot 2013-10-09 at 4.33.58 PM.png
Hopefully you are willingly to help me

Steven

Re: Isometric Depth is not Working Properly

Posted: Wed Oct 09, 2013 9:55 am
by coolbloke1324
Can you zip up your whole project and attach to a reply here so I can test your code? Thanks!