Hello, i made code of uberemulator!
Go to uber-config.conf and add
Code:
## Config Hotel
hotel.name=YourHotelName
Go to UberEnvironment.cs and replace prettyversion per
Code:
public static String HotelName
{
get
{
Configuration = new ConfigurationData("uber-config.conf");
return UberEnvironment.GetConfig().data["hotel.name"];
}
}
public static String PrettyVersion
{
get
{
return HotelName + " Emulator";
}
}
2. Open Program.cs
Find
Code:
static void MyHandler(object sender, UnhandledExceptionEventArgs args)
Replace per
Code:
static void MyHandler(object sender, UnhandledExceptionEventArgs args)
{
if (UberEnvironment.GetConfig().data["shutdown.crash"] == "1")
{
Exception e = (Exception)args.ExceptionObject;
Logging.LogCriticalException(e.ToString());
UberEnvironment.Destroy();
Environment.Exit(2);
Console.ReadKey(true);
}
else if (UberEnvironment.GetConfig().data["shutdown.crash"] == "0")
{
Exception e = (Exception)args.ExceptionObject;
Logging.LogCriticalException(e.ToString());
}
1 = Close the emulator if it crashing and save the errors
0 = Only Save the errors
Go to uber-config.conf
ADD
This code request a restarter if shutdown.crash=1
Go From xGenEmulator of anthony93260
In UberEnvironment.cs, find
Under, ADD
Code:
ServerStarted = DateTime.Now;
Find
Code:
private static Game Game;
under, add
Code:
internal static DateTime ServerStarted;
Go to LowPriorityWorker.cs in
Code:
Public static void Process()
under
while(true)
{
try
{
add
Code:
DateTime Now = DateTime.Now;
TimeSpan TimeUsed = Now - UberEnvironment.ServerStarted;
after, go to Misc/ChatCommandHandler.cs
add
Code:
case "emulator":
{
if (Session.GetHabbo().Rank >= 2)
{
int onlineusers = UberEnvironment.GetGame().GetClientManager().ClientCount;
int RoomsLoaded = UberEnvironment.GetGame().GetRoomManager().LoadedRoomsCount;
Session.SendNotif("Informations de " + UberEnvironment.ConsoleName + "\n- Nombre de connectés: " + onlineusers + "\n- Appart chargés: " + RoomsLoaded + "\n- Server Started: " + UberEnvironment.ServerStarted);
return true;
}
else
{
Session.SendNotif("Vous n'êtes pas un Membre VIP");
}
return false;
}
go to