搜索
查看: 1990|回复: 7

reward_sim.sma問題..掉錢與檢錢

[复制链接]
发表于 2006-12-22 04:36:40 | 显示全部楼层 |阅读模式 来自 中国–香港
如何把下面這些由
reward_sim.sma
分離出來




public color_radio(msgid, msgDest, msgEnt){
new argNum = get_msg_args()
if (argNum!=5) return PLUGIN_CONTINUE
if (get_msg_argtype(1)!=ARG_BYTE) return PLUGIN_CONTINUE
new arg1=get_msg_arg_int(1)
if (arg1!=5) return PLUGIN_CONTINUE
new arg3[256]
get_msg_arg_string(3,arg3,255)
if(equal(arg3,"#Game_radio")){
  new arg4[33],arg5[129]
  get_msg_arg_string(4,arg4,32)
  get_msg_arg_string(5,arg5,128)
  new saymsg[256]
  if(equal(arg5,"#Go_go_go")){//Msg GoGoGo
   format(saymsg,255,"^x03%s(對講機): ^x04全隊,衝呀!",arg4)
  }
  else if(equal(arg5,"#Stick_together_team")){
   format(saymsg,255,"^x03%s(對講機): ^x04全隊保持行動一致",arg4)
  }
  else if(equal(arg5,"#Team_fall_back")){
   format(saymsg,255,"^x03%s(對講機):^x04 全隊,撤退!",arg4)
  }
  else if(equal(arg5,"#Cover_me")){
   format(saymsg,255,"^x03%s(對講機):^x04 掩護我!",arg4)
  }
  else if(equal(arg5,"#You_take_the_point")){
   format(saymsg,255,"^x03%s(對講機):^x04 守住這個位置",arg4)
  }
  else if(equal(arg5,"#Hold_this_position")){
   format(saymsg,255,"^x03%s(對講機):^x04 各隊員保持現在的位置",arg4)
  }
  else if(equal(arg5,"#Regroup_team")){
   format(saymsg,255,"^x03%s(對講機):^x04 重新組隊",arg4)
  }
  else if(equal(arg5,"#Follow_me")){
   format(saymsg,255,"^x03%s(對講機):^x04 跟著我",arg4)
  }
  else if(equal(arg5,"#Taking_fire")){
   format(saymsg,255,"^x03%s(對講機):^x04 進攻...需要火力支援",arg4)
  }
  else if(equal(arg5,"#Get_in_position_and_wait")){
   format(saymsg,255,"^x03%s(對講機):^x04 全隊就位,等我出去時掩護我",arg4)
  }
  else if(equal(arg5,"#Storm_the_front")){
   format(saymsg,255,"^x03%s(對講機):^x04 全隊正面快速突進",arg4)
  }
  else if(equal(arg5,"#Report_in_team")){
   format(saymsg,255,"^x03%s(對講機):^x04 全體隊員報告自己的位置",arg4)
  }
  else if(equal(arg5,"#Affirmative")){
   format(saymsg,255,"^x03%s(對講機):^x04 明白",arg4)
  }
  else if(equal(arg5,"#Roger_that")){
   format(saymsg,255,"^x03%s(對講機):^x04 收到",arg4)
  }
  else if(equal(arg5,"#Enemy_spotted")){
   format(saymsg,255,"^x03%s(對講機):^x04 發現敵人",arg4)
  }
  else if(equal(arg5,"#Need_backup")){
   format(saymsg,255,"^x03%s(對講機):^x04 需要支援",arg4)
  }
  else if(equal(arg5,"#Sector_clear")){
   format(saymsg,255,"^x03%s(對講機):^x04 此區域安全",arg4)
  }
  else if(equal(arg5,"#In_position")){
   format(saymsg,255,"^x03%s(對講機):^x04 我已經就位",arg4)
  }
  else if(equal(arg5,"#Reporting_in")){
   format(saymsg,255,"^x03%s(對講機):^x04 報告你的情況",arg4)
  }
  else if(equal(arg5,"#Get_out_of_there")){
   format(saymsg,255,"^x03%s(對講機):^x04 炸彈快要爆炸了",arg4)
  }
  else if(equal(arg5,"#Negative")){
   format(saymsg,255,"^x03%s(對講機):^x04 無法實現",arg4)
  }
  else if(equal(arg5,"#Enemy_down")){
   format(saymsg,255,"^x03%s(對講機):^x04 敵人已被消滅",arg4)
  }
  else if(equal(arg5,"#Hostage_down")){
   format(saymsg,255,"^x03%s(對講機):^x04 Hostage down.",arg4)
  }
  else if(equal(arg5,"#Fire_in_the_hole")){
   format(saymsg,255,"^x03%s(對講機):^x04 小心被扔中",arg4)
  }
  else {
   return PLUGIN_CONTINUE
   //format(saymsg,255,"^x03%s(對講機): ^x04What are you saying!",arg4)
  }
  message_begin(MSG_ONE, get_user_msgid("SayText"), {0,0,0}, msgEnt)
  write_byte(msgEnt)
  write_string(saymsg)
  message_end()
  //client_color(0,msgEnt,saymsg)
  return PLUGIN_HANDLED
}
return PLUGIN_CONTINUE
}
发表于 2006-12-22 13:41:24 | 显示全部楼层 来自 中国–广东–深圳

