设为首页收藏本站新闻投稿

MOD中国同盟社

 找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 668|回复: 8

[求助] End round when execute a command (not affect to score) ? [复制链接]

Rank: 20Rank: 20Rank: 20Rank: 20Rank: 20

帖子
1150
精华
0
声望
115298 点
金币
7049 Mold
被赞许
43 次
注册时间
2012-3-1

可爱小猫 懒人勋章 星界财团 积分霸主

发表于 2012-4-23 11:12:14 |显示全部楼层
本帖最后由 navmesh 于 2012-4-23 19:29 编辑

End round when execute a command (not affect to score) ?
结束回合执行命令不影响得分

Hi

I ask for a plugin that when execute a command ,the round will end immediately

(and their score is not influence )


I mean


not reset score ,
not adding deaths score to player in scoreboard
does not score for anyteam ( like round draw ,no team wins )

I searched but can' find a single plugin to do this


(i found a plugin that end round but not when executing a command ,maybe it's useful so i add here ,i try to edit but can't ) , hope someone can help

force round end by alka (the round end whenround timer is 0)
https://forums.alliedmods.net/sh ... wthread.php?t=56941[/url]




here you can download
sma file
https://forums.alliedmods.net/at ... 61&d=1183748103[/url]
amxx
http://www.amxmodx.org/plcompile ... b.cgi?file_id=17861[/url]

thanks

你好

一个插件执行命令将立即结束
他们得分影响
我的意思
重设分数
没有死亡的得分球员记分牌
得分anyteam轮抽签没有哪支球队获胜

搜查,但可以找到一个插件做到这一点

发现了一个插件结束一轮,但执行命令,也许有用所以我在这里补充,我尝试编辑但不能希望有人能帮助

碱性回合结束武力回合结束roundtimer0
http://forums.alliedmods.net/showthread.php?t=56941

在这里你可以下载
SMA文件
https://forums.alliedmods.net/at ... 61&d=1183748103
[/url]
AMXX
http://www.amxmodx.org/plcompile ... b.cgi?file_id=17861[/url]


感谢


使用道具 举报

Rank: 8Rank: 8

帖子
300
精华
8
声望
1108 点
金币
32 Mold
被赞许
36 次
注册时间
2012-2-18

MTT职员 懒人勋章 精华帖制造者 可爱小猫

发表于 2012-4-23 11:54:57 |显示全部楼层
I really want to help you,but I don‘t know how to answer this question。sorry My friend。
已有 1 人评分被赞许 收起 理由
navmesh + 1 thank you ,mate ^^

总评分: 被赞许 + 1   查看全部评分

使用道具 举报

Rank: 5Rank: 5

帖子
131
精华
0
声望
867 点
金币
133 Mold
被赞许
10 次
注册时间
2010-12-31
发表于 2012-4-23 16:34:22 |显示全部楼层
hi dude, are you serious?
I've just done a simple search and I found this:
http://forums.alliedmods.net/sho ... amp;highlight=round
this should works
I am the bone of my Scripts,
So I pray, Unlimited Code Works.

使用道具 举报

Rank: 20Rank: 20Rank: 20Rank: 20Rank: 20

帖子
1150
精华
0
声望
115298 点
金币
7049 Mold
被赞许
43 次
注册时间
2012-3-1

可爱小猫 懒人勋章 星界财团 积分霸主

发表于 2012-4-23 16:37:57 |显示全部楼层
MapleRabbit.VS 发表于 2012-4-23 15:34
hi dude, are you serious?
I've just done a simple search and I found this:
http://forums.alliedmods. ...

i knew this
but there are many functions that i don't need in this plugin
so i asked to remove another functions (at the last post at the topic)

I only need this function :when i execute the command :
terminate_round draw
the round end and does not affect to player's score ,teamscore


so anyone please remove all other functions for me (for better performance ) (objective, map check ,round end type timer ,team winning …)
that’s all I need

使用道具 举报

Rank: 7Rank: 7Rank: 7

帖子
565
精华
0
声望
2971 点
金币
52 Mold
被赞许
36 次
注册时间
2010-2-13
发表于 2012-4-23 17:25:46 |显示全部楼层
本帖最后由 DSHGFHDS 于 2012-4-23 17:26 编辑

I show i just can speak Chinese'English.no know you said what, help no bird you
已有 1 人评分被赞许 收起 理由
navmesh + 1 thank you ^^

总评分: 被赞许 + 1   查看全部评分

欢迎加入讨论群 164384320

使用道具 举报

Rank: 5Rank: 5

