5444 Commits

Author SHA1 Message Date
UnknownShadow200
e221e9f343 Bitmap shouldn't be typedefed 2020-08-01 12:19:58 +10:00
UnknownShadow200
f2cfdb372d Define custom model parts as they arrive, instead of buffering them all into memory first
For 64 bit, reduces size of custom_models array from 802 to 465 kilobytes
2020-08-01 11:07:48 +10:00
UnknownShadow200
4cf4db4607 Simplify DefineModelPart packet reading 2020-08-01 09:33:45 +10:00
UnknownShadow200
2c191a847b Scale up launcher title with DPI, make it have correct Y offset when drawing it as bitmapped text 2020-07-31 21:09:51 +10:00
UnknownShadow200
8e0dc6db08 Fix some textures persisting from old texture pack on server software that only sends packet with new url, and doesn't send an additional packet with empty url first (Thanks Goodly) 2020-07-31 16:55:13 +10:00
UnknownShadow200
4534e647e9 For auto join server hash, also try to automatically sign in the user too 2020-07-31 12:07:24 +10:00
UnknownShadow200
0da489e82a fix very rare case where launcher process wouldn't terminate after closing the window 2020-07-31 11:46:33 +10:00
UnknownShadow200
fbbe626a97 Fix launcher flags offset and input widget expand at high DPI
Also avoid double checking file existence when extracting launcher texture pack
2020-07-30 23:06:43 +10:00
UnknownShadow200
559ae5ceac Mostly make launcher servers table DPI scale 2020-07-30 22:44:27 +10:00
UnknownShadow200
fdf92e047b Launcher input widget DPI scales properly 2020-07-30 13:20:33 +10:00
UnknownShadow200
7e7bfb00da fix always crashing on close 2020-07-29 18:17:41 +10:00
UnknownShadow200
4dc05d82f5 Change Launcher screen MakeInstance methods to call SetScreen directly instead of returning pointer 2020-07-29 18:01:39 +10:00
UnknownShadow200
5bf63e79a3 Use single Event_Register_ macro instead of Event_Register_XYZ macros
The Event_Register_XYZ were all just defined to Event_Register_Macro anyway, completely ignoring the type of the arguments given. Therefore it's better to just give a single type unsafe Event_Register_ macro, rather than misleading the user into thinking they were using type safe macros
2020-07-29 17:45:59 +10:00
UnknownShadow200
fd28ce7b27 Add single Event_UnregisterAll method, instead of having code everywhere calling Event_UnregisterXYZ 2020-07-29 11:48:30 +10:00
UnknownShadow200
9afde7d0aa .. and fix 'position:' textatlas leaking. Finally no more crashing. 2020-07-28 19:45:21 +10:00
UnknownShadow200
4deba8e0d4 Fix index buffer leaking if direct3d9 device creation initially failed
Still crashes, but progress at least
2020-07-28 18:59:53 +10:00
UnknownShadow200
386ce44cc8 Fix android makefile to compile, add readme for doc/misc folder 2020-07-27 22:09:37 +10:00
UnknownShadow200
aa85374894 If an attempt is made to extract texture pack while context is lost, add code to reload texture pack when context is recreated
The most noticable way this issue manifests is when you try to start the game (direct3d9) while a fullscreen application is already running. This causes creating the device to initially fail, but when the context is later recreated (because you toggled out of the fullscreen application), all the textures would appear white because the initial texture pack had attempted to load while context was initially lost.

Of course, the game still crashes when you try to resize the window next (or something else that causes context to get lost), but progress still.
2020-07-27 20:38:41 +10:00
UnknownShadow200
593b581465 If user's custom default texture zip is missing, still show error in chat instead of just silently falling back to default.zip 2020-07-27 19:08:48 +10:00
UnknownShadow200
1db73db9f2 fix web client 2020-07-27 18:35:57 +10:00
UnknownShadow200
8bcbad56f6 Consistently use OnInit/OnFree/OnReset everywhere 2020-07-27 18:32:01 +10:00
UnknownShadow200
b60cfbb856 Fix wrong textures sometimes if you change server's textures and you are using custom default textures
Previously, if you changed server's textures, textures that were not in new textures and were not in custom default textures would retain their texture from the server's old textures, instead of reverting to default.zip.

