SolvedSkilly Realms Spawn arena command

Posts 1–13 of 13 · Page 1 of 1
Skilly Realms Spawn arena command
How can i add spawn arena command in skilly realms? , i tried it but it's not spawning the arena .
Quote Originally Posted by badboyallan123 View Post
How can i add spawn arena command in skilly realms? , i tried it but it's not spawning the arena .
1. what are u talking about

2. What are you talking about

if you mean like the /arena like how club source does it than look at club source's command and just translate it to what ever source ur using
Quote Originally Posted by badboyallan123 View Post
How can i add spawn arena command in skilly realms? , i tried it but it's not spawning the arena .
Google Translate, really, we don't understand what you need
Quote Originally Posted by Zolmex View Post
Google Translate, really, we don't understand what you need
obviously a /arena command which spawns the arena portal.
Should be able to spawn a portal just how the spawn command works with spawning stuff.
Code:
                    Entity entity = Entity.Resolve(player.Manager, object type of the portal goes here);
                    entity.Move(player.X, player.Y);
                    player.Owner.EnterWorld(entity);
Quote Originally Posted by Riigged View Post
Should be able to spawn a portal just how the spawn command works with spawning stuff.
Code:
                    Entity entity = Entity.Resolve(player.Manager, object type of the portal goes here);
                    entity.Move(player.X, player.Y);
                    player.Owner.EnterWorld(entity);
Where do i paste this to?,
Quote Originally Posted by RotmgSyahid View Post
Where do i paste this to?,
That is part of a command ( admincommand.cs is recommended )

The command summons what ever object type that you put in "object type of the portal goes here"

but thats not the complete command tho

you'd have to add the easy part to it, for it to work
Then where do i get the sarena command?

nvm i got it.i just dont know how to fix it..
Quote Originally Posted by RotmgSyahid View Post
Then where do i get the sarena command?

nvm i got it.i just dont know how to fix it..
Screen Shot? but i shouldn't be hard its very like much the spawn command
So the spawn command was actually from Project B/Realm Reso source @badboyallan123 also did the same thing, if you need the code here it is=

internal class ArenaCommand : Command
{
public ArenaCommand()
: base("sarena", 1)
{
}

protected override bool Process(Player player, RealmTime time, string[] args)
{


Entity entity = Entity.Resolve(player.Manager, 0x47a9);
World we = player.Manager.GetWorld(player.Owner.Id); //can't use Owner here, as it goes out of scope
int TimeoutTime = player.Manager.GameData.Portals[0x47a9].TimeoutTime;
string DungName = player.Manager.GameData.Portals[0x47a9].DungeonName;


entity.Move(player.X, player.Y);
we.EnterWorld(entity);

ARGB c = new ARGB(0xFF00FF);

TextPacket packet = new TextPacket
{
BubbleTime = 0,
Stars = -1,
Name = "",
Text = "A spawn arena has been opened by " + player.Name
};
player.Owner.BroadcastPacket(packet, null);
we.Timers.Add(new WorldTimer(TimeoutTime * 1000,
(world, t) => //default portal close time * 1000
{
try
{
we.LeaveWorld(entity);
}
catch (Exception ex)
//couldn't remove portal, Owner became null. Should be fixed with RealmManager implementation
{
log.ErrorFormat("Couldn't despawn portal.\n{0}", ex);
}
}));
return true;
}




And the error i get when using the command /sarena:

Client:


WServer:


PS:if the command is wrong,could you kindly fix it?
Quote Originally Posted by RotmgSyahid View Post
So th

PS:if the command is wrong,could you kindly fix it?
Code:
internal class ArenaCommand : Command
    {
        public ArenaCommand()
            : base("arena", 1)
        {
        }

        protected override bool Process(Player player, RealmTime time, string[] args)
        {
            Entity prtal = Entity.Resolve(player.Manager, "Abyss of Demons Portal");
            prtal.Move(player.X, player.Y);
            player.Owner.EnterWorld(prtal);
            World w = player.Manager.GetWorld(player.Owner.Id);
            w.Timers.Add(new WorldTimer(30 * 1000, (world, t) => 
            {
                try
                {
                    w.LeaveWorld(prtal);
                }
                catch 
                {
                    Console.Out.WriteLine("Shitz.");
                }
            }));
            foreach (Client i in player.Manager.Clients.Values)
                i.SendPacket(new TextPacket
                {
                    BubbleTime = 0,
                    Stars = -1,
                    Name = "",
                    Text = "Arena Opened"
                });
            foreach (Client i in player.Manager.Clients.Values)
                i.SendPacket(new NotificationPacket
                {
                    Color = new ARGB(0xff00ff00),
                    ObjectId = player.Id,
                    Text = "Arena Opened"
                });
            return true;
        }
    }
I got this off SD so its not my work
Quote Originally Posted by Demon View Post
Code:
internal class ArenaCommand : Command
    {
        public ArenaCommand()
            : base("arena", 1)
        {
        }

        protected override bool Process(Player player, RealmTime time, string[] args)
        {
            Entity prtal = Entity.Resolve(player.Manager, "Abyss of Demons Portal");
            prtal.Move(player.X, player.Y);
            player.Owner.EnterWorld(prtal);
            World w = player.Manager.GetWorld(player.Owner.Id);
            w.Timers.Add(new WorldTimer(30 * 1000, (world, t) => 
            {
                try
                {
                    w.LeaveWorld(prtal);
                }
                catch 
                {
                    Console.Out.WriteLine("Shitz.");
                }
            }));
            foreach (Client i in player.Manager.Clients.Values)
                i.SendPacket(new TextPacket
                {
                    BubbleTime = 0,
                    Stars = -1,
                    Name = "",
                    Text = "Arena Opened"
                });
            foreach (Client i in player.Manager.Clients.Values)
                i.SendPacket(new NotificationPacket
                {
                    Color = new ARGB(0xff00ff00),
                    ObjectId = player.Id,
                    Text = "Arena Opened"
                });
            return true;
        }
    }
I got this off SD so its not my work
mm
:c rip me
it opens abyss of demon
what should i rename that abyss? @Demon
I mean like how 2 create a arena portal.
Quote Originally Posted by RotmgSyahid View Post
mm
:c rip me
it opens abyss of demon
what should i rename that abyss? @Demon
I mean like how 2 create a arena portal.
To the name of your arena portal

//if you don't have an arena portal then make one ;p
Posts 1–13 of 13 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

None

Talk with us