From a2676f0cc17b75403908be9ea107436fa4eccd2b Mon Sep 17 00:00:00 2001 From: Cooldude2606 Date: Thu, 6 Aug 2020 19:55:20 +0100 Subject: [PATCH 1/2] Fixed Datastore --- expcore/datastore.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/expcore/datastore.lua b/expcore/datastore.lua index f0d5baa9..3fb93017 100644 --- a/expcore/datastore.lua +++ b/expcore/datastore.lua @@ -437,7 +437,7 @@ function Datastore:set_serializer(callback) end --[[-- Set a default value to be returned by get if no other default is given, using will mean get will never return nil, set using the default will set to nil to save space -@tparam any default The value that will be deep copied by get if the value is nil and no other default is given +@tparam any value The value that will be deep copied by get if the value is nil and no other default is given @tparam boolean allowSet When true if the default is passed as the value for set it will be set rather than setting nil @usage-- Set a default value to be returned by get @@ -747,6 +747,7 @@ local function event_error(err) log('An error ocurred in a datastore event handl @tparam string event_name The name of the event to raise for this datastore @tparam string key The key that this event is being raised for @tparam[opt] any value The current value that this key has, might be a deep copy of the value +@tparam[opt] any old_value The previous value that this key has, might be a deep copy of the value @tparam[opt] string source Where this call came from, used to do event recursion so can be parent or child @treturn any The value that is left after being passed through all the event handlers From e44b8d52ba6fb67bde7ba17783a9566c19a8a524 Mon Sep 17 00:00:00 2001 From: Cooldude2606 Date: Thu, 6 Aug 2020 19:58:10 +0100 Subject: [PATCH 2/2] Fixed Reports and warnings --- modules/control/reports.lua | 9 +++------ modules/control/warnings.lua | 2 ++ 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/modules/control/reports.lua b/modules/control/reports.lua index 2c62ce75..ea2a710f 100644 --- a/modules/control/reports.lua +++ b/modules/control/reports.lua @@ -161,13 +161,10 @@ end -- @tparam LuaPlayer player the player who is having the report removed from them -- @tparam string reported_by_name the player who had the report -- @tparam string removed_by_name the player who is clearing the report -<<<<<<< HEAD -local function report_removed_event(player, reported_by_name, removed_by_name) +-- @tparam number batch the index of this event in a batch, always one when not a batch +-- @tparam number batch_count the number of reports removed in this batch, always one when not a batch +local function report_removed_event(player, reported_by_name, removed_by_name, batch, batch_count) script.raise_event(Reports.events.on_report_removed, { -======= -local function report_removed_event(player,reported_by_name,removed_by_name,batch,batch_count) - script.raise_event(Reports.events.on_report_removed,{ ->>>>>>> 6.0.11 name = Reports.events.on_report_removed, tick = game.tick, player_index = player.index, diff --git a/modules/control/warnings.lua b/modules/control/warnings.lua index 10d75e77..aca6f1ba 100644 --- a/modules/control/warnings.lua +++ b/modules/control/warnings.lua @@ -155,6 +155,8 @@ end -- @tparam string warning_by_name the name of the player who made the warning -- @tparam string removed_by_name the name of the player who is doing the action -- @tparam number warning_count the number of warnings that the player how has +-- @tparam number batch the index of this event in a batch, always one when not a batch +-- @tparam number batch_count the number of reports removed in this batch, always one when not a batch local function warning_removed_event(player, warning_by_name, removed_by_name, warning_count, batch, batch_count) script.raise_event(Warnings.events.on_warning_removed, { name = Warnings.events.on_warning_removed,