Number of arguments does not match definition
#1

Код:
COMMAND:fejerverkai(playerid,params[])
{
SetTimer("fejerverkas",3000, false);
new Float:X,Float:Y,Float:Z; GetPlayerPos(playerid,X,Y,Z);
fejerverkai = CreateDynamicObject(19282,X+2,Y,Z,0,0,0);
MoveDynamicObject(fejerverkai, X,Y,Z+4,7.0);
}
public fejerverkas()
{
for( new i = 0; i < MAX_PLAYERS; i++ )
{
new Float:X,Float:Y,Float:Z; GetPlayerPos(i,X,Y,Z);
DestroyObject(fejerverkai);
fejerverkai1 = CreateDynamicObject(19283, GetObjectPos(fejerverkai, X, Y, Z));
}
}
C:\Users\Lauryno\Desktop\Servas\gamemodes\bom.pwn( 1047) : warning 202: number of arguments does not match definition
C:\Users\Lauryno\Desktop\Servas\gamemodes\bom.pwn( 1047) : warning 202: number of arguments does not match definition
C:\Users\Lauryno\Desktop\Servas\gamemodes\bom.pwn( 1047) : warning 202: number of arguments does not match definition
C:\Users\Lauryno\Desktop\Servas\gamemodes\bom.pwn( 1047) : warning 202: number of arguments does not match definition
C:\Users\Lauryno\Desktop\Servas\gamemodes\bom.pwn( 1047) : warning 202: number of arguments does not match definition

I want to make that object fejerverkai1 create where object fejerverkai.
Reply
#2

Try This..

Код:
fejerverkai1 = CreateDynamicObject(19283, GetObjectPos(fejerverkai, X, Y, Z), 0, 0);
Reply
#3

The parameter for CreateDynamicObject is:
pawn Код:
(modelid, Float:X, Float:Y, Float:Z, Float:rX, Float:rY, Float:rZ, Float:DrawDistance)
Where rx, ry and rz are
Float:rX The X rotation of the object.
Float:rY The Y rotation of the object.
Float:rZ The Z rotation of the object.
So you will have to get the rotation of the objects to or you will have to set your own.


P.S.
Please use pawn tags to post codes.
Reply
#4

Quote:
Originally Posted by frozen.iyan
Посмотреть сообщение
Try This..

Код:
fejerverkai1 = CreateDynamicObject(19283, GetObjectPos(fejerverkai, X, Y, Z), 0, 0);
now:

C:\Users\Lauryno\Desktop\Servas\gamemodes\bom.pwn( 1047) : warning 202: number of arguments does not match definition
C:\Users\Lauryno\Desktop\Servas\gamemodes\bom.pwn( 1047) : warning 202: number of arguments does not match definition
C:\Users\Lauryno\Desktop\Servas\gamemodes\bom.pwn( 1047) : warning 202: number of arguments does not match definition
Reply
#5

Quote:
Originally Posted by Louris
Посмотреть сообщение
now:

C:\Users\Lauryno\Desktop\Servas\gamemodes\bom.pwn( 1047) : warning 202: number of arguments does not match definition
C:\Users\Lauryno\Desktop\Servas\gamemodes\bom.pwn( 1047) : warning 202: number of arguments does not match definition
C:\Users\Lauryno\Desktop\Servas\gamemodes\bom.pwn( 1047) : warning 202: number of arguments does not match definition
Quote:
Originally Posted by Faisal_khan
Посмотреть сообщение
The parameter for CreateDynamicObject is:
pawn Код:
(modelid, Float:X, Float:Y, Float:Z, Float:rX, Float:rY, Float:rZ, Float:DrawDistance)
Where rx, ry and rz are
Float:rX The X rotation of the object.
Float:rY The Y rotation of the object.
Float:rZ The Z rotation of the object.
So you will have to get the rotation of the objects to or you will have to set your own.


P.S.
Please use pawn tags to post codes.
Yeah , Change Your Code same with that parameter
Reply
#6

Did you read what I posted?
Reply
#7

Simple enough? Check this: (Goddamn it, why keep the object's name so complicated, lol)
pawn Код:
new Float:x, Float:y, Float:z;
new Float:RotX,Float:RotY,Float:RotZ;
GetObjectPos(fejerverkai, x,y,z);
GetObjectRot(fejerverkai, RotX, RotY, RotZ);
fejerverkai1 = CreateObject(19283, x, y, z, RotX, RotY, RotZ, 100)
Reply
#8

fejerverkai1 = CreateDynamicObject(19283, x, y, z, RotX, RotY, RotZ);


But it doesn't create object.
Reply
#9

WHUPS. Got pwnt, anyways, sorry, incomplete information!
@ Faisal : Thanks, for sharing it with me.
Reply
#10

Quote:
Originally Posted by Rajat_Pawar
Посмотреть сообщение
fejerverkai1 = CreateDynamicObject(19283, x, y, z, RotX, RotY, RotZ, 100 );
For god's sake, why are you eating up the parameters!?
Distance param is optional bruh.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)