Examples of DropItemAction


Examples of games.stendhal.server.entity.npc.action.DropItemAction

        Arrays.asList("letter", "note", "whiggins", "apology"),
        new AndCondition(new QuestInStateCondition(mithrilcloak.getQuestSlot(), "taking_letter"), new PlayerHasItemWithHimCondition("sealed envelope")),
        ConversationStates.ATTENDING,
        "*reads* ... *reads* ... Well, I must say, that is a weight off my mind. Thank you ever so much. Please convey my warmest regards to Whiggins. All is forgiven.",
        new MultipleActions(
                   new DropItemAction("sealed envelope"),
                   new SetQuestAndModifyKarmaAction(mithrilcloak.getQuestSlot(), "took_letter", 10.0)
        ));
  }
View Full Code Here

Examples of games.stendhal.server.entity.npc.action.DropItemAction

        Arrays.asList("fabric", "mithril", "cloak", "mithril cloak", "task", "quest"),
        new AndCondition(new QuestInStateCondition(mithrilcloak.getQuestSlot(), "got_fabric"), new PlayerHasItemWithHimCondition(mithrilcloak.getFabricName())),
        ConversationStates.ATTENDING,
        "Wow you got the " + mithrilcloak.getFabricName() + " , that took longer than I expected! Now, to cut it I need magical #scissors, if you would go get them from #Hogart. I will be waiting for you to return.",
        new MultipleActions(
                   new DropItemAction(mithrilcloak.getFabricName()),
                   new SetQuestAndModifyKarmaAction(mithrilcloak.getQuestSlot(), "need_scissors", 10.0)
        ));

    // remind about fabric. there are so many steps to getting fabric
    // that the player could be in many quest states and she still is just waiting for fabric
View Full Code Here

Examples of games.stendhal.server.entity.npc.action.DropItemAction

        Arrays.asList("clasp", "mithril clasp", "cloak", "mithril cloak", "task", "quest"),
        new AndCondition(new QuestInStateCondition(mithrilcloak.getQuestSlot(), "got_clasp"), new PlayerHasItemWithHimCondition("mithril clasp")),
        ConversationStates.ATTENDING,
        "Wow, Pedinghaus really outdid himself this time. It looks wonderful on your new cloak! Wear it with pride.",
        new MultipleActions(
                   new DropItemAction("mithril clasp"),
                   new SetQuestAndModifyKarmaAction(mithrilcloak.getQuestSlot(), "done", 10.0),
                   new EquipItemAction("mithril cloak", 1, true),
                   new IncreaseXPAction(1000)
                   )
        );
View Full Code Here

Examples of games.stendhal.server.entity.npc.action.DropItemAction

        Arrays.asList("blue striped cloak", "mithril", "mithril cloak", "ida"),
        new AndCondition(new QuestInStateCondition(mithrilcloak.getQuestSlot(), "taking_striped_cloak"), new PlayerHasItemWithHimCondition("blue striped cloak")),
        ConversationStates.ATTENDING,
        "Oh that's from Ida isn't it?! Oh yay! Thank you! Please tell her thanks from me!!",
        new MultipleActions(
                   new DropItemAction("blue striped cloak"),
                   new SetQuestAction(mithrilcloak.getQuestSlot(), "gave_striped_cloak")
                   )
        );

View Full Code Here

Examples of games.stendhal.server.entity.npc.action.DropItemAction

  private void step3returnBook() {
    final SpeakerNPC npc = npcs.get("Ceryl");

    /** Complete the quest */
    final List<ChatAction> reward = new LinkedList<ChatAction>();
    reward.add(new DropItemAction("black book"));
    reward.add(new EquipItemAction("money", 50));
    reward.add(new IncreaseXPAction(100));
    reward.add(new IncreaseKarmaAction(10.0));
    reward.add(new SetQuestAction(QUEST_SLOT, "done"));

View Full Code Here

Examples of games.stendhal.server.entity.npc.action.DropItemAction

        "Ok, I'll wait till mommy finds some helpers...",
        new SetQuestAndModifyKarmaAction(QUEST_SLOT, "rejected", -5.0));
   
    // Player has got chocolate bar and spoken to mummy
    final List<ChatAction> reward = new LinkedList<ChatAction>();
    reward.add(new DropItemAction("chocolate bar"));
    reward.add(new ChatAction() {
      public void fire(final Player player, final Sentence sentence, final EventRaiser npc) {
        // pick a random flower
        String rewardClass = Rand.rand(Arrays.asList("daisies","zantedeschia","pansy"));
       
View Full Code Here

Examples of games.stendhal.server.entity.npc.action.DropItemAction

        Arrays.asList("scissors", "magical", "magical scissors", "mithril", "cloak", "mithril cloak", "task", "quest"),
        new AndCondition(new QuestInStateCondition(mithrilcloak.getQuestSlot(), "got_scissors"), new PlayerHasItemWithHimCondition("magical scissors")),
        ConversationStates.ATTENDING,
        "You brought those magical scissors! Excellent! Now that I can cut the fabric I need a magical needle. You can buy one from a trader in the abandoned keep of Ados mountains, #Ritati Dragon something or other. Just go to him and ask for his 'specials'.",
        new MultipleActions(
                   new DropItemAction("magical scissors"),
                   new SetQuestAndModifyKarmaAction(mithrilcloak.getQuestSlot(), "need_needle;", 10.0),
                   new IncreaseXPAction(100)
                   )
        );
View Full Code Here

Examples of games.stendhal.server.entity.npc.action.DropItemAction

        ConversationPhrases.YES_MESSAGES,
        new PlayerHasItemWithHimCondition("money", NEEDLE_COST),
        ConversationStates.IDLE,
        "Ok, here you are. Be careful with them, they break easy. Now, get lost, you have hung around here far too long already.",       
        new MultipleActions(
          new DropItemAction("money", NEEDLE_COST),
          new EquipItemAction("magical needle", 1, true)
          ));

    // said he had money but he didn't
    npc.add(ConversationStates.QUEST_ITEM_QUESTION,
View Full Code Here

Examples of games.stendhal.server.entity.npc.action.DropItemAction

                needles = Rand.randUniform(1, 3);
              }
              player.setQuest(mithrilcloak.getQuestSlot(), "sewing;" + System.currentTimeMillis() + ";" + needles + ";" + saidjoke);
            }
          },
          new DropItemAction("magical needle")
          )
        );

    // remind about needle
    npc.add(ConversationStates.ATTENDING,
View Full Code Here

Examples of games.stendhal.server.entity.npc.action.DropItemAction

                new PlayerHasItemWithHimCondition("wood",10)),
        ConversationStates.ATTENDING,
        "Great, now I can make new arrows. But for the bows I need " +
        "bowstrings. Please go to #Karl. I know he has horses and if " +
        "you tell him my name he will give you  #'horse hairs' from a horsetail.",
        new MultipleActions(new SetQuestAndModifyKarmaAction(QUEST_SLOT, "hair", 2.0), new DropItemAction("wood", 10)));

    /*
     * For simplicity, respond to 'Karl' at any time.
     */
    npc.addReply("Karl", "Karl is a farmer, east of Semos. He has many pets on his farm.");
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.