forked from w3gh/gproxyplusplus
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Two new commands /track <username> & /trackoff This will /whois username every 4 seconds, and once they are in-game, it will automatically search for that users game via /game gamename. This will also play track_done.wav once the player is in-game. This is to notify the user is in-game, and GProxy is searching for their game name. Code was provided by a previous suggestion made in 2011. (w3gh#5) • Sound notification works/tested on Windows/Mac. • track_done.wav provided with compiled GProxy on ENT Gaming Wiki.
- Loading branch information
Showing
7 changed files
with
176 additions
and
0 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
#include "gettimeofday.h" | ||
|
||
#ifdef WIN32 | ||
|
||
int gettimeofday(struct timeval *tv, struct timezone *tz) | ||
{ | ||
FILETIME ft; | ||
unsigned __int64 tmpres = 0; | ||
static int tzflag; | ||
|
||
if (NULL != tv) | ||
{ | ||
GetSystemTimeAsFileTime(&ft); | ||
|
||
tmpres |= ft.dwHighDateTime; | ||
tmpres <<= 32; | ||
tmpres |= ft.dwLowDateTime; | ||
|
||
/*converting file time to unix epoch*/ | ||
tmpres -= DELTA_EPOCH_IN_MICROSECS; | ||
tmpres /= 10; /*convert into microseconds*/ | ||
tv->tv_sec = (long)(tmpres / 1000000UL); | ||
tv->tv_usec = (long)(tmpres % 1000000UL); | ||
} | ||
|
||
if (NULL != tz) | ||
{ | ||
if (!tzflag) | ||
{ | ||
_tzset(); | ||
tzflag; | ||
} | ||
tz->tz_minuteswest = _timezone / 60; | ||
tz->tz_dsttime = _daylight; | ||
} | ||
|
||
return 0; | ||
} | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#ifndef GETTIMEOFDAY_H | ||
#define GETTIMEOFDAY_H | ||
|
||
#ifdef WIN32 | ||
#include < time.h > | ||
#include <windows.h> | ||
#if defined(_MSC_VER) || defined(_MSC_EXTENSIONS) | ||
#define DELTA_EPOCH_IN_MICROSECS 11644473600000000Ui64 | ||
#else | ||
#define DELTA_EPOCH_IN_MICROSECS 11644473600000000ULL | ||
#endif | ||
|
||
struct timezone | ||
{ | ||
int tz_minuteswest; /* minutes W of Greenwich */ | ||
int tz_dsttime; /* type of dst correction */ | ||
}; | ||
|
||
int gettimeofday(struct timeval *, struct timezone *); | ||
|
||
#else | ||
|
||
#include <sys/time.h> | ||
|
||
#endif | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters