PHP: ////////////////////////////// CHAT //////////////////////////////// if (strtolower($args[0]) == "chat" or strtolower($args[0]) == "c") { $sender->sendMessage($this->plugin->formatMessage("§aFaction chat disabled", true)); return true; if ($this->plugin->isInFaction($player)) { if (isset($this->plugin->factionChatActive[$player])) { unset($this->plugin->factionChatActive[$player]); $sender->sendMessage($this->plugin->formatMessage("§aFaction chat disabled", true)); return true; } else { $this->plugin->factionChatActive[$player] = 1; $sender->sendMessage($this->plugin->formatMessage("§aFaction chat enabled", true)); return true; } } else { $sender->sendMessage($this->plugin->formatMessage("You are not in a faction")); return true; } } if (strtolower($args[0]) == "allychat" or strtolower($args[0]) == "ac") { $sender->sendMessage($this->plugin->formatMessage("§aFaction chat disabled", true)); return true; if ($this->plugin->isInFaction($player)) { if (isset($this->plugin->allyChatActive[$player])) { unset($this->plugin->allyChatActive[$player]); $sender->sendMessage($this->plugin->formatMessage("§aAlly chat disabled", true)); return true; } else { $this->plugin->allyChatActive[$player] = 1; $sender->sendMessage($this->plugin->formatMessage("§aAlly chat enabled", true)); return true; } } else { $sender->sendMessage($this->plugin->formatMessage("You are not in a faction")); return true; } } } } } else { $this->plugin->getServer()->getLogger()->info($this->plugin->formatMessage("Please run command in game")); } }} How do u fix that everytime i use /f chat on my server it keep showing up /f chat is disabled please help i just use awzaw faction plugin to my server
Please dont put code that you dont understand into plugins it's just not a good idea when you dont even know if it even works, or what it does
Nope i added the chat format on the main then i tested first test it work it shows up in the game [TEST] Player: Hi then when i switched my device to NVIDIA SHIELD tab and transfer my files in it Now doesnt work it only shows the message /f chat is disabled
Look at what you are doing. Right after your first if statement, you are sending a faction chat disabled message regardless of anything else. Nothing else is executed because the command returns true before anything else can be run. The PHP function return has the same effect as break in this case. This isn't a PocketMine issue. Also, don't take code and paste it. It may help you once or twice, but you will benefit exponentially more when you write and understand it yourself.
LOL its from awzaw factions is use his plugin but i cant get the /f chat to work so thats why im asking how do u fix it......
The plugins wasn't made by Awzaw, it's a fork. It can't be 100% perfect, changes has to be done by the original author... This doesn't mean we can't fix it, we can by forking it and if it works, you can PR.
Watch your language, @jasonwynn10 was right, this thread should have been in facepalm section, and btw, please d'ont put titles to your thread such as "Please Help really need help on my plugin"