How to use CallFuncND in cocos2d for android -


i want call method thrice different parameters , need have delay between calling them,inorder want use cccallfuncnd,but unable implement in code, please me giving simple example of how call cccallfuncnd.

my code :

this.runaction(cccallfuncnd.action(this, "shift_sec", "1"));  public void shift_sec(string v) {     system.out.println("coming method. : "+v);           } 

i illustrate example:

cccallfuncnd.action(this, "hitcallback", data) 

here
this--> target i.e sender

"hitcallback"-------> string being called.

data -----------> object send

public void hitcallback(object sender,object data){         ccsprite hitspotsprite = (ccsprite)data;         hitspotsprite.removefromparentandcleanup(true);         hitspotsprite = null;     } 

in case shift_sec(string v){} being modified

shift_sec(object sender,object data){} 

Comments

Popular posts from this blog

ios - UICollectionView Self Sizing Cells with Auto Layout -

node.js - ldapjs - write after end error -

DOM Manipulation in Wordpress (and elsewhere) using php -