Difference between revisions of "Useful Signatures (Source)"

From AlliedModders Wiki
Jump to: navigation, search
Line 98: Line 98:
 
'''Example Call'''
 
'''Example Call'''
 
<pawn>SignatureScanCall(sig_id, client, SIGTYPE_CBASEENTITY, PARAM_INT, 123);</pawn>
 
<pawn>SignatureScanCall(sig_id, client, SIGTYPE_CBASEENTITY, PARAM_INT, 123);</pawn>
 +
 +
 +
==CBasePlayer::DamageEffect==
 +
This function shows an effect like you would get if you got damaged. Some options dont do anything, but others look kinda cool
 +
 +
'''The Signature'''
 +
<pawn>\x8b\x44\x24\x08\x83\xec\x14\xa8\x01\x56\x57\xeb\xf1\x74\x36\x6a\x01\xb0\x80\x68\xcd\xcc\xcc\x3d\x88\x44\x24\x2c\x88\x44\x24\x2f\x68\x00\x00\x80\x3f\x8d\x44\x24\x30\x50\x56\xc6\x44\x24\x39\x00\xc6\x44\x24\x3a\x00\xe8\x46\x6d\x09\x00\x83\xc4\x14\x5f</pawn>
 +
 +
'''The Mask'''
 +
<pawn>xxxxxxxxxxx????xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx????xxxxx</pawn>
 +
 +
'''Length'''
 +
62
 +
 +
'''Linux Function'''
 +
<pawn>_ZN11CBasePlayer12DamageEffectEfi</pawn>
 +
 +
'''Function Paramaters'''
 +
*'''Float flDamage'''
 +
**[not used]
 +
*'''int fDamageType'''
 +
**DMG_CRUSH (1<<0)
 +
**DMG_DROWN (1<<14)
 +
**DMG_SLASH (1<<2)
 +
**DMG_PLASMA (1<<24)
 +
**DMG_SONIC (1<<9)
 +
**MG_BULLET (1<<1)
 +
 +
'''Example Call'''
 +
<pawn>SignatureScanCall(sig_id, client, SIGTYPE_CBASEENTITY, PARAM_FLOAT, 0, PARAM_INT, (1<<24));</pawn>

Revision as of 17:57, 28 May 2007

Introduction

I have posted this page here so I can share some useful sigscan signatures. With these, and the use of PimpinJuice's SigOffset Extension you can call some very useful functions from within SourceMod plugins.

Function Signatures

This is the list of all of the functions that we have signatures for.

CBaseEntity::Spawn

This function is used to spawn player entities into the game. Either after creation, or re-spawn the player back to their spawn point. This function is good to call once you have changed the value of 'm_iTeamNum'. Once you have changed this value, you will need to call this function so the swapped player has the right skin and game rules associated.

The Signature

\x83\xec\x2c\x53\x55\x56\x57\x68\x2c\x2d\x49\x22\x8b\xf1\xe8\x2d\x1c\xed\xff\x8b\x06\x8b\xce\xff\x90\x28\x04\x00\x00\x80\xbe\xad\x02\x00\x00\x01\x8d\x8e\xad\x02\x00\x00\xc6\x44\x24\x10\x01\x74\x0a\x8d\x54\x24\x10\x52\xe8\x85\xa8\xed\xff\x80\xbe\xae\x02\x00\x00\x01\x8d\x8e\xae\x02\x00\x00\xc6\x44\x24\x10\x01\x74\x0a\x8d\x44\x24\x10\x50\xe8\xb7\xa8\xed\xff\x8b\x16\x8b\xce\xff\x92\x9c\x05\x00\x00\x8b\x8e\xf8\x0b\x00\x00\x8b\xd8

The Mask

xxxxxxx?????xx?????xxxxxxxxxxxxxxxxxxxxxxxxxxxx??xxxxx?????xxxxxxxxxxxxxxxxxx??xxxxx?????xxxxxxxxxxxxxxxxxx

Length 107

Linux Function

_ZN11CBaseEntity5SpawnEv

Example Call

SignatureScanCall(sig_id, client, SIGTYPE_CBASEENTITY);

CBaseEntity::Teleport

This function will teleport an entity to a certain place in the world with a given vector. Useful for moving things across the world, or 'pushing' with a given force

The Signature

