Skip to content

Commit b68481d

Browse files
author
Roberto De Ioris
authored
Update Android.md
1 parent 70d91b7 commit b68481d

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

docs/Android.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,25 @@ https://github.com/20tab/UnrealEnginePython/tree/master/android/python35
1212
Albeit the repository contains the files for python2.7, currently the only supported release is the 3.5.
1313

1414
Obviously you need UnrealEnginePython source distribution to rebuild the plugin for Android.
15+
16+
## The First Project
17+
18+
I am assuming your project is already deployable on Android and now you want to add a simple Python Component to one of its Character:
19+
20+
```python
21+
import unreal_engine as ue
22+
23+
class AutoJump:
24+
25+
def begin_play(self):
26+
self.timer = self.uobject.set_timer(3, self.jump, True)
27+
28+
def jump(self):
29+
self.uobject.get_owner().Jump()
30+
```
31+
32+
Once the script works in the editor you need to prepare your environment to be android-friendly.
33+
34+
The first step is configuring the packaging system to include the /Content/Scripts directory (where you have your python files, currently the one you created before for your Character):
35+
36+
![android_packaging](https://github.com/20tab/UnrealEnginePython/raw/master/docs/android_packaging.png)

0 commit comments

Comments
 (0)