1
0
mirror of https://github.com/tobspr/shapez.io.git synced 2026-03-02 03:39:21 +00:00
Commit Graph

292 Commits

Author SHA1 Message Date
tobspr
a95e69401d Improve belt direction lock 2020-06-17 13:21:34 +02:00
tobspr
84969a9205 Refactor building placer 2020-06-17 13:12:39 +02:00
Phlosioneer
eb182d6e94 Fix lint issues 2020-06-16 22:48:29 -04:00
Phlosioneer
da24c472d7 Fix click and drag
Clicking and dragging can trigger up to 4 add/destroy signals, and it's
a common case.
2020-06-16 22:08:46 -04:00
Phlosioneer
aef96cff6e Optimize ejector cache for common case
This commit optimizes the ejector cache for clicking and dragging belts,
or adding/removing a building. It's a big performance improvement for
large maps; on average, it only has to visit 60 slots per update,
compared to 20,000+ slots.
2020-06-16 21:50:16 -04:00
Phlosioneer
36cf28029e Remove ejector cache; use slot caches instead
This is a small refactoring that removes the main ejector cache. The
cache is now tracked by slots and ejector components.

It avoids a large array allocation and many small object allocations,
but adds many small array allocations. It's net neutral for performance.
2020-06-16 21:11:26 -04:00
Phlosioneer
2341772425 Optimize belt cache for common case
Most of the time, we're adding/removing one building at a time. We don't
need to recheck every belt, only the ones near the changed belt.
2020-06-16 20:23:11 -04:00
Phlosioneer
8a50fdb392 Remove belt cache array; use BeltComponent instead
Removed the belt cache array. Follow-up belts are cached in the belt's
BeltComponent instead. This change also removes the recursive follow-up
search, which could cause a stack overflow for an extremely long belt
chain.

Saves one object allocation per belt per change, two very large array
allocations per change, many function calls, and belts are only visited
exactly once per change.
2020-06-16 19:56:09 -04:00
Phlosioneer
d4fc2e6dcd Fix lint errors 2020-06-16 16:21:45 -04:00
Phlosioneer
83a4928be5 Make miners cache mined item
Saves two chunk+tile lookups per update, and one chunk+tile lookup per
draw.
2020-06-16 16:02:29 -04:00
tobspr
736e5fb432 Fix crash 2020-06-16 20:13:46 +02:00
tobspr
31ab5f3422 Disable direction lock for everything but belts 2020-06-16 20:10:00 +02:00
tobspr
46ceefd0d8 Disable automatic orientation when using belt lock 2020-06-16 20:02:52 +02:00
tobspr
4fc1ff6b0d Improve belt lock 2020-06-16 19:45:16 +02:00
tobspr
35a13a09e5 Add belt lock feature 2020-06-16 19:40:00 +02:00
tobspr
b753187cde Add setting to disable smart tunnels 2020-06-16 19:24:23 +02:00
tobspr
b8c3668d88 Placing underground belts now removes belts and other (unneeded) tunnels inbetween 2020-06-16 13:19:53 +02:00
tobspr
1af564e816 Add mirrored painter variant 2020-06-16 11:57:17 +02:00
tobspr
fccb30b5a5 Fix dark mode for markers 2020-06-16 10:36:32 +02:00
tobspr
5c12c605f5 Reworked waypoints 2020-06-16 10:25:31 +02:00
tobspr
32d169b7db Bump fast pan speed from 2 to 4 2020-06-15 22:29:55 +02:00
tobspr
840ba60c76 Merge pull request #131 from jaysc/fastpan
added shift modifier for faster pan
2020-06-14 15:52:38 +02:00
Jaysc
5de2c2de94 Removed logic from application_settings 2020-06-14 14:16:37 +01:00
tobspr
cda24ceb04 Refactor item acceptor system for huge performance improvement 2020-06-14 14:37:13 +02:00
tobspr
e95b055e10 Minor improvements to belt performance 2020-06-14 14:20:35 +02:00
Jaysc
8a726f99b6 Changed fastpan to mapMoveFaster and translation 2020-06-13 14:14:35 +01:00
tobspr
6febaff100 Fix untranslated button 2020-06-13 13:22:20 +02:00
tobspr
7e745fd0ce Allow exporting whole bases, closes #137 2020-06-13 10:57:29 +02:00
Jaysc
487a99bb56 added fastpan feature 2020-06-12 18:55:35 +01:00
tobspr
63568ffb2c Merge pull request #112 from mini-bomba/move-speed
Added movement speed setting
2020-06-12 19:09:10 +02:00
tobspr
2f45e345fe Merge pull request #113 from hexagonhexagon/cut-paste-blueprints
Add cut, paste options for blueprints
2020-06-12 19:05:53 +02:00
tobspr
cc9813bf0c Merge pull request #74 from Dimava/extract/selection-world-relative
Make selection relative to world
2020-06-12 19:01:00 +02:00
tobspr
3af6532d32 Refactor pinned shapes and make them smart, closes #72 2020-06-12 18:38:13 +02:00
Dimava
7653c51e1b remove currentSelectionStart (use -World instead) 2020-06-12 15:49:31 +03:00
tobspr
8c01cc23d0 Fix watermark 2020-06-12 13:49:36 +02:00
tobspr
c037f23921 Localize watermark 2020-06-12 13:47:48 +02:00
tobspr
bd944ea758 Update german translation 2020-06-12 12:06:57 +02:00
tobspr
2c4d8e40fd Add korean translation 2020-06-12 10:38:16 +02:00
Cole Faust
eb16025598 Fix grammatical mistake in demo watermark 2020-06-12 00:26:15 -07:00
mini-bomba
107a3ef69c Added movement speed setting 2020-06-12 00:47:59 +02:00
hexagonhexagon
1091a7affd Merge branch 'master' into cut-paste-blueprints 2020-06-11 18:05:44 -04:00
hexagonhexagon
e39a868998 Add "Paste last blueprint" keybind. Last blueprint is not preserved on save/exit. 2020-06-11 17:56:13 -04:00
tobspr
15877f3040 German translations, minor improvements 2020-06-11 19:17:06 +02:00
Jaysc
6601923bd4 stop connection if something in the way 2020-06-11 16:33:25 +01:00
tobspr
c434f7a59f Multiple fixes (see changelog) 2020-06-11 11:51:24 +02:00
tobspr
1c717b0f37 Change hub texture and allow translating it, update stacker texture 2020-06-11 11:29:38 +02:00
tobspr
aa6bd04881 Fix some translations and backward compatibility 2020-06-11 11:06:28 +02:00
hexagonhexagon
f34813392f Add Cut keybind. 2020-06-11 03:33:00 -04:00
tobspr
84966573fa Fix copy paste error 2020-06-11 09:31:03 +02:00
tobspr
89f934024b Merge pull request #44 from hexagonhexagon/shop-ui-tweak
Make upgrade formatting more clear
2020-06-10 11:49:41 +02:00