Should finally completely fix problem where player location world changes in the middle of the /f home smoke effect, triggering an error from trying to calculate distance between worlds

also updated Spout API lib
This commit is contained in:
Brettflan 2012-03-19 01:28:06 -05:00
parent 345e18bf56
commit f3239cd9ed
2 changed files with 3 additions and 3 deletions

Binary file not shown.

View File

@ -76,6 +76,7 @@ public class CmdHome extends FCommand
}
Faction faction = Board.getFactionAt(new FLocation(me.getLocation()));
Location loc = me.getLocation().clone();
// if player is not in a safe zone or their own faction territory, only allow teleport if no enemies are nearby
if
@ -95,7 +96,6 @@ public class CmdHome extends FCommand
)
)
{
Location loc = me.getLocation();
World w = loc.getWorld();
double x = loc.getX();
double y = loc.getY();
@ -135,8 +135,8 @@ public class CmdHome extends FCommand
if (Conf.homesTeleportCommandSmokeEffectEnabled)
{
List<Location> smokeLocations = new ArrayList<Location>();
smokeLocations.add(me.getLocation());
smokeLocations.add(me.getLocation().clone().add(0, 1, 0));
smokeLocations.add(loc);
smokeLocations.add(loc.add(0, 1, 0));
smokeLocations.add(myFaction.getHome());
smokeLocations.add(myFaction.getHome().clone().add(0, 1, 0));
SmokeUtil.spawnCloudRandom(smokeLocations, 3f);