Parcourir la source

started new special effects

SBird1337 il y a 7 ans
Parent
révision
be40998bf4

+ 2
- 2
src/include/assets/mug/mug_08.c Voir le fichier

@@ -8,7 +8,7 @@
8 8
 //	+ 16 tiles lz77 compressed
9 9
 //	Total size: 32 + 504 = 536
10 10
 //
11
-//	Time-stamp: 2017-05-08, 11:18:02
11
+//	Time-stamp: 2017-08-26, 17:30:27
12 12
 //	Exported by Cearn's GBA Image Transmogrifier, v0.8.6
13 13
 //	( http://www.coranac.com/projects/#grit )
14 14
 //
@@ -32,7 +32,7 @@ const unsigned int mug_08Tiles[126] __attribute__((aligned(4)))=
32 32
 	0x02A17700,0x42310000,0x0B011000,0x03208024,0x5589A412,0x006A86E6,0x9679A899,0x78798777,
33 33
 	0x78577700,0x7A897777,0x98770079,0x95977884,0x89009841,0x866ACE86,0x00566A98,0x99967788,
34 34
 	0x77797795,0x77778904,0x22009777,0x00819877,0x77795808,0x01A66897,0x0A9705E0,0x00770000,
35
-	0x74007774,0x04489700,0x012A8900,0x24880000,0x21480042,0x00590042,
35
+	0x74007774,0x04489700,0x012A8900,0x24880000,0x21480042,0x00000042,
36 36
 };
37 37
 
38 38
 const unsigned short mug_08Pal[16] __attribute__((aligned(4)))=

+ 1
- 1
src/include/assets/mug/mug_08.h Voir le fichier

@@ -8,7 +8,7 @@
8 8
 //	+ 16 tiles lz77 compressed
9 9
 //	Total size: 32 + 504 = 536
10 10
 //
11
-//	Time-stamp: 2017-05-08, 11:18:02
11
+//	Time-stamp: 2017-08-26, 17:30:27
12 12
 //	Exported by Cearn's GBA Image Transmogrifier, v0.8.6
13 13
 //	( http://www.coranac.com/projects/#grit )
14 14
 //

+ 29
- 0
src/specials/special_effects/crystal_fade.c Voir le fichier

@@ -0,0 +1,29 @@
1
+#include <pokeagb/pokeagb.h>
2
+
3
+void task_fade_flash(u8 id) {
4
+    switch (tasks[id].priv[1]) {
5
+    case 0:
6
+        fade_screen(0xFFFFFFFF, 5, 0, 16, tasks[id].priv[0]);
7
+        tasks[id].priv[1]++;
8
+        break;
9
+    case 1:
10
+        if (!pal_fade_control.active) {
11
+            fade_screen(0xFFFFFFFF, 5, 16, 0, tasks[id].priv[0]);
12
+            tasks[id].priv[1]++;
13
+        }
14
+        break;
15
+    case 2:
16
+        if(!pal_fade_control.active)
17
+        {
18
+            task_del(id);
19
+            scr
20
+        }
21
+        break;
22
+    }
23
+}
24
+
25
+void sp_crystal_fade(void) {
26
+    u16 color = var_8000;
27
+    u8 t_id = task_add(task_fade_flash);
28
+    tasks[t_id].priv[0] = color;
29
+}