Jump to content

Bad Company Manager (ApiMod for Servers)


Recommended Posts

Current BCM Commands


bc-admins => (BCM) Admins - Provides information on admins, bans, whitelist, and other admin details

bc-assets => (BCM) Assets - Provides info on game resources and assets

bc-block, block => (BCM) World Blocks - Insert, report on, and swap blocks within the area

bc-blockrpc, blockrpc => (BCM) World Blocks - Similar to World Blocks but using RPC (remote procedure call) instead of chunk reloading to update the clients, single block only

bc-chatcolor => (BCM) ChatColor - Change the chat color for a player

bc-chatmax => (BCM) Max Chat Length - Limits the length of text that can be sent to the chat output

bc-chatprefix, bc-prefix => (BCM) Hide Chat Commands Prefix - Hide chat commands that start with the given prefix

bc-chunks, bc-cc => (BCM) Active Chunks - Information about the chunks loaded by the server

bc-co => (BCM) Chunk Observer - Command for controlling dynamic chunk observers and loading chunk areas

bc-debuff => (BCM) Remove Buffs From Entities - Removes a buff from an entity or type of entity

bc-debuffplayer => (BCM) Remove Buffs From Players - Removes a buff from an online player

bc-entities, bc-le => (BCM) Entities - Provides information about all entities in the game

bc-events, bc-config => (BCM) Events - Edit event system configuration and report settings and data

bc-export, export => (BCM) Export - Creates a tts prefab file of the defined location

bc-geb, buffentity => (BCM) Give Buffs to Entities - Buffs the entity or type of entity with the given buff

bc-getspawn => (BCM) Get Spawn - Gets a valid spawn point at the given x,z. Also loads the chunk

bc-give => (BCM) Give Items to Players - Gives the targeted player items into inventory

bc-givequest => (BCM) Give Quests To Players - Grants the remote player(s) the given quest

bc-go => (BCM) Game Objects - Provides detailed information about the game objects such as blocks, items and recipes

bc-gpb, buffplayer => (BCM) Give Buffs to Players - Buffs the remote player with the given buff

bc-gs => (BCM) Players Gamestages - Alias for BCPlayers

bc-help => (BCM) BCHelp - Provides a list of all active BCM commands, and info about /options

bc-id => (BCM) Players Ids - Alias for BCPlayers

bc-import, import => (BCM) Import - Loads a prefab from disk into the world, and activates sleeper spawns

bc-loc, loc => (BCM) Location - Gets your current position and stores it in cache for use in other commands

bc-lp => (BCM) Players - Provides extensive information about all players

bc-manager => (BCM) Horde Spawners - Gets information about the spawn manager system such as active spawns and spawncounts

bc-mute => (BCM) Mute Players - Mutes or unmutes a player in global chat

bc-party => (BCM) Parties - Information about the player parties on the server

bc-pdf => (BCM) Player Files - Player data file information, such as steamid, last online, last write.

bc-playername, bc-pn => (BCM) PlayerName - Provides options to override names or append a prefix to a group of players

bc-pos, bc-lppos => (BCM) Players Positions - Alias for BCPlayers

bc-prefab => (BCM) Prefab - Edit existing prefabs on the server

bc-protect, protect => (BCM) Protect - Add or remove trader protection to an area

bc-remove => (BCM) Remove - Removes the selected entities from the game by unloading them

bc-removequest => (BCM) Remove Quests From Players - Removes an in progress quest from the player

bc-setskill, setskill => (BCM) Set Skills On Players - Allows you to directly set skill levels on a player while they are online

bc-sleeper => (BCM) Sleeper - Display and manipulate the sleeper volumes in prefabs

bc-spawn => (BCM) Spawn - Spawns entities with definable targets and groups/classes and horde counts

bc-task => (BCM) Task - Reports running subthread tasks

bc-teleport, bc-move, move => (BCM) Teleport - Move target entity etc to a new location

bc-test => (BCM) Test - Catchall command for testing new features

bc-tile, tile => (BCM) Tile Entity - Perform actions on the tile entities (loot containers and doors) in the area

bc-time => (BCM) Time - Provides server time, ticks, fps, clients, entities

