Gamestudio Links
Zorro Links
Newest Posts
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
4 registered members (AndrewAMD, ozgur, AbrahamR, wdlmaster), 849 guests, and 7 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Hanky27, firatv, wandaluciaia, Mega_Rod, EternallyCurious
19051 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
About BackGround for Sidescroller games? #397374
03/18/12 15:13
03/18/12 15:13
Joined: May 2010
Posts: 37
AMIR_REZAs Offline OP
Newbie
AMIR_REZAs  Offline OP
Newbie

Joined: May 2010
Posts: 37
Hello

How can I set a 1024*768 wallpaper(bmp format) as a background for a sidescroller game ?

Re: About BackGround for Sidescroller games? [Re: AMIR_REZAs] #397394
03/18/12 18:35
03/18/12 18:35
Joined: Jan 2002
Posts: 4,225
Germany / Essen
Uhrwerk Offline
Expert
Uhrwerk  Offline
Expert

Joined: Jan 2002
Posts: 4,225
Germany / Essen


Always learn from history, to be sure you make the same mistakes again...
Re: About BackGround for Sidescroller games? [Re: Uhrwerk] #397446
03/19/12 12:04
03/19/12 12:04
Joined: May 2010
Posts: 37
AMIR_REZAs Offline OP
Newbie
AMIR_REZAs  Offline OP
Newbie

Joined: May 2010
Posts: 37
But when I use a negative layer it doesn't show my background and my background become invisible!!
can u give me an example?
thanks/

Re: About BackGround for Sidescroller games? [Re: AMIR_REZAs] #397448
03/19/12 12:28
03/19/12 12:28
Joined: Jan 2002
Posts: 4,225
Germany / Essen
Uhrwerk Offline
Expert
Uhrwerk  Offline
Expert

Joined: Jan 2002
Posts: 4,225
Germany / Essen
Code:
#include <acknex.h>

PANEL* p =
{
	bmap = "test.bmp";
	flags = VISIBLE;	
	layer = -1;
}

void main()
{
	
}




Always learn from history, to be sure you make the same mistakes again...
Re: About BackGround for Sidescroller games? [Re: Uhrwerk] #397462
03/19/12 14:20
03/19/12 14:20
Joined: May 2010
Posts: 37
AMIR_REZAs Offline OP
Newbie
AMIR_REZAs  Offline OP
Newbie

Joined: May 2010
Posts: 37
I did it but the panel became invisible!!

Re: About BackGround for Sidescroller games? [Re: AMIR_REZAs] #397469
03/19/12 15:42
03/19/12 15:42
Joined: Oct 2011
Posts: 1,082
Germany
C
Ch40zzC0d3r Offline
Serious User
Ch40zzC0d3r  Offline
Serious User
C

Joined: Oct 2011
Posts: 1,082
Germany
Lol, just add on all layers 1 and out this layer on 0 or 1 smirk

Re: About BackGround for Sidescroller games? [Re: Ch40zzC0d3r] #397473
03/19/12 16:12
03/19/12 16:12
Joined: Aug 2007
Posts: 1,922
Schweiz
Widi Offline
Serious User
Widi  Offline
Serious User

Joined: Aug 2007
Posts: 1,922
Schweiz
If you loaded a wmb level:
Do you set the sky_color to zero? Only then the Background from your level is disabled and you can see the Panels with negative layers.

vec_set (sky_color,vector(0,0,0));

Re: About BackGround for Sidescroller games? [Re: Widi] #397486
03/19/12 17:42
03/19/12 17:42
Joined: May 2010
Posts: 37
AMIR_REZAs Offline OP
Newbie
AMIR_REZAs  Offline OP
Newbie

Joined: May 2010
Posts: 37
Oh thanks a lot "Widi" .
it works ...

Re: About BackGround for Sidescroller games? [Re: AMIR_REZAs] #397487
03/19/12 17:45
03/19/12 17:45
Joined: Aug 2007
Posts: 1,922
Schweiz
Widi Offline
Serious User
Widi  Offline
Serious User

Joined: Aug 2007
Posts: 1,922
Schweiz
You are welcome

Re: About BackGround for Sidescroller games? [Re: Widi] #397490
03/19/12 18:12
03/19/12 18:12
Joined: Jan 2002
Posts: 4,225
Germany / Essen
Uhrwerk Offline
Expert
Uhrwerk  Offline
Expert

Joined: Jan 2002
Posts: 4,225
Germany / Essen
Btw.: I tested the above code. It works out of the box. If the above example did not run you most likely added it to your existing code, where a sky_color was set.


Always learn from history, to be sure you make the same mistakes again...

Moderated by  HeelX, Spirit 

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