Category: MOBILE

MOBILE

UNITY FADE IN/OUT ANIMATION

For my 2D game I wanted to create a “hurt” effect. It should fade in with red color and then fade out back to transparent. All we need to do is to create an empty image and apply the 3-step animation for it. In my case I scaled the imaged for the side of the […]

thaiphan 
MOBILE

UNITY ADS MEDIATION: WHAT IS ZONE ID

If you want to use Unity Ads service as a mediation for rewarded ads, you should know you Project ID and Zone ID. So, let’s look how to find the Zone Id.   The answer is right here: UNITY ADS ZONE ID Zone ID is a name of an Ad in your Ads Dashboard. By default […]

thaiphan 
MOBILE

REACT NATIVE LOCALIZATION

Some React Native features may not be clear or easy to implement, but the localization is made really painless. For localization in React Native we will need to: install the react-native-localization library create an object with localized strings use this object instead of old hardcoded strings. That’s it. Now let’s go through it. INSTALL REACT-NATIVE-LOCALIZATION The simplest way […]

thaiphan 
MOBILE

FIXING UNITY | COMMANDINVOKATIONFAILURE: FAILED TO RE-PACKAGE RESOURCES

Suddenly I saw an error while building the apk-file for my Unity project, which said: CommandInvokationFailure: Failed to re-package resources. Let’s see how to fix that.  The full error message was: CommandInvokationFailure: Failed to re-package resources. See the Console for details. C:\workspace\soft\android-sdk\build-tools\24.0.0\aapt.exe package –auto-add-overlay -v -f -m -J gen -M AndroidManifest.xml -S “res” -I “C:/workspace/soft/android-sdk\platforms\android-23\android.jar” -F […]

thaiphan 
MOBILE

REACT NATIVE: NETWORK REQUEST FAILED FIX

In this post we will fix the Network request failed error in iOS simulator that is common for many React Native new-comers.   NOTE: this article is related to environment issue, but request may also fail because of badly configured ajax call. A lot of people that dives into React Native get stuck when trying to make a simple […]

thaiphan 
MOBILE

REACT NATIVE REMOVE ITEM FROM LISTVIEW.DATASOURCE

I must say, I spent a lot of time trying to understand how to properly remove an element from React Native ListView. But finally I figured out how.   The main problem was that after removing an item from datablob array I updated a dataSource object in component’s state and it behaved strange. It deleted the last item from […]

thaiphan 
MOBILE

REACT NATIVE HTTP GET JSON

In this section we will send HTTP GET-request in React Native application using fetch API and date.jsontest.com web-service.   React Native has an embedded fetch API that is a high-level wrapper for working with HTTP requests. It’s pretty straightforward and easy to use. Let’s look into example of getting JSON data with fetch() function. GET JSON DATA FROM HTTP IN […]

thaiphan 
MOBILE

REACT NATIVE SIMPLE NAVIGATION EXAMPLE

In this article we will take a look on React Native navigation handling example using Navigator component. A lot of code would be shown here, but I’ll try to make it all clear.   So, to make navigation work in React Native we will use the Navigator component. We also need to create 3 classes: the […]

thaiphan