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

Use Tags.GROUPNAME for MyMod proxy #193

Closed
wants to merge 3 commits into from
Closed

Conversation

miozune
Copy link
Member

@miozune miozune commented Jun 23, 2023

Also remove outdated script

@miozune miozune requested a review from a team as a code owner June 23, 2023 08:15
@@ -15,7 +15,7 @@ public class MyMod {

public static final Logger LOG = LogManager.getLogger(Tags.MODID);

@SidedProxy(clientSide = "com.myname.mymodid.ClientProxy", serverSide = "com.myname.mymodid.CommonProxy")
@SidedProxy(clientSide = Tags.GROUPNAME + ".ClientProxy", serverSide = Tags.GROUPNAME + ".CommonProxy")
Copy link
Member

Choose a reason for hiding this comment

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

I think this is one of the things that shouldn't be parametrised, to allow changing maven coordinates without having to modify mod sources (in this case moving all java files to a different package).

Copy link
Member Author

Choose a reason for hiding this comment

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

Is it that common case than starting new project? My intention is to reduce confusion for newcomers

Copy link
Member

Choose a reason for hiding this comment

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

Group, modname and modid shouldn't even be tokenized (if that's a word) in my opinion, as those should never change. Tieing them to properties in gradle.properties feels very counterproductive. (If you need to change one of those for whatever reason you should know what you're doing regardless.)

My intention is to reduce confusion for newcomers

Newcomers should idealy read/watch a tutorial first. They nearly always explain how to use @SidedProxy when setting up the main mod class. Kinda unrelated to this PR but still: giving a newcomer this template removes the need to understand what they are doing, resulting in possibly poorer code quality and/or redundant code and/or more bugs in the long run.

Copy link
Member Author

Choose a reason for hiding this comment

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

hmm, I see

@miozune miozune closed this Jul 11, 2023
@miozune miozune deleted the fix/my-mod-groupname branch July 11, 2023 22:41
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.

4 participants