Доступ к архиву

Переход в группу "Пользователь"

300.00 ₽
Одноразовый платёж
Быстрый переход в группу "Пользователи", без надобности написания постов и ожидания.

Покупка дает возможность:
Быть полноправным участником форума
Нормальное копирование кода
Создавать темы
Скачивать файлы
Доступ к архиву Pawno-Info

Не работают корректно динамик чекпоинты

Статус
В этой теме нельзя размещать новые ответы.

Koberman

Новичок
В видео показываю суть бага. Объясню - первый чекпоинт
PHP:
 	if(IsPlayerInRangeOfPoint(playerid, 2.0, 2470.7422,-1289.1061,1030))
    {
        DisablePlayerCheckpoint(playerid);
 		MovePlayerObject(playerid, rudafab, 2471,-1288.50,1031.6133, 0.80);
 		SetTimerEx("takeruda", 4800, false, "i", playerid);
	}
далее идет
PHP:
if(checkpointid == fstol[0][playerid] || checkpointid == fstol[1][playerid] || checkpointid == fstol[2][playerid] || checkpointid == fstol[3][playerid] || checkpointid == fstol[4][playerid] || checkpointid == fstol[5][playerid] || checkpointid == fstol[6][playerid] || checkpointid == fstol[7][playerid] || checkpointid == fstol[8][playerid] || checkpointid == fstol[9][playerid])
		{
	    	if(GetPVarInt(playerid, "pickfab") == 0) return 1;
	   	    SetPlayerSpecialAction(playerid, 0);
		    RemovePlayerAttachedObject(playerid, 1);
		    SPAO(playerid, 3, 19631, 6, 0.078221, 0.034000, 0.028844, -67.902618, 264.126861, 17.750543, 1.485999, 0.727999, 1.366999);
			ApplyAnimation(playerid, "BASEBALL", "Bat_4", 4.1, 1, 0, 0, 1, 7000);
			SCM(playerid, COLOR_GREY, "f");
			perefab0[playerid] = CreateDynamicCP(2464.8142,-1291.4158,1030.7, 1, 1, 1, playerid, 1.5);
			perefab1[playerid] = CreateDynamicCP(2456.7402,-1291.4159,1030.7, 1, 1, 1, playerid, 1.5);
			perefab2[playerid] = CreateDynamicCP(2449.4851,-1291.4156,1030.7, 1, 1, 1, playerid, 1.5);
			perefab3[playerid] = CreateDynamicCP(2449.4473,-1298.9364,1030.7, 1, 1, 1, playerid, 1.5);
			perefab4[playerid] = CreateDynamicCP(2456.7861,-1298.9365,1030.7, 1, 1, 1, playerid, 1.5);
			perefab5[playerid] = CreateDynamicCP(2464.8035,-1298.9359,1030.7, 1, 1, 1, playerid, 1.5);
		    DestroyDynamicCP(fstol[0][playerid]);
			DestroyDynamicCP(fstol[1][playerid]);
			DestroyDynamicCP(fstol[2][playerid]);
			DestroyDynamicCP(fstol[3][playerid]);
			DestroyDynamicCP(fstol[4][playerid]);
	  		DestroyDynamicCP(fstol[5][playerid]);
			DestroyDynamicCP(fstol[6][playerid]);
			DestroyDynamicCP(fstol[7][playerid]);
			DestroyDynamicCP(fstol[8][playerid]);
			DestroyDynamicCP(fstol[9][playerid]);
			SetTimerEx("takemetall", 7000, 0, "i", playerid);
			if(checkpointid == fstol[0][playerid])
			{
				SetPlayerFacingAngle(playerid, 90);
				SetPlayerObjectPos(playerid, rudastol[0], 2466.35,-1293.5099,1031.9);
			}
			if(checkpointid == fstol[1][playerid])
			{
				SetPlayerFacingAngle(playerid, 90);
				SetPlayerObjectPos(playerid, rudastol[1], 2466.35,-1295.6766,1031.9);
			}
			if(checkpointid == fstol[2][playerid])
			{
			    SetPlayerFacingAngle(playerid, 270);
				SetPlayerObjectPos(playerid, rudastol[2], 2463.35,-1293.5099,1031.9);
			}
			if(checkpointid == fstol[3][playerid])
			{
			    SetPlayerFacingAngle(playerid, 270);
				SetPlayerObjectPos(playerid, rudastol[3], 2463.35,-1295.6766,1031.9);
			}
			if(checkpointid == fstol[4][playerid])
			{
				SetPlayerFacingAngle(playerid, 90);
				SetPlayerObjectPos(playerid, rudastol[4], 2458.35,-1293.5099,1031.9);
			}
			if(checkpointid == fstol[5][playerid])
			{
				SetPlayerFacingAngle(playerid, 90);
				SetPlayerObjectPos(playerid, rudastol[5], 2458.35,-1295.6766,1031.9);
			}
			if(checkpointid == fstol[6][playerid])
			{
				SetPlayerFacingAngle(playerid, 270);
				SetPlayerObjectPos(playerid, rudastol[6], 2455.35,-1293.5099,1031.9);
			}
			if(checkpointid == fstol[7][playerid])
			{
			    SetPlayerFacingAngle(playerid, 270);
				SetPlayerObjectPos(playerid, rudastol[7], 2455.35,-1293.6766,1031.9);
			}
			if(checkpointid == fstol[8][playerid])
			{
				SetPlayerFacingAngle(playerid, 90);
				SetPlayerObjectPos(playerid, rudastol[8], 2450.35,-1293.5099,1031.9);
			}
			if(checkpointid == fstol[9][playerid])
			{
				SetPlayerFacingAngle(playerid, 90);
				SetPlayerObjectPos(playerid, rudastol[9], 2450.35,-1293.6766,1031.9);
			}
		}
