Sunday, 14 December 2014
App Policies: 10.4 Back Button (WP)
For Example:
void Update () {
if (Input.GetKeyDown (KeyCode.Escape)) {
Application.LoadLevel("MainMenu");
}
}
OR
void Update () {
if (Input.GetKeyDown (KeyCode.Escape)) {
Application.Quit ();
}
}
Sunday, 9 November 2014
Use of undeclared identifier 'GL_BGRA_EXT'
Sehari sebelumnya, aplikasi tidak bermasalah, lalu aku update OS dan Xcodenya. Ketika aku buka aplikasinya kembali, ternyata eh ternyata muncul beberapa error xD, hadeuuuuh... Salah satunya ada error gini:
"Use of undeclared identifier 'GL_BGRA_EXT'"
Kemudian aku tanya mbah deh, xixixi, katanya:
" I fixed these by replacing GL_BGRA_EXT with GL_RGBA in both instances "
maksudnya; ganti "GL_BGRA_EXT" dengan "GL_RGBA "
Akhirnya... errorpun hilang,,, :D
Sumber:
http://forum.unity3d.com/threads/ios8-xcode6-compatibility.249533/
"Use of undeclared identifier 'GL_BGRA_EXT'"
Kemudian aku tanya mbah deh, xixixi, katanya:
" I fixed these by replacing GL_BGRA_EXT with GL_RGBA in both instances "
maksudnya; ganti "GL_BGRA_EXT" dengan "GL_RGBA "
Akhirnya... errorpun hilang,,, :D
Sumber:
http://forum.unity3d.com/threads/ios8-xcode6-compatibility.249533/
Memanggil Fungsi dari Gameobject Lain
GameObject go = GameObject.Find("somegameobjectname");
ScriptB other = (ScriptB) go.GetComponent(typeof(ScriptB));
other.DoSomething();
sumber:
http://answers.unity3d.com/questions/7555/how-do-i-call-a-function-in-another-gameobjects-sc.html
Memanggil Fungsi C# di Javascript
var myVar = GameObject.Find("Game Object Name");
myVar.SendMessage("Function Name");
Saturday, 1 November 2014
Unity 3d Game - Pendukung Belajar
- http://unity3d.com/learn
- Lynda - Advanced Unity 3D Game Programming[AKD])
Wednesday, 6 August 2014
Change the height and width of an image
Cara mengubah panjang dan lebar gambar :
Source code diatas adalah mengubah gambar dengan nama "Lighthouse.jpg", dimana ukuran sebenarnya : 4, jadi mempunya ukuran yang lebih kecil dari sebenarnya . Gambar yang telah di resize akan mempunyai nama "hasil.jpg".
1: QImage image1("./data/Lighthouse.jpg");
2: image1.scaled(image1.width()/4,image1.height()/4, Qt::IgnoreAspectRatio, Qt::FastTransformation).save("./data/hasil.jpg", 0, 100);
Source code diatas adalah mengubah gambar dengan nama "Lighthouse.jpg", dimana ukuran sebenarnya : 4, jadi mempunya ukuran yang lebih kecil dari sebenarnya . Gambar yang telah di resize akan mempunyai nama "hasil.jpg".
Subscribe to:
Posts
(
Atom
)