bc-trash => (BCM) Mem Trash - Runs Garbage Collection to try and free up Memory on the server

bc-undo => (BCM) Undo - Reverts the previous world editing command

bc-unlockall => (BCM) Unlock All - An alias for 'tile access'

bc-version => (BCM) Versions - Information about the mods installed on the server

bc-visitregion, visit => (BCM) Visit Region - Visits the region(s) given and reveals the map

Link to comment
Share on other sites

Testing Status for commands in A17


bc-admins - working

bc-assets - working

bc-block - untested

bc-blockrpc - untested

bc-chatcolor - working

bc-chatmax - working

bc-chatprefix - working

bc-chunks - working

bc-co - working

bc-debuff - untested

bc-debuffplayer - untested

bc-entities - working - entityId, type, and position only

bc-events - disabled

bc-export - untested

bc-geb - untested

bc-getspawn - untested

bc-give - working

bc-givequest - working

bc-go - working - mostly. Some types are still disabled

bc-gpb - untested

bc-gs - working

bc-help - working

bc-id - untested

bc-import - partial tested, may not work for importing sleepers and block translations

bc-loc - working

bc-lp - working - skills and buffs not working

bc-manager - untested

bc-mute - working

bc-party - working

bc-playername - working

bc-pdf - working

bc-pos - working

bc-prefab - working

bc-remove - working

bc-removequest - untested

bc-setskill - untested, probably broken

bc-sleeper - broken

bc-spawn - working

bc-task - working

bc-teleport - working - doesnt appear to work on vehicles atm

bc-tile - untested

bc-time - working

bc-trash - untested

bc-undo - untested

bc-unlockall - working

bc-version - working

bc-visitregion - working

Link to comment
Share on other sites

Great work. I wrote a command that has been EXTREMLY helpful for server admin work. Its just a simple "Who owns this" command for secure doors and chests So i can easily figure out who's chest i'm in. I took a look at coppies unlockall command to figure out the basics.

Link to comment
Share on other sites

Great work. I wrote a command that has been EXTREMLY helpful for server admin work. Its just a simple "Who owns this" command for secure doors and chests So i can easily figure out who's chest i'm in. I took a look at coppies unlockall command to figure out the basics.


Yeah between Allocs, Coppis, and Server tools there are some nice examples of how to do a lot of things. Other bits took a fair bit of trail and error to see what worked.


Finding the right place for different stats etc was a mission, bit I have most of it sorted now. I'm in the process of breaking it down into seperate model files for each bit so its modular and I can grab the bits I need for each command without having to duplicate code.


The first useful command I'll be looking at after the purely infomational commands is a quest updated tracker (for Guppy). It will provide a list of quest changes over time, and can pop a log/console message out when changes are spotted.


I'm thinking of having a heartbeat ticker that runs in the background and triggers the checks periodically for events that are tied to it.

Link to comment
Share on other sites

Mostly finished a new component (uploaded to source) that adds a timer that allows actions to be performed at set intervals.


The system has a Heartbeat object that has a pulse and configurable beats per minute (new System.xml file in config)

The system also has Synapses and Neurons. The Synapse defines 1 or more Neurons that will be fired at set intervals. Currently, the synapses can be adjusted in the config for enabled/disabled, and how many beats between each firing. I will be adjusting the code a bit so that which neurons are attached to a synapse is configurable as well.


The default heartbeat is 60 bpm, and the first synapse I'm working on is the quest monitor for GuppyCur that pops a message into the log when a players quest list changes.


The Neurons will require some c# coding, however, some of them will be able to make use of config files, such as the spawning ones.


This is the basis of the system I will be using to create the dynamic spawning system that allows the default spawning system to be entirely replaced.

Link to comment
Share on other sites

Mostly have the quest monitor working, but something isnt quite right when used on a fresh presistent data container, so will need to keep working on it.


For a break I have made a command to return a list of all prefabs from the hub cell data in a single cell, or all cells, or filters by text. The version that searches the full list is very HDD intensive so takes about 15 seconds to run on my local machine, but since the data is static i will add a saved file that contains the data to reduce the subsequent lookups.


