rem: DoInput ((PVOID)&MenuState);
add: DoInput ((PVOID)&MenuState, TRUE);
context: InitEncounter (void){	COUNT i;	MEM_HANDLE hOldIndex;	FRAME SegueFrame;	STAMP s;	TEXT t;	extern FRAME planet[];	MUSIC_REF MR;	SetSemaphore (GraphicsSem);	hOldIndex = SetResourceIndex (hResIndex);	SetContext (SpaceContext);	SetContextFont (TinyFont);	MR = LoadMusicInstance (REDALERT_MUSIC);	PlayMusic (MR, FALSE, 1);	SegueFrame = CaptureDrawable (LoadGraphic (SEGUE_PMAP_ANIM));	ClearSemaphore (GraphicsSem);	while (PLRPlaying (MR))		TaskSwitch ();	StopMusic ();	DestroyMusic (MR);	SetSemaphore (GraphicsSem);	s.origin.x = s.origin.y = 0;	SetTransitionSource (NULL);	BatchGraphics ();		SetContextBackGroundColor (BLACK_COLOR);	ClearDrawable ();	s.frame = SegueFrame;	DrawStamp (&s);//    t.baseline.x = SIS_SCREEN_WIDTH >> 1;	t.baseline.x = (SIS_SCREEN_WIDTH >> 1) + 1;	t.baseline.y = 10;	t.align = ALIGN_CENTER;	SetContextFont (MicroFont);	SetContextForeGroundColor (BUILD_COLOR (MAKE_RGB15 (0x00, 0x00, 0x14), 0x01));	if (LOBYTE (GLOBAL (CurrentActivity)) == IN_HYPERSPACE)	{		t.pStr = GAME_STRING (ENCOUNTER_STRING_BASE + 0);		t.CharCount = (COUNT)~0;		font_DrawText (&t);		t.baseline.y += 12;		t.pStr = GAME_STRING (ENCOUNTER_STRING_BASE + 1);		t.CharCount = (COUNT)~0;		font_DrawText (&t);	}	else	{		UNICODE buf[40];		t.pStr = GAME_STRING (ENCOUNTER_STRING_BASE + 2);		t.CharCount = (COUNT)~0;		font_DrawText (&t);		t.baseline.y += 12;		GetClusterName (CurStarDescPtr, buf);		t.pStr = buf;		t.CharCount = (COUNT)~0;		font_DrawText (&t);		t.baseline.y += 12;		t.pStr = GLOBAL_SIS (PlanetName);		t.CharCount = (COUNT)~0;		font_DrawText (&t);	}	s.origin.x = SIS_SCREEN_WIDTH >> 1;	s.origin.y = SIS_SCREEN_HEIGHT >> 1;	s.frame = planet[0];	DrawStamp (&s);	if (LOBYTE (GLOBAL (CurrentActivity)) != IN_LAST_BATTLE)	{#define NUM_DISPLAY_PTS (sizeof (display_pt) / sizeof (display_pt[0]))		HSTARSHIP hStarShip, hNextShip;		POINT display_pt[] =		{			{10, 51},			{-10, 51},			{33, 40},			{-33, 40},			{49, 18},			{-49, 18},			{52, -6},			{-52, -6},			{44, -27},			{-44, -27},		};		for (hStarShip = GetHeadLink (&race_q[1]), i = 0;				hStarShip && i < 60; hStarShip = hNextShip, ++i)		{			RECT r;			STARSHIPPTR StarShipPtr;			StarShipPtr = LockStarShip (&race_q[1], hStarShip);			if (StarShipPtr->RaceDescPtr->ship_info.crew_level != (BYTE)~0)				hNextShip = _GetSuccLink (StarShipPtr);			else /* if infinite ships */				hNextShip = hStarShip;			s.origin = display_pt[i % NUM_DISPLAY_PTS];			if (i >= NUM_DISPLAY_PTS)			{				COUNT angle, radius;				radius = square_root ((long)s.origin.x * s.origin.x						+ (long)s.origin.y * s.origin.y)						+ ((i / NUM_DISPLAY_PTS) * 18);				angle = ARCTAN (s.origin.x, s.origin.y);				s.origin.x = COSINE (angle, radius);				s.origin.y = SINE (angle, radius);			}			s.frame = SetAbsFrameIndex (					StarShipPtr->RaceDescPtr->ship_info.icons, 0					);			GetFrameRect (s.frame, &r);			s.origin.x += (SIS_SCREEN_WIDTH >> 1) - (r.extent.width >> 1);			s.origin.y += (SIS_SCREEN_HEIGHT >> 1) - (r.extent.height >> 1);			DrawStamp (&s);			UnlockStarShip (&race_q[1], hStarShip);		}	}	UnbatchGraphics ();	DestroyDrawable (ReleaseDrawable (SegueFrame));	ScreenTransition (3, NULL);	SetResourceIndex (hOldIndex);	ClearSemaphore (GraphicsSem);	{		MENU_STATE MenuState;		MenuState.InputFunc = DoSelectAction;		MenuState.Initialized = FALSE;		DrawMenuStateStrings (PM_CONVERSE, MenuState.CurState = HAIL);		SetSemaphore (GraphicsSem);		SetFlashRect ((PRECT)~0L, (FRAME)0);		ClearSemaphore (GraphicsSem);		DoInput ((PVOID)&MenuState);		SetSemaphore (GraphicsSem);		SetFlashRect (NULL_PTR, (FRAME)0);		ClearSemaphore (GraphicsSem);		return (MenuState.CurState);	}}