Commit Graph
4169 Commits
Author SHA1 Message Date
aurhat 0b5180c628 Fix centring the 512x512 scope image 2016-07-03 13:19:52 +02:00
ac-stef 5fe69aa4b4 drop cube 1 media package support
Drop support for maps outside packages/maps and for package config files.
(never been used in AC anyway)

also: generate all map related filenames with proper path separators
2016-06-13 23:22:33 +02:00
aurhat 703d2413e9 Fix extension of files from zip config template 2016-06-12 16:24:25 +02:00
aurhat 3b0813412b Show on serverbrowser number of all players on the servers 2016-05-21 11:42:35 +02:00
aurhat baa24e0795 Show info about changing player only in multiplayer or demo mode 2016-05-10 22:00:05 +02:00
ac-stef 32ffd3a4cd replace non-thread-safe functions
replace all uses of strtok, localtime, gmtime and readdir

on platforms without safe versions, use homebrew or unsafe...
2016-02-28 23:14:47 +01:00
ac-stef 98d01d1f34 fix some errors and warnings for GCC 6
* do not use std::abs() because math.h includes one, that converts ints
  to double. Use own iabs(), which directly uses labs() instead.
* don't use the word "gamma" as name for variables
* don't use a homebrew round() function
2016-02-27 22:50:06 +01:00
ac-stef 535b9df746 define gamemode bitmasks 2016-02-07 18:34:32 +01:00
ac-stef 7f86ae8d9f new command getclosestent
getclosestent
  Returns the entity index number of the closest entity (or of the
  pinned entity, if one exists). Returns -1, if no entities are on the map.
  Returns always exactly the entity, that edit commands like delent
  will use next.

DOCREF getclosestent
2016-02-07 18:34:32 +01:00
ac-stef ecf178866e new command addentity
addentity <type>
  Adds an entity of the specified type at the current camera position
  and returns the index number of the new entity, so that the other
  attributes can be set by editentity.

DOCREF addentity
2016-02-07 18:34:32 +01:00
ac-stef 697197bd5b generalise sorting of lists of integer sets 2016-02-07 18:34:31 +01:00
ac-stef 4da510f51d fix http line recovery
this fixes the reconnect attempt after a http tcp connection was lost
2016-02-07 17:36:03 +01:00
aurhat 730b0ed7ee Fix state of player1 during watching a demo with arena mode
That fixes switching to edit mode during demo watching.
Also some minor fix added.
2016-01-17 22:18:59 +01:00
aurhat e4d5c2d361 Improve accuracy info and some elements of the HUD
Accuracy will be displayed only then, if scoreboard will be enabled, and
only for current weapon - in order to focus attention of players more on
gameplay/work for team than personal stats.
Added "accuracyinfo" command to see accuracy of all used weapons in
output console.
Added some cleanups and fixed memory leak.
2015-12-31 22:57:16 +01:00
aurhat cc2ac85dd5 Improve order of displaying on HUD
Now command console over hudmessages, hudmessages over flag icons/scores
and player's stats.
Also fixed length of the line in command console.
2015-12-13 22:10:30 +01:00
aurhat 957f1e49ca Cleanup
Note: abbreviation of minutes and seconds in HUD messages in ktf is
needed, because for 5:4 aspect ratio messages could not fit in display.
2015-12-13 22:08:16 +01:00
ac-stefandaurhat 1917a07dfa fix flag visibility for htf on maps without bases
- fixes issue #140
- also removed some stale debug code
2015-12-12 22:22:01 +01:00
aurhat 99ee7d10ef Change user data path for the dev version on Mac
Also one more directory level.
2015-11-16 21:03:48 +01:00
gy_be 5d1a9cac19 Fix a memory leak in command.cpp
Do not forget to free command name and its arguments if
it's not allowed in current execution context.
2015-11-09 10:20:24 +03:00
aurhat 747763fdf7 Show flag scores in "death camera" state 2015-10-20 21:57:16 +02:00
aurhat cf554261b9 Update licensing informations 2015-10-13 20:24:23 +02:00
ac-stef 0e6476806a fix crouching, jumping and doublejumping
* fix the old check for different jump start heights as requirement
  for doublejumps
* better handle multiple binds for the "jump" command
* delay relaxed floorclamping for crouching
* remove some redundant code
2015-09-27 00:28:34 +02:00
ac-stef 196d47d34e limit max speed by consecutive doublejumps
Instead of applying 25% bonus speed with every executed doublejump (with
potentially unlimited top speed), limit the reachable max speed to 125%
of regular full speed.

