001/*
002 * Trident - A Multithreaded Server Alternative
003 * Copyright 2014 The TridentSDK Team
004 *
005 * Licensed under the Apache License, Version 2.0 (the "License");
006 * you may not use this file except in compliance with the License.
007 * You may obtain a copy of the License at
008 *
009 *    http://www.apache.org/licenses/LICENSE-2.0
010 *
011 * Unless required by applicable law or agreed to in writing, software
012 * distributed under the License is distributed on an "AS IS" BASIS,
013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014 * See the License for the specific language governing permissions and
015 * limitations under the License.
016 */
017package net.tridentsdk.effect.potion;
018
019import net.tridentsdk.meta.nbt.NBTSerializable;
020
021/**
022 * Represents a potion effect with all the according values
023 *
024 * @author The TridentSDK Team
025 * @since 0.4-alpha
026 */
027public interface PotionEffect extends NBTSerializable {
028    /**
029     * Returns the effect type of this potion
030     * @return the effect type of this potion
031     */
032    PotionEffectType effectType();
033
034    /**
035     * Sets the effect type of this potion
036     * @param type the effect type you wish to set it to
037     */
038    void setEffectType(PotionEffectType type);
039
040    /**
041     * Returns the amplifier of this potion
042     * @return the amplifier of this potion
043     */
044    byte amplifier();
045
046    /**
047     * Sets the amplifier of the potion
048     * @param b the amp you wish to set it to
049     */
050    void setAmplifier(byte b);
051
052    /**
053     * Returns the duration of the potion, in ticks
054     * @return the duration of the potion in ticks
055     */
056    int duration();
057
058    /**
059     * Sets the duration of the potion, measured in ticks
060     * @param duration duration you wish to set it to
061     */
062    void setDuration(int duration);
063
064    /**
065     * Returns whether or not if the potion is ambient
066     * @return whether or not if the potion is ambient
067     */
068    boolean isAmbient();
069
070    /**
071     * Sets if the potion is ambient or not
072     */
073    void setAmbient(boolean ambient);
074
075    /**
076     * Returns whether the potion will show particles to the client
077     * @return whether the potion will show particles to the client
078     */
079    boolean showParticles();
080
081    /**
082     * Sets if the particles should show to the client
083     * @param showParticles if the particles should show to the client
084     */
085    void setShowParticles(boolean showParticles);
086}