回复: reward_sim.sma問題..掉錢與檢錢

发全代码上来,才知道该如何改。
回复

使用道具 举报

发表于 2006-12-22 15:35:38 | 显示全部楼层 来自 中国–广东–潮州

回复: reward_sim.sma問題..掉錢與檢錢

烂人,他是要把彩色radio信息分离出来,不过这个信息只支持CS,没有修正CZ信息位置;
楼主可以参考POP781的手雷无限插件,把
[PHP]
public plugin_init()
{
。。。。。。
//类似下面的那句代码
register_message(get_user_msgid("TextMsg"), "color_radio")
。。。。。。
[/PHP]
连同你所引用出来的代码一起剥离,应该OK了。
回复

使用道具 举报

 楼主| 发表于 2006-12-22 17:29:50 | 显示全部楼层 来自 中国–香港

回复: reward_sim.sma問題..掉錢與檢錢

/* Rewarding
   ver 0.1 By Zhao on 2004.12.4
*/
#include <amxmodx>
#include <csx>
#include <amxmisc>
#include <cstrike>
#include <engine>
#include <mysql>
#include <csstats>
//#define DEBUG
#define MONEY_TIER 8000 // DON'T MESS WITH, Money total at which the plugin switches over keeping track of money
#define MAX_DROPED_MONEY_COUNT 100
#define TE_GLOWSPRITE      23      
#define Maxsounds 1
#define BIG_MONEY_INDEX 16
#define OPEN_SQL
#define MONEY_REWARD
// coord, coord, coord (pos) short (model index) byte (scale / 10)
new soundlist[Maxsounds][] = {"Half-Life17"} //Connecting Music
new money_total[33] // Keep track of peeps money if above MONEY_TIER
new gmsg_Money
new playerkilled[33],teamjoined[33]
new rewards[11]={50,100,300,500,1000,3000,5000,8000,10000,15000,20000}//Rewarding Ramdon
new g_firstblood,Round_Control
new g_random,g_roundcount
new g_money11,g_money22,g_money33
new rewardedbig,g_iRoundEndTriggered
//new connectingmp3
new droped_money_postion[MAX_DROPED_MONEY_COUNT][3]
new droped_money_ammount[MAX_DROPED_MONEY_COUNT][2]//[.][0] is money,[][1] is the round
new droped_money_count
new g_buffer[512]

public client_putinserver(id){
client_cmd(id,"mp3 stop")
return PLUGIN_CONTINUE
}
public team_join(){
new id=read_data(1)
// server_print("Ok, This Team_Join,id:%d",id)
if(teamjoined[id]) return
teamjoined[id]=1
new welcomemsg[129],username[33]
new izStats[8], izBody[8]
new iRankPos, iRankMax
get_user_name(id,username,32)
if (cvar_exists("csstats_reset")){
  iRankPos = get_user_stats( id, izStats, izBody )
  iRankMax = get_statsnum()
  format(welcomemsg,128,"^x01歡迎^x03%s^x01,排名第^x04%d^x01名[共^x04%d^x01名]",username,iRankPos,iRankMax)
}else format(welcomemsg,128,"^x01歡迎^x03%s^x01,無排名",username)
client_color(0,id,welcomemsg)
}
public client_disconnect(id){
new name[32]
get_user_name(id,name,31)
format(g_buffer,511,"%s 離開了服務器.",name)
set_hudmessage(255, 150, 50, 0.10, 0.5, 0, 6.0, 10.0, 0.5, 0.15, 9)
show_hudmessage(0, g_buffer)
playerkilled[id]=0
return PLUGIN_CONTINUE
}
public abs(num){
  return (num>=0)?num:-num
}
public client_connect(id){
new i
i = random_num(0,Maxsounds-1)
client_cmd(id,"mp3 play media/%s",soundlist)
set_cvar_float("mp_startmoney", 801.0) // So you can track when to change to amx_startmoney ammount, I know.. a crude method
money_total[id] = 0
//client_cmd(id,"mp3 play ^"../valve/media/half-life17.mp3^"");
}
public read_gmsg_Money(id)
{
new current_total = read_data(1)

if(current_total == 801){   // If CS is spawning you with mp_startmoney default
  current_total = get_cvar_num("amx_startmoney")  // current total is actually amx_startmoney
  cs_set_user_money(id, current_total,0)   // so set user money to amx_startmoney
  money_total[id] = 0 // reset
}
if(current_total >= MONEY_TIER && !money_total[id]) // If first time above MONEY_TIER
{
  money_total[id] = current_total // Keep track of current total
  send_moneymsg(id,1) // send money msg of current total
  return PLUGIN_CONTINUE
}
if(money_total[id]) // If was over tier on last money message
{
  money_total[id] += current_total - MONEY_TIER  // figure the term of current total - tier
  if(money_total[id] < MONEY_TIER){  // If less then tier set user money to money_total[id] and stop keeping track
   cs_set_user_money(id,money_total[id],1)
   money_total[id] = 0
  }
  else{
   send_moneymsg(id,1) // else send money message
  }
  
  return PLUGIN_CONTINUE  
}
return PLUGIN_CONTINUE
}
public send_moneymsg(id,flash)
{
cs_set_user_money(id,MONEY_TIER,flash) //Set user money to tier ammount so easy to track add and subtract terms

static MAXAMMOUNT

MAXAMMOUNT = get_cvar_num("amx_maxmoney")

if(money_total[id] > MAXAMMOUNT)
  money_total[id] = MAXAMMOUNT
message_begin( MSG_ONE , gmsg_Money , {0,0,0}, id) //Send money message with ammount stored in money_total[id]
write_long(money_total[id])
write_byte(flash)
message_end()
}
public ramdon_money(params[]){
new killer=params[0]
new oldamount=params[1]
new amount
new killername[32]
new random_range,randomvalue
random_range=(rewardedbig)?BIG_MONEY_INDEX:20//控制大額的獎勵不會出現太多次
for(;;){
  randomvalue=random(random_range)
  amount=rewards[randomvalue]
  if (amount!=oldamount) break;
}
get_user_name(killer,killername,31)
if (g_random>0){
  g_random--
  set_hudmessage(0,255,0,0.05,0.25,0, 0.02, 0.4, 0.01, 0.1, 2)
  show_hudmessage(0,"%s一馬當先,奮勇殺敵,獎勵%6d金錢",killername,amount)
  new param[2]
  param[0]=killer
  param[1]=amount
  set_task(0.3,"ramdon_money",0,param,1)
}
else {
  if(randomvalue>=BIG_MONEY_INDEX) rewardedbig=1
  //set_hudmessage(0,255,0,0.75,0.18,0, 1.0, 5.0, 0.1, 0.2, 1)
  set_hudmessage(0,255,0,0.05, 0.25, 0, 0.02, 6.0, 0.01, 0.1, 2)
  show_hudmessage(0,"%s一馬當先,奮勇殺敵,獎勵%6d金錢",killername,amount)
  add_player_money(killer,amount)
  new msg[512]
  format(msg,511,"^x03%s^x01 一馬當先,奮勇殺敵,獎勵^x04 %d ^x01金錢",killername,amount)
  client_color(0,killer,msg)
}
}
public add_player_money(player,ammount){
    static MAXAMMOUNT
    MAXAMMOUNT = get_cvar_num("amx_maxmoney")
    new new_total_money
    if(money_total[player]){
     new_total_money=money_total[player]+ammount
    }
    else
     new_total_money=cs_get_user_money(player) + ammount
    if (new_total_money>=MONEY_TIER){
     money_total[player]=new_total_money
     if(money_total[player]>MAXAMMOUNT) money_total[player]=MAXAMMOUNT
     send_moneymsg(player,1) // send money msg of current total      
    }
    else {
     cs_set_user_money(player,new_total_money)
     money_total[player]=0
    }
}
public random_drop_money(ori_ammount){
  new drop_control
  if(ori_ammount>10000){
   drop_control=random(100000)
   if(ori_ammount>=drop_control){//按照錢的多少,我們產生不同的掉錢的隨機數。
    //現在我們決定要調多少。最多是0.6,0.5  0.4 0.3 0.2,0.1
    return random(6)+1
   }else return 0
  }
  return 0
}
//public client_death(killer,victim,wpnindex,hitplace,TK){
public eDeathMsg(){
new killer,victim,TK
killer=read_data(1)
if(!killer) return PLUGIN_CONTINUE
victim=read_data(2)
TK=(get_user_team(killer)==get_user_team(victim))?1:0
//headshot=read_data(3)
new wpnname[4]
read_data(4,wpnname,3)
new killername[32]
//if (wpnindex==CSW_C4||TK) return PLUGIN_CONTINUE
if(equal(wpnname,"c4")||TK) return PLUGIN_CONTINUE
// new headshot = ( hitplace==HIT_HEAD ) ? 1:0
new selfkill = ( killer==victim ) ? 1:0
if (selfkill) return PLUGIN_CONTINUE
playerkilled[killer]++
if(equal(wpnname,"kni")){
  add_player_money(killer,10000)
  get_user_name(killer,killername,31)
  set_hudmessage(0,255,0,0.05,0.25,0, 0.2, 6.0, 0.1, 0.1, 2)
  //set_hudmessage(0,255,0,0.75,0.18,0, 1.0, 1.0, 0.1, 0.2, 12)
  show_hudmessage(0,"%s使用匕首殺敵,獎勵10000金錢",killername)
  new msg[100]
  format(msg,99,"^x03%s^x01使用匕首殺敵,獎勵^x04 10000 ^x01 金錢",killername)
  client_color(0,killer,msg)
  //log_message("%s使用匕首殺敵,獎勵10000金錢",killername)
}

if (g_firstblood){
  g_firstblood=0
  g_random=6
  new param[2]
  param[0]=killer
  param[1]=0;
  ramdon_money(param)
}
//The Victim Will Drop Some Money
new victim_money
if(money_total[victim]==0) victim_money=cs_get_user_money(victim)
else victim_money=money_total[victim]
//if (victim_money>= MONEY_TIER&&
if (droped_money_count<MAX_DROPED_MONEY_COUNT){
  new drop_prec=random_drop_money(victim_money)
  //new int:dropedmoney=*victim_money
  if(drop_prec>0){
   new dropedmoney=(victim_money*drop_prec/10000)*1000
   add_player_money(victim,-dropedmoney)
   new victim_coord[3]
   get_user_origin(victim, victim_coord)  
   new i
   for (i=0;i<MAX_DROPED_MONEY_COUNT;i++)
   {
    if(droped_money_ammount[0]==0){
     droped_money_count++
     droped_money_postion[0]=victim_coord[0]
     droped_money_postion[1]=victim_coord[1]
     droped_money_postion[2]=victim_coord[2]
     droped_money_ammount[1]=g_roundcount//We record which round droped the money
     droped_money_ammount[0]=dropedmoney*8/10 //We Drop 20 precent money
     break;
    }
   }
   //new ammount_desc[32]
   new victimname[32]
   get_user_name(victim,victimname,31)
   new msg[100]
   format(msg,99,"^x03%s^x01掉了^x04%d^x01錢.",victimname,dropedmoney)
   client_color(0,victim,msg)
  }
}
return PLUGIN_CONTINUE
}
public show_droped_money(){
new i
new money_model_id
for (i=0;i<MAX_DROPED_MONEY_COUNT;i++){
  if (droped_money_ammount[0]>0){
   //We Display the money;
   if(droped_money_ammount[0]<10000){
    money_model_id=g_money11
   }
   else if (droped_money_ammount[0]<100000){
    money_model_id=g_money22
   } else money_model_id=g_money33
   message_begin(MSG_BROADCAST, SVC_TEMPENTITY)
   write_byte(17)//#define TE_SPRITE  17      // additive sprite, plays 1 cycle,More Info,plz reffer to HLSDK
   write_coord(droped_money_postion[0]);
   write_coord(droped_money_postion[1]);
   write_coord(droped_money_postion[2]+20);
   write_short(money_model_id)
   write_byte(2)
   write_byte(128)
   message_end()
  }
}
}
public check_player_pos(){
new playerslist[32]
new i,playerscount,j,moneyammount
new playerspos[3],playername[32]
get_players(playerslist,playerscount,"a") //we only check the alive players
for(i=0;i<playerscount;i++){
  get_user_origin(playerslist,playerspos)
  for(j=0;j<MAX_DROPED_MONEY_COUNT;j++){
    if(droped_money_ammount[j][0]>0&&
      abs(playerspos[0]-droped_money_postion[j][0])<=20&&
      abs(playerspos[1]-droped_money_postion[j][1])<=20&&
      abs(playerspos[2]-droped_money_postion[j][2])<=30){//Pick Up Money
      moneyammount=droped_money_ammount[j][0]
      droped_money_ammount[j][0]=0;
      droped_money_count--;
      add_player_money(playerslist,moneyammount)
      get_user_name(playerslist,playername,31)
       new msg[100]
      format(msg,99,"^x03%s^x01撿到^x04%d^x01錢.",playername,moneyammount);
      client_color(0,playerslist,msg)
      break;
    }
  }
}
}
public new_round(){
new i
if (!Round_Control){
  g_roundcount++
  Round_Control = 1
  g_firstblood=1
  g_iRoundEndTriggered=0
  for(i=0;i<=32;i++)playerkilled=0;
  //We Remove the droped money 3 round ago
  for(i=0;i<MAX_DROPED_MONEY_COUNT;i++){
   if (droped_money_ammount[0]>0&&g_roundcount>(droped_money_ammount[1]+2)){
    droped_money_ammount[0]=0
    droped_money_ammount[1]=0
    droped_money_count--
   }
  }
}
}
public eEndRound(){
  if (g_iRoundEndTriggered) return
  g_iRoundEndTriggered=1
  Round_Control=0
  new i,maxkillcount
  maxkillcount=0
  new RoundEndMsg[513],ipos
  new playerslist[32],playerscount
  ipos=0
  ipos+=format(RoundEndMsg[ipos],512-ipos,"本局殺敵最多的玩家")
  get_players(playerslist,playerscount)//Get  Players
  for(i=0;i<playerscount;i++){
   if(playerkilled[playerslist]&&playerkilled[playerslist]>maxkillcount) maxkillcount=playerkilled[playerslist]
  }
  if(maxkillcount){
   new playername[33],playeradded=0
   ipos+=format(RoundEndMsg[ipos],512-ipos,"  (殺%d人)^n---------------------------------^n",maxkillcount)
   for(i=0;i<playerscount;i++){
    if(playerkilled[playerslist]==maxkillcount){//WeiGet this players
     if (get_user_name(playerslist,playername,32))
      ipos+=format(RoundEndMsg[ipos],512-ipos,"%s^n",playername)
     else ipos+=format(RoundEndMsg[ipos],512-ipos,"未知或已離開遊戲^n")
     ++playeradded
    }
   
    if(playeradded>=2){
     ipos+=format(RoundEndMsg[ipos],512-ipos,"......^n")
     break;
    }
   }
   
  }
  else{
   ipos+=format(RoundEndMsg[ipos],512-ipos,"^n---------------------------------^n大家太客氣了,都沒有殺敵^n")
  }
  ipos+=format(RoundEndMsg[ipos],512-ipos,"^n金錢最多的玩家^n---------------------------------^n")
  new maxctmoney=0,maxtmoney=0,maxmoneytid=0,maxmoneyctid=0
  for(i=0;i<playerscount;i++){
   new userid=playerslist
   new usermoney
   if(!is_user_connected(userid)) continue
   if(money_total[userid]) usermoney=money_total[userid]
   else usermoney=cs_get_user_money(userid)
   if(cs_get_user_team(userid)==CS_TEAM_T){
    if(usermoney>maxtmoney){
     maxtmoney=usermoney
     maxmoneytid=userid
    }
   }
   else {
    if(usermoney>maxctmoney){
     maxctmoney=usermoney
     maxmoneyctid=userid
    }
   }
   
  }
  new ctname[33],tname[33]
  if(maxmoneytid)get_user_name(maxmoneytid,tname,32)
  else tname="沒有人"
  if(maxmoneyctid)get_user_name(maxmoneyctid,ctname,32)
  else ctname="沒有人"
  ipos+=format(RoundEndMsg[ipos],512-ipos,"反恐小組^n%s   %d^n恐怖分子^n%s   %d",ctname,maxctmoney,tname,maxtmoney)
  set_hudmessage( 100, 200, 0, 0.05, 0.55, 0, 0.02, 5.0, 0.1, 0.2, 2 )
  show_hudmessage(0,RoundEndMsg)
}
public eRestart(){
new i
g_roundcount = 0
g_firstblood = 0
Round_Control = 0
rewardedbig = 0
for(i=0;i<=32;i++) money_total=0;
for(i=0;i<=32;i++)playerkilled=0;
for(i=0;i<MAX_DROPED_MONEY_COUNT;i++){
  droped_money_ammount[0]=0
  droped_money_ammount[1]=0
}
droped_money_count=0
// client_print(0,print_chat,"Round Restart and Roundcount=%d",g_roundcount)
}
public plugin_precache()
{
g_money11 = precache_model("sprites/money11.spr");
g_money22 = precache_model("sprites/money22.spr");
g_money33 = precache_model("sprites/money33.spr");
//precache_sound("../valve/media/half-life17.mp3");
}
public client_color(playerid,colorid,msg[]){
  new playerslist[32],playerscount//,i
  get_players(playerslist,playerscount,"c")
  new userid
  if(playerid==0){
   userid=playerid
   message_begin(MSG_ALL, get_user_msgid("SayText"), {0,0,0}, userid)
   write_byte(colorid)
   write_string(msg)
   message_end()
   
  }
  else{
   userid=playerid
   message_begin(MSG_ONE, get_user_msgid("SayText"), {0,0,0}, userid)
   write_byte(colorid)
   write_string(msg)
   message_end()
  }
}
public color_radio(msgid, msgDest, msgEnt){
new argNum = get_msg_args()
if (argNum!=5) return PLUGIN_CONTINUE
if (get_msg_argtype(1)!=ARG_BYTE) return PLUGIN_CONTINUE
new arg1=get_msg_arg_int(1)
if (arg1!=5) return PLUGIN_CONTINUE
new arg3[256]
get_msg_arg_string(3,arg3,255)
if(equal(arg3,"#Game_radio")){
  new arg4[33],arg5[129]
  get_msg_arg_string(4,arg4,32)
  get_msg_arg_string(5,arg5,128)
  new saymsg[256]
  if(equal(arg5,"#Go_go_go")){//Msg GoGoGo
   format(saymsg,255,"^x03%s(對講機): ^x04全隊,衝呀!",arg4)
  }
  else if(equal(arg5,"#Stick_together_team")){
   format(saymsg,255,"^x03%s(對講機): ^x04全隊保持行動一致",arg4)
  }
  else if(equal(arg5,"#Team_fall_back")){
   format(saymsg,255,"^x03%s(對講機):^x04 全隊,撤退!",arg4)
  }
  else if(equal(arg5,"#Cover_me")){
   format(saymsg,255,"^x03%s(對講機):^x04 掩護我!",arg4)
  }
  else if(equal(arg5,"#You_take_the_point")){
   format(saymsg,255,"^x03%s(對講機):^x04 守住這個位置",arg4)
  }
  else if(equal(arg5,"#Hold_this_position")){
   format(saymsg,255,"^x03%s(對講機):^x04 各隊員保持現在的位置",arg4)
  }
  else if(equal(arg5,"#Regroup_team")){
   format(saymsg,255,"^x03%s(對講機):^x04 重新組隊",arg4)
  }
  else if(equal(arg5,"#Follow_me")){
   format(saymsg,255,"^x03%s(對講機):^x04 跟著我",arg4)
  }
  else if(equal(arg5,"#Taking_fire")){
   format(saymsg,255,"^x03%s(對講機):^x04 進攻...需要火力支援",arg4)
  }
  else if(equal(arg5,"#Get_in_position_and_wait")){
   format(saymsg,255,"^x03%s(對講機):^x04 全隊就位,等我出去時掩護我",arg4)
  }
  else if(equal(arg5,"#Storm_the_front")){
   format(saymsg,255,"^x03%s(對講機):^x04 全隊正面快速突進",arg4)
  }
  else if(equal(arg5,"#Report_in_team")){
   format(saymsg,255,"^x03%s(對講機):^x04 全體隊員報告自己的位置",arg4)
  }
  else if(equal(arg5,"#Affirmative")){
   format(saymsg,255,"^x03%s(對講機):^x04 明白",arg4)
  }
  else if(equal(arg5,"#Roger_that")){
   format(saymsg,255,"^x03%s(對講機):^x04 收到",arg4)
  }
  else if(equal(arg5,"#Enemy_spotted")){
   format(saymsg,255,"^x03%s(對講機):^x04 發現敵人",arg4)
  }
  else if(equal(arg5,"#Need_backup")){
   format(saymsg,255,"^x03%s(對講機):^x04 需要支援",arg4)
  }
  else if(equal(arg5,"#Sector_clear")){
   format(saymsg,255,"^x03%s(對講機):^x04 此區域安全",arg4)
  }
  else if(equal(arg5,"#In_position")){
   format(saymsg,255,"^x03%s(對講機):^x04 我已經就位",arg4)
  }
  else if(equal(arg5,"#Reporting_in")){
   format(saymsg,255,"^x03%s(對講機):^x04 報告你的情況",arg4)
  }
  else if(equal(arg5,"#Get_out_of_there")){
   format(saymsg,255,"^x03%s(對講機):^x04 炸彈快要爆炸了",arg4)
  }
  else if(equal(arg5,"#Negative")){
   format(saymsg,255,"^x03%s(對講機):^x04 無法實現",arg4)
  }
  else if(equal(arg5,"#Enemy_down")){
   format(saymsg,255,"^x03%s(對講機):^x04 敵人已被消滅",arg4)
  }
  else if(equal(arg5,"#Hostage_down")){
   format(saymsg,255,"^x03%s(對講機):^x04 Hostage down.",arg4)
  }
  else if(equal(arg5,"#Fire_in_the_hole")){
   format(saymsg,255,"^x03%s(對講機):^x04 小心被扔中",arg4)
  }
  else {
   return PLUGIN_CONTINUE
   //format(saymsg,255,"^x03%s(對講機): ^x04What are you saying!",arg4)
  }
  message_begin(MSG_ONE, get_user_msgid("SayText"), {0,0,0}, msgEnt)
  write_byte(msgEnt)
  write_string(saymsg)
  message_end()
  //client_color(0,msgEnt,saymsg)
  return PLUGIN_HANDLED
}
return PLUGIN_CONTINUE
}
public plugin_init(){
register_plugin("First Killer Reward","0.1","Zhao")
register_event("RoundTime", "new_round", "bc")  
// register_event("ResetHUD", "new_round", "abc")
#if defined MONEY_REWARD
register_event("DeathMsg","eDeathMsg","a")
register_event("Money","read_gmsg_Money","b")
#endif
register_event("SendAudio", "eEndRound", "a", "2&%!MRAD_terwin","2&%!MRAD_ctwin","2&%!MRAD_rounddraw")
register_event("TextMsg","eRestart","a","2&#Game_C","2&#Game_w")
// register_event("BarTime","bartime_event","b")
register_cvar("amx_startmoney", "800")
register_cvar("amx_maxmoney", "999999")
register_message(get_user_msgid("TextMsg"),"color_radio")
register_event("TeamInfo","team_join","a","2!UNASSIGNED") // Team Joining
  
g_firstblood=1
rewardedbig = 0
droped_money_count=0
g_roundcount=0
gmsg_Money = get_user_msgid("Money")
#if defined MONEY_REWARD
set_task(0.5,"show_droped_money",887,"",0,"b")
set_task(0.1,"check_player_pos",888,"",0,"b")
#endif
}
回复

使用道具 举报

 楼主| 发表于 2006-12-24 18:01:50 | 显示全部楼层 来自 中国–香港

回复: reward_sim.sma問題..掉錢與檢錢

有沒人可以幫下我-=-
回复

使用道具 举报

发表于 2006-12-24 23:05:29 | 显示全部楼层 来自 中国–广东–深圳

回复: reward_sim.sma問題..掉錢與檢錢

代码不全,请用附件上传。
回复

使用道具 举报

发表于 2006-12-25 12:07:46 | 显示全部楼层 来自 中国–广东–潮州–湘桥区

回复: reward_sim.sma問題..掉錢與檢錢

Post by 0920357689
有沒人可以幫下我-=-

在3楼已经告诉你了,我不明白你是没看到还是要别人全部帮你做好。
回复

使用道具 举报

 楼主| 发表于 2006-12-28 06:52:26 | 显示全部楼层 来自 中国–香港

回复: reward_sim.sma問題..掉錢與檢錢

偶找不到3樓說的那個插件....
回复

使用道具 举报

游客
回复
您需要登录后才可以回帖 登录 | 注个册吧

快速回复 返回顶部 返回列表