|
发表于 2005-10-8 17:47:30
|
显示全部楼层
来自 中国–广东–广州–天河区
回复: 请问yanexp,网页查看CS排行及状态+地图背景PHP 能否放在TOP15或启动页中?
Post by wzf828
那就给大家分享一下啦
打开StatsX.sma源码
查找 /* get top 15 */处替换为以下内容即可,居我这测试在CS里以WEB显示TOP15数据还是很完整的!
效果图:
http://npower.vicp.net/csgame/cstop15.jpg
- /* get top 15 */
- getTop15() {
- new pos, stats[8], body[8], name[32],state[4]
- //#if !defined NO_STEAM
-
- pos = format(g_Buffer,2047,"<style>body{color:#FFCC99;background-color:black;margin-top:5}.one{background-color:#310000}.two{background-color:#630000}td{font-size:14px}</style><center><b><font size=4>广州天河力量网吧CS1.6至尊排行</b><table width=500>")
- pos += format(g_Buffer[pos],2047-pos,"%s","<tr bgcolor=#9C0000><td>#<td>昵称<td>杀敌<td>死亡<td>击中<td>开枪<td>爆头</tr>")
- new imax = get_statsnum()
- if (imax > 15) imax = 15
- for(new a = 0; a < imax; ++a){
- if (equal(state,"one")) copy(state,3,"two")
- else copy(state,3,"one")
- get_stats(a,stats,body,name,31)
- pos += format(g_Buffer[pos],2047-pos,
- "<tr class=%s><td>%d<td>%s<td>%d<td>%d<td>%d<td>%d<td>%d",state,a+1,name,stats[0],stats[1],stats[5],stats[4],stats[2])
- }
- copy(g_Buffer[pos],2047-pos,"</table><hr size=1 color=blue></font>详情http://nPower.vicp.net")
- /*#else
- pos = format(g_Buffer,2047," # %-28.27s %6s %6s %6s %6s %6s^n",
- "nick", "kills" , "deaths" , "hits","shots","hs" )
- new imax = get_statsnum()
- if (imax > 15) imax = 15
- for(new a = 0; a < imax; ++a){
- get_stats(a,stats,body,name,31)
- pos += format(g_Buffer[pos],2047-pos,"%2d. %-28.27s %6d %6d %6d %6d %6d^n",a+1,name,stats[0],stats[1],stats[5],stats[4],stats[2])
- }
- #endif*/
- }
复制代码 |
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有账号?注个册吧
×
|