Skip to content

Commit

Permalink
fix(scripting/server): native pointer args for Player type
Browse files Browse the repository at this point in the history
Oversight from a previous change that didn't account for arguments of type "Player" being charPtr on the server-side.
  • Loading branch information
tens0rfl0w committed Dec 23, 2024
1 parent c970038 commit fa95d3e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ext/natives/codegen_out_pointer_args.lua
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ for _, v in pairs(_natives) do
argx = PAS_ARG_POINTER -- These are incorrectly labelled as intPtr
elseif (a.type.name == 'object') then
argx = PAS_ARG_POINTER | PAS_ARG_BUFFER
elseif (a.type.name == 'charPtr') or (a.type.name == 'func') then
elseif (a.type.name == 'charPtr') or (a.type.name == 'func') or (gApiSet == 'server' and a.type.name == 'Player') then
argx = PAS_ARG_POINTER | PAS_ARG_STRING
elseif a.pointer then
argx = PAS_ARG_POINTER
Expand Down

0 comments on commit fa95d3e

Please sign in to comment.