Commit Graph

279 Commits

Author SHA1 Message Date
Peace-Maker
0b131d6864 Pause dependent plugins on SetFailState (bug 6120)
When a plugin calls SetFailState it is paused and all natives it
registered are unavailable. Other plugins, which depend on those natives
keep running and error whenever they try to call those natives.

This correctly sets the dependent plugins to an error state as if the
plugin which called SetFailState was unloaded.
2014-12-20 11:07:57 +01:00
David Anderson
b1cb06c5ce Update DBI for transitional syntax. 2014-12-13 16:34:58 -08:00
David Anderson
722a23c818 Redo menu methodmaps. 2014-12-13 12:53:30 -08:00
Thordin
f27c33cd18 Increased handles to 32k 2014-12-07 21:50:40 -08:00
Sean Lewis
d2e01da287 Wrap 3rd parameter in FindValueInArray to check for existence. 2014-12-06 17:07:54 -06:00
Sean Lewis
3ef2bdcb8d Add block parameter to FindValueInArray native. 2014-12-06 03:21:53 -06:00
Asher Baker
50898d7a4f Merge pull request #208 from asherkin/long-lang-codes
Support long key names for languages (bug 6282)
2014-11-24 19:07:18 +00:00
Asher Baker
ced026cecc Support long key names for languages. (bug 6282) 2014-11-22 22:18:49 +00:00
David Anderson
be6da2f810 Merge pull request #173 from alliedmodders/tr-smc
Port SMC parsing API to transitional syntax.
2014-11-19 22:38:19 -08:00
David Anderson
0511543c76 Merge pull request #206 from alliedmodders/tr-files
Port files.inc to transitional syntax.
2014-11-18 18:56:07 -08:00
Nicholas Hastings
50400cf029 Remove unused variables. 2014-11-15 19:35:47 -05:00
David Anderson
79143d8b6e Port files.inc to transitional syntax. 2014-11-15 13:42:28 -08:00
David Anderson
f25953bb6c Merge pull request #187 from alliedmodders/tr-arrays
Update ArrayList for transitional syntax.
2014-11-15 13:04:29 -08:00
David Anderson
461dc3af3d Merge pull request #189 from alliedmodders/tr-tries
Port string maps to transitional syntax.
2014-11-15 12:52:37 -08:00
David Anderson
4cb29eb054 Port adt_stack to transitional syntax. 2014-11-15 12:46:17 -08:00
David Anderson
8479c2f067 Port SMC parsing API to transitional syntax. 2014-11-09 12:33:07 -08:00
David Anderson
6ba4bcb955 Port string maps to transitional syntax. 2014-11-08 17:43:28 -08:00
David Anderson
919a31df57 Update ArrayList for transitional syntax. 2014-11-08 16:31:33 -08:00
David Anderson
f16501d34a Simplify filesystem native implementation. 2014-11-08 15:44:35 -08:00
Nicholas Hastings
9021b23bc2 Fix crash on OpenDirectory with use_valve_fs if path not found.
Also fixes minor memory leak on bad path.
2014-10-28 13:57:40 -04:00
Nicholas Hastings
dca15ebabf Fix OpenDirectory with use_valve_fs requirement of trailing slash. 2014-10-28 13:53:27 -04:00
Nicholas Hastings
512fae4c25 Fix crash on Windows when dumping admin cache to file. 2014-10-08 17:31:02 -07:00
Nicholas Hastings
0f6063af60 Re-add DBI query throttling (r=dvander). 2014-09-18 22:02:32 -04:00
Nicholas Hastings
c62e7458f9 Disable RTTI for Loader, Logic, and JIT bins 2014-09-11 17:15:59 -07:00
Nicholas Hastings
e6fd19fb8c Fix crash regression from typo in 892edd9650 2014-09-09 22:05:59 -04:00
Nicholas Hastings
a597277a64 Merge pull request #153 from alliedmodders/auth-fixups
More auth fixups for Steam auth (bug 6243, r=asherkin).
2014-09-09 16:24:57 -04:00
Nicholas Hastings
b3dada65fa Fix build. 2014-09-09 13:21:01 -07:00
Nicholas Hastings
ad7d920ce0 Move menu natives from core to logic 2014-09-05 08:24:40 -07:00
Nicholas Hastings
1bf4eb80bd Cache Steam ID and rendered forms when caching networkID 2014-09-04 16:14:34 -07:00
Nicholas Hastings
f1dc24c089 Move Steam2/3 id rendering logic to CPlayer 2014-09-04 15:27:44 -07:00
Nicholas Hastings
892edd9650 Allow BindIdentity and FindAdminByIdentity to take more SteamID formats for steam auth type 2014-09-04 15:26:12 -07:00
David Anderson
a1dc1101f7 Fix build. 2014-09-03 22:33:05 -07:00
Nicholas Hastings
7f3656215b Consistency Fixes (ID->Id, AuthString->AuthId) 2014-09-03 15:13:30 -07:00
Nicholas Hastings
3fba1d2817 Fix some nits 2014-09-03 10:50:11 -07:00
Nicholas Hastings
e11fec9ba1 Rename GetClientAuthString2 to GetClientAuthId 2014-09-02 18:11:36 -07:00
Nicholas Hastings
eafd6626ec Fix true return when validation wanted and steam id pending 2014-09-02 17:44:11 -07:00
Nicholas Hastings
e3b87a5ca4 Spin new logic into GetClientAuthString2...
and mark GetClientAuthString as deprecated, using 1.6.x GetClientAuthString behavior
2014-09-02 17:43:10 -07:00
Nicholas Hastings
8c89b72fbc Expose explicit client auth string formats 2014-09-02 14:40:39 -07:00
Nicholas Hastings
e093c7f72a Merge pull request #120 from alliedmodders/wip-valve-fs2
Add support for Valve FS to natives that use file handles (r=asherkin).
2014-08-30 14:25:53 -04:00
David Anderson
9267d0c803 Eliminate Newborn/NoAddRef (bug 5907, r=ds). 2014-08-22 22:50:25 -07:00
Nicholas Hastings
73115f7afa Add support for specifying gameinfo search path when using valveFS in file natives 2014-08-22 06:00:43 -07:00
Nicholas Hastings
e1158889e5 Fix backwards use_valve_fs logic for OpenDirectory 2014-08-22 05:56:23 -07:00
Nicholas Hastings
5716927cbf Fix compile error on with MSVC. 2014-08-20 21:37:47 -04:00
Nicholas Hastings
09250f89cc Merge pull request #133 from alliedmodders/logger-logic
Move Logger and core natives from core to logic (r=dvander).
2014-08-20 06:43:31 -04:00
Nicholas Hastings
e9ba251c1c Fix link errors. 2014-08-17 11:11:55 -04:00
Nicholas Hastings
e4645332aa Convert missed files in logic to use logger from logic. 2014-08-17 11:06:43 -04:00
Nicholas Hastings
8ffdfb6a0c Merge pull request #43 from hlstriker/master
Added a new function SetFilePermissions to set permissions of a file (r=psychonic).
2014-08-16 10:02:09 -04:00
Kyle Sanderson
766b6e1770 Merge pull request #127 from alliedmodders/coremapend
Add OnCoreMapEnd to extension's interface.
2014-08-15 20:48:59 -07:00
Nicholas Hastings
486910a9a1 Add missing files 2014-08-13 14:26:18 -07:00
Nicholas Hastings
17d5af0e2f Move Logger and Core natives to Logic 2014-08-13 14:24:35 -07:00
David Anderson
4b8e26463a Merge pull request #122 from peace-maker/datapack_funcpointer
Add WritePackFunction and ReadPackFunction natives
2014-08-12 10:33:27 -07:00
Ryan Stecker
0bde28cc17 Add a command to dump profiling output. 2014-08-09 13:32:05 -05:00
Ruben Gonzalez
7a88386568 Add OnCoreMapEnd to extension's interface. 2014-08-08 01:01:47 -04:00
Nicholas Hastings
4e5b1a58ce Add ValveFS support to more filesystem functions: OpenDirectory (CloseHandle on directory) ReadDirEntry DirExists CreateDirectory RenameFile 2014-08-06 13:15:24 -07:00
Peace-Maker
bfcfbbe107 Add WritePackFunction and ReadPackFunction natives
Adds type safety to CDataPack. Cells can't be read as Float anymore. Now
you're able to store a function pointer in a datapack and be sure the
pointer can't be read as a cell and a cell can't be read as a function
pointer.
2014-08-04 02:05:25 +02:00
Nicholas Hastings
f2b19e6c87 Add more accurate return value for DeleteFile when using Valve FS. 2014-08-03 09:10:02 -04:00
Nicholas Hastings
573aea20fb More progress:
Abstracted many fs funcs with helper class.
Removed much duplicated code.
Fixed ReadFile assuming FS errors for ValveFS.
Added ValveFS support for ReadFileString, WriteFile, WriteFileString, DeleteFile.
Added missing param in doc for OpenFile.
2014-08-01 12:38:51 -07:00
Nicholas Hastings
5e7e7ce551 Improved FPrint(f) passthrough 2014-08-01 06:09:09 -07:00
Ruben Gonzalez
c116353285 WiP addition of support for ValveFS to many more filesystem natives. 2014-07-31 20:56:07 -04:00
David Anderson
2a46f8f881 Add GetNativeFunction (bug 6200). 2014-07-23 23:36:11 -07:00
David Anderson
db9ee5326a Allow CloseHandle() on nulls. 2014-07-05 13:52:44 -07:00
Andrew
3022b665dd Initialized the mask variable.
Moved the FPERM_ defines into the .cpp and removed the header file.
2014-06-27 16:43:51 -04:00
David Anderson
b26552d74c Improve usability of start/stop. 2014-06-24 20:55:53 -07:00
David Anderson
fac52a2897 Fill out API more. 2014-06-24 01:18:16 -07:00
David Anderson
ec61d4d188 Add a general profiling abstraction layer. 2014-06-24 01:04:13 -07:00
David Anderson
b64551e984 Fix a Handle leak when reporting transaction errors. 2014-06-22 11:05:20 -07:00
Andrew
f3299b2c8c Added a new function SetFilePermissions to set permissions of a file. I'm not sure about the Windows implementation. See this feature request: https://bugs.alliedmods.net/show_bug.cgi?id=6152 2014-06-21 00:45:07 -04:00
David Anderson
f250461648 Fix typo. 2014-06-05 01:28:53 -07:00
David Anderson
36c342fc7b Add comment. 2014-06-05 01:22:44 -07:00
David Anderson
e6d8416f0e Fix typo. 2014-06-05 00:59:46 -07:00
David Anderson
cb16a78681 Fix memory bugs. 2014-06-05 00:38:09 -07:00
David Anderson
2930fb1963 Change indentation. 2014-06-04 22:46:40 -07:00
David Anderson
d7b49f7706 Initial implementation. 2014-06-04 22:45:26 -07:00
Nicholas Hastings
6ee42dc7fe Really fix Mac build. 2014-05-29 15:09:38 -04:00
Nicholas Hastings
e0f6544c86 Fix Mac build. 2014-05-29 14:16:11 -04:00
Asher Baker
ab68e70998 Merge pull request #14 from psychonic/rip-magic
Replace magic numbers for sm_show_activity with named constants (r=asherkin).
2014-05-29 19:06:22 +01:00
Nicholas Hastings
beb3f8c1d4 Replace magic numbers for sm_show_activity with named constants. 2014-05-29 13:54:51 -04:00
Nicholas Hastings
35784c018d Move adminsys and more natives from core to logic. 2014-05-29 13:31:12 -04:00
Nicholas Hastings
dbc881143b Move many player natives from core to logic. 2014-05-28 23:20:41 -04:00
Peace-Maker
6ac013376f Call OnLibraryAdded for all available libraries (bug 5925, PR #4)
commit c1b064c9232553045f6f5bfaf7df0feb6ceb4571
Author: Peace-Maker <peace-maker@wcfan.de>
Date:   Wed May 28 03:16:22 2014 +0200

    Coding style adjustments

commit 37a16dbba24cc2035fb8838be8729067cb9bc13a
Author: Peace-Maker <peace-maker@wcfan.de>
Date:   Wed May 28 03:03:25 2014 +0200

    Load core.phrases before calling OnLibraryAdded

commit 676ac951111c7e8f565debbd4316850a4c4a8d00
Author: Peace-Maker <peace-maker@wcfan.de>
Date:   Tue May 27 13:18:48 2014 +0200

    Call OnLibraryAdded for all available librarys (bug 5925)

    When loading multiple plugins at once (on server start or mapchange)
    OnLibraryAdded is only called for libraries which are loaded after the
    current plugin. The plugin isn't informed about the libraries that were
    added before its OnPluginStart forward was called.

    This patch calls OnLibraryAdded for all already registered libraries the
    current plugin has missed.
2014-05-27 19:26:58 -07:00
David Anderson
cfde247ef7 Revert "Call OnLibraryAdded for all available librarys (bug 5925, pull request #4)"
This reverts commit ac11eb8910.
2014-05-27 19:25:52 -07:00
David Anderson
ac11eb8910 Call OnLibraryAdded for all available librarys (bug 5925, pull request #4)
commit c1b064c9232553045f6f5bfaf7df0feb6ceb4571
Author: Peace-Maker <peace-maker@wcfan.de>
Date:   Wed May 28 03:16:22 2014 +0200

    Coding style adjustments

commit 37a16dbba24cc2035fb8838be8729067cb9bc13a
Author: Peace-Maker <peace-maker@wcfan.de>
Date:   Wed May 28 03:03:25 2014 +0200

    Load core.phrases before calling OnLibraryAdded

commit 676ac951111c7e8f565debbd4316850a4c4a8d00
Author: Peace-Maker <peace-maker@wcfan.de>
Date:   Tue May 27 13:18:48 2014 +0200

    Call OnLibraryAdded for all available librarys (bug 5925)

    When loading multiple plugins at once (on server start or mapchange)
    OnLibraryAdded is only called for libraries which are loaded after the
    current plugin. The plugin isn't informed about the libraries that were
    added before its OnPluginStart forward was called.

    This patch calls OnLibraryAdded for all already registered libraries the
    current plugin has missed.
2014-05-27 19:24:33 -07:00
Kyle Sanderson
9c62e94239 Optimize native call if statically bound (bug 5842, r=ds,fyren f=dvander).
Original patch written by David Anderson (original r from Fyren).
- Updated to function with the current JIT compiler.
- Took in clean-ups from later-dated patches.
2014-05-11 14:36:32 -07:00
Peace-Maker
5149205109 Clear default driver reference if unloaded (bug 5934, r=dvander). 2014-05-09 10:36:58 -07:00
Nicholas Hastings
f0d6fd1912 Fix usage of replace param in SetTrieArray (bug 6113, r=asherkin). 2014-05-04 21:38:32 -04:00
Scott Ehlert
ecec7dbef3 Deduplicate a number of files used by extensions by moving them to the public directory (bug 5341, r=psychonic).
These files include smsdk_ext.cpp, smsdk_ext.h, sm_memtable.h, CDetour/*, and asm/*.
The smsdk_config.h file for each extension has also been moved out of the 'sdk' directory into its parent.

--HG--
rename : extensions/bintools/sdk/smsdk_config.h => extensions/bintools/smsdk_config.h
rename : extensions/clientprefs/sdk/smsdk_config.h => extensions/clientprefs/smsdk_config.h
rename : extensions/cstrike/sdk/smsdk_config.h => extensions/cstrike/smsdk_config.h
rename : extensions/curl/sdk/smsdk_config.h => extensions/curl/smsdk_config.h
rename : extensions/geoip/sdk/smsdk_config.h => extensions/geoip/smsdk_config.h
rename : extensions/mysql/sdk/smsdk_config.h => extensions/mysql/smsdk_config.h
rename : extensions/regex/sdk/smsdk_config.h => extensions/regex/smsdk_config.h
rename : extensions/sdkhooks/sdk/smsdk_config.h => extensions/sdkhooks/smsdk_config.h
rename : extensions/sdktools/sdk/smsdk_config.h => extensions/sdktools/smsdk_config.h
rename : extensions/sqlite/sdk/smsdk_config.h => extensions/sqlite/smsdk_config.h
rename : extensions/structs/sdk/smsdk_config.h => extensions/structs/smsdk_config.h
rename : extensions/tf2/sdk/smsdk_config.h => extensions/tf2/smsdk_config.h
rename : extensions/topmenus/sdk/smsdk_config.h => extensions/topmenus/smsdk_config.h
rename : extensions/updater/sdk/smsdk_config.h => extensions/updater/smsdk_config.h
rename : extensions/sdktools/CDetour/detourhelpers.h => public/CDetour/detourhelpers.h
rename : extensions/sdktools/CDetour/detours.cpp => public/CDetour/detours.cpp
rename : extensions/sdktools/CDetour/detours.h => public/CDetour/detours.h
rename : extensions/sdktools/asm/asm.c => public/asm/asm.c
rename : extensions/sdktools/asm/asm.h => public/asm/asm.h
rename : public/sample_ext/sdk/smsdk_config.h => public/sample_ext/smsdk_config.h
rename : core/logic/sm_memtable.h => public/sm_memtable.h
rename : public/sample_ext/sdk/smsdk_ext.cpp => public/smsdk_ext.cpp
rename : public/sample_ext/sdk/smsdk_ext.h => public/smsdk_ext.h
2014-04-23 21:19:28 -05:00
David Anderson
61c4d2b805 Fix typo pointed out by Nephrite (bug 6107, comment #7).
--HG--
extra : rebase_source : 9e62da715c2560dd102644b04b5d46413d100890
2014-04-23 10:18:56 -07:00
David Anderson
c64edf31fc Fix Windows build, again. 2014-04-22 20:04:12 -07:00
David Anderson
e69e9eddc7 Change float comparison operators to return false for NaN (bug 6107, r=ds).
--HG--
extra : rebase_source : a11c56fb23d6617545def3591ec6100dd143eb3e
2014-04-22 19:40:45 -07:00
Ondrej Hošek
c3e9d7de41 Add support for single-file gamedata custom overrides (bug 5386, r=psychonic). 2014-04-07 12:14:26 -04:00
Nicholas Hastings
563dd617af Add sm_reload_translations command (bug 5750, r=asherkin). 2014-03-30 12:08:11 -04:00
Nicholas Hastings
2f6b64e92e Make IGameConfig::GetMemSig return value clearer (bug 6081, r=asherkin). 2014-03-29 14:22:53 -04:00
Scott Ehlert
ce6b993954 Use Linux game data for offsets and signatures/symbols on OS X if Mac-specific data is not available (bug 6056, r=dvander).
Although unlikely, OS X game data can also be used on Linux if Linux-specfic data is missing.
2014-02-15 23:23:53 -06:00
Nicholas Hastings
5abd9edf62 Remove over-aggressive error handling of Addresses gamedata (bug 6044, r=asherkin).
--HG--
extra : rebase_source : 704dcfdf285286814411f3dd5be2dd6e02872085
2014-02-10 09:43:10 -05:00
Scott Ehlert
e00e879af5 Use == instead of is operator for checking string equality in AMBuild scripts (bug 6043, r=dvander). 2014-02-09 22:50:20 -06:00
Ruben Gonzalez
925d514224 Increase max sig length (irc, r=psychonic)
--HG--
extra : amend_source : 24f20bd01d0277e255f47e0c4392396ec1871104
2014-02-08 20:00:52 -05:00
Kyle Sanderson
36cc7610a1 Fix bad handle Forward handling in RequstFrame (irc, r=psychonic). 2014-02-08 15:10:35 -07:00
Kyle Sanderson
06d2017a95 Remove unmanaged forwards from lookup list on Release (bug 6025, r=psychonic). 2014-02-08 14:51:44 -07:00
Nicholas Hastings
ad5740f8a7 Add support for Valve search paths to GetFileSize native (bug 5931, r=asherkin). 2014-01-07 14:24:53 -05:00
Nicholas Hastings
310f77d96a Consolidate FileExists usage in logic bin (bug 5931, r=asherkin). 2014-01-07 14:24:41 -05:00