sethp for multiple targets
Closed this issue · 2 comments
Hello, great work so far with this plugin, it works pretty well, and I would consider this one of the best admin plugins right now for cssharp.
But I notice if I set the command “css_sethp @ALL xxx” it doenst work and it only print out "[CSS] There are multiple clients that match", which I would answer: "yes, that was on purpose".
Also, I dont know if it is possible yet, it would be great if one command of the duo css_hp and css_sethp could change the hp the player spawns with.
So one command set the current hp (like it is now) and one controls the spawn hp.
The same “issue” goes for css_who. I was missing a command like css_players, where it gives an overview over all player connected, so I tried “css_who @ALL“.
I would be great if you could add such an functionality, whether it is with css_who or a new command.
Thank you for your work.
A little look into the code reveals the source of that bug:
In FindTarget() was the singletarget arg set to true, despite the "all @ command" input option.
This happens actually surprisingly often in funcommands.cs, in fact 9 times. (css_freeze, css_unfreeze, css_sethp, css_speed, css_god, css_bury, css_unbury, css_bring ,css_glow)
While looking at the code I also noticed that css_revice and css_respawn are probably switched up.
As css_respawn respawns only dead player, css_revive respawns every player.
But that’s just a guess base on the names: only "revive" dead player would better fit the css_revive tag and respawn all would fit css_respawn.
Thanks for your feedback. I have fixed the problem where commands were only targeting one person. And I also set the sethp command. As for the respawn, revive commands, I didn't think about changing them because people got used to it that way. Doesn't seem to be a big problem