Commit Graph
100 Commits
Author SHA1 Message Date
Arkshine 590e6b1258 C++11: Sync AMTL libraries from upstream 2014-12-06 14:00:15 +01:00
Vincent Herbet 2bba5ce69a Merge pull request #161 from 9iky6/patch-12
Fix spectators not being killed if silent switch is on
2014-12-05 17:23:37 +01:00
Vincent Herbet 8951f80748 Merge pull request #159 from Arkshine/fix-get_user_name
Fix typo in get_user_name() where hostname was returned as blank string
2014-11-13 21:20:40 +01:00
Arkshine 4ffd847b7a Fix typo in get_user_name() where hostname was returned as blank string 2014-11-13 19:01:26 +01:00
Vincent Herbet 0dd638d0fd Merge pull request #158 from Arkshine/fix-sizeof-fix
Improve more sizeof return on array without specifiying the dimensions
2014-11-11 21:09:44 +01:00
Arkshine 1a97b2cbe1 Improve more sizeof return on array without specifiying the dimension 2014-11-11 12:34:16 +01:00
Vincent Herbet 9b662bb0ca Merge pull request #157 from Chuvi-w/master
Revert "Done" text due to AMXX-Studio compatibility.
2014-11-10 19:33:14 +01:00
Vincent Herbet 666aaf013a Merge pull request #156 from 9iky6/patch-11
Fix stock regex_match_simple
2014-11-07 14:57:12 +01:00
Vincent Herbet d5086f6a54 Merge pull request #154 from ClaudiuHKS/master
Add MySQL Reconnect Feature
2014-10-28 10:15:30 +01:00
Vincent Herbet 6e60b596d7 Merge pull request #152 from Arkshine/improve-find_ent_by_owner
Allow find_ent_by_owner native to work in client_disconnect forward
2014-10-26 13:06:55 +01:00
Vincent Herbet 929d6255fc Merge pull request #153 from Arkshine/fix-ham-specialbot
Fix specialbot not working with [Enable/Disable]HamForward natives
2014-10-26 13:06:38 +01:00
Arkshine b451fbd1c8 Fix specialbot not working with [Enable/Disable]HamForward natives 2014-10-25 20:44:17 +02:00
Vincent Herbet 419bdecc20 Merge pull request #149 from Arkshine/improve-get_map_objectives
Improve get_map_objectives native
2014-10-25 12:10:32 +02:00
Vincent Herbet 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
Vincent Herbet 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
Arkshine cfcd6e9ac9 Allow find_ent_by_owner native to work in client_disconnect forward 2014-10-25 11:08:31 +02:00
Arkshine 1bd022305f Add MSG_INIT support in messsage_begin native (bug 6254) 2014-10-24 21:04:42 +02:00
Arkshine d0ab27092c Allow show_menu native to send empty text and add reset_menu stock (bug 6244) 2014-10-24 20:36:38 +02:00
Arkshine 850ae540a9 Improve get_map_objectives native. 2014-10-24 12:58:24 +02:00
Vincent Herbet b2aa84ddbd Merge pull request #147 from Arkshine/fix-linux-warning
Fix linux warning in previous commit
2014-10-24 11:43:04 +02:00
Arkshine 9cf4564057 Fix linux warning in previous commit 2014-10-24 11:25:52 +02:00
Vincent Herbet d8fc093fd8 Merge pull request #143 from ClaudiuHKS/master
Colored Menus and GeoIP Bug Fix
2014-10-18 20:18:29 +02:00
Vincent Herbet 3894e53cf6 Merge pull request #141 from Freeman-AM/master
Removal of many hardcoded contents (part 1)
2014-10-13 10:18:32 +02:00
Vincent Herbet 2e1a7b56d8 Merge pull request #140 from Nextra/menu-recursion
Fix recursion issues with show_menu and newmenus
2014-10-11 10:58:00 +02:00
Vincent Herbet 581f734099 Merge pull request #139 from 9iky6/patch-10
Update engine_stocks.inc
2014-10-05 15:42:21 +02:00
Vincent Herbet f8b2d26a00 Merge pull request #137 from Arkshine/update-compiler-2
Update compiler - 2
2014-09-29 20:42:17 +02:00
Arkshine 3b3e78d65b Compiler: Remove commented code in previous commit 2014-09-29 20:36:14 +02:00
Vincent Herbet a8efe40293 Merge pull request #138 from Arkshine/sync-amtl
Sync AMTL from upstream
2014-09-29 19:05:58 +02:00
Arkshine 35e661fdf9 Sync AMTL from upstream 2014-09-29 18:36:37 +02:00
Vincent Herbet e1206eb310 Merge pull request #136 from Freeman-AM/master
Missing stuff in cstrike and ns amxx.cfg
2014-09-29 17:39:18 +02:00
Arkshine 199b41af0a Compiler: Treat pawn warnings as errors when building 2014-09-29 15:55:16 +02:00
Arkshine e7c7313f77 Compiler: Add a flag for warnings-as-errors 2014-09-29 15:54:39 +02:00
Arkshine ae2699ca98 Compiler: Disable estimated memory usage 2014-09-29 15:12:56 +02:00
Vincent Herbet e7452e00ce Merge pull request #135 from Freeman-AM/master
CS Statx and DOD stats: add missing utf-8 symbols support in motd
2014-09-21 13:01:43 +02:00
Vincent Herbet a350be335b Merge pull request #134 from WildCard65/master
Fix typo in modules.cpp
2014-09-20 02:51:05 +02:00
Vincent Herbet 598936be46 Merge pull request #133 from Arkshine/sync-amtl
Sync AMTL
2014-09-18 19:41:51 +02:00
Vincent Herbet d0623e5ef7 Merge pull request #132 from Arkshine/geoip-fix-typo
Fix typo in #99 (reported by Hattrick)
2014-09-18 19:41:40 +02:00
Vincent Herbet bc5924a780 Merge pull request #131 from Arkshine/fix-plugin-warning
Fix unreachable code warning (reported by kwpd)
2014-09-18 19:41:31 +02:00
Arkshine c1dca680f2 Don't remove this return 2014-09-18 19:35:29 +02:00
Arkshine d4b0444d7a Sync AMTL 2014-09-18 19:29:58 +02:00
Arkshine d9efe61030 Fix typo in #99 (reported by Hattrick) 2014-09-18 19:24:37 +02:00
Arkshine a93886fb65 Fix unreachable code warning (reported by kwpd) 2014-09-18 19:17:00 +02:00
Vincent Herbet 87774ae21f Merge pull request #130 from Arkshine/fix-regression
Fix a crash regression in #112
2014-09-15 13:27:49 +02:00
Arkshine 19e06100b2 Fix a crash regression in #112 2014-09-15 09:57:38 +02:00
Vincent Herbet e8acb93b99 Merge pull request #75 from LittleKu/patch-1
Add chinese language
2014-09-04 23:25:11 +02:00
Vincent Herbet 152c984176 Merge pull request #128 from Arkshine/Fix-missing-compiler-message
Fix compiler crash due to missing recursion message warning (bug 6251)
2014-08-31 14:59:08 +02:00
Arkshine de85f2735e Fix compiler crash due to missing recursion message warning. 2014-08-31 14:52:24 +02:00
Vincent Herbet 39cf32879d Merge pull request #127 from Ni3znajomy/master
Fix a typo in the documentation.
2014-08-29 22:04:14 +02:00
Vincent Herbet 1463103cd7 Merge pull request #116 from Arkshine/update-compiler-safe-fix-feature
Update compiler
2014-08-26 09:07:45 +02:00
Arkshine f30c7a63b1 Compiler: Fix linux compilation and close file handle on success in pc_opensrc. 2014-08-26 09:06:02 +02:00
Arkshine e46785a434 Compiler: Improve/fix recursion detection.
Imported from Pawn 3.2.3664 and 3.3.3875.
2014-08-26 09:05:23 +02:00
Arkshine a873066466 Compiler: Fix enum field size was not taken into account when implicitly passed to a function.
Imported from Pawn 3.3.3930.

