Skip to content
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

Fix a transferEnergy type error where it suggested a creep. #258

Merged
merged 4 commits into from
Jul 17, 2024

Conversation

InfinityDevTech
Copy link
Contributor

Brief Description

StructureLink.transferEnergy()

Offered either a Creep or a StructureLink as an option to send energy to.
Links cannot beam energy into a creeps mind.

Checklists

  • [ x] Test passed
  • [ x] Coding style (indentation, etc)
  • [ x] Edits have been made to src/ files not index.d.ts
  • [ x] Run npm run dtslint to update index.d.ts

@DiamondMofeng
Copy link
Member

Thanks for your fix ❤️

We can see that transferEnergy no longer accepts Creep as a target after this change
screeps/engine@879b4ca#diff-1542a7dcc950f72720a06df87eed6689815424c825be3557643c3412f95dce5cR154

Copy link
Member

@DiamondMofeng DiamondMofeng left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you remove the comment `If the target is a creep, it has to be at adjacent square to the link.'?

@InfinityDevTech
Copy link
Contributor Author

Can you remove the comment `If the target is a creep, it has to be at adjacent square to the link.'?

Completed, also, re-worded it a bit to make sense with the context of the function call.

@DiamondMofeng DiamondMofeng merged commit 5a93dc1 into screepers:master Jul 17, 2024
0 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants