Commit Graph

138 Commits

Author SHA1 Message Date
Choonster TheMage cb02f24cf2 Fix uncaught ClassCastException from invalid recipe file (#4043)
A JsonSyntaxException will now be thrown, caught and logged when the conditions property of a recipe isn't an array
2017-06-24 01:24:54 -07:00
Shadowfacts f009435fa4 Allow condition factories to be registered from JSON (#4015) 2017-06-16 20:24:58 -07:00
LexManos a8659a1613 In-progress Registry system enhancement.
Needs cpw to take a look at enabling removing/overriding in the registry stuff.
But in theory it loads json recipes for mods now.
2017-06-14 10:14:56 -07:00
mezz 286777b824 Fix getShareTag replacing data on the server (#3776) Closes #3682 2017-06-04 18:38:16 -07:00
Madsthunder 93a4e13837 [1.11.2] Fixed Zombie Villagers not setting and getting professions correctly (#3678) 2017-04-30 21:59:57 -07:00
Paulo "JCranky" Siqueira be2d814155 Add LootTableManager to the LootTableLoadEvent (#3717) 2017-04-07 16:22:49 -07:00
sinus 25497d310b Adding config GUIs to the @Config based configuration System (#3735)
Lots of internal API that modders should not touch. See test mods for example usages.
2017-04-01 14:24:50 -07:00
James Mitchell 5f6bf3b063 Stop rotation of extended pistons, beds, and double chests Fixes #3634
Fix rotation of repeaters and comparators
2017-02-19 10:48:43 -08:00
mezz 8eea766288 [1.11.x] Refine fluid placement utilities (#3509) 2016-12-05 20:17:47 -08:00
liach 2337b0a6ae Moved TextureStitchEvent.Pre to allow custom sprites for blocks (#3436) 2016-12-01 20:49:23 -08:00
LexManos c459b87ec9 Initial 1.11 release update. 2016-11-15 19:26:10 -08:00
RainWarrior 5445f96327 Extended Animation State Machine format to allow multiple transitions from one state. 2016-05-13 12:46:34 +03:00
RainWarrior 5f62404f8a Switched animation system to capabilities, added animated item example, fixed state passing in MultiModel. 2016-03-21 10:48:52 +03:00
RainWarrior b8bb8c374c Fixed MultiLayerModel not getting correct submodels; Unified the gui lighting of normal and custom models - diffuse lighting is now done in the pipeline, no need for IColoredBakedQuad anymore. 2016-03-17 07:29:44 +03:00
RainWarrior b81a13d010 Fixed model error reporting, fixed model errors in test mods that shouldn't happen, fixed custom texture loading, made more things private/final. 2016-03-16 01:42:23 +03:00
RainWarrior 5d352bda6c Big model loader refactoring: simplified a lot of things, broke some error reporting. Still generally works. 2016-03-13 16:16:25 +03:00
RainWarrior 0710bdf3f5 Model animation system.
Main things of interest:
  * IAnimationStateMachine - state machine for animations; can load
    from json.
  * AnimationTESR - automatic TESR for animated models.
  * AnimationModelBase - same for entities.
  * ITimeValue - time-varying value, used to control animation
    parameters from code.

  * TESRs can now be batched - look at TESR.renderTileEntityFast +
    TE.hasFastRenderer.
  * RegionRenderCache is not accessible to TESRs and other client-side
    logic - MinecraftForgeClient.getRegionRenderCache.
2016-01-24 09:59:38 +03:00
RainWarrior 949e77b46a Model loader improvements: adding custom data/textures to models that don't need them doesn't cause a error now, since it's common to put those in the defaults section of the blockstate json; you can get IModel associated with the variant now - using ModelLoaderRegistry.getModel; MultiLayerModel should now respect transformations applied to it, and respect part transformations. 2016-01-06 22:00:43 +03:00
RainWarrior 856a9c3cdd Fixed perspective transformation handling for fluid models, changed inventory fluid model to use unrotated still texture. 2016-01-04 13:54:45 +03:00
Bernhard Bonigl 4f6784b733 Add a dynamic bucket model that displays the animated liquid contained
Has a config option (default off) that replaces the vanilla buckets with the forge bucket model

New original bucket textures from mr_hazard
2015-12-21 22:22:40 +01:00
RainWarrior 86c09722a0 IModel can now depend on a variant definition (ModelResourceLocation); added MultiLayerModel - simple model that'll render correctly in multiple layers + example of using it. 2015-12-15 21:49:19 +03:00
RainWarrior d6ee373e87 Preparations for the Animation system.
Changes to the Model API - IModelState now works with Optional. Handling of parts of the model is not optional, and coordinate space/result interpretation is up to the caller. IModel doesn't extend IModelPart by default anymore; MapModelState uses composition to achieve previous functionality, IModelPart implementations are disjoint now. Updated perspective handing to the new API, removed IPerspectiveState (MapModelState is now the same thing). Perspective transforms for the default fluid model.
2015-12-14 23:27:27 +03:00
RainWarrior 9815d729b5 Fixed NPE is B3D loader caused by the missing vertex normal; updated the example chest model - it's now has 2 meshes; Updated ModelAnimationDebug - it now uses the new chest model, renders the base with the static world renderer, and only the lid with the TESR. 2015-11-23 10:12:01 +03:00
RainWarrior 13d7530e43 Implemented interpolation of TRSR transformations; B3D: added interpolation capabilities to B3DState, animated TESR example in ModelAnimationTest (pure TESR right now, no separation inside the example model between the static and dynamic parts right now). 2015-11-16 06:51:39 +03:00
RainWarrior 8a11ad7a7a OBJ loader: reworked texture resolution: keys now have to start with #, like every other model loader; models without explicit library now work, remapping is possible by using the key "#OBJModel.Default.Texture.Name"; in addition to remapping by material name, remapping by texture name works too, like in other model formats. 2015-11-07 20:36:57 +03:00
shadekiller666 7a20543d5f OBJLoader: Quick bandages to support/fix the new way that face/vertex normals are calculated, a very quick bandage to patch TextureCoordinates for the time being, and the Parser now uses a Pattern to split strings on whitespace instead of only splitting on " ". 2015-10-29 02:21:28 -07:00
RainWarrior 7c7547227c Perspective awareness for vanilla and multi models, fixes #2148.
Improved error handling in MultiModel.
2015-10-27 17:40:05 +03:00
shadekiller666 d1b220f6a3 Added OBJ loader for the ModelLoaderRegistry system. 2015-10-26 19:38:49 +03:00
RainWarrior b175d265b9 Much requested temporary hack for items and TESRs. Context: #1582, #1597, #1713, #2058 and others. 2015-09-02 07:35:24 +03:00
shadekiller666 87bbbfafcc Fixed a bug with ExtendedBlockStates containing at least one IProperty and one IUnlistedProperty not allowing blocks to be placed. 2015-07-25 14:55:42 -07:00
RainWarrior c4f370a7e6 Custom transformations in forge blockstate json. 2015-06-30 21:37:11 +03:00
RainWarrior 1582e401ed Added ItemLayerModel - less awkward, simpler and faster version of ItemModelGenerator. 2015-06-23 04:43:48 +03:00
RainWarrior 07038f8342 Added fluid renderer. 2015-06-18 14:26:53 +03:00
RainWarrior d6bc936ffa B3D Improvements
- fixed keyframe transformation application
 - textures are now resolved the same way as in vanilla models
 - added the ability to use forge blockstate texture information
 - removed unused code from the B3D example
2015-06-04 18:58:42 +03:00
Lex Manos 267e1ee62f Hook BlockState's Json loading to add support for simplified Forge format.
See https://github.com/MinecraftForge/MinecraftForge/pull/1885 for more details.
2015-06-02 16:49:56 -07:00
RainWarrior b8add23d9b ModelBakeEvent now has ModelLoader as an argument instead of ModelBakery; Added various static hooks to ModelLoader to allow registering model-related information before it's needed (prevents file-not-found errors on first baking pass); ModelLoader waits until ModelBakeEvent is done before showing any missing model exceptions; It's now possible to define models completely in-code (as illustrated by ModelBakeEventDebug). 2015-02-04 09:45:23 +03:00
RainWarrior 6eba0ebb93 Added model loader registry
Entry point: ModelLoaderRegistry
loader interface: ICustomModelLoader
custom model: IModel

ModelLoader is responsible for splicing into vanilla model system.
(you probably don't need to use it directly)

Interop with vanilla models isn't great yet
(vanilla models can't refer to custom ones as parents), will improve in
the future.

Includes loader for B3D models, with animation support
(net.minecraftforge.client.model.b3d).
Blender export plugin with compatible coordinate system:
https://github.com/RainWarrior/B3DExport

OBJ loader is being written, will be included at some point in the
future. For now you can convert OBJ to B3D via blender, or wait.
2015-01-29 11:33:52 +03:00
RainWarrior 134fbaa1ff Added model bake event (allows mods to insert custom baked models, much like TextureStitchEvent allows to load custom textures), ISmartBlock/ItemModel (ability form models to react to block/item states), Block.getExtendedState, support for unlisted properties in block states. Includes example implementation of http://imgur.com/a/FyyJX 2014-12-04 14:16:30 +03:00