Example:

---

enum tag
{
  member[32]
}

new var[tag];

foo(const string[], size = sizeof(string))
{
    // size returns 1 before fix, 32, after.
}

public plugin_init()
{
    foo(var[member]);
}

---
2014-08-26 09:05:22 +02:00
Arkshine f60b00ee71 Compiler: Use hash table for global name lookups.
Imported from SM: https://bugs.alliedmods.net/show_bug.cgi?id=4496.
2014-08-26 09:05:20 +02:00
Arkshine a876962405 Compiler: Use in-memory buffers for reading files, and handle newlines better.
Imported from https://github.com/alliedmodders/sourcemod/pull/63.
2014-08-26 09:05:18 +02:00
Arkshine c2ca5d857d Compiler: Change __line to __LINE__. 2014-08-26 09:05:17 +02:00
Arkshine 27825963f6 Compiler: Fix indentation. 2014-08-26 09:05:15 +02:00
Arkshine ca7b0ceadd Compiler: Revert "Add #warning directive."
Probably not that useful.
2014-08-26 09:05:13 +02:00
Arkshine 32b546df69 Compiler: Revert "Fix runtime error in variadic functions that return strings."
Better fix by dvander will be provided later.
2014-08-26 09:05:11 +02:00
Arkshine cea2f598b2 Compiler: Fix a regression in handling multi-dimensional arrays (introduced in 744d67b)
Fix imported from Pawn 3.3.4058.
2014-08-26 09:05:10 +02:00
Arkshine d44eb7bf8d Compiler: Update VERSION_INT.
Some people may want to check compiler version with __Pawn, and it would be a good idea to bump the version.
Since we have a special version, and to avoid to use digit which may be used by official version, I propose using letters, so: 0x30A.
This should be resonneable.
2014-08-26 09:05:08 +02:00
Arkshine e1445316aa Compiler: Fix moar. 2014-08-26 09:05:07 +02:00
Arkshine 238e3707c8 Compiler: Fix linux compilation. 2014-08-26 09:05:05 +02:00
Arkshine 16e5f54507 Compiler: Improve the reported line number accuracy on warning 203/4 (symbol never used).
Imported from Pawn 3.1.3541+.
https://code.google.com/p/pawnscript/source/detail?r=25
2014-08-26 09:05:03 +02:00
Arkshine 65c29cafa0 Compiler: Fix #elseif handling not working as expected.
Improted from Pawn 3.1.3636.

