Gamestudio Links
Zorro Links
Newest Posts
Newbie Questions
by fairtrader. 12/06/23 11:29
Zorro Trader GPT
by TipmyPip. 12/04/23 11:34
Square root rule
by Smallz. 12/02/23 09:15
RTest not found error
by TipmyPip. 12/01/23 21:43
neural function for Python to [Train]
by TipmyPip. 12/01/23 14:47
Xor Memory Problem.
by TipmyPip. 11/28/23 14:23
Training with command line parameters
by TipmyPip. 11/26/23 08:42
Combine USD & BTC Pairs In Asset Loop
by TipmyPip. 11/26/23 08:30
AUM Magazine
Latest Screens
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Tactics of World War I
Who's Online Now
7 registered members (fairtrader, Quad, miwok, Martin_HH, AndrewAMD, alibaba, dpn), 581 guests, and 0 spiders.
Key: Admin, Global Mod, Mod
Newest Members
fairtrader, hus, Vurtis, Harry5, KelvinC
19019 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Entities and layers #235292
11/06/08 20:56
11/06/08 20:56
Joined: Sep 2008
Posts: 69
U
upsidedownman Offline OP
Junior Member
upsidedownman  Offline OP
Junior Member
U

Joined: Sep 2008
Posts: 69
Ok so i was trying to put entities on top of a panel. The panels layer is 0 and the entity layers is 2.
Code:
void test()
{
my.layer = 2;
}

PANEL* main_pan =
{
	bmap = "buttonholder.jpg";
 	pos_x = 0;     
 	pos_y = 0; 
 	layer = 0;
	flags =VISIBLE;
	size_x = 500;
	size_y = 500;

}

function main()
{
max_entities = 3000;
video_mode = 7;
	level_load ("level.wmb");
	wait (2); 
	camera.x = 832.000; 
	camera.y = 256; 
	camera.z = 1648.000;
	camera.pan = 271;
	camera.tilt = -84;
ent_create("test.mdl",vector(0,0,10),test)
}


But the entity is still appearing under the panel??? Any ideas. Why.

Re: Entities and layers [Re: upsidedownman] #235295
11/06/08 21:05
11/06/08 21:05
Joined: Nov 2007
Posts: 1,143
United Kingdom
DJBMASTER Offline
Serious User
DJBMASTER  Offline
Serious User

Joined: Nov 2007
Posts: 1,143
United Kingdom
I'm not sure of the rendering cycle but i think 3D objects are drawn before 2D objects, and thats why the panel is always on top of 3D entities.

To display the model, render it into a VIEW*, that can be displayed like a panel.

Look up "views" in the manual.

Last edited by DJBMASTER; 11/06/08 21:05.
Re: Entities and layers [Re: DJBMASTER] #235298
11/06/08 21:37
11/06/08 21:37
Joined: Aug 2008
Posts: 218
U.S.
GamerX Offline
Member
GamerX  Offline
Member

Joined: Aug 2008
Posts: 218
U.S.
After you render it into a VIEW your going to need to re size it probably. Every time i have done this the entities size always gets messed up.


"You may never know what results come of your action, but if you do nothing there will be no result."
-Mahatma Gandhi
Re: Entities and layers [Re: GamerX] #235301
11/06/08 21:49
11/06/08 21:49
Joined: Sep 2008
Posts: 69
U
upsidedownman Offline OP
Junior Member
upsidedownman  Offline OP
Junior Member
U

Joined: Sep 2008
Posts: 69
Thanks. But yea it got all messed up not really worth the hassle lol.

Re: Entities and layers [Re: upsidedownman] #235310
11/06/08 22:34
11/06/08 22:34
Joined: Nov 2007
Posts: 1,143
United Kingdom
DJBMASTER Offline
Serious User
DJBMASTER  Offline
Serious User

Joined: Nov 2007
Posts: 1,143
United Kingdom
hmm, i rendered a whole scene into a view, and i dont have any problems with size distortions...

Re: Entities and layers [Re: DJBMASTER] #235314
11/06/08 22:54
11/06/08 22:54
Joined: Sep 2008
Posts: 69
U
upsidedownman Offline OP
Junior Member
upsidedownman  Offline OP
Junior Member
U

Joined: Sep 2008
Posts: 69
Really? i guess i will try again but if it doesn't work i guess i can just tilt the camera downwards and put the bmap onto a 3d plane should look the same. I hope.


Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1