mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-14 07:24:52 +09:00
Rename Slave to Host
The role of a slave as a host for Factorio servers is not well reflected in its name and has caused confusion among users. Rename slave to host to better reflect its role as a host of Factorio servers.
This commit is contained in:
1 parent
70ad295a89
commit
6fc3abafd5
101 files changed
+1168
-1168
No files matched your search
@@ -59,7 +59,7 @@ class ControllerPlugin extends libPlugin.BaseControllerPlugin {
|
||||
|
||||
this.lastProgressBroadcast = Date.now();
|
||||
if (techs.length) {
|
||||
this.broadcastEventToSlaves(this.info.messages.progress, { technologies: techs });
|
||||
this.broadcastEventToHosts(this.info.messages.progress, { technologies: techs });
|
||||
}
|
||||
}
|
||||
|
||||
@@ -97,7 +97,7 @@ class ControllerPlugin extends libPlugin.BaseControllerPlugin {
|
||||
tech.progress = null;
|
||||
this.progressToBroadcast.delete(name);
|
||||
|
||||
this.broadcastEventToSlaves(this.info.messages.finished, { name, level: tech.level });
|
||||
this.broadcastEventToHosts(this.info.messages.finished, { name, level: tech.level });
|
||||
}
|
||||
}
|
||||
|
||||
@@ -127,7 +127,7 @@ class ControllerPlugin extends libPlugin.BaseControllerPlugin {
|
||||
if (progress) {
|
||||
this.progressToBroadcast.add(name);
|
||||
} else if (researched || baseLevel(name) !== level) {
|
||||
this.broadcastEventToSlaves(this.info.messages.finished, { name, level });
|
||||
this.broadcastEventToHosts(this.info.messages.finished, { name, level });
|
||||
}
|
||||
|
||||
} else {
|
||||
@@ -138,7 +138,7 @@ class ControllerPlugin extends libPlugin.BaseControllerPlugin {
|
||||
if (tech.level < level || researched) {
|
||||
// Send update if the unlocked level is greater
|
||||
if (level - !researched > tech.level - !tech.researched) {
|
||||
this.broadcastEventToSlaves(this.info.messages.finished, { name, level: level - !researched });
|
||||
this.broadcastEventToHosts(this.info.messages.finished, { name, level: level - !researched });
|
||||
}
|
||||
tech.level = level;
|
||||
tech.progress = progress;
|
||||
|
||||
Reference in new issue
Block a user