ArchDude17's Adventurer Armory Package

Made for the “Treasure Hunt” Build Jam 6/13/2022

Alright so this package has quite a bit in it and for the most part it is pretty self explanatory but there are a few things that I would like to explain. First of all this Package technically contains another package I made called BEAM Gun, caulk this up to learning experience but I didn’t mean to format it that way originally, and meant for some of those scripts to stay attached to their various existing packages as dependencies but that didn’t happen, I plan to try to sort that out but as I write this first version the clock ticks on the time to upload for the jam so taht is a problem for later…

Anyway…

So this package is meant to be sort of a one stop shop for making different adventure games that has treasure or some kind of resource finding. I think the best way to explain what is in it is to break it up in parts, since that’s how I designed it.

Part 1: Hunting Treasure
This part of the package is dedicated to really hunting down treasure, especially the neatly hidden or buried kind.

TreasureDetectorTemplate:
There is a “TreasureDetectorTemplate” which is the first device in this part. As named, this is a repurposed “gun” that instead of bullets shoots a trigger (TreasureDetectorTriggerTemplate) which detects entities in its volume and if an entity belongs to the list of Detectible entities in the TreasureDetectorScript placed on the TreasureDetectorTemplate it sends a signal to make a tone and turn a light green. If the gun is being fired and no entity on the list is detected then the light will be red. When making a tone, the pitch and volume will increase the closer you get to a detected entity. This is setup out of the box to detect both the default template “Collectable” from the collectibles package as well as an included “TreasureChestTemp” which works similar to the collectible in that on interaction it opens, plays an effect and adds a score to the player, all which can be modified in the properties view.

Fundamentally the detector works as a “Template Finder”, simply add what templates you want detected in the TreasureDetectorScript properties on the TreasureDetectorTemplate. If you want to play with the trigger settings there are options in the properties tab to change height and width but to change the range of the detection you will want to cahgne the “maxRange” property on the detector in the “DGunScript”. This Script is a modified gunScript and functions mostly the same but with a few changes. primarily it actually just shoots the trigger detection forward of the gun and not to what the player is technically looking at (though close) this is because the mesh was blocking the look at and it was weird sorry.

To use this simply give it to your player in their inventory (using the normal inventory setup) and now they can use. Primary action will activate the detector and releasing the button ends the detect

How It Really Works: A lobster is kept in a cage and it can smell treasure. When it smells treasure it rings a bell, which sends a vibration changing the color of the light.

TRNCH Gun:
The next item is the TRNCHGunTemplate. This is essentially a fully automatic shovel, but with some extra bells and whistles…literally. The TRNCH gun digs holes of varying sizes, which can be toggled by pressing Q or Right on the DPad. You can change what settings are available to the player. I put a warning in the script so I recommend reading that.

This item is perfect for uncovering buried treasure after finding it with your trusty detector.
Works by vibrating a shovel super fast.

Head Lamp:
While you dig and hunt for treasure you might need some light so I included a head lamp that you can give your players. All you have to do is drag the “Player Head Lamp” Script folder on to the player and it will take care of the rest. Now you can press B or Left DPad to toggle the light and this works without effecting inventory.

FlashLight:
If holding soemthing in your inventory is your need well heres a flashlight for you, toggle on off with shoot.

Part 2: Resource Finding
Now maybe your “treasure” is actually a resource that you have placed for your adventurer well now you can help them find all the resources they need. This part contains items designed to help detect and get resources.

ResourceDetectorTemplate:
This template is used to give the playe the ability to “find” a resource. it works similar to the TreasureDetector but instead of giving it templates to find it instead works by placing the “AddResourceScript” to an entity, putting what its resource name is and then adding that resource to detectable resources on the RDetectorScript. Additionally if you are a little lazy, or planning ahead, I have added the “ResourceManager” to this package. This lets you keep track of resource entities as well as creates a dynamic list of unique resource types. On the gun there is an option to get the list of resources from the resource manager instead of an entered list. The Resource manager must be placed in the world to work but the detector is again given to the gun.

There is a GoldOre and IronOre included with this package, and can show off how you can toggle the resource that is being searched for (one at a time) by the detector by pressing Q or Right DPad.

To help with gathering the resources I have added the BEAM Gun, this is similar to the TRNCH Gun in many ways but works a little differently in practice. Note the ore isn’t set up for damage but the gun is.

Last I added something fun and still WIP, it is a Mimic! The Mimic will chase the player when interacted with, so this could be a good scare to add to your game, or wait for me to update it further with some fun surprises.

Enjoy

slight edit sorry, so crayta was being weird and forced me to split the package for now, one half is as named the other is called “ResourceFinder” but kept crashing everytime I tried them together, again sorry, please don’t disqualify me for having to do that or add this addendum after.