SpigotEssentials-Survey

From Peirleitner.at Development

This module adds Surveys to your existing copy of SpigotEssentials.

Commands & Permissions

# Name Syntax Aliases Description Permissions Permission Pack Since Notes
001 /survey /survey <Question> /umfrage Create a new survey command.survey DONATOR 1.0.0 None
002 /yes /yes /ja Vote Yes on the current survey command.yes GENERAL 1.0.0 None
003 /no /no /nein Vote No on the current survey command.no GENERAL 1.0.0 None

Configuration

Key Default Value Description Since Type Notes
prefix &7[&cSurvey&7] &f The prefix used on sending messages 1.0.0 String None
send-prefix-with-messages true If the prefix should be attached to every message sent 1.0.0 boolean None
survey.time-between-surveys 5 Time in minutes to wait before a new survey can be created 1.0.0 Integer None
survey.time-to-vote 5 Time in minutes to vote 1.0.0 Integer None
survey.broadcast-message <Too long..> Messages that will be broadcast on Survey creation 1.0.0 List<String> None
survey.result-message <Too long..> Messages that will be broadcasted on Survey end 1.0.0 List<String> None

Developer

API

Survey

at.peirleitner.spigotessentials.survey.util.Survey.class

# Name Description Return Since Notes
001 id Identifier for this Survey Integer 1.0.0 None
002 creator Creator of this Survey UUID 1.0.0 None
003 question Question String String 1.0.0 None
004 voted All votes on this Survey HashMap<UUID, VoteResult> 1.0.0 None
005 created Timestamp of Survey creation Long 1.0.0 None

VoteResult

at.peirleitner.spigotessentials.survey.util.VoteResult.class

# Name Description Since Notes
001 YES Voted for Yes 1.0.0 None
002 NO Voted for No 1.0.0 None

SurveyResult

at.peirleitner.spigotessentials.survey.util.SurveyResult.class

# Name Description Since Notes
001 YES Survey ended with most votes beeing for Yes 1.0.0 None
002 NO Survey ended with most votes beeing for No 1.0.0 None
003 UNDECIDED The Survey was undecided 1.0.0 None

Events

# Name Description Cancellable Since Notes
001 SurveyCreateEvent Called when creating a new survey Yes 1.0.0 None
002 SurveyVoteEvent Called when voting on a survey Yes 1.0.0 VoteResult returns the value of the Vote (YES, NO)
003 SurveyEndEvent Called when the survey ends No 1.0.0 None