没有合适的资源?快使用搜索试试~ 我知道了~
资源推荐
资源详情
资源评论
SmartFoxServer sfs 实现私聊
新建LobbyGUI.cs
using UnityEngine;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.InteropServices;
using System.Security.Permissions;
using System.Text;
using SmartFoxClientAPI;
using SmartFoxClientAPI.Data;
public class LobbyGUI : MonoBehaviour
{
private SmartFoxClient smartFox;
private string zone = "simpleChat";
private string username = "";
private string password = "";
private string loginErrorMessage = "";
private static bool isLoggedIn;
private static bool roomListReceived = false;
private static bool F=false;
private static bool ESC=false;
private static bool HY=false;
private static bool windowsKG=false;
private string newMessage = "";
private ArrayList messages = new ArrayList();
// Locker to use for messages collection to ensure its cross-thread safety
private System.Object messagesLocker = new System.Object();
private Vector2 chatScrollPosition, userScrollPosition;
private int roomSelection = 0;
private string [] roomStrings;
private int userSelection=0;
private string [] userStrings;
public int QJ_userid;
public int QJ_userroomid;
public string QJ_username;
public string QJ_userPrivatemsg;
public GUISkin gSkin;
void Awake ()
{
DontDestroyOnLoad (this);
}
void Start()
{
if (SmartFox.initialized)
private static bool windowsKG=false;
private string newMessage = "";
private ArrayList messages = new ArrayList();
// Locker to use for messages collection to ensure its cross-thread safety
private System.Object messagesLocker = new System.Object();
private Vector2 chatScrollPosition, userScrollPosition;
private int roomSelection = 0;
private string [] roomStrings;
private int userSelection=0;
private string [] userStrings;
public int QJ_userid;
public int QJ_userroomid;
public string QJ_username;
public string QJ_userPrivatemsg;
public GUISkin gSkin;
void Awake ()
{
DontDestroyOnLoad (this);
}
void Start()
{
if (SmartFox.initialized)
剩余13页未读,继续阅读
资源评论
- qzl3937002018-04-04资源的sfs版本不能确定,本人用过版本2.0.1的sfs2x,2.0.1与这个资源里关于事件监听的增减方法不一样。这个资源看着像是官方的Lobby例子改的,加了一部分中文注释。3分贵了点。
alexyuanlei
- 粉丝: 4
- 资源: 22
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功