Commit graph

48 commits

Author SHA1 Message Date
turleypol
21577d8e5b
Clang Tidy concat namespaces (#855)
* tidy

* Automated clang-tidy change: modernize-concat-nested-namespaces

* compile test

* fix namespace

---------

Co-authored-by: Clang Tidy <clang-tidy@users.noreply.github.com>
2026-01-17 10:30:21 +01:00
turleypol
c588c51a33
Expansion helper classes for central handling of features (#756)
* use uoexpansion enums for A9, B9 flags
added TOL to uoexpansion
currently unsure where this will end

simplified account initialisation, added errorcheck

* Expansion classes for server and account
fixed flags

* use of AccountExpansion,ServerExpansion
extended tests
splitted unittest file
added missing test for Min/MaxAttackRange

* more micro performance for world saving
use all 4 cores in CI builds
fix compiler flag warning on windows

* save test for weight_multiplier

* enable gothic,rustictiles when using HSA expansion

* removed ancient unused files

* addressed comments
renamed ServerExpansion to ServerFeatures
added method for expansion name

* got rid of client UOExpansionFlag which is the same as the accout
expansion

* updated core-changes and docs

* updated generated ssopt

* test for tooltips
changed method names
removed/clarified comments

* npc hitchance was never saved
added missing npc save tests

* hitchance bug exists also for items...
added missing test for movemode
2025-02-05 19:02:25 +01:00
turleypol
d873551c25
removed pol_distance/inrange* functions (#556)
* removed pol_distance/inrange* functions
replaced lastxyz with Pos4d

* replaced WorldIterator::InVisualRange with InMaxVisualRange returning
all objects in maximum update range. Adapted each caller, they now have
to check in_visual_range
Multis should now be send to clients with its footprint in mind.
added testscript for boat moving in/out of range

* removed non pos InRange/InBox functions
gamestate.update_range doesnt need to be a Vector, renamed

* corrected send_action_to_inrange

* replaced clip methods with general numeric type clamp function

* added Range2d constructor with radius

* splitted update_range. chr has now a los_size (how far can it see) and
an object has a visible_size (0 for objects 1/2 footprint for multis)

* use in_range instead of pol_distance

* corrected order of checks

* fixed warnings

* fixed visual size of multis
testclient added wornitems pkt support
added tests for los

* corechanges
2023-12-25 22:02:52 +01:00
turleypol
bab7433e37 Allow newline and tabs for strings again
Found one oldschool utf16 pkt write
2020-01-04 12:35:04 +01:00
turleypol
cec9460708 removed duplicate nullterm for tooltips 2019-09-01 22:30:10 +02:00
turleypol
0859c84eac guessing tooltips and gump packets
use newer ninja for travis
2019-08-17 17:26:55 +02:00
turleypol
9cfb4ec5a5 moved pkt headers into network folder 2018-12-30 21:35:54 +01:00
esdete
dc2d29b433 NULL to nullptr 2018-07-31 14:30:29 +02:00
turleypol
dbb25bdb62
Include and buildsystem cleanup (#45)
Include cleanup
Reworked buildsystem (Linux only)
Removed dynamic libs, Linux now again uses static linking (like windows)
2018-01-29 21:55:48 +01:00
turleypol
798eda5b63 Cleanup of header includes. 2018-01-01 21:52:14 +01:00
turley
c855a27815 Added new baseclass for uobject
contains only minimum data and can be created with arbritary data.
This reduces memory overhead for each los-check.
Plus minor cleanup
2016-12-12 22:21:59 +01:00
turley
189cad3479 Formating everything
Authors are not forced to use the clang-format setting, but should
atleast be inspired by the style.
The only thing which is now not allowed are tabs for ident/alignment!
2016-02-19 19:26:35 +01:00
turley
ed7b16b233 normalized lineendings 2016-02-11 22:54:43 +01:00
Gabriele Tozzi
d1ac902926 Documentation: reformatted headers for DoxyGen 2016-01-28 14:52:40 +01:00
turley
1a35f79c3a Moved more non frequent used attributes into dynprops. cleanup for the movepkt. 2015-05-15 14:14:03 +02:00
turley
8d42a12b7c Optimized ObjRevision pkt, GraphicEffect pkts, Damage pkt 2015-04-17 18:58:14 +02:00
turley
79dff37246 Splitted gamestate external. 2015-01-02 14:46:44 +01:00
turley
88ec380941 Moved globals into separate directory. 2014-12-30 15:20:59 +01:00
turley
2737393f2a Tried to put all global vars into centralized structures.
Currently plib/systemstate, pol/uvars, pol/ucfg, pol/multi/multidef

Next step should be to split them based on usage, since its currently a bit of include hell...
2014-12-30 14:14:41 +01:00
turley
dd4d4c0f9a Added new WorldIteratorFilter for active client only players
Fixed warning during pkt write of sound effects.
2014-11-21 21:28:09 +01:00
turley
a08b5e4e4a Packet writer improvement
parameter can now have different type, only allow integer and enums, same sign
added runtimecheck for max value
2014-11-14 17:54:41 +01:00
frozenblit
1f0f7581dd Some more cleanups 2014-11-03 01:29:21 +01:00
frozenblit
ed679dba3d Moved message handling code into its own cpp
Created a new file (msghandl.cpp) and moved the code from pol.cpp there.
Moved related files to the "network" folder, where they belong. Fixed
include names... (we should make this relative to the project root!)
2014-10-01 21:10:32 +02:00
turley
fb873de803 decoupled headers to optimize a bit the build time 2014-05-03 09:06:19 +00:00
turley
261052f48d cleanup of the world iteration methods 2014-01-19 15:25:48 +00:00
turley
47fec4bdf5 splitted world zones into players and npcs, added several helper functions to only interate over the wanted types (player+npcs,player,npc,items,multis) best usable with lambdas. 2013-12-31 14:14:04 +00:00
turley
99d7dc3037 namespaces...finally :)
Hard part is finished every file is touched. Namespaces are currently rough named by directory name.
Maybe we could split it more
2013-12-21 09:10:46 +00:00
turley
10f6277683 msg_queue: new method to move the msg directly into the queue
streamsaver: changed the writer to unique_ptr and move directly into queue
clienttransmit: move transmitdata directly into the queue
itemdesc: removed several external maps, added save_on_exit member
items: added pointer to itemdesc and use it directly
2013-10-12 15:06:43 +00:00
turley
11ce4da294 changed pkt writer
generic definition, but gives linker error if unsupported type used, and compiler error if <..> is missing. Damn argument deduction
hopefully with this last pkt error in tooltips will never happen.
Chances that i broke a pkt .... high :P
2012-02-19 20:40:44 +00:00
turley
9edf8c2b52 gnaa fixed tooltips
added proposal for better write/writeflipped function def
Muad, Nando take a look at it.. :)
2012-02-19 13:58:11 +00:00
turley
43c2d5e19f fixed possible crash with tooltip pkt 2012-02-18 12:39:13 +00:00
turley
bb74c945d3 started to replace PacketOut... 2011-12-17 15:52:02 +00:00
turley
796d4992f9 finished refactoring of pkthelper 2011-12-17 12:05:57 +00:00
turley
440e57bced hsa mul support
changed objtype to max 0x20000
splitted pkt transmit
needs more testing
2011-06-14 15:20:00 +00:00
turley
823f18b0cc Added: pol.cfg AccountDataSafe (default -1)
Values:
            -1 : old behaviour, saves accounts.txt immediately after an account change
             0 : saves only during worldsave (if needed)
            >0 : saves every X seconds and during worldsave (if needed)
removed debugging stuff for pkts
2011-03-10 12:57:50 +00:00
turley
88c18237bd some pkt fixes + several debugtests (will be removed later) 2010-04-24 07:35:19 +00:00
turley
6e443a75ca finished pkt rewrite (except custom housing but not important)
removed xoutbuffer from client class and added a special buffer in pkt singleton
removed some threadlocks
mmmh should be finished need tester :)
2010-04-18 15:27:06 +00:00
turley
4b4f25d334 0xbf subs 2010-04-13 15:15:44 +00:00
turley
32c5528ad9 pkt 0xdc-0xf3 2010-04-11 14:13:49 +00:00
turley
03ed725f56 pkt 0xab-0xcc
had to move xmitoutbuffer to client class (threadsafty)
2010-04-10 10:30:25 +00:00
turley
93b37c5862 pkt 0xA9,0xAA
some fixes
added PolCore().pkt_status array of structs{pkt,sub,count} (currently a bit senseless due to critical pkt handling)
2010-04-09 14:00:47 +00:00
turley
7c54d3175f gcc fixes, minor cleanup 2009-11-06 16:07:47 +00:00
turley
045bc24873 removed chr.isUOKR added chr.ClientType
removed all bool is* versionmembers and added bitfield clienttype
changed all versionchecks to check the bitfield
added 0xE1 support (0xA9 packet will now send the flag for request)
2009-09-16 08:48:57 +00:00
muaddib_pol
631ed68c4a + All projects now using literal paths for includes.
+ Disabled Compiler warning 4244 in VS for str.cpp and strutil.cpp due to fact they are false warnings there.
2009-09-12 23:51:20 +00:00
muaddib_pol
5740a51281 + Partial Network and Item code moved 2009-09-08 01:42:26 +00:00
muaddib_pol
6a73041445 + Network Code organized some. Baby steps, baby steps 2009-09-07 20:37:38 +00:00
muaddib_pol
49072c3c41 + To-Do file updates
+ Beginning of Mobile and Module source file organization
+ Makefile.Gcc updates
2009-09-06 14:11:24 +00:00
muaddib_pol
d032ee448f + POL is now, open source. 2009-09-03 19:44:42 +00:00