Static Lazer

Discussion in 'Plugin Development' started by MrJossy, Jun 22, 2015.

Thread Status:
Not open for further replies.
  1. Offline

    MrJossy

    Heya!

    Many of you problably play Mineplex. If you do, you may know the skill Static Lazer either from Sheep (SSM) or Mage in Champions. Anyways, if you don't know what I am talking about, I leave you an image right here :)

    http://prntscr.com/7k1oeh

    Ok. Now let's get to the thread. I want to make this but I have problems.

    1st. I cant do this with block iterator because as you can see in the print screen it creates a line of particles not a line of blocks filled with particles. (I've tried this. It won't work.).

    2nd. I don't know how to make this.

    So if anyone could help me, it would be great!

    Thanks for reading! :D
     
  2. Offline

    Zombie_Striker

    You wil l have to create a method which takes in where the player is looking and incrementing a number in one for loop (e.g. y = playersyaw * I). Look into players pitch and yaw.
     
  3. Offline

    MrJossy

    Could you give me an example?
     
  4. Offline

    Zombie_Striker

    public void particels(Player p){
    int x= p.getLocattion().getdirection().getx();
    int y= p.getLocattion().getdirection().gety();
    int z= p.getLocattion().getdirection().getz();
    int temp1;
    int temp2;
    int temp3;
    for(int i = 0; i < 50; i++){

    temp1 = p.getlocation().getx() +x*i;
    temp2 =p.getlocation().gety() y*i;
    temp3 =p.getlocation().getz() z*i;

    World#playEffect(particleEffect, new Location(x,y,z))
    }
    }
     
    MrJossy likes this.
Thread Status:
Not open for further replies.

Share This Page