1541 Commits
Author SHA1 Message Date
ac-stef 04e3d946bc updated automatic mapmodel menus 2015-05-17 00:24:39 +02:00
ac-stef 03f974b2bc additional text attributes for mapmodels
This adds a means to store additional attributes for mapmodels, including
a caching mechanism, so the mapmodels don't have to be loaded to access
the information. The goal is, to provide fully automatic mapmodel menus
for map editing who also add information about downloaded mapmodels.

Model attributes are extracted everytime, when a model is loaded. At game
end, all available data is written to config/mapmodelattributes.cfg and
restored at next startup. On release, a file with all (but only) official
models should be included. Since autodownloaded models are usually "loaded"
after download, those are automatically added to the database. If someone
adds models manually to the directories (media pack, w/e), the command
"loadallmapmodels" can be used to try to find all available models. The
only way to delete something from the database, is to delete the file
config/mapmodelattributes.cfg when the game is closed.

The current list of attributes is:

keywords
  List of one or more menu topics to list the model under. Check
  config/menus_edit.cfg for available keywords. Unknown keywords will
  be listed separately.

desc
  Short name or description of the model. Will be used as menu entry.

usage
  Important information for how to use that specific model.

author
  Who created the mapmodel. If it's a derivative of another model, state
  the author of the mod (refer to the original author under "license", if
  you like). Always use the exact same spelling for the same author, to
  allow menus to automatically group models by author.

license
  Free-text attribute for license info or info about additional
  contributors (or original authors for derivated works).

distribution
  One of "official", "autodownload" or "manual". Other values default to
  "manual". This is used to determine, if a map contains only original
  media or media that can be download automatically.

version
  Single numerical value to separate older from newer versions. Defaults
  to zero. Higher numbers mean "newer". Maybe someone manages to implement
  a versioning system for custom media in the future...

New commands:

mdlattribute <attr> <value>
  To be used in model config files. Adds a value for a specified
  attribute to the model.

mapmodelregister <modelpath> <attr1> <attr2> ...
  Adds values for all attributes to a specific mapmodel. This is used to
  restore the cached values from config/mapmodelattributes.cfg during
  game start. Does not actually verify of load the model.

mapmodelattributes <modelpath> <attr>
  Returns the value of a specific attribute of a mapmodel. If modelpath
  is a number, it is interpreted as index for the list of models in the
  current map config. If no attribute name is specified, all attributes
  are printed to the console instead.

getmapmodelattributes <list of attribute names>
  Returns a table of all known mapmodels. Each model is listed with the
  modelpath and the values for the requested attributes. To be used
  instead of a fixed table in menu_edit.cfg. In addition to attribute
  names, the function also allows the keywords "explodekeywords" and
  "sortby:" as arguments. If "explodekeywords" is given, all mapmodels
  with more than one keyword are listed multiple times, once for each
  keyword. If an attribute name is preceeded by "sortby:" the list will
  be sorted by this table column. If "sortby:" is used several times,
  this first sort will have highest priority. The list is always sorted
  by path by default.

  example:
    getmapmodelattributes sortby: author sortby: desc explodekeywords

loadallmapmodels
  Tries to load mapmodels from /all/ paths below packages/models/mapmodels.
  Will throw a lot of error messages, because not all directories contain
  models to load. This command can be used to build or rebuild the
  complete list of all available mapmodels. It is only necessary, if models
  are added manually to the directories, since every mapmodel gets added
  to the list when it is loaded - which takes care of all automatically
  downloaded models.

