广告广告
  加入我的最爱 设为首页 风格修改
首页 首尾
 手机版   订阅   地图  繁体 
您是第 2023 个阅读者
 
发表文章 发表投票 回覆文章
  可列印版   加为IE收藏   收藏主题   上一主题 | 下一主题   
陈维亨
个人文章 个人相簿 个人日记 个人地图
路人甲
级别: 路人甲 该用户目前不上站
推文 x0 鲜花 x10
分享: 转寄此文章 Facebook Plurk Twitter 复制连结到剪贴簿 转换为繁体 转换为简体 载入图片
推文 x0
[1.6][插件] 求zp4.3问题一问!! 因该不难  (help me! help me! please)
当我开启解毒剂购买时,
bot只要买完解毒剂转人类时虽然有成功,
但为何他的模型还是僵尸,请问版上的大大有人能帮帮我解决吗?
拜托! 拜托! 表情 表情


献花 x0 回到顶端 [楼 主] From:台湾中华电信股份有限公司 | Posted:2013-12-25 20:53 |
a7811311622 手机
个人头像
个人文章 个人相簿 个人日记 个人地图
特殊贡献奖 优秀管理员勋章 社区建设奖
头衔:我…在工作了…我…在工作了…
版主
级别: 版主 该用户目前不上站
版区: CS提问区
推文 x771 鲜花 x2152
分享: 转寄此文章 Facebook Plurk Twitter 复制连结到剪贴簿 转换为繁体 转换为简体 载入图片

下面是引用 陈维亨 于 2013-12-25 20:53 发表的 help me! help me! please,|求zp4.3问题一问!! 因该不难: 到引言文
当我开启解毒剂购买时,
bot只要买完解毒剂转人类时虽然有成功,
但为何他的模型还是僵尸,请问版上的大大有人能帮帮我解决吗?
拜托! 拜托! 表情  表情
问题可能会演变成复杂化…
先是单纯的可能1:humanme(id, survivor, silentmode) 里转变模组的内容出问题…
麻烦的可能2:其他哪个插件很脑残的用 public zp_user_humanized_post(id) 去转变模组…
可是鬼知道哪个插件这么做…


尚无签名,欢迎 [新增个性化签名]
献花 x1 回到顶端 [1 楼] From:台湾中华电信股份有限公司 | Posted:2013-12-26 00:05 |
陈维亨
个人文章 个人相簿 个人日记 个人地图
路人甲
级别: 路人甲 该用户目前不上站
推文 x0 鲜花 x10
分享: 转寄此文章 Facebook Plurk Twitter 复制连结到剪贴簿 转换为繁体 转换为简体 载入图片

敢请大大帮我察看哪里出了问题?
拜托!拜托!

