hello i cannot speak russian
i have a question about ultimate unpreacher
can you you use it to replace radio sounds for vip players?
void Radio1(CBasePlayer *player, int slot)
{
if (gpGlobals->time <= player->m_flRadioTime)
return;
if (player->m_iRadioMessages <= 0)
return;
player->m_iRadioMessages--;
player->m_flRadioTime = gpGlobals->time + 1.5;
switch (slot)
{
case 1: player->Radio("%!MRAD_COVERME", "#Cover_me"); break;
case 2: player->Radio("%!MRAD_TAKEPOINT", "#You_take_the_point"); break;
case 3: player->Radio("%!MRAD_POSITION", "#Hold_this_position"); break;
case 4: player->Radio("%!MRAD_REGROUP", "#Regroup_team"); break;
case 5: player->Radio("%!MRAD_FOLLOWME", "#Follow_me"); break;
case 6: player->Radio("%!MRAD_HITASSIST", "#Taking_fire"); break;
}
}
void Radio2(CBasePlayer *player, int slot)
{
if (gpGlobals->time <= player->m_flRadioTime)
return;
if (player->m_iRadioMessages <= 0)
return;
player->m_iRadioMessages--;
player->m_flRadioTime = gpGlobals->time + 1.5;
switch (slot)
{
case 1: player->Radio("%!MRAD_GO", "#Go_go_go"); break;
case 2: player->Radio("%!MRAD_FALLBACK", "#Team_fall_back"); break;
case 3: player->Radio("%!MRAD_STICKTOG", "#Stick_together_team"); break;
case 4: player->Radio("%!MRAD_GETINPOS", "#Get_in_position_and_wait"); break;
case 5: player->Radio("%!MRAD_STORMFRONT", "#Storm_the_front"); break;
case 6: player->Radio("%!MRAD_REPORTIN", "#Report_in_team"); break;
}
}
void Radio3(CBasePlayer *player, int slot)
{
if (gpGlobals->time <= player->m_flRadioTime)
return;
if (player->m_iRadioMessages <= 0)
return;
player->m_iRadioMessages--;
player->m_flRadioTime = gpGlobals->time + 1.5;
switch (slot)
{
case 1:
{
if (RANDOM_LONG(0, 1))
player->Radio("%!MRAD_AFFIRM", "#Affirmative");
else
player->Radio("%!MRAD_ROGER", "#Roger_that");
break;
}
case 2: player->Radio("%!MRAD_ENEMYSPOT", "#Enemy_spotted"); break;
case 3: player->Radio("%!MRAD_BACKUP", "#Need_backup"); break;
case 4: player->Radio("%!MRAD_CLEAR", "#Sector_clear"); break;
case 5: player->Radio("%!MRAD_INPOS", "#In_position"); break;
case 6: player->Radio("%!MRAD_REPRTINGIN", "#Reporting_in"); break;
case 7: player->Radio("%!MRAD_BLOW", "#Get_out_of_there"); break;
case 8: player->Radio("%!MRAD_NEGATIVE", "#Negative"); break;
case 9: player->Radio("%!MRAD_ENEMYDOWN", "#Enemy_down"); break;
}
}
void CBasePlayer::Radio(const char *msg_id, const char *msg_verbose, int pitch, bool showIcon)
{
if (!IsPlayer())
return;
if (pev->deadflag != DEAD_NO && !IsBot())
return;
CBaseEntity *pEntity = NULL;
while ((pEntity = UTIL_FindEntityByClassname(pEntity, "player")) != NULL)
{
if (FNullEnt(pEntity->edict()))
break;
CBasePlayer *pTarget = GetClassPtr((CBasePlayer *)pEntity->pev);
if (!pTarget->IsPlayer())
{
if (pTarget->pev->iuser1 == OBS_CHASE_LOCKED || pTarget->pev->iuser1 == OBS_CHASE_FREE || pTarget->pev->iuser1 == OBS_IN_EYE)
{
if (!FNullEnt(m_hObserverTarget))
pTarget = (CBasePlayer *)((CBaseEntity *)m_hObserverTarget);
else
pTarget = NULL;
}
}
else
{
if (pTarget->pev->flags == FL_DORMANT)
pTarget = NULL;
}
if (!pTarget)
continue;
if (pTarget->m_iTeam != m_iTeam)
continue;
if (pTarget->m_bIgnoreRadio)
continue;
MESSAGE_BEGIN(MSG_ONE, gmsgSendAudio, NULL, pTarget->pev);
WRITE_BYTE(ENTINDEX(edict()));
WRITE_STRING(msg_id);
WRITE_SHORT(pitch);
MESSAGE_END();
if (msg_verbose)
ClientPrint(pTarget->pev, HUD_PRINTRADIO, NumAsString(ENTINDEX(edict())), "#Game_radio", STRING(pev->netname), msg_verbose);
if (showIcon)
{
MESSAGE_BEGIN(MSG_ONE, SVC_TEMPENTITY, NULL, pTarget->pev);
WRITE_BYTE(TE_PLAYERATTACHMENT);
WRITE_BYTE(ENTINDEX(edict()));
WRITE_COORD(35);
WRITE_SHORT(g_sModelIndexRadio);
WRITE_SHORT(15);
MESSAGE_END();
}
}
}
Зачем, если прямо в нем, без декомпиляции, можно изменить звук или вовсе убрать?! ?MayroN, hlmodelviewer качаешь, распаковвваешь нужную модель со звуком, заменяешь звук, запаковыааешь модель обратно
+Just listing the path in list.ini ?
models/v_sg550.mdl
models/v_g3sg1.mdl
models/p_sg550.mdl
models/p_g3sg1.mdl
models/w_sg550.mdl
models/w_g3sg1.mdl
models/p_shield.mdl
models/v_shield.mdl
models/w_shield.mdl
models/shield/p_shield_deagle.mdl
models/shield/p_shield_fiveseven.mdl
models/shield/p_shield_flashbang.mdl
models/shield/p_shield_glock18.mdl
models/shield/p_shield_hegrenade.mdl
models/shield/p_shield_knife.mdl
models/shield/p_shield_p228.mdl
models/shield/p_shield_smokegrenade.mdl
models/shield/p_shield_usp.mdl
models/shield/v_shield_deagle.mdl
models/shield/v_shield_fiveseven.mdl
models/shield/v_shield_flashbang.mdl
models/shield/v_shield_glock18.mdl
models/shield/v_shield_hegrenade.mdl
models/shield/v_shield_knife.mdl
models/shield/v_shield_p228.mdl
models/shield/v_shield_smokegrenade.mdl
models/shield/v_shield_usp.mdl
Thanks bro :)+
Код:models/v_sg550.mdl models/v_g3sg1.mdl models/p_sg550.mdl models/p_g3sg1.mdl models/w_sg550.mdl models/w_g3sg1.mdl models/p_shield.mdl models/v_shield.mdl models/w_shield.mdl models/shield/p_shield_deagle.mdl models/shield/p_shield_fiveseven.mdl models/shield/p_shield_flashbang.mdl models/shield/p_shield_glock18.mdl models/shield/p_shield_hegrenade.mdl models/shield/p_shield_knife.mdl models/shield/p_shield_p228.mdl models/shield/p_shield_smokegrenade.mdl models/shield/p_shield_usp.mdl models/shield/v_shield_deagle.mdl models/shield/v_shield_fiveseven.mdl models/shield/v_shield_flashbang.mdl models/shield/v_shield_glock18.mdl models/shield/v_shield_hegrenade.mdl models/shield/v_shield_knife.mdl models/shield/v_shield_p228.mdl models/shield/v_shield_smokegrenade.mdl models/shield/v_shield_usp.mdl
try it but I'm not sureBtw we Don't even use any hostage Maps, Soyou know what more can be disabled ? for hostages ?
models/hostage.mdl
yup)What if I put a model entry in list.ini, & any map uses that model.. Will Server Crash at start of that map ?
map_name.ini
or for maps with some prefix prefix-my_map_prefix.ini
.Also can "sound/hostage/" 5 sounds.Btw we Don't even use any hostage Maps, Soyou know what more can be disabled ? for hostages ?