Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

1 Screenshot

  • 686,192
  • 11,221
  • 128.48 kB

About BotSpawn

BotSpawn spawns a set number of Rust AI bots at chosen monuments.
It also supports bots at server airdrops, supply drops, biomes, custom locations, and 'toplayer' by chat command.
Offers Facepunch default scientist and murderers, with additional customisation options, including kits.


BotSpawn allows storage of sets of data files.
Each set has a prefix in their names and a specific set is loaded by setting this prefix in config - DataPrefix = "NameHere",

  • Default locations are generated automatically and their settings are held in /oxide/data/BotSpawn/prefix-DefaultProfiles.json.
  • Custom location are added by chat-command and their settings are held in /oxide/data/BotSpawn/prefix-CustomProfiles.json.

 

Recent updates notes.

The way custom spawn points are stored changed in V2.1.2.
The change means three main things.
1: You will have to remove and re-add all your custom spawn points.
2: If you're using Parent_Monument with custom spawn points, those custom spawn points will now automatically relocate each wipe.
I.E. You will no longer have to set them up from scratch every wipe.
3: If you're using Parent_Monument with custom spawn points, Parent_Monument must be set (and botspawn reloaded) before adding custom spawn points.
If you change Parent_Monument, or set it later, all custom spawn points will need removed and re-done.

 

 

Optional dependencies -

Permissions.

  • botspawn.allowed - Required for non-admin use

Console commands.

  • bot.count - Displays the number of live BotSpawn npcs in console.
  • bots.count - Displays the number of live BotSpawn npcs in console, listed by profile name.
  • botspawn spawn <profilename> - Spawns additional out-of-population npcs, for the given profile.
  • botspawn kill <profilename> - Kills any out-of-population npcs, for the given profile.
  • botspawn.toplayer <playername> <profilename> - Spawns bots from given profile at given player.
  • botspawn.addspawn - for keybinding
  • botspawn.removespawn - for keybinding
  • botspawn.info - Display profile name of the npc you're looking at

 

Notes.

General notes.
BotSpawn maintains populations based the Day_Time_Spawn_Amount and Night_Time_Spawn_Amount for each profile.
NPCs spawned for airdrops or by 'spawn' or 'toplayer' commands, or by calls from other plugins
are not considered part of the population and will not respawn on death.

Without Kits default Scientists/Murders will have nothing in their corpse inventory
except default Rust random loot - No weapons or clothes.

All BotSpawn options will govern BotSpawn bots, only.
The only exception is "NPCs_Attack_BotSpawn" option which prevents other npcs from attacking BotSpawn npcs.

 

Configuration.

  • "DataPrefix": "default", (tells BotSpawn which data files to load)
  • "DayStartHour": 8,
  • "NightStartHour": 20,
  • "NPCs_Attack_BotSpawn": false,
  • "HTNs_Attacks_BotSpawn": false,(Scarecrows etc npcs will ignore botspawn npcs.)
  • "BotSpawn_Attacks_NPCs": false,
  • "APC_Safe": true,
  • "Turret_Safe": true,
  • "Animal_Safe": true,
  • "Supply_Enabled": false, (spawn 'airdrop' bots for user-called supplys)
  • "Remove_BackPacks_Percent": 100 is always : 0 is never.
  • "Remove_KeyCard": true, (any keycards in bot default loot will be destroyed)
  • "Ignore_HumanNPC": true, (ignore 'bots' from HumanNPCCore plugin)
  • "Ignore_HTN": true/false (botspawn npcs will ignore scarecrows etc.),
  • "Ignore_Sleepers": true/false,
  • "Pve_Safe": true, (bots will not be injured by fire/barbs, etc.)
  • "Max_Chute_Wind_Speed": 100
  • "Max_Chute_Fall_Speed": 100
  • "Staggered_Despawn": false
  • "PeaceKeepers_Ignore_Melee": false

 

*'BotSpawn' are npcs spawned by this plugin.
*'NPCs' are npcsb spawned by any other means.

Note - The 'Attacks' global options are preventative.
False = disable : True = default behaviour.

Chat commands.

  • /botspawn add <customname> - Add a custom profile at your location
  • /botspawn remove <customname> - Remove a custom profile at your location
  • /botspawn move <existingname> - Relocate a custom profile to your location
  • /botspawn list - Show all custom location names
  • /botspawn toplayer <playername> <profilename> - Spawns npcs near player, using specified profile settings.
  • /botspawn info - Tells you the profile name of the npc you're looking at.
  • /botspawn spawn <profilename> - Spawns additional out-of-population npcs, for the given profile.
  • /botspawn kill <profilename> - Kills any out-of-population npcs, for the given profile.
  • /botspawn reload <profilename> - Reloads a specific profile, reading any data file changes, without reloading the whole plugin.

