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

Wiki development #135

Open
Vakorg opened this issue Sep 16, 2018 · 1 comment
Open

Wiki development #135

Vakorg opened this issue Sep 16, 2018 · 1 comment

Comments

@Vakorg
Copy link

Vakorg commented Sep 16, 2018

I think that need to use code samples in the wiki, such as here https://docs.screeps.com/api/

@BurnySc2
Copy link
Collaborator

That's a great idea!
In my opinion, the wiki needs a huge rework anyway. Lots of Units filters and Unit properties were added.
I suppose small code samples should be added to the wiki, but adding all filters and properties would be too much.
I will try to edit the wiki when I have spare time.

Do you know a good way to do type annotation in python code samples?
For example:

for my_structure in self.units.structure.not_ready:
    print("This structure {} is still in construction: {}%".format(my_structure, round(my_structure.build_progress * 100, 1)))

Here, my_structure is of type Unit which would be good to know.

PS: Screeps is an awesome game, too bad I dislike javascript :(

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

No branches or pull requests

2 participants