mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 04:37:00 +00:00
Merge commit 'origin/master' into 310
This commit is contained in:
commit
55d6fbe3cb
46 changed files with 325 additions and 1369 deletions
|
|
@ -160,10 +160,6 @@ EXTRA_DIST += \
|
|||
postgre/pg_type.h \
|
||||
postgre/postgres_ext.h
|
||||
|
||||
# SQLite header files for Win32 builds
|
||||
EXTRA_DIST += \
|
||||
sqlite/sqlite.h
|
||||
|
||||
# Sockets header files for Win32 builds
|
||||
EXTRA_DIST += \
|
||||
sockets\Base64.h \
|
||||
|
|
|
|||
|
|
@ -1,834 +0,0 @@
|
|||
/*
|
||||
** 2001 September 15
|
||||
**
|
||||
** The author disclaims copyright to this source code. In place of
|
||||
** a legal notice, here is a blessing:
|
||||
**
|
||||
** May you do good and not evil.
|
||||
** May you find forgiveness for yourself and forgive others.
|
||||
** May you share freely, never taking more than you give.
|
||||
**
|
||||
*************************************************************************
|
||||
** This header file defines the interface that the SQLite library
|
||||
** presents to client programs.
|
||||
**
|
||||
** @(#) $Id: sqlite.h,v 1.3 2004/06/29 01:57:36 silent Exp $
|
||||
*/
|
||||
#ifndef _SQLITE_H_
|
||||
#define _SQLITE_H_
|
||||
#include <stdarg.h> /* Needed for the definition of va_list */
|
||||
|
||||
/*
|
||||
** Make sure we can call this stuff from C++.
|
||||
*/
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/*
|
||||
** The version of the SQLite library.
|
||||
*/
|
||||
#define SQLITE_VERSION "2.8.13"
|
||||
|
||||
/*
|
||||
** The version string is also compiled into the library so that a program
|
||||
** can check to make sure that the lib*.a file and the *.h file are from
|
||||
** the same version.
|
||||
*/
|
||||
extern const char sqlite_version[];
|
||||
|
||||
/*
|
||||
** The SQLITE_UTF8 macro is defined if the library expects to see
|
||||
** UTF-8 encoded data. The SQLITE_ISO8859 macro is defined if the
|
||||
** iso8859 encoded should be used.
|
||||
*/
|
||||
#define SQLITE_ISO8859 1
|
||||
|
||||
/*
|
||||
** The following constant holds one of two strings, "UTF-8" or "iso8859",
|
||||
** depending on which character encoding the SQLite library expects to
|
||||
** see. The character encoding makes a difference for the LIKE and GLOB
|
||||
** operators and for the LENGTH() and SUBSTR() functions.
|
||||
*/
|
||||
extern const char sqlite_encoding[];
|
||||
|
||||
/*
|
||||
** Each open sqlite database is represented by an instance of the
|
||||
** following opaque structure.
|
||||
*/
|
||||
typedef struct sqlite sqlite;
|
||||
|
||||
/*
|
||||
** A function to open a new sqlite database.
|
||||
**
|
||||
** If the database does not exist and mode indicates write
|
||||
** permission, then a new database is created. If the database
|
||||
** does not exist and mode does not indicate write permission,
|
||||
** then the open fails, an error message generated (if errmsg!=0)
|
||||
** and the function returns 0.
|
||||
**
|
||||
** If mode does not indicates user write permission, then the
|
||||
** database is opened read-only.
|
||||
**
|
||||
** The Truth: As currently implemented, all databases are opened
|
||||
** for writing all the time. Maybe someday we will provide the
|
||||
** ability to open a database readonly. The mode parameters is
|
||||
** provided in anticipation of that enhancement.
|
||||
*/
|
||||
sqlite *sqlite_open(const char *filename, int mode, char **errmsg);
|
||||
|
||||
/*
|
||||
** A function to close the database.
|
||||
**
|
||||
** Call this function with a pointer to a structure that was previously
|
||||
** returned from sqlite_open() and the corresponding database will by closed.
|
||||
*/
|
||||
void sqlite_close(sqlite *);
|
||||
|
||||
/*
|
||||
** The type for a callback function.
|
||||
*/
|
||||
typedef int (*sqlite_callback)(void*,int,char**, char**);
|
||||
|
||||
/*
|
||||
** A function to executes one or more statements of SQL.
|
||||
**
|
||||
** If one or more of the SQL statements are queries, then
|
||||
** the callback function specified by the 3rd parameter is
|
||||
** invoked once for each row of the query result. This callback
|
||||
** should normally return 0. If the callback returns a non-zero
|
||||
** value then the query is aborted, all subsequent SQL statements
|
||||
** are skipped and the sqlite_exec() function returns the SQLITE_ABORT.
|
||||
**
|
||||
** The 4th parameter is an arbitrary pointer that is passed
|
||||
** to the callback function as its first parameter.
|
||||
**
|
||||
** The 2nd parameter to the callback function is the number of
|
||||
** columns in the query result. The 3rd parameter to the callback
|
||||
** is an array of strings holding the values for each column.
|
||||
** The 4th parameter to the callback is an array of strings holding
|
||||
** the names of each column.
|
||||
**
|
||||
** The callback function may be NULL, even for queries. A NULL
|
||||
** callback is not an error. It just means that no callback
|
||||
** will be invoked.
|
||||
**
|
||||
** If an error occurs while parsing or evaluating the SQL (but
|
||||
** not while executing the callback) then an appropriate error
|
||||
** message is written into memory obtained from malloc() and
|
||||
** *errmsg is made to point to that message. The calling function
|
||||
** is responsible for freeing the memory that holds the error
|
||||
** message. Use sqlite_freemem() for this. If errmsg==NULL,
|
||||
** then no error message is ever written.
|
||||
**
|
||||
** The return value is is SQLITE_OK if there are no errors and
|
||||
** some other return code if there is an error. The particular
|
||||
** return value depends on the type of error.
|
||||
**
|
||||
** If the query could not be executed because a database file is
|
||||
** locked or busy, then this function returns SQLITE_BUSY. (This
|
||||
** behavior can be modified somewhat using the sqlite_busy_handler()
|
||||
** and sqlite_busy_timeout() functions below.)
|
||||
*/
|
||||
int sqlite_exec(
|
||||
sqlite*, /* An open database */
|
||||
const char *sql, /* SQL to be executed */
|
||||
sqlite_callback, /* Callback function */
|
||||
void *, /* 1st argument to callback function */
|
||||
char **errmsg /* Error msg written here */
|
||||
);
|
||||
|
||||
/*
|
||||
** Return values for sqlite_exec() and sqlite_step()
|
||||
*/
|
||||
#define SQLITE_OK 0 /* Successful result */
|
||||
#define SQLITE_ERROR 1 /* SQL error or missing database */
|
||||
#define SQLITE_INTERNAL 2 /* An internal logic error in SQLite */
|
||||
#define SQLITE_PERM 3 /* Access permission denied */
|
||||
#define SQLITE_ABORT 4 /* Callback routine requested an abort */
|
||||
#define SQLITE_BUSY 5 /* The database file is locked */
|
||||
#define SQLITE_LOCKED 6 /* A table in the database is locked */
|
||||
#define SQLITE_NOMEM 7 /* A malloc() failed */
|
||||
#define SQLITE_READONLY 8 /* Attempt to write a readonly database */
|
||||
#define SQLITE_INTERRUPT 9 /* Operation terminated by sqlite_interrupt() */
|
||||
#define SQLITE_IOERR 10 /* Some kind of disk I/O error occurred */
|
||||
#define SQLITE_CORRUPT 11 /* The database disk image is malformed */
|
||||
#define SQLITE_NOTFOUND 12 /* (Internal Only) Table or record not found */
|
||||
#define SQLITE_FULL 13 /* Insertion failed because database is full */
|
||||
#define SQLITE_CANTOPEN 14 /* Unable to open the database file */
|
||||
#define SQLITE_PROTOCOL 15 /* Database lock protocol error */
|
||||
#define SQLITE_EMPTY 16 /* (Internal Only) Database table is empty */
|
||||
#define SQLITE_SCHEMA 17 /* The database schema changed */
|
||||
#define SQLITE_TOOBIG 18 /* Too much data for one row of a table */
|
||||
#define SQLITE_CONSTRAINT 19 /* Abort due to contraint violation */
|
||||
#define SQLITE_MISMATCH 20 /* Data type mismatch */
|
||||
#define SQLITE_MISUSE 21 /* Library used incorrectly */
|
||||
#define SQLITE_NOLFS 22 /* Uses OS features not supported on host */
|
||||
#define SQLITE_AUTH 23 /* Authorization denied */
|
||||
#define SQLITE_FORMAT 24 /* Auxiliary database format error */
|
||||
#define SQLITE_RANGE 25 /* 2nd parameter to sqlite_bind out of range */
|
||||
#define SQLITE_NOTADB 26 /* File opened that is not a database file */
|
||||
#define SQLITE_ROW 100 /* sqlite_step() has another row ready */
|
||||
#define SQLITE_DONE 101 /* sqlite_step() has finished executing */
|
||||
|
||||
/*
|
||||
** Each entry in an SQLite table has a unique integer key. (The key is
|
||||
** the value of the INTEGER PRIMARY KEY column if there is such a column,
|
||||
** otherwise the key is generated at random. The unique key is always
|
||||
** available as the ROWID, OID, or _ROWID_ column.) The following routine
|
||||
** returns the integer key of the most recent insert in the database.
|
||||
**
|
||||
** This function is similar to the mysql_insert_id() function from MySQL.
|
||||
*/
|
||||
int sqlite_last_insert_rowid(sqlite*);
|
||||
|
||||
/*
|
||||
** This function returns the number of database rows that were changed
|
||||
** (or inserted or deleted) by the most recent called sqlite_exec().
|
||||
**
|
||||
** All changes are counted, even if they were later undone by a
|
||||
** ROLLBACK or ABORT. Except, changes associated with creating and
|
||||
** dropping tables are not counted.
|
||||
**
|
||||
** If a callback invokes sqlite_exec() recursively, then the changes
|
||||
** in the inner, recursive call are counted together with the changes
|
||||
** in the outer call.
|
||||
**
|
||||
** SQLite implements the command "DELETE FROM table" without a WHERE clause
|
||||
** by dropping and recreating the table. (This is much faster than going
|
||||
** through and deleting individual elements form the table.) Because of
|
||||
** this optimization, the change count for "DELETE FROM table" will be
|
||||
** zero regardless of the number of elements that were originally in the
|
||||
** table. To get an accurate count of the number of rows deleted, use
|
||||
** "DELETE FROM table WHERE 1" instead.
|
||||
*/
|
||||
int sqlite_changes(sqlite*);
|
||||
|
||||
/*
|
||||
** This function returns the number of database rows that were changed
|
||||
** by the last INSERT, UPDATE, or DELETE statment executed by sqlite_exec(),
|
||||
** or by the last VM to run to completion. The change count is not updated
|
||||
** by SQL statements other than INSERT, UPDATE or DELETE.
|
||||
**
|
||||
** Changes are counted, even if they are later undone by a ROLLBACK or
|
||||
** ABORT. Changes associated with trigger programs that execute as a
|
||||
** result of the INSERT, UPDATE, or DELETE statement are not counted.
|
||||
**
|
||||
** If a callback invokes sqlite_exec() recursively, then the changes
|
||||
** in the inner, recursive call are counted together with the changes
|
||||
** in the outer call.
|
||||
**
|
||||
** SQLite implements the command "DELETE FROM table" without a WHERE clause
|
||||
** by dropping and recreating the table. (This is much faster than going
|
||||
** through and deleting individual elements form the table.) Because of
|
||||
** this optimization, the change count for "DELETE FROM table" will be
|
||||
** zero regardless of the number of elements that were originally in the
|
||||
** table. To get an accurate count of the number of rows deleted, use
|
||||
** "DELETE FROM table WHERE 1" instead.
|
||||
**
|
||||
******* THIS IS AN EXPERIMENTAL API AND IS SUBJECT TO CHANGE ******
|
||||
*/
|
||||
int sqlite_last_statement_changes(sqlite*);
|
||||
|
||||
/* If the parameter to this routine is one of the return value constants
|
||||
** defined above, then this routine returns a constant text string which
|
||||
** descripts (in English) the meaning of the return value.
|
||||
*/
|
||||
const char *sqlite_error_string(int);
|
||||
#define sqliteErrStr sqlite_error_string /* Legacy. Do not use in new code. */
|
||||
|
||||
/* This function causes any pending database operation to abort and
|
||||
** return at its earliest opportunity. This routine is typically
|
||||
** called in response to a user action such as pressing "Cancel"
|
||||
** or Ctrl-C where the user wants a long query operation to halt
|
||||
** immediately.
|
||||
*/
|
||||
void sqlite_interrupt(sqlite*);
|
||||
|
||||
|
||||
/* This function returns true if the given input string comprises
|
||||
** one or more complete SQL statements.
|
||||
**
|
||||
** The algorithm is simple. If the last token other than spaces
|
||||
** and comments is a semicolon, then return true. otherwise return
|
||||
** false.
|
||||
*/
|
||||
int sqlite_complete(const char *sql);
|
||||
|
||||
/*
|
||||
** This routine identifies a callback function that is invoked
|
||||
** whenever an attempt is made to open a database table that is
|
||||
** currently locked by another process or thread. If the busy callback
|
||||
** is NULL, then sqlite_exec() returns SQLITE_BUSY immediately if
|
||||
** it finds a locked table. If the busy callback is not NULL, then
|
||||
** sqlite_exec() invokes the callback with three arguments. The
|
||||
** second argument is the name of the locked table and the third
|
||||
** argument is the number of times the table has been busy. If the
|
||||
** busy callback returns 0, then sqlite_exec() immediately returns
|
||||
** SQLITE_BUSY. If the callback returns non-zero, then sqlite_exec()
|
||||
** tries to open the table again and the cycle repeats.
|
||||
**
|
||||
** The default busy callback is NULL.
|
||||
**
|
||||
** Sqlite is re-entrant, so the busy handler may start a new query.
|
||||
** (It is not clear why anyone would every want to do this, but it
|
||||
** is allowed, in theory.) But the busy handler may not close the
|
||||
** database. Closing the database from a busy handler will delete
|
||||
** data structures out from under the executing query and will
|
||||
** probably result in a coredump.
|
||||
*/
|
||||
void sqlite_busy_handler(sqlite*, int(*)(void*,const char*,int), void*);
|
||||
|
||||
/*
|
||||
** This routine sets a busy handler that sleeps for a while when a
|
||||
** table is locked. The handler will sleep multiple times until
|
||||
** at least "ms" milleseconds of sleeping have been done. After
|
||||
** "ms" milleseconds of sleeping, the handler returns 0 which
|
||||
** causes sqlite_exec() to return SQLITE_BUSY.
|
||||
**
|
||||
** Calling this routine with an argument less than or equal to zero
|
||||
** turns off all busy handlers.
|
||||
*/
|
||||
void sqlite_busy_timeout(sqlite*, int ms);
|
||||
|
||||
/*
|
||||
** This next routine is really just a wrapper around sqlite_exec().
|
||||
** Instead of invoking a user-supplied callback for each row of the
|
||||
** result, this routine remembers each row of the result in memory
|
||||
** obtained from malloc(), then returns all of the result after the
|
||||
** query has finished.
|
||||
**
|
||||
** As an example, suppose the query result where this table:
|
||||
**
|
||||
** Name | Age
|
||||
** -----------------------
|
||||
** Alice | 43
|
||||
** Bob | 28
|
||||
** Cindy | 21
|
||||
**
|
||||
** If the 3rd argument were &azResult then after the function returns
|
||||
** azResult will contain the following data:
|
||||
**
|
||||
** azResult[0] = "Name";
|
||||
** azResult[1] = "Age";
|
||||
** azResult[2] = "Alice";
|
||||
** azResult[3] = "43";
|
||||
** azResult[4] = "Bob";
|
||||
** azResult[5] = "28";
|
||||
** azResult[6] = "Cindy";
|
||||
** azResult[7] = "21";
|
||||
**
|
||||
** Notice that there is an extra row of data containing the column
|
||||
** headers. But the *nrow return value is still 3. *ncolumn is
|
||||
** set to 2. In general, the number of values inserted into azResult
|
||||
** will be ((*nrow) + 1)*(*ncolumn).
|
||||
**
|
||||
** After the calling function has finished using the result, it should
|
||||
** pass the result data pointer to sqlite_free_table() in order to
|
||||
** release the memory that was malloc-ed. Because of the way the
|
||||
** malloc() happens, the calling function must not try to call
|
||||
** malloc() directly. Only sqlite_free_table() is able to release
|
||||
** the memory properly and safely.
|
||||
**
|
||||
** The return value of this routine is the same as from sqlite_exec().
|
||||
*/
|
||||
int sqlite_get_table(
|
||||
sqlite*, /* An open database */
|
||||
const char *sql, /* SQL to be executed */
|
||||
char ***resultp, /* Result written to a char *[] that this points to */
|
||||
int *nrow, /* Number of result rows written here */
|
||||
int *ncolumn, /* Number of result columns written here */
|
||||
char **errmsg /* Error msg written here */
|
||||
);
|
||||
|
||||
/*
|
||||
** Call this routine to free the memory that sqlite_get_table() allocated.
|
||||
*/
|
||||
void sqlite_free_table(char **result);
|
||||
|
||||
/*
|
||||
** The following routines are wrappers around sqlite_exec() and
|
||||
** sqlite_get_table(). The only difference between the routines that
|
||||
** follow and the originals is that the second argument to the
|
||||
** routines that follow is really a printf()-style format
|
||||
** string describing the SQL to be executed. Arguments to the format
|
||||
** string appear at the end of the argument list.
|
||||
**
|
||||
** All of the usual printf formatting options apply. In addition, there
|
||||
** is a "%q" option. %q works like %s in that it substitutes a null-terminated
|
||||
** string from the argument list. But %q also doubles every '\'' character.
|
||||
** %q is designed for use inside a string literal. By doubling each '\''
|
||||
** character it escapes that character and allows it to be inserted into
|
||||
** the string.
|
||||
**
|
||||
** For example, so some string variable contains text as follows:
|
||||
**
|
||||
** char *zText = "It's a happy day!";
|
||||
**
|
||||
** We can use this text in an SQL statement as follows:
|
||||
**
|
||||
** sqlite_exec_printf(db, "INSERT INTO table VALUES('%q')",
|
||||
** callback1, 0, 0, zText);
|
||||
**
|
||||
** Because the %q format string is used, the '\'' character in zText
|
||||
** is escaped and the SQL generated is as follows:
|
||||
**
|
||||
** INSERT INTO table1 VALUES('It''s a happy day!')
|
||||
**
|
||||
** This is correct. Had we used %s instead of %q, the generated SQL
|
||||
** would have looked like this:
|
||||
**
|
||||
** INSERT INTO table1 VALUES('It's a happy day!');
|
||||
**
|
||||
** This second example is an SQL syntax error. As a general rule you
|
||||
** should always use %q instead of %s when inserting text into a string
|
||||
** literal.
|
||||
*/
|
||||
int sqlite_exec_printf(
|
||||
sqlite*, /* An open database */
|
||||
const char *sqlFormat, /* printf-style format string for the SQL */
|
||||
sqlite_callback, /* Callback function */
|
||||
void *, /* 1st argument to callback function */
|
||||
char **errmsg, /* Error msg written here */
|
||||
... /* Arguments to the format string. */
|
||||
);
|
||||
int sqlite_exec_vprintf(
|
||||
sqlite*, /* An open database */
|
||||
const char *sqlFormat, /* printf-style format string for the SQL */
|
||||
sqlite_callback, /* Callback function */
|
||||
void *, /* 1st argument to callback function */
|
||||
char **errmsg, /* Error msg written here */
|
||||
va_list ap /* Arguments to the format string. */
|
||||
);
|
||||
int sqlite_get_table_printf(
|
||||
sqlite*, /* An open database */
|
||||
const char *sqlFormat, /* printf-style format string for the SQL */
|
||||
char ***resultp, /* Result written to a char *[] that this points to */
|
||||
int *nrow, /* Number of result rows written here */
|
||||
int *ncolumn, /* Number of result columns written here */
|
||||
char **errmsg, /* Error msg written here */
|
||||
... /* Arguments to the format string */
|
||||
);
|
||||
int sqlite_get_table_vprintf(
|
||||
sqlite*, /* An open database */
|
||||
const char *sqlFormat, /* printf-style format string for the SQL */
|
||||
char ***resultp, /* Result written to a char *[] that this points to */
|
||||
int *nrow, /* Number of result rows written here */
|
||||
int *ncolumn, /* Number of result columns written here */
|
||||
char **errmsg, /* Error msg written here */
|
||||
va_list ap /* Arguments to the format string */
|
||||
);
|
||||
char *sqlite_mprintf(const char*,...);
|
||||
char *sqlite_vmprintf(const char*, va_list);
|
||||
|
||||
/*
|
||||
** Windows systems should call this routine to free memory that
|
||||
** is returned in the in the errmsg parameter of sqlite_open() when
|
||||
** SQLite is a DLL. For some reason, it does not work to call free()
|
||||
** directly.
|
||||
*/
|
||||
void sqlite_freemem(void *p);
|
||||
|
||||
/*
|
||||
** Windows systems need functions to call to return the sqlite_version
|
||||
** and sqlite_encoding strings.
|
||||
*/
|
||||
const char *sqlite_libversion(void);
|
||||
const char *sqlite_libencoding(void);
|
||||
|
||||
/*
|
||||
** A pointer to the following structure is used to communicate with
|
||||
** the implementations of user-defined functions.
|
||||
*/
|
||||
typedef struct sqlite_func sqlite_func;
|
||||
|
||||
/*
|
||||
** Use the following routines to create new user-defined functions. See
|
||||
** the documentation for details.
|
||||
*/
|
||||
int sqlite_create_function(
|
||||
sqlite*, /* Database where the new function is registered */
|
||||
const char *zName, /* Name of the new function */
|
||||
int nArg, /* Number of arguments. -1 means any number */
|
||||
void (*xFunc)(sqlite_func*,int,const char**), /* C code to implement */
|
||||
void *pUserData /* Available via the sqlite_user_data() call */
|
||||
);
|
||||
int sqlite_create_aggregate(
|
||||
sqlite*, /* Database where the new function is registered */
|
||||
const char *zName, /* Name of the function */
|
||||
int nArg, /* Number of arguments */
|
||||
void (*xStep)(sqlite_func*,int,const char**), /* Called for each row */
|
||||
void (*xFinalize)(sqlite_func*), /* Called once to get final result */
|
||||
void *pUserData /* Available via the sqlite_user_data() call */
|
||||
);
|
||||
|
||||
/*
|
||||
** Use the following routine to define the datatype returned by a
|
||||
** user-defined function. The second argument can be one of the
|
||||
** constants SQLITE_NUMERIC, SQLITE_TEXT, or SQLITE_ARGS or it
|
||||
** can be an integer greater than or equal to zero. When the datatype
|
||||
** parameter is non-negative, the type of the result will be the
|
||||
** same as the datatype-th argument. If datatype==SQLITE_NUMERIC
|
||||
** then the result is always numeric. If datatype==SQLITE_TEXT then
|
||||
** the result is always text. If datatype==SQLITE_ARGS then the result
|
||||
** is numeric if any argument is numeric and is text otherwise.
|
||||
*/
|
||||
int sqlite_function_type(
|
||||
sqlite *db, /* The database there the function is registered */
|
||||
const char *zName, /* Name of the function */
|
||||
int datatype /* The datatype for this function */
|
||||
);
|
||||
#define SQLITE_NUMERIC (-1)
|
||||
#define SQLITE_TEXT (-2)
|
||||
#define SQLITE_ARGS (-3)
|
||||
|
||||
/*
|
||||
** The user function implementations call one of the following four routines
|
||||
** in order to return their results. The first parameter to each of these
|
||||
** routines is a copy of the first argument to xFunc() or xFinialize().
|
||||
** The second parameter to these routines is the result to be returned.
|
||||
** A NULL can be passed as the second parameter to sqlite_set_result_string()
|
||||
** in order to return a NULL result.
|
||||
**
|
||||
** The 3rd argument to _string and _error is the number of characters to
|
||||
** take from the string. If this argument is negative, then all characters
|
||||
** up to and including the first '\000' are used.
|
||||
**
|
||||
** The sqlite_set_result_string() function allocates a buffer to hold the
|
||||
** result and returns a pointer to this buffer. The calling routine
|
||||
** (that is, the implmentation of a user function) can alter the content
|
||||
** of this buffer if desired.
|
||||
*/
|
||||
char *sqlite_set_result_string(sqlite_func*,const char*,int);
|
||||
void sqlite_set_result_int(sqlite_func*,int);
|
||||
void sqlite_set_result_double(sqlite_func*,double);
|
||||
void sqlite_set_result_error(sqlite_func*,const char*,int);
|
||||
|
||||
/*
|
||||
** The pUserData parameter to the sqlite_create_function() and
|
||||
** sqlite_create_aggregate() routines used to register user functions
|
||||
** is available to the implementation of the function using this
|
||||
** call.
|
||||
*/
|
||||
void *sqlite_user_data(sqlite_func*);
|
||||
|
||||
/*
|
||||
** Aggregate functions use the following routine to allocate
|
||||
** a structure for storing their state. The first time this routine
|
||||
** is called for a particular aggregate, a new structure of size nBytes
|
||||
** is allocated, zeroed, and returned. On subsequent calls (for the
|
||||
** same aggregate instance) the same buffer is returned. The implementation
|
||||
** of the aggregate can use the returned buffer to accumulate data.
|
||||
**
|
||||
** The buffer allocated is freed automatically be SQLite.
|
||||
*/
|
||||
void *sqlite_aggregate_context(sqlite_func*, int nBytes);
|
||||
|
||||
/*
|
||||
** The next routine returns the number of calls to xStep for a particular
|
||||
** aggregate function instance. The current call to xStep counts so this
|
||||
** routine always returns at least 1.
|
||||
*/
|
||||
int sqlite_aggregate_count(sqlite_func*);
|
||||
|
||||
/*
|
||||
** This routine registers a callback with the SQLite library. The
|
||||
** callback is invoked (at compile-time, not at run-time) for each
|
||||
** attempt to access a column of a table in the database. The callback
|
||||
** returns SQLITE_OK if access is allowed, SQLITE_DENY if the entire
|
||||
** SQL statement should be aborted with an error and SQLITE_IGNORE
|
||||
** if the column should be treated as a NULL value.
|
||||
*/
|
||||
int sqlite_set_authorizer(
|
||||
sqlite*,
|
||||
int (*xAuth)(void*,int,const char*,const char*,const char*,const char*),
|
||||
void *pUserData
|
||||
);
|
||||
|
||||
/*
|
||||
** The second parameter to the access authorization function above will
|
||||
** be one of the values below. These values signify what kind of operation
|
||||
** is to be authorized. The 3rd and 4th parameters to the authorization
|
||||
** function will be parameters or NULL depending on which of the following
|
||||
** codes is used as the second parameter. The 5th parameter is the name
|
||||
** of the database ("main", "temp", etc.) if applicable. The 6th parameter
|
||||
** is the name of the inner-most trigger or view that is responsible for
|
||||
** the access attempt or NULL if this access attempt is directly from
|
||||
** input SQL code.
|
||||
**
|
||||
** Arg-3 Arg-4
|
||||
*/
|
||||
#define SQLITE_COPY 0 /* Table Name File Name */
|
||||
#define SQLITE_CREATE_INDEX 1 /* Index Name Table Name */
|
||||
#define SQLITE_CREATE_TABLE 2 /* Table Name NULL */
|
||||
#define SQLITE_CREATE_TEMP_INDEX 3 /* Index Name Table Name */
|
||||
#define SQLITE_CREATE_TEMP_TABLE 4 /* Table Name NULL */
|
||||
#define SQLITE_CREATE_TEMP_TRIGGER 5 /* Trigger Name Table Name */
|
||||
#define SQLITE_CREATE_TEMP_VIEW 6 /* View Name NULL */
|
||||
#define SQLITE_CREATE_TRIGGER 7 /* Trigger Name Table Name */
|
||||
#define SQLITE_CREATE_VIEW 8 /* View Name NULL */
|
||||
#define SQLITE_DELETE 9 /* Table Name NULL */
|
||||
#define SQLITE_DROP_INDEX 10 /* Index Name Table Name */
|
||||
#define SQLITE_DROP_TABLE 11 /* Table Name NULL */
|
||||
#define SQLITE_DROP_TEMP_INDEX 12 /* Index Name Table Name */
|
||||
#define SQLITE_DROP_TEMP_TABLE 13 /* Table Name NULL */
|
||||
#define SQLITE_DROP_TEMP_TRIGGER 14 /* Trigger Name Table Name */
|
||||
#define SQLITE_DROP_TEMP_VIEW 15 /* View Name NULL */
|
||||
#define SQLITE_DROP_TRIGGER 16 /* Trigger Name Table Name */
|
||||
#define SQLITE_DROP_VIEW 17 /* View Name NULL */
|
||||
#define SQLITE_INSERT 18 /* Table Name NULL */
|
||||
#define SQLITE_PRAGMA 19 /* Pragma Name 1st arg or NULL */
|
||||
#define SQLITE_READ 20 /* Table Name Column Name */
|
||||
#define SQLITE_SELECT 21 /* NULL NULL */
|
||||
#define SQLITE_TRANSACTION 22 /* NULL NULL */
|
||||
#define SQLITE_UPDATE 23 /* Table Name Column Name */
|
||||
#define SQLITE_ATTACH 24 /* Filename NULL */
|
||||
#define SQLITE_DETACH 25 /* Database Name NULL */
|
||||
|
||||
|
||||
/*
|
||||
** The return value of the authorization function should be one of the
|
||||
** following constants:
|
||||
*/
|
||||
/* #define SQLITE_OK 0 // Allow access (This is actually defined above) */
|
||||
#define SQLITE_DENY 1 /* Abort the SQL statement with an error */
|
||||
#define SQLITE_IGNORE 2 /* Don't allow access, but don't generate an error */
|
||||
|
||||
/*
|
||||
** Register a function that is called at every invocation of sqlite_exec()
|
||||
** or sqlite_compile(). This function can be used (for example) to generate
|
||||
** a log file of all SQL executed against a database.
|
||||
*/
|
||||
void *sqlite_trace(sqlite*, void(*xTrace)(void*,const char*), void*);
|
||||
|
||||
/*** The Callback-Free API
|
||||
**
|
||||
** The following routines implement a new way to access SQLite that does not
|
||||
** involve the use of callbacks.
|
||||
**
|
||||
** An sqlite_vm is an opaque object that represents a single SQL statement
|
||||
** that is ready to be executed.
|
||||
*/
|
||||
typedef struct sqlite_vm sqlite_vm;
|
||||
|
||||
/*
|
||||
** To execute an SQLite query without the use of callbacks, you first have
|
||||
** to compile the SQL using this routine. The 1st parameter "db" is a pointer
|
||||
** to an sqlite object obtained from sqlite_open(). The 2nd parameter
|
||||
** "zSql" is the text of the SQL to be compiled. The remaining parameters
|
||||
** are all outputs.
|
||||
**
|
||||
** *pzTail is made to point to the first character past the end of the first
|
||||
** SQL statement in zSql. This routine only compiles the first statement
|
||||
** in zSql, so *pzTail is left pointing to what remains uncompiled.
|
||||
**
|
||||
** *ppVm is left pointing to a "virtual machine" that can be used to execute
|
||||
** the compiled statement. Or if there is an error, *ppVm may be set to NULL.
|
||||
** If the input text contained no SQL (if the input is and empty string or
|
||||
** a comment) then *ppVm is set to NULL.
|
||||
**
|
||||
** If any errors are detected during compilation, an error message is written
|
||||
** into space obtained from malloc() and *pzErrMsg is made to point to that
|
||||
** error message. The calling routine is responsible for freeing the text
|
||||
** of this message when it has finished with it. Use sqlite_freemem() to
|
||||
** free the message. pzErrMsg may be NULL in which case no error message
|
||||
** will be generated.
|
||||
**
|
||||
** On success, SQLITE_OK is returned. Otherwise and error code is returned.
|
||||
*/
|
||||
int sqlite_compile(
|
||||
sqlite *db, /* The open database */
|
||||
const char *zSql, /* SQL statement to be compiled */
|
||||
const char **pzTail, /* OUT: uncompiled tail of zSql */
|
||||
sqlite_vm **ppVm, /* OUT: the virtual machine to execute zSql */
|
||||
char **pzErrmsg /* OUT: Error message. */
|
||||
);
|
||||
|
||||
/*
|
||||
** After an SQL statement has been compiled, it is handed to this routine
|
||||
** to be executed. This routine executes the statement as far as it can
|
||||
** go then returns. The return value will be one of SQLITE_DONE,
|
||||
** SQLITE_ERROR, SQLITE_BUSY, SQLITE_ROW, or SQLITE_MISUSE.
|
||||
**
|
||||
** SQLITE_DONE means that the execute of the SQL statement is complete
|
||||
** an no errors have occurred. sqlite_step() should not be called again
|
||||
** for the same virtual machine. *pN is set to the number of columns in
|
||||
** the result set and *pazColName is set to an array of strings that
|
||||
** describe the column names and datatypes. The name of the i-th column
|
||||
** is (*pazColName)[i] and the datatype of the i-th column is
|
||||
** (*pazColName)[i+*pN]. *pazValue is set to NULL.
|
||||
**
|
||||
** SQLITE_ERROR means that the virtual machine encountered a run-time
|
||||
** error. sqlite_step() should not be called again for the same
|
||||
** virtual machine. *pN is set to 0 and *pazColName and *pazValue are set
|
||||
** to NULL. Use sqlite_finalize() to obtain the specific error code
|
||||
** and the error message text for the error.
|
||||
**
|
||||
** SQLITE_BUSY means that an attempt to open the database failed because
|
||||
** another thread or process is holding a lock. The calling routine
|
||||
** can try again to open the database by calling sqlite_step() again.
|
||||
** The return code will only be SQLITE_BUSY if no busy handler is registered
|
||||
** using the sqlite_busy_handler() or sqlite_busy_timeout() routines. If
|
||||
** a busy handler callback has been registered but returns 0, then this
|
||||
** routine will return SQLITE_ERROR and sqltie_finalize() will return
|
||||
** SQLITE_BUSY when it is called.
|
||||
**
|
||||
** SQLITE_ROW means that a single row of the result is now available.
|
||||
** The data is contained in *pazValue. The value of the i-th column is
|
||||
** (*azValue)[i]. *pN and *pazColName are set as described in SQLITE_DONE.
|
||||
** Invoke sqlite_step() again to advance to the next row.
|
||||
**
|
||||
** SQLITE_MISUSE is returned if sqlite_step() is called incorrectly.
|
||||
** For example, if you call sqlite_step() after the virtual machine
|
||||
** has halted (after a prior call to sqlite_step() has returned SQLITE_DONE)
|
||||
** or if you call sqlite_step() with an incorrectly initialized virtual
|
||||
** machine or a virtual machine that has been deleted or that is associated
|
||||
** with an sqlite structure that has been closed.
|
||||
*/
|
||||
int sqlite_step(
|
||||
sqlite_vm *pVm, /* The virtual machine to execute */
|
||||
int *pN, /* OUT: Number of columns in result */
|
||||
const char ***pazValue, /* OUT: Column data */
|
||||
const char ***pazColName /* OUT: Column names and datatypes */
|
||||
);
|
||||
|
||||
/*
|
||||
** This routine is called to delete a virtual machine after it has finished
|
||||
** executing. The return value is the result code. SQLITE_OK is returned
|
||||
** if the statement executed successfully and some other value is returned if
|
||||
** there was any kind of error. If an error occurred and pzErrMsg is not
|
||||
** NULL, then an error message is written into memory obtained from malloc()
|
||||
** and *pzErrMsg is made to point to that error message. The calling routine
|
||||
** should use sqlite_freemem() to delete this message when it has finished
|
||||
** with it.
|
||||
**
|
||||
** This routine can be called at any point during the execution of the
|
||||
** virtual machine. If the virtual machine has not completed execution
|
||||
** when this routine is called, that is like encountering an error or
|
||||
** an interrupt. (See sqlite_interrupt().) Incomplete updates may be
|
||||
** rolled back and transactions cancelled, depending on the circumstances,
|
||||
** and the result code returned will be SQLITE_ABORT.
|
||||
*/
|
||||
int sqlite_finalize(sqlite_vm*, char **pzErrMsg);
|
||||
|
||||
/*
|
||||
** This routine deletes the virtual machine, writes any error message to
|
||||
** *pzErrMsg and returns an SQLite return code in the same way as the
|
||||
** sqlite_finalize() function.
|
||||
**
|
||||
** Additionally, if ppVm is not NULL, *ppVm is left pointing to a new virtual
|
||||
** machine loaded with the compiled version of the original query ready for
|
||||
** execution.
|
||||
**
|
||||
** If sqlite_reset() returns SQLITE_SCHEMA, then *ppVm is set to NULL.
|
||||
**
|
||||
******* THIS IS AN EXPERIMENTAL API AND IS SUBJECT TO CHANGE ******
|
||||
*/
|
||||
int sqlite_reset(sqlite_vm*, char **pzErrMsg);
|
||||
|
||||
/*
|
||||
** If the SQL that was handed to sqlite_compile contains variables that
|
||||
** are represeted in the SQL text by a question mark ('?'). This routine
|
||||
** is used to assign values to those variables.
|
||||
**
|
||||
** The first parameter is a virtual machine obtained from sqlite_compile().
|
||||
** The 2nd "idx" parameter determines which variable in the SQL statement
|
||||
** to bind the value to. The left most '?' is 1. The 3rd parameter is
|
||||
** the value to assign to that variable. The 4th parameter is the number
|
||||
** of bytes in the value, including the terminating \000 for strings.
|
||||
** Finally, the 5th "copy" parameter is TRUE if SQLite should make its
|
||||
** own private copy of this value, or false if the space that the 3rd
|
||||
** parameter points to will be unchanging and can be used directly by
|
||||
** SQLite.
|
||||
**
|
||||
** Unbound variables are treated as having a value of NULL. To explicitly
|
||||
** set a variable to NULL, call this routine with the 3rd parameter as a
|
||||
** NULL pointer.
|
||||
**
|
||||
** If the 4th "len" parameter is -1, then strlen() is used to find the
|
||||
** length.
|
||||
**
|
||||
** This routine can only be called immediately after sqlite_compile()
|
||||
** or sqlite_reset() and before any calls to sqlite_step().
|
||||
**
|
||||
******* THIS IS AN EXPERIMENTAL API AND IS SUBJECT TO CHANGE ******
|
||||
*/
|
||||
int sqlite_bind(sqlite_vm*, int idx, const char *value, int len, int copy);
|
||||
|
||||
/*
|
||||
** This routine configures a callback function - the progress callback - that
|
||||
** is invoked periodically during long running calls to sqlite_exec(),
|
||||
** sqlite_step() and sqlite_get_table(). An example use for this API is to keep
|
||||
** a GUI updated during a large query.
|
||||
**
|
||||
** The progress callback is invoked once for every N virtual machine opcodes,
|
||||
** where N is the second argument to this function. The progress callback
|
||||
** itself is identified by the third argument to this function. The fourth
|
||||
** argument to this function is a void pointer passed to the progress callback
|
||||
** function each time it is invoked.
|
||||
**
|
||||
** If a call to sqlite_exec(), sqlite_step() or sqlite_get_table() results
|
||||
** in less than N opcodes being executed, then the progress callback is not
|
||||
** invoked.
|
||||
**
|
||||
** Calling this routine overwrites any previously installed progress callback.
|
||||
** To remove the progress callback altogether, pass NULL as the third
|
||||
** argument to this function.
|
||||
**
|
||||
** If the progress callback returns a result other than 0, then the current
|
||||
** query is immediately terminated and any database changes rolled back. If the
|
||||
** query was part of a larger transaction, then the transaction is not rolled
|
||||
** back and remains active. The sqlite_exec() call returns SQLITE_ABORT.
|
||||
**
|
||||
******* THIS IS AN EXPERIMENTAL API AND IS SUBJECT TO CHANGE ******
|
||||
*/
|
||||
void sqlite_progress_handler(sqlite*, int, int(*)(void*), void*);
|
||||
|
||||
/*
|
||||
** Register a callback function to be invoked whenever a new transaction
|
||||
** is committed. The pArg argument is passed through to the callback.
|
||||
** callback. If the callback function returns non-zero, then the commit
|
||||
** is converted into a rollback.
|
||||
**
|
||||
** If another function was previously registered, its pArg value is returned.
|
||||
** Otherwise NULL is returned.
|
||||
**
|
||||
** Registering a NULL function disables the callback.
|
||||
**
|
||||
******* THIS IS AN EXPERIMENTAL API AND IS SUBJECT TO CHANGE ******
|
||||
*/
|
||||
void *sqlite_commit_hook(sqlite*, int(*)(void*), void*);
|
||||
|
||||
/*
|
||||
** Open an encrypted SQLite database. If pKey==0 or nKey==0, this routine
|
||||
** is the same as sqlite_open().
|
||||
**
|
||||
** The code to implement this API is not available in the public release
|
||||
** of SQLite.
|
||||
*/
|
||||
sqlite *sqlite_open_encrypted(
|
||||
const char *zFilename, /* Name of the encrypted database */
|
||||
const void *pKey, /* Pointer to the key */
|
||||
int nKey, /* Number of bytes in the key */
|
||||
int *pErrcode, /* Write error code here */
|
||||
char **pzErrmsg /* Write error message here */
|
||||
);
|
||||
|
||||
/*
|
||||
** Change the key on an open database. If the current database is not
|
||||
** encrypted, this routine will encrypt it. If pNew==0 or nNew==0, the
|
||||
** database is decrypted.
|
||||
**
|
||||
** The code to implement this API is not available in the public release
|
||||
** of SQLite.
|
||||
*/
|
||||
int sqlite_rekey(
|
||||
sqlite *db, /* Database to be rekeyed */
|
||||
const void *pKey, int nKey /* The new key */
|
||||
);
|
||||
|
||||
#ifdef __cplusplus
|
||||
} /* End of the 'extern "C"' block */
|
||||
#endif
|
||||
|
||||
#endif /* _SQLITE_H_ */
|
||||
|
|
@ -24,16 +24,14 @@ EXTRA_DIST = \
|
|||
win32_debug/libeay32.dll \
|
||||
win32_debug/libeay32.lib \
|
||||
win32_debug/libmySQL.dll \
|
||||
win32_debug/libmySQL.lib \
|
||||
win32_debug/sqlite.lib
|
||||
win32_debug/libmySQL.lib
|
||||
|
||||
# Release libraries for Win32 builds.
|
||||
EXTRA_DIST += \
|
||||
win32_release/libeay32.dll \
|
||||
win32_release/libeay32.lib \
|
||||
win32_release/libmySQL.dll \
|
||||
win32_release/libmySQL.lib \
|
||||
win32_release/sqlite.lib
|
||||
win32_release/libmySQL.lib
|
||||
|
||||
# Debug libraries for Win64 builds.
|
||||
EXTRA_DIST += \
|
||||
|
|
|
|||
Binary file not shown.
Binary file not shown.
|
|
@ -23,7 +23,7 @@ DROP TABLE IF EXISTS `db_version`;
|
|||
CREATE TABLE `db_version` (
|
||||
`version` varchar(120) default NULL,
|
||||
`creature_ai_version` varchar(120) default NULL,
|
||||
`required_7662_02_mangos_spell_bonus_data` bit(1) default NULL
|
||||
`required_7706_01_mangos_command` bit(1) default NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 ROW_FORMAT=FIXED COMMENT='Used DB version notes';
|
||||
|
||||
--
|
||||
|
|
@ -258,7 +258,9 @@ INSERT INTO `command` VALUES
|
|||
('account',0,'Syntax: .account\r\n\r\nDisplay the access level of your account.'),
|
||||
('account create',4,'Syntax: .account create $account $password\r\n\r\nCreate account and set password to it.'),
|
||||
('account delete',4,'Syntax: .account delete $account\r\n\r\nDelete account with all characters.'),
|
||||
('account lock',0,'Syntax: .account lock [on|off]\r\n\r\nAllow login from account only from current used IP or remove this requirement.'),
|
||||
('account onlinelist',4,'Syntax: .account onlinelist\r\n\r\nShow list of online accounts.'),
|
||||
('account password',0,'Syntax: .account password $old_password $new_password $new_password\r\n\r\nChange your account password.'),
|
||||
('account set addon',3,'Syntax: .account set addon [$account] #addon\r\n\r\nSet user (possible targeted) expansion addon level allowed. Addon values: 0 - normal, 1 - tbc, 2 - wotlk.'),
|
||||
('account set gmlevel',4,'Syntax: .account set gmlevel [$account] #level\r\n\r\nSet the security level for targeted player (can''t be used at self) or for account $name to a level of #level.\r\n\r\n#level may range from 0 to 3.'),
|
||||
('account set password',4,'Syntax: .account set password $account $password $password\r\n\r\nSet password for account.'),
|
||||
|
|
@ -281,7 +283,9 @@ INSERT INTO `command` VALUES
|
|||
('cast dist',3,'Syntax: .cast dist #spellid [#dist [triggered]]\r\n You will cast spell to pint at distance #dist. If \'trigered\' or part provided then spell casted with triggered flag. Not all spells can be casted as area spells.'),
|
||||
('cast self',3,'Syntax: .cast self #spellid [triggered]\r\nCast #spellid by target at target itself. If \'trigered\' or part provided then spell casted with triggered flag.'),
|
||||
('cast target',3,'Syntax: .cast target #spellid [triggered]\r\n Selected target will cast #spellid to his victim. If \'trigered\' or part provided then spell casted with triggered flag.'),
|
||||
('chardelete',4,'Syntax: .chardelete $charactername\r\n\r\nDelete character.'),
|
||||
('character customize',2,'Syntax: .character customize [$name]\r\n\r\nMark selected in game or by $name in command character for customize at next login.'),
|
||||
('character delete',4,'Syntax: .character delete $name\r\n\r\nDelete character $name.'),
|
||||
('character rename',2,'Syntax: .character rename [$name]\r\n\r\nMark selected in game or by $name in command character for rename at next login.'),
|
||||
('combatstop',2,'Syntax: .combatstop [$playername]\r\nStop combat for selected character. If selected non-player then command applied to self. If $playername provided then attempt applied to online player $playername.'),
|
||||
('commands',0,'Syntax: .commands\r\n\r\nDisplay a list of available commands for your account level.'),
|
||||
('cooldown',3,'Syntax: .cooldown [#spell_id]\r\n\r\nRemove all (if spell_id not provided) or #spel_id spell cooldown from selected character or you (if no selection).'),
|
||||
|
|
@ -367,7 +371,6 @@ INSERT INTO `command` VALUES
|
|||
('list item',3,'Syntax: .list item #item_id [#max_count]\r\n\r\nOutput items with item id #item_id found in all character inventories, mails, auctions, and guild banks. Output item guids, item owner guid, owner account and owner name (guild name and guid in case guild bank). Will be output maximum #max_count items. If #max_count not provided use 10 as default value.'),
|
||||
('list object',3,'Syntax: .list object #gameobject_id [#max_count]\r\n\r\nOutput gameobjects with gameobject id #gameobject_id found in world. Output gameobject guids and coordinates sorted by distance from character. Will be output maximum #max_count gameobject. If #max_count not provided use 10 as default value.'),
|
||||
('loadscripts',3,'Syntax: .loadscripts $scriptlibraryname\r\n\r\nUnload current and load the script library $scriptlibraryname or reload current if $scriptlibraryname omitted, in case you changed it while the server was running.'),
|
||||
('lockaccount',0,'Syntax: .lockaccount [on|off]\r\n\r\nAllow login from account only from current used IP or remove this requirement.'),
|
||||
('lookup area',1,'Syntax: .lookup area $namepart\r\n\r\nLooks up an area by $namepart, and returns all matches with their area ID\'s.'),
|
||||
('lookup creature',3,'Syntax: .lookup creature $namepart\r\n\r\nLooks up a creature by $namepart, and returns all matches with their creature ID\'s.'),
|
||||
('lookup event',2,'Syntax: .lookup event $name\r\nAttempts to find the ID of the event with the provided $name.'),
|
||||
|
|
@ -438,11 +441,9 @@ INSERT INTO `command` VALUES
|
|||
('npc textemote',1,'Syntax: .npc textemote #emoteid\r\n\r\nMake the selected creature to do textemote with an emote of id #emoteid.'),
|
||||
('npc whisper',1,'Syntax: .npc whisper #playerguid #text\r\nMake the selected npc whisper #text to #playerguid.'),
|
||||
('npc unfollow',2,'Syntax: .npc unfollow\r\n\r\nSelected creature (non pet) stop follow you.'),
|
||||
('password',0,'Syntax: .password $old_password $new_password $new_password\r\n\r\nChange your account password.'),
|
||||
('pdump write',3,'Syntax: .pdump write $filename $playerNameOrGUID\r\nWrite character dump with name/guid $playerNameOrGUID to file $filename.'),
|
||||
('pdump load',3,'Syntax: .pdump load $filename $account [$newname] [$newguid]\r\nLoad character dump from dump file into character list of $account with saved or $newname, with saved (or first free) or $newguid guid.'),
|
||||
('pinfo',2,'Syntax: .pinfo [$player_name] [rep]\r\n\r\nOutput account information for selected player or player find by $player_name. If \"rep\" parameter provided show reputation information for player.'),
|
||||
('plimit',3,'Syntax: .plimit [#num|-1|-2|-3|reset|player|moderator|gamemaster|administrator]\r\n\r\nWithout arg show current player amount and security level limitations for login to server, with arg set player linit ($num > 0) or securiti limitation ($num < 0 or security leme name. With `reset` sets player limit to the one in the config file'),
|
||||
('quest add',3,'Syntax: .quest add #quest_id\r\n\r\nAdd to character quest log quest #quest_id. Quest started from item can\'t be added by this command but correct .additem call provided in command output.'),
|
||||
('quest complete',3,'Syntax: .quest complete #questid\r\nMark all quest objectives as completed for target character active quest. After this target character can go and get quest reward.'),
|
||||
('quest remove',3,'Syntax: .quest remove #quest_id\r\n\r\nSet quest #quest_id state to not completed and not active (and remove from active quest list) for selected player.'),
|
||||
|
|
@ -478,6 +479,7 @@ INSERT INTO `command` VALUES
|
|||
('server idlerestart',3,'Syntax: .server idlerestart #delay\r\n\r\nRestart the server after #delay seconds if no active connections are present (no players). Use #exist_code or 2 as program exist code.'),
|
||||
('server idlerestart cancel',3,'Syntax: .server idlerestart cancel\r\n\r\nCancel the restart/shutdown timer if any.'),
|
||||
('server motd',0,'Syntax: .server motd\r\n\r\nShow server Message of the day.'),
|
||||
('server plimit',3,'Syntax: .server plimit [#num|-1|-2|-3|reset|player|moderator|gamemaster|administrator]\r\n\r\nWithout arg show current player amount and security level limitations for login to server, with arg set player linit ($num > 0) or securiti limitation ($num < 0 or security leme name. With `reset` sets player limit to the one in the config file'),
|
||||
('server restart',3,'Syntax: .server restart #delay\r\n\r\nRestart the server after #delay seconds. Use #exist_code or 2 as program exist code.'),
|
||||
('server restart cancel',3,'Syntax: .server restart cancel\r\n\r\nCancel the restart/shutdown timer if any.'),
|
||||
('server set loglevel',4,'Syntax: .server set loglevel #level\r\n\r\nSet server log level (0 - errors only, 1 - basic, 2 - detail, 3 - debug).'),
|
||||
|
|
|
|||
13
sql/updates/7705_01_mangos_command.sql
Normal file
13
sql/updates/7705_01_mangos_command.sql
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
ALTER TABLE db_version CHANGE COLUMN required_7662_02_mangos_spell_bonus_data required_7705_01_mangos_command bit;
|
||||
|
||||
DELETE FROM `command` WHERE `name` IN (
|
||||
'account lock','account password','chardelete','character customize','character delete',
|
||||
'character rename','customize','lockaccount','password','rename'
|
||||
);
|
||||
|
||||
INSERT INTO `command` VALUES
|
||||
('account lock',0,'Syntax: .account lock [on|off]\r\n\r\nAllow login from account only from current used IP or remove this requirement.'),
|
||||
('account password',0,'Syntax: .account password $old_password $new_password $new_password\r\n\r\nChange your account password.'),
|
||||
('character customize',2,'Syntax: .character customize [$name]\r\n\r\nMark selected in game or by $name in command character for customize at next login.'),
|
||||
('character delete',4,'Syntax: .character delete $name\r\n\r\nDelete character $name.'),
|
||||
('character rename',2,'Syntax: .character rename [$name]\r\n\r\nMark selected in game or by $name in command character for rename at next login.');
|
||||
6
sql/updates/7706_01_mangos_command.sql
Normal file
6
sql/updates/7706_01_mangos_command.sql
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
ALTER TABLE db_version CHANGE COLUMN required_7705_01_mangos_command required_7706_01_mangos_command bit;
|
||||
|
||||
DELETE FROM `command` WHERE `name` IN ('plimit','server plimit');
|
||||
|
||||
INSERT INTO `command` VALUES
|
||||
('server plimit',3,'Syntax: .server plimit [#num|-1|-2|-3|reset|player|moderator|gamemaster|administrator]\r\n\r\nWithout arg show current player amount and security level limitations for login to server, with arg set player linit ($num > 0) or securiti limitation ($num < 0 or security leme name. With `reset` sets player limit to the one in the config file');
|
||||
|
|
@ -173,6 +173,8 @@ pkgdata_DATA = \
|
|||
7644_01_characters_character_pet.sql \
|
||||
7662_01_mangos_spell_chain.sql \
|
||||
7662_02_mangos_spell_bonus_data.sql \
|
||||
7705_01_mangos_command.sql \
|
||||
7706_01_mangos_command.sql \
|
||||
README
|
||||
|
||||
## Additional files to include when running 'make dist'
|
||||
|
|
@ -326,4 +328,6 @@ EXTRA_DIST = \
|
|||
7644_01_characters_character_pet.sql \
|
||||
7662_01_mangos_spell_chain.sql \
|
||||
7662_02_mangos_spell_bonus_data.sql \
|
||||
7705_01_mangos_command.sql \
|
||||
7706_01_mangos_command.sql \
|
||||
README
|
||||
|
|
|
|||
|
|
@ -314,6 +314,7 @@ void ScriptedAI::UpdateAI(const uint32)
|
|||
|
||||
void ScriptedAI::EnterEvadeMode()
|
||||
{
|
||||
m_creature->CombatStop(true);
|
||||
if( m_creature->isAlive() )
|
||||
DoGoHome();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -250,6 +250,41 @@ void AchievementMgr::Reset()
|
|||
CheckAllAchievementCriteria();
|
||||
}
|
||||
|
||||
void AchievementMgr::ResetAchievementCriteria(AchievementCriteriaTypes type, uint32 miscvalue1, uint32 miscvalue2)
|
||||
{
|
||||
if((sLog.getLogFilter() & LOG_FILTER_ACHIEVEMENT_UPDATES)==0)
|
||||
sLog.outDetail("AchievementMgr::ResetAchievementCriteria(%u, %u, %u)", type, miscvalue1, miscvalue2);
|
||||
|
||||
if (!sWorld.getConfig(CONFIG_GM_ALLOW_ACHIEVEMENT_GAINS) && m_player->GetSession()->GetSecurity() > SEC_PLAYER)
|
||||
return;
|
||||
|
||||
AchievementCriteriaEntryList const& achievementCriteriaList = achievementmgr.GetAchievementCriteriaByType(type);
|
||||
for(AchievementCriteriaEntryList::const_iterator i = achievementCriteriaList.begin(); i!=achievementCriteriaList.end(); ++i)
|
||||
{
|
||||
AchievementCriteriaEntry const *achievementCriteria = (*i);
|
||||
|
||||
AchievementEntry const *achievement = sAchievementStore.LookupEntry(achievementCriteria->referredAchievement);
|
||||
if (!achievement)
|
||||
continue;
|
||||
|
||||
// don't update already completed criteria
|
||||
if (IsCompletedCriteria(achievementCriteria,achievement))
|
||||
continue;
|
||||
|
||||
switch (type)
|
||||
{
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_DAMAGE_DONE: // have total statistic also not expected to be reset
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HEALING_DONE: // have total statistic also not expected to be reset
|
||||
if (achievementCriteria->healing_done.flag == miscvalue1 &&
|
||||
achievementCriteria->healing_done.mapid == miscvalue2)
|
||||
SetCriteriaProgress(achievementCriteria, 0, PROGRESS_SET);
|
||||
break;
|
||||
default: // reset all cases
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void AchievementMgr::DeleteFromDB(uint32 lowguid)
|
||||
{
|
||||
CharacterDatabase.BeginTransaction ();
|
||||
|
|
@ -538,6 +573,8 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
|
|||
case ACHIEVEMENT_CRITERIA_TYPE_GOLD_SPENT_AT_BARBER:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_GOLD_SPENT_FOR_MAIL:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_LOOT_MONEY:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_TOTAL_DAMAGE_RECEIVED:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_TOTAL_HEALING_RECEIVED:
|
||||
// AchievementMgr::UpdateAchievementCriteria might also be called on login - skip in this case
|
||||
if(!miscvalue1)
|
||||
continue;
|
||||
|
|
@ -546,6 +583,10 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
|
|||
// std case: high value at miscvalue1
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_AUCTION_BID:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_AUCTION_SOLD: /* FIXME: for online player only currently */
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HIT_DEALT:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HIT_RECEIVED:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HEAL_CASTED:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HEALING_RECEIVED:
|
||||
// AchievementMgr::UpdateAchievementCriteria might also be called on login - skip in this case
|
||||
if(!miscvalue1)
|
||||
continue;
|
||||
|
|
@ -814,10 +855,10 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
|
|||
SetCriteriaProgress(achievementCriteria, 1, PROGRESS_ACCUMULATE);
|
||||
break;
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_LEARN_SPELL:
|
||||
// spell always provide and at login spell learning.
|
||||
if(miscvalue1 && miscvalue1!=achievementCriteria->learn_spell.spellID)
|
||||
continue;
|
||||
if(GetPlayer()->HasSpell(miscvalue1))
|
||||
|
||||
if(GetPlayer()->HasSpell(achievementCriteria->learn_spell.spellID))
|
||||
SetCriteriaProgress(achievementCriteria, 1);
|
||||
break;
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_OWN_ITEM:
|
||||
|
|
@ -937,6 +978,25 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
|
|||
SetCriteriaProgress(achievementCriteria, 1, PROGRESS_ACCUMULATE);
|
||||
break;
|
||||
}
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_DAMAGE_DONE:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HEALING_DONE:
|
||||
{
|
||||
if (!miscvalue1)
|
||||
continue;
|
||||
|
||||
if (achievementCriteria->healing_done.flag == ACHIEVEMENT_CRITERIA_CONDITION_MAP)
|
||||
{
|
||||
if(GetPlayer()->GetMapId() != achievementCriteria->healing_done.mapid)
|
||||
continue;
|
||||
|
||||
// map specific case (BG in fact) expected player targeted damage/heal
|
||||
if(!unit || unit->GetTypeId()!=TYPEID_PLAYER)
|
||||
continue;
|
||||
}
|
||||
|
||||
SetCriteriaProgress(achievementCriteria, miscvalue1, PROGRESS_ACCUMULATE);
|
||||
break;
|
||||
}
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_EQUIP_ITEM:
|
||||
// miscvalue1 = item_id
|
||||
if(!miscvalue1)
|
||||
|
|
@ -1033,6 +1093,9 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
|
|||
SetCriteriaProgress(achievementCriteria, spellCount);
|
||||
break;
|
||||
}
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_EARN_HONORABLE_KILL:
|
||||
SetCriteriaProgress(achievementCriteria, GetPlayer()->GetUInt32Value(PLAYER_FIELD_LIFETIME_HONORBALE_KILLS));
|
||||
break;
|
||||
// std case: not exist in DBC, not triggered in code as result
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HEALTH:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_SPELLPOWER:
|
||||
|
|
@ -1044,7 +1107,6 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
|
|||
// FIXME: not triggered in code as result, need to implement
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_WIN_BG:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_COMPLETE_DAILY_QUEST_DAILY:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_DAMAGE_DONE:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_COMPLETE_RAID:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_BG_OBJECTIVE_CAPTURE:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HONORABLE_KILL_AT_AREA:
|
||||
|
|
@ -1058,7 +1120,6 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
|
|||
case ACHIEVEMENT_CRITERIA_TYPE_EQUIP_EPIC_ITEM:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HK_CLASS:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HK_RACE:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HEALING_DONE:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_GET_KILLING_BLOWS:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_MONEY_FROM_VENDORS:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_NUMBER_OF_TALENT_RESETS:
|
||||
|
|
@ -1074,16 +1135,9 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
|
|||
case ACHIEVEMENT_CRITERIA_TYPE_RECEIVE_EPIC_ITEM:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_ROLL_NEED:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_ROLL_GREED:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HIT_DEALT:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HIT_RECEIVED:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_TOTAL_DAMAGE_RECEIVED:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HEAL_CASTED:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_TOTAL_HEALING_RECEIVED:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HEALING_RECEIVED:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_QUEST_ABANDONED:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_FLIGHT_PATHS_TAKEN:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_LOOT_TYPE:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_EARN_HONORABLE_KILL:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_ACCEPTED_SUMMONINGS:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_TOTAL:
|
||||
break; // Not implemented yet :(
|
||||
|
|
@ -1194,6 +1248,9 @@ bool AchievementMgr::IsCompletedCriteria(AchievementCriteriaEntry const* achieve
|
|||
return progress->counter >= achievementCriteria->roll_greed_on_loot.count;
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_DO_EMOTE:
|
||||
return progress->counter >= achievementCriteria->do_emote.count;
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_DAMAGE_DONE:
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_HEALING_DONE:
|
||||
return progress->counter >= achievementCriteria->healing_done.count;
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_EQUIP_ITEM:
|
||||
return progress->counter >= achievementCriteria->equip_item.count;
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_MONEY_FROM_QUEST_REWARD:
|
||||
|
|
@ -1208,6 +1265,8 @@ bool AchievementMgr::IsCompletedCriteria(AchievementCriteriaEntry const* achieve
|
|||
return progress->counter >= achievementCriteria->learn_skillline_spell.spellCount;
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_LEARN_SKILL_LINE:
|
||||
return progress->counter >= achievementCriteria->learn_skill_line.spellCount;
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_EARN_HONORABLE_KILL:
|
||||
return progress->counter >= achievementCriteria->honorable_kill.killCount;
|
||||
|
||||
// handle all statistic-only criteria here
|
||||
case ACHIEVEMENT_CRITERIA_TYPE_COMPLETE_BATTLEGROUND:
|
||||
|
|
|
|||
|
|
@ -169,6 +169,7 @@ class AchievementMgr
|
|||
static void DeleteFromDB(uint32 lowguid);
|
||||
void LoadFromDB(QueryResult *achievementResult, QueryResult *criteriaResult);
|
||||
void SaveToDB();
|
||||
void ResetAchievementCriteria(AchievementCriteriaTypes type, uint32 miscvalue1=0, uint32 miscvalue2=0);
|
||||
void UpdateAchievementCriteria(AchievementCriteriaTypes type, uint32 miscvalue1=0, uint32 miscvalue2=0, Unit *unit=NULL, uint32 time=0);
|
||||
void CheckAllAchievementCriteria();
|
||||
void SendAllAchievementData();
|
||||
|
|
|
|||
|
|
@ -73,7 +73,7 @@ void AggressorAI::EnterEvadeMode()
|
|||
{
|
||||
DEBUG_LOG("Creature stopped attacking cuz his dead [guid=%u]", m_creature->GetGUIDLow());
|
||||
i_victimGuid = 0;
|
||||
m_creature->CombatStop();
|
||||
m_creature->CombatStop(true);
|
||||
m_creature->DeleteThreatList();
|
||||
return;
|
||||
}
|
||||
|
|
@ -114,7 +114,7 @@ void AggressorAI::EnterEvadeMode()
|
|||
|
||||
m_creature->DeleteThreatList();
|
||||
i_victimGuid = 0;
|
||||
m_creature->CombatStop();
|
||||
m_creature->CombatStop(true);
|
||||
m_creature->SetLootRecipient(NULL);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1115,6 +1115,9 @@ void BattleGround::AddPlayer(Player *plr)
|
|||
plr->CastSpell(plr, SPELL_PREPARATION, true); // reduces all mana cost of spells.
|
||||
}
|
||||
|
||||
plr->GetAchievementMgr().ResetAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_HEALING_DONE, ACHIEVEMENT_CRITERIA_CONDITION_MAP, GetMapId());
|
||||
plr->GetAchievementMgr().ResetAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_DAMAGE_DONE, ACHIEVEMENT_CRITERIA_CONDITION_MAP, GetMapId());
|
||||
|
||||
// setup BG group membership
|
||||
PlayerAddedToBGCheckIfBGIsRunning(plr);
|
||||
AddOrSetPlayerToCorrectBgGroup(plr, guid, team);
|
||||
|
|
|
|||
|
|
@ -66,7 +66,9 @@ ChatCommand * ChatHandler::getCommandTable()
|
|||
{ "create", SEC_CONSOLE, true, &ChatHandler::HandleAccountCreateCommand, "", NULL },
|
||||
{ "delete", SEC_CONSOLE, true, &ChatHandler::HandleAccountDeleteCommand, "", NULL },
|
||||
{ "onlinelist", SEC_CONSOLE, true, &ChatHandler::HandleAccountOnlineListCommand, "", NULL },
|
||||
{ "lock", SEC_PLAYER, false, &ChatHandler::HandleAccountLockCommand, "", NULL },
|
||||
{ "set", SEC_ADMINISTRATOR, true, NULL, "", accountSetCommandTable },
|
||||
{ "password", SEC_PLAYER, false, &ChatHandler::HandleAccountPasswordCommand, "", NULL },
|
||||
{ "", SEC_PLAYER, false, &ChatHandler::HandleAccountCommand, "", NULL },
|
||||
{ NULL, 0, false, NULL, "", NULL }
|
||||
};
|
||||
|
|
@ -105,6 +107,14 @@ ChatCommand * ChatHandler::getCommandTable()
|
|||
{ NULL, 0, false, NULL, "", NULL }
|
||||
};
|
||||
|
||||
static ChatCommand characterCommandTable[] =
|
||||
{
|
||||
{ "rename", SEC_GAMEMASTER, true, &ChatHandler::HandleCharacterRenameCommand, "", NULL },
|
||||
{ "customize", SEC_GAMEMASTER, true, &ChatHandler::HandleCharacterCustomizeCommand, "", NULL },
|
||||
{ "delete", SEC_CONSOLE, true, &ChatHandler::HandleCharacterDeleteCommand, "", NULL },
|
||||
{ NULL, 0, false, NULL, "", NULL }
|
||||
};
|
||||
|
||||
static ChatCommand debugPlayCommandTable[] =
|
||||
{
|
||||
{ "cinematic", SEC_MODERATOR, false, &ChatHandler::HandleDebugPlayCinematicCommand, "", NULL },
|
||||
|
|
@ -171,11 +181,11 @@ ChatCommand * ChatHandler::getCommandTable()
|
|||
|
||||
static ChatCommand goCommandTable[] =
|
||||
{
|
||||
{ "grid", SEC_MODERATOR, false, &ChatHandler::HandleGoGridCommand, "", NULL },
|
||||
{ "creature", SEC_MODERATOR, false, &ChatHandler::HandleGoCreatureCommand, "", NULL },
|
||||
{ "graveyard", SEC_MODERATOR, false, &ChatHandler::HandleGoGraveyardCommand, "", NULL },
|
||||
{ "grid", SEC_MODERATOR, false, &ChatHandler::HandleGoGridCommand, "", NULL },
|
||||
{ "object", SEC_MODERATOR, false, &ChatHandler::HandleGoObjectCommand, "", NULL },
|
||||
{ "trigger", SEC_MODERATOR, false, &ChatHandler::HandleGoTriggerCommand, "", NULL },
|
||||
{ "graveyard", SEC_MODERATOR, false, &ChatHandler::HandleGoGraveyardCommand, "", NULL },
|
||||
{ "zonexy", SEC_MODERATOR, false, &ChatHandler::HandleGoZoneXYCommand, "", NULL },
|
||||
{ "xy", SEC_MODERATOR, false, &ChatHandler::HandleGoXYCommand, "", NULL },
|
||||
{ "xyz", SEC_MODERATOR, false, &ChatHandler::HandleGoXYZCommand, "", NULL },
|
||||
|
|
@ -501,6 +511,7 @@ ChatCommand * ChatHandler::getCommandTable()
|
|||
{ "idleshutdown", SEC_ADMINISTRATOR, true, NULL, "", serverShutdownCommandTable },
|
||||
{ "info", SEC_PLAYER, true, &ChatHandler::HandleServerInfoCommand, "", NULL },
|
||||
{ "motd", SEC_PLAYER, true, &ChatHandler::HandleServerMotdCommand, "", NULL },
|
||||
{ "plimit", SEC_ADMINISTRATOR, true, &ChatHandler::HandleServerPLimitCommand, "", NULL },
|
||||
{ "restart", SEC_ADMINISTRATOR, true, NULL, "", serverRestartCommandTable },
|
||||
{ "shutdown", SEC_ADMINISTRATOR, true, NULL, "", serverShutdownCommandTable },
|
||||
{ "set", SEC_ADMINISTRATOR, true, NULL, "", serverSetCommandTable },
|
||||
|
|
@ -537,28 +548,29 @@ ChatCommand * ChatHandler::getCommandTable()
|
|||
|
||||
static ChatCommand commandTable[] =
|
||||
{
|
||||
{ "account", SEC_PLAYER, true, NULL, "", accountCommandTable },
|
||||
{ "gm", SEC_MODERATOR, true, NULL, "", gmCommandTable },
|
||||
{ "npc", SEC_MODERATOR, false, NULL, "", npcCommandTable },
|
||||
{ "go", SEC_MODERATOR, false, NULL, "", goCommandTable },
|
||||
{ "learn", SEC_MODERATOR, false, NULL, "", learnCommandTable },
|
||||
{ "modify", SEC_MODERATOR, false, NULL, "", modifyCommandTable },
|
||||
{ "debug", SEC_MODERATOR, false, NULL, "", debugCommandTable },
|
||||
{ "tele", SEC_MODERATOR, true, NULL, "", teleCommandTable },
|
||||
{ "event", SEC_GAMEMASTER, false, NULL, "", eventCommandTable },
|
||||
{ "gobject", SEC_GAMEMASTER, false, NULL, "", gobjectCommandTable },
|
||||
{ "honor", SEC_GAMEMASTER, false, NULL, "", honorCommandTable },
|
||||
{ "wp", SEC_GAMEMASTER, false, NULL, "", wpCommandTable },
|
||||
{ "quest", SEC_ADMINISTRATOR, false, NULL, "", questCommandTable },
|
||||
{ "reload", SEC_ADMINISTRATOR, true, NULL, "", reloadCommandTable },
|
||||
{ "list", SEC_ADMINISTRATOR, true, NULL, "", listCommandTable },
|
||||
{ "lookup", SEC_ADMINISTRATOR, true, NULL, "", lookupCommandTable },
|
||||
{ "pdump", SEC_ADMINISTRATOR, true, NULL, "", pdumpCommandTable },
|
||||
{ "guild", SEC_ADMINISTRATOR, true, NULL, "", guildCommandTable },
|
||||
{ "cast", SEC_ADMINISTRATOR, false, NULL, "", castCommandTable },
|
||||
{ "reset", SEC_ADMINISTRATOR, false, NULL, "", resetCommandTable },
|
||||
{ "account", SEC_PLAYER, true, NULL, "", accountCommandTable },
|
||||
{ "gm", SEC_MODERATOR, true, NULL, "", gmCommandTable },
|
||||
{ "npc", SEC_MODERATOR, false, NULL, "", npcCommandTable },
|
||||
{ "go", SEC_MODERATOR, false, NULL, "", goCommandTable },
|
||||
{ "learn", SEC_MODERATOR, false, NULL, "", learnCommandTable },
|
||||
{ "modify", SEC_MODERATOR, false, NULL, "", modifyCommandTable },
|
||||
{ "debug", SEC_MODERATOR, false, NULL, "", debugCommandTable },
|
||||
{ "tele", SEC_MODERATOR, true, NULL, "", teleCommandTable },
|
||||
{ "character", SEC_GAMEMASTER, false, NULL, "", characterCommandTable},
|
||||
{ "event", SEC_GAMEMASTER, false, NULL, "", eventCommandTable },
|
||||
{ "gobject", SEC_GAMEMASTER, false, NULL, "", gobjectCommandTable },
|
||||
{ "honor", SEC_GAMEMASTER, false, NULL, "", honorCommandTable },
|
||||
{ "wp", SEC_GAMEMASTER, false, NULL, "", wpCommandTable },
|
||||
{ "quest", SEC_ADMINISTRATOR, false, NULL, "", questCommandTable },
|
||||
{ "reload", SEC_ADMINISTRATOR, true, NULL, "", reloadCommandTable },
|
||||
{ "list", SEC_ADMINISTRATOR, true, NULL, "", listCommandTable },
|
||||
{ "lookup", SEC_ADMINISTRATOR, true, NULL, "", lookupCommandTable },
|
||||
{ "pdump", SEC_ADMINISTRATOR, true, NULL, "", pdumpCommandTable },
|
||||
{ "guild", SEC_ADMINISTRATOR, true, NULL, "", guildCommandTable },
|
||||
{ "cast", SEC_ADMINISTRATOR, false, NULL, "", castCommandTable },
|
||||
{ "reset", SEC_ADMINISTRATOR, false, NULL, "", resetCommandTable },
|
||||
{ "instance", SEC_ADMINISTRATOR, true, NULL, "", instanceCommandTable },
|
||||
{ "server", SEC_ADMINISTRATOR, true, NULL, "", serverCommandTable },
|
||||
{ "server", SEC_ADMINISTRATOR, true, NULL, "", serverCommandTable },
|
||||
|
||||
{ "aura", SEC_ADMINISTRATOR, false, &ChatHandler::HandleAuraCommand, "", NULL },
|
||||
{ "unaura", SEC_ADMINISTRATOR, false, &ChatHandler::HandleUnAuraCommand, "", NULL },
|
||||
|
|
@ -570,7 +582,7 @@ ChatCommand * ChatHandler::getCommandTable()
|
|||
{ "commands", SEC_PLAYER, true, &ChatHandler::HandleCommandsCommand, "", NULL },
|
||||
{ "demorph", SEC_GAMEMASTER, false, &ChatHandler::HandleDeMorphCommand, "", NULL },
|
||||
{ "die", SEC_ADMINISTRATOR, false, &ChatHandler::HandleDieCommand, "", NULL },
|
||||
{ "revive", SEC_ADMINISTRATOR, false, &ChatHandler::HandleReviveCommand, "", NULL },
|
||||
{ "revive", SEC_ADMINISTRATOR, true, &ChatHandler::HandleReviveCommand, "", NULL },
|
||||
{ "dismount", SEC_PLAYER, false, &ChatHandler::HandleDismountCommand, "", NULL },
|
||||
{ "gps", SEC_MODERATOR, false, &ChatHandler::HandleGPSCommand, "", NULL },
|
||||
{ "guid", SEC_GAMEMASTER, false, &ChatHandler::HandleGUIDCommand, "", NULL },
|
||||
|
|
@ -583,11 +595,10 @@ ChatCommand * ChatHandler::getCommandTable()
|
|||
{ "save", SEC_PLAYER, false, &ChatHandler::HandleSaveCommand, "", NULL },
|
||||
{ "saveall", SEC_MODERATOR, true, &ChatHandler::HandleSaveAllCommand, "", NULL },
|
||||
{ "kick", SEC_GAMEMASTER, true, &ChatHandler::HandleKickPlayerCommand, "", NULL },
|
||||
{ "ban", SEC_ADMINISTRATOR, true, NULL, "", banCommandTable },
|
||||
{ "unban", SEC_ADMINISTRATOR, true, NULL, "", unbanCommandTable },
|
||||
{ "baninfo", SEC_ADMINISTRATOR, false, NULL, "", baninfoCommandTable },
|
||||
{ "banlist", SEC_ADMINISTRATOR, true, NULL, "", banlistCommandTable },
|
||||
{ "plimit", SEC_ADMINISTRATOR, true, &ChatHandler::HandlePLimitCommand, "", NULL },
|
||||
{ "ban", SEC_ADMINISTRATOR, true, NULL, "", banCommandTable },
|
||||
{ "unban", SEC_ADMINISTRATOR, true, NULL, "", unbanCommandTable },
|
||||
{ "baninfo", SEC_ADMINISTRATOR, false, NULL, "", baninfoCommandTable },
|
||||
{ "banlist", SEC_ADMINISTRATOR, true, NULL, "", banlistCommandTable },
|
||||
{ "start", SEC_PLAYER, false, &ChatHandler::HandleStartCommand, "", NULL },
|
||||
{ "taxicheat", SEC_MODERATOR, false, &ChatHandler::HandleTaxiCheatCommand, "", NULL },
|
||||
{ "linkgrave", SEC_ADMINISTRATOR, false, &ChatHandler::HandleLinkGraveCommand, "", NULL },
|
||||
|
|
@ -607,12 +618,8 @@ ChatCommand * ChatHandler::getCommandTable()
|
|||
{ "setskill", SEC_ADMINISTRATOR, false, &ChatHandler::HandleSetSkillCommand, "", NULL },
|
||||
{ "whispers", SEC_MODERATOR, false, &ChatHandler::HandleWhispersCommand, "", NULL },
|
||||
{ "pinfo", SEC_GAMEMASTER, true, &ChatHandler::HandlePInfoCommand, "", NULL },
|
||||
{ "password", SEC_PLAYER, false, &ChatHandler::HandlePasswordCommand, "", NULL },
|
||||
{ "lockaccount", SEC_PLAYER, false, &ChatHandler::HandleLockAccountCommand, "", NULL },
|
||||
{ "respawn", SEC_ADMINISTRATOR, false, &ChatHandler::HandleRespawnCommand, "", NULL },
|
||||
{ "send", SEC_MODERATOR, true, NULL, "", sendCommandTable },
|
||||
{ "rename", SEC_GAMEMASTER, true, &ChatHandler::HandleRenameCommand, "", NULL },
|
||||
{ "customize", SEC_GAMEMASTER, true, &ChatHandler::HandleCustomizeCommand, "", NULL },
|
||||
{ "send", SEC_MODERATOR, true, NULL, "", sendCommandTable },
|
||||
{ "loadscripts", SEC_ADMINISTRATOR, true, &ChatHandler::HandleLoadScriptsCommand, "", NULL },
|
||||
{ "mute", SEC_MODERATOR, true, &ChatHandler::HandleMuteCommand, "", NULL },
|
||||
{ "unmute", SEC_MODERATOR, true, &ChatHandler::HandleUnmuteCommand, "", NULL },
|
||||
|
|
@ -621,7 +628,6 @@ ChatCommand * ChatHandler::getCommandTable()
|
|||
{ "damage", SEC_ADMINISTRATOR, false, &ChatHandler::HandleDamageCommand, "", NULL },
|
||||
{ "combatstop", SEC_GAMEMASTER, false, &ChatHandler::HandleCombatStopCommand, "", NULL },
|
||||
{ "flusharenapoints",SEC_ADMINISTRATOR, false, &ChatHandler::HandleFlushArenaPointsCommand, "", NULL },
|
||||
{ "chardelete", SEC_CONSOLE, true, &ChatHandler::HandleCharacterDeleteCommand, "", NULL },
|
||||
{ "repairitems", SEC_GAMEMASTER, false, &ChatHandler::HandleRepairitemsCommand, "", NULL },
|
||||
{ "waterwalk", SEC_GAMEMASTER, false, &ChatHandler::HandleWaterwalkCommand, "", NULL },
|
||||
|
||||
|
|
|
|||
|
|
@ -90,7 +90,9 @@ class ChatHandler
|
|||
bool HandleAccountCommand(const char* args);
|
||||
bool HandleAccountCreateCommand(const char* args);
|
||||
bool HandleAccountDeleteCommand(const char* args);
|
||||
bool HandleAccountLockCommand(const char* args);
|
||||
bool HandleAccountOnlineListCommand(const char* args);
|
||||
bool HandleAccountPasswordCommand(const char* args);
|
||||
bool HandleAccountSetAddonCommand(const char* args);
|
||||
bool HandleAccountSetGmLevelCommand(const char* args);
|
||||
bool HandleAccountSetPasswordCommand(const char* args);
|
||||
|
|
@ -111,6 +113,10 @@ class ChatHandler
|
|||
bool HandleCastSelfCommand(const char *args);
|
||||
bool HandleCastTargetCommand(const char *args);
|
||||
|
||||
bool HandleCharacterCustomizeCommand(const char * args);
|
||||
bool HandleCharacterDeleteCommand(const char* args);
|
||||
bool HandleCharacterRenameCommand(const char * args);
|
||||
|
||||
bool HandleDebugAnimCommand(const char* args);
|
||||
bool HandleDebugArenaCommand(const char * args);
|
||||
bool HandleDebugBattlegroundCommand(const char * args);
|
||||
|
|
@ -161,6 +167,16 @@ class ChatHandler
|
|||
bool HandleGMListIngameCommand(const char* args);
|
||||
bool HandleGMVisibleCommand(const char* args);
|
||||
|
||||
bool HandleGoCommand(const char* args);
|
||||
bool HandleGoCreatureCommand(const char* args);
|
||||
bool HandleGoGraveyardCommand(const char* args);
|
||||
bool HandleGoGridCommand(const char* args);
|
||||
bool HandleGoObjectCommand(const char* args);
|
||||
bool HandleGoTriggerCommand(const char* args);
|
||||
bool HandleGoXYCommand(const char* args);
|
||||
bool HandleGoXYZCommand(const char* args);
|
||||
bool HandleGoZoneXYCommand(const char* args);
|
||||
|
||||
bool HandleGuildCreateCommand(const char* args);
|
||||
bool HandleGuildInviteCommand(const char* args);
|
||||
bool HandleGuildUninviteCommand(const char* args);
|
||||
|
|
@ -236,6 +252,7 @@ class ChatHandler
|
|||
bool HandleNpcAddCommand(const char* args);
|
||||
bool HandleNpcAddMoveCommand(const char* args);
|
||||
bool HandleNpcAddVendorItemCommand(const char* args);
|
||||
bool HandleNpcAllowMovementCommand(const char* args);
|
||||
bool HandleNpcChangeEntryCommand(const char *args);
|
||||
bool HandleNpcChangeLevelCommand(const char* args);
|
||||
bool HandleNpcDeleteCommand(const char* args);
|
||||
|
|
@ -265,6 +282,9 @@ class ChatHandler
|
|||
bool HandleNpcSubNameCommand(const char* args);
|
||||
//----------------------------------------------------------
|
||||
|
||||
bool HandlePDumpLoadCommand(const char *args);
|
||||
bool HandlePDumpWriteCommand(const char *args);
|
||||
|
||||
bool HandleQuestAdd(const char * args);
|
||||
bool HandleQuestRemove(const char * args);
|
||||
bool HandleQuestComplete(const char * args);
|
||||
|
|
@ -364,9 +384,10 @@ class ChatHandler
|
|||
bool HandleServerIdleShutDownCommand(const char* args);
|
||||
bool HandleServerInfoCommand(const char* args);
|
||||
bool HandleServerMotdCommand(const char* args);
|
||||
bool HandleServerPLimitCommand(const char* args);
|
||||
bool HandleServerRestartCommand(const char* args);
|
||||
bool HandleServerSetMotdCommand(const char* args);
|
||||
bool HandleServerSetLogLevelCommand(const char* args);
|
||||
bool HandleServerSetMotdCommand(const char* args);
|
||||
bool HandleServerShutDownCommand(const char* args);
|
||||
bool HandleServerShutDownCancelCommand(const char* args);
|
||||
|
||||
|
|
@ -408,24 +429,11 @@ class ChatHandler
|
|||
bool HandleGUIDCommand(const char* args);
|
||||
bool HandleItemMoveCommand(const char* args);
|
||||
bool HandleDeMorphCommand(const char* args);
|
||||
bool HandleGoCreatureCommand(const char* args);
|
||||
bool HandleGoObjectCommand(const char* args);
|
||||
bool HandleGoTriggerCommand(const char* args);
|
||||
bool HandleGoGraveyardCommand(const char* args);
|
||||
bool HandlePInfoCommand(const char* args);
|
||||
bool HandlePLimitCommand(const char* args);
|
||||
bool HandleMuteCommand(const char* args);
|
||||
bool HandleUnmuteCommand(const char* args);
|
||||
bool HandleMovegensCommand(const char* args);
|
||||
|
||||
bool HandleCharacterDeleteCommand(const char* args);
|
||||
bool HandleGoXYCommand(const char* args);
|
||||
bool HandleGoXYZCommand(const char* args);
|
||||
bool HandleGoZoneXYCommand(const char* args);
|
||||
bool HandleGoGridCommand(const char* args);
|
||||
bool HandleNpcAllowMovementCommand(const char* args);
|
||||
bool HandleGoCommand(const char* args);
|
||||
|
||||
bool HandleCooldownCommand(const char* args);
|
||||
bool HandleUnLearnCommand(const char* args);
|
||||
bool HandleGetDistanceCommand(const char* args);
|
||||
|
|
@ -454,13 +462,7 @@ class ChatHandler
|
|||
bool HandleDelTicketCommand(const char* args);
|
||||
bool HandleMaxSkillCommand(const char* args);
|
||||
bool HandleSetSkillCommand(const char* args);
|
||||
bool HandlePasswordCommand(const char* args);
|
||||
bool HandleLockAccountCommand(const char* args);
|
||||
bool HandleRespawnCommand(const char* args);
|
||||
bool HandleRenameCommand(const char * args);
|
||||
bool HandleCustomizeCommand(const char * args);
|
||||
bool HandlePDumpLoadCommand(const char *args);
|
||||
bool HandlePDumpWriteCommand(const char *args);
|
||||
bool HandleComeToMeCommand(const char *args);
|
||||
bool HandleCombatStopCommand(const char *args);
|
||||
bool HandleFlushArenaPointsCommand(const char *args);
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ int CreatureEventAI::Permissible(const Creature *creature)
|
|||
return PERMIT_BASE_NO;
|
||||
}
|
||||
|
||||
CreatureEventAI::CreatureEventAI(Creature *c ) : CreatureAI(c), InCombat(false)
|
||||
CreatureEventAI::CreatureEventAI(Creature *c ) : CreatureAI(c)
|
||||
{
|
||||
CreatureEventAI_Event_Map::iterator CreatureEvents = CreatureEAI_Mgr.GetCreatureEventAIMap().find(m_creature->GetEntry());
|
||||
if (CreatureEvents != CreatureEAI_Mgr.GetCreatureEventAIMap().end())
|
||||
|
|
@ -139,7 +139,7 @@ bool CreatureEventAI::ProcessEvent(CreatureEventAIHolder& pHolder, Unit* pAction
|
|||
{
|
||||
case EVENT_T_TIMER:
|
||||
{
|
||||
if (!InCombat)
|
||||
if (!m_creature->isInCombat())
|
||||
return false;
|
||||
|
||||
//Repeat Timers
|
||||
|
|
@ -158,7 +158,7 @@ bool CreatureEventAI::ProcessEvent(CreatureEventAIHolder& pHolder, Unit* pAction
|
|||
break;
|
||||
case EVENT_T_TIMER_OOC:
|
||||
{
|
||||
if (InCombat)
|
||||
if (m_creature->isInCombat())
|
||||
return false;
|
||||
|
||||
//Repeat Timers
|
||||
|
|
@ -178,7 +178,7 @@ bool CreatureEventAI::ProcessEvent(CreatureEventAIHolder& pHolder, Unit* pAction
|
|||
break;
|
||||
case EVENT_T_HP:
|
||||
{
|
||||
if (!InCombat || !m_creature->GetMaxHealth())
|
||||
if (!m_creature->isInCombat() || !m_creature->GetMaxHealth())
|
||||
return false;
|
||||
|
||||
uint32 perc = (m_creature->GetHealth()*100) / m_creature->GetMaxHealth();
|
||||
|
|
@ -203,7 +203,7 @@ bool CreatureEventAI::ProcessEvent(CreatureEventAIHolder& pHolder, Unit* pAction
|
|||
break;
|
||||
case EVENT_T_MANA:
|
||||
{
|
||||
if (!InCombat || !m_creature->GetMaxPower(POWER_MANA))
|
||||
if (!m_creature->isInCombat() || !m_creature->GetMaxPower(POWER_MANA))
|
||||
return false;
|
||||
|
||||
uint32 perc = (m_creature->GetPower(POWER_MANA)*100) / m_creature->GetMaxPower(POWER_MANA);
|
||||
|
|
@ -313,7 +313,7 @@ bool CreatureEventAI::ProcessEvent(CreatureEventAIHolder& pHolder, Unit* pAction
|
|||
break;
|
||||
case EVENT_T_TARGET_HP:
|
||||
{
|
||||
if (!InCombat || !m_creature->getVictim() || !m_creature->getVictim()->GetMaxHealth())
|
||||
if (!m_creature->isInCombat() || !m_creature->getVictim() || !m_creature->getVictim()->GetMaxHealth())
|
||||
return false;
|
||||
|
||||
uint32 perc = (m_creature->getVictim()->GetHealth()*100) / m_creature->getVictim()->GetMaxHealth();
|
||||
|
|
@ -338,7 +338,7 @@ bool CreatureEventAI::ProcessEvent(CreatureEventAIHolder& pHolder, Unit* pAction
|
|||
break;
|
||||
case EVENT_T_TARGET_CASTING:
|
||||
{
|
||||
if (!InCombat || !m_creature->getVictim() || !m_creature->getVictim()->IsNonMeleeSpellCasted(false, false, true))
|
||||
if (!m_creature->isInCombat() || !m_creature->getVictim() || !m_creature->getVictim()->IsNonMeleeSpellCasted(false, false, true))
|
||||
return false;
|
||||
|
||||
//Repeat Timers
|
||||
|
|
@ -358,7 +358,7 @@ bool CreatureEventAI::ProcessEvent(CreatureEventAIHolder& pHolder, Unit* pAction
|
|||
break;
|
||||
case EVENT_T_FRIENDLY_HP:
|
||||
{
|
||||
if (!InCombat)
|
||||
if (!m_creature->isInCombat())
|
||||
return false;
|
||||
|
||||
Unit* pUnit = DoSelectLowestHpFriendly(param2, param1);
|
||||
|
|
@ -385,7 +385,7 @@ bool CreatureEventAI::ProcessEvent(CreatureEventAIHolder& pHolder, Unit* pAction
|
|||
break;
|
||||
case EVENT_T_FRIENDLY_IS_CC:
|
||||
{
|
||||
if (!InCombat)
|
||||
if (!m_creature->isInCombat())
|
||||
return false;
|
||||
|
||||
std::list<Creature*> pList;
|
||||
|
|
@ -989,7 +989,6 @@ void CreatureEventAI::ProcessAction(uint16 type, uint32 param1, uint32 param2, u
|
|||
|
||||
void CreatureEventAI::JustRespawned()
|
||||
{
|
||||
InCombat = false;
|
||||
Reset();
|
||||
|
||||
if (bEmptyList)
|
||||
|
|
@ -1060,18 +1059,15 @@ void CreatureEventAI::JustReachedHome()
|
|||
|
||||
void CreatureEventAI::EnterEvadeMode()
|
||||
{
|
||||
m_creature->InterruptNonMeleeSpells(true);
|
||||
m_creature->RemoveAllAuras();
|
||||
m_creature->DeleteThreatList();
|
||||
m_creature->CombatStop();
|
||||
m_creature->CombatStop(true);
|
||||
|
||||
if (m_creature->isAlive())
|
||||
m_creature->GetMotionMaster()->MoveTargetedHome();
|
||||
|
||||
m_creature->SetLootRecipient(NULL);
|
||||
|
||||
InCombat = false;
|
||||
|
||||
if (bEmptyList)
|
||||
return;
|
||||
|
||||
|
|
@ -1085,7 +1081,6 @@ void CreatureEventAI::EnterEvadeMode()
|
|||
|
||||
void CreatureEventAI::JustDied(Unit* killer)
|
||||
{
|
||||
InCombat = false;
|
||||
Reset();
|
||||
|
||||
if (bEmptyList)
|
||||
|
|
@ -1169,17 +1164,16 @@ void CreatureEventAI::AttackStart(Unit *who)
|
|||
if (!who)
|
||||
return;
|
||||
|
||||
bool inCombat = m_creature->isInCombat();
|
||||
|
||||
if (m_creature->Attack(who, MeleeEnabled))
|
||||
{
|
||||
m_creature->AddThreat(who, 0.0f);
|
||||
m_creature->SetInCombatWith(who);
|
||||
who->SetInCombatWith(m_creature);
|
||||
|
||||
if (!InCombat)
|
||||
{
|
||||
InCombat = true;
|
||||
if (!inCombat)
|
||||
Aggro(who);
|
||||
}
|
||||
|
||||
if (CombatMovementEnabled)
|
||||
{
|
||||
|
|
@ -1220,7 +1214,7 @@ void CreatureEventAI::MoveInLineOfSight(Unit *who)
|
|||
}
|
||||
}
|
||||
|
||||
if (m_creature->isCivilian() && m_creature->IsNeutralToAll())
|
||||
if (m_creature->isCivilian() || m_creature->IsNeutralToAll())
|
||||
return;
|
||||
|
||||
if (!m_creature->hasUnitState(UNIT_STAT_STUNNED) && who->isTargetableForAttack() &&
|
||||
|
|
@ -1269,7 +1263,7 @@ void CreatureEventAI::SpellHit(Unit* pUnit, const SpellEntry* pSpell)
|
|||
void CreatureEventAI::UpdateAI(const uint32 diff)
|
||||
{
|
||||
//Check if we are in combat (also updates calls threat update code)
|
||||
bool Combat = InCombat ? (m_creature->SelectHostilTarget() && m_creature->getVictim()) : false;
|
||||
bool Combat = m_creature->SelectHostilTarget() && m_creature->getVictim();
|
||||
|
||||
//Must return if creature isn't alive. Normally select hostil target and get victim prevent this
|
||||
if (!m_creature->isAlive())
|
||||
|
|
|
|||
|
|
@ -285,8 +285,6 @@ class MANGOS_DLL_SPEC CreatureEventAI : public CreatureAI
|
|||
void DoFindFriendlyMissingBuff(std::list<Creature*>& _list, float range, uint32 spellid);
|
||||
void DoFindFriendlyCC(std::list<Creature*>& _list, float range);
|
||||
|
||||
//Bool for if we are in combat or not
|
||||
bool InCombat;
|
||||
//Holder for events (stores enabled, time, and eventid)
|
||||
std::list<CreatureEventAIHolder> CreatureEventAIList;
|
||||
uint32 EventUpdateTime; //Time between event updates
|
||||
|
|
|
|||
|
|
@ -509,7 +509,8 @@ struct AreaTableEntry
|
|||
struct AreaGroupEntry
|
||||
{
|
||||
uint32 AreaGroupId; // 0
|
||||
uint32 AreaId[7]; // 1-7
|
||||
uint32 AreaId[6]; // 1-6
|
||||
uint32 nextGroup; // 7 index of next group
|
||||
};
|
||||
|
||||
struct AreaTriggerEntry
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ void GuardAI::EnterEvadeMode()
|
|||
i_state = STATE_NORMAL;
|
||||
|
||||
i_victimGuid = 0;
|
||||
m_creature->CombatStop();
|
||||
m_creature->CombatStop(true);
|
||||
m_creature->DeleteThreatList();
|
||||
return;
|
||||
}
|
||||
|
|
@ -97,7 +97,7 @@ void GuardAI::EnterEvadeMode()
|
|||
m_creature->RemoveAllAuras();
|
||||
m_creature->DeleteThreatList();
|
||||
i_victimGuid = 0;
|
||||
m_creature->CombatStop();
|
||||
m_creature->CombatStop(true);
|
||||
i_state = STATE_NORMAL;
|
||||
|
||||
// Remove TargetedMovementGenerator from MotionMaster stack list, and add HomeMovementGenerator instead
|
||||
|
|
|
|||
|
|
@ -177,7 +177,7 @@ bool ChatHandler::HandleGMListIngameCommand(const char* /*args*/)
|
|||
return true;
|
||||
}
|
||||
|
||||
bool ChatHandler::HandlePasswordCommand(const char* args)
|
||||
bool ChatHandler::HandleAccountPasswordCommand(const char* args)
|
||||
{
|
||||
if(!*args)
|
||||
return false;
|
||||
|
|
@ -228,7 +228,7 @@ bool ChatHandler::HandlePasswordCommand(const char* args)
|
|||
return true;
|
||||
}
|
||||
|
||||
bool ChatHandler::HandleLockAccountCommand(const char* args)
|
||||
bool ChatHandler::HandleAccountLockCommand(const char* args)
|
||||
{
|
||||
if (!*args)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -3650,7 +3650,7 @@ bool ChatHandler::HandleWpImportCommand(const char *args)
|
|||
}
|
||||
|
||||
//rename characters
|
||||
bool ChatHandler::HandleRenameCommand(const char* args)
|
||||
bool ChatHandler::HandleCharacterRenameCommand(const char* args)
|
||||
{
|
||||
Player* target = NULL;
|
||||
uint64 targetGUID = 0;
|
||||
|
|
@ -3712,7 +3712,7 @@ bool ChatHandler::HandleRenameCommand(const char* args)
|
|||
}
|
||||
|
||||
// customize characters
|
||||
bool ChatHandler::HandleCustomizeCommand(const char* args)
|
||||
bool ChatHandler::HandleCharacterCustomizeCommand(const char* args)
|
||||
{
|
||||
Player* target = NULL;
|
||||
uint64 targetGUID = 0;
|
||||
|
|
|
|||
|
|
@ -3439,33 +3439,44 @@ bool ChatHandler::HandleModifyArenaCommand(const char * args)
|
|||
|
||||
bool ChatHandler::HandleReviveCommand(const char* args)
|
||||
{
|
||||
Player* SelectedPlayer = NULL;
|
||||
Player* player = NULL;
|
||||
uint64 player_guid = 0;
|
||||
|
||||
if (*args)
|
||||
{
|
||||
std::string name = extractPlayerNameFromLink((char*)args);
|
||||
if(name.empty())
|
||||
if (name.empty())
|
||||
{
|
||||
SendSysMessage(LANG_PLAYER_NOT_FOUND);
|
||||
SetSentErrorMessage(true);
|
||||
return false;
|
||||
}
|
||||
|
||||
SelectedPlayer = objmgr.GetPlayer(name.c_str());
|
||||
player = objmgr.GetPlayer(name.c_str());
|
||||
if (!player)
|
||||
player_guid = objmgr.GetPlayerGUIDByName(name);
|
||||
}
|
||||
else
|
||||
SelectedPlayer = getSelectedPlayer();
|
||||
player = getSelectedPlayer();
|
||||
|
||||
if(!SelectedPlayer)
|
||||
if (player)
|
||||
{
|
||||
player->ResurrectPlayer(0.5f);
|
||||
player->SpawnCorpseBones();
|
||||
player->SaveToDB();
|
||||
}
|
||||
else if (player_guid)
|
||||
{
|
||||
// will resurrected at login without corpse
|
||||
ObjectAccessor::Instance().ConvertCorpseForPlayer(player_guid);
|
||||
}
|
||||
else
|
||||
{
|
||||
SendSysMessage(LANG_NO_CHAR_SELECTED);
|
||||
SetSentErrorMessage(true);
|
||||
return false;
|
||||
}
|
||||
|
||||
SelectedPlayer->ResurrectPlayer(0.5f);
|
||||
SelectedPlayer->SpawnCorpseBones();
|
||||
SelectedPlayer->SaveToDB();
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -4511,6 +4522,8 @@ bool ChatHandler::HandleResetHonorCommand (const char * args)
|
|||
player->SetUInt32Value(PLAYER_FIELD_TODAY_CONTRIBUTION, 0);
|
||||
player->SetUInt32Value(PLAYER_FIELD_YESTERDAY_CONTRIBUTION, 0);
|
||||
|
||||
player->UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_EARN_HONORABLE_KILL);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -5904,7 +5917,7 @@ bool ChatHandler::HandleMovegensCommand(const char* /*args*/)
|
|||
return true;
|
||||
}
|
||||
|
||||
bool ChatHandler::HandlePLimitCommand(const char *args)
|
||||
bool ChatHandler::HandleServerPLimitCommand(const char *args)
|
||||
{
|
||||
if(*args)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -187,7 +187,7 @@ class MANGOS_DLL_SPEC Object
|
|||
return *(((uint8*)&m_uint32Values[ index ])+offset);
|
||||
}
|
||||
|
||||
uint8 GetUInt16Value( uint16 index, uint8 offset) const
|
||||
uint16 GetUInt16Value( uint16 index, uint8 offset) const
|
||||
{
|
||||
ASSERT( index < m_valuesCount || PrintIndexError( index , false) );
|
||||
ASSERT( offset < 2 );
|
||||
|
|
|
|||
|
|
@ -5843,6 +5843,7 @@ bool Player::RewardHonor(Unit *uVictim, uint32 groupsize, float honor)
|
|||
ApplyModUInt32Value(PLAYER_FIELD_KILLS, 1, true);
|
||||
// and those in a lifetime
|
||||
ApplyModUInt32Value(PLAYER_FIELD_LIFETIME_HONORBALE_KILLS, 1, true);
|
||||
UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_EARN_HONORABLE_KILL);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1806,7 +1806,7 @@ class MANGOS_DLL_SPEC Player : public Unit
|
|||
for (int i=0; i < PLAYER_MAX_BATTLEGROUND_QUEUES; i++)
|
||||
if (m_bgBattleGroundQueueID[i].bgQueueTypeId == bgQueueTypeId)
|
||||
return m_bgBattleGroundQueueID[i].invitedToInstance != 0;
|
||||
return PLAYER_MAX_BATTLEGROUND_QUEUES;
|
||||
return false;
|
||||
}
|
||||
bool InBattleGroundQueueForBattleGroundQueueType(BattleGroundQueueTypeId bgQueueTypeId) const
|
||||
{
|
||||
|
|
|
|||
|
|
@ -91,7 +91,7 @@ ReactorAI::EnterEvadeMode()
|
|||
m_creature->GetMotionMaster()->MovementExpired();
|
||||
m_creature->GetMotionMaster()->MoveIdle();
|
||||
i_victimGuid = 0;
|
||||
m_creature->CombatStop();
|
||||
m_creature->CombatStop(true);
|
||||
m_creature->DeleteThreatList();
|
||||
return;
|
||||
}
|
||||
|
|
@ -118,7 +118,7 @@ ReactorAI::EnterEvadeMode()
|
|||
m_creature->RemoveAllAuras();
|
||||
m_creature->DeleteThreatList();
|
||||
i_victimGuid = 0;
|
||||
m_creature->CombatStop();
|
||||
m_creature->CombatStop(true);
|
||||
m_creature->SetLootRecipient(NULL);
|
||||
|
||||
// Remove TargetedMovementGenerator from MotionMaster stack list, and add HomeMovementGenerator instead
|
||||
|
|
|
|||
|
|
@ -1040,18 +1040,12 @@ void Spell::DoAllEffectOnTarget(TargetInfo *target)
|
|||
else
|
||||
procEx |= PROC_EX_NORMAL_HIT;
|
||||
|
||||
caster->SendHealSpellLog(unitTarget, m_spellInfo->Id, addhealth, crit);
|
||||
|
||||
// Do triggers for unit (reflect triggers passed on hit phase for correct drop charge)
|
||||
if (m_canTrigger && missInfo != SPELL_MISS_REFLECT)
|
||||
caster->ProcDamageAndSpell(unitTarget, procAttacker, procVictim, procEx, addhealth, m_attackType, m_spellInfo);
|
||||
|
||||
int32 gain = unitTarget->ModifyHealth( int32(addhealth) );
|
||||
|
||||
int32 gain = caster->DealHeal(unitTarget, addhealth, m_spellInfo, crit);
|
||||
unitTarget->getHostilRefManager().threatAssist(caster, float(gain) * 0.5f, m_spellInfo);
|
||||
if(caster->GetTypeId()==TYPEID_PLAYER)
|
||||
if(BattleGround *bg = ((Player*)caster)->GetBattleGround())
|
||||
bg->UpdatePlayerScore(((Player*)caster), SCORE_HEALING_DONE, gain);
|
||||
}
|
||||
// Do damage and triggers
|
||||
else if (m_damage)
|
||||
|
|
@ -2776,10 +2770,7 @@ void Spell::finish(bool ok)
|
|||
|
||||
// Heal caster for all health leech from all targets
|
||||
if (m_healthLeech)
|
||||
{
|
||||
m_caster->ModifyHealth(m_healthLeech);
|
||||
m_caster->SendHealSpellLog(m_caster, m_spellInfo->Id, uint32(m_healthLeech));
|
||||
}
|
||||
m_caster->DealHeal(m_caster, uint32(m_healthLeech), m_spellInfo);
|
||||
|
||||
if (IsMeleeAttackResetSpell())
|
||||
{
|
||||
|
|
|
|||
|
|
@ -630,12 +630,12 @@ namespace MaNGOS
|
|||
{
|
||||
std::list<Unit*> *i_data;
|
||||
Spell &i_spell;
|
||||
const uint32& i_push_type;
|
||||
SpellNotifyPushType i_push_type;
|
||||
float i_radius;
|
||||
SpellTargets i_TargetType;
|
||||
Unit* i_originalCaster;
|
||||
|
||||
SpellNotifierCreatureAndPlayer(Spell &spell, std::list<Unit*> &data, float radius, const uint32 &type,
|
||||
SpellNotifierCreatureAndPlayer(Spell &spell, std::list<Unit*> &data, float radius, SpellNotifyPushType type,
|
||||
SpellTargets TargetType = SPELL_TARGETS_NOT_FRIENDLY)
|
||||
: i_data(&data), i_spell(spell), i_push_type(type), i_radius(radius), i_TargetType(TargetType)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1436,8 +1436,7 @@ void Aura::TriggerSpell()
|
|||
case 23493:
|
||||
{
|
||||
int32 heal = caster->GetMaxHealth() / 10;
|
||||
caster->ModifyHealth( heal );
|
||||
caster->SendHealSpellLog(caster, 23493, heal);
|
||||
caster->DealHeal(caster, heal, auraSpellInfo);
|
||||
|
||||
int32 mana = caster->GetMaxPower(POWER_MANA);
|
||||
if (mana)
|
||||
|
|
@ -5881,10 +5880,8 @@ void Aura::PeriodicTick()
|
|||
|
||||
uint32 heal = pCaster->SpellHealingBonus(pCaster, spellProto, uint32(new_damage * multiplier), DOT, stackAmount);
|
||||
|
||||
int32 gain = pCaster->ModifyHealth(heal);
|
||||
int32 gain = pCaster->DealHeal(pCaster, heal, spellProto);
|
||||
pCaster->getHostilRefManager().threatAssist(pCaster, gain * 0.5f, spellProto);
|
||||
|
||||
pCaster->SendHealSpellLog(pCaster, spellProto->Id, heal);
|
||||
break;
|
||||
}
|
||||
case SPELL_AURA_PERIODIC_HEAL:
|
||||
|
|
|
|||
|
|
@ -1239,6 +1239,12 @@ void Spell::EffectDummy(uint32 i)
|
|||
m_damage+=damage;
|
||||
return;
|
||||
}
|
||||
// Concussion Blow
|
||||
if(m_spellInfo->SpellFamilyFlags & 0x0000000004000000LL)
|
||||
{
|
||||
m_damage+= uint32(damage * m_caster->GetTotalAttackPowerValue(BASE_ATTACK) / 100);
|
||||
return;
|
||||
}
|
||||
switch(m_spellInfo->Id)
|
||||
{
|
||||
// Warrior's Wrath
|
||||
|
|
@ -2507,14 +2513,8 @@ void Spell::EffectHealPct( uint32 /*i*/ )
|
|||
if(Player* modOwner = m_caster->GetSpellModOwner())
|
||||
modOwner->ApplySpellMod(m_spellInfo->Id, SPELLMOD_DAMAGE, addhealth, this);
|
||||
|
||||
caster->SendHealSpellLog(unitTarget, m_spellInfo->Id, addhealth, false);
|
||||
|
||||
int32 gain = unitTarget->ModifyHealth( int32(addhealth) );
|
||||
int32 gain = caster->DealHeal(unitTarget, addhealth, m_spellInfo);
|
||||
unitTarget->getHostilRefManager().threatAssist(m_caster, float(gain) * 0.5f, m_spellInfo);
|
||||
|
||||
if(caster->GetTypeId()==TYPEID_PLAYER)
|
||||
if(BattleGround *bg = ((Player*)caster)->GetBattleGround())
|
||||
bg->UpdatePlayerScore(((Player*)caster), SCORE_HEALING_DONE, gain);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -2531,8 +2531,7 @@ void Spell::EffectHealMechanical( uint32 /*i*/ )
|
|||
return;
|
||||
|
||||
uint32 addhealth = caster->SpellHealingBonus(unitTarget, m_spellInfo, uint32(damage), HEAL);
|
||||
caster->SendHealSpellLog(unitTarget, m_spellInfo->Id, addhealth, false);
|
||||
unitTarget->ModifyHealth( int32(damage) );
|
||||
caster->DealHeal(unitTarget, addhealth, m_spellInfo);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -2562,11 +2561,7 @@ void Spell::EffectHealthLeech(uint32 i)
|
|||
if(m_caster->isAlive())
|
||||
{
|
||||
new_damage = m_caster->SpellHealingBonus(m_caster, m_spellInfo, new_damage, HEAL);
|
||||
|
||||
m_caster->ModifyHealth(new_damage);
|
||||
|
||||
if(m_caster->GetTypeId() == TYPEID_PLAYER)
|
||||
m_caster->SendHealSpellLog(m_caster, m_spellInfo->Id, uint32(new_damage));
|
||||
m_caster->DealHeal(m_caster, uint32(new_damage), m_spellInfo);
|
||||
}
|
||||
// m_healthLeech+=tmpvalue;
|
||||
// m_damage+=new_damage;
|
||||
|
|
|
|||
|
|
@ -2588,15 +2588,18 @@ SpellCastResult SpellMgr::GetSpellAllowedInLocationError(SpellEntry const *spell
|
|||
if( spellInfo->AreaGroupId > 0)
|
||||
{
|
||||
bool found = false;
|
||||
|
||||
AreaGroupEntry const* groupEntry = sAreaGroupStore.LookupEntry(spellInfo->AreaGroupId);
|
||||
if(groupEntry)
|
||||
while (groupEntry)
|
||||
{
|
||||
for (uint8 i=0; i<7; i++)
|
||||
for (uint32 i=0; i<6; i++)
|
||||
if( groupEntry->AreaId[i] == zone_id || groupEntry->AreaId[i] == area_id )
|
||||
found = true;
|
||||
if (found || !groupEntry->nextGroup)
|
||||
break;
|
||||
// Try search in next group
|
||||
groupEntry = sAreaGroupStore.LookupEntry(groupEntry->nextGroup);
|
||||
}
|
||||
|
||||
|
||||
if(!found)
|
||||
return SPELL_FAILED_INCORRECT_AREA;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ TotemAI::MoveInLineOfSight(Unit *)
|
|||
|
||||
void TotemAI::EnterEvadeMode()
|
||||
{
|
||||
m_creature->CombatStop();
|
||||
m_creature->CombatStop(true);
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
|||
|
|
@ -497,17 +497,27 @@ uint32 Unit::DealDamage(Unit *pVictim, uint32 damage, CleanDamage const* cleanDa
|
|||
}
|
||||
}
|
||||
|
||||
if(pVictim->GetTypeId() == TYPEID_PLAYER && GetTypeId() == TYPEID_PLAYER)
|
||||
if (GetTypeId() == TYPEID_PLAYER && this != pVictim)
|
||||
{
|
||||
if(((Player*)pVictim)->InBattleGround())
|
||||
Player *killer = ((Player*)this);
|
||||
|
||||
// in bg, count dmg if victim is also a player
|
||||
if (pVictim->GetTypeId()==TYPEID_PLAYER)
|
||||
{
|
||||
Player *killer = ((Player*)this);
|
||||
if(killer != ((Player*)pVictim))
|
||||
if(BattleGround *bg = killer->GetBattleGround())
|
||||
bg->UpdatePlayerScore(killer, SCORE_DAMAGE_DONE, damage);
|
||||
if (BattleGround *bg = killer->GetBattleGround())
|
||||
{
|
||||
// FIXME: kept by compatibility. don't know in BG if the restriction apply.
|
||||
bg->UpdatePlayerScore(killer, SCORE_DAMAGE_DONE, damage);
|
||||
}
|
||||
}
|
||||
|
||||
killer->UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_DAMAGE_DONE, damage, 0, pVictim);
|
||||
killer->UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HIT_DEALT, damage);
|
||||
}
|
||||
|
||||
if (pVictim->GetTypeId() == TYPEID_PLAYER)
|
||||
((Player*)pVictim)->UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HIT_RECEIVED, damage);
|
||||
|
||||
if (pVictim->GetTypeId() == TYPEID_UNIT && !((Creature*)pVictim)->isPet() && !((Creature*)pVictim)->hasLootRecipient())
|
||||
((Creature*)pVictim)->SetLootRecipient(this);
|
||||
|
||||
|
|
@ -515,6 +525,10 @@ uint32 Unit::DealDamage(Unit *pVictim, uint32 damage, CleanDamage const* cleanDa
|
|||
{
|
||||
DEBUG_LOG("DealDamage: victim just died");
|
||||
|
||||
if (pVictim->GetTypeId() == TYPEID_PLAYER)
|
||||
((Player*)pVictim)->UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_TOTAL_DAMAGE_RECEIVED, health);
|
||||
|
||||
|
||||
// find player: owner of controlled `this` or `this` itself maybe
|
||||
Player *player = GetCharmerOrOwnerPlayerOrPlayerItself();
|
||||
|
||||
|
|
@ -680,6 +694,9 @@ uint32 Unit::DealDamage(Unit *pVictim, uint32 damage, CleanDamage const* cleanDa
|
|||
{
|
||||
DEBUG_LOG("DealDamageAlive");
|
||||
|
||||
if (pVictim->GetTypeId() == TYPEID_PLAYER)
|
||||
((Player*)pVictim)->UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_TOTAL_DAMAGE_RECEIVED, damage);
|
||||
|
||||
pVictim->ModifyHealth(- (int32)damage);
|
||||
|
||||
if(damagetype != DOT)
|
||||
|
|
@ -1291,8 +1308,8 @@ void Unit::CalculateMeleeDamage(Unit *pVictim, uint32 damage, CalcDamageInfo *da
|
|||
damageInfo->procEx|=PROC_EX_NORMAL_HIT;
|
||||
float reducePercent = 1.0f; //damage factor
|
||||
// calculate base values and mods
|
||||
float baseLowEnd = 1.3;
|
||||
float baseHighEnd = 1.2;
|
||||
float baseLowEnd = 1.3f;
|
||||
float baseHighEnd = 1.2f;
|
||||
switch(getClass()) // lowering base values for casters
|
||||
{
|
||||
case CLASS_SHAMAN:
|
||||
|
|
@ -1300,17 +1317,17 @@ void Unit::CalculateMeleeDamage(Unit *pVictim, uint32 damage, CalcDamageInfo *da
|
|||
case CLASS_MAGE:
|
||||
case CLASS_WARLOCK:
|
||||
case CLASS_DRUID:
|
||||
baseLowEnd -= 0.7;
|
||||
baseHighEnd -= 0.3;
|
||||
baseLowEnd -= 0.7f;
|
||||
baseHighEnd -= 0.3f;
|
||||
break;
|
||||
}
|
||||
|
||||
float maxLowEnd = 0.6;
|
||||
float maxLowEnd = 0.6f;
|
||||
switch(getClass()) // upper for melee classes
|
||||
{
|
||||
case CLASS_WARRIOR:
|
||||
case CLASS_ROGUE:
|
||||
maxLowEnd = 0.91; //If the attacker is a melee class then instead the lower value of 0.91
|
||||
maxLowEnd = 0.91f; //If the attacker is a melee class then instead the lower value of 0.91
|
||||
}
|
||||
|
||||
// calculate values
|
||||
|
|
@ -1406,29 +1423,29 @@ void Unit::DealMeleeDamage(CalcDamageInfo *damageInfo, bool durabilityLoss)
|
|||
// Reduce attack time
|
||||
if (pVictim->haveOffhandWeapon() && offtime < basetime)
|
||||
{
|
||||
float percent20 = pVictim->GetAttackTime(OFF_ATTACK) * 0.20;
|
||||
float percent60 = 3 * percent20;
|
||||
float percent20 = pVictim->GetAttackTime(OFF_ATTACK) * 0.20f;
|
||||
float percent60 = 3.0f * percent20;
|
||||
if(offtime > percent20 && offtime <= percent60)
|
||||
{
|
||||
pVictim->setAttackTimer(OFF_ATTACK, uint32(percent20));
|
||||
}
|
||||
else if(offtime > percent60)
|
||||
{
|
||||
offtime -= 2 * percent20;
|
||||
offtime -= 2.0f * percent20;
|
||||
pVictim->setAttackTimer(OFF_ATTACK, uint32(offtime));
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
float percent20 = pVictim->GetAttackTime(BASE_ATTACK) * 0.20;
|
||||
float percent60 = 3 * percent20;
|
||||
float percent60 = 3.0f * percent20;
|
||||
if(basetime > percent20 && basetime <= percent60)
|
||||
{
|
||||
pVictim->setAttackTimer(BASE_ATTACK, uint32(percent20));
|
||||
}
|
||||
else if(basetime > percent60)
|
||||
{
|
||||
basetime -= 2 * percent20;
|
||||
basetime -= 2.0f * percent20;
|
||||
pVictim->setAttackTimer(BASE_ATTACK, uint32(basetime));
|
||||
}
|
||||
}
|
||||
|
|
@ -1444,19 +1461,19 @@ void Unit::DealMeleeDamage(CalcDamageInfo *damageInfo, bool durabilityLoss)
|
|||
{
|
||||
// -probability is between 0% and 40%
|
||||
// 20% base chance
|
||||
float Probability = 20;
|
||||
float Probability = 20.0f;
|
||||
|
||||
//there is a newbie protection, at level 10 just 7% base chance; assuming linear function
|
||||
if( pVictim->getLevel() < 30 )
|
||||
Probability = 0.65f*pVictim->getLevel()+0.5;
|
||||
Probability = 0.65f*pVictim->getLevel()+0.5f;
|
||||
|
||||
uint32 VictimDefense=pVictim->GetDefenseSkillValue();
|
||||
uint32 AttackerMeleeSkill=GetUnitMeleeSkill();
|
||||
|
||||
Probability *= AttackerMeleeSkill/(float)VictimDefense;
|
||||
|
||||
if(Probability > 40)
|
||||
Probability = 40;
|
||||
if(Probability > 40.0f)
|
||||
Probability = 40.0f;
|
||||
|
||||
if(roll_chance_f(Probability))
|
||||
CastSpell(pVictim, 1604, true);
|
||||
|
|
@ -1954,11 +1971,6 @@ void Unit::AttackerStateUpdate (Unit *pVictim, WeaponAttackType attType, bool ex
|
|||
--m_extraAttacks;
|
||||
}
|
||||
}
|
||||
|
||||
// if damage pVictim call AI reaction
|
||||
if(pVictim->GetTypeId()==TYPEID_UNIT && ((Creature*)pVictim)->AI())
|
||||
((Creature*)pVictim)->AI()->AttackedBy(this);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -1979,6 +1991,10 @@ void Unit::AttackerStateUpdate (Unit *pVictim, WeaponAttackType attType, bool ex
|
|||
DEBUG_LOG("AttackerStateUpdate: (NPC) %u attacked %u (TypeId: %u) for %u dmg, absorbed %u, blocked %u, resisted %u.",
|
||||
GetGUIDLow(), pVictim->GetGUIDLow(), pVictim->GetTypeId(), damageInfo.damage, damageInfo.absorb, damageInfo.blocked_amount, damageInfo.resist);
|
||||
|
||||
// if damage pVictim call AI reaction
|
||||
if(pVictim->GetTypeId()==TYPEID_UNIT && ((Creature*)pVictim)->AI())
|
||||
((Creature*)pVictim)->AI()->AttackedBy(this);
|
||||
|
||||
// extra attack only at any non extra attack (normal case)
|
||||
if(!extra && extraAttacks)
|
||||
{
|
||||
|
|
@ -1989,10 +2005,6 @@ void Unit::AttackerStateUpdate (Unit *pVictim, WeaponAttackType attType, bool ex
|
|||
--m_extraAttacks;
|
||||
}
|
||||
}
|
||||
|
||||
// if damage pVictim call AI reaction
|
||||
if(pVictim->GetTypeId()==TYPEID_UNIT && ((Creature*)pVictim)->AI())
|
||||
((Creature*)pVictim)->AI()->AttackedBy(this);
|
||||
}
|
||||
|
||||
MeleeHitOutcome Unit::RollMeleeOutcomeAgainst(const Unit *pVictim, WeaponAttackType attType) const
|
||||
|
|
@ -7215,9 +7227,9 @@ bool Unit::AttackStop(bool targetSwitch /*=false*/)
|
|||
return true;
|
||||
}
|
||||
|
||||
void Unit::CombatStop(bool cast)
|
||||
void Unit::CombatStop(bool includingCast)
|
||||
{
|
||||
if(cast& IsNonMeleeSpellCasted(false))
|
||||
if (includingCast && IsNonMeleeSpellCasted(false))
|
||||
InterruptNonMeleeSpells(false);
|
||||
|
||||
AttackStop();
|
||||
|
|
@ -7227,19 +7239,19 @@ void Unit::CombatStop(bool cast)
|
|||
ClearInCombat();
|
||||
}
|
||||
|
||||
void Unit::CombatStopWithPets(bool cast)
|
||||
void Unit::CombatStopWithPets(bool includingCast)
|
||||
{
|
||||
CombatStop(cast);
|
||||
CombatStop(includingCast);
|
||||
if(Pet* pet = GetPet())
|
||||
pet->CombatStop(cast);
|
||||
pet->CombatStop(includingCast);
|
||||
if(Unit* charm = GetCharm())
|
||||
charm->CombatStop(cast);
|
||||
charm->CombatStop(includingCast);
|
||||
if(GetTypeId()==TYPEID_PLAYER)
|
||||
{
|
||||
GuardianPetList const& guardians = ((Player*)this)->GetGuardians();
|
||||
for(GuardianPetList::const_iterator itr = guardians.begin(); itr != guardians.end(); ++itr)
|
||||
if(Unit* guardian = Unit::GetUnit(*this,*itr))
|
||||
guardian->CombatStop(cast);
|
||||
guardian->CombatStop(includingCast);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -7424,6 +7436,33 @@ void Unit::UnsummonAllTotems()
|
|||
}
|
||||
}
|
||||
|
||||
int32 Unit::DealHeal(Unit *pVictim, uint32 addhealth, SpellEntry const *spellProto, bool critical)
|
||||
{
|
||||
int32 gain = pVictim->ModifyHealth(int32(addhealth));
|
||||
|
||||
if (GetTypeId()==TYPEID_PLAYER)
|
||||
{
|
||||
SendHealSpellLog(pVictim, spellProto->Id, addhealth, critical);
|
||||
|
||||
if (BattleGround *bg = ((Player*)this)->GetBattleGround())
|
||||
bg->UpdatePlayerScore((Player*)this, SCORE_HEALING_DONE, gain);
|
||||
|
||||
// use the actual gain, as the overheal shall not be counted, skip gain 0 (it ignored anyway in to criteria)
|
||||
if (gain)
|
||||
((Player*)this)->GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_HEALING_DONE, gain, 0, pVictim);
|
||||
|
||||
((Player*)this)->GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HEAL_CASTED, addhealth);
|
||||
}
|
||||
|
||||
if (pVictim->GetTypeId()==TYPEID_PLAYER)
|
||||
{
|
||||
((Player*)pVictim)->GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_TOTAL_HEALING_RECEIVED, gain);
|
||||
((Player*)pVictim)->GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_HIGHEST_HEALING_RECEIVED, addhealth);
|
||||
}
|
||||
|
||||
return gain;
|
||||
}
|
||||
|
||||
Unit* Unit::SelectMagnetTarget(Unit *victim, SpellEntry const *spellInfo)
|
||||
{
|
||||
if(!victim)
|
||||
|
|
|
|||
|
|
@ -855,8 +855,8 @@ class MANGOS_DLL_SPEC Unit : public WorldObject
|
|||
AttackerSet const& getAttackers() const { return m_attackers; }
|
||||
bool isAttackingPlayer() const;
|
||||
Unit* getVictim() const { return m_attacking; }
|
||||
void CombatStop(bool cast = false);
|
||||
void CombatStopWithPets(bool cast = false);
|
||||
void CombatStop(bool includingCast = false);
|
||||
void CombatStopWithPets(bool includingCast = false);
|
||||
Unit* SelectNearbyTarget() const;
|
||||
bool hasNegativeAuraWithInterruptFlag(uint32 flag);
|
||||
|
||||
|
|
@ -952,6 +952,7 @@ class MANGOS_DLL_SPEC Unit : public WorldObject
|
|||
|
||||
uint16 GetMaxSkillValueForLevel(Unit const* target = NULL) const { return (target ? getLevelForTarget(target) : getLevel()) * 5; }
|
||||
uint32 DealDamage(Unit *pVictim, uint32 damage, CleanDamage const* cleanDamage, DamageEffectType damagetype, SpellSchoolMask damageSchoolMask, SpellEntry const *spellProto, bool durabilityLoss);
|
||||
int32 DealHeal(Unit *pVictim, uint32 addhealth, SpellEntry const *spellProto, bool critical = false);
|
||||
|
||||
void ProcDamageAndSpell(Unit *pVictim, uint32 procAttacker, uint32 procVictim, uint32 procEx, uint32 amount, WeaponAttackType attType = BASE_ATTACK, SpellEntry const *procSpell = NULL);
|
||||
void ProcDamageAndSpellFor( bool isVictim, Unit * pTarget, uint32 procFlag, uint32 procExtra, WeaponAttackType attType, SpellEntry const * procSpell, uint32 damage );
|
||||
|
|
|
|||
|
|
@ -1949,7 +1949,6 @@ void World::ScriptsProcess()
|
|||
}
|
||||
|
||||
if( go->GetGoType()==GAMEOBJECT_TYPE_FISHINGNODE ||
|
||||
go->GetGoType()==GAMEOBJECT_TYPE_FISHINGNODE ||
|
||||
go->GetGoType()==GAMEOBJECT_TYPE_DOOR ||
|
||||
go->GetGoType()==GAMEOBJECT_TYPE_BUTTON ||
|
||||
go->GetGoType()==GAMEOBJECT_TYPE_TRAP )
|
||||
|
|
|
|||
|
|
@ -37,10 +37,8 @@ typedef DatabasePostgre DatabaseType;
|
|||
#define _OFFSET_ "LIMIT 1 OFFSET %d"
|
||||
#else
|
||||
#include "Database/QueryResultMysql.h"
|
||||
#include "Database/QueryResultSqlite.h"
|
||||
#include "Database/Database.h"
|
||||
#include "Database/DatabaseMysql.h"
|
||||
#include "Database/DatabaseSqlite.h"
|
||||
typedef DatabaseMysql DatabaseType;
|
||||
#define _LIKE_ "LIKE"
|
||||
#define _TABLE_SIM_ "`"
|
||||
|
|
|
|||
|
|
@ -1,101 +0,0 @@
|
|||
/*
|
||||
* Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#ifndef DO_POSTGRESQL
|
||||
|
||||
#include "DatabaseEnv.h"
|
||||
|
||||
DatabaseSqlite::DatabaseSqlite() : Database(), mSqlite(0)
|
||||
{
|
||||
}
|
||||
|
||||
DatabaseSqlite::~DatabaseSqlite()
|
||||
{
|
||||
if (mSqlite)
|
||||
sqlite_close(mSqlite);
|
||||
}
|
||||
|
||||
bool DatabaseSqlite::Initialize(const char *infoString)
|
||||
{
|
||||
if(!Database::Initialize(infoString))
|
||||
return false;
|
||||
|
||||
char *errmsg;
|
||||
|
||||
mSqlite = sqlite_open(infoString, 0, &errmsg);
|
||||
|
||||
if (!mSqlite)
|
||||
{
|
||||
|
||||
if (errmsg)
|
||||
sqlite_freemem(errmsg);
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
QueryResult* DatabaseSqlite::Query(const char *sql)
|
||||
{
|
||||
char *errmsg;
|
||||
|
||||
if (!mSqlite)
|
||||
return 0;
|
||||
|
||||
char **tableData;
|
||||
int rowCount;
|
||||
int fieldCount;
|
||||
|
||||
sqlite_get_table(mSqlite, sql, &tableData, &rowCount, &fieldCount, &errmsg);
|
||||
|
||||
if (!rowCount)
|
||||
return 0;
|
||||
|
||||
if (!tableData)
|
||||
{
|
||||
|
||||
if (errmsg)
|
||||
sqlite_freemem(errmsg);
|
||||
return 0;
|
||||
}
|
||||
|
||||
QueryResultSqlite *queryResult = new QueryResultSqlite(tableData, rowCount, fieldCount);
|
||||
if(!queryResult)
|
||||
{
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
queryResult->NextRow();
|
||||
|
||||
return queryResult;
|
||||
}
|
||||
|
||||
bool DatabaseSqlite::Execute(const char *sql)
|
||||
{
|
||||
char *errmsg;
|
||||
|
||||
if (!mSqlite)
|
||||
return false;
|
||||
|
||||
if(sqlite_exec(mSqlite, sql, NULL, NULL, &errmsg) != SQLITE_OK)
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
#endif
|
||||
|
|
@ -1,43 +0,0 @@
|
|||
/*
|
||||
* Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#ifndef DO_POSTGRESQL
|
||||
|
||||
#ifndef _DATABASESQLITE_H
|
||||
#define _DATABASESQLITE_H
|
||||
|
||||
#include <sqlite/sqlite.h>
|
||||
|
||||
class DatabaseSqlite : public Database
|
||||
{
|
||||
public:
|
||||
DatabaseSqlite();
|
||||
~DatabaseSqlite();
|
||||
|
||||
bool Initialize(const char *infoString);
|
||||
|
||||
QueryResult* Query(const char *sql);
|
||||
bool Execute(const char *sql);
|
||||
|
||||
operator bool () const { return mSqlite != NULL; }
|
||||
|
||||
private:
|
||||
sqlite *mSqlite;
|
||||
};
|
||||
#endif
|
||||
#endif
|
||||
|
|
@ -38,8 +38,6 @@ libmangosdatabase_a_SOURCES = \
|
|||
DatabasePostgre.cpp \
|
||||
DatabaseMysql.h \
|
||||
DatabasePostgre.h \
|
||||
DatabaseSqlite.cpp \
|
||||
DatabaseSqlite.h \
|
||||
DBCEnums.h \
|
||||
Field.cpp \
|
||||
Field.h \
|
||||
|
|
@ -50,8 +48,6 @@ libmangosdatabase_a_SOURCES = \
|
|||
QueryResultMysql.h \
|
||||
QueryResultPostgre.cpp \
|
||||
QueryResultPostgre.h \
|
||||
QueryResultSqlite.cpp \
|
||||
QueryResultSqlite.h \
|
||||
SQLStorage.cpp \
|
||||
SQLStorage.h \
|
||||
SQLStorageImpl.h \
|
||||
|
|
|
|||
|
|
@ -1,96 +0,0 @@
|
|||
/*
|
||||
* Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#ifndef DO_POSTGRESQL
|
||||
|
||||
#include "DatabaseEnv.h"
|
||||
|
||||
QueryResultSqlite::QueryResultSqlite(char **tableData, uint32 rowCount, uint32 fieldCount) :
|
||||
QueryResult(rowCount, fieldCount), mTableData(tableData), mTableIndex(0)
|
||||
{
|
||||
mCurrentRow = new Field[mFieldCount];
|
||||
|
||||
for (uint32 i = 0; i < mFieldCount; i++)
|
||||
{
|
||||
mFieldNames[i] = mTableData[i];
|
||||
mCurrentRow[i].SetType(Field::DB_TYPE_UNKNOWN);
|
||||
}
|
||||
}
|
||||
|
||||
QueryResultSqlite::~QueryResultSqlite()
|
||||
{
|
||||
EndQuery();
|
||||
}
|
||||
|
||||
bool QueryResultSqlite::NextRow()
|
||||
{
|
||||
int startIndex;
|
||||
uint32 i;
|
||||
|
||||
if (!mTableData)
|
||||
return false;
|
||||
|
||||
if (mTableIndex >= mRowCount)
|
||||
{
|
||||
EndQuery();
|
||||
return false;
|
||||
}
|
||||
|
||||
startIndex = (mTableIndex + 1) * mFieldCount;
|
||||
for (i = 0; i < mFieldCount; i++)
|
||||
{
|
||||
mCurrentRow[i].SetValue(mTableData[startIndex + i]);
|
||||
}
|
||||
|
||||
++mTableIndex;
|
||||
return true;
|
||||
}
|
||||
|
||||
void QueryResultSqlite::EndQuery()
|
||||
{
|
||||
if (mCurrentRow)
|
||||
{
|
||||
delete [] mCurrentRow;
|
||||
mCurrentRow = NULL;
|
||||
}
|
||||
if (mTableData)
|
||||
{
|
||||
sqlite_free_table(mTableData);
|
||||
mTableData = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
enum Field::DataTypes QueryResultSqlite::ConvertNativeType(const char* sqliteType) const
|
||||
{
|
||||
if (sqliteType)
|
||||
{
|
||||
switch (*sqliteType)
|
||||
{
|
||||
case 'S':
|
||||
return Field::DB_TYPE_STRING;
|
||||
case 'I':
|
||||
return Field::DB_TYPE_INTEGER;
|
||||
case 'F':
|
||||
return Field::DB_TYPE_FLOAT;
|
||||
default:
|
||||
return Field::DB_TYPE_UNKNOWN;
|
||||
};
|
||||
}
|
||||
return Field::DB_TYPE_UNKNOWN;
|
||||
}
|
||||
#endif
|
||||
|
|
@ -1,43 +0,0 @@
|
|||
/*
|
||||
* Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
*/
|
||||
|
||||
#ifndef DO_POSTGRESQL
|
||||
|
||||
#if !defined(QUERYRESULTSQLITE_H)
|
||||
#define QUERYRESULTSQLITE_H
|
||||
|
||||
#include <sqlite/sqlite.h>
|
||||
|
||||
class QueryResultSqlite : public QueryResult
|
||||
{
|
||||
public:
|
||||
QueryResultSqlite(char **tableData, uint32 rowCount, uint32 fieldCount);
|
||||
|
||||
~QueryResultSqlite();
|
||||
|
||||
bool NextRow();
|
||||
|
||||
private:
|
||||
enum Field::DataTypes ConvertNativeType(const char* sqliteType) const;
|
||||
void EndQuery();
|
||||
|
||||
char **mTableData;
|
||||
uint32 mTableIndex;
|
||||
};
|
||||
#endif
|
||||
#endif
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
#ifndef __REVISION_NR_H__
|
||||
#define __REVISION_NR_H__
|
||||
#define REVISION_NR "7692"
|
||||
#define REVISION_NR "7713"
|
||||
#endif // __REVISION_NR_H__
|
||||
|
|
|
|||
|
|
@ -144,12 +144,6 @@
|
|||
<File
|
||||
RelativePath="..\..\src\shared\Database\DatabaseMysql.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\DatabaseSqlite.cpp">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\DatabaseSqlite.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\Field.cpp">
|
||||
</File>
|
||||
|
|
@ -168,12 +162,6 @@
|
|||
<File
|
||||
RelativePath="..\..\src\shared\Database\QueryResultMysql.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\QueryResultSqlite.cpp">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\QueryResultSqlite.h">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\SqlDelayThread.cpp">
|
||||
</File>
|
||||
|
|
|
|||
|
|
@ -368,14 +368,6 @@
|
|||
RelativePath="..\..\src\shared\Database\DatabaseMysql.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\DatabaseSqlite.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\DatabaseSqlite.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\Field.cpp"
|
||||
>
|
||||
|
|
@ -400,14 +392,6 @@
|
|||
RelativePath="..\..\src\shared\Database\QueryResultMysql.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\QueryResultSqlite.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\QueryResultSqlite.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\SqlDelayThread.cpp"
|
||||
>
|
||||
|
|
|
|||
|
|
@ -372,14 +372,6 @@
|
|||
RelativePath="..\..\src\shared\Database\DatabaseMysql.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\DatabaseSqlite.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\DatabaseSqlite.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\Field.cpp"
|
||||
>
|
||||
|
|
@ -404,14 +396,6 @@
|
|||
RelativePath="..\..\src\shared\Database\QueryResultMysql.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\QueryResultSqlite.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\QueryResultSqlite.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\src\shared\Database\SqlDelayThread.cpp"
|
||||
>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue