-
Notifications
You must be signed in to change notification settings - Fork 11
/
[clientscript,objbox_setbuttons].cs2
62 lines (62 loc) · 2.76 KB
/
[clientscript,objbox_setbuttons].cs2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
// 2868
[clientscript,objbox_setbuttons](string $string0)
cc_deleteall(interface_193:0);
if_setonclick(null, interface_193:0);
if (string_length($string0) <= 0) {
return;
}
cc_create(interface_193:0, ^iftype_rectangle, 0);
cc_sethide(true);
cc_create(interface_193:0, ^iftype_rectangle, 1);
cc_sethide(true);
cc_create(interface_193:0, ^iftype_text, 2);
cc_sethide(false);
cc_setposition(96, 0, ^setpos_abs_left, ^setpos_abs_bottom);
cc_settextshadow(false);
cc_settextalign(^settextalign_centre, ^settextalign_bottom, 0);
cc_settextfont(q8_full);
def_string $string1 = "";
def_component $component0 = null;
def_string $op2 = "";
$op2, $string0 = ~script632($string0);
if (string_length($string0) <= 0) {
cc_setsize(380, 78, ^setsize_abs, ^setsize_minus);
cc_setcolour(^blue);
cc_setonmouseover("cc_colour_swapper(event_com, event_comsubid, ^white)");
cc_setonmouseleave("cc_colour_swapper(event_com, event_comsubid, ^blue)");
cc_settext($op2);
if (~on_mobile = true) {
$component0 = interface_193:0;
}
cc_setop(1, "Continue");
cc_setonop("objbox_listener(true, null, null, ^key_space, $string1, event_com, event_comsubid, 0, $op2, $component0, 0)");
cc_setonkey("objbox_listener(false, event_key, event_keychar, ^key_space, $string1, event_com, event_comsubid, 0, $op2, $component0, 0)");
if ($component0 ! null) {
if_setonclick("objbox_listener(true, null, null, ^key_space, $string1, event_com, cc_getid, 0, $op2, $component0, 0)", $component0);
}
} else {
.cc_create(interface_193:0, ^iftype_text, 3);
.cc_sethide(false);
.cc_setposition(286, 0, ^setpos_abs_left, ^setpos_abs_bottom);
.cc_settextshadow(false);
.cc_settextalign(^settextalign_centre, ^settextalign_bottom, 0);
cc_setcolour(0x7f0000);
.cc_setcolour(^blue);
cc_setonmouseover("cc_colour_swapper(event_com, event_comsubid, ^white)");
.cc_setonmouseover("cc_colour_swapper(event_com, event_comsubid, ^white)");
cc_setonmouseleave("cc_colour_swapper(event_com, event_comsubid, 0x7f0000)");
.cc_setonmouseleave("cc_colour_swapper(event_com, event_comsubid, ^blue)");
.cc_settextfont(q8_full);
cc_setsize(190, 78, ^setsize_abs, ^setsize_minus);
.cc_setsize(190, 78, ^setsize_abs, ^setsize_minus);
cc_settext($op2);
.cc_settext($string0);
cc_setop(1, $op2);
.cc_setop(1, $string0);
$string1 = "1";
cc_setonop("objbox_listener(true, null, null, ^key_escape, $string1, event_com, event_comsubid, 0, $op2, null, 0)");
cc_setonkey("objbox_listener(false, event_key, event_keychar, ^key_escape, $string1, event_com, event_comsubid, 0, $op2, null, 0)");
$string1 = "2";
.cc_setonop("objbox_listener(true, null, null, ^key_space, $string1, event_com, event_comsubid, 1, $string0, null, 0)");
.cc_setonkey("objbox_listener(false, event_key, event_keychar, ^key_space, $string1, event_com, event_comsubid, 1, $string0, null, 0)");
}