Advertisement
Guest User

Untitled

a guest
Aug 30th, 2015
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.03 KB | None | 0 0
  1. Room room = parsedClient.GetHabbo().CurrentRoom;
  2. RoomUser roomuser2 = room.GetRoomUserManager().GetRoomUserByHabbo(Client.GetHabbo().Id);
  3. RoomUser roomuser1 = room.GetRoomUserManager().GetRoomUserByHabbo(parsedClient.GetHabbo().Id);
  4.  
  5. if (Sound == "InvalidSoundType")
  6. return;
  7.  
  8. if ((Math.Abs((int)(roomuser1.X - roomuser2.X)) >= 1))
  9. { TCPClient.Append(Client.GetHabbo().Id, "Sound", "RoomEvent", Sound, CalucateRatio(1).ToString()); }
  10. if ((Math.Abs((int)(roomuser1.X - roomuser2.X)) >= 2))
  11. { TCPClient.Append(Client.GetHabbo().Id, "Sound", "RoomEvent", Sound, CalucateRatio(2).ToString()); }
  12. if ((Math.Abs((int)(roomuser1.X - roomuser2.X)) >= 3))
  13. { TCPClient.Append(Client.GetHabbo().Id, "Sound", "RoomEvent", Sound, CalucateRatio(3).ToString()); }
  14. if ((Math.Abs((int)(roomuser1.X - roomuser2.X)) >= 4))
  15. { TCPClient.Append(Client.GetHabbo().Id, "Sound", "RoomEvent", Sound, CalucateRatio(4).ToString()); }
  16. if ((Math.Abs((int)(roomuser1.X - roomuser2.X)) >= 5))
  17. { TCPClient.Append(Client.GetHabbo().Id, "Sound", "RoomEvent", Sound, CalucateRatio(5).ToString()); }
  18. if ((Math.Abs((int)(roomuser1.X - roomuser2.X)) >= 6))
  19. { TCPClient.Append(Client.GetHabbo().Id, "Sound", "RoomEvent", Sound, CalucateRatio(6).ToString()); }
  20. if ((Math.Abs((int)(roomuser1.X - roomuser2.X)) >= 7))
  21. { TCPClient.Append(Client.GetHabbo().Id, "Sound", "RoomEvent", Sound, CalucateRatio(7).ToString()); }
  22. if ((Math.Abs((int)(roomuser1.X - roomuser2.X)) >= 8))
  23. { TCPClient.Append(Client.GetHabbo().Id, "Sound", "RoomEvent", Sound, CalucateRatio(8).ToString()); }
  24. if ((Math.Abs((int)(roomuser1.X - roomuser2.X)) >= 9))
  25. { TCPClient.Append(Client.GetHabbo().Id, "Sound", "RoomEvent", Sound, CalucateRatio(9).ToString()); }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement