[DEV] Xoa Emulator v4 [Jammy]

Status
Not open for further replies.

Ari

Member
Sep 29, 2010
320
48
Yes guys I'm back this may be my last emulator I will be developing.
All this is, is a edit of Holograph Emulator, for RP hotels

Features:
A whole new BOT system
Mostly everything will be cached
Much more..

Here are some screenies:

ceb7f7c4e89c2aa609f1e67879429084.png

b4c503c7f8bd2d03f6ba7aa3b0e21c98.png

465d4c877529d14587c434d4e381b7ea.png

e686e4d42f42d05c61b8739ff341ebd1.png

cd5ef00c6932793507485e3b6caabc2c.png

ae6cb97c9887b1da3e580b0ff960174b.png

2c90e6d84672964c0156d4c5b8cbc751.png

2cf71ddb22605fa17aa6fcb241c3013e.png


Code Snippits:
Code:
        internal void arrestUser(int uid, int time)
        {
            virtualUser User = userManager.getUser(uid);
            using (DatabaseClient dbClient = Eucalypt.dbManager.GetClient())
            {
                if (_Jailed == 1)
                {
                    User._Arrests = User._Arrests + 1;
                    User._Jailed = 1;
                    User._JailTime = time;
                    User._LandAtDoor = true;
                    jailLooper.Abort();
                    jailLooper = null;
 
                    Room.sendSaying(roomUser, "\n\n*" + _Username + " re-arrests " + User._Username + " for " + time + " minutes* " + "" + " \n\n  " + _Username + " re-arrests " + User._Username + "  for " + time + " minutes*");
 
                    User.sendData("D^" + "H" + Encoding.encodeVL64(7));
                    User.sendData("BK" + "You have been re-arrested by " + _Username + ".");
 
                    ThreadStart jailStarter = new ThreadStart(User.jailTime);
                    User.jailLooper = new Thread(jailStarter);
                    User.jailLooper.Priority = ThreadPriority.Lowest;
                    User.jailLooper.Start();
                }
                else if (_Jailed == 0)
                {
                    User._Arrests = User._Arrests + 1;
                    User._Jailed = 1;
                    User._JailTime = time;
 
                    int fine = time * 5;
                    dbClient.runQuery("UPDATE users SET credits = credits - '" + fine + "' WHERE name = '" + User._Username + "'");
                    User._LandAtDoor = true;
                    User._Wanted = 0;
                    User.refreshValueables(true, false);
 
                    Room.sendSaying(roomUser, "\n\n*" + _Username + " arrests " + User._Username + " for " + time + " minutes, and issues them a " + fine + " credit fine* " + "" + " \n\n  " + _Username + " arrests " + User._Username + "  for " + time + " minutes, and issues them a " + fine + " credit fine*");
 
                    User.sendData("D^" + "H" + Encoding.encodeVL64(7));
                    User.sendData("BK" + "You have been arrested by " + _Username + ", and fined " + fine + " credits.");
 
                    ThreadStart jailStarter = new ThreadStart(User.jailTime);
                    User.jailLooper = new Thread(jailStarter);
                    User.jailLooper.Priority = ThreadPriority.Lowest;
                    User.jailLooper.Start();
                }
            }
        }
Code:
        internal void killUser(int uid)
        {
            virtualUser User = userManager.getUser(uid);
            if (User._Mission == "[CW] Red Team" || User._Mission == "[CW] Blue Team")
            {
                User.sendData("D^" + "H" + Encoding.encodeVL64(423));
                User.sendData("BK" + "You were knocked out by another user and sent to the graveyard.");
            }
            else if (User._Mission == "[Game] Deathmatch" || User._Mission == "[Game] Brawl")
            {
                if (User._Mission == "[Game] Deathmatch")
                {
                    User.sendData("D^" + "H" + Encoding.encodeVL64(21));
                    User.sendData("BK" + "An administrator has summoned you.");
                }
                if (User._Mission == "[Game] Brawl")
                {
                    User.sendData("D^" + "H" + Encoding.encodeVL64(21));
                    User.sendData("BK" + "An administrator has summoned you.");
                }
                User.refreshAppearance(true, true, true);
                User._Health = 100;
            }
            else
            {
                User._OOC = 1;
                User.sendData("D^" + "H" + Encoding.encodeVL64(2));
                User.sendData("BK" + "You have been knocked out by another user and sent to the hospital.");
                User._Health = 100;
                User._Dead = 1;
                User._DeadTime = 600;
                User._Mission = "[Dead]" + _Mission + "";
                User._Deaths = User._Deaths + 1;
 
                User.refreshAppearance(true, true, true);
            }
 
        }
I'll add some more screenshots and code snippits further on in development

Credits:
Me
Craig
RastaLulz
Cecer1
Xavi
Jacky
C0be (Makarov)
 

Ept

Many men wish death upon me.
Jun 16, 2011
591
276
Approved, good luck with this. Is this an ordinary RP emulator? Or are you implementing new ideas, and not just 'cleaning the code'?
 

Ari

Member
Sep 29, 2010
320
48
I'm implementing new ideas such as new arenas and games that are automated
 

Adil

DevBest CEO
May 28, 2011
1,276
714
Looks nice, good luck Jammy :p.
If you need any help I'd be glad to offer assistance
 

Crup

weeeeee
Jul 25, 2010
545
310
Nice Jammy, I'm glad to see that your back on the track with habbo. The arrest void doesn't seem right as that can be enabled when a user uses the ;arrest command but nice anyways.
 

iDevon

Solo Dolo
Dec 27, 2010
404
49
Hmm.. can't wait to see the outcome of this. Knowing you it will obviously be finished, welcome back Jammy !
 

Ari

Member
Sep 29, 2010
320
48
Nice Jammy, I'm glad to see that your back on the track with habbo. The arrest void doesn't seem right as that can be enabled when a user uses the ;arrest command but nice anyways.

That's wat its so :arrest doesn't need lots of code and it can be used by other things if needed instead of having lots of code again 
Made a users stats kinda thingy, It doesn't seem to update very often so I just put strength on there.
cd5ef00c6932793507485e3b6caabc2c.png
 

iDevon

Solo Dolo
Dec 27, 2010
404
49
That's wat its so :arrest doesn't need lots of code and it can be used by other things if needed instead of having lots of code again 
Made a users stats kinda thingy, It doesn't seem to update very often so I just put strength on there.
cd5ef00c6932793507485e3b6caabc2c.png
Is that only displayed for the privately to the player or publicly to everyone?
 

Crup

weeeeee
Jul 25, 2010
545
310
You should make more to that, you can add :Age, Eye Color, Race , Job etc.
 

Sledmore

Chaturbate Livestreamer
Staff member
FindRetros Moderator
Jul 24, 2010
5,194
3,901
Looks good, but curious to all these files? Like VirtualJob and VirutalGang. Surely there isn't need for a whole new file? But if that's how you like to work, I wont mock it xP.

Also, curious to the '_Deadtime = 600' you handling timers into seconds?!? Also, no need to update motto there, I'd just edit it via the detailsString, so you don't need to bother calling it anywhere, and just set for if arrested, dead etc. ;-). - Wouldn't run your games via motto either! You should just set an internal int for the game ID and give the user it, can also help for it the user disconnects in a long run game. And you could make a void to assign the users!! And do so much more, so much easier! Last thing, or it seems like I'm being a nob, I don't see why your using '_LandAtDoor', you could just edit the 'addUser' void, and set everything there, it helps SO MUCH, with games, arrows, arrests etc!

Good luck, if you do need help, don't hesitate to ask :-].
 

Ari

Member
Sep 29, 2010
320
48
Looks good, but curious to all these files? Like VirtualJob and VirutalGang. Surely there isn't need for a whole new file? But if that's how you like to work, I wont mock it xP.

