-
Notifications
You must be signed in to change notification settings - Fork 0
/
README.txt
61 lines (39 loc) · 1.43 KB
/
README.txt
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
-----------------------------
INTRO
-----------------------------
The extensions framework lets you import Flash libraries (SWF) and use them inside of your games. The most common use case is to import a sponsor's API into a Stencyl game.
-----------------------------
CONVERTING A SWC TO A SWF
-----------------------------
Stencyl only recognizes SWFs. If you have a SWC, follow these steps to extract the SWF from it.
1) Rename the SWC's extension to ZIP.
2) Unzip the file.
3) Inside will be the SWF.
-----------------------------
HOW TO MAKE A FLASH EXTENSION
-----------------------------
1) Make a new folder under plaf/haxe/extensions/
2) It must contain these 5 files.
include.nmml (leave as-is)
<?xml version="1.0" encoding="utf-8"?>
<project>
<haxeflag name="-swf-lib" value="library.swf" if="flash"/>
</project>
blocks.xml (leave as-is)
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<palette>
</palette>
info.txt (edit the details to fit your case)
name=Test Extension (Flash SWF)
description=A test extension for Flash
author=Jon
website=http://www.stencyl.com
version=1.0
compatibility=flash
icon.png - 32 x 32 icon
library.swf - the SWF library you want to import. If it's a SWC, follow the instructions above.
2) Enable the extension inside of Stencyl
* Open game, click 'Settings'
* Flip to the Extensions page and click Enable
* Reopen the game
3) Now, you can call the code inside the SWF through code blocks.