SilverMayCry Posted October 15, 2014 Posted October 15, 2014 how do i put the selection on my array here announce ""+strcharinfo(0)+": "+.Message$+"",bc_all,0; if i make an array like this of hex codes setarray .color$[0],"0xFF0000","0xFF4000","0xFF8000","0xFFBF00","0xFFFF00","0xBFFF00","0x80FF00","0x40FF00","0xFA5882","0x0101DF","0x7401DF"; set .@menu$,implode(.color$, ":"); set .@selection, select(.@menu$) -1; Quote
Winz Posted October 15, 2014 Posted October 15, 2014 (edited) wow it's such a complicated code.. If I were you, I probably will do something like this: set .@choice$,"0xFF0000","0xFF4000","0xFF8000","0xFFBF00","0xFFFF00","0xBFFF00","0x80FF00","0x40FF00","0xFA5882","0x0101DF","0x7401DF"; select .@choice$; explode(.@option$,.@choice$,":"); <then on the broadcast> announce ""+strcharinfo(0)+": "+.Message$+"",bc_all,.@option$[@menu-1]; reference: rathena.org/wiki/Select Edited October 15, 2014 by Winz Quote
SilverMayCry Posted October 16, 2014 Author Posted October 16, 2014 (edited) thanks man, figured it out i did it this way instead. setarray .@cname$[0],"Green","Red","Purple","Pink","Orange"; setarray .@color$[0],"0x33FF33","0xD20000","0xCC00FF","0xFF33CC","0xFF9900"; then i set menu for (set .@c, 0; .@c < getarraysize(.@cname$); set .@c, .@c + 1){ set .@menu_cname$[getarraysize(.@menu_cname$)], .@cname$[.@c]; set .@menu_index[getarraysize(.@menu_index)], .@c; set .@menu$, .@menu_cname$[0]; for (set .@c, 1; .@c < getarraysize(.@menu_cname$); set .@c, .@c + 1) { set .@menu$, .@menu$ + ":" + .@menu_cname$[.@c]; } set .@c, select(.@menu$) - 1; input .Message$; next; announce ""+strcharinfo(0)+": "+.Message$+"",bc_all,.@color$[.@c]; Edited October 16, 2014 by SilverMayCry Quote
Question
SilverMayCry
3 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.