после
PHP:
{
	    if(checkpointid == perefab0[playerid] || checkpointid == perefab1[playerid] || checkpointid == perefab2[playerid] || checkpointid == perefab3[playerid] || checkpointid == perefab4[playerid] || checkpointid == perefab5[playerid])
	    {
	        if(GetPVarInt(playerid, "metallsuccess") == 0) return 1;
			RemovePlayerAttachedObject(playerid, 1);
			SetPlayerSpecialAction(playerid, 0);
			TogglePlayerControllable(playerid, 0);
	  	    DestroyDynamicCP(perefab0[playerid]);
			DestroyDynamicCP(perefab1[playerid]);
			DestroyDynamicCP(perefab2[playerid]);
			DestroyDynamicCP(perefab3[playerid]);
			DestroyDynamicCP(perefab4[playerid]);
	  		DestroyDynamicCP(perefab5[playerid]);
			SetTimerEx("successfulmetall", 7000, 0, "i", playerid);
		}
	}
и конец
PHP:
{
	 	if(checkpointid == fabsklad0[playerid] || checkpointid == fabsklad1[playerid])
			{
			if(GetPVarInt(playerid, "metallok") == 0) return 1;
		    SetPVarInt(playerid, "fabanim", 0);
		    SetPVarInt(playerid, "fabsuccess", 0);
			SetPlayerSpecialAction(playerid, 0);
			DisablePlayerCheckpoint(playerid);
			SetPlayerChatBubble(playerid, "{5AD435}+ 1 ñëèòîê", -1, 15.0, 3000);
		    SetPlayerCheckpoint(playerid, 2470.7422,-1289.1061,1030, 2.0);
			RemovePlayerAttachedObject(playerid, 1);
			ApplyAnimation(playerid,"CRIB","CRIB_Use_Switch",4.0,0,0,0,0,0);
			SetPVarInt(playerid, "metalls", GetPVarInt(playerid, "metalls") + 1);
	 		DestroyDynamicCP(fabsklad0[playerid]);
			DestroyDynamicCP(fabsklad1[playerid]);
		}
	}
