601e772daf
ReservedSlot: kick people with 0 idle time too, add back rule 4: alive non-donator, idle > 30, no item
160 lines
2.3 KiB
SourcePawn
160 lines
2.3 KiB
SourcePawn
#if defined entWatch_class_item_included
|
|
#endinput
|
|
#endif
|
|
|
|
#define entWatch_class_item_included
|
|
|
|
methodmap CItem < Basic
|
|
{
|
|
public CItem(CConfig value = view_as<CConfig>(INVALID_HANDLE))
|
|
{
|
|
Basic myclass = new Basic();
|
|
|
|
myclass.SetHandle("dConfig", value);
|
|
|
|
myclass.SetInt("iClient", INVALID_ENT_REFERENCE);
|
|
myclass.SetInt("iButton", INVALID_ENT_REFERENCE);
|
|
myclass.SetInt("iWeapon", INVALID_ENT_REFERENCE);
|
|
myclass.SetInt("iTrigger", INVALID_ENT_REFERENCE);
|
|
|
|
myclass.SetInt("iTimesUsed", 0);
|
|
myclass.SetFloat("flTimeReady", 0.0);
|
|
|
|
myclass.SetFloat("flWait", 0.0);
|
|
|
|
return view_as<CItem>(myclass);
|
|
}
|
|
|
|
|
|
property CConfig dConfig
|
|
{
|
|
public get()
|
|
{
|
|
return view_as<CConfig>(this.GetHandle("dConfig"));
|
|
}
|
|
public set(CConfig value)
|
|
{
|
|
this.SetHandle("dConfig", value);
|
|
}
|
|
}
|
|
|
|
|
|
property int iClient
|
|
{
|
|
public get()
|
|
{
|
|
return this.GetInt("iClient");
|
|
}
|
|
public set(int value)
|
|
{
|
|
this.SetInt("iClient", value);
|
|
}
|
|
}
|
|
|
|
property int iButton
|
|
{
|
|
public get()
|
|
{
|
|
return this.GetInt("iButton");
|
|
}
|
|
public set(int value)
|
|
{
|
|
this.SetInt("iButton", value);
|
|
}
|
|
}
|
|
|
|
property int iWeapon
|
|
{
|
|
public get()
|
|
{
|
|
return this.GetInt("iWeapon");
|
|
}
|
|
public set(int value)
|
|
{
|
|
this.SetInt("iWeapon", value);
|
|
}
|
|
}
|
|
|
|
property int iTrigger
|
|
{
|
|
public get()
|
|
{
|
|
return this.GetInt("iTrigger");
|
|
}
|
|
public set(int value)
|
|
{
|
|
this.SetInt("iTrigger", value);
|
|
}
|
|
}
|
|
|
|
|
|
property int iTimesUsed
|
|
{
|
|
public get()
|
|
{
|
|
return this.GetInt("iTimesUsed");
|
|
}
|
|
public set(int value)
|
|
{
|
|
this.SetInt("iTimesUsed", value);
|
|
}
|
|
}
|
|
|
|
property float flTimeReady
|
|
{
|
|
public get()
|
|
{
|
|
return this.GetFloat("flTimeReady");
|
|
}
|
|
public set(float value)
|
|
{
|
|
this.SetFloat("flTimeReady", value);
|
|
}
|
|
}
|
|
|
|
property float flWait
|
|
{
|
|
public get()
|
|
{
|
|
return this.GetFloat("flWait");
|
|
}
|
|
public set(float value)
|
|
{
|
|
this.SetFloat("flWait", value);
|
|
}
|
|
}
|
|
|
|
|
|
property bool bClient
|
|
{
|
|
public get()
|
|
{
|
|
return view_as<bool>(this.iClient != INVALID_ENT_REFERENCE);
|
|
}
|
|
}
|
|
|
|
property bool bButton
|
|
{
|
|
public get()
|
|
{
|
|
return view_as<bool>(this.iButton != INVALID_ENT_REFERENCE);
|
|
}
|
|
}
|
|
|
|
property bool bWeapon
|
|
{
|
|
public get()
|
|
{
|
|
return view_as<bool>(this.iWeapon != INVALID_ENT_REFERENCE);
|
|
}
|
|
}
|
|
|
|
property bool bTrigger
|
|
{
|
|
public get()
|
|
{
|
|
return view_as<bool>(this.iTrigger != INVALID_ENT_REFERENCE);
|
|
}
|
|
}
|
|
}
|