Skip to content

Customization

mortuusars edited this page Jul 19, 2024 · 1 revision

Attachments

Custom Films 🎞️

You can customize film by setting two properties in film item's NBT tag: FrameSize and FrameCount.

  • FrameSize - resolution of the captured photo. Default is 320.
  • FrameCount - number of frames in a film. Default is 16.

Warning! Larger values of FrameSize can cause lag and stutters. Larger values of FrameCount can cause disconnects from server and/or other issues. 32 will probably be fine, 64 maybe. But I haven't tested it. Use at your own risk.

This custom film can be added to the game with a custom recipe, quest reward or in a loot table.


Custom Flashes 💡

Any item can be added to exposure:flashes tag to make it behave like a flash while on camera.


Custom Lenses 🔍

Since 1.5.0, lenses configuration is now data-driven.
Example Datapack

Datapack creation:

To add a custom lens, create a .json file and place it in data/exposure/lenses folder. You would need a file for each focal range you want to have.

Example json:

{
  "item": {
    "item": "minecraft:glass"
  },
  "focal_range": {
    "min": 10,
    "max": 18
  }
}
  • item: is an Ingredient, same as in recipes. All things applied: tags, nbt matching, etc.
  • focal_range: Limits are: 10-300.

NOTE:

To be able to place the item in lens slot on the Camera, you would need to add the item to exposure:lenses tag. This can be done in the same datapack or with KubeJS/CraftTweaker.


Custom Filters ⏹️

You can add custom Camera filter with different effects. This will howewer require some knowledge of minecraft shaders.

Since 1.5.0, filters configuration is data-driven. The process is similar to lenses, but with a resourcepack instead of a datapack.
Example Resource Pack

Resource Pack creation:

To add a custom filter, create a .json file and place it in assets/exposure/filters folder.

Example json:

{
  "item": {
    "item": "minecraft:spider_eye"
  },
  "shader": "minecraft:shaders/post/spider.json"
}
  • item: is an Ingredient, same as in recipes. All things applied: tags, nbt matching, etc.
  • shader: location of the shader for this filter. Hint: use /shader apply @s <shader> command to preview the shader as you're making it. This command will also show you all available shaders (there's several cool ones in vanilla. And mods can have them as well)

If you want to create a simple shader that changes color/tint etc - look at included Exposure's shaders, with a bit of tinkering, you'll be able to create one no problem (hopefully). For complex shaders - may the light help you.

NOTE:

To be able to place the item in filter slot on the Camera, you would need to add the item to exposure:filters tag. This can be done with a datapack or with KubeJS/CraftTweaker.


Use in quests 📑

Photograph item contains a fair amount of additional information: Position, Dimension, Biome, Weather, Light Level, etc. But most interesting is the entities that were captured in the photo.
Mods like KubeJS can be used to process this info and do various interesting things with it.

For simple quests - Photograph will contain a boolean NBT-tag for every entity that was captured which will look like this: "minecraft:warden":true.
This can be used in FTBQuests, for example, to create a quest where a player needs to take a photo of the specific entity.