Why is that didn't work?
#1

Solved.
Reply
#2

you never used them.

the loose indentation is made because your script indenting is bad.
Press Tab to indent a script code
Shift + Tab to unindent a script code
Reply
#3

try this

Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
    if (strcmp("/miniguns", cmdtext, true, 5) == 0)
    {
        new minigun1;
        new minigun2;
        minigun1 = CreateObject(362, 0.78, 1.46, 0.40,   2.40, 27.12, 87.01);
        minigun2 = CreateObject(362, -0.52, 1.29, 0.50,   2.40, 27.12, 87.01);
        AttachObjectToVehicle(GetPVarInt(playerid, "minigun1"), GetPlayerVehicleID(playerid), 0.78, 1.46, 0.40,   2.40, 27.12, 87.01);
        AttachObjectToVehicle(GetPVarInt(playerid, "minigun2"), GetPlayerVehicleID(playerid), -0.52, 1.29, 0.50,   2.40, 27.12, 87.01);
        return 1;
    }
    if (strcmp("/rpgs", cmdtext, true, 10) == 0)
    {
         new RPG1;
         new RPG2;
         RPG1 = CreateObject(359, 0.53, -0.33, 0.72,   0.00, 0.00, 86.16);
         RPG2 = CreateObject(359, -0.58, -0.18, 0.72,   0.00, 0.00, 86.16);
         AttachObjectToVehicle(GetPVarInt(playerid, "RPG1"), GetPlayerVehicleID(playerid), 0.53, -0.33, 0.72,   0.00, 0.00, 86.16);
         AttachObjectToVehicle(GetPVarInt(playerid, "RPG2"), GetPlayerVehicleID(playerid), -0.58, -0.18, 0.72,   0.00, 0.00, 86.16);
        return 1;
    }
im not sure but i think it will work
Reply
#4

Код:
C:\DOCUME~1\admin\Desktop\NEF7FE~1\FILTER~1\cartuner.pwn(151) : warning 204: symbol is assigned a value that is never used: "minigun2"
C:\DOCUME~1\admin\Desktop\NEF7FE~1\FILTER~1\cartuner.pwn(150) : warning 204: symbol is assigned a value that is never used: "minigun1"
C:\DOCUME~1\admin\Desktop\NEF7FE~1\FILTER~1\cartuner.pwn(164) : warning 217: loose indentation
C:\DOCUME~1\admin\Desktop\NEF7FE~1\FILTER~1\cartuner.pwn(161) : warning 204: symbol is assigned a value that is never used: "RPG2"
C:\DOCUME~1\admin\Desktop\NEF7FE~1\FILTER~1\cartuner.pwn(160) : warning 204: symbol is assigned a value that is never used: "RPG1"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


5 Warnings.
With your code Kepa
Reply
#5

Quote:
Originally Posted by Gangster-rocks
Посмотреть сообщение
Код:
C:\DOCUME~1\admin\Desktop\NEF7FE~1\FILTER~1\cartuner.pwn(151) : warning 204: symbol is assigned a value that is never used: "minigun2"
C:\DOCUME~1\admin\Desktop\NEF7FE~1\FILTER~1\cartuner.pwn(150) : warning 204: symbol is assigned a value that is never used: "minigun1"
C:\DOCUME~1\admin\Desktop\NEF7FE~1\FILTER~1\cartuner.pwn(164) : warning 217: loose indentation
C:\DOCUME~1\admin\Desktop\NEF7FE~1\FILTER~1\cartuner.pwn(161) : warning 204: symbol is assigned a value that is never used: "RPG2"
C:\DOCUME~1\admin\Desktop\NEF7FE~1\FILTER~1\cartuner.pwn(160) : warning 204: symbol is assigned a value that is never used: "RPG1"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


5 Warnings.
With your code Kepa
Simply remove the unused variables then? If they are never used, there's no need for them to exist, so remove the declaration of those variables!
Reply
#6

Quote:
Originally Posted by JaTochNietDan
Посмотреть сообщение
Simply remove the unused variables then? If they are never used, there's no need for them to exist, so remove the declaration of those variables!
When i do this its give me errors
Reply
#7

pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
    if (strcmp("/miniguns", cmdtext, true, 5) == 0)
    {
        new minigun1;
        new minigun2;
        minigun1 = CreateObject(362, 0.78, 1.46, 0.40,   2.40, 27.12, 87.01);
        minigun2 = CreateObject(362, -0.52, 1.29, 0.50,   2.40, 27.12, 87.01);
        AttachObjectToVehicle(GetPVarInt(playerid, "minigun1"), GetPlayerVehicleID(playerid), 0.78, 1.46, 0.40,   2.40, 27.12, 87.01);
        AttachObjectToVehicle(GetPVarInt(playerid, "minigun2"), GetPlayerVehicleID(playerid), -0.52, 1.29, 0.50,   2.40, 27.12, 87.01);
        return 1;
    }
    if (strcmp("/rpgs", cmdtext, true, 10) == 0)
    {
         new RPG1;
         new RPG2;
         RPG1 = CreateObject(359, 0.53, -0.33, 0.72,   0.00, 0.00, 86.16);
         RPG2 = CreateObject(359, -0.58, -0.18, 0.72,   0.00, 0.00, 86.16);
         AttachObjectToVehicle(GetPVarInt(playerid, "RPG1"), GetPlayerVehicleID(playerid), 0.53, -0.33, 0.72,   0.00, 0.00, 86.16);
         AttachObjectToVehicle(GetPVarInt(playerid, "RPG2"), GetPlayerVehicleID(playerid), -0.58, -0.18, 0.72,   0.00, 0.00, 86.16);
        return 1;
    }
}
You were missing a bracket
Reply
#8

Not working -_- THIS SUCK
Reply
#9

Instead of saying suck try to figure out yourself.
We are trying our best to solve your problem but what you call us suck
Get a life dude.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)