For custom spawn points.

  • /botspawn edit <existingname> - Show, and begin editing custom spawn points.
  • /botspawn show <duration> - show custom spawn points for profile being edited, for X seconds.
  • /botspawn addspawn - Adds your current location to the spawns for the profile you're editing.
  • /botspawn removespawn - Removes the last-added custom spawn point.
  • /botspawn removespawn <number> - Removes a specific custom spawn point, by number.
  • /botspawn movespawn <number> - Moves a specific custom spawn point, by number.

Note: You will need to edit data/BotSpawn.json and set AutoSpawn: "true", as well as any other customisations.

 

Default locations.

  • Events
    AirDrop - Spawns when crate is spawned.
    HackableLockedCrate - Spawns when hack is initiated.
  • Monuments

All major monuments are automatically detected and numbered 0/1/2 to allow multiples.
HackableLockedCrate profile does not apply to the oilrig crates, or crates spawned by BotSpawn.

 

Biomes

  • Arid
  • Temperate
  • Tundra
  • Arctic

Note: Radius is irrelevant for biomes Each bot spawns at a random position within the relevant biome.

 

Options per-profile.

The following options will be listed once in your data json for each location.
The only essential setting is AutoSpawn : True. Everything else is preference.

  • AutoSpawn - true/false.
  • Murderer - True/False.
    Spawns the 'running zombie' murderer prefab instead of Scientist.
  • Bot Names - [], See below.
  • Bot Name Prefix - eg "NPC".
  • Keep_Default_Loadout - true/false.
    Keeps Scientist/Murderer attire and weapons, in addition to your custom kits.
  • Kit - [], See below.
  • Day_Time_Spawn_Amount - 0.
  • Night_Time_Spawn_Amount - 0.
  • Radius - 200 - Size of the area in which bots will spawn.
  • Roam_Range - 40.
  • Chute - true/false.
  • Stationary - true/false - Allows CustomSpawnPoints npcs to exist off navmesh; They will aim and fire but will not move.
  • UseCustomSpawns - true/false.
  • ChangeCustomSpawnOnDeath - true/false - Killed npc will spawn at his original spawnpoint, or a random one.
  • Announce_Spawn - true/false.
  • Announcement_Text - "Custom text here.".
  • Bot Health - 100 is default. Value can exceed 100.
  • Bot_Accuracy_Percent 100 is most accurate.
  • Bot_Damage_Percent (dealt)- 100 is greatest amount of damage.
  • Aggro_Range - 30.
  • DeAggro_Range - 40.
  • Peace_Keeper- true/false
    Bots ignore you if you have no projectile/fire weapon drawn.
    Melee will do no damage to bots.
  • Peace_Keeper_CoolDown - 5 (seconds).
    Once aggravated, bots will remain hostile towards you for this period, even if you put away your weapon.
  • Attacks_Other_Profiles - true/false.*
  • Suicide_Timer - 300 seconds.**
  • Die_Instantly_From_Headshot - true/false.
  • Instant_Death_From_Headshot_Allowed_Weapons - Shortprefabnames - See below
  • Weapon_Drop_Percent - 100 is always : 0 is never.
  • Min_Weapon_Drop_Condition_Percent - 50(%).
  • Max_Weapon_Drop_Condition_Percent - 100(%).
  • Wipe_Belt_Percent - 100 is always : 0 is never..
  • Wipe_Clothing_Percent - 100 is always : 0 is never.
  • Allow_Rust_Loot_Percent - 100 is always : 0 is never.
  • Spawn_Hackable_Death_Crate - true/false - spawns hackable crate at npc corpse.
  • Death_Crate_CustomLoot_Profile - "CustomLootProfileName.
  • Death_Crate_LockDuration - 600.
  • Disable_Radio - true/false.
  • Running_Speed_Boost - 0.0 is default. Values of even 1.0 or 2.0 will make a big difference.
  • AlwaysUseLights - true/false (ignore time of day)
  • Corpse_Duration: 60 (Seconds)
  • Respawn_Timer - 60 (Seconds).

For custom profiles only

  • Location - Data only - Do not change manually.
  • Parent_Monument - eg "Dome"
  • Maintains position relative to parent after map seed change.

 

* Murderers will never attack murderers but murd V sci and sci V sci will work fine.
** Prevents long term build up of airdrop and toplayer bots.
** Does not apply to re-spawning regular bots.

Kits, Names, and Headshot weapons should be formatted as follows:
["kit1"], for single or ["kit1", "kit2", "kit3"], for many.
["name1"], for single or ["name1", "name2", "name3"], for many.
["lr300.entity"], for single or [ "lr300.entity", "m92.entity" ], for many.

