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

Code Smell detection in your project #1

Open
vittorianardone opened this issue Oct 2, 2019 · 0 comments
Open

Code Smell detection in your project #1

vittorianardone opened this issue Oct 2, 2019 · 0 comments

Comments

@vittorianardone
Copy link

Dear Developers,

we are a team of researchers from University of Sannio (Italy) that are conducting research on bad practices in Unity development. We are developed a linter able to indicate where is located into the code a bad smell affecting it.

The following smell may result in maintainability problems in a Unity project:
An excess of usage of public or [SerializedField] attributes (filled through the IDE's inspector) to couple "MonoBehavior" scripts and GameObjects. This is because the coupling is not visible in the source code, and any change to GameObjects or scripts need to be done through the inspector.

In your project our linter finds this problem into the following file, more precisely it contains public attributes of GameObject type:

Possible Solutions:

  • Link/Instantiate GameObjects from the source code so that the coupling between MonoBehaviour script and GameObjects can be visible from the source code and not just from the Inspector.

In order to better finalize our study we are proposing this issue. If you consider it as a smell, we would like to invite you to fixing it. We would be grateful for that, and also your game ;).

If you have any questions about this issue and/or our research, please do not hesitate to contact me: Vittoria Nardone ([email protected]).

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

1 participant