Announcement

Collapse
No announcement yet.

Weapon Teleport Source Code

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Weapon Teleport Source Code

    Don't know if it works but I assume it needs updated. Credit to Fallen.

    bool EvilCompare(const DWORD dwAd,const BYTE *bMask,const int size,const BYTE FALSECODE)
    {
    for(int i = 0;i<size;i++)
    if(bMask[i] != FALSECODE)
    if( *(BYTE *)(dwAd + i) != bMask[i]) return false;
    return true;
    }

    DWORD EvilPattern(DWORD dwAd,BYTE *bMask,int size,BYTE FALSECODE)
    {
    for(DWORD i=0; i<0xFFFFFF; i++)
    if(EvilCompare((dwAd + i),bMask,size,FALSECODE)) return (dwAd + i);
    return 0;
    }


    void GetVa(void *WeaponObject)
    {


    if( *(DWORD *)(GUNBASE) )
    {
    _Object* MyObject = *(_Object **)(*(DWORD *)(GUNBASE) + 0x350); //My
    *(D3DXVECTOR3 *)(WeaponObject) = GetBonePosition(MyObject,6);
    }

    }

    __declspec( naked ) VOID WINAPI WeaponTeleport()
    {
    void *WeaponObject;
    _asm PUSHAD;
    _asm mov WeaponObject,edx;
    GetVa(WeaponObject);
    _asm POPAD;
    _asm MOV EDX,DWORD PTR SS:[ESP+0xA8];
    _asm PUSH ESI;
    _asm PUSH EDX;
    _asm MOV ECX,EAX;
    _asm jmp retWT;
    }


    -----------------------------------------------------------------------------------------------
    Code:
    BYTE IsMask_We[] = {0x8B, 0x94, 0x24, 0xA8, 0x00, 0x00, 0x00, 0x56, 0x52, 0x8B, 0xC8};
    DWORD HookAddy = EvilPattern(hShell, IsMask_We,sizeof(IsMask_We),0xFF); // Detour __declspec( naked ) WeaponTeleport in this address
    retWT = HookAddy + 0xB;

  • #2
    this looks like a very tedious way of doing ltclient->setobjectposition

    Comment


    • #3
      I'm not much of a coder but I assumed if there was a simpler way then perhaps he thought this would be harder to detect or avoid some sort of a client error?

      Comment


      • #4
        Originally posted by addcoolman View Post
        I'm not much of a coder but I assumed if there was a simpler way then perhaps he thought this would be harder to detect or avoid some sort of a client error?
        We have already made such a function,but cf checks positions now which causing client errors if you change the positions of weapons.

        Comment


        • #5
          Kilt [MENTION=849]Immortal[/MENTION] so cute hehe.

          /closed
          Need help?
          Skype - sinful.system

          Link to forum rules: http://sinfulexp.net/forum/showthrea...-Website-Rules!

          Comment

          Working...
          X