форварды
PHP:
forward successfulmetall(playerid);
public successfulmetall(playerid)
{
	TogglePlayerControllable(playerid, 1);
    SetPVarInt(playerid, "metallok", 1);
	ClearAnimations(playerid);
   	SPAO(playerid, 1, 19941, 6, 0.136311, 0.007520, 0.047129, -50.699184, -23.775056, 167.323684, 0.639472, 0.611998, 0.705999);
	fabsklad0[playerid] = CreateDynamicCP(2479.8374,-1307.4606,1030.7, 1, 1, 1, playerid, 1.5);
	fabsklad1[playerid] = CreateDynamicCP(2482.7444,-1307.0693,1030.7, 1, 1, 1, playerid, 1.5);
    return 1;
}
forward takemetall(playerid);
public takemetall(playerid)
{
    SetPVarInt(playerid, "metallsuccess", 1);
    SetPVarInt(playerid, "pickfab", 0);
   	ApplyAnimation(playerid, "GHANDS", "GSIGN3LH", 4.1,0,1,1,1,1);
	SetPlayerSpecialAction(playerid, SPECIAL_ACTION_CARRY);
	RemovePlayerAttachedObject(playerid, 3);
	SPAO(playerid, 1, 3930, 1, 0.312312, 0.462520, -0.072870, 118.700828, 77.924964, -34.176250, 0.639472, 0.611999, 0.705999);
	SetPlayerObjectPos(playerid, rudastol[0], 2471,-1284.3618,2031.6133);
	SetPlayerObjectPos(playerid, rudastol[1], 2471,-1284.3618,2031.6133);
	SetPlayerObjectPos(playerid, rudastol[2], 2471,-1284.3618,2031.6133);
	SetPlayerObjectPos(playerid, rudastol[3], 2471,-1284.3618,2031.6133);
	SetPlayerObjectPos(playerid, rudastol[4], 2471,-1284.3618,2031.6133);
	SetPlayerObjectPos(playerid, rudastol[5], 2471,-1284.3618,2031.6133);
	SetPlayerObjectPos(playerid, rudastol[6], 2471,-1284.3618,2031.6133);
	SetPlayerObjectPos(playerid, rudastol[7], 2471,-1284.3618,2031.6133);
	SetPlayerObjectPos(playerid, rudastol[8], 2471,-1284.3618,2031.6133);
	SetPlayerObjectPos(playerid, rudastol[9], 2471,-1284.3618,2031.6133);
	return 1;
}
forward takeruda(playerid);
public takeruda(playerid)
{
    SetPVarInt(playerid, "fabsuccess", 1);
    SetPVarInt(playerid, "fabanim", 1);
    ApplyAnimation(playerid, "CARRY", "LIFTUP", 4.0, 0, 0, 0, 0, 0);
    SetPlayerObjectPos(playerid, rudafab, 2471,-1284.3618,1031.6133);
   	SetTimerEx("pickfab", 1100, false, "i", playerid);
}
forward pickfab(playerid);
public pickfab(playerid)
{
 	SetPVarInt(playerid, "pickfab", 1);
	ApplyAnimation(playerid, "GHANDS", "GSIGN3LH", 4.1,0,1,1,1,1);
	SetPlayerSpecialAction(playerid, SPECIAL_ACTION_CARRY);
	SPAO(playerid, 1, 3930, 1, 0.312312, 0.462520, -0.072870, 118.700828, 77.924964, -34.176250, 0.639472, 0.611999, 0.705999);
	fstol[0][playerid] = CreateDynamicCP(2467.0583,-1293.5099,1030.7, 1, 1, 1, playerid, 1.5);
    fstol[1][playerid] = CreateDynamicCP(2467.0562,-1295.6766,1030.7, 1, 1, 1, playerid, 1.5);
    fstol[2][playerid] = CreateDynamicCP(2462.0583,-1293.5099,1030.7, 1, 1, 1, playerid, 1.5);
    fstol[3][playerid] = CreateDynamicCP(2462.0562,-1295.6766,1030.7, 1, 1, 1, playerid, 1.5);
    fstol[4][playerid] = CreateDynamicCP(2459.0583,-1293.5099,1030.7, 1, 1, 1, playerid, 1.5);
    fstol[5][playerid] = CreateDynamicCP(2459.0562,-1295.6766,1030.7, 1, 1, 1, playerid, 1.5);
    fstol[6][playerid] = CreateDynamicCP(2454.5,-1293.5099,1030.7, 1, 1, 1, playerid, 1.5);
    fstol[7][playerid] = CreateDynamicCP(2454.5,-1295.6766,1030.7, 1, 1, 1, playerid, 1.5);
    fstol[8][playerid] = CreateDynamicCP(2451.8,-1293.5099,1030.7, 1, 1, 1, playerid, 1.5);
    fstol[9][playerid] = CreateDynamicCP(2451.8,-1295.6766,1030.7, 1, 1, 1, playerid, 1.5);
}
 
Статус
В этой теме нельзя размещать новые ответы.
Сверху Снизу