If there are multiple entries BotSpawn will randomly pick one from the list.
If the number of kits is equal to the number of bots, BotSpawn will always pair them together in sequence.
Random names are generated for any blank entries - ["one", "", "three"],.

 

API.

Single instance calls.

These will not respawn (like "toplayer" bots) location is your intended target, profileName is taken from BotSpawn (config or data), and group should be made up and assigned by the user.

string[] AddGroupSpawn(Vector3 location, string profileName, string group)
string[] RemoveGroupSpawn(string group)
string NpcGroup(NPCPlayer npc)

Long term calls.

string[] CreateNewProfile(string name, string profile)
string[] ProfileExists(string name)
string[] RemoveProfile(string name)

All returns are string array ["true/false/error", "details message"]
Also, botspawn can return the Monument Name and a list of live bots, for each AutoSpawn = true monument.
 

var result = (Dictionary<string, List<ulong>>)BotSpawn?.Call("botSpawnbots");

 

Example call.

[PluginReference]
private Plugin BotSpawn;

Vector3 location = new Vector3(0,0,0);
string[] Spawn = BotSpawn?.Call("AddGroupSpawn", location, "Dome", "YourNameHere") as string[];

Puts($"{Spawn[0]}");
Puts($"{Spawn[1]}");

 

FAQ.

Q: There's a million options. Where do I start?
A: Set AutoSpawn to true for at least one monument in config/BotSpawn.json, then reload the plugin.
A: Everything else is preference/user customisation.

Q: My bots disappear or don't move.
A: It's possible that some belt items and some weapon skins may caused the bots to stop responding.
A: Try plain weapons only in the belt to troubleshoot.
A: Failing that, try a different location.
A: Certain terrain still causes issues for bot spawning.

Q: Performance sucks.
A: Try setting ai_dormant = true
A: If this helps but you'd like to modify the dormancy range, you can specify 'ai_to_player_distance_wakeup_range X'. The default is 160m.
A: Failing that, please reduce the number of bots.

Q: My bots won't die?!
A: Make sure Godmode permissions allow you to do damage.
A: Same for vanish ^.
A: If you're running a PVE server, use a PVE plugin which allows you to alter its settings for NPCPlayers.

Q: I take damage when attacking my bots.
A: This can also be caused by server, or plugin, PVE settings.

Q: Will X kill my bots?
A: Radiation, drowning, falling, and helicopters will not kill your bots.
A: Turret targeting bots can be toggled. Bradley targeting bots can be toggled.
A: Fire (campfires etc) will kill your bots. Damage from barbs, cacti etc will kill your bots, but can be prevented with the 'Pve_Safe' config option set to true.

Q: What weapons can my bots use?
A: I recommend sticking to basic bullet-weapons, hand tools and melee weapons.
A: Some weapons may work better than others. Some weapon skins have been known to cause issues and errors.
A: Please try plain weapons if you're having problems. Scientists are not optimised to use melee, only.
A: At least one projectile weapon should be given.

Q: Can I have custom profile locations?
A: Yes. Your custom locations are stored in data with a filename of *YourPrefix*-CustomProfiles.json.
Use chat command '/botspawn add NewNameHere' to create a profile at your present location.

Q: Can I have specific custom spawn points? (underground, etc)
A: Yes. Use the built in commands to create custom spawn points and set UseCustomSpawns to true, for some profile..
A: That BotSpawn profile will now ignore radius settings and use the precise spawn points from your file.

Q: Can I spawn bots at airdrops.
A: Yes. Airdrop option spawns bots at server drops. Spawn at user-supply call is an additional option.

Q: My bot kits aren't working.
A: Console will report if your kit does not exist, or if there is no active weapon there.
A: Please redeem the kit yourself to an empty inventory, to ensure that you remember to put items in it!
A: If it's empty, kit yourself out the way you want the kit to be then type: /kit edit NameOfKit and /kit items.

Q: How can I prove that bots have spawned? I can't find them.
A: Type bot.count into console.
A: Respawn timer is taken into account so if you spawn one and kill him, bot.count will show 0 until respawn.

Q: bot.count console command shows that there are 0 bots.
A: Double check that at least one monument is set "AutoSpawn": true in your config, and reload the plugin.
A: Also, don't forget their respawn timer. Make sure they aren't all dead when you bot.count.

  • Like 13
  • Love 6

Steenamaroo's Other Downloads


User Feedback

About Us

Codefling is a forward-thinking platform for developers to share and monetize their work from plugins to game assets and everything in-between.

2,605 files sold to 300 customers and $35,993 of payments processed this year!

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.