Skip to content

PlayerSay and PlayerCanSeePlayersChat problems #68

@Earu

Description

@Earu

https://github.com/MechanicalMind/murder/blob/master/gamemode/sv_player.lua#L473
In the above file, in your PlayerSay override, you call the PlayerCanSeePlayersChat hook and return a boolean.

  1. PlayerCanSeePlayersChat is called after PlayerSay because the PlayerSay hook can modify a player message, the string is then passed to PlayerCanSeePlayersChat. To test this behavior I invite you to test the following code server-side in sandbox:
hook.Add("PlayerSay","test",function(...)
	return "test"
end)

hook.Add("PlayerCanSeePlayersChat","test",print)
  1. PlayerSay return type is a string, not a boolean. wiki

Those behaviors are issues for addon makers because they're unexpected behaviors since they do not follow the base gamemode function signatures.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions