Menu
Forums
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Trending
What's new
New posts
New profile posts
Latest activity
Members
Current visitors
New profile posts
Search profile posts
Upgrades
Log in
Register
What's new
Search
Search
Search titles only
By:
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
Server Development
Habbo Retros
Habbo Tutorials
DeltaCMS Edited By Mack-xoa!!
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="devine" data-source="post: 90202" data-attributes="member: 7443"><p>This is RP by da way if u know wat tht is its a comand to summon a bolt of lighting stunning somone and causing atleast 24 damage <img src="/styles/default/xenforo/smilies/emojione/smile.png" class="smilie" loading="lazy" alt=":)" title="Smile :)" data-shortname=":)" /> hope u like it</p><p> </p><p> </p><p>#region :lightning <user> & :uncuff <user></p><p> case "stun": // Freeze the specified user</p><p> </p><p> virtualUser User = userManager.getUser(args[1]);</p><p> if (User._roomID == _roomID && (roomUser.Y + 1 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y + 2 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y - 2 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X + 2 == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X - 2 == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y + 2 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y - 2 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y + 2 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y - 2 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X + 2 == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X - 2 == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X + 2 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X - 2 == User.roomUser.X) || (roomUser.Y + 2 == User.roomUser.Y && roomUser.X - 2 == User.roomUser.X) || (roomUser.Y - 2 == User.roomUser.Y && roomUser.X + 2 == User.roomUser.X) || (roomUser.Y + 2 == User.roomUser.Y && roomUser.X + 2 == User.roomUser.X) || (roomUser.Y - 2 == User.roomUser.Y && roomUser.X - 2 == User.roomUser.X))</p><p> {</p><p> /*</p><p> if (roomUser.walkLock == true)</p><p> {</p><p> sendData("BK" + "Nice try, but you are either stunned or cuffed.");</p><p> }</p><p> else</p><p> {</p><p> if (punchCdLooper != null)</p><p> {</p><p> Room.sendSaying(roomUser, "(cooldown)");</p><p> }</p><p> else</p><p> {</p><p> int isArrested;</p><p> using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient())</p><p> {</p><p> isArrested = dbClient.getInt("SELECT arrested FROM users WHERE name = '" + _Username + "'");</p><p> }</p><p> if (isArrested < 1)</p><p> {</p><p> virtualUser User = userManager.getUser(args[1]);</p><p> if (User._roomID == _roomID && (roomUser.Y == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X))</p><p> {</p><p> string health_db;</p><p> string str_db;</p><p> int health_db_ko;</p><p> int canHit;</p><p> </p><p> //db queries</p><p> using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient())</p><p> {</p><p> canHit = dbClient.getInt("SELECT violence FROM rooms WHERE id = '" + _roomID + "'");</p><p> health_db = dbClient.getString("SELECT health FROM users WHERE name = '" + User._Username + "'");</p><p> str_db = dbClient.getString("SELECT str FROM users WHERE name = '" + _Username + "'");</p><p> }</p><p> </p><p> if (canHit == 1)</p><p> {</p><p> return false;</p><p> }</p><p> </p><p> //db queries</p><p> using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient())</p><p> {</p><p> health_db_ko = dbClient.getInt("SELECT health FROM users WHERE name = '" + User._Username + "'");</p><p> int getHit = health_db_ko - 1;</p><p> if (getHit > health_db_ko)</p><p> {</p><p> sendData("BK" + "Sorry, but you can not knock yourself out.");</p><p> return false;</p><p> }</p><p> else</p><p> {</p><p> dbClient.runQuery("UPDATE users SET health = health - '1' WHERE name = '" + User._Username + "'");</p><p> }</p><p> }</p><p> Room.sendShout(roomUser, "*Sticks with lighting " + args[1] + ", causing 30 damage*");</p><p> int health_int = health_db_ko;</p><p> </p><p> ThreadStart punchCdStarter = new ThreadStart(punchCoolDown);</p><p> punchCdLooper = new Thread(punchCdStarter);</p><p> punchCdLooper.Priority = ThreadPriority.Lowest;</p><p> punchCdLooper.Start();</p><p> </p><p> //if the user has 0 or less helth left</p><p> if (health_int < 1)</p><p> {</p><p> User.sendData("D^" + "H" + Encoding.encodeVL64(153));</p><p> User.sendData("BK" + "You have been knocked out by another user and sent to the hospital.");</p><p> Room.sendShout(roomUser, "*Knocks out " + args[1] + ", sending them to the hospital*");</p><p> using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient())</p><p> {</p><p> dbClient.runQuery("UPDATE users SET health = '100' WHERE name = '" + User._Username + "'");</p><p> dbClient.runQuery("UPDATE users SET kills = kills + 1 WHERE name = '" + _Username + "'");</p><p> dbClient.runQuery("UPDATE users SET deaths = deaths + 1 WHERE name = '" + User._Username + "'");</p><p> }</p><p> ThreadStart koStarter = new ThreadStart(knockOut);</p><p> deadLooper = new Thread(koStarter);</p><p> deadLooper.Priority = ThreadPriority.Lowest;</p><p> User.deadLooper.Start();</p><p> User.roomUser.walkLock = true;</p><p> }</p><p> }</p><p> else</p><p> {</p><p> if (User._roomID == _roomID && (roomUser.Y + 1 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X))</p><p> {</p><p> Room.sendShout(roomUser, "*Swings at " + args[1] + ", but misses*");</p><p> }</p><p> //else</p><p> //{</p><p> // Room.sendSaying(roomUser, "*Swings at " + args[1] + ", but misses*");</p><p> //}</p><p> }</p><p> </p><p> int _userID = userManager.getUserID(args[1]);</p><p> virtualUser Target = userManager.getUser(_userID);</p><p> Target.roomUser.walkLock = true; // Freeze the user</p><p> Room.sendSaying(roomUser, "*I SUMMON LIGHTING ON " + Target._Username + "*");</p><p> </p><p> #endregion</p><p> </p><p> #region <img src="/styles/default/xenforo/smilies/emojione/tongue.png" class="smilie" loading="lazy" alt=":p" title="Stick Out Tongue :p" data-shortname=":p" />unch <user></p><p> case "punch":</p><p> case "hit":</p><p> {</p><p> using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient())</p><p> {</p><p> virtualUser User = userManager.getUser(args[1]);</p><p> if (User._roomID != _roomID)</p><p> break;</p><p> </p><p> if (roomUser.walkLock == true)</p><p> {</p><p> sendData("BK" + "Nice try, but you are either stunned or cuffed.");</p><p> break;</p><p> }</p><p> </p><p> if (punchCdLooper != null)</p><p> {</p><p> Room.sendWhisper(roomUser, _Username, "*attempts to swing at " + User._Username + ", but is too exhausted*");</p><p> break;</p><p> }</p><p> </p><p> int isArrested = dbClient.getInt("SELECT arrested FROM users WHERE name = '" + _Username + "'");</p><p> int canHit = dbClient.getInt("SELECT violence FROM rooms WHERE id = '" + _roomID + "'");</p><p> int isAfk = dbClient.getInt("SELECT afk FROM users WHERE name = '" + User._Username + "'");</p><p> if (isAfk == 1)</p><p> {</p><p> sendData("BK" + "Sorry, but this user is AFK.");</p><p> break;</p><p> }</p><p> </p><p> if (isArrested < 1)</p><p> {</p><p> if (canHit == 1)</p><p> {</p><p> sendData("BK" + "Sorry, but this room has been declared a no fighting zone.");</p><p> break;</p><p> }</p><p> </p><p> if (User._roomID == _roomID && (roomUser.Y == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X))</p><p> {</p><p> //db queries</p><p> int myHealth = dbClient.getInt("SELECT health FROM users WHERE name = '" + User._Username + "'");</p><p> int str_mod = dbClient.getInt("SELECT str FROM users WHERE name = '" + _Username + "'");</p><p> </p><p> //generates a random number</p><p> Random randNum = new Random();</p><p> int hit_dif_0 = randNum.Next(1, 3);</p><p> int hit_dif_1 = randNum.Next(1, 13);</p><p> </p><p> //what a user hits</p><p> int hit = str_mod * hit_dif_0 + hit_dif_1;</p><p> </p><p> int getHit = myHealth - hit;</p><p> if (getHit < 1 && _Username == User._Username)</p><p> {</p><p> sendData("BK" + "Sorry, but you can not knock yourself out.");</p><p> }</p><p> else</p><p> {</p><p> dbClient.runQuery("UPDATE users SET health = health - '" + hit + "' WHERE name = '" + User._Username + "'");</p><p> dbClient.runQuery("UPDATE users SET hits = hits + 1 WHERE name = '" + _Username + "'");</p><p> int health_db_ko = dbClient.getInt("SELECT health FROM users WHERE name = '" + User._Username + "'");</p><p> Room.sendShout(roomUser, "*Swings at " + args[1] + ", causing " + hit + " damage*");</p><p> </p><p> ThreadStart punchCdStarter = new ThreadStart(punchCoolDown);</p><p> punchCdLooper = new Thread(punchCdStarter);</p><p> punchCdLooper.Priority = ThreadPriority.Lowest;</p><p> punchCdLooper.Start();</p><p> </p><p> //if the user has 0 or less helth left</p><p> if (health_db_ko < 1)</p><p> {</p><p> if (User._Mission == "[Game] Brawl")</p><p> {</p><p> Room.sendShout(roomUser, "*Knocks out " + args[1] + ", sending them to the lobby*");</p><p> if (User._Mission == "[Game] Brawl")</p><p> {</p><p> if (_Mission == "[Game] Brawl")</p><p> {</p><p> dbClient.runQuery("UPDATE users SET game_brawl = game_brawl + '10' WHERE name = '" + _Username + "'");</p><p> }</p><p> User.sendData("D^" + "H" + Encoding.encodeVL64(10));</p><p> User.sendData("BK" + "Thank you for playing brawl.");</p><p> }</p><p> User.refreshAppearance(true, true, true);</p><p> dbClient.runQuery("UPDATE users SET health = '100' WHERE name = '" + User._Username + "'");</p><p> }</p><p> else</p><p> {</p><p> User.sendData("D^" + "H" + Encoding.encodeVL64(2));</p><p> User.sendData("BK" + "You have been knocked out by another user and sent to the hospital.");</p><p> Room.sendShout(roomUser, "*Knocks out " + args[1] + ", sending them to the hospital*");</p><p> dbClient.runQuery("UPDATE users SET kills = kills + 1 WHERE name = '" + _Username + "'");</p><p> dbClient.runQuery("UPDATE users SET deaths = deaths + 1, time_dead = '10' WHERE name = '" + User._Username + "'");</p><p> User._Mission = "Dead";</p><p> User._DeathTimer = 10;</p><p> </p><p> refreshAppearance(true, true, true);</p><p> </p><p> ThreadStart koStarter = new ThreadStart(User.knockOut);</p><p> User.deadLooper = new Thread(koStarter);</p><p> User.deadLooper.Priority = ThreadPriority.Lowest;</p><p> User.deadLooper.Start();</p><p> </p><p> User.roomUser.walkLock = true;</p><p> }</p><p> }</p><p> }</p><p> }</p><p> else</p><p> {</p><p> if (User._roomID == _roomID && (roomUser.Y + 1 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X))</p><p> {</p><p> Room.sendShout(roomUser, "*Swings at " + args[1] + ", but misses*");</p><p> }</p><p> }</p><p> }</p><p> }</p><p> break;</p><p> }</p><p> #endregion</p></blockquote><p></p>
[QUOTE="devine, post: 90202, member: 7443"] This is RP by da way if u know wat tht is its a comand to summon a bolt of lighting stunning somone and causing atleast 24 damage :) hope u like it #region :lightning <user> & :uncuff <user> case "stun": // Freeze the specified user virtualUser User = userManager.getUser(args[1]); if (User._roomID == _roomID && (roomUser.Y + 1 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y + 2 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y - 2 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X + 2 == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X - 2 == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y + 2 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y - 2 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y + 2 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y - 2 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X + 2 == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X - 2 == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X + 2 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X - 2 == User.roomUser.X) || (roomUser.Y + 2 == User.roomUser.Y && roomUser.X - 2 == User.roomUser.X) || (roomUser.Y - 2 == User.roomUser.Y && roomUser.X + 2 == User.roomUser.X) || (roomUser.Y + 2 == User.roomUser.Y && roomUser.X + 2 == User.roomUser.X) || (roomUser.Y - 2 == User.roomUser.Y && roomUser.X - 2 == User.roomUser.X)) { /* if (roomUser.walkLock == true) { sendData("BK" + "Nice try, but you are either stunned or cuffed."); } else { if (punchCdLooper != null) { Room.sendSaying(roomUser, "(cooldown)"); } else { int isArrested; using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient()) { isArrested = dbClient.getInt("SELECT arrested FROM users WHERE name = '" + _Username + "'"); } if (isArrested < 1) { virtualUser User = userManager.getUser(args[1]); if (User._roomID == _roomID && (roomUser.Y == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X)) { string health_db; string str_db; int health_db_ko; int canHit; //db queries using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient()) { canHit = dbClient.getInt("SELECT violence FROM rooms WHERE id = '" + _roomID + "'"); health_db = dbClient.getString("SELECT health FROM users WHERE name = '" + User._Username + "'"); str_db = dbClient.getString("SELECT str FROM users WHERE name = '" + _Username + "'"); } if (canHit == 1) { return false; } //db queries using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient()) { health_db_ko = dbClient.getInt("SELECT health FROM users WHERE name = '" + User._Username + "'"); int getHit = health_db_ko - 1; if (getHit > health_db_ko) { sendData("BK" + "Sorry, but you can not knock yourself out."); return false; } else { dbClient.runQuery("UPDATE users SET health = health - '1' WHERE name = '" + User._Username + "'"); } } Room.sendShout(roomUser, "*Sticks with lighting " + args[1] + ", causing 30 damage*"); int health_int = health_db_ko; ThreadStart punchCdStarter = new ThreadStart(punchCoolDown); punchCdLooper = new Thread(punchCdStarter); punchCdLooper.Priority = ThreadPriority.Lowest; punchCdLooper.Start(); //if the user has 0 or less helth left if (health_int < 1) { User.sendData("D^" + "H" + Encoding.encodeVL64(153)); User.sendData("BK" + "You have been knocked out by another user and sent to the hospital."); Room.sendShout(roomUser, "*Knocks out " + args[1] + ", sending them to the hospital*"); using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient()) { dbClient.runQuery("UPDATE users SET health = '100' WHERE name = '" + User._Username + "'"); dbClient.runQuery("UPDATE users SET kills = kills + 1 WHERE name = '" + _Username + "'"); dbClient.runQuery("UPDATE users SET deaths = deaths + 1 WHERE name = '" + User._Username + "'"); } ThreadStart koStarter = new ThreadStart(knockOut); deadLooper = new Thread(koStarter); deadLooper.Priority = ThreadPriority.Lowest; User.deadLooper.Start(); User.roomUser.walkLock = true; } } else { if (User._roomID == _roomID && (roomUser.Y + 1 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X)) { Room.sendShout(roomUser, "*Swings at " + args[1] + ", but misses*"); } //else //{ // Room.sendSaying(roomUser, "*Swings at " + args[1] + ", but misses*"); //} } int _userID = userManager.getUserID(args[1]); virtualUser Target = userManager.getUser(_userID); Target.roomUser.walkLock = true; // Freeze the user Room.sendSaying(roomUser, "*I SUMMON LIGHTING ON " + Target._Username + "*"); #endregion #region :punch <user> case "punch": case "hit": { using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient()) { virtualUser User = userManager.getUser(args[1]); if (User._roomID != _roomID) break; if (roomUser.walkLock == true) { sendData("BK" + "Nice try, but you are either stunned or cuffed."); break; } if (punchCdLooper != null) { Room.sendWhisper(roomUser, _Username, "*attempts to swing at " + User._Username + ", but is too exhausted*"); break; } int isArrested = dbClient.getInt("SELECT arrested FROM users WHERE name = '" + _Username + "'"); int canHit = dbClient.getInt("SELECT violence FROM rooms WHERE id = '" + _roomID + "'"); int isAfk = dbClient.getInt("SELECT afk FROM users WHERE name = '" + User._Username + "'"); if (isAfk == 1) { sendData("BK" + "Sorry, but this user is AFK."); break; } if (isArrested < 1) { if (canHit == 1) { sendData("BK" + "Sorry, but this room has been declared a no fighting zone."); break; } if (User._roomID == _roomID && (roomUser.Y == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X)) { //db queries int myHealth = dbClient.getInt("SELECT health FROM users WHERE name = '" + User._Username + "'"); int str_mod = dbClient.getInt("SELECT str FROM users WHERE name = '" + _Username + "'"); //generates a random number Random randNum = new Random(); int hit_dif_0 = randNum.Next(1, 3); int hit_dif_1 = randNum.Next(1, 13); //what a user hits int hit = str_mod * hit_dif_0 + hit_dif_1; int getHit = myHealth - hit; if (getHit < 1 && _Username == User._Username) { sendData("BK" + "Sorry, but you can not knock yourself out."); } else { dbClient.runQuery("UPDATE users SET health = health - '" + hit + "' WHERE name = '" + User._Username + "'"); dbClient.runQuery("UPDATE users SET hits = hits + 1 WHERE name = '" + _Username + "'"); int health_db_ko = dbClient.getInt("SELECT health FROM users WHERE name = '" + User._Username + "'"); Room.sendShout(roomUser, "*Swings at " + args[1] + ", causing " + hit + " damage*"); ThreadStart punchCdStarter = new ThreadStart(punchCoolDown); punchCdLooper = new Thread(punchCdStarter); punchCdLooper.Priority = ThreadPriority.Lowest; punchCdLooper.Start(); //if the user has 0 or less helth left if (health_db_ko < 1) { if (User._Mission == "[Game] Brawl") { Room.sendShout(roomUser, "*Knocks out " + args[1] + ", sending them to the lobby*"); if (User._Mission == "[Game] Brawl") { if (_Mission == "[Game] Brawl") { dbClient.runQuery("UPDATE users SET game_brawl = game_brawl + '10' WHERE name = '" + _Username + "'"); } User.sendData("D^" + "H" + Encoding.encodeVL64(10)); User.sendData("BK" + "Thank you for playing brawl."); } User.refreshAppearance(true, true, true); dbClient.runQuery("UPDATE users SET health = '100' WHERE name = '" + User._Username + "'"); } else { User.sendData("D^" + "H" + Encoding.encodeVL64(2)); User.sendData("BK" + "You have been knocked out by another user and sent to the hospital."); Room.sendShout(roomUser, "*Knocks out " + args[1] + ", sending them to the hospital*"); dbClient.runQuery("UPDATE users SET kills = kills + 1 WHERE name = '" + _Username + "'"); dbClient.runQuery("UPDATE users SET deaths = deaths + 1, time_dead = '10' WHERE name = '" + User._Username + "'"); User._Mission = "Dead"; User._DeathTimer = 10; refreshAppearance(true, true, true); ThreadStart koStarter = new ThreadStart(User.knockOut); User.deadLooper = new Thread(koStarter); User.deadLooper.Priority = ThreadPriority.Lowest; User.deadLooper.Start(); User.roomUser.walkLock = true; } } } } else { if (User._roomID == _roomID && (roomUser.Y + 1 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X) || (roomUser.Y - 1 == User.roomUser.Y && roomUser.X + 1 == User.roomUser.X) || (roomUser.Y + 1 == User.roomUser.Y && roomUser.X - 1 == User.roomUser.X)) { Room.sendShout(roomUser, "*Swings at " + args[1] + ", but misses*"); } } } } break; } #endregion [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Server Development
Habbo Retros
Habbo Tutorials
DeltaCMS Edited By Mack-xoa!!
Top