On Network Join
Description
Fires when a player joins the network, on the first server the proxy sends them to. Every later move to another server is a server switch.
It is a player trigger: it runs on the joining player in MythicCrucible item skills, and the events.network-join list of the Paper config runs skills for it. It never runs on mobs. It waits until the player's data has loaded, see Missed Events. Skill Variables lists the variables it sets.
If the first server does not run MythicProxy, nothing fires there, and the player's next move counts as a switch.
This trigger requires MythicMobs Premium!
Examples
Needs MythicCrucible. The helmet greets the player with the name of the server they joined, while they wear or hold it. In an item file:
TravelerHelmet:
Id: LEATHER_HELMET
Display: 'Traveler Helmet'
Skills:
- message{m="Welcome to <skill.var.server>"} @self ~onNetworkJoin
Counts the player's logins, without MythicCrucible. In a skill file:
LoginCounter:
Skills:
- networkVariableAdd{var=logins;scope=caster;amount=1} @self
- message{m="Login number <caster.netvar.logins> on <skill.var.server>"} @self
List it in the backend config.yml:
events:
network-join:
- LoginCounter
Aliases
- onProxyJoin
- onNetwork_Join