Item Drops Plugin for Godot 4
A downloadable asset pack for Windows, macOS, Linux, and Android
Elevate your Godot 4 game with Item Drops, a versatile toolkit designed to seamlessly integrate item spawning, gatherable nodes, pickup mechanics, and interactable objects into your 2D world. Effortlessly create loot-filled chests, harvestable crops, enemy loot drops, or randomized treasure tables—all with minimal setup. Whether you're building a platformer, RPG, or survival game, Item Drops empowers you to bring your item systems to life.
What’s Inside?
Drops
Transform your inventory items into physical objects in the game world with these powerful spawning tools:
- RandomDrops: Spawn scenes randomly from a customizable DropsTable with a single call to spawn_drops.
- InventoryDrops: Drop existing items from a character’s inventory directly into the world.
- InventoryAccessSettings: Connect to any inventory system by defining custom methods and properties for pickup and drop actions.
- DropsTable: Set drop odds for each scene to instance as 2D objects in the game world.
- DropsGenerator: Calculates which items to spawn based on your DropsTable odds.
Pickups
Turn scenes into collectible items that integrate with your inventory system:
- Pickup2D: A 2D object that can be picked up by a PickupsCollector2D, perfect for loot or resources.
- PickupsCollector2D: A trigger area that collects Pickup2D objects, adding them to your chosen inventory when overlapped.
- PickupAnimationPlayer: Simple way to trigger animation on pickup if you want to play an effect before freeing the Pickup2D
Scene Spawning
Instance dropped items into the game world with dynamic behaviors:
- LaunchForceSceneSpawner2D: Applies an impulse force to spawned RigidBody2D objects for instant movement (e.g., loot flying outward).
- ShapeEdgeSceneSpawner2D: Randomly spawns scenes along the edges of a collision shape for natural placement.
- SpawnedMoveOnSpawnComponent2D: Adds a one-time movement script to scenes spawned by a SceneSpawner, animating their entry.
Gathering
Harvest resources from the world with these intuitive components:
- GatherableComponent: Marks a node as harvestable, spawning items via a SceneSpawner until depleted.
- AutoGathererComponent: Automatically harvests a GatherableComponent after a set real-world time interval.
- AddAfterSecondsComponent: Replenishes a GatherableComponent by calling its add(int) method after a delay.
Interaction
Enable rich player-object interactions with these flexible tools:
- AnimationToggleInteractable2D: Toggles an AnimationTree property (e.g., for opening chests, doors, or switches) with smooth animations.
- Interacter2D: Allows characters to interact with nearby Interactable2D components via an action key.
- InteractionIndicator2D: Displays an icon when an Interactable2D is within range, enhancing usability.
Item Drops Signal Bus
Centralize event handling with a shared signal resource:
- Connect nodes (e.g., HUDs) to receive PickupEvent, GatherEvent, and SpawnEvent signals for real-time updates.
Why Choose Item Drops?
- Flexible Integration: With InventoryAccessSettings, adding and removing item resources from inventories is largely system agnostic. You can define the methods that need to be called to work with inventories systems.
- Ready-to-Use Demos: Includes 2D sidescrolling and top-down gathering demo projects showcasing all features.
- Lightweight & Modular: Add only the components you need, keeping your project efficient.
- Enhanced Gameplay: From loot drops to interactive objects, create engaging mechanics fast.
Purchase
In order to download this asset pack you must purchase it at or above the minimum price of $17 USD. You will get access to the following files:
Development log
- 0.4.1 Bug Fixes & GdUnit Testing4 days ago
- 0.4 Demo, Inventory Access, and Interactable Objects12 days ago
- 0.3 & 0.3.1 Enemy Item Drops & Signal Bus UpdateFeb 25, 2024
Comments
Log in with itch.io to leave a comment.
Not sure where is best to contact you. The code runs through with no errors, but never actually spawns anything into the game world.
I can spawn items from my loot chest no problem with the same scene I use in your DropsComponent.
when I call the " drops_component.spawn_drops(1.0) "
nothin is spawned into the world. Any help would be great thanks.
The spawn point when the code is run shows the correct spawn location as well
drops_to_spawn in the DropsComponent also shows the correct packedscene
However, after the code is run and checking the child count in the PickupsGroupNode, it is still 0
Any help here would be spectacular thanks.
So I tracked down the issue. As the only spawner that now works appears to be the spawn_scene_at_point
That chunk was however missing the add_child(instance)
just added that and it works great.
In process of a move at the moment but if you ping me on https://discord.com/invite/vxMuaeZd I can help out if you run into any other issues next week
Appreciate that thanks. I got it all sorted with the parent call and all as well. My smooth brain sometimes needs a little longer than some to wrap my head around some one elses' code lol
spawn_parent.call_deferred("add_child", instance)
Again appreciate the response.
Cant wait for a tutorial on this add-on. Your videos on the grid_building and world_time made them really easy to implement.
Thanks it's going to come with an update to the plugin too. Trying to get it out there after this grid builder plugin update I'm working on atm.
Awesome, glad to hear it! Appreciate all the work you do!