This limits regular gameplay only marginally but removes a lot of cheat
potential.
2015-09-26 15:32:27 +02:00
ac-stef d75409a29c fix ladder physics
When both "forward" and "backward" keys are pressed, now the action
matches the last pressed one. Now the keys work on the ladder exactly
as with regular movement.
2015-09-26 11:34:47 +02:00
ac-stef 5006663d19 update VC project file
and add workaround for missing C99 type uint64_t in VC2008
2015-09-24 23:17:50 +02:00
ac-stef 917df65a51 remove all instances of round()
VS2008 doesn't have round() in math.h and the old inline function (removed
in 50d1413d, had problems in newer compilers). Now floor() or straight
casting to int is used. Let's see, which MS compiler will trip on that...
2015-09-24 19:51:50 +02:00
aurhat b06a5209e3 Add background to description of active menu items
DOCREF menuselectiondescbgcolor
2015-09-21 20:36:12 +02:00
aurhat fa047595b6 Add header to alternate views in serverbrowser
Also clean up SEARCH category.
2015-09-21 20:33:50 +02:00
aurhat cbddcf05cf Add searching for map and demo in menu
Searching is by map/demo names and descriptions (also custom descriptions,
in case of demo).

DOCREF menudirlist
2015-09-21 20:29:15 +02:00
aurhat 6268f5c118 Remove/adjust dependencies on Windows 2015-09-20 13:13:01 +02:00
aurhat 07ad1cedda Update xcode project - replace libcurl 2015-09-20 01:28:19 +02:00
Jani-Markus Maunusandac-stef d570eccd16 fixed missing include for Windows build 2015-09-19 15:43:43 +02:00
aurhat 6c99a9d2a3 Show "whois" info in one line 2015-09-18 21:27:16 +02:00
ac-stef 16565a2e05 allow package servers to be disabled or deleted
This is coded into the priority of a server:
* a priority of -1000 or lower marks a server as disabled
* a priority of -10000 or lower excludes a server from being saved to
  pcksources.cfg at program end, so a game restart will delete the server
  from the list
2015-09-17 16:41:05 +02:00
ac-stef 12a05d41e9 add interface for timedwait on semaphores
According to SDL documentation, the SDL implementation of timedwait may
suck on some platforms, so it should only be used, where high CPU usage
during the wait is no issue.

getpckserver() will now only wait for one second for access to the
package server list and return an error instead of waiting indefinitely.
2015-09-17 16:40:59 +02:00
ac-stef cbd0e7b4bc add timeout and manual abort to connect() 2015-09-15 13:18:03 +02:00
ac-stef ecc63d7047 more thread wrapper functions
Add code to detach threads without losing any ressources.
(use POSIX libs when SDL is not available)
2015-09-15 13:18:03 +02:00
ac-stef f6c161bcc5 add map export to format 9
Export to the map format of AC 1.2. Use with caution. Experimental.
2015-09-14 16:32:56 +02:00
ac-stef f424c95a7f allow the package server ping thread to take ages
Don't have the main thread wait for the ping thread, because the ping
thread may take a long time to respond - when a server connection can't
be established. Sadly, there's no timeout for "connect()".
2015-09-14 16:03:09 +02:00
ac-stef 5a4b605b33 fix flag drop position under water
Just placing the flag on top of the water didn't work for fully flooded
map areas, as the flag went out of reach.
This fix tries to float the flag up to the surface and stops, if something
blocks the way.
2015-09-14 13:57:55 +02:00
aurhat 7bba47a0dd Show on minimap indicative arrow at editing local player 2015-09-12 12:52:27 +02:00
ac-stef 532453b9f8 tweak command completion
If the fragment is also a full command, skip that command during the first
round of TAB completions.
2015-09-08 21:03:06 +02:00
ac-stef 396eae3ee0 fix #131
although I doubt, that anyone ever fell for that

(the fix prevents, that nickname completion can change the first char of
the console string to a slash, which would change the line from chat to
command)
2015-09-08 20:22:07 +02:00
aurhat 03a39feab8 Don't show players outside of map on minimap
When client connected to server (or started to play demo), where there was
a player dead since this client connecting, then position of the player
on minimap (and radar) was displayed wrongly outside of the map, sometimes
for the whole match. Now such positions will be hidden.
2015-09-08 15:09:24 +02:00
ac-stef 91753026dc fix enet issue #31
easier to fix the library than every use of the functions
2015-09-08 11:51:02 +02:00
aurhat 2fb111adf4 Fix wall clock with 12h format
Stock strftime doesn't use capitalized "P", so for example on Windows
the wall clock didn't appear for 12h format. PM and AM are converted
to lowercase.
2015-09-08 01:05:54 +02:00
aurhat b7643a5200 Remove obsolete dependency on wldap32
wldap32 was linked to removed libcurl, so it's unnecessary now.
2015-09-08 01:05:54 +02:00
ac-stef d86f6cc6ff rename ERROR macro
seems to be defined otherwise on windows
2015-09-07 22:34:35 +02:00
ac-stef 6c97202aa3 retry mapmodel downloads
Mapmodels which were not found once are put on a list and not tried to
be loaded again. With this commit, the list is cleared during a map load
if autodownload is enabled. This causes all missing models to be
downloaded.

Fixes issues with manually aborted autodownloads.
2015-09-07 14:53:57 +02:00
ac-stef 68c3ea43b1 improved http error handling
* don't treat 404 as http error
* real errors return -1 and disconnect
* -1 is treated as real error
2015-09-07 14:53:57 +02:00