1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

Help undifined index

Discussion in 'Plugin Help' started by Mochi, May 21, 2020.

  1. Mochi

    Mochi Baby Zombie

    Messages:
    113
    17:59:31] [Server thread/CRITICAL]: ErrorException: "Undefined index: swmode" (EXCEPTION) in "plugins/SkyWars[0.1]/src/sw/Main" at line 122

    Code:
    PHP:
    public function join($player$mode "solo"$swmode "normal"){
            foreach(
    $this->arenas as $name => $arena){
                if(
    $arena->getData()["mode"] == $mode and $arena->getData()["swmode"] == $swmode){
                    if(
    $arena->join($player)){
                        return 
    true;
                    }
                }
            }
            return 
    false;
        }
     
  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.