Commit Graph

1215 Commits

Author SHA1 Message Date
78f577686a Fix ArrayDestroy/DestroyStack erroring on null handle 2015-02-17 23:24:17 +01:00
c071f53f2c Add new hashers and new natives
Replace the only hasher called MD5 with the ones listed below.

(+) CRC32, MD5, SHA1, SHA256, SHA3 224 BIT, SHA3 256 BIT, SHA3 384 BIT,
SHA3 512 BIT, Keccak 224 BIT, Keccak 256 BIT, Keccak 384 BIT and Keccak
512 BIT.

Add the natives listed below.

(+) hash_string(const string[], hashType:type, output[], const
outputSize)
(+) hash_file(const fileName, hashType:type, output[], const outputSize)
(+) is_arkshine_a_doctor() :  Hidden native, but a sign of recompense
for him being very active since 1.8.3 version of AMX Mod X
(+) get_system_endianness() :  Checks if the system is currently Big
Endian or Little Endian.

Add the following Enum.

(+) hashType {}
(+) sysEndianness {}

Deprecate the following natives.

(-) amx_md5()
(-) amx_md5_file()

It has been tested on Windows and Linux. The sanity checks seems to be
properly working, so no worries about them.

These are useful if people are using Sockets, cURLs or MySQLs in order
to compare hashes of different files On-line for further investigation.
You are not able to check if the files are older or newer, but you can
see if the content is different (Hash Checksum mismatch).

