Skip to content

Add SDK.Player.Action #6

@victorpopkov

Description

@victorpopkov

Verify

  • I understand that if I ignore these instructions, my issue may be closed without review.
  • I have made sure that there are no similar opened issues.
  • I have made sure that the SDK version matches the latest release.

Is your feature request related to a problem? Please describe.

We should consider adding a new SDK.Player.Action module to handle everything related to different player actions. For example, see dstmodders/mod-keep-following#8. It would be nice to have SDK.Player.Action.UseItem() at very least and let SDK respect both client and server.

Describe the solution you'd like

Add SDK.Player.Action similar to SDK.Player.Attribute. Respectively, SDK.Remote.Player should be extended. I would also consider adding 4th level submodules support and split SDK.Remote.Player further:

SDK.Remote.Player.Action
SDK.Remote.Player.Attribute

The existing SDK.Player.WalkToPoint() and SDK.RPC.WalkToPoint() should be moved into SDK.Player.Action and SDK.Remote.Player.Action respectively.

Describe alternatives you've considered

We could leave SDK.RPC as is and not extend SDK.Remote.Player. Another consideration is that we could move all player-related remote functionality:

SDK.Remote.Player.Action => SDK.Player.Remote.Action
SDK.Remote.Player.Attribute => SDK.Player.Remote.Attribute

Additional context

Progress

  1. Add SDK.Player.Action
  2. Move and rename SDK.Remote.Player to SDK.Player.Remote
  3. Split SDK.Player.Remote into submodules:
    1. SDK.Player.Remote.Action
    2. SDK.Player.Remote.Attribute
  4. Implement SDK.Player.Remote.Action functions:
    1. Hide()
    2. UseItem()
    3. UseEquippedHeadItem()
    4. UseEquippedBodyItem()
    5. WalkToPoint()
  5. Implement SDK.Player.Action functions:
    1. Hide()
    2. UseItem()
    3. UseEquippedHeadItem()
    4. UseEquippedBodyItem()
    5. WalkToPoint()
  6. Write tests

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions