Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

[BANZAI] Esphere Banzai reload the tile Colors. 90%

Status
Not open for further replies.
Newbie Spellweaver
Joined
Dec 4, 2008
Messages
54
Reaction score
3
ADD THIS TO YOUR DB AT ROOM_ITEMS:
Code:
ALTER TABLE  `room_items` ADD  `bb_apparatus_state` INT( 255 ) NOT NULL DEFAULT  '0'


AND THIS CODE AT ROOM.CS IN YOUR SERVER..
Code:
if (Item.GetBaseItem().InteractionType.ToLower() == "bb_apparatus")
                    using (DatabaseClient dbClient = UberEnvironment.GetDatabase().GetClient())
                    {
                        string color = dbClient.ReadString("SELECT bb_ball FROM `users` WHERE id='" + User.HabboId + "'");
                        int state;
                        string ColorBase = "";

                        state = dbClient.ReadInt32("SELECT bb_apparatus_state FROM `room_items` WHERE id = '" + Item.Id + "' LIMIT 1");
                        {
                            if (state == 1)
                            {

                                ColorBase = "0";
                                dbClient.ExecuteQuery("UPDATE `room_items` SET bb_state = '0'");
                            }
                            else if (state == 2)
                            {

                                ColorBase = "0";
                                dbClient.ExecuteQuery("UPDATE `room_items` SET bb_state = '0'");
                            }
                            else if (state == 3)
                            {

                                ColorBase = "0";
                                dbClient.ExecuteQuery("UPDATE `room_items` SET bb_state = '0'");
                            }
                            else if (state == 4)
                            {

                                ColorBase = "0";
                                dbClient.ExecuteQuery("UPDATE `room_items` SET bb_state = '0'");
                            }

                            ServerMessage Baldosa = new ServerMessage(88);
                            Baldosa.AppendStringWithBreak(Item.Id.ToString());
                            Baldosa.AppendStringWithBreak(ColorBase);
                            SendMessage(Baldosa);
                            Item.UPDATEState(true, true);
                        }
                    }

AND THEN ADD THE INTERACTION BB_APPARATUS AT THE FURNITURE.

MATTERS:

- THE COLOR JUST RELOAD IF YOU WALK ON THE TILE.
- THE TILE IN ALL ROOMS OF DB, RELOAD.



LOOK, BB_APPARATUS:
Elienay - [BANZAI] Esphere Banzai reload the tile Colors. 90% - RaGEZONE Forums




SO, CREDITS FOR ME (NAY)
I'M BRAZILLIAN, THANKS .
 
Last edited:
Status
Not open for further replies.
Back
Top