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
class ByteConverter | |
{ | |
/*public static byte[] BuffToBuildData(int data_id) | |
{ | |
int Length = 0; | |
System.IntPtr ptr = GamePlayer_GetBattleReportBaseInfoBuf(data_id, ref Length); | |
if (ptr == System.IntPtr.Zero) | |
{ | |
return null; |
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
# coding=utf8 | |
from selenium import webdriver | |
from selenium.webdriver.common.by import By | |
from selenium.webdriver.common.keys import Keys | |
from selenium.webdriver.support import expected_conditions as EC | |
from selenium.webdriver.support.wait import WebDriverWait | |
ID = 'id' # your id. | |
PWD = 'password' # your password |
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
public class TableDataUtil | |
{ | |
public static string GetDataDetailStr<T>(T obj) | |
{ | |
// | |
// 取出所有public欄位資料並回傳字串. | |
// | |
StringBuilder sb = new StringBuilder(); | |
sb.AppendLine(obj.GetType().ToString()); |
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
#if UNITY_EDITOR | |
using System.Collections.Generic; | |
using UnityEngine; | |
using UnityEditor; | |
#endif | |
public class NGUIAtlasToStringConverter { | |
#if UNITY_EDITOR | |
[MenuItem("Tools/NGUI Atlas to Sprites Tool/Convert")] |
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
PLUGIN_DLL_API const Data* GamePlayer_GetBattleReportBaseInfo(const uint32 mail_id) { ... } | |
PLUGIN_DLL_API uint32 Repo_ReportID(Data *Dta) { return Dta->id; } | |
PLUGIN_DLL_API uint32 Repo_ReportTime(Data *Dta) { return Dta->time; } | |
PLUGIN_DLL_API uint16 Repo_Type(Data *Dta) { return Dta->type; } |
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
PLUGIN_DLL_API bool GetDataRef(const int data_id, | |
Data* ref) | |
{ | |
const go3::BuildDataPN* report = go3::BuildDataTable3::Instance().GetTableData(data_id); | |
if (NULL == report) | |
{ | |
return NULL; | |
} |
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
PLUGIN_DLL_API const void* GetDataPtr(const int data_id, int &length) | |
{ | |
length = sizeof(Data); | |
const Data* Dta = ... // 資料來源 | |
if (NULL == Dta) | |
{ | |
return NULL; | |
} |
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
/*class TableDelegate | |
{ | |
public: | |
int GetItemCount(){return 0;} | |
bool OnItemShow( Node *Item, int Index){}; | |
};*/ | |
template<class TableDelegateT> | |
class TableViewUtilEx |
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
clock_t t1, t2; | |
t1 = clock(); | |
DoSomething(); | |
t2 = clock(); | |
float diff = ((float)(t2 - t1) / 1000000.0F) * 1000; | |
printf("battle total time : %f \n ", diff); |
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
#include "main.h" | |
#include "AppDelegate.h" | |
#include "HelloWorldScene.h" | |
#include "cocos2d.h" | |
#include "wx/wx.h" | |
USING_NS_CC; | |
class MyApp : public wxApp | |
{ | |
public: |
NewerOlder