-- Example

#define VAR 1

#if VAR == 1
  // code
#elseif VAR == 2
  // code
#endif

--
Returns error(38).
2014-08-26 09:05:01 +02:00
Arkshine c4b233d094 Compiler: Improve sizeof return on array without specifiying the dimensions.
Imported from Pawn 3.1.3636.

"When making an array without specifiying the dimensions, but where the element
count at the lowest dimension is the same for all, the compiler now "counts"
this size, rather than setting the lowest dimension as "variable length".

An example for this situation is the declaration:
    new my_array[][] = { {1,0}, {2,1}, {3,1} }
No dimensions are given, but the new compiler determines that the minor
dimension is 2 (and the major dimension is 3). Previous compilers set the
minor dimension to 0 --meaning "variable"."
2014-08-26 09:05:00 +02:00
Arkshine cd189320e5 Compiler: Fix the "@" character was not allowed in macro definitions (while the documentation stated that they were).
Imported from Pawn 3.1.3599.
2014-08-26 09:04:58 +02:00
Arkshine 17114347d1 Compiler: Fix runtime error in variadic functions that return strings.
Imported from SM-AM: https://github.com/Zeex/pawn/commit/1d1244c2f04845051ef94f5455b18703b59e113f.

"This fixes a bug where returning a string from a variadic function caused
an invalid memory access error during runtime. It seems like they forgot
to update existing string return code for variadic functions."
2014-08-26 09:04:56 +02:00
Arkshine 1866afd80b Compiler: Add __line
Imported from SA-MP: https://github.com/Zeex/pawn/commit/605ae7f4d3530640f50c2d5d59668deb0db15079
This is a backport from Pawn 4.0. It sets to the current line number during compile time.
Documention for 3.x actually mention this.
2014-08-26 09:04:55 +02:00
Arkshine fcdeea683b Compiler: Add #warning directive.
Basically same as error but as warning.
Imported from SA-MP: https://github.com/Zeex/pawn/commit/1bd6be93e06ff0e56d264e633b23c7d899b034e0

Example:

  #warning don't eat egg.

Result:

  warning.sma(1) : warning 234: user warning: don't eat egg.
2014-08-26 09:04:53 +02:00
Arkshine 92255bcdc3 Compiler: Fix crash when using tagof(tagname:)
Imported from SA-MP: https://github.com/Zeex/pawn/commit/53ef10ffc787545672af4118355ba340dd6b5e7c
2014-08-26 09:04:52 +02:00
Arkshine b2442a2268 Compiler: Ignore #pragma tabsize with non-positive argument.
Imported from SA-MP: https://github.com/Zeex/pawn/commit/7f30a03f9411d2169ee9e413ceb8f5b9c07dc120.
2014-08-26 09:04:50 +02:00
Arkshine 1b3b07d4d8 Compiler: Add __BINARY_PATH__ and __BINARY_FILE__.
Imported from SM: https://hg.alliedmods.net/sourcemod-central/rev/bd38ac67afe1 and https://hg.alliedmods.net/sourcemod-central/rev/eb4c45360aaf.
2014-08-26 09:04:48 +02:00
Arkshine 95f3b0d354 Compiler: Fix return omission with else-after-return.
Imported from SM: https://bugs.alliedmods.net/show_bug.cgi?id=4852.
2014-08-26 09:04:47 +02:00
Arkshine 9b5c6bfff0 Compiler: Fix asserting when returning a string literal.
Imported from SM: https://bugs.alliedmods.net/show_bug.cgi?id=3836.
2014-08-26 09:04:45 +02:00
Arkshine 57b172072a Compiler: Fix bogus assert about name lengths.
Imported from SM: https://bugs.alliedmods.net/show_bug.cgi?id=4486.
2014-08-26 09:04:44 +02:00
Arkshine 3b2618f63b Compiler: Fix improper handling of constant chained relational operators.
Imported from SM: https://bugs.alliedmods.net/show_bug.cgi?id=3838.
2014-08-26 09:04:42 +02:00
Arkshine 4f525b9150 Compiler: Fix memory corruption when parsing natives.
Imported from SM: https://bugs.alliedmods.net/show_bug.cgi?id=5840
2014-08-26 09:04:40 +02:00
Arkshine 325a746d90 Compiler: Fix issue with multidimensional array variable release.
Imported from SM: https://bugs.alliedmods.net/show_bug.cgi?id=6100.
2014-08-26 09:04:39 +02:00
Arkshine 6978e2dc4c Compiler: Fix in recursion detection.
Original fix imported from pawn 3.1.3522.
This fixes where for some plugins you would have:

   Stack/heap size:      16384 bytes; usage is unknown, due to recursion

