X

由于无法提供服务器的高昂费用,博客即将迁移到github pages...

点击右上的X可以临时关闭此框并阻止跳转^_^

现在带您过去 秒后跳转...

SAMP-地图-新鞋停车场围栏Obj

    新鞋停车场围栏

    下面是围栏的创建,写入OnGameModeInit()函数即可;

     	CreateObject(985, 1407.17517, -2267.35474, 12.53770,   0.00000, 0.00000, 180.00000);
    	CreateObject(985, 1415.00610, -2267.35474, 12.53770,   0.00000, 0.00000, 180.00000);
    	CreateObject(985, 1399.33862, -2267.35474, 12.53770,   0.00000, 0.00000, 180.00000);
    	CreateObject(985, 1399.33862, -2267.35474, 12.53770,   0.00000, 0.00000, 180.00000);
    	CreateObject(985, 1391.50842, -2267.35474, 12.53770,   0.00000, 0.00000, 180.00000);
    	CreateObject(985, 1383.69531, -2267.35474, 12.53770,   0.00000, 0.00000, 180.00000);
    	CreateObject(985, 1371.91162, -2263.42041, 12.53770,   0.00000, 0.00000, 90.00000);
    	CreateObject(985, 1371.91162, -2255.59082, 12.53770,   0.00000, 0.00000, 90.00000);
    	CreateObject(985, 1371.91162, -2247.79932, 12.53770,   0.00000, 0.00000, 90.00000);
    	CreateObject(985, 1371.91162, -2240.01318, 12.53770,   0.00000, 0.00000, 90.00000);
    	CreateObject(985, 1371.91162, -2232.20728, 12.53770,   0.00000, 0.00000, 90.00000);
    	CreateObject(985, 1371.91162, -2224.41846, 12.53770,   0.00000, 0.00000, 90.00000);
    	CreateObject(985, 1371.91162, -2216.63135, 12.53770,   0.00000, 0.00000, 90.00000);
    	CreateObject(985, 1371.91162, -2208.81470, 12.53770,   0.00000, 0.00000, 90.00000);
    	CreateObject(985, 1383.63245, -2204.85791, 12.53770,   0.00000, 0.00000, 0.00000);
    	CreateObject(985, 1391.45520, -2204.85791, 12.53770,   0.00000, 0.00000, 0.00000);
    	CreateObject(985, 1399.27893, -2204.85791, 12.53770,   0.00000, 0.00000, 0.00000);
    	CreateObject(985, 1407.10815, -2204.85791, 12.53770,   0.00000, 0.00000, 0.00000);
    	CreateObject(985, 1418.95215, -2263.45361, 12.53770,   0.00000, 0.00000, -90.00000);
    	CreateObject(985, 1418.95215, -2255.62061, 12.53770,   0.00000, 0.00000, -90.00000);
    	CreateObject(985, 1418.95215, -2247.78955, 12.53770,   0.00000, 0.00000, -90.00000);
    	CreateObject(985, 1418.95215, -2239.96265, 12.53770,   0.00000, 0.00000, -90.00000);
    	CreateObject(985, 1418.95215, -2224.43652, 12.53770,   0.00000, 0.00000, -90.00000);
    	CreateObject(985, 1418.95215, -2208.79883, 12.53770,   0.00000, 0.00000, -90.00000);
    	CreateObject(985, 1418.95215, -2216.62427, 12.53770,   0.00000, 0.00000, -90.00000);
    	CreateObject(985, 1375.85364, -2267.35474, 12.53770,   0.00000, 0.00000, 180.00000);
    	CreateObject(985, 1375.78442, -2204.85791, 12.53770,   0.00000, 0.00000, 180.00000);
    

    接下来是遥控门的代码:(左右打开的门)

    /* 首先声明两个门的变量: */
    new xxgate1;
    new xxgate2;
    
    /* 一个函数: */
    forward GateCloseXx();
    
    /* 初始化动态对象 写在public OnGameModeInit()函数体里面 */
    	xxgate1 = CreateObject(988,1419.0482,-2235.0635,13.5822,0.00000,0.00000,90.00000);
    	xxgate2 = CreateObject(988,1419.0477,-2229.5605,13.5822,0.00000,0.00000,90.00000);
    
    /* 函数代码实例: */
    public GateCloseXx()
    {
          //DestroyDynamicObject( xxgate2 );
          MoveObject(xxgate1,1419.0482,-2235.0635,13.5822,2,0.00000,0.00000,90.0000);
          MoveObject(xxgate2,1419.0477,-2229.5605,13.5822,2,0.00000,0.00000,90.0000);
          lsxinxie = 0;
          return 1;
    }
    
    /* 开门指令: */
    		/* 找到下面的代码 */
    	if(!strcmp(cmdtext, "/go", true)) // By CuervO_NegrO
    	{
    	    if(IsAPDMember(playerid) || IsAFreecop(playerid))
    		{
    			.......
    		}
    		...
    		...
    		...
    		/* 下面是新增的 */
    		else if(PlayerInfo[playerid][pMember] == 11 || PlayerInfo[playerid][pLeader] == 11)
    		{
    			if (IsPlayerInRangeOfPoint(playerid, 15,1419.3103,-2232.0325,12.8972))
    			{
    				if(lsxinxie == 1) { SendClientMessage(playerid, COLOR_GREY, "** 新鞋停车场门已经打开了"); return 1; }
    		      	MoveObject(xxgate1,1419.0482,-2238.0635,13.5822,2,0.00000,0.00000,90.0000);
    		      	MoveObject(xxgate2,1419.0477,-2225.5605,13.5822,2,0.00000,0.00000,90.0000);
    		      	SetTimer("GateCloseXx", 6000, 0);
    		      	SendClientMessage(playerid, COLOR_BLUE,"新鞋停场大门打开了并将在6秒后关闭.");
    
    		      	format(string, sizeof(string), "* %s 打开了 新鞋停车场大门.", sendername);
    		      	ProxDetector(30.0, playerid, string, COLOR_CHAT1,COLOR_CHAT2,COLOR_CHAT3,COLOR_CHAT4,COLOR_CHAT5);
    		      	lsxinxie = 1;
    			}
    			else
    			{
    				SendClientMessage(playerid, COLOR_GREY,"* 你附近没有可以打开的门 新鞋!.");
    				return 1;
    			}
    		}
    		/* 上面是新增的 */
    		/* 下面是已经有的 */
    		else
    		{
    			SendClientMessage(playerid, COLOR_GREY,"* 你没有开门的遥控器.");
    		}
    		return 1;
    	}
    

数据库系统的基本概念

    1. 数据(Data):数据是数据库中存储的基本对象,它有多种表现形式。数据是描述事物的符号记录,这些符号可以是文字、图形、声音和图像等。
    2. 数据库(DataBase,DB):数据库是一个长期存储在计算机内的,有组织的、可共享的、统一管理的数据集合。
    3. 数据库管理系统(DataBase Management,DBMS):数据库管理系统是为数据库的建立、使用和维护而配置的系统软件。
      1. 数据定义功能
      2. 数据操作功能
      3. 数据库的运行管理功能
      4. 数据库的建立和维护功能
    4. 数据库管理员(DataBase Administrator,DBA):数据库管理员是负责管理和维护数据库服务器的人员
      1. DBA应参与数据库和应用系统的设计
      2. DBA应参与决定数据库的存储结构和存取策略的工作
      3. DBA要负责定义数据的安全性要求和完整性要求
      4. DBA负责监视和控制数据库系统的运行以及系统的维护和数据恢复工作
      5. DBA负责数据库的改进和重组
    5. 数据库系统(Database System,DBS):数据库系统是指在计算机系统中引入数据库后的系统,一般由数据库、数据库管理系统、应用系统、数据库管理员和用户构成。