forked from MagicBane/Server
return summon recycle timer when declined
This commit is contained in:
@@ -244,6 +244,10 @@ public enum PowersManager {
|
|||||||
if (playerCharacter == null)
|
if (playerCharacter == null)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
if(playerCharacter.getRecycleTimers().containsKey(msg.getPowerUsedID())){
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
boolean CSRCast = false;
|
boolean CSRCast = false;
|
||||||
|
|
||||||
if(msg.getPowerUsedID() == 430628895) {
|
if(msg.getPowerUsedID() == 430628895) {
|
||||||
@@ -1501,7 +1505,7 @@ public enum PowersManager {
|
|||||||
// Handle Accepting or Denying a summons.
|
// Handle Accepting or Denying a summons.
|
||||||
// set timer based on summon type.
|
// set timer based on summon type.
|
||||||
boolean wentThrough = false;
|
boolean wentThrough = false;
|
||||||
if (msg.accepted())
|
if (msg.accepted()) {
|
||||||
// summons accepted, let's move the player if within time
|
// summons accepted, let's move the player if within time
|
||||||
if (source.isAlive()) {
|
if (source.isAlive()) {
|
||||||
|
|
||||||
@@ -1565,7 +1569,10 @@ public enum PowersManager {
|
|||||||
timers.put("Summon", jc);
|
timers.put("Summon", jc);
|
||||||
wentThrough = true;
|
wentThrough = true;
|
||||||
}
|
}
|
||||||
|
}else{
|
||||||
|
// recycle summons power
|
||||||
|
finishRecycleTime(428523680, source, true);
|
||||||
|
}
|
||||||
// Summons failed
|
// Summons failed
|
||||||
if (!wentThrough)
|
if (!wentThrough)
|
||||||
// summons refused. Let's be nice and reset recycle timer
|
// summons refused. Let's be nice and reset recycle timer
|
||||||
|
|||||||
Reference in New Issue
Block a user