帖子
131
精华
0
声望
867 点
金币
133 Mold
被赞许
10 次
注册时间
2010-12-31
发表于 2012-4-23 17:33:25 |显示全部楼层
Sad that I didn't got a compiler in this computer, as I've no longer working on amxx scripting, sorry but I really don't have time to do this.
已有 1 人评分被赞许 收起 理由
navmesh + 1 thanks man ,i really appreciate it ^^

总评分: 被赞许 + 1   查看全部评分

I am the bone of my Scripts,
So I pray, Unlimited Code Works.

使用道具 举报

Rank: 20Rank: 20Rank: 20Rank: 20Rank: 20

帖子
1150
精华
0
声望
115298 点
金币
7049 Mold
被赞许
43 次
注册时间
2012-3-1

可爱小猫 懒人勋章 星界财团 积分霸主

发表于 2012-4-23 17:40:03 |显示全部楼层
DSHGFHDS 发表于 2012-4-23 16:25
I show i just can speak Chinese'English.no know you said what, help no bird you

I  used translation tool to translate into chinese at first post
maybe it's not clearly
anyone who kind please translate into chinese for me ^^
thanks

我用翻译工具翻译成中文的第一篇文章
也许是不明确


任何一种,请为我翻译成中文^ ^
谢谢

使用道具 举报

Rank: 20Rank: 20Rank: 20Rank: 20Rank: 20

帖子
1150
精华
0
声望
115298 点
金币
7049 Mold
被赞许
43 次
注册时间
2012-3-1

可爱小猫 懒人勋章 星界财团 积分霸主

发表于 2012-4-23 20:36:15 |显示全部楼层
well i think changing the  "force round end" by alka is easier than "round terminator"

here is the code "force round end by alka"
it force the round end when roundtimer =0 ,
someone please edit sothat the round end when execute a command
thanks

