Announcement

Collapse
No announcement yet.

[Tutorial][PS2] Detect players using unique team IDs in the game lobby (online/LAN)

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • [Tutorial][PS2] Detect players using unique team IDs in the game lobby (online/LAN)

    Game information:
    [PS2][SCUS_972.75] SOCOM II

    This is in NO way a code for cheating online. This code is only for detecting players who are using specific codes in an online/LAN lobby.


    Tutorial information:
    • Online/LAN lobby cheater detection. (NOTE: This tutorial only goes over detecting unique team IDs and players hiding their name)
    • This is strictly a method tutorial since each game is extremely different when it comes to the mechanics of an online/LAN lobby.



    About this code:
    This code detects players trying to hide with unique team IDs, or players using codes to hide their name, in the online/lan lobby. These players will be refered to as phantoms. Phantom players will show up in the spectator box. Players using no name codes will show up as "phantom".

    Q: Why make something like this?
    A: People on socom using codes called phantom and no name can join your game and be completely hidden visually. These people are obviously cheaters or glitchers and it allows you to hold the game from starting if one is detected.



    How to create the code(this is strictly based on SOCOM 2, others games will be vastly different)
    1: Find out how players are changing their team ID and how they are using no name codes to hide their name.
    2: Debug the lobby to find where the player pointers for the lobby are stored. In SOCOM 2 there is a player persona stack that has the info for each player such as: team ID, player name, etc.
    3: Find the team ID for each team(for SOCOM 2 there are 3 teams: seals, terrorists, and spectators).
    4: Write a code that checks the team ID and name of each player, if the team ID is not equal to one of the above three teams then force that player to the spectator team by overwriting their team ID. If the player does not have a name then force their name to be "phantom" or "cheater".

    That's all there is to it. I will include the source below to give you a better understanding.


    Here is an image that has 11 players in the lobby, several with no name and several that simply do not show up because they are using unique team IDs.





    Here is an image with the code that detects the unigue team IDs and no name players.




    Source Code:

    Code:
    
    
    /*
    
    Lobby Phantom Detector
    - Detects phantom users in the lobby and forces them
    to the spectator box.
    
    */
    
    // hook
    address $202C50F4
    jal $000d9000
    
    
    
    
    ////////////////// MAIN FNC ///////////////////
    
    /*
    
    register s2 offsets
    0: player team id
    e: player name
    2e: clan tag
    
    00441470 = my team id address
    -- 00010000 = spectator team
    
    
    */
    
    
    
    address $200d9000
    
    addiu sp, sp, $ff90
    sd ra, $0000(sp)
    sq s2, $0010(sp)
    sq t0, $0020(sp)
    sq t1, $0030(sp)
    sq a0, $0040(sp)
    sq a1, $0050(sp)
    
    // check for phantom player
    lw t0, $0000(s2) // get current team id
    
    
    // seal
    lui t1, $4000
    addiu t1, t1, $0001
    beq t0, t1, :__check_player_name
    nop
    
    // terrorist
    lui t1, $8000
    addiu t1, t1, $0100
    beq t0, t1, :__check_player_name
    nop
    
    // spectator
    lui t1, $0001
    addiu t1, t1, $0000
    beq t0, t1, :__check_player_name
    nop
    
    
    
    // PLAYER IS A PHANTOM
    
    // force phantom player to spectator box
    lui t0, $0001
    addiu t0, t0, $0000
    sw t0, $0000(s2)
    
    
    
    // check if player has a name
    __check_player_name:
    lb t0, $000E(s2) //check if player has name
    bne t0, zero, :__END
    nop
    
    //else, write "phantom"
    // strcpy; a0 = ptr to copy from
    // strcpy; a1 = ptr to copy to
    lui a1, $000E
    addiu a1, a1, $9A60
    jal $00199060 //strcpy
    addiu a0, s2, $000E //offset to player name
    beq zero, zero :__END
    nop
    
    
    __END:
    
    ld ra, $0000(sp)
    lq s2, $0010(sp)
    lq t0, $0020(sp)
    lq t1, $0030(sp)
    lq a0, $0040(sp)
    lq a1, $0050(sp)
    jr ra
    addiu sp, sp, $0070
    
    
    
    // player name text
    address $200d9a60
    print "phantom"
    Code in RAW format:

    Code:
    Lobby Phantom/No Name Detector
    202C50F4 0C036400
    200D9000 27BDFF90
    200D9004 FFBF0000
    200D9008 7FB20010
    200D900C 7FA80020
    200D9010 7FA90030
    200D9014 7FA40040
    200D9018 7FA50050
    200D901C 8E480000
    200D9020 3C094000
    200D9024 25290001
    200D9028 1109000C
    200D902C 00000000
    200D9030 3C098000
    200D9034 25290100
    200D9038 11090008
    200D903C 00000000
    200D9040 3C090001
    200D9044 25290000
    200D9048 11090004
    200D904C 00000000
    200D9050 3C080001
    200D9054 25080000
    200D9058 AE480000
    200D905C 8248000E
    200D9060 15000007
    200D9064 00000000
    200D9068 3C05000E
    200D906C 24A59A60
    200D9070 0C066418
    200D9074 2644000E
    200D9078 10000001
    200D907C 00000000
    200D9080 DFBF0000
    200D9084 7BB20010
    200D9088 7BA80020
    200D908C 7BA90030
    200D9090 7BA40040
    200D9094 7BA50050
    200D9098 03E00008
    200D909C 27BD0070
    200D9A60 6E616870
    200D9A64 006D6F74
Working...
X