Undefined offset 1 ,help

Discussion in 'Plugin Help' started by Mochi, Jun 14, 2019.

  1. Mochi

    Mochi Spider Jockey

    Messages:
    37
    Code :
    PHP:
        public function onRun($ticks){
            
    $money $this->plugin->getServer()->getPluginManager()->getPlugin("EconomyAPI");
            
    $money_top $money->getAllMoney();
            
    arsort($money_top);
            
    $particle = new FloatingTextParticle(new Vector3($this->plugin->cf->get("x"), $this->plugin->cf->get("y"), $this->plugin->cf->get("z")), "    §9[§6TOPMONEY§9]\n §3".array_keys($money_top)[0]." §f: §d".$money_top[array_keys($money_top)[0]]. "$\n§3 ".array_keys($money_top)[1]." §f: §d".$money_top[array_keys($money_top)[1]]."$\n§3 ".array_keys($money_top)[2]." §f: §d".$money_top[array_keys($money_top)[2]]."$\n§3 ".array_keys($money_top)[3]." §f: §d".$money_top[array_keys($money_top)[3]]."$\n§3 ".array_keys($money_top)[4]." §f: §d".$money_top[array_keys($money_top)[4]]."$\n§3 ".array_keys($money_top)[5]." §f: §d".$money_top[array_keys($money_top)[5]]."$\n§3 ".array_keys($money_top)[6]." §f: §d".$money_top[array_keys($money_top)[6]]."$\n§3 ".array_keys($money_top)[7]." §f: §d".$money_top[array_keys($money_top)[7]]."$\n§3 ".array_keys($money_top)[8]." §f: §d".$money_top[array_keys($money_top)[8]]."$\n§3 ".array_keys($money_top)[9]." §f: §d".$money_top[array_keys($money_top)[9]]."$ §r");
            
    $this->player->getLevel()->addParticle($particle, [$this->player]);
        }
    }
     
  2. Mochi

    Mochi Spider Jockey

    Messages:
    37
    Screenshot
     

    Attached Files:

  3. ElLazer

    ElLazer Silverfish

    Messages:
    21
    GitHub:
    lazerdev
    Lemme take a look at your main at line 85.
     

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.