This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using System.Collections; | |
using System.Collections.Generic; | |
using System.IO; | |
public class LoadText { | |
// Resources/text/から指定のテキストファイルを改行区切りで読む | |
public List<string> loadTextFile(string textFileName){ | |
TextAsset textAsset = Resources.Load<TextAsset>("text/" + textFileName); | |
string[] strs = textAsset.text.Split ("\n" [0]); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
JNIEnv *pEnv; | |
jclass classId; | |
jmethodID methodId; | |
//~~~ | |
jboolean flg = (jboolean)pEnv->CallStaticBooleanMethod(classId , methodId); | |
//~~~ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// NativeUtil.cpp | |
#include "NativeUtil.h" | |
#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS) | |
#import <objc/runtime.h> | |
#import <Foundation/Foundation.h> | |
#import <UIKit/UIKit.h> | |
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 指定したカットシーンを再生 | |
AnimatorTimeline.Play("Take名"); | |
// 指定したカットシーンをループ再生 | |
AnimatorTimeline.Play("Take名", true); | |
// 再生中のカットシーンを止める | |
AnimatorTimeline.Stop(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_client->emit("event" , "aaaaa"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
unsigned char* buf = FileUtils::getInstance()->getFileDataFromZip( | |
path.c_str() , | |
zipFile.c_str(), | |
(ssize_t*)&size); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma strict | |
public var speed : float = 3; | |
private var direction : Vector3 = Vector3.zero; | |
private var playerController : CharacterController; | |
private var animator : Animator; | |
function Start() { | |
playerController = GetComponent( CharacterController ); | |
animator = GetComponentInChildren( Animator ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using System.Collections; | |
public class BallSetup : MonoBehaviour { | |
// Use this for initialization | |
void Start () { | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using System.Collections; | |
public class CreateStage : MonoBehaviour { | |
public GameObject gameObject; | |
// Use this for initialization | |
void Start () { | |
int countW = 5; | |
int countH = 5; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
animator.SetFloat("speed" , varticalMove); |