summaryrefslogtreecommitdiff
path: root/src/cs2/cs2.h
blob: f8a3f9bf984db6c0c268d4451cbc5c3e90ec3dc2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#pragma once
#include "../process64.h"
#include "iface.h"

#include "sdk.h"

class CS2 : public PROCESS64 {
public:
  CS2() : PROCESS64( "cs2.exe" ) {};

  bool open();

  IFACE_ENTRY get_iface( const char* name ) {
    VECTOR<IFACE_ENTRY> entries = iface_get_all( this );
    for( auto it : entries ) {
      if( strncmp( it.name, name, strlen( name ) ) == 0 ) {
        return it;
      }
    }

    return {};
  }
  
  struct {
    MODULE_ENTRY client;
    MODULE_ENTRY engine;
    MODULE_ENTRY schema;
  } mod;

  struct {
    IFACE_ENTRY client;
    IFACE_ENTRY engine;
    IFACE_ENTRY schema;
  } iface;

  VECTOR<NETVAR_ENTRY> netvars; 
};