/[projects]/miscJava/bukkit-minecraft-plugins/HoerupUtils/src/main/java/dk/thoerup/bukkit/hoeruputils/SpawnCommand.java
ViewVC logotype

Diff of /miscJava/bukkit-minecraft-plugins/HoerupUtils/src/main/java/dk/thoerup/bukkit/hoeruputils/SpawnCommand.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1848 by torben, Sat Sep 22 14:58:13 2012 UTC revision 3201 by torben, Wed May 31 08:56:00 2017 UTC
# Line 1  Line 1 
1  package dk.thoerup.bukkit.hoeruputils;  package dk.thoerup.bukkit.hoeruputils;
2    
 import org.bukkit.ChatColor;  
3  import org.bukkit.Location;  import org.bukkit.Location;
 import org.bukkit.World;  
4  import org.bukkit.command.Command;  import org.bukkit.command.Command;
5  import org.bukkit.command.CommandExecutor;  import org.bukkit.command.CommandExecutor;
6  import org.bukkit.command.CommandSender;  import org.bukkit.command.CommandSender;
# Line 19  public class SpawnCommand implements Com Line 17  public class SpawnCommand implements Com
17    
18                  Player p = (Player) sender;                  Player p = (Player) sender;
19                  Location spawn = p.getLocation().getWorld().getSpawnLocation();                  Location spawn = p.getLocation().getWorld().getSpawnLocation();
20                    int clearY = spawn.getWorld().getHighestBlockYAt( spawn );
21                    spawn.setY( clearY );
22    
23    
24                  p.teleport( spawn );                  p.teleport( spawn );

Legend:
Removed from v.1848  
changed lines
  Added in v.3201

  ViewVC Help
Powered by ViewVC 1.1.20