Commit graph

3411 commits

Author SHA1 Message Date
Lucas Nicodemus
eb8aad8a3b
Add extra debug logs to OnTileEdit Bouncer call 2020-05-23 00:39:39 -07:00
Lucas Nicodemus
d610ab929b
Support dirt bomb (fixes #1853, fixes #1865)
This commits adds rudamentary support for dirt bombs. There's probably
some edge cases in here but the entire handler really needs to be
rewritten. This is total spaghetti and completely unreadable and
unrecognizable.
2020-05-23 00:38:03 -07:00
Lucas Nicodemus
c5ec45bc02
Support using the scarab bomb (fixes #1808)
Also fixes #1781. Partially fixes #1865.
2020-05-22 23:53:34 -07:00
Lucas Nicodemus
7452d3c91d
Support using bottomless lava bucket
This is in response to discussion #1859. Due to the nature of this
already terrible handler, I refuse to add any other types of checks for
whether or not this item is banned and lava. If you want to ban lava,
ban a lava bucket. Don't ban an infinite lava bucket, because finite
lava is still infinite lava in this topsy turvy game where the client
rules the world.
2020-05-22 23:33:09 -07:00
Lucas Nicodemus
a457e8c9ee
Support lava absorbant sponge (fixes #1852) 2020-05-22 23:22:48 -07:00
Lucas Nicodemus
dbc4bd4747
Add verbose debug log for rangechecks 2020-05-22 22:16:41 -07:00
Lucas Nicodemus
b87f5d0a1b
Fix probable typo in sundail special perm
This check used & instead of && which is technically possible but
probably not the right thing to do here.
2020-05-22 21:11:37 -07:00
Lucas Nicodemus
41f35a27df
Merge branch 'general-devel' of github.com:Pryaxis/TShock into general-devel 2020-05-22 21:06:48 -07:00
Lucas Nicodemus
f227a2a1e4
Add verbose logging to rest of GetDataHandlers
Should help put the nail in the coffin of many 1.4 bugs
2020-05-22 21:06:16 -07:00
Chris
5d2945ab1f Change SendMessage & SendMessageFromPlayer to use FromLiteral not FromFormattable. Solves #1856 2020-05-23 13:05:22 +09:30
Lucas Nicodemus
03e41a521e
Add more logging to Bouncer to debug antihack
This adds more logging in Bouncer so as to detect more false positives.
2020-05-22 19:34:55 -07:00
Chris
4dc1edaa34
Merge branch 'general-devel' into fix-1834 2020-05-23 10:00:17 +09:30
Lucas Nicodemus
7a5c2e4d26
Add verbose logging for many bouncer packets
This type of change is designed to make it easier to debug problems with
Bouncer's anticheat checks and antigrief checks by allowing server
operators to send better reports. In particular, the logs will help us
diagnose precisely which checks are tripping, and they can cross
correlate the item with the check to adjust the precise check.

More work is needed to add more checks in more places, but you can't
just do this naively and need to actually think when adding things.
2020-05-22 15:34:04 -07:00
Olink
7d83e06e83 Fix the snake flute item. 2020-05-22 18:02:03 -04:00
Olink
836fd1d156
Fix for spawn issues when using SSC and beds
It looks like the only time the client informs the server of the spawn location is via the PlayerSpawn packet. In SSC, understandably, we don't trust any updates from the client if we can avoid it. In this scenario, we have code in PlayerSpawn to check for beds when they attempt to spawn, but no code to handle negative spawn locations. The client sends -1,-1 coordinates when the player has no spawn. We should trust this.
2020-05-22 14:21:15 -07:00
Chris
b9b83dd36f Resolve null reference on REST user group name. Solves #1850 2020-05-22 14:41:52 +09:30
Chris
83eb707761 Update SendMessage and SendMessageFromPlayer to use inbuilt Terraria chat messaging 2020-05-22 13:27:03 +09:30
Axeel
56a9e27365
Fix player respawn again (#1830)
* fix respawn time unit, add spawn bouncer, add respawn time config warning

Co-authored-by: Lucas Nicodemus <shank@shanked.me>
2020-05-21 13:37:31 +08:00
Lucas Nicodemus
f25ed62599
Make setup system less confusing to new players 2020-05-20 15:36:27 -07:00
Axeel
773092b7bf
Merge branch 'general-devel' into sqliteconf 2020-05-20 22:46:15 +08:00
鱼鱼
68019602d2 uncommented something accidentally commented out 2020-05-20 21:37:30 +08:00
鱼鱼
946d54b69e fix player spawn stuff 2020-05-20 21:27:49 +08:00
鱼鱼
1eaa1eb901 Make sqlite db path configurable 2020-05-20 19:44:48 +08:00
Chris
208afe9a7e Merge branch 'general-devel' of https://github.com/Pryaxis/TShock into general-devel 2020-05-20 18:00:51 +09:30
Chris
7ad46abced Removed -worldpath because you should now just use -world with the full file path 2020-05-20 18:00:28 +09:30
Lucas Nicodemus
dea5e0f8f8
Remove reference to obsolete forums in setup
Thanks to @Retrograde-i486 for pointing this out! Fixes #1793.
2020-05-20 00:25:13 -07:00
Lucas Nicodemus
7314a34986
Properly don't log if not logging enabled 2020-05-20 00:00:09 -07:00
Lucas Nicodemus
3b748f1156
Potentially fix player desync issue
It was discovered that LastNetPosition is being checked to see if it's
zero in Bouncer. Then, Bouncer rejects the update. The default is zero
and potentially this can be zero in other ways. The original code in
master (checked at 9f4892f in GetDataHandlers) had an additional write
on LastNetPosition to update it, but this write was not moved over to
Bouncer. Thus, there is a high probability that players are "desync'd"
after LastNetPosition gets stuck at zero and never updates.
2020-05-19 23:50:02 -07:00
Lucas Nicodemus
e6df3edeec
Merge branch 'general-devel' into h/betterlogs 2020-05-19 23:02:46 -07:00
Lucas Nicodemus
e20f717269
Remove reimplementation of Terraria player sync
The reimplementation of Terraria player sync was first created by
@Zidonuke when introducing better antihack and the item ban system. He
added this because he was probably attempting to correct the client that
sent that sent bad data. The primary purpose was to send data back to
the client, not necessarily for the purpose of doing anything for the
server. This is demonstrated by the fact that when we added player
update handling, we started rejecting the packets outright and not
sending the player any packets. This means that functionally we don't
run this code hardly ever if someone is actually disabled.

Some of those code was related to /confuse. That is also being removed.
2020-05-19 22:26:46 -07:00
Lucas Nicodemus
145885beb3
Remove /confuse command 2020-05-19 22:26:45 -07:00
Lucas Nicodemus
e9098d0e78
Add verbose debug logs to a variety of checks
These are high priority checks we really want to look at. I want to add
more of these debug statements to all checks in Bouncer and other parts
of GetDataHandlers, but I think this is good enough for now.
2020-05-19 22:11:21 -07:00
Lucas Nicodemus
b76d906c59
Overhaul debug logging
Debug logging now provides ConsoleDebug and ILog has been updated to
support the concept of debug logs. Debug logs are now controlled by
config.json instead of by preprocessor debug flag.
2020-05-19 22:04:10 -07:00
Chris
2df23c53b7 Add annotations to new permissions 2020-05-20 00:39:24 +09:30
Chris
6ecdf8545f Consolidated a number of world event commands into one master command
`worldevent` is now the root for the following:
Meteor, fullmoon, bloodmoon, eclipse, invasions, sandstorm, rain.
Added a new set of permission nodes to represent world events: `tshock.world.events.*`
2020-05-20 00:11:04 +09:30
Chris
a178b31333 Fixes world mode some more 2020-05-19 23:04:23 +09:30
Asada shinon
31f9c57080 Quick Command ID Fix 2020-05-19 19:02:40 +08:00
Chris
240b6b71b0 Change toggleexpert command to change the world mode 2020-05-19 13:20:45 +09:30
Lucas Nicodemus
35198647a1
Presumptively fix MySQL 8 compat
`Groups` is a reserved name in MySQL 8 and this should fix compat issues
with it.
2020-05-18 18:40:51 -07:00
Lucas Nicodemus
d8747c34e9
Rename /bloodmoon to /tbloodmoon 2020-05-18 18:25:07 -07:00
Patrikkk
8ced5d5dfc Adding new buffs to OnNPCAddBuff
Missed these buffs with their bufftimes, so it was always caught by the bouncer, thinking players are hacking.
2020-05-18 18:47:39 +02:00
Lucas Nicodemus
41c813a2dd
Version tick: 4.4.0 2020-05-18 01:04:51 -07:00
Lucas Nicodemus
013c58e923
Update TShock version codename 2020-05-18 01:00:23 -07:00
Lucas Nicodemus
3471646dc7
Temporarily disable some projectile cheat checks 2020-05-18 00:52:44 -07:00
Lucas Nicodemus
92f8095277
Read extra data for kill portal 2020-05-18 00:00:55 -07:00
Lucas Nicodemus
0a95457a7e
Merge branch 'general-devel' of github.com:Pryaxis/TShock into general-devel 2020-05-17 23:48:55 -07:00
Lucas Nicodemus
12d40e98ad
Disable always return on HandleLoadNetModule
As of 1.4.x.x, these are used for more than just chat text and we need
to start handling them separately. The original check here would just
return true (handling the event) for any module that's not text. Now, we
need to actually do processing and check for exploits on these.
2020-05-17 23:47:29 -07:00
Chris
ea53fdf04a Merge branch 'general-devel' of https://github.com/Pryaxis/TShock into general-devel 2020-05-18 15:47:40 +09:30
Chris
c2e3f65a2a Add modeling to new projectile handling 2020-05-18 15:47:31 +09:30
Lucas Nicodemus
926f97b49f
Update OnTeleport hook with new changes 2020-05-17 23:17:03 -07:00