\x83\xEC\x18\x53\x56\x8B\xD9\x8B\x0D\x78\xB2\x46\x22\x33\xF6\x33\xC0\x3B\xCE\x7E\x21\x8B\x15\x6C\xB2\x46\x22\xEB\x03\x8D\x49\x00\x39\x1C\x82\x74\x09\x83\xC0\x01\x3B\xC1\x7C\xF4\xEB\x08\x3B\xC6\x0F\x8D\x17\x01\x00\x00\x55\x57\x8D\x44\x24\x10\x50\x51\xB9\x6C\xB2\x46\x22\x89\x5C\x24\x18\xE8\xB4\x88\xF9\xFF\x8D\x4C\x24\x14\x51\x53\x89\x44\x24\x18\x89\x74\x24\x1C\x89\x74\x24\x20\x89\x74\x24\x24\x89\x74\x24\x28\x89\x74\x24\x2C

The Mask

xxxxxxx??????xxxxxx?????????????xxx?????xx????xx??????x?????xx?????xxxx?????????xxxxxxxxxxxxxxxxxxxxxxxxxx

Length 106

Linux Function

_ZN11CBaseEntity8TeleportEPK6VectorPK6QAngleS

Function Paramaters

  • Vector newPosition
    • The place to teleport to
  • QAngle newAngles
    • The new angle of the entity
  • Vector newVelocity
    • Directional vector for velocity

Example Call

new Float:Pos[3];
new Float:Vel[3];
SignatureScanCall(sig_id, client, SIGTYPE_CBASEENTITY, PARAM_VECTOR, Pos, PARAM_QANGLE, -1, PARAM_VECTOR, Vel);


CBaseEntity::SetModel

This function will set the model of the entity to the model that you specify. (Yes even player models ;))

The Signature

\x56\x8b\x74\x24\x08\x57\x8b\xf9\x8b\x0d\x8c\x69\x5f\x22\x8b\x01\x56\xff\x50\x08\x8b\x0d\x8c\x69\x5f\x22\x8b\x11\x50\xff\x52\x04\x85\xc0\x74\x20\x8b\x0d\x8c\x69\x5f\x22\x8b\x11\x50\xff\xf2\x24\x83\xf8\x01

The Mask

xxxxxxxx??????xxx?????????xxx???xx????????xxx??xxxx

Length 51

Linux Function

_ZN11CBaseEntity8SetModelEPKc

Function Paramaters

  • const char *szModelName
    • The model to set to

Example Call

PrecacheModel("models/Alyx.mdl");
SignatureScanCall(sig_id, client, SIGTYPE_CBASEENTITY, PARAM_CONST_CHAR_PTR, "models/Alyx.mdl");


CBaseEntity::SetModelIndex

This function will set the model of the entity to the model index that you specify. To see a list of models currently cached and their id's type this into server console

sv_cheats 1;listmodels;sv_cheats 0

The Signature

\x53\x8b\x5c\x24\x08\x56\x57\x8b\xf9\x66\x8b\x4f\x1e\x8d\x77\x1e\x8d\x44\x24\x10\x66\x3b\x08\x74\x0c\x56\x8d\x4e\xe2\xe8\x4a\xe9\xfd\xff\x66\x89\x18\x8b\xcf

The Mask

xxxxxxxxxxxxxxxxxxx????????????????????

Length 39

Linux Function

_ZN11CBaseEntity13SetModelIndexEi

Function Paramaters

  • int index
    • The model index to set to

Example Call

SignatureScanCall(sig_id, client, SIGTYPE_CBASEENTITY, PARAM_INT, 123);


CBasePlayer::DamageEffect

This function shows an effect like you would get if you got damaged. Some options dont do anything, but others look kinda cool

The Signature

\x8b\x44\x24\x08\x83\xec\x14\xa8\x01\x56\x57\xeb\xf1\x74\x36\x6a\x01\xb0\x80\x68\xcd\xcc\xcc\x3d\x88\x44\x24\x2c\x88\x44\x24\x2f\x68\x00\x00\x80\x3f\x8d\x44\x24\x30\x50\x56\xc6\x44\x24\x39\x00\xc6\x44\x24\x3a\x00\xe8\x46\x6d\x09\x00\x83\xc4\x14\x5f

The Mask

xxxxxxxxxxx????xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx????xxxxx

Length 62

Linux Function

_ZN11CBasePlayer12DamageEffectEfi

Function Paramaters

  • Float flDamage
    • [not used]
  • int fDamageType
    • DMG_CRUSH (1<<0)
    • DMG_DROWN (1<<14)
    • DMG_SLASH (1<<2)
    • DMG_PLASMA (1<<24)
    • DMG_SONIC (1<<9)
    • MG_BULLET (1<<1)

Example Call

SignatureScanCall(sig_id, client, SIGTYPE_CBASEENTITY, PARAM_FLOAT, 0, PARAM_INT, (1<<24));