mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-15 15:24:52 +09:00
Remove the unused and badly behaved getCommand and getLua functions from clusterTools. The main issue with these is that encourage the use of large commands that have negative impact on the performance of the servers, as such large commands have to be transmitted to all players that are connected. These functions also have poor handling of lua comments and will fail on strings containing for example "--".
17 lines
426 B
JavaScript
17 lines
426 B
JavaScript
/**
|
|
|
|
Functions frequently needed from different places in the cluster. Ex:
|
|
* Getting an instance's displayname from their ID
|
|
|
|
*/
|
|
|
|
module.exports = ({config} = {}) => ({
|
|
/**
|
|
async function to get an instances displayname from their instanceID
|
|
|
|
arg1 is the instanceID
|
|
Promise resolves with a string, either the displayName or instanceID if not found.
|
|
*/
|
|
getInstanceName: require("./getInstanceName.js")(config),
|
|
})
|