这里是由碱性的部队回合结束
它迫使回合结束当roundtimer= 0,
有人请编辑充分使用回合结束时,执行命令
谢谢
  1. #include <amxmodx>
  2. #include <fakemeta>
  3. #include <cstrike>
  4. #include <fun>

  5. #define PLUGIN "Force Round End"
  6. #define VERSION "1.2"
  7. #define AUTHOR "Alka"

  8. #define CHECK_TIME 3.0 //Float

  9. #define TASK_ID 1337

  10. //Globals
  11. new bool:g_round_started;
  12. new g_roundtime, g_adv_time;
  13. new weapon[33][31];
  14. new CsArmorType:armortype[33];
  15. new armoramount[33];
  16. new g_maxplayers;

  17. //Cvars
  18. new
  19. toggle_plugin,
  20. g_show_adv,
  21. g_recive_weapons;

  22. stock const ents_list[][] = {
  23.        
  24.         "func_bomb_target",
  25.         "info_bomb_target",
  26.         "hostage_entity",
  27.         "monster_scientist",
  28.         "func_hostage_rescue",
  29.         "info_hostage_rescue",
  30.         "info_vip_start",
  31.         "func_vip_safetyzone",
  32.         "func_escapezone"
  33. }

  34. stock const WeaponNames[31][] = {
  35.         "",
  36.         "weapon_p228",
  37.         "",
  38.         "weapon_scout",
  39.         "weapon_hegrenade",
  40.         "weapon_xm1014",
  41.         "",
  42.         "weapon_mac10",
  43.         "weapon_aug",
  44.         "weapon_smokegrenade",
  45.         "weapon_elite",
  46.         "weapon_fiveseven",
  47.         "weapon_ump45",
  48.         "weapon_sg550",
  49.         "weapon_galil",
  50.         "weapon_famas",
  51.         "weapon_usp",
  52.         "weapon_glock18",
  53.         "weapon_awp",
  54.         "weapon_mp5navy",
  55.         "weapon_m249",
  56.         "weapon_m3",
  57.         "weapon_m4a1",
  58.         "weapon_tmp",
  59.         "weapon_g3sg1",
  60.         "weapon_flashbang",
  61.         "weapon_deagle",
  62.         "weapon_sg552",
  63.         "weapon_ak47",
  64.         "",
  65.         "weapon_p90"
  66. }

  67. public plugin_init(){
  68.        
  69.         register_plugin(PLUGIN, VERSION, AUTHOR);
  70.        
  71.         register_logevent("round_start", 2, "1=Round_Start");
  72.         register_logevent("round_end", 2, "1=Round_End");
  73.        
  74.         register_event("TextMsg", "round_restart", "a", "2&#Game_C", "2&#Game_w");
  75.        
  76.         register_message(get_user_msgid("RoundTime"), "Round_Timer");
  77.        
  78.         set_task(CHECK_TIME,"check_map");
  79.        
  80.         g_maxplayers = get_maxplayers();
  81.        
  82.         toggle_plugin = register_cvar("amx_fre","1");
  83.         g_show_adv = register_cvar("amx_fre_adv","1");
  84.         g_recive_weapons = register_cvar("amx_fre_rw","1");
  85. }


  86. public round_start() {
  87.        
  88.         if(get_pcvar_num(g_recive_weapons))
  89.         {
  90.                 give_weapons();
  91.         }
  92.         g_round_started = true;
  93. }

  94. public round_end()
  95.         remove_task(TASK_ID);

  96. public round_restart()
  97.         remove_task(TASK_ID);


  98. public Round_Timer()
  99. {
  100.         if(g_round_started)
  101.                 g_round_started = false;
  102.         else
  103.                 return;
  104.        
  105.         g_roundtime = get_msg_arg_int(1);
  106.         g_adv_time = (g_roundtime - 11); //Postponement fix. (11) - Round is ending after 0:00
  107.        
  108.         if(get_pcvar_num(toggle_plugin))
  109.         {
  110.                 set_task(float(g_roundtime), "force_end",TASK_ID);
  111.                 if(get_pcvar_num(g_show_adv))
  112.                 {
  113.                         set_task(float(g_adv_time), "show_adv",TASK_ID);
  114.                 }
  115.         }
  116. }

  117. public force_end()
  118. {
  119.         new g_players[32], num;
  120.         get_players(g_players, num);
  121.        
  122.         new x;
  123.         for(new i = 0; i < num; i++)
  124.         {
  125.                 x = g_players[i];
  126.                
  127.                 user_silentkill(x);
  128.                 cs_set_user_deaths(x, get_user_deaths(x) - 1);
  129.         }
  130. }

  131. public show_adv()
  132. {
  133.         set_hudmessage(0, 255, 0, -1.0, -1.0, 1, 6.0, 3.0,_,_,-1);
  134.         show_hudmessage(0, "10 Seconds until round end!");
  135.        
  136.         if(get_pcvar_num(g_recive_weapons))
  137.         {
  138.                 get_weapons();
  139.         }
  140. }

  141. public get_weapons()
  142. {
  143.         static i, i2
  144.         for( i=0 ; i<=g_maxplayers ; i++)
  145.         {
  146.                 arrayset(weapon[i],0,31)
  147.                 if(is_user_alive(i))
  148.                 {
  149.                         armoramount[i] = cs_get_user_armor(i,armortype[i])
  150.                         for(i2=1;i2<=30;i2++)
  151.                         {
  152.                                 if(i2!=2 && i2!=6 && i2!=29)
  153.                                 {
  154.                                         if(user_has_weapon(i,i2))
  155.                                         {
  156.                                                 weapon[i][i2] = cs_get_user_bpammo(i,i2)
  157.                                                 if(!weapon[i][i2])  weapon[i][i2] = 1
  158.                                         }
  159.                                 }
  160.                         }
  161.                 }
  162.         }
  163. }

  164. public give_weapons()
  165. {
  166.         new i, i2
  167.         for( i=0 ; i<=g_maxplayers ; i++)
  168.         {
  169.                 if(is_user_alive(i))
  170.                 {
  171.                        
  172.                         cs_set_user_armor(i,armoramount[i],armortype[i])
  173.                         strip_user_weapons(i)
  174.                         for(i2=1;i2<=30;i2++)
  175.                         {
  176.                                 if(i2!=2 && i2!=6 && i2!=29)
  177.                                 {
  178.                                         if(weapon[i][i2])
  179.                                         {
  180.                                                 give_item(i,WeaponNames[i2])
  181.                                                 cs_set_user_bpammo(i,i2,weapon[i][i2])
  182.                                         }
  183.                                 }
  184.                         }
  185.                         give_item(i,"weapon_knife")
  186.                 }
  187.         }
  188. }

  189. public check_map()
  190. {
  191.         for (new a = 0; a < sizeof ents_list; a++)
  192.         {
  193.                 if (engfunc(EngFunc_FindEntityByString, -1, "classname", ents_list[a]))
  194.                 {
  195.                         pause("a");
  196.                 }
  197.         }
  198. }
复制代码

使用道具 举报

Rank: 5Rank: 5

帖子
247
精华
0
声望
1053 点
金币
129 Mold
被赞许
2 次
注册时间
2008-9-15
发表于 2013-5-26 03:46:08 |显示全部楼层
这个插件只是强制处死玩家以达到回合结束
系统错误,请联系管理员

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

回顶部