Translations:Modding:Simple Particles/5/en

From Vintage Story Wiki

Now we have the property, the only thing left to do is to set the position and spawn the particles into the world. I'm gonna use the OnHeldInteractStart and *Step method inside a custom made Item class (you can read more about this in the Collectibles Tutorial): <syntaxhighlight lang="c#">

       public override void OnHeldInteractStart(ItemSlot slot, EntityAgent byEntity, BlockSelection blockSel, EntitySelection entitySel, ref EnumHandHandling handHandling)
       {
           handHandling = EnumHandHandling.Handled;
       }