I'm glad I did this. Thanks to
2015-02-16 14:39:45 +02:00
7452317c10 Merge pull request #203 from Arkshine/fix/crash-on-shutdown
Fix crash by freeing memory the right way
2015-02-12 14:46:53 +01:00
120e5b94f9 Fix crash by freeing memory the right way 2015-02-12 14:37:46 +01:00
4ec11496e6 Fix missing new lines in "amxx version" command 2015-02-12 10:46:20 +01:00
fb28b2d416 Fix missing parenthesis. 2015-02-11 00:18:22 +01:00
e99a1c8b09 Fix crash when cvar hook detour is not created 2015-02-10 23:19:03 +01:00
7d084ee0bf Merge pull request #185 from Arkshine/feature/hooking-cvars
Introduce new features for cvars
2015-01-30 14:20:11 +01:00
1488b9747f Cvars: De-frenchify by Nextra 2015-01-29 21:44:53 +01:00
a5b5c7e9cd Cvars: Fix code to avoid Nextra be confused 2015-01-29 14:01:58 +01:00
f8baef15ca Cvars: Adjust more things
- Moved some functions in CvarManager
- Fixed detour enabled all the time
- Fixed bounds not properly handled
- Refreshed data of regisetered cvars at map change
2015-01-28 23:51:43 +01:00
187b187ef2 Cvars: To not traumatize Nextra 2015-01-28 00:58:07 +01:00
ac50f3ff34 Cvars: Check lower/upper bounds in create_cvar as well 2015-01-28 00:47:01 +01:00
e4a7e67783 Cvars: Adjust few things
- Hook is not as post, because allowing blocking change is not really that useful and this makes a context more simpler.
- Setting a min bound > max bound and reversely throw an error
- set_pcvar_bounds set cvar value on new min/max bound.
- Remove error "A cvar can't be binded with several variables", it's okay to no error such situation.
2015-01-28 00:26:24 +01:00
1a5e1928ec Cvars: Fix field orders and linux compilation 2015-01-27 16:27:26 +01:00
d75b14d4af Cvars: Extend "amxx cvars" command output 2015-01-27 15:07:17 +01:00
356a981164 Cvars: Add get/set_pcvar_bool natives 2015-01-26 14:26:48 +01:00
8a241ed0fd Cvars: Add new description param in get_plugins_cvar 2015-01-25 11:38:01 +01:00
cb0b9da51f Cvars: Add bind_pcvar_num/float/string 2015-01-24 21:31:00 +01:00
8ebb7be36d Cvars: Add get|set_pcvar_bounds natives 2015-01-24 15:04:49 +01:00
a05d0df50e Cvars: Add create_cvar native with more options (description, bounds) 2015-01-23 19:05:34 +01:00
15ad1d2247 Cvars: Moving cvars stuffs in its own files
cvars.cpp renamed to CvarManager.cpp
all cvars natives moved to a new cvars.cpp file
Pawn include is updated as wall.
2015-01-23 19:05:34 +01:00
768fa2c3bc Cvars: Add hook_cvar_change, [enable|disable]_cvar_hook natives 2015-01-23 19:05:33 +01:00
0db5963641 Cvars: Remove global forward 2015-01-23 19:05:33 +01:00
cdc7d550eb Cvars: Rearrange a bit some code
Changed class CCVar -> struct CvarInfo
Added CvarManager class and moved some code there
Code of registering a cvar is rewritten
Cvars datas are stored in a hashtable for fast lookup
For natives compatibility, an inline list is kept (though CList -> ke::InlineList)
Replace some CVAR_GET/SEt_ by FindVar
2015-01-23 19:05:32 +01:00
f973f5beb7 Cvars: Convert CString to ke::AString in CCVar class 2015-01-23 19:05:32 +01:00
6619176a76 Cvars: Move CCVar class to cvars.h 2015-01-23 19:05:31 +01:00
faeaf9259e Cvars: Add OnCvarChanged global forward
I really tried to use "cvar_changed" as name, but it bothered me so much to look that weird I could not keep it.
2015-01-23 19:05:31 +01:00
34d91789c4 Cvars: Hook Cvar_DirectSet from engine library 2015-01-23 19:05:30 +01:00
cdfd789f56 Rename change_level to engine_changelevel 2015-01-23 16:55:16 +01:00
dd9975cd67 Rename msvc10 directories to msvc12 2015-01-14 10:31:33 +01:00
97369c5d6c Upgrade VS projetcs to use v120_xp toolset and fix missing include paths 2015-01-14 10:25:46 +01:00
7f71cfaee7 Merge pull request #165 from Arkshine/feature/add-version-lib-and-missing-rc
Update versioning system and add missing module RC file (bug 6222)
2015-01-07 18:59:51 +01:00
7c96c30be8 Replace old SVN_* defines by the new ones 2014-12-08 01:42:42 +01:00
1146bcad2c C++11: Fix some code 2014-12-06 14:02:55 +01:00
4ffd847b7a Fix typo in get_user_name() where hostname was returned as blank string 2014-11-13 19:01:26 +01:00
5f824d64da Merge pull request #150 from Arkshine/add-reset_menu
Allow show_menu native to send empty text + add reset_menu stock (bug 6244)
2014-10-25 12:00:08 +02:00
79479e40c6 Merge pull request #151 from Arkshine/add-msg_init-support
Add MSG_INIT support in message_begin native (bug 6254)
2014-10-25 11:45:02 +02:00
1bd022305f Add MSG_INIT support in messsage_begin native (bug 6254) 2014-10-24 21:04:42 +02:00
d0ab27092c Allow show_menu native to send empty text and add reset_menu stock (bug 6244) 2014-10-24 20:36:38 +02:00
9cf4564057 Fix linux warning in previous commit 2014-10-24 11:25:52 +02:00
d1c0b8fea6 Improving Code 2014-10-18 11:09:49 -07:00
82cbc94f27 Improving Code 2014-10-18 10:58:26 -07:00
59a1b018ed Improving Code 2014-10-18 10:34:03 -07:00
aa963603ed Adding New Game Modifications Due Colored Menus
Adding New Game Modifications Due Colored Menus.
2014-10-18 10:09:11 -07:00
41d7554efd Fix recursion issues with show_menu and newmenus 2014-10-11 00:35:05 +02:00
a676d9ea52 Fix typo in modules.cpp
Ya...
2014-09-19 20:45:44 -04:00
204004b90e Merge pull request #112 from Arkshine/deduplicate-files
Deduplicate a number of files used by modules by moving them to the public directory
2014-08-23 10:00:13 +02:00
bd08cc5126 Merge pull request #126 from Arkshine/feature-find-player-engclient_print
Allow some natives to be used on connecting players (bug 6229).
2014-08-19 18:35:52 +02:00
bf23890a34 Reverse condition for clarity and to make Nextra happy! 2014-08-19 18:25:00 +02:00