i'm new java , i'm trying create poll system using pircbot. far code this:
if (message.startswith("!poll")) { string polly = message.substring(6); string[] vote = polly.split(" "); string vote1 = vote[0]; string vote2 = vote[1]; }
which splits strings can type !poll "option1 option2" example , split vote1 = option1 , vote2 = option2.
i'm kind of lost here. heading in right direction creating voting system?
i figure i'd have separate statement follows.
if (message.equalsignorecase("!vote " + option1))
but i'm not sure go either.
Comments
Post a Comment