Results 1 to 6 of 6
  1. #1
    ManKindGaming's Avatar
    Join Date
    May 2017
    Gender
    male
    Posts
    126
    Reputation
    10
    Thanks
    15
    My Mood
    Sad

    DC From XP Room once lvl 20. [FSOD]

    Hello I was wondering how I would make a user DC from a XP Room once hitting level 20, I have done this before but cannot remember how all I remember is that I did it in the XPROOM.cs file,
    Here is my current file...

    Code:
    namespace wServer.realm.worlds
    {
        public class XPRoom : World
        {
            public XPRoom()
            {
                Name = "XPRoom";
                ClientWorldName = "XP Room";
                Background = 0;
                AllowTeleport = false;
            }
    
            protected override void Init()
            {
                LoadMap("wServer.realm.worlds.maps.XPROOM.jm", MapType.Json);
            }
        }
    }

  2. #2
    MikeRaarupBirk's Avatar
    Join Date
    Mar 2016
    Gender
    male
    Posts
    1,583
    Reputation
    38
    Thanks
    3,775
    My Mood
    Stressed
    Quote Originally Posted by ManKindGaming View Post
    Hello I was wondering how I would make a user DC from a XP Room once hitting level 20, I have done this before but cannot remember how all I remember is that I did it in the XPROOM.cs file,
    Here is my current file...


    Code:
    namespace wServer.realm.worlds
    {
        public class XPRoom : World
        {
            public XPRoom()
            {
                Name = "XPRoom";
                ClientWorldName = "XP Room";
                Background = 0;
                AllowTeleport = false;
            }
    
            protected override void Init()
            {
                LoadMap("wServer.realm.worlds.maps.XPROOM.jm", MapType.Json);
            }
        }
    }
    try this:

    Code:
    namespace wServer.realm.worlds
    {
        public class XPRoom : World
        {
            public XPRoom()
            {
                Name = "XPRoom";
                ClientWorldName = "XP Room";
                Background = 0;
                AllowTeleport = false;
            }
    
            protected override void Init()
            {
                LoadMap("wServer.realm.worlds.maps.XPROOM.jm", MapType.Json);
            }
    
            private Client client;
            public override void Tick()
            {
                if (client.Player.Level == 20)
                {
                    client.Disconnect();
                }
            }
        }
    }

  3. #3
    ManKindGaming's Avatar
    Join Date
    May 2017
    Gender
    male
    Posts
    126
    Reputation
    10
    Thanks
    15
    My Mood
    Sad
    @Raple, @Ahlwong, Solved!
    Last edited by ManKindGaming; 07-31-2017 at 10:39 AM.

  4. #4
    Riigged's Avatar
    Join Date
    Jan 2013
    Gender
    male
    Location
    no
    Posts
    3,846
    Reputation
    401
    Thanks
    10,254
    My Mood
    Devilish
    why not just remove the "xp room" and have your players spawn into the game already as a level 20?
    i mean, its pretty much the same thing, them going into the xp room and sitting there for 5 minutes for a free level 20, might as well just give it to them to begin with

    xp room/handing out levels is bad for your server imo js.

     








  5. #5
    ManKindGaming's Avatar
    Join Date
    May 2017
    Gender
    male
    Posts
    126
    Reputation
    10
    Thanks
    15
    My Mood
    Sad
    Quote Originally Posted by Riigged View Post
    why not just remove the "xp room" and have your players spawn into the game already as a level 20?
    i mean, its pretty much the same thing, them going into the xp room and sitting there for 5 minutes for a free level 20, might as well just give it to them to begin with

    xp room/handing out levels is bad for your server imo js.
    Because it is an optional choice, and also the XP Room is just a cool addon. (I also make the chickens have a chance to drop farm eggs.)

  6. #6
    Anime's Avatar
    Join Date
    Jul 2017
    Gender
    male
    Posts
    988
    Reputation
    42
    Thanks
    170
    Would this require you to create XPRoom.cs?

    - - - Updated - - -

    Because, for now, I don't have that lol. I have a map without the XPRoom.cs for some reason.

Similar Threads

  1. Replies: 10
    Last Post: 12-14-2013, 03:18 PM
  2. [Tutorial] Kick Players From Mummy Rooms
    By kjsheng999 in forum Mission Against Terror Hacks & Cheats
    Replies: 45
    Last Post: 11-21-2012, 02:23 AM
  3. [Release] Please Give Link In This Tread Kick Players From Mummy Rooms!
    By hafiz22 in forum Mission Against Terror Hacks & Cheats
    Replies: 3
    Last Post: 11-19-2012, 04:37 AM
  4. Glitch room/Pwl lvl room :D
    By zlavik in forum Combat Arms Glitches
    Replies: 10
    Last Post: 08-08-2009, 08:34 PM
  5. Glitch room/Pwl lvl room/100% win fireteam room
    By zlavik in forum Combat Arms Hacks & Cheats
    Replies: 5
    Last Post: 08-08-2009, 03:14 AM