06.08.2014, 16:11
(
Последний раз редактировалось Zume; 30.12.2014 в 06:59.
)
Es una simple herramienta para facilitar la bъsqueda de sonidos. Tomen en cuenta que es solamente un tool.
(Pastebin: http://pastebin.com/89ZP2GNK).
pawn Код:
#include <a_samp>
#define DIALOGO_SONIDOS 240
stock SonidosSAMP[][] =
{
{1002, "SOUND_CEILING_VENT_LAND"},
{1009, "SOUND_BONNET_DENT"},
{1027, "SOUND_WHEEL_OF_FORTUNE_CLACKER"},
{1035, "SOUND_SHUTTER_DOOR_START"},
{1036, "SOUND_SHUTTER_DOOR_STOP"},
{1039, "SOUND_PARACHUTE_OPEN"},
{1052, "SOUND_AMMUNATION_BUY_WEAPON"},
{1053, "SOUND_AMMUNATION_BUY_WEAPON_DENIED"},
{1054, "SOUND_SHOP_BUY"},
{1055, "SOUND_SHOP_BUY_DENIED"},
{1056, "SOUND_RACE_321"},
{1057, "SOUND_RACE_GO"},
{1058, "SOUND_PART_MISSION_COMPLETE"},
{1062, "SOUND_GOGO_TRACK_START (music)"},
{1068, "SOUND_GOGO_TRACK_STOP (music)"},
{1063, "SOUND_DUAL_TRACK_START (music)"},
{1069, "SOUND_DUAL_TRACK_STOP (music)"},
{1076, "SOUND_BEE_TRACK_START (music)"},
{1077, "SOUND_BEE_TRACK_STOP (music)"},
{1083, "SOUND_ROULETTE_ADD_CASH"},
{1084, "SOUND_ROULETTE_REMOVE_CASH"},
{1085, "SOUND_ROULETTE_NO_CASH"},
{1095, "SOUND_BIKE_PACKER_CLUNK"},
{1097, "SOUND_AWARD_TRACK_START (music)"},
{1098, "SOUND_AWARD_TRACK_STOP (music)"},
{1100, "SOUND_MESH_GATE_OPEN_START"},
{1101, "SOUND_MESH_GATE_OPEN_STOP"},
{1130, "SOUND_PUNCH_PED"},
{1131, "SOUND_AMMUNATION_GUN_COLLISION"},
{1132, "SOUND_CAMERA_SHOT"},
{1133, "SOUND_BUY_CAR_MOD"},
{1134, "SOUND_BUY_CAR_RESPRAY"},
{1135, "SOUND_BASEBALL_BAT_HIT_PED"},
{1136, "SOUND_STAMP_PED"},
{1137, "SOUND_CHECKPOINT_AMBER"},
{1138, "SOUND_CHECKPOINT_GREEN"},
{1139, "SOUND_CHECKPOINT_RED"},
{1140, "SOUND_CAR_SMASH_CAR"},
{1141, "SOUND_CAR_SMASH_GATE"},
{1142, "SOUND_OTB_TRACK_START"},
{1143, "SOUND_OTB_TRACK_STOP"},
{1144, "SOUND_PED_HIT_WATER_SPLASH"},
{1145, "SOUND_RESTAURANT_TRAY_COLLISION"},
{1147, "SOUND_SWEETS_HORN"},
{1148, "SOUND_MAGNET_VEHICLE_COLLISION"},
{1149, "SOUND_PROPERTY_PURCHASED"},
{1150, "SOUND_PICKUP_STANDARD"},
{1153, "SOUND_GARAGE_DOOR_START"},
{1154, "SOUND_GARAGE_DOOR_STOP"},
{1163, "SOUND_PED_COLLAPSE"},
{1165, "SOUND_SHUTTER_DOOR_SLOW_START"},
{1166, "SOUND_SHUTTER_DOOR_SLOW_STOP"},
{1169, "SOUND_RESTAURANT_CJ_PUKE"},
{1183, "SOUND_DRIVING_AWARD_TRACK_START (music)"},
{1184, "SOUND_DRIVING_AWARD_TRACK_STOP"},
{1185, "SOUND_BIKE_AWARD_TRACK_START (music)"},
{1186, "SOUND_BIKE_AWARD_TRACK_STOP"},
{1187, "SOUND_PILOT_AWARD_TRACK_START (music)"},
{1188, "SOUND_PILOT_AWARD_TRACK_STOP"},
{1190, "SOUND_SLAP"}
};
new SonidosArray[MAX_PLAYERS][sizeof(SonidosSAMP)];
main()
{
}
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/sonidos", cmdtext, true, 10) == 0)
{
for(new s = 0; s < sizeof(SonidosSAMP); s++)
{
SonidosArray[playerid][s] = -1;
}
new S_[128], X_[2500], art = 0;
for (new x = 0; x < sizeof(SonidosSAMP); x++)
{
if(art < sizeof(SonidosSAMP))
{
format(S_, sizeof(S_), "%s - %d\n", SonidosSAMP[x][1], SonidosSAMP[x][0]);
strcat(X_, S_);
SonidosArray[playerid][art] = x;
art++;
}
}
ShowPlayerDialog(playerid, DIALOGO_SONIDOS, DIALOG_STYLE_LIST, "Buscador de sonidos SA:MP.", X_, "Reproducir", "Salir");
return 1;
}
return 0;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
switch(dialogid)
{
case DIALOGO_SONIDOS:
{
if(response)
{
new Float:p_[3];
GetPlayerPos(playerid, p_[0], p_[1], p_[2]);
PlayerPlaySound(playerid, 1186, p_[0], p_[1], p_[2]);
PlayerPlaySound(playerid, SonidosSAMP[SonidosArray[playerid][listitem]][0], p_[0], p_[1], p_[2]);
}
}
}
return 1;
}