Welcome to the RaGEZONE - MMORPG development forums.

[RP] Team Deathmatch [Sledmore]

This is a discussion on [RP] Team Deathmatch [Sledmore] within the Habbo Releases forums, part of the Habbo Hotel category; Hey guys, Well this isn't a really good release, But still, It's a simple event game for RP servers. Right, ...

Page 1 of 3 123 LastLast
Results 1 to 15 of 42
  1. #1
    Account Upgraded | Title Enabled!
    Rank
    Member +
    Join Date
    Jun 2009
    Posts
    956
    Liked
    230
    Gamertag: A Thick Cow Steam ID: Sledmore

    [RP] Team Deathmatch [Sledmore]

    Click
    Hey guys,

    Well this isn't a really good release, But still, It's a simple event game for RP servers.

    Right, I'm going to release different parts of it. The game is 'Team Deathmatch' :).

    Right, firstly, search for this;


    Code:
                                        //gets information from the database
    under it add this;

    Code:
     int blacktdm = dbClient.getInt("SELECT yellow_team FROM users WHERE name = '" + _Username + "'");
                                        int yellowtdm = dbClient.getInt("SELECT black_team FROM users WHERE name = '" + _Username + "'");
    Right, Search for this;

    Code:
                                                if (dead == 1)
                                                {
                                                    //sends user back to the hospital
                                                    sendData("D^" + "H" + Encoding.encodeVL64(2));
                                                    sendData("BK" + "You logged out while you were dead.\r\rTherefore you MUST reset your dead timer by using the folowing command:\r:deadtimer\r\rThis will restart your dead timer to where you left off last login.");
                                                    _Mission = "Dead";
                                                    refreshAppearance(false, true, true);
                                                }
                                            }
                                        }
    And under it add this;

    Code:
                                        else
                                        {
                                            if (blacktdm == 1)
                                            {
                                                _Mission = "Black Team - Team Death Match!";
                                                _Figure = _Uni + "ch-210-110.lg-281-110.sh-290-110";
                                                refreshAppearance(false, true, true);
    
                                                sendData("D^" + "H" + Encoding.encodeVL64(onloadroom));
                                                dbClient.runQuery("UPDATE users SET black_team = '1' WHERE name = '" + _Username + "'");
                                            }
                                            else if (yellowtdm == 1)
                                            {
                                                _Mission = "Yellow Team - Team Death Match!";
                                                _Figure = _Uni + "ch-210-93.lg-281-93.sh-290-93";
                                                refreshAppearance(false, true, true);
    
                                                sendData("D^" + "H" + Encoding.encodeVL64(onloadroom));
                                                dbClient.runQuery("UPDATE users SET yellow_team = '1' WHERE name = '" + _Username + "'");
                                            }
                                            else if (yellowtdm == 0 || blacktdm == 0)
                                            {
                                                sendData("D^" + "H" + Encoding.encodeVL64(onloadroom));
                                            }
                                        }
                                    }
                                    break;
                                }
    Then, on punch, on the default events, add this;

    Code:
                            if (User._Mission == "Yellow Team - Team Death Match!")
                            {
                                if (_Mission == "Black Team - Team Death Match!" || User._Mission == "Yellow Team - Team Death Match!")
                                {
                                    dbClient.runQuery("UPDATE users SET game_dm = game_dm + '10' WHERE name = '" + _Username + "'");
                                }
                                User.sendData("D^" + "H" + Encoding.encodeVL64(21));
                                User.sendData("BK" + "Thank you for playing team deathmatch.");
                                dbClient.runQuery("UPDATE users SET yellow_team = '0' WHERE name = '" + User._Username + "'");
                                dbClient.runQuery("UPDATE users SET black_team = '0' WHERE name = '" + User._Username + "'");
                                Room.sendShout(roomUser, "*Knocks out " + args[1] + ", sending them to the lobby*");
                            }
                            if (User._Mission == "Black Team - Team Death Match!")
                            {
                                if (_Mission == "Yellow Team - Team Death Match!" || User._Mission == "Black Team - Team Death Match!")
                                {
                                    dbClient.runQuery("UPDATE users SET game_dm = game_dm + '10' WHERE name = '" + _Username + "'");
                                }
                                User.sendData("D^" + "H" + Encoding.encodeVL64(21));
                                User.sendData("BK" + "Thank you for playing team deathmatch.");
                                dbClient.runQuery("UPDATE users SET yellow_team = '0' WHERE name = '" + User._Username + "'");
                                dbClient.runQuery("UPDATE users SET black_team = '0' WHERE name = '" + User._Username + "'");
    
                                Room.sendShout(roomUser, "*Knocks out " + args[1] + ", sending them to the lobby*");
                            }
    Here are some one way gates (;
    Note: You'll have to add a figure in here, as mine was all splits.


    Code:
                                            if (Item.Sprite == "one_way_door*8")
                                            {
                                                int isWorking;
                                                using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient())
                                                {
                                                    isWorking = dbClient.getInt("SELECT working FROM users WHERE name = '" + _Username + "'");
                                                }
    
                                                if (isWorking == 1)
                                                {
                                                    workLooper.Abort();
                                                    workLooper = null;
                                                }
    
                                                using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient())
                                                {
    
                                                    _Mission = "Black Team - Team Death Match!";
    
    
                                                    refreshAppearance(false, true, true);
    
                                                    dbClient.runQuery("UPDATE users SET black_team = '1' WHERE name = '" + _Username + "'");
                                                }
                                            }
    
                                            if (Item.Sprite == "one_way_door*9")
                                            {
                                                int isWorking;
                                                using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient())
                                                {
                                                    isWorking = dbClient.getInt("SELECT working FROM users WHERE name = '" + _Username + "'");
                                                }
    
                                                if (isWorking == 1)
                                                {
                                                    workLooper.Abort();
                                                    workLooper = null;
                                                }
    
                                                using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient())
                                                {
    
                                                    _Mission = "Yellow Team - Team Death Match!";
                                                    refreshAppearance(false, true, true);
    
                                                    dbClient.runQuery("UPDATE users SET yellow_team = '1' WHERE name = '" + _Username + "'");
                                                }
                                            }
    Right, here is the kickfromgame for staff above the rank 4.

    Code:
                        #region :kickfromgame (events)
                        case "kickfromgame":
                            {
                                if (_Rank > 4)
                                {
                                    virtualUser User = userManager.getUser(args[1]);
                                    {
                                        if (User._Mission == "[Game] Deathmatch" || User._Mission == "[Game] Brawl" || User._Mission == "Yellow Team - Team Death Match!" || User._Mission == "Black Team - Team Death Match!" || User._Mission == "Red Fighter - Arena Fight!" || User._Mission == "Blue Fighter - Arena Fight!")
                                        {
                                            using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient())
                                            {
                                                User.sendData("BK" + "Thank you for playing, You have been kicked from the game, By an administrator!");
                                                dbClient.runQuery("UPDATE users SET yellow_team = '0' WHERE name = '" + User._Username + "'");
                                                dbClient.runQuery("UPDATE users SET black_team = '0' WHERE name = '" + User._Username + "'");
                                                dbClient.runQuery("UPDATE users SET health = '100' WHERE name = '" + _Username + "'");
                                                User.sendData("D^" + "H" + Encoding.encodeVL64(21));
                                                User.refreshAppearance(true, true, true);
                                            }
                                        }
                                        else
                                        {
                                            sendData("BK" + "This user is not in a game!");
                                        }
                                    }
                                }
                                break;
                            }
                        #endregion
    And also, here is the :leavegame command!

    Code:
    #region :leavegame (events)
                        case "leavegame":
                            {
                                if (this._Mission == "[Game] Deathmatch" || this._Mission == "[Game] Brawl" || this._Mission == "Yellow Team - Team Death Match!" || this._Mission == "Black Team - Team Death Match!" || this._Mission == "Red Fighter - Arena Fight!" || this._Mission == "Blue Fighter - Arena Fight!")
                                {
                                    using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient())
                                    {
                                        sendData("BK" + "Thank you for playing, You have been sent to the events lobby!");
                                        dbClient.runQuery("UPDATE users SET yellow_team = '0' WHERE name = '" + _Username + "'");
                                        dbClient.runQuery("UPDATE users SET black_team = '0' WHERE name = '" + _Username + "'");
                                        dbClient.runQuery("UPDATE users SET health = '100' WHERE name = '" + _Username + "'");
                                        this.sendData("D^" + "H" + Encoding.encodeVL64(21));
                                        this.refreshAppearance(true, true, true);
                                    }
                                }
                                else
                                {
                                    sendData("BK" + "You are not in a game!");
                                }
                                break;
                            }
                        #endregion
    Right, You need to add in some collums in the user table, the two;

    yellow_team
    black_team


    both int 1, as defined = 0 (;

    I know this looks messy, But i never thought about releasing this, or improving.. If you would like to go do it!

    Thanks, Also, remember to click thanks if you like it. (;

    I'm sorry this isnt a really good tutorial to setting it up, but it's easy ;).


    Oh, one last thing, You'll need to do an SQL, for the gates :P.

    [EDIT]

    added SQL;

    Code:
    INSERT INTO `catalogue_items` (`tid`, `catalogue_name`, `catalogue_description`, `catalogue_cost`, `typeid`, `length`, `width`, `top`, `name_cct`, `colour`, `catalogue_id_page`, `door`, `tradeable`, `recycleable`, `catalogue_id_index`, `cip`, `cid`) VALUES
    (342543, 'Black teamdeath match gate', 'this one is used for team deathmatch!!', 5, 1, 1, 1, 0.00, 'one_way_door*8', '#525252,#ffffff,#525252', 100, '0', '1', '1', 20, 0, 0),
    (342544, 'Yellow teamdeath match gate', 'this one is used for team deathmatch!!', 5, 1, 1, 1, 0.00, 'one_way_door*9', '#FFD837,#ffffff,#FFD837', 100, '0', '1', '1', 20, 0, 0);
    Last edited by Sledmore; 09-10-10 at 12:02 PM.

  2. #2
    C# & Javascript
    Rank
    Member +
    Join Date
    Nov 2009
    Location
    Miami
    Posts
    304
    Liked
    22

    Re: [RP] Team Deathmatch [Sledmore]

    Nice one sledmore 10/10
    Learning C#

  3. #3
    Alpha Member
    Rank
    Alpha Member
    Join Date
    Oct 2007
    Posts
    2,713
    Liked
    675
    Gamertag: Cake Jake Bake

    Re: [RP] Team Deathmatch [Sledmore]

    Soon as i seen the name Sledmore i knew this would be good nice one sledy *Clicks the thanks button*

  4. #4
    Daiguren Hyōrinmaru
    Rank
    Member +
    Join Date
    Jul 2010
    Location
    Michigan, US
    Posts
    1,439
    Liked
    51
    Gamertag: jessietheboss

    Re: [RP] Team Deathmatch [Sledmore]

    Wow very nice 10/10 :D

  5. #5
    Iron like Lion in Zion!
    Rank
    Moderator
    Join Date
    Apr 2009
    Location
    Nassau, Bahamas
    Posts
    2,963
    Liked
    812
    Gamertag: SCREAM c9

    Re: [RP] Team Deathmatch [Sledmore]

    Everyone like forgot about the RPs?

    They backsided it, but its good to see that you still have time to do some roleplay releases.
    Take it easy,
    - vLife


  6. #6
    Account Upgraded | Title Enabled!
    Rank
    Member +
    Join Date
    Jun 2009
    Posts
    956
    Liked
    230
    Gamertag: A Thick Cow Steam ID: Sledmore

    Re: [RP] Team Deathmatch [Sledmore]

    Thank you guys, I'l most likely release other things, I have ;).


    Quote Originally Posted by vLife View Post
    Everyone like forgot about the RPs?

    They backsided it, but its good to see that you still have time to do some roleplay releases.

    Ya ikr, and Thanks :P.
    Last edited by Sledmore; 09-10-10 at 03:06 AM.

  7. #7
    Gone
    Rank
    Alpha Member
    Join Date
    Feb 2008
    Location
    Cuba
    Posts
    2,156
    Liked
    375

    Re: [RP] Team Deathmatch [Sledmore]

    Why don't you just do tinyint instead of int? then on C# do the int equivalent (in16 ? idfk)
    I've died. The person known as Moogly is no more.

  8. #8
    Member
    Rank
    Member
    Join Date
    Mar 2009
    Posts
    34
    Liked
    1

    Re: [RP] Team Deathmatch [Sledmore]

    df is a TinyInt?

  9. #9
    Account Upgraded | Title Enabled!
    Rank
    Member +
    Join Date
    Jun 2009
    Posts
    956
    Liked
    230
    Gamertag: A Thick Cow Steam ID: Sledmore

    Re: [RP] Team Deathmatch [Sledmore]

    Quote Originally Posted by Moogly View Post
    Why don't you just do tinyint instead of int? then on C# do the int equivalent (in16 ? idfk)
    Er, What's TinyInt? Thanks though, I'l try and figure what it is, and use it in the future ;).

    Quote Originally Posted by FreshKickzCobe View Post
    df is a TinyInt?
    I know right, I'm baffled too lol.

  10. #10
    || www.SUPER-Hotel.net ||
    Rank
    Member +
    Join Date
    Aug 2009
    Posts
    268
    Liked
    20

    Re: [RP] Team Deathmatch [Sledmore]

    is this Holograph or Uber ??

  11. #11
    Now 35% cooler!
    Rank
    Subscriber
    Join Date
    Oct 2008
    Location
    C:/
    Posts
    2,332
    Liked
    464
    Gamertag: The Livar

    Re: [RP] Team Deathmatch [Sledmore]

    Quote Originally Posted by Beny. View Post
    is this Holograph or Uber ??
    Holograph obviously, when in the Development section was there an ever UberRP?



    -|ivar

  12. #12
    || www.SUPER-Hotel.net ||
    Rank
    Member +
    Join Date
    Aug 2009
    Posts
    268
    Liked
    20

    Re: [RP] Team Deathmatch [Sledmore]

    Now, I have made an UberRP ...

  13. #13
    Account Upgraded | Title Enabled!
    Rank
    Member +
    Join Date
    Jun 2009
    Posts
    956
    Liked
    230
    Gamertag: A Thick Cow Steam ID: Sledmore

    Re: [RP] Team Deathmatch [Sledmore]

    Quote Originally Posted by Beny. View Post
    is this Holograph or Uber ??
    Holograph.

    Quote Originally Posted by Beny. View Post
    Now, I have made an UberRP ...
    Cool, Can I see it (;?

  14. #14
    Im Back!
    Rank
    Member +
    Join Date
    Sep 2010
    Posts
    524
    Liked
    77

    Re: [RP] Team Deathmatch [Sledmore]

    Very nice man.. 10/10!
    [SIGPIC][/SIGPIC]

  15. #15
    || www.SUPER-Hotel.net ||
    Rank
    Member +
    Join Date
    Aug 2009
    Posts
    268
    Liked
    20

    Re: [RP] Team Deathmatch [Sledmore]

    Sledmore, Its mine and PEjump2's :P
    Im making a thread now ...

 

 
Page 1 of 3 123 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •