Advertisement
ovokore

Network::Receive::ROla

Apr 21st, 2025 (edited)
671
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Perl 0.67 KB | None | 0 0
  1. package Network::Receive::ROla;
  2.  
  3. use strict;
  4. use base qw(Network::Receive::ServerType0);
  5.  
  6. sub new {
  7.     my ($class) = @_;
  8.     my $self = $class->SUPER::new(@_);
  9.    
  10.     my %packets = (
  11.         '0AE3' => ['received_login_token', 'v l Z20 Z*', [qw(len login_type flag login_token)]],
  12.         '0AC4' => ['account_server_info', 'v a4 a4 a4 a4 a26 C x17 a*', [qw(len sessionID accountID sessionID2 lastLoginIP lastLoginTime accountSex serverInfo)]],
  13.     );
  14.    
  15.     $self->{packet_list}{$_} = $packets{$_} for keys %packets;
  16.  
  17.     my %handlers = qw(
  18.         received_login_token 0AE3
  19.         account_server_info 0AC4
  20.     );
  21.  
  22.     $self->{packet_lut}{$_} = $handlers{$_} for keys %handlers;
  23.    
  24.     return $self;
  25. }
  26.  
  27. 1;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement