Greetz RaGEZONE! What's up?
Currently I've been busy with a new emulator (based on HabboEnvirontment V3) and a new CMS (from scratch).
Emulator:
SWF Release: RELEASE63-201207100852-501822384
Database: AtomDB
Currently coded features:
Logging in 100%
Friends 90% - Doesn't update when user goes offline, only if user goes online.
Chatting 100%
Catalogue 90% - vip_buy packet not coded, club_gifts packet neither, no group shit
Navigator Public Categories 100%
Navigator All Rooms 90% - Most users in not coded, highest score not coded
Room entering 100%
Chatting in room 33% - No shouting and whispering, no commands
Walking 99% - Little bit buggy, no room check patch
Profiles 95% - Achievement points not coded, last online not coded
Groups 5% - Only at room info and in profiles, but on profiles also not 100%
Achievements 90% - No specific levels, system not fully coded
Snippets:
PHP Code:
public ClientMessageHandler()
{
Type t = typeof(Opcodes.OpcodesIn);
foreach (var Field in t.GetFields())
{
string Name = Field.Name;
short Value = (short)Field.GetValue(0);
PacketNames.Add(Value, Name);
foreach (var Type in Assembly.GetExecutingAssembly().GetTypes())
{
if (Type.Name != Name)
continue;
var Packet = (Type.GetConstructor(new Type[] { }).Invoke(new object[] { })) as IPacket;
Packets.Add(Value, Packet);
}
}
HabboEnvironment.ConsoleSystem.PrintLine("PACKETS", "Added {0} Packet Names!", ConsoleColor.Magenta, PacketNames.Count);
HabboEnvironment.ConsoleSystem.PrintLine("PACKETS", "Added {0} Packet Events!", ConsoleColor.Magenta, Packets.Count);
}
PHP Code:
public class ServerMessage
{
private List<byte> Message;
public ServerMessage() { }
public ServerMessage(short ID)
{
Message = new List<byte>();
AppendInt16(ID);
}
public ServerMessage New(short ID)
{
Message = new List<byte>();
AppendInt16(ID);
return this;
}
private void AppendInt32(int Int32)
{
AddBytes(BitConverter.GetBytes(Int32), true);
}
private void AppendUInt32(uint UInt32)
{
AddBytes(BitConverter.GetBytes(UInt32), true);
}
private void AppendInt16(short Short)
{
AddBytes(BitConverter.GetBytes(Short), true);
}
private void AppendString(string String)
{
AppendInt16((short)String.Length);
AddBytes(Encoding.Default.GetBytes(String), false);
}
private void AppendBool(bool Bool)
{
AddBytes(new byte[] { (Bool) ? (byte)1 : (byte)0 }, false);
}
private void AddBytes(byte[] Bytes, bool IsInt)
{
if (IsInt)
{
for (int i = Bytes.Length - 1; i > -1; i--)
{
this.Message.Add(Bytes[i]);
}
}
else
{
this.Message.AddRange(Bytes);
}
}
public ServerMessage Append<T>(object obj)
{
if (typeof(T) == typeof(int))
{
AppendInt32((int)obj);
return this;
}
if (typeof(T) == typeof(string))
{
AppendString(obj.ToString());
return this;
}
if (typeof(T) == typeof(bool))
{
AppendBool((bool)obj);
return this;
}
if (typeof(T) == typeof(short))
{
AppendInt16((short)obj);
return this;
}
if (typeof(T) == typeof(uint))
{
AppendUInt32((uint)obj);
return this;
}
if (typeof(T) == typeof(string[]))
{
for (int i = 0; i < ((string[])obj).Length; i++)
AppendString(((string[])obj)[i]);
}
return this;
}
public byte[] ToByteArray()
{
List<byte> NewMsg = new List<byte>();
NewMsg.AddRange(BitConverter.GetBytes(Message.Count));
NewMsg.Reverse();
NewMsg.AddRange(Message);
return NewMsg.ToArray();
}
public void Send(Session Session)
{
Session.WriteComposer(this);
}
public int GetBitLen()
{
return Message.Count;
}
}
Images:







CMS:
Type: OOP
Currently coded features:
Login 90% - No password hash
Template system 100%
MySQL 90% - Exploitable, going to remove exploits of course
MySQLi 10% - Only connecting
Snippets:
PHP Code:
<?php
class Template
{
private $file = '';
private $body = '';
public $parameters = array();
public function __construct()
{
$this->AddParameter('site', 'http://' . $_SERVER["SERVER_NAME"]);
}
public function AddTemplate($name)
{
$this->file = 'http://' . $_SERVER["SERVER_NAME"] . '/app/templates/templ.' . $name . '.tmp';
$this->WriteTemplateFile();
}
private function WriteTemplateFile()
{
$this->body .= file_get_contents($this->file);
}
public function Write($whattowrite)
{
$this->body .= $whattowrite;
}
public function AddParameter($key, $value)
{
$this->parameters[$key] = $value;
}
public function toString()
{
$newbody = $this->body;
foreach ($this->parameters as $param => $value)
{
$newbody = str_replace('$' . $param . '$', $value, $newbody);
}
echo $newbody;
$this->body = '';
}
}
?>
Images: Soon, very soon.