Skip to content
This repository was archived by the owner on Aug 12, 2025. It is now read-only.

NotQuiteLoona/CustomItemSpawns

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

CustomItemSpawns

This EXILED plugin allows server owners to specify custom spawns for items.

For each item, you can specify the room and its offset from a room’s coordinates.

DISCLAIMER

NOTHING IN THIS PLUGIN HAS BEEN WELL TESTED BESIDES ITEM SPAWN ON ROUND START. BE PREPARED FOR BUGS, ESPECIALLY WITH EXPERIMENTAL SETTING ENABLED!

You always can report bugs in the Issues section of this repo.

Installation

Download the latest release and move it to:

Windows

C:\Users\%UserName%\AppData\Roaming\EXILED\Plugins

Linux

~/.config/EXILED/Plugins

After you launch the server, all configuration parameters should be autogenerated.

How-to config

Most of the config values are self-explainable by description, but items itself requires some additional info. Here it goes:

To the first list (items), you should add items from the ItemType enum.

To the second list (rooms), you should add rooms from the RoomType enum to spawn items in.

To the third list (offsets), you should add offsets in XYZ lists.

All elements in all lists must correspond to each other.

Example

items:
- Flashlight
rooms:
- EzCafeteria
offsets:
- x: 2
  y: 3
  z: 5

This configuration will spawn a flashlight in the Entrance Zone cafeteria with an offset of 2 forward, 3 left, and 5 up (generally you shouldn’t think about XYZ as forward-left-up, but I’ve used this for the sake of simplicity).

More complex example:

items:
- Flashlight
- GunCOM15
- GunE11SR
rooms:
- EzCafeteria
- Hcz079
- Lcz914
offsets:
- x: 2
  y: 3
  z: 5
- x: 0
  y: 0
  z: 2
- x: 0
  y: 0
  z: 1

This configuration will spawn:

  1. Flashlight in the Entrance Zone cafeteria with an offset of 2 forward, 3 left, and 5 up.
  2. COM-15 at the SCP-079 containment Chamber with an offset of 2 up.
  3. Epsilon-11-SR at the SCP-914 containment chamber.

Other info

Hint: To spawn an item above the floor just give it some positive Z offset – it is a vertical axis.

You can add as many items as you want – theoretically, 2,147,483,647 and/or available RAM limits you, but actually, I don’t think you’re going to add more than two billion items.

Also, the config has some default values – you can use them as a reference.

To find possible values, you can visit this page.

Commands

This plugin also has a bunch of useful commands.

item_offset is the only client console command, and will give you the offset of your character from the center of the room you are currently in. You can use this command for the configuration of item offsets.

is is the parent (base) command for all other remote admin commands.

For is there are four available subcommands:

  • spawn_items (alias si) - Spawns all items that are specified in the config.
  • respawn_items (alias ri) - Respawns all items that are specified in the config.
  • clear_spawned_items (alias csi) - Removes all spawned items, which are not already picked up.
  • help (aliases are h, man, manual) - gives you everything written above in this list.

FAQ

Q: Where can I find possible values for the configuration?

A: To find possible values, you can visit this page.

Q: Is it possible to make item spawn configurable completely in one place?

A: It is possible, but it will take too much performance. Due to C# (and most of the strong-typed languages) limitations, lists, arrays, dictionaries, etc. can take only one type of data - it means that one list can contain either item, room, or vector3. I can make a string dictionary with some conversion methods, though they will take a LOT of performance. I don’t think it’s worth it.

Contributing and issues

There is no strict code style, you can make contributions in any style you want. As for the issues... Ensure that you provided all required info or be ready for questions and do not delete the logs.

About

EXILED plugin that allows owners to specify custom spawns for any item.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages