Event argument turns into nil if 2 previous were nil

Client Version: Canary
Server Version: 4162
Category of bug: Client & Server
Behaviour: When triggering any event, if 2 previous event arguments were nil next arguments will be nil regardless of their content passed in a script
What i expected to happen: To have all my arguments passed
Code for reproduction:

AddEventHandler('argumentsTest', function(arg1, arg2, arg3, arg4)
  print(arg1, arg2, arg3, arg4)
  -- expected output: 1, nil, nil, 4
  -- output: 1, nil, nil, nil
end)


TriggerEvent('argumentsTest', 1, nil, nil, 4) 

The bug appears in all type of events: client, server and between them.

Follow up to: Null arguments in native events (is this a bug?) - #2 by deterministic_bubble

I’ll eventually get around to testing my fix for this (baked directly into the C library). I just need to find the motivation to test these changes against my collection of server dumps to ensure nothing has regressed.

1 Like

A fix should be on canary (well, like ~15 after this post).