This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<link rel="import" href="../paper-toast/paper-toast.html"> | |
<link rel="import" href="../paper-button/paper-button.html"> | |
<link rel="import" href="../paper-tabs/paper-tab.html"> | |
<link rel="import" href="../paper-ripple/paper-ripple.html"> | |
<link rel="import" href="../topeka-elements/avatars.html"> | |
<link rel="import" href="../core-icon/core-icon.html"> | |
<link rel="import" href="../topeka-elements/theme.html"> | |
<link rel="import" href="../topeka-elements/topeka-resources.html"> | |
<link rel="import" href="../topeka-elements/topeka-categories.html"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<link rel="import" href="../core-scaffold/core-scaffold.html"> | |
<link rel="import" href="../core-header-panel/core-header-panel.html"> | |
<link rel="import" href="../core-menu/core-menu.html"> | |
<link rel="import" href="../core-item/core-item.html"> | |
<link rel="import" href="../core-icon-button/core-icon-button.html"> | |
<link rel="import" href="../core-toolbar/core-toolbar.html"> | |
<link rel="import" href="../core-menu/core-submenu.html"> | |
<polymer-element name="my-element"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import com.sun.xml.internal.ws.util.StringUtils; | |
import org.terasology.entitySystem.entity.EntityRef; | |
import org.terasology.entitySystem.systems.BaseComponentSystem; | |
import org.terasology.entitySystem.systems.RegisterSystem; | |
import org.terasology.logic.console.Command; | |
import org.terasology.logic.console.CommandParam; | |
import java.lang.reflect.Constructor; | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Copyright 2014 MovingBlocks | |
* | |
* Licensed under the Apache License, Version 2.0 (the "License"); | |
* you may not use this file except in compliance with the License. | |
* You may obtain a copy of the License at | |
* | |
* http://www.apache.org/licenses/LICENSE-2.0 | |
* | |
* Unless required by applicable law or agreed to in writing, software |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
We have two options for implementing the command parameter suggestion: | |
A) | |
The CommandParameterAdapter (https://github.com/Limeth/Terasology/blob/develop/engine/src/main/java/org/terasology/logic/console/internal/adapter/CommandParameterAdapter.java) would have a method returning all possible cases, while a CommandParam would accept a Predicate-like object filtering those cases. The filtered cases would then be suggested after being composed to Strings by the corresponding CommandParameterAdapter. | |
B) | |
The CommandParam would accept a 'suggestion' parameter of a class implementing an interface with a return type of Object[] or Collection<Object>. The returned values would then be suggested after being composed to Strings by the corresponding CommandParameterAdapter. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Command | |
public String tell(EntityRef sender, @CommandParam(value = "target", suggester = SUGGESTER_PLAYER) EntityRef target, String message) { | |
return "sent."; | |
} | |
private final Suggester SUGGESTER_PLAYER = new Suggester() { | |
public List<EntityRef> suggest() { | |
return /*all entityrefs of players*/; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Command | |
public String tell(EntityRef sender, @CommandParam(value = "target", suggester = SUGGESTER_PLAYER) EntityRef target, String message) { | |
return "sent."; | |
} | |
private class PlayerSuggester extends Suggester { | |
@Override | |
public List<EntityRef> suggest() { | |
return /*all entityrefs of players*/; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package cz.minestrike.me.limeth.minestrike.util; | |
import java.io.File; | |
import java.io.IOException; | |
import java.util.regex.Matcher; | |
import java.util.regex.Pattern; | |
import net.minecraft.server.v1_7_R4.EntityPlayer; | |
import net.minecraft.server.v1_7_R4.PacketPlayOutNamedSoundEffect; | |
import net.minecraft.server.v1_7_R4.PlayerConnection; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package cz.projectsurvive.limeth.hitboxbind.frames; | |
import cz.projectsurvive.limeth.hitboxbind.HitboxFrameParseException; | |
import cz.projectsurvive.limeth.hitboxbind.HitboxMedia; | |
import cz.projectsurvive.limeth.hitboxbind.util.ReadOnlyBinding; | |
import de.howaner.FramePicture.util.Frame; | |
import org.bukkit.Location; | |
import org.bukkit.block.BlockFace; | |
import java.awt.*; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package cz.minestrike.me.limeth.minestrike; | |
import java.io.File; | |
import java.io.FileReader; | |
import java.io.FileWriter; | |
import java.io.IOException; | |
import java.util.Properties; | |
import org.bukkit.Bukkit; | |
import org.bukkit.Location; |
OlderNewer