1 registered members (AndrewAMD),
682
guests, and 9
spiders. |
Key:
Admin,
Global Mod,
Mod
|
|
|
Problem !!!
#344984
10/22/10 14:01
10/22/10 14:01
|
Joined: Aug 2010
Posts: 131 Iran
Mafia_IR
OP
Member
|
OP
Member
Joined: Aug 2010
Posts: 131
Iran
|
i have an odd problem in panel : #include <acknex.h> #include <default.c>
///////////////////////////////////////////////////////////////////////
BMAP* menu_jpg = "pic//Menu.jpg" ; BMAP* LD_jpg = "pic//LD.jpg" ; BMAP* SG_jpg = "pic//SG.jpg" ; BMAP* NG_jpg = "pic//NG.jpg" ; BMAP* HM_jpg = "pic//HM.jpg" ; BMAP* CTM_jpg = "pic//CTM.jpg" ; BMAP* EX_jpg = "pic//EX.jpg" ;
/////////////////////////////////////////////////////////////////////// function NGF () { level_load("level_one.wmb"); beep(); }
PANEL* menu = { pos_x = 120 ; pos_y = 10 ; layer = 1 ; bmap = "menu_jpg" ; button (250, 134, NG_jpg, NULL, NULL, NGF, NULL, NULL); flags = OVERLAY | SHOW; } function main () { video_mode = 7 ; video_screen = 2 ; }
As you can see in this panel , engine should shows my panel background and a button . my panel was showed but button is not . what is problem ? Thanks .
Last edited by Mafia_IR; 10/22/10 14:02.
|
|
|
Re: Problem !!!
[Re: Helghast]
#345045
10/22/10 19:18
10/22/10 19:18
|
Joined: Aug 2010
Posts: 131 Iran
Mafia_IR
OP
Member
|
OP
Member
Joined: Aug 2010
Posts: 131
Iran
|
I've used : BMAP* NG_bmp = "pic//NG.bmp"; instead of BMAP* NG_jpg = "pic//NG.jpg"; but , no difference ... and engine shows my panel background but button is not ...
|
|
|
Re: Problem !!!
[Re: Mafia_IR]
#345103
10/23/10 09:05
10/23/10 09:05
|
Joined: Nov 2008
Posts: 216
jane
Member
|
Member
Joined: Nov 2008
Posts: 216
|
Here a free Batch-Converter: http://easy-graphic-converter.softonic.de/and i have changed a little bit the script:
#define PRAGMA_PATH "pic"
#include <acknex.h>
#include <default.c>
///////////////////////////////////////////////////////////////////////
BMAP* menu_tga = "Menu.tga" ;
BMAP* LD_tga = "LD.tga" ;
BMAP* SG_tga = "SG.tga" ;
BMAP* NG_tga = "NG.tga" ;
BMAP* HM_tga = "HM.tga" ;
BMAP* CTM_tga = "CTM.tga" ;
BMAP* EX_tga = "EX.tga" ;
///////////////////////////////////////////////////////////////////////
function NGF ()
{
level_load("level_one.wmb");
beep();
}
PANEL* menu =
{
pos_x = 120 ;
pos_y = 10 ;
layer = 1 ;
bmap = "menu_jpg" ;
button (250, 134, NG_tga, NULL, NULL, NGF, NULL, NULL);
flags = OVERLAY | SHOW;
}
function main ()
{
video_mode = 7 ;
video_screen = 2 ;
level_load(NULL);
}
Last edited by jane; 10/23/10 09:07.
|
|
|
Re: Problem !!!
[Re: badapple]
#345143
10/23/10 15:43
10/23/10 15:43
|
Joined: Nov 2008
Posts: 216
jane
Member
|
Member
Joined: Nov 2008
Posts: 216
|
sorry in the script is another error
the line:
bmap = "menu_jpg" ;
must be:
bmap = menu_tga;
your tga is correct, this should work.
EDIT: set the layer from 1 to 10
the button-position (x,y) is the distance from the point top-left from the paneln not from the screen.
the button must be complete inside of the panel .
EDIT: thanks Richi007
Last edited by jane; 10/23/10 16:04.
|
|
|
|