How to give player effect and if it dies. the effect will not reset

Discussion in 'Development' started by AmlxP Modz, May 22, 2020 at 4:14 PM.

  1. AmlxP Modz

    AmlxP Modz Creeper

    Messages:
    2
    GitHub:
    amlxp
  2. Levi

    Levi Skeleton

    Messages:
    875
    GitHub:
    captainleviftw
    reapply the effect again
     
  3. aminozomty

    aminozomty Silverfish

    Messages:
    18
    GitHub:
    aminozomty
    you can use that it will help you
    PHP:
    public function onRespawn(PlayerRespawnEvent $event){
       
    $player $event->getPlayer();
       
    $effect Effect::getEffect(8);  //Effect::getEffect(effect id);
       
    $player->addEffect(new EffectInstance($effect9991)); 
    }
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.