DOCREF mdlattribute mapmodelregister mapmodelattributes
DOCREF getmapmodelattributes loadallmapmodels
2015-05-17 00:24:38 +02:00
aurhat 1d497ac4d8 Add dedicated crosshair in edit mode
DOCREF loadcrosshair
2015-04-28 20:47:54 +02:00
Cmdr-Thrawnandaurhat 7e0b2be051 Changes to sound muting menus
* Fixed completely broken hitsound mute toggle
* Moved bullet sound toggles into appropriate menu
* Changed heartbeat toggle to use muteitem (for consistency)
* Fixed footsteps toggle (Previous behavior was to turn off all
footstep sounds, a toggle already existing elsewhere, rather
than muting the specific sound as it's intended to)
* Sorted sound menu (At grenadier's request)
2015-04-25 13:58:44 +02:00
cmdr_thrawnandaurhat 7fd5d19941 Update Game Mode Descriptions
* Added descriptions for modes 20 and 21
* Altered punctuation / whitespace for consistency
* Fixed grammar (you -> your)
2015-04-18 00:43:12 +02:00
Pascal de Bruijnandaurhat 76ec19b746 settings: allow edittoggle to be reconfigured
"editbind E edittoggle" is needed for such cases, when edittoggle will be
bounded to key, for which editbind exists. Then that will allow to
exit from edit mode still with use a key.
2015-04-15 20:36:01 +02:00
ac-stef 57a0d286c1 automatic mapmodel menus
auto-generate mapmodel menus depending on the actually available models
in the current map config.

Also fixes memory leak in "newmenu".

DOCREF mapmodelname mapmodelbyname mapmodelchanged
2015-04-12 18:09:36 +02:00
ac-stef f511889731 customisable sort order for file lists in menus 2015-04-12 18:09:36 +02:00
RandumKiwiandac-stef 5e8c64d8b7 Bind Q to change to previously selected weapon.
This will mirror the default bind in other FPS games and therefore
make AC easier to understand for unarmeds.
2015-04-12 18:06:09 +02:00
aurhat 1d1c9e6f96 Improve key binds
Changes:
1. added single aliases bounded to the keys, in order to maintain easier
the binds;
2. cleaned up binds;
3. updated Keyboard menu and fixed searching binds.
Remark: aliases bounded to the keys shouldn't have leading and trailing
white spaces, if they are present in Keyboard menu, otherwise they won't
be found. So construction like, for example: bind SLASH [ key_commandline ]
is inadmissible.
4. Alternate edit binds (default disabled) moved to
config/opt/alternateeditbinds.cfg and removed old_editbinds variable.

DOCREF old_editbinds
2015-04-03 23:44:22 +02:00
aurhat 5de86f9838 Cleanup
Fixed nested list in Cubescript, fixed conopen (now read-only), removed changeteam(),
fixed name of shortcuts for team survivor modes (so it fixes
https://github.com/assaultcube/AC/issues/73 ).

DOCREF ts tsurv btsurv
2015-03-29 14:57:29 +02:00
ac-stef 631685afb6 new commands curmenu and closecurmenu
curmenu gives back the name of the currently open menu, which can be used
to close just that.

The new script "closecurmenu" uses curmenu to close the current menu.

DOCREF curmenu closecurmenu
2015-03-29 13:21:47 +02:00
ac-stef 1e188aadbd fix loadcrosshair 2015-03-26 15:07:50 +01:00
cmdr_thrawnandac-stef 54ed91732e Show main menu when client starts
* added option in Misc settings
* default is: show menu
2015-03-24 02:48:47 +01:00
ac-stef 982bc037a7 moved "scripts" folder to "config/autostart"
All cfg-files in config/autostart get executed during startup.

- more appropriate directory name and place
- files are now sorted alphabetically, as promised
- doubles are removed (resulting from identical file names in home and
  install tree) since they would only result in files run twice
- scripts with file names prefixed with "_veryfirst_", "_beforesaved_"
  or "_aftersaved_" will be run as very first config file, right before
  saved.cfg or right after saved.cfg
- all remaining files will be run right before autoexec.cfg
- the directory "config/autostart" will be created, if it doesn't already
  exist in the home tree
2015-03-24 02:06:19 +01:00
ac-stef abdf080ae9 fix "grenades" script 2015-03-20 17:11:48 +01:00
aurhat d05ea601bd Rename fullscreenscript to fullscreentoggle
Commit adds also fullscreen setting to QUICK setup menu.

DOCREF fullscreentoggle
2015-03-08 21:22:39 +01:00
ac-stef 6cdb2f88e1 change scripts to use tempalias and push/pop
* no more need to delete aliases "onQuit"
* removed on_quit.cfg
* moved faq.cfg, parsestrings.cfg and survival.cfg to config/opt
* run faq.cfg and survival.cfg when needed

DOCREF addListOnQuit
2015-03-06 22:38:28 +01:00
ac-stef 32db3e5e88 new options for saved.cfg
Defaults to omitting variables from saved.cfg, that are still at default
value. By setting omitunchangeddefaults to zero, those variables get
written, but commented out. The variable "groupvariables" sets the number
of variables with similar names, that can be grouped on one line. Setting
it to zero will additionally write min, max and default values and a
short description of the variable to file.

In general, variables, that are still at default value, will not be
restored from saved.cfg, so when the default in the game is changed, all
clients will use that new default. This way, testers don't have to erase
their saved.cfg as often.

DOCREF omitunchangeddefaults groupvariables
2015-03-06 14:01:52 +01:00
ac-stef 8153813c14 fix string escaping for SVARs
* avoid double richtext conversion for mspmsg
* fix minor memleak in pushident()
* always escape strings for the command buffer
2015-02-23 20:12:47 +01:00
ac-stef 1956f0acc0 clean up loadcrosshair
* use the same list of gun names for all occasions
* switched syntax, so that argument completion will work
* support old syntax, so old config files will work
* fix path handling by disallowing paths altogether ;)

DOCREF loadcrosshair
2015-02-23 18:55:58 +01:00
ac-stef f75f0c0af4 add optional pre-access function for SVARs
allows a SVAR to be assembled when needed

also:

* mapmsg is now a SVAR
* getmapmsg was removed (now: $mapmsg)
* new editsvar script to edit any SVAR in the console buffer
* nonfunctional menu removed

DOCREF mapmsg getmapmsg editsvar
2015-02-23 18:52:34 +01:00
ac-stef 47f71f1288 allow symbolic arguments for some commands
* new command "listoptions" lists the argument options for several
  argument types like entities, weapons and teamnames
* "burstshots", "weapon", "magcontent", "magreserve", "fragmessage" and
  "gibmessage" now allow guns to be specified by name
* "addpunct" allows plaintext arguments like "brackets" and "quotes"
* the "team" command now understands numeric teams
* entity types can now be specified by type index number
* removed some lists from the config files (now provided by listoptions)
* added argument completion for several commands
* change nextprimary from integer to string variable

DOCREF listoptions burstshots weapon addpunct
DOCREF fragmessage gibmessage magcontent magreserve
DOCREF nextprimary
2015-02-23 18:52:04 +01:00
ac-stef 39cbee947d Merge branch 'master' into next 2015-02-08 16:17:04 +01:00
aurhat 779627cb94 Remove obsolete recorddemo/stopdemo from menu 2014-12-31 16:58:33 +01:00
aurhat aa127afbdd Cleanup maprot 2014-12-13 22:35:55 +01:00
aurhat fa483e1fcd Add custom description of demos
Custom description is displayed in "Watching demo" and "Play demo" menu.
2014-11-29 16:06:50 +01:00
ac-stef a957ae497e add entry for autodownload in misc settings menu 2014-11-26 21:50:29 +01:00
RandumKiwi ef8d03f4ab Fix for conver_mapconfig.sh: Allow spaces in filenames. 2014-11-17 09:56:36 +13:00
aurhat b6a5418c24 Add alternative views in serverbrowser and improve favourites
Alternative views in the serverbrowser are implemented with use favourites.
Categories (names) of favourite servers, which will be displayed on the
views, have to be included in "serverbrowseraltviews" alias (accessible
in menu).
Switching between views is possible with use Alt + Mouse wheel and
Alt + Up/Down (or eventually "[" and "]", if they are dedicated keys
on your keyboard).

The commit also:
1. adds MATCH category to favourites;
2. shows category name in settings of favourites;
3. shows weights in serverbrowser instead of favourites image,
when showweights = 1;
4. cleans up some tabs.
2014-11-11 21:07:19 +01:00
ac-stef e2ac8efadd remove restrictions on mapmodel rotation
Until now, the angles of mapmodels (and ctf-flags) were rounded to the
nearest 15-degree-step during rendering. This patch moves the rounding
to the time of placement of the model. Now the angle can be changed freely
after the model has been placed.

This commit also changes the angle resolution to 0.25 degree.

When changing the angle (press "1" + scrollwheel), additionally pressing
editmeta (a.k.a. LCTRL) changes the increments of the wheel from 1 to 10.

During a savemap with format 9, the angle resolution is reduced again, to
keep compatibility. Therefore, this features is only for testing right now.
It won't be preserved during a save (at least, as long as format 9 is used)
2014-10-22 12:08:42 +02:00
aurhat 931c442f67 Improve "favourite servers" feature
The commit:
1. does serverdescription keyword case insensitive for
showonlyfavourites > 0;
2. fixes typo in argument of alias in keyword;
3. fixes disabling background color for servers of the category, when
alpha is changed to 0;
4. shows 0 instead of 10 in info about digit, which toggles 10th category;
5. adds info about "image" attribute in favourites.cfg;
6. adds new feature: "Search for servers".
2014-10-04 20:25:44 +02:00
aurhat 05b902ba11 Show always all servers after forcing serverlist update 2014-10-04 20:25:43 +02:00
aurhat 533797f6e7 Don't show "connecting to $servername", if server doesn't have a name 2014-09-20 00:29:27 +02:00
ac-stef d8f39d821a allow kick/ban reasons to have up to 20 spaces without fuss 2014-08-02 12:41:30 +02:00
aurhatandac-stef d021909224 Restore old working quicknadethrow code and fix bug in it
This commit restores old working quicknadethrow code, which existed after
commit: https://github.com/assaultcube/AC/commit/aaeca4ef323f09d252498bcc66eb90d51aef4586
and keeps later bug fixes (which thought needed to be fixed).
It fixes https://github.com/assaultcube/AC/issues/25

It also fixes followed bug: after releasing right mouse button/G key
and quickly pressing it again, weapon, to which quicknadethrow switched,
starts to shoot.
2014-07-19 14:43:35 +02:00
aurhatandac-stef 79943778e7 Show list of demos in "Download demo" menu 2014-07-08 19:02:17 +02:00
aurhat 0898dfa384 Add list of standard resolutions to the settings in video menu 2014-06-19 13:52:31 +02:00
ac-stef aaf01e8b2a redo for the editor
an undo for undos :)
2014-05-15 13:48:31 +02:00
ac-stef 50b3f6867c show detailed data of the cube inside editing focus
* shows all geometry data of the cube in editing focus in the hud
* can be toggled by F8 in editmode
* shows cuby type, floor and ceiling heights, vdelta and all textures

(if mipstats *and* edit focus details are requested: show focus detail)
2014-05-15 13:48:30 +02:00
ac-stef ff8aea940d some edit fixes
* fixing edit paste
* fix power of 2 check for corner selection
* fix pasting multiple selections changed target selections
* fixing editdrag: plugging memory leak
* fixing editdrag: proper binding of keys
* fixing editdrag: allow deselecting (by selecting a second time)
* make a little more room for undos (RAM is cheap and maps are big)
* some cleanups
2014-05-15 11:42:54 +02:00
ac-stef eb60302e67 cleanup
- fix possible crash in conc (but it's still an ugly hack)
- fix noob usage of strcmp
- flag some memory leaks (it would be nice, if the author(s) would clean
   up the mess himself)
- fix crash in substr
- whitespace cleanup

there are plenty more memory leaks in command.cpp - for example, every
goto in cubescript does not clean up anything
2014-05-14 22:54:37 +02:00
aerkefiende 12a65543c1 Merge branch 'aniso' of github.com:pmjdebruijn/AC into pmjdebruijn-aniso 2014-04-08 21:13:19 +02:00
aerkefiende f5815f4277 Changing the interval to 5 health points in menuslider for heartbeat 2014-04-03 22:16:43 +02:00
Pascal de BruijnandPascal de Bruijn 9876a3f7f4 menus_settings: add anisotropic filtering 2014-03-28 18:40:24 +01:00
aurhat cf3d2692ad This commit adds simple fix to "changespeed" script.
It shouldn't work in multiplayer and when gamespeed is less than 10 and grather than 1000.
To test  bug type in multiplayer, for example: "/changespeed 1100 30" .
2014-02-14 22:57:43 +01:00
aurhat b672cea505 This commit fixes bug related to bot mode, when it is started from non-bot mode.
To see this bug just start AC, run bot team mode and watch:
- "enemies" menu instead of  "team enemies" menu,
- number of players less by 2 than should be.
2014-02-12 21:19:55 +01:00
aurhat b33b74c11c Fixed reference to "scopesens" in old "zoom" script, because it is a variable nowadays, and not command.
Bug is visible clearly after typing  "/zoom 1".
2014-02-11 21:33:53 +01:00
RandumKiwi 9197de052f Fix BASH vs KSH conflicts, by forcing user to use BASH. 2014-02-06 09:04:27 +13:00
ac-stef d258b7c186 less annoying visualisation for tagclips
- press B to get the former filled volume view
- raise the value of tagnumfull to get both views simultaneously
- cubescript parameters should be cleaned up before release
2014-01-30 19:38:41 +01:00