lite-c workshop#6 - button issue

Posted By: danielctodd

lite-c workshop#6 - button issue - 10/15/11 04:10

This is probably something simple but I can't seem to figure it out. Here is the code and the runtime error.
Code:
////////////////////////////////////////////////////////////////////
#include <acknex.h>
#include <default.c>

////////////////////////////////////////////////////////////////////

function main()
{
  screen_size.x = 800;
  screen_size.y = 600;
	screen_color.blue = 150;
	mouse_mode = 4;
}

function quit_program()
{
	while (key_any) {wait (1);}
	sys_exit(NULL);
}

//////////////////////////////////////////////////////////////////////

PANEL* main_pan =
{
	bmap = "main.pcx";
 	pos_x = 250;     
 	pos_y = 200;    
	button (250, 134, "quitclicked.pcx", "quitnormal.pcx", "quitover.pcx", quit_program, NULL, NULL); 
	button (150, 94, "buttonclicked.pcx", "buttonnormal.pcx", "buttonover.pcx", NULL, NULL, NULL);
	flags = OVERLAY | SHOW;
}


Runtime Error: Can't open buttonclicked.pcx

I made 3 basic buttons in gimp and saved them as ZSoft PCX images, leaving them in the same directory as the other buttons.
Any help is appreciated.
Posted By: mrcerez

Re: lite-c workshop#6 - button issue - 10/15/11 06:31

you delete buttonclicked.pcx?
your button name is exm(abab.pcx) you must chance

button (250, 134, "abab.pcx", "cccc.pcx", "amdint.pcx", quit_program, NULL, NULL);
Posted By: danielctodd

Re: lite-c workshop#6 - button issue - 10/16/11 00:37

Never mind. It was a simple mistake on my part. I forgot I made another folder to house the same workshops so I could have both the original and the edited versions.
© 2024 lite-C Forums