Now, you get:

   Stack/heap size:      16384 bytes; estimated max. usage=782 cells (3128 bytes)
2014-08-26 09:04:37 +02:00
Arkshine 520493fab1 Compiler: Add #pragma deprecated.
This is based on SM, including patch to support macros/constants (https://hg.alliedmods.net/sourcemod-central/rev/ef8dd1cddc35).
Updated also some pawn includes to use this new pragma.
2014-08-26 09:04:36 +02:00
Arkshine 09303625fb Compiler: Generate .scp files as part of the build process.
Stolen from SM (https://github.com/alliedmodders/sourcemod/pull/112).
2014-08-26 09:02:38 +02:00
Arkshine 02b6d0a288 Compiler: Increase input line length.
1023 can be achieved really fastly, e.g. with some SQL definitions.
This is the same value as SM.
2014-08-26 09:02:36 +02:00
Vincent Herbet 4d454b474c Attempt to fix build 2014-08-23 10:17:47 +02:00
Vincent Herbet 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
Vincent Herbet ccf919c58c Fix typo in previous commit (r=dvander) 2014-08-21 20:57:08 +02:00
Vincent Herbet 9e0f946696 Merge pull request #124 from Arkshine/fix-sound-onbuy
Block weapon pickup sound if shield is disallowed in CS_OnBuy forward.
2014-08-19 19:27:36 +02:00
Vincent Herbet 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
Arkshine bf23890a34 Reverse condition for clarity and to make Nextra happy! 2014-08-19 18:25:00 +02:00
Vincent Herbet 9eedca0a98 Merge pull request #125 from Arkshine/fix-abort
Don't show blank line in abort() with AMX_ERR_NONE (bug 6233).
2014-08-19 18:15:24 +02:00
Arkshine 68aec7eec0 Use new flags in get_players/find_player instead to avoid breakage. 2014-08-19 15:39:06 +02:00
Arkshine 76811b7b84 Allow get_players() as well. 2014-08-19 10:08:25 +02:00
Vincent Herbet 38d43e8fc9 Merge pull request #122 from xPaw/lastmanhp
Add an option to disable showing last man's health (bug 5847)
2014-08-19 09:56:07 +02:00
Arkshine 9cd90838e1 Remove safety checks as it's not really necessary. 2014-08-19 09:04:09 +02:00
Arkshine e7d7de870a Block weapon pickup sound if shield is disallowed in CS_OnBuy forward. 2014-08-18 22:02:08 +02:00
Vincent Herbet bcbf454255 Merge pull request #123 from yamikaitou/master
Fix compile error
2014-08-18 14:36:49 +02:00
Arkshine 481e1528d6 Don't show blank line in abort() with AMX_ERR_NONE (bug 6233). 2014-08-17 23:33:00 +02:00
Arkshine 33c0a676fd Allow find_player() and engclient_print() (in console) to be used on connecting players (bug 6229). 2014-08-17 23:31:46 +02:00
Vincent Herbet 19f1c1a9ec Merge pull request #119 from reuben/metamod-path
Look for Metamod in ../metamod-hl1 as well since that's the name of the new git repo
2014-08-17 15:45:00 +02:00
Vincent Herbet f185eaa232 Update TRANS_SILENT Serbian translaton. 2014-08-16 17:41:27 +02:00
Vincent Herbet d49064b43e Merge pull request #113 from kiapwnz/silentswitch
Added Silent Transfer Option in Team Menu.
2014-08-16 15:13:18 +02:00