Jump to content

Photo

Execute Function


  • Please log in to reply
2 replies to this topic

#1 DarkArlene Posted 08 August 2015 - 12:36 PM

DarkArlene

    Soldier

  • Members
  • Pip
  • 2 posts

Hello,

great library by the way. It helped me in so many things.

 

Anyway I'm trying to execute some functions from vtable and i got stuck.

virtual bool	IsInGame( void )

Works very easily

public static bool  IsInGame() { return AppMemory[GetFunction(Pointer, 26), false].Execute<bool>(); }

How about This one :

virtual void	ExecuteCmd( const char *CmdString )

Even easier

public static void  ExecuteCmd(string cmd) { AppMemory[GetFunction(Pointer, 33), false].Execute(cmd); }

Now i'm wondering how do i execute function when paramaters are references like this one :

virtual void	GetScreenSize( int& width, int& height )

  • Back to top
  • Report

#2 PappenPeter Posted 28 November 2015 - 08:45 PM

PappenPeter

    Soldier

  • Members
  • Pip
  • 4 posts

FXALBMm.png

 

well the only difference is you will need a Vector2 :)


  • Back to top
  • Report

#3 DarkArlene Posted 05 December 2015 - 02:21 PM

DarkArlene

    Soldier

  • Members
  • Pip
  • 2 posts

FXALBMm.png

 

well the only difference is you will need a Vector2 :)

 

So if i understand well if i got this function that has as parameters 2 references

 

GetScreenSize( int& width, int& height )

 

I use Vector2 as returning value and i get those two results ?


Edited by DarkArlene, 05 December 2015 - 02:22 PM.

  • Back to top
  • Report




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users