stamps.r3cp3ct-Japanese-sticker-triggers
parent
c035f052d6
commit
cedfcf0974
@ -0,0 +1,76 @@ |
||||
# |
||||
#Properties file for sigIRCv2 |
||||
#Thu Sep 13 20:34:27 CDT 2018 |
||||
Auto_Update_Program=1 |
||||
Automatically_Update_Program=false |
||||
BANDORI_module_X=76 |
||||
BANDORI_module_Y=307 |
||||
BANDORI_module_height=120 |
||||
BANDORI_module_width=640 |
||||
CHATLOG_module_BackgroundColor=195,195,195,255 |
||||
CHATLOG_module_MessageHistory=50 |
||||
CHATLOG_module_X=1042 |
||||
CHATLOG_module_Y=388 |
||||
CHATLOG_module_height=518 |
||||
CHATLOG_module_width=516 |
||||
CONTROLLER_module_X=46 |
||||
CONTROLLER_module_Y=272 |
||||
CONTROLLER_module_height=312 |
||||
CONTROLLER_module_width=320 |
||||
Disable_Chat_Messages=false |
||||
Max_FPS=30 |
||||
Module_bandori_Enabled=false |
||||
Module_chatlog_Enabled=false |
||||
Module_controller_Enabled=false |
||||
Module_rabirace_Enabled=false |
||||
Module_rabiribi_Enabled=false |
||||
Module_touhoumother_Enabled=false |
||||
Module_twitch_Enabled=false |
||||
RABIRACE_module_X=492 |
||||
RABIRACE_module_Y=226 |
||||
RABIRACE_module_height=561 |
||||
RABIRACE_module_width=481 |
||||
RABIRIBI_module_X=0 |
||||
RABIRIBI_module_Y=0 |
||||
RABIRIBI_module_height=1050 |
||||
RABIRIBI_module_width=1680 |
||||
SCROLLINGCHAT_module_X=1016 |
||||
SCROLLINGCHAT_module_Y=223 |
||||
SCROLLINGCHAT_module_height=132 |
||||
SCROLLINGCHAT_module_width=456 |
||||
TOUHOUMOTHER_module_X=0 |
||||
TOUHOUMOTHER_module_Y=312 |
||||
TOUHOUMOTHER_module_height=312 |
||||
TOUHOUMOTHER_module_width=320 |
||||
TWITCH_module_X=507 |
||||
TWITCH_module_Y=366 |
||||
TWITCH_module_followerText_Y=42 |
||||
TWITCH_module_followerText_centerX=292 |
||||
TWITCH_module_follower_img=sigIRC/glaceon_follower.png |
||||
TWITCH_module_follower_img_animation=true |
||||
TWITCH_module_height=200 |
||||
TWITCH_module_newFollowerImgBackgroundColor=90,90,90 |
||||
TWITCH_module_newFollowerImgLogoSize=32 |
||||
TWITCH_module_newFollowerShadowTextColor=26,90,150 |
||||
TWITCH_module_newFollowerTextColor=255,255,255 |
||||
TWITCH_module_width=500 |
||||
Testing_Mode=false |
||||
backgroundColor=-10066177 |
||||
channel=\#SigoNitori |
||||
chatRows=3 |
||||
chatScrollSpd=4 |
||||
dingThreshold=6 |
||||
hardware_acceleration=true |
||||
lastSubEmote_APIUpdate=331 |
||||
messageFont=Gill Sans Ultra Bold Condensed |
||||
nickname=SigoNitori |
||||
overlayMode=false |
||||
rowSpacing=64 |
||||
server=irc.chat.twitch.tv |
||||
showWindowControls=true |
||||
touhoumotherConsoleFont=Agency FB Bold |
||||
usernameFont=Segoe UI Semibold |
||||
windowHeight=632 |
||||
windowWidth=1212 |
||||
windowX=442 |
||||
windowY=205 |
Binary file not shown.
@ -0,0 +1,225 @@ |
||||
package sig.modules; |
||||
|
||||
import java.awt.Graphics; |
||||
import java.awt.event.WindowEvent; |
||||
import java.awt.geom.Rectangle2D; |
||||
import java.awt.image.BufferedImage; |
||||
import java.io.File; |
||||
import java.io.IOException; |
||||
import java.util.ArrayList; |
||||
import java.util.Arrays; |
||||
import java.util.HashMap; |
||||
import java.util.List; |
||||
|
||||
import javax.imageio.ImageIO; |
||||
|
||||
import sig.FileManager; |
||||
import sig.Module; |
||||
import sig.sigIRC; |
||||
import sig.utils.SoundUtils; |
||||
|
||||
public class BandoriModule extends Module{ |
||||
public static BandoriModule bandori_module; |
||||
public BufferedImage stamp_collection1,stamp_collection2; |
||||
public static HashMap<String,ImageScheme> image_map = new HashMap<String,ImageScheme>(); |
||||
public static HashMap<String,List<String>> stamp_map = new HashMap<String,List<String>>(); |
||||
static List<Stamp> active_stamps = new ArrayList<Stamp>(); |
||||
|
||||
public BandoriModule(Rectangle2D bounds, String moduleName) { |
||||
this(bounds,moduleName,true); |
||||
} |
||||
|
||||
public BandoriModule(Rectangle2D bounds, String moduleName, boolean enabled) { |
||||
super(bounds, moduleName, enabled); |
||||
Initialize(); |
||||
} |
||||
|
||||
void Initialize() { |
||||
BandoriModule.bandori_module = this; |
||||
try { |
||||
stamp_collection1 = ImageIO.read(new File(sigIRC.BASEDIR+"sigIRC/stamps1.png")); |
||||
stamp_collection2 = ImageIO.read(new File(sigIRC.BASEDIR+"sigIRC/stamps2.png")); |
||||
} catch (IOException e) { |
||||
e.printStackTrace(); |
||||
} |
||||
image_map.put("kasumi_gogo", new ImageScheme(stamp_collection1,0)); |
||||
image_map.put("tae_letsplay", new ImageScheme(stamp_collection1,1)); |
||||
image_map.put("rimi_choco", new ImageScheme(stamp_collection1,2)); |
||||
image_map.put("saya_bread", new ImageScheme(stamp_collection1,3)); |
||||
image_map.put("arisa_doki", new ImageScheme(stamp_collection1,4)); |
||||
image_map.put("ran_same", new ImageScheme(stamp_collection1,5)); |
||||
image_map.put("moca_youdidit", new ImageScheme(stamp_collection1,6)); |
||||
image_map.put("himari_heyheyhoh", new ImageScheme(stamp_collection1,7)); |
||||
image_map.put("tomoe_letsdothis", new ImageScheme(stamp_collection1,8)); |
||||
image_map.put("tsugumi_wecandoit", new ImageScheme(stamp_collection1,9)); |
||||
image_map.put("kokoro_happylucky", new ImageScheme(stamp_collection1,10)); |
||||
image_map.put("kaoru_fleeting", new ImageScheme(stamp_collection1,11)); |
||||
image_map.put("hagumi_smileyay", new ImageScheme(stamp_collection1,12)); |
||||
image_map.put("kanon_fuee", new ImageScheme(stamp_collection1,13)); |
||||
image_map.put("misaki_ready", new ImageScheme(stamp_collection1,14)); |
||||
image_map.put("aya_fever", new ImageScheme(stamp_collection1,15)); |
||||
image_map.put("hina_fullcombo", new ImageScheme(stamp_collection1,16)); |
||||
image_map.put("chisato_planned", new ImageScheme(stamp_collection1,17)); |
||||
image_map.put("maya_huhehe", new ImageScheme(stamp_collection1,18)); |
||||
image_map.put("eve_bushido", new ImageScheme(stamp_collection1,19)); |
||||
image_map.put("yukina_notbad", new ImageScheme(stamp_collection1,20)); |
||||
image_map.put("sayo_goodwork", new ImageScheme(stamp_collection1,21)); |
||||
image_map.put("lisa_nextonelastone", new ImageScheme(stamp_collection1,22)); |
||||
image_map.put("ako_onemoretime", new ImageScheme(stamp_collection1,23)); |
||||
image_map.put("rinko_jam", new ImageScheme(stamp_collection2,0)); |
||||
image_map.put("marina_yeahyeah", new ImageScheme(stamp_collection2,1)); //Skip 2.
|
||||
image_map.put("kokoro_moremore", new ImageScheme(stamp_collection2,3)); |
||||
image_map.put("arisa_huh", new ImageScheme(stamp_collection2,4)); |
||||
image_map.put("yukina_followmylead", new ImageScheme(stamp_collection2,5)); |
||||
image_map.put("kaoru_suchalovelyevening", new ImageScheme(stamp_collection2,6)); |
||||
image_map.put("rimi_congrats", new ImageScheme(stamp_collection2,7)); |
||||
image_map.put("ran_somethingbigiscoming", new ImageScheme(stamp_collection2,8)); |
||||
image_map.put("tsugumi_comeon", new ImageScheme(stamp_collection2,9)); |
||||
image_map.put("tae_fufusocute", new ImageScheme(stamp_collection2,10)); |
||||
image_map.put("eve_marchintobattle", new ImageScheme(stamp_collection2,11)); |
||||
image_map.put("saya_illtry", new ImageScheme(stamp_collection2,12)); |
||||
image_map.put("lisa_imsohappy", new ImageScheme(stamp_collection2,13)); |
||||
image_map.put("sayo_ohwell", new ImageScheme(stamp_collection2,14)); |
||||
image_map.put("ako_areyouokay", new ImageScheme(stamp_collection2,15)); |
||||
image_map.put("chisato_thisissomuchfun", new ImageScheme(stamp_collection2,16)); |
||||
image_map.put("rinko_theresnoway", new ImageScheme(stamp_collection2,17)); |
||||
image_map.put("tae_thisisgreat", new ImageScheme(stamp_collection2,18)); |
||||
image_map.put("moca_thisisgettinginteresting", new ImageScheme(stamp_collection2,19)); |
||||
image_map.put("kaoru_takemyhand", new ImageScheme(stamp_collection2,20)); |
||||
image_map.put("kokoro_letsmaketheworldsmile", new ImageScheme(stamp_collection2,21)); |
||||
|
||||
stamp_map.put("kasumi_gogo",Arrays.asList("gogo")); |
||||
stamp_map.put("tae_letsplay",Arrays.asList("playtogether","wanttoplay","multilive","letsplay")); |
||||
stamp_map.put("rimi_choco",Arrays.asList("choco","cornet")); |
||||
stamp_map.put("saya_bread",Arrays.asList("bread")); |
||||
stamp_map.put("arisa_doki",Arrays.asList("doki")); |
||||
stamp_map.put("ran_same",Arrays.asList("sameasalways","alwayssame","alwaysthesame")); |
||||
stamp_map.put("moca_youdidit",Arrays.asList("youdidit","congratulations","buns")); |
||||
stamp_map.put("himari_heyheyhoh",Arrays.asList("heyo","heyheyhoh","heyhey","hihi")); |
||||
stamp_map.put("tomoe_letsdothis",Arrays.asList("letsdothis","letsdoit")); |
||||
stamp_map.put("tsugumi_wecandoit",Arrays.asList("wegotthis","wegotit","wecan")); |
||||
stamp_map.put("kokoro_happylucky",Arrays.asList("happy!","lucky")); |
||||
stamp_map.put("kaoru_fleeting",Arrays.asList("fleeting")); |
||||
stamp_map.put("hagumi_smileyay",Arrays.asList("smileyay","yay")); |
||||
stamp_map.put("kanon_fuee",Arrays.asList("fuee","waa","ree")); |
||||
stamp_map.put("misaki_ready",Arrays.asList("amready","beenready","ready!")); |
||||
stamp_map.put("aya_fever",Arrays.asList("fever")); |
||||
stamp_map.put("hina_fullcombo",Arrays.asList("fc","fullcombo","nomiss","allperfect","notasinglemiss")); |
||||
stamp_map.put("chisato_planned",Arrays.asList("justasplanned","allplanned","calculated","thatcoming")); |
||||
stamp_map.put("maya_huhehe",Arrays.asList("hehe","huehe","huehue")); |
||||
stamp_map.put("eve_bushido",Arrays.asList("bushido")); |
||||
stamp_map.put("yukina_notbad",Arrays.asList("notbad","veryclose")); |
||||
stamp_map.put("sayo_goodwork",Arrays.asList("goodwork","goodjob","nicejob","welldone","greatwork","greatjob")); |
||||
stamp_map.put("lisa_nextonelastone",Arrays.asList("lastone","mylast")); |
||||
stamp_map.put("ako_onemoretime",Arrays.asList("onemore","goagain","keepgoing","dontstop")); |
||||
stamp_map.put("rinko_jam",Arrays.asList("lovethissong","jam")); |
||||
stamp_map.put("marina_yeahyeah",Arrays.asList("yeahyeah","letsgo")); |
||||
stamp_map.put("kokoro_moremore",Arrays.asList("moremore","iwantmore")); |
||||
stamp_map.put("arisa_huh",Arrays.asList("huh?","hh?","yy?","aat?","aa?","tt?","nani","nand")); |
||||
stamp_map.put("yukina_followmylead",Arrays.asList("followmylead","takethelead","guideyou")); |
||||
stamp_map.put("kaoru_suchalovelyevening",Arrays.asList("goodevening","lovelyevening","beautifulnight","grandnight","wonderfulevening")); |
||||
stamp_map.put("rimi_congrats",Arrays.asList("grats")); |
||||
stamp_map.put("ran_somethingbigiscoming",Arrays.asList("somethingbig","iscoming")); |
||||
stamp_map.put("tsugumi_comeon",Arrays.asList("comeon","dontbeafraid","dontbeshy")); |
||||
stamp_map.put("tae_fufusocute",Arrays.asList("socute","kawaii","fufu","adorable","cute")); |
||||
stamp_map.put("eve_marchintobattle",Arrays.asList("marchintobattle","chargeintobattle")); |
||||
stamp_map.put("saya_illtry",Arrays.asList("illtry","itachance","itatry","atleastonce")); |
||||
stamp_map.put("lisa_imsohappy",Arrays.asList("ecstatic","sohappy","toohappy")); |
||||
stamp_map.put("sayo_ohwell",Arrays.asList("ohwell","ahwell","youtried")); |
||||
stamp_map.put("ako_areyouokay",Arrays.asList("youok","beok","daijou")); |
||||
stamp_map.put("chisato_thisissomuchfun",Arrays.asList("muchfun","veryfun","reallyfun","extremelyfun","offun")); |
||||
stamp_map.put("rinko_theresnoway",Arrays.asList("noway")); |
||||
stamp_map.put("tae_thisisgreat",Arrays.asList("thisisgreat","thisisawesome","thisiswonderful")); |
||||
stamp_map.put("moca_thisisgettinginteresting",Arrays.asList("gettinginteresting","thingsaregetting","thisisgetting")); |
||||
stamp_map.put("kaoru_takemyhand",Arrays.asList("takemyhand","allowmeto","demonstrate","romeo")); |
||||
stamp_map.put("kokoro_letsmaketheworldsmile",Arrays.asList("hhw","happyworld","hellohappy","worldsmile")); |
||||
} |
||||
|
||||
public void run() { |
||||
for (int i=0;i<active_stamps.size();i++) { |
||||
Stamp s = active_stamps.get(i); |
||||
if (!s.run()) { |
||||
active_stamps.remove(i--); |
||||
} |
||||
} |
||||
} |
||||
|
||||
public static void checkForStamp(String user,String message) { |
||||
boolean foundmatch = false; |
||||
message = message.toLowerCase().replaceAll("[ ]", ""); |
||||
for (String key : image_map.keySet()) { |
||||
for (String message_search : stamp_map.get(key)) { |
||||
String filteredmessage = message; |
||||
filteredmessage = filteredmessage.replaceAll("[^A-Za-z0-9]",""); |
||||
//System.out.println(filteredmessage);
|
||||
if (message_search.contains("?") || message_search.contains("!")) { |
||||
if (message.contains(message_search)) { |
||||
foundmatch = true; |
||||
CreateStamp(key); |
||||
break; |
||||
} |
||||
} else { |
||||
if (filteredmessage.contains(message_search)) { |
||||
foundmatch=true; |
||||
CreateStamp(key); |
||||
break; |
||||
} |
||||
} |
||||
} |
||||
if (foundmatch) { |
||||
break; |
||||
} |
||||
} |
||||
} |
||||
|
||||
public static void CreateStamp(String stamp_name) { |
||||
final int STAMP_DURATION = 180; |
||||
String soundName = sigIRC.BASEDIR+"sigIRC/sounds/stamp_sound.wav"; |
||||
FileManager manager = new FileManager("sigIRC/sounds/stamp_sound.wav"); |
||||
manager.verifyAndFetchFileFromServer(); |
||||
SoundUtils.playSound(soundName); |
||||
active_stamps.add(new Stamp(image_map.get(stamp_name),STAMP_DURATION)); |
||||
} |
||||
|
||||
public void ApplyConfigWindowProperties() { |
||||
sigIRC.bandorimodule_X=(int)position.getX(); |
||||
sigIRC.bandorimodule_Y=(int)position.getY(); |
||||
sigIRC.config.setInteger("BANDORI_module_X", sigIRC.bandorimodule_X); |
||||
sigIRC.config.setInteger("BANDORI_module_Y", sigIRC.bandorimodule_Y); |
||||
} |
||||
|
||||
public void windowClosed(WindowEvent ev) { |
||||
|
||||
} |
||||
|
||||
public void draw(Graphics g) { |
||||
super.draw(g); |
||||
for (Stamp s : active_stamps) { |
||||
//Stamp is 130x107 pixels
|
||||
g.drawImage(s.scheme.base, (int)(s.randX+position.getX()), (int)position.getY()+24, (int)(s.randX+130+position.getX()), (int)position.getY()+24+107, |
||||
s.scheme.stamp_index%6*270+4, s.scheme.stamp_index/6*223+3, s.scheme.stamp_index%6*270+260+4, s.scheme.stamp_index/6*223+214+3, sigIRC.panel); |
||||
} |
||||
} |
||||
} |
||||
|
||||
class Stamp{ |
||||
ImageScheme scheme; |
||||
int timer; |
||||
int randX = (int)(Math.random()*(BandoriModule.bandori_module.position.getWidth()-130)); |
||||
Stamp(ImageScheme scheme,int start_timer) { |
||||
this.scheme = scheme; |
||||
this.timer = start_timer; |
||||
} |
||||
public boolean run() { |
||||
return --timer>0; |
||||
} |
||||
} |
||||
|
||||
class ImageScheme{ |
||||
BufferedImage base; |
||||
int stamp_index; //0-23.
|
||||
ImageScheme(BufferedImage base,int index) { |
||||
this.base=base; |
||||
this.stamp_index=index; |
||||
} |
||||
} |
@ -1,86 +1,18 @@ |
||||
SigoNitori |
||||
25 |
||||
8468886 |
||||
41 |
||||
41 |
||||
31 |
||||
25 |
||||
37 |
||||
60 |
||||
0 |
||||
0 |
||||
0 |
||||
0 |
||||
0 |
||||
0 |
||||
0 |
||||
false |
||||
5 |
||||
4 |
||||
100.0 |
||||
95.51538 |
||||
1527990500 |
||||
0 |
||||
0 |
||||
5.361208E-36 |
||||
4.8674998E-36 |
||||
1536205835 |
||||
KEYITEMS: |
||||
HAMMER;3 |
||||
CARROT_BOMB;3 |
||||
RIBBON;1 |
||||
SPEED_BOOST;3 |
||||
AUTO_EARRINGS;3 |
||||
RABI_SLIPPERS;1 |
||||
SUNNY_BEAM;1 |
||||
AIR_JUMP;1 |
||||
SLIDING_POWDER;3 |
||||
HOURGLASS;1 |
||||
BUNNY_WHIRL;3 |
||||
QUICK_BARRETTE;1 |
||||
HAMMER_WAVE;3 |
||||
HAMMER_ROLL;3 |
||||
LIGHT_ORB;3 |
||||
PLUS_NECKLACE;3 |
||||
EXPLODE_SHOT;1 |
||||
AIR_DASH;3 |
||||
BUNNY_STRIKE;3 |
||||
WALL_JUMP;3 |
||||
SPIKE_BARRIER;3 |
||||
BUNNY_AMULET;4 |
||||
SOUL_HEART;1 |
||||
BOOK_OF_CARROT;1 |
||||
CHAOS_ROD;1 |
||||
WATER_ORB;3 |
||||
FIRE_ORB;3 |
||||
NATURE_ORB;3 |
||||
P_HAIRPIN;3 |
||||
CYBER_FLOWER;1 |
||||
HEALING_STAFF;1 |
||||
MAX_BRACELET;1 |
||||
STRANGE_BOX;1 |
||||
CHARGE_RING;3 |
||||
CARROT_SHOOTER;1 |
||||
SUPER_CARROT;3 |
||||
BUNNY_CLOVER;1 |
||||
BADGES: |
||||
BADGE_HEALTH_PLUS;2 |
||||
BADGE_TOXIC_STRIKE;2 |
||||
BADGE_DEF_GROW;1 |
||||
BADGE_MANA_SURGE;2 |
||||
BADGE_DEF_TRADE;1 |
||||
BADGE_ARMORED;1 |
||||
BADGE_CASHBACK;1 |
||||
BADGE_SURVIVAL;2 |
||||
BADGE_HEALTH_SURGE;2 |
||||
BADGE_MANA_PLUS;2 |
||||
BADGE_CRISIS_BOOST;2 |
||||
BADGE_ATK_GROW;1 |
||||
BADGE_ATK_TRADE;2 |
||||
BADGE_ARM_STRENGTH;2 |
||||
BADGE_CARROT_BOOST;1 |
||||
BADGE_WEAKEN;1 |
||||
BADGE_SELF_DEFENSE;1 |
||||
BADGE_LUCKY_SEVEN;2 |
||||
BADGE_HEX_CANCEL;1 |
||||
BADGE_PURE_LOVE;2 |
||||
BADGE_FRAME_CANCEL;2 |
||||
BADGE_HEALTH_WAGER;2 |
||||
BADGE_MANA_WAGER;1 |
||||
BADGE_STAMINA_PLUS;2 |
||||
BADGE_BLESSED;2 |
||||
BADGE_HITBOX_DOWN;2 |
||||
BADGE_TOP_FORM;2 |
||||
BADGE_TOUGH_SKIN;2 |
||||
BADGE_ERINA_BADGE;2 |
||||
BADGE_RIBBON_BADGE;2 |
||||
BADGE_AUTO_TRIGGER;1 |
||||
UPDATES: |
Loading…
Reference in new issue