本文整理汇总了Java中de.slikey.effectlib.util.ParticleEffect.display方法的典型用法代码示例。如果您正苦于以下问题:Java ParticleEffect.display方法的具体用法?Java ParticleEffect.display怎么用?Java ParticleEffect.display使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类de.slikey.effectlib.util.ParticleEffect
的用法示例。
在下文中一共展示了ParticleEffect.display方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: showWithOffset
import de.slikey.effectlib.util.ParticleEffect; //导入方法依赖的package包/类
/**
* Show the specified amount of ParticleEffect at the location with
* random x, y, and z offsets in the range (0.5, 0.5).
* @param effect
* @param loc
*/
public static void showWithOffset(ParticleEffect effect, Location loc, double offsetMultiplier, int amount) {
float x = (float) (Math.random() * (Math.random() < 0.5 ? -offsetMultiplier : offsetMultiplier) * 0.5f);
float y = (float) (Math.random() * (Math.random() < 0.5 ? -offsetMultiplier : offsetMultiplier) * 0.5f);
float z = (float) (Math.random() * (Math.random() < 0.5 ? -offsetMultiplier : offsetMultiplier) * 0.5f);
effect.display(x, y, z, 0, amount, loc, 100);
}
示例2: show
import de.slikey.effectlib.util.ParticleEffect; //导入方法依赖的package包/类
public static void show(ParticleEffect effect, Location loc, int amount) {
effect.display(0, 0, 0, 0, amount, loc, 100);
}
示例3: showWithOffsetPositiveY
import de.slikey.effectlib.util.ParticleEffect; //导入方法依赖的package包/类
public static void showWithOffsetPositiveY(ParticleEffect effect, Location loc, double offsetMultiplier, int amount) {
float x = (float) (Math.random() * (Math.random() < 0.5 ? -offsetMultiplier : offsetMultiplier) * 0.5f);
float y = (float) (Math.random() * offsetMultiplier * 0.5f);
float z = (float) (Math.random() * (Math.random() < 0.5 ? -offsetMultiplier : offsetMultiplier) * 0.5f);
effect.display(x, y, z, 0, amount, loc, 100);
}
示例4: showWithSpeed
import de.slikey.effectlib.util.ParticleEffect; //导入方法依赖的package包/类
public static void showWithSpeed(ParticleEffect effect, Location loc, float speed, int amount) {
effect.display(0, 0, 0, speed, amount, loc, 100);
}
示例5: showWithData
import de.slikey.effectlib.util.ParticleEffect; //导入方法依赖的package包/类
public static void showWithData(ParticleEffect effect, Location loc, ParticleData data, int amount) {
effect.display(data, 0, 0, 0, 0, amount, loc, 100);
}
示例6: showWithDataAndOffset
import de.slikey.effectlib.util.ParticleEffect; //导入方法依赖的package包/类
public static void showWithDataAndOffset(ParticleEffect effect, Location loc, ParticleData data, int amount, double offsetX, double offsetY, double offsetZ) {
effect.display(data, (float) offsetX, (float) offsetY, (float) offsetZ, 0, amount, loc, 100);
}
示例7: display
import de.slikey.effectlib.util.ParticleEffect; //导入方法依赖的package包/类
protected void display(ParticleEffect particle, Location location, Color color, float speed, int amount) {
if (this.targetPlayer != null) particle.setTargetPlayer(this.targetPlayer);
particle.display(particle.getData(material, materialData), location, color, visibleRange, particleOffsetX, particleOffsetY, particleOffsetZ, speed, amount);
}