28.12.2010, 20:00
♥Introduction
☻ This script was done by the applications that created drakon la ne a topic and went and did it ne![COLOR="rgb(139, 0, 0)"]☻[/COLOR]He pretty simple and you add security cameras using AddCamera
♥Como Usar
♥ AddCamera e usado da seguinte forma:pawn Код:
// Name X Y Z Angle
AddCamera("Los Santos", 1209.8090,-1751.8210,13.5937,2125.52);
@ Credits: HigorOliver
Coder :
pawn Код:
//==============================================================================
#include <a_samp>
#define FILTERSCRIPT // Define FS
#define MAX_CAM 500 // Max de Cameras
//==============================================================================
new
Total=-1;
enum
Cams
{
CameraN[100],
Float:Cod1,
Float:Cod2,
Float:Cod3,
Float:Angulo,
ID
};
new
Camera[MAX_CAM][Cams];
//==============================================================================
public
OnFilterScriptInit()
{
print("\n--------------------------------------");
print("System de Camera By: Higor (:");
print("--------------------------------------\n");
AddCamera("Los Santos", 1209.8090,-1751.8210,13.5937,2125.52);
return true;
}
//==============================================================================
stock
AddCamera(nomete[], Float:codd1, Float:codd2, Float:codd3,Float:angle1)
{
Total++;
format(Camera[Total][CameraN],100,"%s",nomete);
Camera[Total][Cod1] = codd1;
Camera[Total][Cod2] = codd2;
Camera[Total][Cod3] = codd3;
Camera[Total][Angulo] = angle1;
Camera[Total][ID] = Total;
printf("ID: %d Camera: %s ",Total,Camera[Total][CameraN]);
return true;
}
//==============================================================================
public
OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
new string[128];
if(listitem == Camera[listitem][ID])
{
if(!response) return false;
format(string, sizeof(string), "Camera -> %s", Camera[listitem][CameraN]);
SendClientMessage(playerid, 0xFFFFFFFF, string);
SetPlayerCameraPos(playerid,Camera[listitem][Cod1],Camera[listitem][Cod2],Camera[listitem][Cod3]);
SetPlayerFacingAngle(playerid,Camera[listitem][Angulo]);
return true;
}
return false;
}
//==============================================================================
public
OnPlayerCommandText(playerid, cmdtext[])
{
if(!strcmp(cmdtext, "/cameras", true)) {
new dados[1050];
format(dados, 1050, "");
for(new i=0;i<=Total;i++) {
format(dados,1050, "%s%s\n",dados,Camera[i][CameraN]);
}
ShowPlayerDialog(playerid,251,DIALOG_STYLE_LIST, "Cameras",dados,"Go", "Exit");
}
return false;
}