Показать сообщение отдельно
Старый 09.04.2009, 16:54   #3
Romanzes
Разработчик
 
Аватар для Romanzes
 
Регистрация: 06.04.2008
Сообщений: 541
Написано 196 полезных сообщений
(для 638 пользователей)
Ответ: Question from holland :)

По поводу Sagem'ов ничем не могу помочь. Хотел только сказать, что переменная schaambef у тебя явно лишняя. Я бы переделал код вот так:
program HackGame; 
uses text;

var option1, option2 : integer; 
    play, clicked : command;    
    optie1, optie2, verhaal : string;
		key: integer;

procedure question (optie1, optie2: string);
	begin
  ShowMenu('Select a game', CH_IMPLICIT); 
     
  option1 := MenuAppendString(optie1); 
  option2 := MenuAppendString(optie2); 

  play := CreateCommand('Play', CM_SCREEN, 1); 
  AddCommand(play); 

  repeat Delay(100); until GetClickedCommand = play; 
end;

procedure gamescreen (verhaal: string);
	begin
  	showCanvas;
	text.init;
	text.set_text_par(10, 10, getWidth-10, getHeight-10, 1, 16, 2, 64, verhaal);
	setColor(128,255,0);
	fillRect(0,0,GetWidth,GetHeight);
	setColor(0,128,64);
	text.draw_mult_str;
	Repaint; Delay(100);
	while true do begin
		setColor(128,255,0);
		fillRect(0,0,GetWidth,GetHeight);
		setColor(0,128,64);
		text.draw_mult_str;
		Repaint; Delay(100);
		key:=KeyToAction(GetKeyPressed);
		if key=GA_UP then text.Mode_Up;
		if key=GA_DOWN then text.Mode_Down;
		if key=GA_LEFT then text.Page_Up;
		if key=GA_RIGHT then text.Page_Down;
		if key=GA_FIRE then break;
		Delay(100);
	end;		
end;


begin 
gamescreen ('blablablablablabla.');
question ('hello there', 'question here');
gamescreen ('another question here');
question ('hello again', 'option two question');
end.
Надеюсь, я ничего не напутал с синтаксисом, так как давно уже не пользовался Midlet Pascal'ем.
(Offline)
 
Ответить с цитированием