Категория может быть null

This commit is contained in:
DBotThePony 2023-08-13 19:52:33 +07:00
parent 3617b38196
commit 48e1cd5263
Signed by: DBot
GPG Key ID: DCC23B5715498507
2 changed files with 21 additions and 21 deletions

View File

@ -31,7 +31,7 @@ interface IItemDefinition : IThingWithDescription {
/** /**
* Категория предмета, определяет, в какую вкладку инвентаря оно попадает * Категория предмета, определяет, в какую вкладку инвентаря оно попадает
*/ */
val category: String val category: String?
/** /**
* Иконка в инвентаре, относительный и абсолютный пути * Иконка в инвентаре, относительный и абсолютный пути

View File

@ -16,24 +16,24 @@ data class ItemDefinition(
@JsonFlat @JsonFlat
val descriptionData: ThingDescription, val descriptionData: ThingDescription,
override var itemName: String, override val itemName: String,
override var price: Long = 0, override val price: Long = 0,
override var rarity: ItemRarity = ItemRarity.COMMON, override val rarity: ItemRarity = ItemRarity.COMMON,
override var category: String, override val category: String? = null,
override var inventoryIcon: ImmutableList<IInventoryIcon>? = null, override val inventoryIcon: ImmutableList<IInventoryIcon>? = null,
override var itemTags: ImmutableList<String> = ImmutableList.of(), override val itemTags: ImmutableList<String> = ImmutableList.of(),
override var learnBlueprintsOnPickup: ImmutableList<RegistryReference<IItemDefinition>> = ImmutableList.of(), override val learnBlueprintsOnPickup: ImmutableList<RegistryReference<IItemDefinition>> = ImmutableList.of(),
override var maxStack: Long = 9999L, override val maxStack: Long = 9999L,
override var eventCategory: String? = null, override val eventCategory: String? = null,
override var consumeOnPickup: Boolean = false, override val consumeOnPickup: Boolean = false,
override var pickupQuestTemplates: ImmutableList<String> = ImmutableList.of(), override val pickupQuestTemplates: ImmutableList<String> = ImmutableList.of(),
override var tooltipKind: String = "normal", override val tooltipKind: String = "normal",
override var twoHanded: Boolean = false, override val twoHanded: Boolean = false,
override var radioMessagesOnPickup: ImmutableList<String> = ImmutableList.of(), override val radioMessagesOnPickup: ImmutableList<String> = ImmutableList.of(),
override var fuelAmount: Long = 0, override val fuelAmount: Long = 0,
override var pickupSoundsSmall: ImmutableList<String> = ImmutableList.of(), override val pickupSoundsSmall: ImmutableList<String> = ImmutableList.of(),
override var pickupSoundsMedium: ImmutableList<String> = ImmutableList.of(), override val pickupSoundsMedium: ImmutableList<String> = ImmutableList.of(),
override var pickupSoundsLarge: ImmutableList<String> = ImmutableList.of(), override val pickupSoundsLarge: ImmutableList<String> = ImmutableList.of(),
override var smallStackLimit: Long? = null, override val smallStackLimit: Long? = null,
override var mediumStackLimit: Long? = null, override val mediumStackLimit: Long? = null,
) : IItemDefinition, IThingWithDescription by descriptionData ) : IItemDefinition, IThingWithDescription by descriptionData