Gamestudio Links
Zorro Links
Newest Posts
loading historical data 1st time
by AndrewAMD. 04/14/23 12:54
Trade at bar open
by juanex. 04/13/23 19:43
Bug in Highpass2 filter
by rki. 04/13/23 09:54
Adding Limit Orders For IB
by scatters. 04/11/23 16:16
FisherN
by rki. 04/11/23 08:38
AUM Magazine
Latest Screens
SHADOW (2014)
DEAD TASTE
Tactics of World War I
Hecknex World
Who's Online Now
1 registered members (Grant), 999 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
rki, FranzIII, indonesiae, The_Judge, storrealba
18919 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
2D Tank Game. #328352
06/12/10 12:18
06/12/10 12:18
Joined: Feb 2010
Posts: 10
India
T
Tutu Offline OP
Newbie
Tutu  Offline OP
Newbie
T

Joined: Feb 2010
Posts: 10
India
I want to build a 2D top view Tank game. I'm getting 2 problems....

1) Using -ve layer values in an Empty level disappears my Panels.

2) I want to use Multi-colored Image in which each color will have its significant meaning. Like GREEN mean grass, WHITE means snow, BLUE means water & many more. Using this I want to navigate through my game in which if the tank detects BLUE in front it will stop, if grass then okay to move, etc.


Please give me a solution for this problem.

Re: 2D Tank Game. [Re: Tutu] #328815
06/15/10 14:32
06/15/10 14:32
Joined: Oct 2004
Posts: 4,134
Netherlands
Joozey Offline
Expert
Joozey  Offline
Expert

Joined: Oct 2004
Posts: 4,134
Netherlands
I believe negative layers make it a (sky) background, thus indeed appear behind anything else. Start at 1000 or something if you need to go lower.
The manual says:
Quote:
A7.06 Panels, texts, and view entities with a positive layer value are placed above any view; with a negative layer value they are placed below any view. This can be used to define an image visible in the background of a view that has no sky and a transparent sky_color.


To detect you're in water or not, read about pixel_for_bmap in the manual. Check the pixel that is in front of the tank. If its value is blue, you know it's water.

Last edited by Joozey; 06/15/10 14:33.

Click and join the 3dgs irc community!
Room: #3dgs

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