Hello!
I am trying to make it so that when you open my addin, it restarts from the beginning of the program.
I found this routine on casiopeia:
Code:
It was designed for OS 2/2.02, but it seems to work on the fx-CG50 Emulator.
I was just wondering if this is safe to run on hardware (OS 3.50), or if anyone has experience with this of a similar function?
I am trying to make it so that when you open my addin, it restarts from the beginning of the program.
I found this routine on casiopeia:
Code:
short*APP_EnableRestart(){
unsigned int ea;
unsigned int j;
short*pEnableRestartFlag;
ea = *(unsigned int*)0x8002007C;
ea += 0x1e6e*4;
ea = *(unsigned int*)( ea );
j = *(unsigned char*)( ea + 1 );
j *= 4;
j = ( ea + j + 4 ) & 0xFFFFFFFC;
pEnableRestartFlag = (short*)(*( unsigned int*)( j ) + 8 );
if ( pEnableRestartFlag ) *pEnableRestartFlag = 1;
return pEnableRestartFlag;
}
It was designed for OS 2/2.02, but it seems to work on the fx-CG50 Emulator.
I was just wondering if this is safe to run on hardware (OS 3.50), or if anyone has experience with this of a similar function?