Also, curious to the '_Deadtime = 600' you handling timers into seconds?!? Also, no need to update motto there, I'd just edit it via the detailsString, so you don't need to bother calling it anywhere, and just set for if arrested, dead etc. ;-). - Wouldn't run your games via motto either! You should just set an internal int for the game ID and give the user it, can also help for it the user disconnects in a long run game. And you could make a void to assign the users!! And do so much more, so much easier! Last thing, or it seems like I'm being a nob, I don't see why your using '_LandAtDoor', you could just edit the 'addUser' void, and set everything there, it helps SO MUCH, with games, arrows, arrests etc!

Good luck, if you do need help, don't hesitate to ask :-].

I like to keep everything organised (I'm autistic) and tbh I have no idea why I am using _landatdoor it doesn't even do anything lol

And I'll change up the details string for users and bots thanks for the suggestions ;D
 

Sledmore

Chaturbate Livestreamer
Staff member
FindRetros Moderator
Jul 24, 2010
5,194
3,901
I like to keep everything organised (I'm autistic) and tbh I have no idea why I am using _landatdoor it doesn't even do anything lol

And I'll change up the details string for users and bots thanks for the suggestions ;D

Ah xD, and no problems. However, I'm still confused with the 'User._DeadTime = 600;' - Are you running this by seconds? As 600 seconds is 10 minutes.
 

Ari

Member
Sep 29, 2010
320
48
Ah xD, and no problems. However, I'm still confused with the 'User._DeadTime = 600;' - Are you running this by seconds? As 600 seconds is 10 minutes.

Yes I've changed it to 300 seconds I made a mistake and when it shows the user it divides it by 60 so it shows them how many minutes not seconds ;D
 

Ari

Member
Sep 29, 2010
320
48
Heres a snippit of how I time everything :)
Code:
if (A.User._roomID != 7 && A.User.roomUser.Y != 10 && A.User.roomUser.X != 8)
                        {
                            A.User._JailBreaking = false;
                        }
 
                        if (A.User._JailBreaking)
                        {
                            A.User.JBTime++;
                            if (A.User.JBTime == 60)
                            {
                                sendSaying(A.User.roomUser, "*needs 3 more minutes to break down the jailcell wall*");
                            }
                            if (A.User.JBTime == 120)
                            {
                                sendSaying(A.User.roomUser, "*needs 2 more minutes to break down the jailcell wall*");
                            }
                            if (A.User.JBTime == 180)
                            {
                                sendSaying(A.User.roomUser, "*needs 1 more minutes to break down the jailcell wall*");
                            }
                            if (A.User.JBTime == 240)
                            {
                                sendSaying(A.User.roomUser, "*successfully breaks down the jailcell wall freeing everyone inside*");
                                userManager.JailBreak();
                                A.User._JailBreaking = false;
                            }
                        }
 

Crup

weeeeee
Jul 25, 2010
545
310
Heres a snippit of how I time everything :)
Code:
if (A.User._roomID != 7 && A.User.roomUser.Y != 10 && A.User.roomUser.X != 8)
                        {
                            A.User._JailBreaking = false;
                        }
 
                        if (A.User._JailBreaking)
                        {
                            A.User.JBTime++;
                            if (A.User.JBTime == 60)
                            {
                                sendSaying(A.User.roomUser, "*needs 3 more minutes to break down the jailcell wall*");
                            }
                            if (A.User.JBTime == 120)
                            {
                                sendSaying(A.User.roomUser, "*needs 2 more minutes to break down the jailcell wall*");
                            }
                            if (A.User.JBTime == 180)
                            {
                                sendSaying(A.User.roomUser, "*needs 1 more minutes to break down the jailcell wall*");
                            }
                            if (A.User.JBTime == 240)
                            {
                                sendSaying(A.User.roomUser, "*successfully breaks down the jailcell wall freeing everyone inside*");
                                userManager.JailBreak();
                                A.User._JailBreaking = false;
                            }
                        }
is this a looper or?
 
Status
Not open for further replies.

Users who are viewing this thread

Top