humanme(id, survivor, silentmode)
{
     // User humanize attempt forward
     ExecuteForward(g_fwUserHumanize_attempt, g_fwDummyResult, id, survivor)
     
     // One or more plugins blocked the "humanization". Only allow this after making sure it's
     // not going to leave us with no humans. Take into account a last player leaving case.
     // BUGFIX: only allow after a mode has started, to prevent blocking first survivor e.g.
     if (g_fwDummyResult >= ZP_PLUGIN_HANDLED && g_modestarted && fnGetHumans() > g_lastplayerleaving)
           return;
     
     // Pre user humanize forward
     ExecuteForward(g_fwUserHumanized_pre, g_fwDummyResult, id, survivor)
     
     // Remove previous tasks
     remove_task(id+TASK_MODEL)
     remove_task(id+TASK_BLOOD)
     remove_task(id+TASK_AURA)
     remove_task(id+TASK_BURN)
     remove_task(id+TASK_NVISION)
     
     // Reset some vars
     g_zombie[id] = false
     g_nemesis[id] = false
     g_survivor[id] = false
     g_firstzombie[id] = false
     g_canbuy[id] = true
     g_nvision[id] = false
     g_nvisionenabled[id] = false
     
     // Remove survivor's aura (bugfix)
     set_pev(id, pev_effects, pev(id, pev_effects) &~ EF_BRIGHTLIGHT)
     
     // Remove spawn protection (bugfix)
     g_nodamage[id] = false
     set_pev(id, pev_effects, pev(id, pev_effects) &~ EF_NODRAW)
     
     // Reset burning duration counter (bugfix)
     g_burning_duration[id] = 0
     
     // Drop previous weapons
     drop_weapons(id, 1)
     drop_weapons(id, 2)
     
     // Strip off from weapons
     fm_strip_user_weapons(id)
     fm_give_item(id, "weapon_knife")
     
     // Set human attributes based on the mode
     if (survivor)
     {
           // Survivor
           g_survivor[id] = true
           
           // Set Health [0 = auto]
           if (get_pcvar_num(cvar_survhp) == 0)
           {
                 if (get_pcvar_num(cvar_survbasehp) == 0)
                       fm_set_user_health(id, get_pcvar_num(cvar_humanhp) * fnGetAlive())
                 else
                       fm_set_user_health(id, get_pcvar_num(cvar_survbasehp) * fnGetAlive())
           }
           else
                 fm_set_user_health(id, get_pcvar_num(cvar_survhp))
           
           // Set gravity, unless frozen
           if (!g_frozen[id]) set_pev(id, pev_gravity, get_pcvar_float(cvar_survgravity))
           
           // Give survivor his own weapon
           static survweapon[32]
           get_pcvar_string(cvar_survweapon, survweapon, charsmax(survweapon))
           fm_give_item(id, survweapon)
           ExecuteHamB(Ham_GiveAmmo, id, MAXBPAMMO[cs_weapon_name_to_id(survweapon)], AMMOTYPE[cs_weapon_name_to_id(survweapon)], MAXBPAMMO[cs_weapon_name_to_id(survweapon)])
           
           // Turn off his flashlight
           turn_off_flashlight(id)
           
           // Give the survivor a bright light
           if (get_pcvar_num(cvar_survaura)) set_pev(id, pev_effects, pev(id, pev_effects) | EF_BRIGHTLIGHT)
           
           // Survivor bots will also need nightvision to see in the dark
           if (g_isbot[id])
           {
                 g_nvision[id] = true
                 cs_set_user_nvg(id, 1)
           }
     } 表情 表情 表情 表情 表情 表情


献花 x0 回到顶端 [2 楼] From:台湾中华电信股份有限公司 | Posted:2013-12-26 01:35 |
a7811311622 手机
个人头像
个人文章 个人相簿 个人日记 个人地图
特殊贡献奖 优秀管理员勋章 社区建设奖
头衔:我…在工作了…我…在工作了…
版主
级别: 版主 该用户目前不上站
版区: CS提问区
推文 x771 鲜花 x2152
分享: 转寄此文章 Facebook Plurk Twitter 复制连结到剪贴簿 转换为繁体 转换为简体 载入图片

下面是引用 陈维亨 于 2013-12-26 01:35 发表的 : 到引言文
敢请大大帮我察看哪里出了问题?
拜托!拜托!
humanme(id, survivor, silentmode)
{
     // User humanize attempt forward
.......
别说这就是全部的内容…
如果真的是…这段根本残废了…
我手边一个干净(姑且是?)的ZP4.3源码是这样:
复制程式
// Function Human Me (player id, turn into a survivor, silent mode)
humanme(id, survivor, silentmode)
{
    // User humanize attempt forward
    ExecuteForward(g_fwUserHumanize_attempt, g_fwDummyResult, id, survivor)
    
    // One or more plugins blocked the "humanization". Only allow this after making sure it's
    // not going to leave us with no humans. Take into account a last player leaving case.
    // BUGFIX: only allow after a mode has started, to prevent blocking first survivor e.g.
    if (g_fwDummyResult >= ZP_PLUGIN_HANDLED && g_modestarted && fnGetHumans() > g_lastplayerleaving)
        return;
    
    // Pre user humanize forward
    ExecuteForward(g_fwUserHumanized_pre, g_fwDummyResult, id, survivor)
    
    // Remove previous tasks
    remove_task(id+TASK_MODEL)
    remove_task(id+TASK_BLOOD)
    remove_task(id+TASK_AURA)
    remove_task(id+TASK_BURN)
    remove_task(id+TASK_NVISION)
    
    // Reset some vars
    g_zombie[id] = false
    g_nemesis[id] = false
    g_survivor[id] = false
    g_firstzombie[id] = false
    g_canbuy[id] = true
    g_nvision[id] = false
    g_nvisionenabled[id] = false
    
    // Remove survivor's aura (bugfix)
    set_pev(id, pev_effects, pev(id, pev_effects) &~ EF_BRIGHTLIGHT)
    
    // Remove spawn protection (bugfix)
    g_nodamage[id] = false
    set_pev(id, pev_effects, pev(id, pev_effects) &~ EF_NODRAW)
    
    // Reset burning duration counter (bugfix)
    g_burning_duration[id] = 0
    
    // Drop previous weapons
    drop_weapons(id, 1)
    drop_weapons(id, 2)
    
    // Strip off from weapons
    fm_strip_user_weapons(id)
    fm_give_item(id, "weapon_knife")
    
    // Set human attributes based on the mode
    if (survivor)
    {
        // Survivor
        g_survivor[id] = true
        
        // Set Health [0 = auto]
        if (get_pcvar_num(cvar_survhp) == 0)
        {
            if (get_pcvar_num(cvar_survbasehp) == 0)
                fm_set_user_health(id, get_pcvar_num(cvar_humanhp) * fnGetAlive())
            else
                fm_set_user_health(id, get_pcvar_num(cvar_survbasehp) * fnGetAlive())
        }
        else
            fm_set_user_health(id, get_pcvar_num(cvar_survhp))
        
        // Set gravity, unless frozen
        if (!g_frozen[id]) set_pev(id, pev_gravity, get_pcvar_float(cvar_survgravity))
        
        // Give survivor his own weapon
        static survweapon[32]
        get_pcvar_string(cvar_survweapon, survweapon, charsmax(survweapon))
        fm_give_item(id, survweapon)
        ExecuteHamB(Ham_GiveAmmo, id, MAXBPAMMO[cs_weapon_name_to_id(survweapon)], AMMOTYPE[cs_weapon_name_to_id(survweapon)], MAXBPAMMO[cs_weapon_name_to_id(survweapon)])
        
        // Turn off his flashlight
        turn_off_flashlight(id)
        
        // Give the survivor a bright light
        if (get_pcvar_num(cvar_survaura)) set_pev(id, pev_effects, pev(id, pev_effects) | EF_BRIGHTLIGHT)
        
        // Survivor bots will also need nightvision to see in the dark
        if (g_isbot[id])
        {
            g_nvision[id] = true
            cs_set_user_nvg(id, 1)
        }
    }
    else
    {
        // Human taking an antidote
        
        // Set health
        fm_set_user_health(id, get_pcvar_num(cvar_humanhp))
        
        // Set gravity, unless frozen
        if (!g_frozen[id]) set_pev(id, pev_gravity, get_pcvar_float(cvar_humangravity))
        
        // Show custom buy menu?
        if (get_pcvar_num(cvar_buycustom))
            set_task(0.2, "show_menu_buy1", id+TASK_SPAWN)
        
        // Silent mode = no HUD messages, no antidote sound
        if (!silentmode)
        {
            // Antidote sound
            static sound[64]
            ArrayGetString(sound_antidote, random_num(0, ArraySize(sound_antidote) - 1), sound, charsmax(sound))
            emit_sound(id, CHAN_ITEM, sound, 1.0, ATTN_NORM, 0, PITCH_NORM)
            
            // Show Antidote HUD notice
            set_hudmessage(0, 0, 255, HUD_INFECT_X, HUD_INFECT_Y, 0, 0.0, 5.0, 1.0, 1.0, -1)
            ShowSyncHudMsg(0, g_MsgSync, "%L", LANG_PLAYER, "NOTICE_ANTIDOTE", g_playername[id])
        }
    }
    
    // Switch to CT
    if (fm_cs_get_user_team(id) != FM_CS_TEAM_CT) // need to change team?
    {
        remove_task(id+TASK_TEAM)
        fm_cs_set_user_team(id, FM_CS_TEAM_CT)
        fm_user_team_update(id)
    }
    
    // Custom models stuff
    static currentmodel[32], tempmodel[32], already_has_model, i, iRand, size
    already_has_model = false
    
    if (g_handle_models_on_separate_ent)
    {
        // Set the right model
        if (g_survivor[id])
        {
            iRand = random_num(0, ArraySize(model_survivor) - 1)
            ArrayGetString(model_survivor, iRand, g_playermodel[id], charsmax(g_playermodel[]))
            if (g_set_modelindex_offset) fm_cs_set_user_model_index(id, ArrayGetCell(g_modelindex_survivor, iRand))
        }
        else
        {
            if (get_pcvar_num(cvar_adminmodelshuman) && (get_user_flags(id) & g_access_flag[ACCESS_ADMIN_MODELS]))
            {
                iRand = random_num(0, ArraySize(model_admin_human) - 1)
                ArrayGetString(model_admin_human, iRand, g_playermodel[id], charsmax(g_playermodel[]))
                if (g_set_modelindex_offset) fm_cs_set_user_model_index(id, ArrayGetCell(g_modelindex_admin_human, iRand))
            }
            else
            {
                iRand = random_num(0, ArraySize(model_human) - 1)
                ArrayGetString(model_human, iRand, g_playermodel[id], charsmax(g_playermodel[]))
                if (g_set_modelindex_offset) fm_cs_set_user_model_index(id, ArrayGetCell(g_modelindex_human, iRand))
            }
        }
        
        // Set model on player model entity
        fm_set_playermodel_ent(id)
        
        // Set survivor glow / remove glow on player model entity, unless frozen
        if (!g_frozen[id])
        {
            if (g_survivor[id] && get_pcvar_num(cvar_survglow))
                fm_set_rendering(g_ent_playermodel[id], kRenderFxGlowShell, 0, 0, 255, kRenderNormal, 25)
            else
                fm_set_rendering(g_ent_playermodel[id])
        }
    }
    else
    {
        // Get current model for comparing it with the current one
        fm_cs_get_user_model(id, currentmodel, charsmax(currentmodel))
        
        // Set the right model, after checking that we don't already have it
        if (g_survivor[id])
        {
            size = ArraySize(model_survivor)
            for (i = 0; i < size; i++)
            {
                ArrayGetString(model_survivor, i, tempmodel, charsmax(tempmodel))
                if (equal(currentmodel, tempmodel)) already_has_model = true
            }
            
            if (!already_has_model)
            {
                iRand = random_num(0, size - 1)
                ArrayGetString(model_survivor, iRand, g_playermodel[id], charsmax(g_playermodel[]))
                if (g_set_modelindex_offset) fm_cs_set_user_model_index(id, ArrayGetCell(g_modelindex_survivor, iRand))
            }
        }
        else
        {
            if (get_pcvar_num(cvar_adminmodelshuman) && (get_user_flags(id) & g_access_flag[ACCESS_ADMIN_MODELS]))
            {
                size = ArraySize(model_admin_human)
                for (i = 0; i < size; i++)
                {
                    ArrayGetString(model_admin_human, i, tempmodel, charsmax(tempmodel))
                    if (equal(currentmodel, tempmodel)) already_has_model = true
                }
                
                if (!already_has_model)
                {
                    iRand = random_num(0, size - 1)
                    ArrayGetString(model_admin_human, iRand, g_playermodel[id], charsmax(g_playermodel[]))
                    if (g_set_modelindex_offset) fm_cs_set_user_model_index(id, ArrayGetCell(g_modelindex_admin_human, iRand))
                }
            }
            else
            {
                size = ArraySize(model_human)
                for (i = 0; i < size; i++)
                {
                    ArrayGetString(model_human, i, tempmodel, charsmax(tempmodel))
                    if (equal(currentmodel, tempmodel)) already_has_model = true
                }
                
                if (!already_has_model)
                {
                    iRand = random_num(0, size - 1)
                    ArrayGetString(model_human, iRand, g_playermodel[id], charsmax(g_playermodel[]))
                    if (g_set_modelindex_offset) fm_cs_set_user_model_index(id, ArrayGetCell(g_modelindex_human, iRand))
                }
            }
        }
        
        // Need to change the model?
        if (!already_has_model)
        {
            // An additional delay is offset at round start
            // since SVC_BAD is more likely to be triggered there
            if (g_newround)
                set_task(5.0 * g_modelchange_delay, "fm_user_model_update", id+TASK_MODEL)
            else
                fm_user_model_update(id+TASK_MODEL)
        }
        
        // Set survivor glow / remove glow, unless frozen
        if (!g_frozen[id])
        {
            if (g_survivor[id] && get_pcvar_num(cvar_survglow))
                fm_set_rendering(id, kRenderFxGlowShell, 0, 0, 255, kRenderNormal, 25)
            else
                fm_set_rendering(id)
        }
    }
    
    // Restore FOV?
    if (get_pcvar_num(cvar_zombiefov) != 90 && get_pcvar_num(cvar_zombiefov) != 0)
    {
        message_begin(MSG_ONE, g_msgSetFOV, _, id)
        write_byte(90) // angle
        message_end()
    }
    
    // Disable nightvision
    if (g_isbot[id]) cs_set_user_nvg(id, 0)
    else if (!get_pcvar_num(cvar_customnvg) && g_nvisionenabled[id]) set_user_gnvision(id, 0)
    
    // Post user humanize forward
    ExecuteForward(g_fwUserHumanized_post, g_fwDummyResult, id, survivor)
    
    // Last Zombie Check
    fnCheckLastZombie()
}



尚无签名,欢迎 [新增个性化签名]
献花 x0 回到顶端 [3 楼] From:台湾中华电信股份有限公司 | Posted:2013-12-26 10:22 |
陈维亨
个人文章 个人相簿 个人日记 个人地图
路人甲
级别: 路人甲 该用户目前不上站
推文 x0 鲜花 x10
分享: 转寄此文章 Facebook Plurk Twitter 复制连结到剪贴簿 转换为繁体 转换为简体 载入图片

试了之后发现是其他插件的问题! ))好险插件安装不多==
您给我的那段试了之后发现问题还在
所以我开始找其他插件有没有问题
还是谢谢您的解答
a7811311622 大大 表情


献花 x0 回到顶端 [4 楼] From:台湾中华电信股份有限公司 | Posted:2013-12-26 20:17 |

首页  发表文章 发表投票 回覆文章
Powered by PHPWind v1.3.6
Copyright © 2003-04 PHPWind
Processed in 0.023197 second(s),query:16 Gzip disabled
本站由 瀛睿律师事务所 担任常年法律顾问 | 免责声明 | 本网站已依台湾网站内容分级规定处理 | 连络我们 | 访客留言