TMDevelopmentTinulica & Maiky

Developer API

Developer API

1.0.22+ · package dev.tmdevelopment.flarereferrals.api · add FlareReferrals to softdepend in your plugin.yml.

int invites = FlareReferralsAPI.getInvites(player.getUniqueId());
UUID inviter = FlareReferralsAPI.getInviter(player.getUniqueId());   // null = nobody
boolean waiting = FlareReferralsAPI.isPending(player.getUniqueId()); // waits for the playtime check
List<FlareReferralsAPI.TopEntry> top = FlareReferralsAPI.getTop(10);
EventWhen
ReferralEventa player writes /referrals <inviter> and the checks passed, before the invite is saved. Cancellable: FlareReferrals then sends nothing, tell the player why yourself
ReferralCompleteEventthe invite counts (right away or after the playtime check). getPlayer(), getInviter(), getInviterName(), getInvites()
@EventHandler
public void onInvite(ReferralCompleteEvent e) {
    if (e.getInvites() == 50) Bukkit.broadcastMessage(e.getInviterName() + " invited 50 players!");
}

Everything runs on the main thread. On a network the events are called on the server where the player wrote the command.

Ultimo aggiornamento:

Accedi

Nuovo? Scrivi solo la tua email: l'account nasce quando clicchi il link. Nessuna password.

oppure

Ti mandiamo un link che ti fa entrare con un clic. Vale per account nuovi ed esistenti.

Entra con la password

Continuando accetti i Termini e condizioni e la Privacy policy.

Staff: apri “Entra con la password” e scrivi il tuo nome utente al posto dell’email. Dopo la password ti chiediamo il codice 2FA.