Incorrect device example in UEFN Docs

The documentation for Coding devices in UEFN does not work correctly.

This is the code specified in the docs:

`using { /Verse.org/Simulation }
using { /Fortnite.com/Devices }

spawner_button := class(creative_device):
@editable
Button:button_device = button_device{}
@editable
ItemSpawner:item_spawner_device = item_spawner_device{}

OnBegin<override>()<suspends> : void =
    Button.InteractedWithEvent.Subscribe(OnButtonInteractedWith) 

OnButtonInteractedWith(Player:agent) : void =
    ItemSpawner.SpawnItem(Player)`

However, the current iteration of the method call on ItemSpawner.SpawnItem(Player) is incorrect. This function parameter expects a value of type tuple(), but this argument is an incompatible value of type agent.

Confirmed with a print statement that otherwise you can cause an interaction so long as you don’t provide a param to the ItemSpawner.SpawnItem(), but no item spawns at the player.

Same problem

Hi:

Thanks for the report. This is indeed a problem of incorrect documentation and I will forward this along to the right people.

It seems that you need to add the items to be spawned in the item array in the settings of the ItemSpawner in the editor

Sorry, how can you solve this problem? I don´t undertand it

Thanks for the feedback! We’ve updated that documentation page. If you’re looking for how to set up an Item Spawner device with items it should spawn, check out the device page for it!