Tabnine Logo
DynamicLocation.setDirection
Code IndexAdd Tabnine to your IDE (free)

How to use
setDirection
method
in
de.slikey.effectlib.util.DynamicLocation

Best Java code snippets using de.slikey.effectlib.util.DynamicLocation.setDirection (Showing top 3 results out of 315)

origin: Slikey/EffectLib

public void update() {
  if (location == null || (!updateLocation && !updateDirection)) {
    return;
  }
  Entity entityReference = entity == null ? null : entity.get();
  if (entityReference != null) {
    Location currentLocation = getEntityLocation(entityReference);
    if (updateDirection)
    {
      setDirection(currentLocation.getDirection());
    }
    if (updateLocation)
    {
      updateFrom(currentLocation);
    }
  }
}
origin: elBukkit/MagicPlugin

  protected void startProjectileEffects(CastContext context, String effectKey) {

    Collection<EffectPlayer> projectileEffects = context.getEffects(effectKey);
    for (EffectPlayer apiEffectPlayer : projectileEffects)
    {
      if (effectLocation == null) {
        effectLocation = new DynamicLocation(actionContext.getTargetLocation());
        effectLocation.setDirection(velocity);
      }
      if (activeProjectileEffects == null) {
        activeProjectileEffects = new ArrayList<>();
      }
      // Hrm- this is ugly, but I don't want the API to depend on EffectLib.
      if (apiEffectPlayer instanceof com.elmakers.mine.bukkit.effect.EffectPlayer)
      {
        com.elmakers.mine.bukkit.effect.EffectPlayer effectPlayer = (com.elmakers.mine.bukkit.effect.EffectPlayer)apiEffectPlayer;
        effectPlayer.setEffectPlayList(activeProjectileEffects);
        if (projectileEffectsUseTarget) {
          Entity sourceEntity = actionContext.getEntity();
          DynamicLocation sourceLocation = sourceEntity == null ? new DynamicLocation(actionContext.getLocation()) : new DynamicLocation(sourceEntity);
          effectPlayer.startEffects(sourceLocation, effectLocation);
        } else {
          effectPlayer.startEffects(effectLocation, null);
        }
      }
    }
  }
}
origin: elBukkit/MagicPlugin

effectLocation.setDirection(velocity);
de.slikey.effectlib.utilDynamicLocationsetDirection

Popular methods of DynamicLocation

  • <init>
  • addOffset
  • addRelativeOffset
  • getEntity
  • getLocation
  • updateFrom
  • getEntityLocation
  • hasValidEntity
  • setDirectionOffset
  • setPitch
  • setUpdateDirection
  • setUpdateLocation
  • setUpdateDirection,
  • setUpdateLocation,
  • setYaw,
  • update,
  • updateDirection,
  • updateOffsets

Popular in Java

  • Running tasks concurrently on multiple threads
  • setRequestProperty (URLConnection)
  • requestLocationUpdates (LocationManager)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • InputStream (java.io)
    A readable source of bytes.Most clients will use input streams that read data from the file system (
  • ArrayList (java.util)
    ArrayList is an implementation of List, backed by an array. All optional operations including adding
  • Executors (java.util.concurrent)
    Factory and utility methods for Executor, ExecutorService, ScheduledExecutorService, ThreadFactory,
  • Cipher (javax.crypto)
    This class provides access to implementations of cryptographic ciphers for encryption and decryption
  • Logger (org.slf4j)
    The org.slf4j.Logger interface is the main user entry point of SLF4J API. It is expected that loggin
  • SAXParseException (org.xml.sax)
    Encapsulate an XML parse error or warning.> This module, both source code and documentation, is in t
  • Top PhpStorm plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now