-
-
Notifications
You must be signed in to change notification settings - Fork 137
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve console commands #1354
Improve console commands #1354
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
quick review :
hit body part seems to work okay, I tested it by cutting the right arm and then calling
hitbodypart HumanHandRightItem(Clone) all toxic 1000
it destroys it instantly as expected
same test for destroy body part, I get an exception
using command destroybodypart HumanHandRightItem(Clone)
NullReferenceException: Object reference not set to an instance of an object
SS3D.Systems.IngameConsoleSystem.Commands.Command.ReceiveCheckResponse[T] (System.String[] args, SS3D.Systems.IngameConsoleSystem.Commands.Command+CheckArgsResponse& response, T& calculatedValues) (at Assets/Scripts/SS3D/Systems/IngameConsoleSystem/Commands/Command.cs:67)
SS3D.Systems.IngameConsoleSystem.Commands.DestroyBodyPartCommand.Perform (System.String[] args, FishNet.Connection.NetworkConnection conn) (at Assets/Scripts/SS3D/Systems/IngameConsoleSystem/Commands/DestroyBodyPartCommand.cs:26)
SS3D.Systems.IngameConsoleSystem.CommandsController.RpcLogic___CmdProcessOnlineCommand_161581254 (System.String commandName, System.String[] args, FishNet.Connection.NetworkConnection conn) (at Assets/Scripts/SS3D/Systems/IngameConsoleSystem/CommandsController.cs:127)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested about half commands on host and 5 or 6 on clients, everything works, code makes sense and reduce a lot the clutter. Please get your branch up to date and it's ready to merge.
Assets/Scripts/SS3D/Systems/IngameConsoleSystem/Commands/HurtCommand.cs
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
all good, nice stuff, good work
Introduce a couple of methods to remove code repetition and significantly shorten all the commands.
Also fix a little bug, where long help command was executing twice