PDA

View Full Version : Menu items



rolandsh
27-05-09, 07:27
so i used RH base and i added menu but i need to add cvars , ,how i can do that , i did if (!vis_chams) bla bla bla (code) but it says definer vis_chams not found , so i add to sdk.h , float vis_chams , soo i did , when i compile it says error , vis_chams already exist at client.obj or smth like that , how can i fix it?? please.

Sorry for asking here but rh forums is down.

rolandsh
27-05-09, 09:51
HELP!@

BlehNOWScenetickiller
28-05-09, 09:49
No.

You would do.

(CPP)
This will act like a Settings.

#include "sdk.h"
#include "cvars.h"

CvarList Cvars ----- ( or you can make "Cvars" whatever you want, so when you type Cvars. it pops up with all your cvars)

CvarList::CvarList()
{
Cvars = 1.0;
}
Easy right?

The .H would be this :

#include "sdk.h"
#ifndef __MYCVARS_H__
#define __MYCVARS_H__

Class CvarList
{
public:
CvarList();
float cvar_here, cvar_here, cvar_here;
float cvar_here, cvar_Here, cvar_HERE;
};

extern CvarList Cvars (or whatever you put in the first cpp)
#endif


Hope it worked for you.