https://docs.google.com/spreadsheets/d/1nqiw2A9Y2da5rYQlKDNMTwaAWT-xVChy2QsH2mROX1U/edit#gid=13099823 is a google doc with some examples of the data it gives you.


ListHubCellData.cs is the code for anyone that is interested. I will make a new release with a compiled dll in a day or two once I get my questmonitor command working correctly.

Link to comment
Share on other sites

What's up with those y coordinates. That's odd.


I'm clamping the height to make a flat world for prefab building :p


<module name="clampOutput" type="ClampOutput">

<property name="sourceModule" value="scaleBiasOutput"/>

<property name="bounds" value="1,1"/>

<!-- <property name="bounds" value="-28,190"/>-->



If you look at the vanilla tab is has a lot more variation in the y co-ord

Link to comment
Share on other sites

Lot of changes uploaded to source. I'll tidy up a few things and Finish the List Game Objects commands and add a param to filter results and do the 1.1.0 release with a dll tomorrow.


Managed get a memory efficient cache working for the hub cell data results, so only the first use after a server reboot will be slow, after that its less than 1 second even ruturning the entire 6000+ prefab list.


I've unified most of the commands and added /options for affecting the output such as /log /chat /csv /nl /color /worldpos /csvpos and a few command specific ones (like /current for the hub cell data command)


doing bc-lhcd /nl /chat isnt advised :p

Link to comment
Share on other sites

I think it might even be possible to add dynamic changes to various game objects then call the save method and save the xml back out to the server xml's. This has some real potential.


I'm going to be playing with randomly generated archetypes and entities today to see whats possible there too.

Link to comment
Share on other sites

Updated to Release 1.2.0 - Download via first page for the zip


Lots of stuff added.


Main additions are:

List Players - many variants to list the individual components returned by ListPlayersExtensive


List game objects - commands to display the lists / details of the various game objects such as blocks/items, loot, entities, spawning, biomes, etc (not all commands have been finished, they all have the full list commands, some have the individual items and /details components)


Added /options to allow for adding various addition options to commands, such as /log /chat /online /offline /color=FFFFFF, see the bc-help command for common options and individual help commands for specific options


Added default options settings in the Commands.xml file which can be overridden on the command line


Added a give/remove quest to/from player commands, so that you can change players quests remotely.


Added a Heartbeat/Synapse/Neuron system that will allow for configurable functions that operate on a heartbeat timer. The first Synapse implemented is the Quest Monitor. It will send text to the log when a players quest list changes with the changed quest and its new status.


If the logs have errors about the persistent data file from the v1.0.0 version then you will need to remove it (in the saves folder, BCMPersistentData.bin)

Link to comment
Share on other sites

What's the heartbeat timer set to?


60 BPM by default. It can be changed in the config System.xml


Each Synapse has a setting for how often it fires as well, quest monitor is set to every 15 beats


<?xml version="1.0" encoding="UTF-8" ?>
 <Heartbeat isalive="true"/>
 <BPM rate="60"/>
 <Synapse name="questmonitor" enabled="true" beats="15"/>

Link to comment
Share on other sites

See the new vid? Block to entity. :)


Haven't really been keeping up with the vids, but I can guess how that could be done. Could probably do it with my mod but if they already have something in the works for it I will focus on other things for now ;)

Link to comment
Share on other sites

A little demo of the Buff Entity Command :)




Sorry about the long pauses, I really should work out why it does that and get it fixed ;) ... probably doesnt help runnign a dedi, and having visual studio and a bunch of other stuff all running on the same machine :)

Link to comment
Share on other sites

Do any of your commands give you the ability to determine which prefab you're standing closest to?


...let me back up.


The ability to fix a prefab, by standing near it and getting that particular prefabs ID to spawn it in, would be cool. It's a lot of pieces though... getting the list of prefabs (done). Getting the coordinates of the one you're next to (can be done). Reimporting it (can be done). I'm sure I'm missing some pieces though, but it'd be nice to "fix" certain areas more easily.

Link to comment
Share on other sites

I'm wondering if your new spawning system will still work once the put the sleeper system in place. it sounds like they are replacing many wandering zombies with static ones that aren't trigger until you create an event in proximity to them.


They might be making major hard coded changes to achieve the change.

Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Create New...