In Island Transactions Documentation Not Consistent?

Shovel<public> := module:
    Name<public><localizes>: message = "Shovel"
    Description<public><localizes>: message = "An unbreakable shovel used to dig holes for planting."
    ShortDescription<public><localizes>: message = "Digs holes."

shovel<public> := class<concrete>(my_island_entitlement):
    var Name<override><final>             := Shovel.Name
    var Description<override><final>      := Shovel.Description
    var ShortDescription<override><final> := Shovel.ShortDescription
    var Icon<override><final>             := # path to your texture here
    MaxCount<override>:int= 1
    Consumable<override>:logic = false
    PaidRandomItem<override>:logic = false
    PaidArea<override>:logic = false
    ConsequentialToGameplay<override>:logic = true

First off you need to specify the message type for the description, short description, etc. But furthermore, it will not even compile because Shovel and shovel need to be case insensitive. I mean it’s not even like this is tucked deep away in the documentation. This is literally the first code someone sees.

Hello,

It’s possible to express extreme disappointment without accusing people of not caring!

I opened up the Transactions Template to see how they’re doing things - in entitlement_definitions.verse I see:

EntitlementInfo<public> := module:
    PrimoShovel<public> := module:
        Name<public><localizes>: message = "Primo shovel"
        Description<public><localizes>: message = "An unbreakable shovel used to dig holes for planting."
        ShortDescription<public><localizes>: message = "Digs holes."

and further down

Entitlements<public> := module:
    using { EntitlementInfo }

    # Using custom entitlement class to distinguish your entitlements from all other entitlements.
    feature_example_entitlement<public> := class<abstract><castable><unique>(entitlement){}

#...........

primo_shovel<public> := class<concrete>(feature_example_entitlement):
        var Name<override>:message = PrimoShovel.Name
        var Description<override>:message = PrimoShovel.Description
        var ShortDescription<override>:message = PrimoShovel.ShortDescription
        var Icon<override>:texture = Textures.T_Shovel
        # Setting 'Consumable' to false means the entitlement is durable
        Consumable<override> : logic = false
        PaidRandomItem<override> : logic = false
        PaidArea<override> : logic = false
        ConsequentialToGameplay<override>:logic = true

This all compiles successfully and looks to work in-game. I see PrimoShovel capitalized in the ‘Entitlement Info’ section, but lowercase in the ‘Entitlements’ section, so I wonder what errors you’re seeing related to capitalization.

It looks like the Entitlements section references Entitlement Info (“using { EntitlementInfo }”) but that’s not shown in the docs snipped. Do are you using that ‘using’ in your code?

Also for the message problem I see that the feature example project does not use <final>, does removing <final> 'fix that message error?

I’m also noticing that the feature example uses <unique> when defining ‘feature_example_entitlement’ but the docs (‘my_island_entitlement’) does not use this.

Happy to troubleshoot further. If it turns out there are errors in the docs posting an issue/bug report might be a path for getting it fixed.

1 Like

Hello,

You’re correct maybe they do care but it is at the very least not consistent. I was just extra annoyed when I wrote it. I am referring to this page on the documentation site, Creating Items and Offers in Fortnite | Fortnite Documentation | Epic Developer Community . I know the template provided within UEFN is correct and functions work properly but the code on this page which is what I was referring to does not.

Also anytime I tried to compile the code from that web page there was an error about Shovel and shovel needing to be case insensitive.

This also uses the keyword while the other does not. Either way I feel like what is provided as a template in the engine and what someone would be also reading about on the documentation website should be relatively consistent.

No worries, I agree that doc is not a great ‘jumping off point’. (Hard to immediately understand overall structure from examples of specific pieces)

I’d expect to see more and more tutorials after the feature is released tomorrow. If you find any older tutorials it’s important to know that the terminology ‘Product’ changed to ‘Entitlement’. class<abstract><castable>(product){} vs class<abstract><castable>(entitlement){}

The template is a bit overwhelming at first, I’m currently trying to get up to speed following this tutorial and this livestream.