Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Main
- {
- questname "Change Class"
- version 1
- }
- state Begin
- {
- desc "Talk to Wise Man"
- action AddNpcChat( 4 , "Hellow stranger" );
- action AddNpcText( 4 , "Hellow stranger, what can I do for you?" );
- action AddNpcInput( 4 , 1 , "View Classes");
- action AddNpcInput( 4 , 2 , "Exit");
- rule InputNpc( 1 ) goto ClassMenu
- rule InputNpc( 2 ) goto QuestReset
- }
- state ClassMenu
- {
- desc "Talk to Wise Man"
- action ShowHint("Class menu opened");
- action AddNpcText( 4 , "Would you like to buy a class?" );
- action AddNpcInput( 4 , 1 , "Priest Class");
- action AddNpcInput( 4 , 2 , "Magician Class");
- action AddNpcInput( 4 , 3 , "Rogue Class");
- action AddNpcInput( 4 , 4 , "Archer Class");
- action AddNpcInput( 4 , 5 , "Warrior Class");
- rule InputNpc( 1 ) goto PriestSelected
- rule InputNpc( 2 ) goto MagicianSelected
- rule InputNpc( 3 ) goto RogueSelected
- rule InputNpc( 4 ) goto ArcherSelected
- rule InputNpc( 5 ) goto WarriorSelected
- }
- state PriestSelected
- {
- action AddNpcText( 4 , "Priest Cost: 100G");
- action AddNpcInput( 4 , 1 , "Buy Priest");
- action AddNpcInput( 4 , 2 , "View Classes");
- action AddNpcInput( 4 , 3 , "Exit");
- rule InputNpc( 1 ) goto PriestBought
- rule InputNpc( 2 ) goto ClassMenu
- rule InputNpc( 3 ) goto QuestReset
- }
- state MagicianSelected
- {
- action AddNpcText( 4 , "Magician Cost: 200G");
- action AddNpcInput( 4 , 1 , "Buy Magician");
- action AddNpcInput( 4 , 2 , "View Classes");
- action AddNpcInput( 4 , 3 , "Exit");
- rule InputNpc( 1 ) goto MagicianBought
- rule InputNpc( 2 ) goto ClassMenu
- rule InputNpc( 3 ) goto QuestReset
- }
- state RogueSelected
- {
- action AddNpcText( 4 , "Rogue Cost: 300G");
- action AddNpcInput( 4 , 1 , "Buy Rogue");
- action AddNpcInput( 4 , 2 , "View Classes");
- action AddNpcInput( 4 , 3 , "Exit");
- rule InputNpc( 1 ) goto RogueBought
- rule InputNpc( 2 ) goto ClassMenu
- rule InputNpc( 3 ) goto QuestReset
- }
- state ArcherSelected
- {
- action AddNpcText( 4 , "Archer Cost: 400G");
- action AddNpcInput( 4 , 1 , "Buy Archer");
- action AddNpcInput( 4 , 2 , "View Classes");
- action AddNpcInput( 4 , 3 , "Exit");
- rule InputNpc( 1 ) goto ArcherBought
- rule InputNpc( 2 ) goto ClassMenu
- rule InputNpc( 3 ) goto QuestReset
- }
- state WarriorSelected
- {
- action AddNpcText( 4 , "Warrior Cost: 500G");
- action AddNpcInput( 4 , 1 , "Buy Warrior");
- action AddNpcInput( 4 , 2 , "View Classes");
- action AddNpcInput( 4 , 3 , "Exit");
- rule InputNpc( 1 ) goto WarriorBought
- rule InputNpc( 2 ) goto ClassMenu
- rule InputNpc( 3 ) goto QuestReset
- }
- state PriestBought
- {
- action SetClass(2);
- action RemoveItem( 1 , 100)
- action ShowHint("You bought the Priest Class for: 100 Gold.");
- action Reset();
- }
- state MagicianBought
- {
- action SetClass(3);
- action RemoveItem( 1 , 200)
- action ShowHint("You bought the Magician Class for: 200 Gold.");
- action Reset();
- }
- state RogueBought
- {
- action SetClass(4);
- action RemoveItem( 1 , 300)
- action ShowHint("You bought the Rogue Class for: 300 Gold.");
- action Reset();
- }
- state ArcherBought
- {
- action SetClass(5);
- action RemoveItem( 1 , 400)
- action ShowHint("You bought the Archer Class for: 400 Gold.");
- action Reset();
- }
- state WarriorBought
- {
- action SetClass(6);
- action RemoveItem( 1 , 500)
- action ShowHint("You bought the Warrior Class for: 500 Gold.");
- action Reset();
- }
- state QuestReset
- {
- action Reset();
- }
Advertisement
Add Comment
Please, Sign In to add comment