Raised This Month: $ Target: $400
 0% 

Function call


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
joropito
AlliedModders Donor
Join Date: Mar 2009
Location: pfnAddToFullPack
Old 06-24-2010 , 16:04   Re: Function call
Reply With Quote #7

OT, check at Cvar_DirectSet() function.

It does the following depending on cvar flags:

PHP Code:
            Log_Printf("Server cvar \"%s\" = \"%s\"\n", *(_DWORD *)a2);
            
SV_BroadcastPrintf("\"%s\" changed to \"%s\"\n", *(_DWORD *)a2); 
Here's the code:

PHP Code:

void __usercall Cvar_DirectSet
(long double a1<st0>, int a2char *a3)
{
  
char *v3// edi@1
  
char *v4// ecx@4
  
char *v5// esi@4
  
int v6// esi@11
  
int v7// ST24_4@13
  
int v8// eax@13
  
char v9// al@13
  
int v10// eax@14
  
char *v11// edx@20
  
int v12// eax@20
  
int v13// eax@24
  
int v14// eax@24
  
char v15// [sp+10h] [bp-40Ch]@4

  
v3 a3;
  if ( 
a2 )
  {
    if ( 
a3 )
    {
      if ( *(
_BYTE *)(a2 8) < )
      {
        
v15 0;
        
v4 a3;
        
v5 = &v15;
        
v3 = &v15;
        while ( *
v4 )
        {
          if ( (
unsigned __int8)(*v4 32) <= 0x5Eu )
            *
v5++ = *v4++;
          else
            ++
v4;
        }
        *
v5 0;
        if ( !
Q_strlen(&v15) )
          
Q_strcpy(&v15"empty");
      }
      
v6 Q_strcmp(*(_DWORD *)(a2 4), v3);
      if ( *(
_BYTE *)(a2 8) & )
      {
        if ( !*(
_DWORD *)cls )
        {
          
v7 = *(_DWORD *)a2;
          
v8 Info_Serverinfo();
          
Info_SetValueForKey(v8v7v3512);
          
v9 Info_Serverinfo();
          
SV_BroadcastCommand("fullserverinfo \"%s\"\n"v9);
        }
      }
      
v10 = *(_DWORD *)(a2 8);
      if ( 
v10 )
      {
        if ( 
v6 )
        {
          if ( !(
BYTE1(v10) & 1) )
          {
            
Log_Printf("Server cvar \"%s\" = \"%s\"\n", *(_DWORD *)a2);
            
SV_BroadcastPrintf("\"%s\" changed to \"%s\"\n", *(_DWORD *)a2);
          }
          if ( *(
_BYTE *)(a2 8) & 0x20 )
          {
            if ( 
Q_strlen(v3) <= || (v12 Q_stricmp(v3"none"), v11 = (char *)&off_A7F80, !v12) )
              
v11 = (char *)&off_A7F80 2;
          }
          else
          {
            
v11 v3;
          }
          
Steam_SetCVar(*(_DWORD *)a2v11);
        }
      }
      
Z_Free(*(_DWORD *)(a2 4));
      
v13 Q_strlen(v3);
      
v14 Z_Malloc(v13 1);
      *(
_DWORD *)(a2 4) = v14;
      
Q_strcpy(v14v3);
      
Q_atof(*(_DWORD *)(a2 4));
      *(
float *)(a2 12) = a1;
    }
  }

__________________

Divide et vinces
approved plugins | steam account

I don't accept PM for support. Just ask on forums.
If you're looking for private work, PM me.

Last edited by joropito; 06-24-2010 at 16:08.
joropito is offline
Send a message via MSN to joropito
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 14:48.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode