Commit Graph

49 Commits (jgrpp)

Author SHA1 Message Date
Jonathan G Rennison d09b504bc5 Merge branch 'master' into jgrpp
# Conflicts:
#	.github/workflows/ci-build.yml
#	.github/workflows/release-linux.yml
#	.github/workflows/release-macos.yml
#	.github/workflows/release-source.yml
#	.github/workflows/release.yml
#	CMakeLists.txt
#	COMPILING.md
#	src/ai/ai_core.cpp
#	src/ai/ai_gui.cpp
#	src/bridge_gui.cpp
#	src/company_gui.cpp
#	src/console_cmds.cpp
#	src/core/CMakeLists.txt
#	src/core/smallmap_type.hpp
#	src/disaster_vehicle.h
#	src/effectvehicle_base.h
#	src/fontcache.cpp
#	src/game/game_core.cpp
#	src/game/game_gui.cpp
#	src/gamelog.cpp
#	src/gamelog_internal.h
#	src/group_gui.cpp
#	src/linkgraph/linkgraph.h
#	src/misc.cpp
#	src/network/core/config.h
#	src/network/core/udp.cpp
#	src/network/network_chat_gui.cpp
#	src/network/network_content_gui.cpp
#	src/network/network_gui.cpp
#	src/newgrf.cpp
#	src/newgrf_gui.cpp
#	src/newgrf_profiling.cpp
#	src/newgrf_profiling.h
#	src/object_gui.cpp
#	src/openttd.cpp
#	src/openttd.h
#	src/order_gui.cpp
#	src/os/windows/font_win32.cpp
#	src/rail_gui.cpp
#	src/road.cpp
#	src/road_gui.cpp
#	src/saveload/afterload.cpp
#	src/saveload/saveload.h
#	src/script/api/script_controller.cpp
#	src/script/api/script_roadtypelist.cpp
#	src/script/script_config.cpp
#	src/script/script_config.hpp
#	src/script/script_instance.cpp
#	src/script/script_scanner.cpp
#	src/script/squirrel.cpp
#	src/script/squirrel_helper.hpp
#	src/settings_gui.cpp
#	src/settings_internal.h
#	src/settings_type.h
#	src/table/settings/network_private_settings.ini
#	src/timetable_gui.cpp
#	src/vehicle.cpp
#	src/vehicle_base.h
#	src/window_gui.h
11 months ago
Jonathan G Rennison fd4d4d341d Merge branch 'master' into jgrpp
# Conflicts:
#	src/animated_tile.cpp
#	src/cargopacket.h
#	src/cheat_gui.cpp
#	src/company_cmd.cpp
#	src/company_gui.cpp
#	src/date.cpp
#	src/disaster_vehicle.cpp
#	src/dock_gui.cpp
#	src/economy.cpp
#	src/engine.cpp
#	src/error_gui.cpp
#	src/fontcache/spritefontcache.cpp
#	src/game/game_gui.cpp
#	src/game/game_text.cpp
#	src/gfx.cpp
#	src/graph_gui.cpp
#	src/highscore_gui.cpp
#	src/industry_cmd.cpp
#	src/lang/dutch.txt
#	src/lang/english_AU.txt
#	src/lang/english_US.txt
#	src/lang/finnish.txt
#	src/lang/french.txt
#	src/lang/italian.txt
#	src/lang/portuguese.txt
#	src/lang/russian.txt
#	src/lang/turkish.txt
#	src/lang/vietnamese.txt
#	src/main_gui.cpp
#	src/misc_gui.cpp
#	src/network/network_gui.cpp
#	src/network/network_server.cpp
#	src/newgrf.cpp
#	src/newgrf.h
#	src/newgrf_generic.cpp
#	src/news_gui.cpp
#	src/openttd.cpp
#	src/os/unix/unix.cpp
#	src/os/windows/font_win32.cpp
#	src/os/windows/win32.cpp
#	src/rail_gui.cpp
#	src/road_gui.cpp
#	src/saveload/afterload.cpp
#	src/saveload/misc_sl.cpp
#	src/saveload/oldloader_sl.cpp
#	src/saveload/saveload.cpp
#	src/saveload/saveload.h
#	src/script/script_gui.cpp
#	src/settings_table.cpp
#	src/signs_gui.cpp
#	src/smallmap_gui.cpp
#	src/smallmap_gui.h
#	src/spritecache.cpp
#	src/spritecache.h
#	src/spriteloader/grf.cpp
#	src/station_cmd.cpp
#	src/statusbar_gui.cpp
#	src/stdafx.h
#	src/strgen/strgen_base.cpp
#	src/subsidy.cpp
#	src/table/settings/difficulty_settings.ini
#	src/texteff.cpp
#	src/timetable_cmd.cpp
#	src/timetable_gui.cpp
#	src/toolbar_gui.cpp
#	src/town_cmd.cpp
#	src/town_gui.cpp
#	src/townname.cpp
#	src/vehicle.cpp
#	src/waypoint_cmd.cpp
#	src/widgets/dropdown.cpp
#	src/window.cpp
1 year ago
Rubidium b1b578f988 Cleanup: stredup-ing string variant for calling scripts 1 year ago
Rubidium ab51175db2 Codechange: use std::string for script config 1 year ago
Rubidium e035705239 Codechange: introduce and use std::string variant of sq_throwerror 1 year ago
Rubidium a30f7c83bd Codechange: use std::string for script names to load 1 year ago
Rubidium 9b0123ab66 Codechange: use std::string for script API versions 1 year ago
Rubidium 3d8d99ba11 Add: method to call script functions with std::string 1 year ago
Rubidium 8b93e45e22 Codechange: use string/fmt instead of printf for squirrel's PRINTFUNC 1 year ago
PeterN e97bf271dc
Codechange: Make SpriteType, CargoSortType, SourceType and ScriptType enum classes. (#10663)
This avoids a (soft) namespace conflict between the four ST_* enums.
1 year ago
Jonathan G Rennison 62afd94b47 Merge branch 'master' into jgrpp-beta
# Conflicts:
#	src/company_cmd.cpp
#	src/economy.cpp
#	src/lang/swedish.txt
#	src/network/network_command.cpp
#	src/news_gui.cpp
#	src/saveload/saveload.h
#	src/script/api/script_list.cpp
#	src/video/cocoa/cocoa_v.mm
#	src/video/sdl2_v.cpp
3 years ago
Rubidium 3237e97b35 Cleanup: [Script] Use nullptr instead of 0 or NULL 3 years ago
Jonathan G Rennison 45386efcd0 Script: Allow changing ops limit and memory limit settings in game 4 years ago
Charles Pigott 64b1c70fdd Codechange: Add WARN_FORMAT to vseprintf and fix the cascade of warnings that followed 4 years ago
S. D. Cloudt 13cc8a0cee Cleanup: Removed SVN headers 5 years ago
Niels Martin Hansen 140a96b3a0 Change: Limit memory allocations for each Squirrel instance
This can avoid out-of-memory situations due to single scripts using up the entire address space.
Instead, scripts that go above the maximum are killed.
The maximum is default 1 GB per script, but can be configured by a setting.
5 years ago
Henry Wilson 7c8e7c6b6e Codechange: Use null pointer literal instead of the NULL macro 5 years ago
rubidium 7c4e9dd71d (svn r26771) -Cleanup: remove OTTD2SQ and SQ2OTTD 10 years ago
rubidium a6b4e59963 (svn r26617) -Fix [FS#5973]: [Script] Loading/parsing of info .nuts was done in the same VM, causing e.g. constants to break the loading of info of other scripts 10 years ago
truebrain 12aa5b6a58 (svn r23604) -Add: initial support for GameScripts 13 years ago
truebrain 3e6d026129 (svn r23366) -Codechange: move most of the Dummy code to script/, unifying it 13 years ago
truebrain e37149a1de (svn r23362) -Codechange: refactor AIScanner, splitting it in AIScannerInfo and AIScannerLibrary 13 years ago
truebrain 3da8b5097a (svn r23360) -Codechange: move AIInstance to ScriptInstance, making it reusable by other script API instances 13 years ago
truebrain 98103121d4 (svn r23355) -Codechange: rename all AI* to Script* (Rubidium) 13 years ago
truebrain 00877dd6d3 (svn r23352) -Add: support dynamically adding an API prefix when returning a C++ class to Squirrel 13 years ago
truebrain bff7c33aa9 (svn r23350) -Add: support different ScriptTypes in the helper functions for GetClassName (Rubidium) 13 years ago
truebrain d03bbdd4ac (svn r23295) -Codechange: put ImportLibrary in AIController (and document the parameters for NoAI docs) 13 years ago
truebrain 54ec3a2a3f (svn r23293) -Codechange: make LoadScript/LoadFile non-static 13 years ago
truebrain 32b28bb868 (svn r23264) -Fix (r23263): save before commit 13 years ago
rubidium 65d0d19b16 (svn r23118) -Feature: [NoAI] Allow AIs to query the amount of remaining operations for the current tick 13 years ago
rubidium e9fe58d7bf (svn r22120) -Change: [NoAI] Prevent AIs from getting consistently over their allowed amount of operations by subtracting the amount they went over "budget" from the budget for the next "tick". 13 years ago
rubidium 090d6fb8b7 (svn r21311) -Fix [FS#4260]: AIs in an infinite loop in e.g. autosave, but also getting settings and such from info.nut, would not be interrupted after a while causing OpenTTD to seem to not respond 14 years ago
rubidium 30f2afac9b (svn r20632) -Cleanup: remove "a few" unneeded includes, and add them to some headers 14 years ago
rubidium 1fa98e1695 (svn r20574) -Codechange: a little over 1 million vehicles should be enough for the forseeable future 14 years ago
rubidium b1bd106703 (svn r18862) -Fix [FS#3544]: don't pass AI strings through iconv 15 years ago
rubidium e8ddf001c8 (svn r17570) -Fix: a number of Doxygen warnings about missing parameters, which were sometimes missing and sometimes just typos 15 years ago
yexo ca6c4ee98a (svn r17498) -Add [NoAI]: Enable the squirrel std math library 15 years ago
rubidium 7fbc33dae1 (svn r17248) -Fix: add GPL license notice where appropriate 15 years ago
yexo a4afa140f3 (svn r17223) -Change [NoAI] [FS#2980]: Crash an AI when it uses a DoCommand / Sleep instead of just printing an error message in the AI Debug Window 15 years ago
yexo c2ed884012 (svn r17005) -Add [NoAI]: AIAbstractList::SORT_ASCENDING / SORT_DESCENDING 15 years ago
yexo f085d7775b (svn r16834) -Fix [FS#3034]: call the AI Save() function only once so AIs can't crash OpenTTD 15 years ago
yexo 4ea3e511bd (svn r16502) -Fix [FS#2935]: when an AI was suspended while in a function called (indirectly) via call/acall/pcall OpenTTD crashed. Fix this by disallowing AIs to be suspended while called via call/acall/pcall.
IMPORTANT FOR AI WRITERS: AIs can no longer call any DoCommand functions (change anything, build vehicles, etc.) in a function called (indirectly) via call/acall/pcall. Where possible, please rewrite your code so it doesn't use call/acall/pcall
15 years ago
yexo 3949050714 (svn r16113) -Feature [NoAI]: Add UseAsRandomAI as function in info.nut. When an AI returns false, it'll never be chosen as random AI. 15 years ago
yexo cabfe35e54 (svn r15558) -Cleanup: Remove some unnecessary friend declarations. 16 years ago
yexo 8e14d77d05 (svn r15467) -Fix [NoAI]: AIs with an error in their info.nut are no longer available in-game. 16 years ago
rubidium e1b1fd18b5 (svn r15406) -Fix: make Valuate actually cost a few opcodes to not make it a single opcode method of doing lots of the same thing. This should resolve most of the hiccups caused by AIs. 16 years ago
rubidium 1c30c8c801 (svn r15330) -Fix [FS#2597]: leaking of Squirrel when using circular references (by enabling the GC). 16 years ago
truebrain bcbbf2c366 (svn r15045) -Add [NoAI API CHANGE]: in info.nut you can now have (optional) a CanLoadFromVersion(version), which should return true/false, to indicate if you can load a savegame made with your AI of version 'version'
-Add [NoAI API CHANGE]: in main.nut the Load() function now should be Load(version, data), where 'version' is the version of your AI which made the savegame
-Codechange [NoAI]: various of function renames to make things more sane
-Add [NoAI]: push the 'version' of the AI through various of layers
-Codechange [NoAI]: various of code cleanups
-Add [NoAI]: store the version of the AI in the savegame too
16 years ago
truebrain a3dd7506d3 (svn r15027) -Merge: tomatos and bananas left to be, here is NoAI for all to see.
NoAI is an API (a framework) to build your own AIs in. See:
   http://wiki.openttd.org/wiki/index.php/AI:Main_Page
 With many thanks to:
  - glx and Rubidium for their syncing, feedback and hard work
  - Yexo for his feedback, patches, and AIs which tested the system very deep
  - Morloth for his feedback and patches
  - TJIP for hosting a challenge which kept NoAI on track
  - All AI authors for testing our AI API, and all other people who helped in one way or another
-Remove: all old AIs and their cheats/hacks
16 years ago