// OUTDOOR SECTION SCRIPT
//    Section: X = 0, Y = 5: Lava Ocean NW

beginoutdoorscript;

variables;

int choice,i,j,k;
string dlgstr;

body;

beginstate INIT_STATE;
// This state called whenever this section is loaded into memory.
break;

beginstate START_STATE;
// Starting state of the section, called every turn the party 
// stands inside this section until you change the state.
break;

beginstate 10;
	if (get_flag(205,0) == 0) {
		reset_dialog();
		add_dialog_str(0,"Before you, the ground is aflame.",0);
		add_dialog_str(1,"An ocean of lava stretches as far as you can see. A few rocks here and there serve to create paths between small hills, islands amidst the fires, paths that seem almost too orderly to be natural.",0);
		add_dialog_str(2,"The journey from Thassaka to here is already a difficult trek; if the expedition is to travel to this place, you must find some place inside this ocean of lava for it to stop at least for a brief time.",0);
		add_dialog_str(3,"But they can't stay. You must also find some way out to a more hospitable area, or else you all may perish. Once you've found both of those things, you can report back to Pithoss that you've scouted the area enough for the expedition to proceed.",0);
		set_flag(205,0,run_dialog(1));
		}
break;

beginstate 11;
if (has_special_item(1) != 0)
	end();
	
	reset_dialog_preset_options(1);
	if (get_flag(17,3))
		add_dialog_str(0,"This must be Elin-Tel. Apparently he didn't make it far. Little remains of him after so many centuries, but the skeleton is broken in several places, evidence of a violent death.",0);
	else
		add_dialog_str(0,"You find the badly damaged body of an ancient vahnatai. Little remains of him after so many centuries, but the skeleton is broken in several places, evidence of a violent death.",0);
	add_dialog_str(1,"On the body, you find a small crystal key. What do you do?",0);
	if (run_dialog(1) == 2)
		change_spec_item(1,1);
break;

beginstate 12;
if (get_skill_total(18) < 16) {
	message_dialog("You find some strange-looking plants. Unfortunately, you don't know enough about Nature Lore to know what they are or how they might be used.","");
	end();
	}
	
if (get_flag(205,1) == 0) {
	reset_dialog();
	add_dialog_str(0,"You find a patch of Mandrake! Your knowledge of Nature Lore extends to how to pick it so that it will keep its vital parts that are useful in potions. Do you wish to pick it?",0);
	add_dialog_choice(0,"No. (Leave it alone.)");
	add_dialog_choice(1,"Yes. (Pick it.)");
	if (run_dialog(1) == 2) {
		set_flag(205,1,reward_give(219));
		reward_give(219);
		reward_give(219);
		}
	}
else
	message_dialog("Mandrake grows back slowly, and this patch has not yet grown back.","");
break;