Merge pull request #70 in MIN/mineplex from Myst_TRICKORTREAT2 to master

* commit '1a6617bce1af68b0665323d59b956daf290ca91f':
  Changes.
This commit is contained in:
Shaun Bennett 2015-10-31 01:07:55 -05:00
commit bce439d0cf

View File

@ -50,36 +50,34 @@ public class TrickOrTreatManager extends MiniPlugin
private HashSet<String> _interacting = new HashSet<String>();
// private String[] _nextYear = new String[]
// {
// "Nosy kids...",
// "I'm out of candy!",
// "Come back next year.",
// "No double dipping!",
// "I've seen that costume before...",
// "You already have enough candy!",
// "Once is enough.",
// "Isn't it past your bedtime?",
// "I already gave you my candy, what more do you want!",
// "You again...",
// "I said no more!",
// "No taking the whole bowl.",
// "I have my eye on you...",
// "You know what happens to children who want more candy...",
// "This was a great year, wasn't it?",
// "Aww, did you come back just to talk to me?",
// "*heavy staring*",
// "Run along, now!",
// "The real horror will be your dentist's face...",
// "I've heard good things about the house down the road.",
// "I started out with 700 pieces!",
// "I might call it a night soon.",
// "Meow",
// "*heavy ninjaing*",
// "*heavy pandaing*",
// "Sure is a mystical night, isn't it?",
// "Do you want to hear my song? I wrote it myself!",
// };
private String[] _nextYear = new String[]
{
"Nosy kids...",
"I'm out of candy!",
"Come back next year.",
"No double dipping!",
"I've seen that costume before...",
"You already have enough candy!",
"Once is enough.",
"Isn't it past your bedtime?",
"I already gave you my candy, what more do you want!",
"You again...",
"I said no more!",
"No taking the whole bowl.",
"I have my eye on you...",
"You know what happens to children who want more candy...",
"This was a great year, wasn't it?",
"Aww, did you come back just to talk to me?",
"*heavy staring*",
"Run along, now!",
"The real horror will be your dentist's face...",
"I've heard good things about the house down the road.",
"I started out with 700 pieces!",
"I might call it a night soon.",
"Meow",
"Sure is a mystical night, isn't it?",
"Do you want to hear my song? I wrote it myself!",
};
public TrickOrTreatManager(JavaPlugin plugin, HubManager manager, TaskManager taskManager, DonationManager donationManager, CoreClientManager coreClientManager)
{
@ -146,8 +144,8 @@ public class TrickOrTreatManager extends MiniPlugin
public void run()
{
if (!_taskManager.hasCompletedTask(event.getPlayer(), task))
{
final boolean trick = UtilMath.r(10) > 4;
{
final boolean trick = UtilMath.r(10) > 5;
UtilPlayer.message(event.getPlayer(), C.cDGreenB + "You: " + C.cGreenB + "Trick or Treat!");
@ -241,20 +239,7 @@ public class TrickOrTreatManager extends MiniPlugin
}
else
{
try { Thread.sleep(500); } catch (Exception ex) { } //XXX
UtilPlayer.message(event.getPlayer(), C.cGoldB + villagerName + ": " + C.cYellowB + "Back for seconds, are we? Looks like someone needs another trick...");
try { Thread.sleep(750); } catch (Exception ex) { } //XXX
runSync(new Runnable()
{
@Override
public void run()
{
new Trick(event.getPlayer(), villagerName);
}
});
UtilPlayer.message(event.getPlayer(), C.cGoldB + villagerName + ": " + C.cYellowB + UtilMath.randomElement(_nextYear));
}
_interacting.remove(event.getPlayer().getName());