com.dongbat.invasion.buff.effects.Stun.java Source code

Java tutorial

Introduction

Here is the source code for com.dongbat.invasion.buff.effects.Stun.java

Source

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.dongbat.invasion.buff.effects;

import com.artemis.Entity;
import com.badlogic.gdx.math.Vector2;
import com.dongbat.invasion.buff.BuffEffect;
import com.dongbat.invasion.util.PhysicsUtil;

/**
 *
 * @author password
 */
public class Stun implements BuffEffect {

    @Override
    public void durationStart(Entity source, Entity target) {
        // do nothing
    }

    @Override
    public void update(Entity source, Entity target) {
        PhysicsUtil.setVelocity(target, Vector2.Zero);
    }

    @Override
    public void durationEnd(Entity source, Entity target) {
        // do nothing
    }

}