Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
loom:datagen [2023/02/28 17:49] – Add docs for data() deprecation shedanielloom:datagen [2023/12/26 00:58] (current) – fix merging hyphens juuz
Line 2: Line 2:
  
 **NOTE:** This is **only** for Forge projects! Data Generators are still in development for Architectury projects. Fabric projects can follow Fabric Loom documentation. **NOTE:** This is **only** for Forge projects! Data Generators are still in development for Architectury projects. Fabric projects can follow Fabric Loom documentation.
- 
-Builtin support for Forge Data Generators was deprecated due to its low customisability and relatively ease of manually configuring it in the project’s build.gradle. 
  
 To make Data Generators work, we first need to add the src/generated folder to the resources classpath. To make Data Generators work, we first need to add the src/generated folder to the resources classpath.
Line 38: Line 36:
 Refresh Gradle, and you are done! Refresh Gradle, and you are done!
  
-If you wish to add more arguments (like ''--existing''), following is an example on how to add additional arguments:+If you wish to add more arguments (like ''%%--%%existing''), following is an example on how to add additional arguments:
  
 <code groovy> <code groovy>
Line 53: Line 51:
  
 **The legacy dataGen() block has been deprecated and may not function properly in future versions of Loom** **The legacy dataGen() block has been deprecated and may not function properly in future versions of Loom**
 +
 +The Loom DSL for Forge Data Generators was deprecated due to its low customisability and relatively ease of manually configuring it in the project’s build.gradle. The documentation
 +below is included mostly as a historical reference.
  
 Data Generators Support has been added to Architectury Loom, starting from 0.6.55, this is how you declare it: Data Generators Support has been added to Architectury Loom, starting from 0.6.55, this is how you declare it:
Line 66: Line 67:
 Run ''runData'' or use your IDE's run configurations to generate the assets, should be the same as ForgeGradle. Run ''runData'' or use your IDE's run configurations to generate the assets, should be the same as ForgeGradle.
  
-Architectury Loom automatically adds the following arguments: ''--all --mod <the mod ids> --output <path to src/generated/resources>'', if you wish to add more (like ''--existing''), following is an example on how to add additional arguments:+Architectury Loom automatically adds the following arguments: ''%%--%%all %%--%%mod <the mod ids> %%--%%output <path to src/generated/resources>'', if you wish to add more (like ''%%--%%existing''), following is an example on how to add additional arguments:
  
 <code groovy> <code groovy>