-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy path[proc,create_v2_stone_button_filled_free].cs2
48 lines (48 loc) · 3.96 KB
/
[proc,create_v2_stone_button_filled_free].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
// 2974
[proc,create_v2_stone_button_filled_free](component $component0, int $int1, int $int2, int $int3, int $int4, int $int5, string $text0, int $colour6, int $colour7, int $int8, int $int9)(int)
def_int $int10 = 0;
def_int $x11 = calc($int2 - 9 + $int4);
def_int $y12 = calc($int3 - 9 + $int5);
def_int $width13 = calc($int2 - 18);
def_int $height14 = calc($int3 - 18);
if ($int9 = 0) {
~create_graphic($component0, $int1, tradebacking, $int4, $int5, ^setpos_abs_left, ^setpos_abs_top, $int2, $int3, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 1), "v2_stone_button,0", $int4, $int5, ^setpos_abs_left, ^setpos_abs_top, 9, 9, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 2), "v2_stone_button,1", $x11, $int5, ^setpos_abs_left, ^setpos_abs_top, 9, 9, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 3), "v2_stone_button,2", $int4, $y12, ^setpos_abs_left, ^setpos_abs_top, 9, 9, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 4), "v2_stone_button,3", $x11, $y12, ^setpos_abs_left, ^setpos_abs_top, 9, 9, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 5), "v2_stone_button,4", $int4, calc(9 + $int5), ^setpos_abs_left, ^setpos_abs_top, 9, $height14, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 6), "v2_stone_button,5", calc($int4 + 9), $int5, ^setpos_abs_left, ^setpos_abs_top, $width13, 9, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 7), "v2_stone_button,6", $x11, calc(9 + $int5), ^setpos_abs_left, ^setpos_abs_top, 9, $height14, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 8), "v2_stone_button,7", calc($int4 + 9), $y12, ^setpos_abs_left, ^setpos_abs_top, $width13, 9, ^setsize_abs, ^setsize_abs);
} else {
~create_graphic($component0, $int1, tradebacking_dark, $int4, $int5, ^setpos_abs_left, ^setpos_abs_top, $int2, $int3, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 1), "v2_stone_button_in,0", $int4, $int5, ^setpos_abs_left, ^setpos_abs_top, 9, 9, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 2), "v2_stone_button_in,1", $x11, $int5, ^setpos_abs_left, ^setpos_abs_top, 9, 9, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 3), "v2_stone_button_in,2", $int4, $y12, ^setpos_abs_left, ^setpos_abs_top, 9, 9, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 4), "v2_stone_button_in,3", $x11, $y12, ^setpos_abs_left, ^setpos_abs_top, 9, 9, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 5), "v2_stone_button_in,4", $int4, calc(9 + $int5), ^setpos_abs_left, ^setpos_abs_top, 9, $height14, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 6), "v2_stone_button_in,5", calc(9 + $int4), $int5, ^setpos_abs_left, ^setpos_abs_top, $width13, 9, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 7), "v2_stone_button_in,6", $x11, calc(9 + $int5), ^setpos_abs_left, ^setpos_abs_top, 9, $height14, ^setsize_abs, ^setsize_abs);
~create_graphic($component0, calc($int1 + 8), "v2_stone_button_in,7", calc($int4 + 9), $y12, ^setpos_abs_left, ^setpos_abs_top, $width13, 9, ^setsize_abs, ^setsize_abs);
}
cc_create($component0, ^iftype_text, calc($int1 + 9));
cc_setsize(calc($int2 - 6), calc($int3 - 6), ^setsize_abs, ^setsize_abs);
cc_setposition(calc(3 + $int4), calc(3 + $int5), ^setpos_abs_left, ^setpos_abs_top);
cc_settext($text0);
cc_settextfont(p12_full);
cc_settextshadow(true);
cc_setcolour($colour6);
if ($int8 ! 0) {
cc_setop(1, "Show task: <col=ff9040><$text0>");
}
cc_settextalign(^settextalign_centre, ^settextalign_centre, 20);
if ($int9 = 0) {
if (~on_mobile = true) {
cc_setonmouseover("v2_stone_button_in_filled_free($component0, $int1, $colour6)");
} else {
cc_setonmouseover("v2_stone_button_in_filled_free($component0, $int1, $colour7)");
}
cc_setonmouseleave("v2_stone_button_filled_free($component0, $int1, $colour6)");
}
return(calc($int1 + 10));