coolguy950 (10-24-2016),EHaehthsthethetheh (10-23-2016)
Step 1:
Go to WServer/Realm/Commands/AdminCommands.cs and find your spawn command
Step 2:
Find
And placeCode:{ player.SendInfo("Unknown entity!"); return false; }
If you want to have it so only a certain rank can do it do this insteadCode:if (name.ToLower().Contains("enemy here")) { player.SendError("Cannot spawn this object!"); return false; }
Step 3:Code:if ((name.ToLower().Contains("*Enemy Here*")) && Client.Account.Rank == *Rank Here*) { player.SendError("Cannot spawn this object!"); return false;
Rebuild Solution
coolguy950 (10-24-2016),EHaehthsthethetheh (10-23-2016)
instead of this.. (highlighted in red)
it should beCode:if ((name.ToLower().Contains("*Enemy Here*")) && Client.Account.Rank == *Rank Here*) { player.SendError("Cannot spawn this object!"); return false; }
The way you made it basically does this:Code:if ((name.ToLower().Contains("*Enemy Here*")) && Client.Account.Rank <= *Rank Here*)
Lets say you fill in *Enemy Here* with Medusa, and *Rank Here* with 5..
That means ONLY rank 5 can't spawn Medusa, but 1, 2, 3, 4 can still spawn it, so if you use <= 5, it will apply to rank 5 and everything below rank 5.
[MPGH]Ahl (10-24-2016)
News Force Head Editor from 09/14/2018 - 03/02/2020
Publicist from 11/23/2017 - 06/07/2019
Global Moderator since 09/24/2017
Minion+ from 04/16/2017 - 09/24/2017
Market Place Minion from 04/16/2017 - 09/24/2017
Minecraft Minion from 02/23/2017 - 09/24/2017
Realm of the Mad God Minion from 11/06/2016 - 09/24/2017
Middleman from 09/14/2016 - 09/24/2017
News Force Editor from 08/23/2016 - 09/14/2018
News Force (Section of the Week) from 03/21/2016 - 07/17/2017
News Force (User News) from 10/18/2015 - 09/14/2018
Donator since 03/16/2015
Realm of the Mad God Editor from 05/20/2014 - 07/08/2014
Member since 12/23/2012
Rep Power: 82
just do it multiple times
Example:
Or if you'd like it to be cleaner than thisCode:{ player.SendInfo("Unknown entity!"); return false; } if ((name.ToLower().Contains("*Enemy 1 Here*")) && Client.Account.Rank == *Rank Here*) { player.SendError("Cannot spawn this object!"); return false; if ((name.ToLower().Contains("*Enemy 2 Here*")) && Client.Account.Rank == *Rank Here*) { player.SendError("Cannot spawn this object!"); return false; if ((name.ToLower().Contains("*Enemy 3 Here*")) && Client.Account.Rank == *Rank Here*) { player.SendError("Cannot spawn this object!"); return false; if ((name.ToLower().Contains("*Enemy 4 Here*")) && Client.Account.Rank == *Rank Here*) { player.SendError("Cannot spawn this object!"); return false;
Code:if ((name.ToLower().Contains("*Enemy Here*" || "*Enemy Here*" || "*Enemy Here*")) && Client.Account.Rank == *Rank Here*) { player.SendError("Cannot spawn this object!"); return false;
Last edited by Spectre11; 10-24-2016 at 06:54 PM.
Nice work. For once somebody actually used a satisfying font color. You deserve a _bo_bo_!
Here you go:
Spectre11 (10-25-2016)