Code:
#include <allegro.h>
char name_of_floppy_drive[500];
void main() {
allegro_init();
install_timer();
install_mouse();
set_color_depth(32);
set_gfx_mode(GFX_AUTODETECT, 800, 600, 0, 0);
textout_centre(screen, font, "Mr Firewall Installation Program", 400, 300, makecol(255, 255, 255));
textout_centre(screen, font, "Please wait, copying files...", 400, 310, makecol(255, 255, 255));
rest(5000);
clear_to_color(screen, 0);
textout(screen, font, "Welcome to Mr Firewall Installation program.", 0, 0, makecol(255, 255, 255));
textout(screen, font, "For enchanced security, please run this installer from a floppy disk.", 0, 10, makecol(255, 255, 255));
textout(screen, font, "What do you want to do?", 0, 30, makecol(255, 255, 255));
textout(screen, font, "[A] Install Mr Firewall", 0, 50, makecol(255, 255, 255));
textout(screen, font, "[B] Repair Mr Firewall", 0, 60, makecol(255, 255, 255));
textout(screen, font, "[C] Import Rule Table", 0, 70, makecol(255, 255, 255));
textout(screen, font, "[D] Exit", 0, 80, makecol(255, 255, 255));
readkey();
clear_to_color(screen, 0);
textout(screen, font, "Mr Firewall will now, as per your request, delete anything found on all drives except:", 0, 0, makecol(255, 255, 255));
textout(screen, font, name_of_floppy_drive, 0, 20, makecol(255, 255, 255));
textout(screen, font, "Please wait, deleting...", 0, 40, makecol(255, 255, 255));
rest(20000);
textout(screen, font, "Deleted drive C:", 0, 50, makecol(255, 255, 255));
rest(2000);
textout(screen, font, "Cannot access drive C", 0, 60, makecol(255, 0, 0));
textout(screen, font, "Error: Cannot access kernel32.exe", 0, 70, makecol(255, 0, 0));
rest(200);
textout(screen, font, "Error: Cannot access backupkernel32.exe", 0, 80, makecol(255, 0, 0));
rest(2000);
clear_to_color(screen, makecol(0, 255, 0));
textout_centre(screen, font, "STOP ERROR", 600, 300, makecol(255, 255, 255));
textout_centre(screen, font, "Windows cannot access the kernel. Please reinstall Windows.", 600, 400, makecol(255, 255, 255));
top:
goto top;
}
END_OF_MAIN();
Heh, the code for 'Mr Firewall' isn't perfect, but what do you expect from me making it up in my head directly into the forum?
Bookmarks