public void addToStreamEx(Bundle stream, FRIENDDATALIST v) { stream.writeUint32((UInt32)v.Count); for (int i = 0; i < v.Count; ++i) { itemType.addToStreamEx(stream, v[i]); } ; }
//好友数据 public void friendListData(FRIENDDATALIST arg1) { int i = 1; foreach (var item in arg1) { GameObject prefab = Resources.Load <GameObject>("prefabs/rankItem"); GameObject friend = GameObject.Instantiate(prefab, Content) as GameObject; friend.GetComponent <rankItemControl>().initItemData(i, item.playerName, item.playerBean, item.status); i++; } }
public FRIENDDATALIST createFromStreamEx(MemoryStream stream) { UInt32 size = stream.readUint32(); FRIENDDATALIST datas = new FRIENDDATALIST(); while (size > 0) { --size; datas.Add(itemType.createFromStreamEx(stream)); } ; return(datas); }
//好友数据 public override void friendListData(FRIENDDATALIST arg1) { KBEngine.Event.fireOut("friendListData", new object[] { arg1 }); }
public abstract void friendListData(FRIENDDATALIST arg1);
public override void onRemoteMethodCall(MemoryStream stream) { ScriptModule sm = EntityDef.moduledefs["Account"]; UInt16 methodUtype = 0; UInt16 componentPropertyUType = 0; if (sm.usePropertyDescrAlias) { componentPropertyUType = stream.readUint8(); } else { componentPropertyUType = stream.readUint16(); } if (sm.useMethodDescrAlias) { methodUtype = stream.readUint8(); } else { methodUtype = stream.readUint16(); } Method method = null; if (componentPropertyUType == 0) { method = sm.idmethods[methodUtype]; } else { Property pComponentPropertyDescription = sm.idpropertys[componentPropertyUType]; switch (pComponentPropertyDescription.properUtype) { default: break; } return; } switch (method.methodUtype) { case 33: POKERLIST displayPoker_arg1 = ((DATATYPE_POKERLIST)method.args[0]).createFromStreamEx(stream); displayPoker(displayPoker_arg1); break; case 37: FRIENDDATALIST friendListData_arg1 = ((DATATYPE_FRIENDDATALIST)method.args[0]).createFromStreamEx(stream); friendListData(friendListData_arg1); break; case 26: initGamePoker(); break; case 31: SByte loadLandlordPoker_arg1 = stream.readInt8(); POKERLIST loadLandlordPoker_arg2 = ((DATATYPE_POKERLIST)method.args[1]).createFromStreamEx(stream); loadLandlordPoker(loadLandlordPoker_arg1, loadLandlordPoker_arg2); break; case 27: notifyToCallLandlord(); break; case 28: SByte notifyToPlayPoker_arg1 = stream.readInt8(); notifyToPlayPoker(notifyToPlayPoker_arg1); break; case 34: passPoker(); break; case 32: playPokerFailed(); break; case 29: SByte playerReadyGame_arg1 = stream.readInt8(); SByte playerReadyGame_arg2 = stream.readInt8(); playerReadyGame(playerReadyGame_arg1, playerReadyGame_arg2); break; case 30: SByte playerToLandlord_arg1 = stream.readInt8(); SByte playerToLandlord_arg2 = stream.readInt8(); playerToLandlord(playerToLandlord_arg1, playerToLandlord_arg2); break; case 35: Int32 pokerGameOver_arg1 = stream.readInt32(); pokerGameOver(pokerGameOver_arg1); break; case 36: MAILDATA receiveMail_arg1 = ((DATATYPE_MAILDATA)method.args[0]).createFromStreamEx(stream); receiveMail(receiveMail_arg1); break; case 25: SByte returnErrorMessage_arg1 = stream.readInt8(); returnErrorMessage(returnErrorMessage_arg1); break; case 38: Int32 stayInRoom_arg1 = stream.readInt32(); stayInRoom(stayInRoom_arg1); break; default: break; } ; }