Help gm commands

Mu online season 21 - grand opening

paulxplan

Dedicated Member
Dedicated Member
May 29, 2013
62
4
35
hi guys, just wondering why (@goto name) not working on zircon files? ive seen that in the list on here the @grouprecall is the other way around is there another command for goto?

cheers
 
  • Like
Reactions: trancefied

trancefied

Loyal Member
Loyal Member
May 16, 2020
208
77
40
changes to its code needs to be done, this should work fine.

Code:
namespace Server.Envir.Commands.Command.Admin
{
class Goto : AbstractParameterizedCommand<IAdminCommand>
{
public override string VALUE => "GOTO";
public override int PARAMS_LENGTH => 2;

public override void Action(PlayerObject player, string[] vals)
{
if (vals.Length < PARAMS_LENGTH)
{

throw new Exception($"Syntax: @GOTO <Playername>");
}

string targetName = vals[1];

PlayerObject targetPlayer = SEnvir.GetPlayerByCharacter(targetName);

if (targetPlayer == null)
{

throw new Exception($"Player '{targetName}' could not be found.");
}




player.Teleport(targetPlayer.CurrentMap, targetPlayer.CurrentLocation);
}
}
}
 
  • Like
Reactions: Hwarang
Upvote 0