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

Added some JavaDoc (code documentation) #4

Merged
merged 1 commit into from Jan 21, 2020
Merged

Conversation

@BenjaminAmos
Copy link
Contributor

BenjaminAmos commented Jan 21, 2020

Most of the main methods have been documented, as well as the primary classes in the module.

@casals casals merged commit 62830a1 into Terasology:master Jan 21, 2020
1 check passed
1 check passed
continuous-integration/jenkins/pr-merge This commit looks good
Details
Copy link

skaldarnar left a comment

Thanks a lot for the PR! Highly appreciated! 👍

I left a few comments to share my two cents about best practices in doc comments, and to spread awareness of some internal about events, systems, and how they interact with each other 😉

@@ -2,6 +2,9 @@

import org.terasology.entitySystem.event.Event;

/**
* An event which, when received, will allow the target entity's sensors to detect other entities.

This comment has been minimized.

Copy link
@skaldarnar

skaldarnar Jan 21, 2020

What you describe here is the (current) default behavior when the event reaches the system currently in place.
That means that the documentation currently is correct, and it is definitely helpful, but it also means that introducing new/other systems may change the behavior this event provokes without changing the event itself.

Without that additional information it is hard to describe this event, though.

@@ -4,9 +4,20 @@
import org.terasology.entitySystem.entity.EntityRef;
import org.terasology.network.Replicate;

/**
* A sensor located physically in the world, which can detect entities when activated.

This comment has been minimized.

Copy link
@skaldarnar

skaldarnar Jan 21, 2020

Does it need to be "in the world"? I don't see a location component here, but I also might be missing something...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants
You can’t perform that action at this time.