Skip to content

Instantly share code, notes, and snippets.

@ssg
Created January 24, 2011 22:16
Show Gist options
  • Save ssg/794087 to your computer and use it in GitHub Desktop.
Save ssg/794087 to your computer and use it in GitHub Desktop.
sexy fighter cracktro
{ this is obviously missing a lot stuff (obj files) - but scrolltexts are fun to read }
uses XBuf,XProtect,XMode,crt,Dos;
const
finished:boolean=false;
game = 'SEXY FIGHTER';
software = 'FROG';
cracker = 'SSG & FatalicA';
var
GlobalPalette : TPalette;
var
n:byte;
SSG,FatalicA:PImage;
fuckit:boolean;
Old9,Old8:pointer;
PalP:pointer;
procedure SSGproc;external;
{$L SSG.OBJ}
procedure FATproc;external;
{$L FAT.OBJ}
procedure ScrollUp;far;
var
b:byte;
tmp:longint;
begin
for b:=0 to 15 do begin
Port[$3d4] := $8;
Port[$3d5] := b;
asm
mov dx,3dah
@Loop1:
in al,dx
test al,8
jne @Loop1
@Loop2:
in al,dx
test al,8
je @Loop2
end;
end;
Port[$3d4] := $8;
Port[$3d5] := 0;
gotoxy(wherex,wherey-1);
move(mem[$b800:160],mem[$b800:0],4000-160);
end;
procedure ScrollText(s:string);
var
x:integer;
begin
if finished then exit;
for x := 320 downto -(length(s)*8) do begin
if finished then break;
WriteStr(x,96,s);
sync;
end;
end;
procedure New9;far;assembler;
asm
push ax
in al,60h
mov ah,al
or al,80h
out 61h,al
cmp ah,1
jne @Exit
push es
push di
mov di,seg @data
mov es,di
mov di,offset finished
mov byte ptr es:[di],1
pop di
pop es
@Exit:
mov al,$20
out $20,al
pop ax
iret
end;
procedure InitKeyboard;
begin
GetIntVec(9,Old9);
SetIntVec(9,@New9);
end;
procedure DoneKeyboard;
begin
if Old9 <> NIL then SetIntVec(9,Old9);
end;
const
in8:word = 0;
procedure new8;interrupt;
var
temp:TRGB;
begin
if in8 = 0 then begin
inc(in8);
temp := GlobalPalette[32];
FastMove(GlobalPalette[33],GlobalPalette[32],31*SizeOf(TRGB));
GlobalPalette[32+31] := temp;
SetPalette(GlobalPalette);
dec(in8);
end else dec(in8);
port[$20] := $20;
end;
var
SP:TPalette;
begin
asm
mov al,0
out 40h,al
mov al,80h
out 40h,al
end;
Old9 := NIL;
InitKeyboard;
GetPalette(SP);
for n:=1 to 25 do begin
fuckit := wherey = 1;
ScrollUp;
if fuckit then break;
end;
NullPalette;
InitXMode;
NullPalette;
SSG := LoadMem(@SSGproc);
FatalicA := LoadMem(@FATproc);
PalP := @SSGproc;
inc(word(PalP),32);
Move(PalP^,GlobalPalette,768);
for n:=32 to 32+15 do GlobalPalette[48+(47-n)] := GlobalPalette[n];
PutCentered(0,2,CenterX,SSG);
PutCentered(0,200-FatalicA^.YSize-2,CenterX,FatalicA);
SetSmoothPal(GlobalPalette);
GetIntVec(8,Old8);
SetIntVec(8,@New8);
SetBIOSFont;
repeat
ScrollText('GENSYS Proudly Presents');
ScrollText(game);
ScrollText('Published by '+software);
ScrollText('Cracked by '+cracker);
ScrollText('Intro by SSG - (Coded in BP7)');
ScrollText('Supplied by DiM-SOFT');
ScrollText('Greetz goes to');
ScrollText('Wiseman (our rookie coder)');
ScrollText('iBO (ATDT monster)');
ScrollText('Boogie (lost in vm.cc.baum.edu.tr)');
ScrollText('Harun (thanx for PCinterns)');
ScrollText('Stranger (young soldier)');
ScrollText('All guyz in tranavm2 (whatchadoin''right there?)');
ScrollText('...');
ScrollText('One scroll text of an intro on a C64 said: "It''s hard to write long intro texts". They were right');
ScrollText('This crackin'' job is cool but takes much time');
ScrollText('Our quality releases are coming soon...');
ScrollText('Press ESC to skip this intro');
ScrollText('Convert this game to English if you know anything about this Japanese shit');
ScrollText('Damn this Windows... (and other Microsoft products of course)');
ScrollText('Hey, Borland! Wake up! Now it''s time to release this BOSS!?');
ScrollText('(Also it''s a great time to fill out your registration card)');
ScrollText('...');
ScrollText('This HOT game first does its anti-debug job.');
ScrollText('Then the first time you fucked the girl, game asks you the copy protection code');
ScrollText('This wasn''t the problem. The most difficult part (which SSG didn''t want to mess with it) is runtime checks');
ScrollText('Then FatalicA''s army has arrived and fixed that part');
ScrollText('But the ultimate intro is coded by SSG , too');
ScrollText('..over..');
until finished;
SetIntVec(8,Old8);
ClearBuf(GlobalPalette,SizeOf(TPalette));
SetSmoothPal(GlobalPalette);
DoneXMode;
DoneKeyboard;
asm
mov al,$ff
out 40h,al
out 40h,al
end;
end.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment