Tamás Bálint Misius
c73fa1bcdd
Prevent almost all HTTP requests from blocking
...
The ones that remain blocking are the ones that run on different threads; see Task, yet another big mess to clean up.
2023-06-10 19:19:53 +02:00
Tamás Bálint Misius
7ef02a6c0b
Remove return value from Simulation::Load
...
Not useful anymore, it can only fail if the GameSave passed in is nullptr, which this commit guards against.
Also make Simulation::Load and Simulation::Save take block-oriented positions and rects.
2023-05-13 13:21:05 +02:00
Tamás Bálint Misius
9bd8bd2274
Fix some deprecation warnings
...
Namely:
- [[deprecated("Use Mat2")]]
- [[deprecated("Use Vec2")]]
- [[deprecated("Use Mat2::operator*(Vec2)")]]
- [[deprecated("Use Vec2<float>::operator*(float)")]]
- [[deprecated("Use Vec2::operator+")]]
- [[deprecated("Use Vec2::operator-")]]
- [[deprecated("Use Vec2::Zero")]]
- [[deprecated("Use Mat2::Identity")]]
2023-05-12 18:53:48 +02:00
Tamás Bálint Misius
0f95ce82f8
Sanitize GameSave/SaveInfo/SaveFile ownership
2023-05-11 12:40:23 +02:00
catsoften
a715f5d71a
Use RGB for constants and gradients, other misc changes
2023-04-16 22:13:39 +02:00
Tamás Bálint Misius
34e4d90dac
Properly seed rng at load time for saves that don't carry rng state
...
Also save rngState as a user object rather than two separate i64s.
2023-04-15 23:04:58 +02:00
Tamás Bálint Misius
a8604ef579
Add ensureDeterminism to saves
2023-04-15 22:19:54 +02:00
mniip
132e3508cf
Refactor tools
2023-04-05 14:11:37 +02:00
mniip
e93db9c06a
RasterDrawMethods CRTP, PlaneAdapters in VideoBuffer, Graphics, and Renderer
2023-04-05 02:29:35 +02:00
Tamás Bálint Misius
369dadf81e
Fix crash from new brush code when TPTMP is enabled
...
Okay yeah this is actually a well-camouflaged refactor.
2023-02-28 14:57:30 +01:00
mniip
ed8ec51f95
Copy brushes instead of making temporary changes to them
2023-02-22 09:58:03 +01:00
mniip
515df765e4
Clean up brush code
2023-02-22 09:58:03 +01:00
Tamás Bálint Misius
b9c8817386
Group gravity files into their own directory
...
Also replace non-FFT gravity with "no gravity"; fine for render.
2023-01-27 23:04:27 +01:00
Tamás Bálint Misius
159d0eb4b7
Group platform files into their own directory
2023-01-27 17:31:40 +01:00
Tamás Bálint Misius
a438584871
Only save custom GOL data if it changed
2023-01-27 09:27:32 +01:00
Tamás Bálint Misius
4f0c365e05
Preprocessor purge round 19: Split and minimize usage of Config.h
...
Also mostly banish it from other headers, and shuffle standard header includes to minimize cross-contamination between headers.
2023-01-27 09:27:32 +01:00
Tamás Bálint Misius
8680f0d4a7
Remove PATH_SEP, set PATH_SEP_CHAR in meson.build
2023-01-27 09:26:41 +01:00
Tamás Bálint Misius
afda2826bf
Refactor preferences
2023-01-27 09:26:41 +01:00
Tamás Bálint Misius
1f22e209f1
Localize Simulation::Before/AfterSim control to GameModel
2023-01-27 09:26:39 +01:00
xphere07
fe67ec8550
Add temperature scales option
...
Make the PROP tool default to the current temperature scale
Make the PROP tool's temp suffixes work in the console(This is currently blocked by AnyType doing resource management wrong)
Signed-off-by: xphere07 <xphere07@outlook.com>
2022-12-27 22:07:52 +09:00
Tamás Bálint Misius
ca93e69b19
UpdateParticles takes a range that is inclusive on both ends
2022-12-22 17:34:43 +01:00
Tamás Bálint Misius
5ae7755025
Fix the zoom window producing out of bounds coordinates
...
Also fixes sim.adjustCoords doing the same.
2022-12-18 09:05:55 +01:00
Tamás Bálint Misius
304cc3a47b
Move Read/WriteFile from Client to Platform
2022-10-05 19:55:04 +02:00
Tamás Bálint Misius
04e899e824
Use std::vector<char> consistently for file operations
...
This made it possible to get rid of two GameSave constructors.
Also clean up Client::LoadSaveFile, Client::ReadFile, and Client::WriteFile in the process, and remove unused SaveRenderer::Render
2022-09-08 06:45:25 +02:00
catsoften
6aa68adbf4
Add custom gravity mode and replace hardcoded gravity interactions ( #820 )
...
Co-authored-by: Tamás Bálint Misius <lbphacker@gmail.com>
2022-07-31 08:19:16 +02:00
xphere07
674134588c
Upgrade to C++17 ( #819 )
2021-12-13 14:41:02 +01:00
jacob1
44590d82e9
Add a few more Lua functions
...
sim.replaceModeFlags
sim.listCustomGol
sim.addCustomGol
sim.removeCustomGol
tpt.perfectCircleBrush
sim.floodDeco
2021-08-27 23:57:55 -04:00
Tamás Bálint Misius
eac92d1b04
Optimise undo history memory usage
...
By storing only the differences between Snapshots where possible.
NOTE: This may be reverted later if it causes too much trouble.
2021-08-04 17:19:15 +02:00
Tamás Bálint Misius
ea07244119
Refresh history code in GameMVC
2021-08-04 17:08:23 +02:00
Tamás Bálint Misius
c0e065cc76
Fix certain Lua APIs mangling integers
...
Also fix a few warnings.
2021-07-18 20:33:50 +02:00
jacob1
05f722b397
Fix custom brush loading
2021-07-11 16:48:05 -04:00
jacob1
d1016cf58d
move Platform.cpp to common/, seems to fit in a little better there
2021-06-26 00:58:37 -04:00
jacob1
6e0ace2e4d
Add / move some filesystem methods to Platform.cpp
2021-06-26 00:58:37 -04:00
Tamás Bálint Misius
ffe730c615
Save ambient heat temperature and add it to options
2021-06-04 22:39:07 +02:00
Tamás Bálint Misius
dfc8dc80bd
Write prefs every time they change ( fixes #770 )
2021-04-18 12:23:31 +02:00
Tamás Bálint Misius
4b7e85c2fb
Fix a metric ton of MSVC warnings
2021-02-15 21:24:44 +01:00
Tamás Bálint Misius
ba72dc7a22
Custom GOL ( #731 )
...
Co-authored-by: jacob1 <jfu614@gmail.com>
2020-10-08 20:23:59 +02:00
jacob1
899a2a046c
Add ctrl+u shortcut to reset ambient heat
2020-04-27 23:20:54 -04:00
jacob1
1e23269dd4
Add "perfect circle brush" option (on by default), to allow using old circle brush
2020-02-03 00:20:46 -05:00
Tamás Bálint Misius
4d52531889
Ditch element and tool classes
2020-01-09 19:22:11 +01:00
Tamás Bálint Misius
a6127bc1fb
Add Lua API for deco tool colour space, see 51e5f2b
2019-09-21 21:58:50 +02:00
Tamás Bálint Misius
51e5f2bffa
Add option to make deco tools use sRGB colour space
...
Currently only affects the smudge tool. I'd have to look
into the others to decide if they need chaging. They probably
do though, they're not exactly intuitive.
I also fixed a bug with DropDowns where their popup would
show up in some random place if the parent window was a
ScrollPanel, and changed a few alignments here and there.
Notably, DropDowns now align the popup so that the currently
selected item is vertically centered and doesn't move when
the popup is opened.
2019-09-21 21:37:34 +02:00
jacob1
e280fea031
arbitrary gravity code cleanup
...
Was working on modernizing the code in my mod, copied all the changes here too
2019-08-05 00:08:06 -04:00
Tamás Bálint Misius
dbd5999d1c
Reinstate inversion of inclusion of pressure when shift is held
...
This feature was removed temporarily in a407aba
.
Whether pressure is included when saving or loading is
determined as follows:
* load-like operations (which invoke Simulation::Load) always
include pressure;
* save-like operations (which invoke Simulation::Save) include
pressure if the Simulation.IncludePressure preference node
is true;
* finally the state of the shift key inverts the decision.
2019-07-16 19:43:52 +02:00
Tamás Bálint Misius
a407aba087
Make Simulation.IncludePressure pref node accessible from OptionsView
...
Also remove ugly and messy behaviour depending on whether
shift is being held while copying or stamping.
2019-07-10 00:35:49 +02:00
yarek
bc5fd4ffc8
Small UI refactor
...
nFixed category refreshing
2019-07-06 09:03:07 +02:00
yareky
5508f0ccfd
Allows to change menu selection from hovering to mouse click
...
New option in the menu available. This new menu behaviour is disabled by default.
2019-07-06 09:03:07 +02:00
Tamás Bálint Misius
8897c6daea
Make elem.free rebuild menus ( fixes #649 )
...
Also make sure removed elements don't stay selected.
2019-06-11 21:12:22 +02:00
Tamás Bálint Misius
0179cefc78
Flatten include trees
2019-04-20 15:36:11 +02:00
jacob1
2e17b848b1
Make element names a String (unicode support)
...
This won't be used by official elements, but mods or lua scripts could and do use unicode
2019-03-12 00:10:43 -04:00