Now default.zip will always be reloaded too when you have a custom default texture pack. This does make it a little bit slower, but default.zip is simple anyways and always loading it should not really be noticable. (even on my laptop, averages ~40 ms)
2020-07-27 18:14:12 +10:00
UnknownShadow200
5c665ee067 Simplify texture pack loading code, make png/zip detection consistent 2020-07-27 16:59:52 +10:00
UnknownShadow200
56b2986e41 Condense plugin loading failure messages a little bit 2020-07-27 00:07:58 +10:00
UnknownShadow200
149fe29c23 Enforce third person camera clipping when -noclip is in motd (thanks goodly) 2020-07-26 12:50:44 +10:00
UnknownShadow200
d90b06e6a8 minor code cleanup 2020-07-24 19:36:03 +10:00
UnknownShadow200
586e7c4830 Fix when using cmd+c/cmd+v on 32 bit mac, 'c' and 'v' characters are still appended to text input
This commit makes all key character input ignored while command key is pressed
2020-07-24 12:10:37 +10:00
UnknownShadow200
3b1b13eb22 Add support for RISCV register dumping on linux 2020-07-23 23:26:51 +10:00
UnknownShadow200
65ee8fe655 Cleanup options code, simplify css on example classisphere website 2020-07-23 09:07:39 +10:00
UnknownShadow200
f55a55b3c6 Simplify options saving/loading code 2020-07-22 19:19:46 +10:00
UnknownShadow200
a0f4171209 Attempt to fix rare 'options.txt already in use' errors when using direct connect and auto close launcher (Thanks SpiralP) 2020-07-22 16:51:00 +10:00
UnknownShadow200
23c8e49280 Export NetPlayer_Init per request 2020-07-22 15:33:30 +10:00
UnknownShadow200
9d31c74d5d Don't use Game_UpdateDimensions when calculating launcher framebuffer dimensions
The launcher part should be depending on as little of the core game code as possible
2020-07-21 22:39:03 +10:00
UnknownShadow200
ae88643304 Launcher: Scale button borders (and other borders) by DPI 2020-07-21 22:28:29 +10:00
UnknownShadow200
cfd606317f Open source release packaging part of buildbot 2020-07-21 14:46:03 +10:00
UnknownShadow200
81bbc6d3a7 Less warnings compiling web client 2020-07-20 21:41:35 +10:00
UnknownShadow200
b707fef2c8 Fix in launcher if you clicked Updates -> Any button to download before update checking had actually finished, it wouldn't do anything.
This was particularly annoying, because the update checker usually finishes very quickly. So the first time you clicked the button, it didn't do anything, but the next time you clicked the button, it would actually start downloading.
2020-07-19 12:14:50 +10:00
UnknownShadow200
6b8cff6111 Properly detect mac < 10.4 and use NS api instead. Therefore 10.3 is now minimum supported macOS version 2020-07-19 00:30:32 +10:00
UnknownShadow200
40971873a6 Cleanup debug logging messages
Remove launcher web task logging, simplify http logging messages
2020-07-18 13:21:10 +10:00
UnknownShadow200
f1522b9fc9 Split up LScreen Init methods into Init/Show methods (since this was what all the screens were doing anyways) 2020-07-18 12:53:46 +10:00
UnknownShadow200
1a7c4a24f7 I am altering the API. Pray I don't alter it any further.
Readd obsolete Dynamic_Get/Load because some plugins depend on it
2020-07-17 20:07:19 +10:00
UnknownShadow200
79a22ff18c Use simpler GLContext_GetAll for loading OpenGL 1.5/1.2 functions 2020-07-17 17:18:51 +10:00
UnknownShadow200
188ea885ee Also make libcurl dynamic loading use new DynamicLib_GetAll 2020-07-17 12:32:47 +10:00
UnknownShadow200
f5095d4389 Add simpler DynamicLib_GetAll interface 2020-07-17 12:24:33 +10:00
UnknownShadow200
1ee9e86502 When disconnecting from server due to invalid opcode, also include opcode of last valid packet in message 2020-07-15 19:11:48 +10:00
UnknownShadow200
a819ca770f Don't crash if out of memory when allocating samples for writing .wav file 2020-07-14 21:48:30 +10:00
UnknownShadow200
d403ba6659 Show slightly more user friendly decimal instead of hexadecimal error number (Thanks MasterMen) 2020-07-14 21:15:07 +10:00
UnknownShadow200
b9ef7fbe70 Keep data length local instead of relying on file length when writing out .wav sounds 2020-07-14 19:40:41 +10:00
UnknownShadow200
d7299b12fd Change message from 'using nolimit mode is discouraged' to 'nolimit mode is pointless - it wastefully renders frames that you don't even see'
tired of people telling others that they should be playing in nolimit mode
2020-07-14 11:37:25 +10:00
UnknownShadow200
24e37d0658 Reduce glVertexAttribPointer calls to improve performance in
web client when low performance is due to gl call overhead.

Examples of FPS differences:
-- CR 83/FF 78/IE 11 (Win7 desktop nvidia, 512 viewdist)
-------------------------------------------------------
NA2 FB :  60->60,   38->47,   25->39
PR main:  90->100,  60->76,   42->70
TGA FB :  60->80,   49->62,   35->56
NB  FB :  60->60,   44->47,   32->37
Au70 FB: 140->167,  72->92,   60->99
Lag map:  30->60,   25->40,   15->30
CR  FB : 160->162, 100->108, 112->124
Fltgras: 200->200, 185->185, 310->320

-- CR 83/IE 11 (Win 7 laptop intel, 256 viewdist)
NA2 FB :  40-70 ->  50-80 ,  14->24
PR main:  25-35 ->  25-40 ,  22->27
TGA FB :  20-30 ->  20-40 ,  18->22
NB  FB :  40-50 ->  40-80 ,  17->55
Au70 FB:  30-70 ->  40-80 ,  20->35
Lag map:  20-30 ->  30-60 ,  10->20
CR FB  :  70-120->  70-130,  30->45
Fltgras: 150-170-> 150-170,  66->66

-- CR/FF mobile (Android, 128 viewdist)
PR main:  16->17,    8->  8
TGA FB :  50->60,   20-> 22
Au70 FB:  70->80,   30-> 30
Lag map:  17->23,    8-> 11
Fltgras: 150->150,  57->60

So to the best of my knowledge, there are no performance regressions.
Raspberry pi/android should also improve a little bit, but untested.
(benefit will be less as GLES calls are much cheaper compared to WebGL calls)

These measurements should be looked at as relative percent improvements, not
as absolute FPS comparisons. I did not try to properly benchmark here -
especially for the laptop, where FPS wildly varied. All these are averages.
2020-07-13 23:30:55 +10:00