PIXI Snake game made in React Native with @flyskywhy/react-native-gcanvas
instead of expo-gl
๐พ The goal of this project is to create a simple Snake clone that could be used in any 'webgl' or '2d' context. The primary target being native iPhone and Android apps.
For now, SnakeRN is based on react-native-pixi@2 and [email protected]
, even actually SnakeRN can be based on pixi.js
@4
, @5
, @6
or @7
directly without react-native-pixi
as described in react-native-pixi@3, I just leave it to be a final example of react-native-pixi@2
.
npm install --legacy-peer-deps
npm run rn
to start react-native packager for development.
npm run rn-fresh
to reset-cache before start react-native packager for development.
npm run android
to generate android/app/build/outputs/apk/debug/app-debug.apk
for development.
npm run build-android
to generate android/app/build/outputs/apk/release/app-release.apk
for production.
npm run bundle-android
to android/app/build/outputs/bundle/release/app-release.aab
for production.
use Xcode.
npm run web
for development, then view it at http://localhost:3000 in web browser.
npm run web-fresh
to delete node_modules/.cache/* before npm run web
, it's useful if there is running strange bug unknow.
npm run build-web
to generate files in build/
for production to deploy to https://foo.bar.com/
, and can use npx [email protected] build
to simply test it at http://127.0.0.1:8080 in web browser.
npm run build-web-snakeRN
to generate files in build/
for production to deploy to https://foo.bar.com/snakeRN/
, e.g. https://flyskywhy.github.io/snakeRN/ .
Give it a ๐ if you found it helpful ๐๐