Jump to content
  • 0

pomoc Pomoc z errory


Guest Sacre

Dotaz

Ahoj prosím vás chtěl bych se zeptat když mi to píše v pawnu

error 021: symbol already defined: "GetVehicleWithinDistance"

Ale umazat to nemůžu protože by mi pak nefungovali ostatní věci nevíte co stím ?

Řádky:

4013:GetVehicleWithinDistance(playerid, Float:x1, Float:y1, Float:z11, Float:dist, &veh)
4031:	IsVehicleRcTram( vehicleid ){
4413:GetVehicleWithinDistance(playerid, Float:x1, Float:y1, Float:z11, Float:dist, &veh)
4414:{

 

Errory:

C:\Documents and Settings\Svoboda\Plocha\czeworld.pwn(4013) : error 021: symbol already defined: "GetVehicleWithinDistance"
C:\Documents and Settings\Svoboda\Plocha\czeworld.pwn(4031) : error 021: symbol already defined: "IsVehicleRcTram"
C:\Documents and Settings\Svoboda\Plocha\czeworld.pwn(4413) : error 025: function heading differs from prototype
C:\Documents and Settings\Svoboda\Plocha\czeworld.pwn(4414) : error 021: symbol already defined: "GetVehicleWithinDistance"
Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.

Dík

Link to comment
Share on other sites

8 odpovědí na tuto otázku

Recommended Posts

  • 0

Jo to taky vím ale nemůžu to smazat třeba to mám vj ednom povolání dám do druhého a hned already defined nemůžu to z jednoho smazat nahodí to více errrorů a pak by to povolánií nebylo funkční

Link to comment
Share on other sites

  • 0

DObře :

 

Řádky:

	GetVehicleWithinDistance( playerid, Float:x1, Float:y1, Float:z1, Float:dist, &veh)
{
for(new i = 1; i < MAX_VEHICLES; i++)
{
if(GetVehicleModel(i) > 0)
{
if(GetPlayerVehicleID(playerid) != i )
{
new Float:x, Float:y, Float:z;
new Float:x2, Float:y2, Float:z2;
GetVehiclePos(i, x, y, z);
x2 = x1 - x; y2 = y1 - y; z2 = z1 - z;
new Float:vDist = (x2*x2+y2*y2+z2*z2);
if( vDist < dist)
{
veh = i;
dist = vDist;
}}}}}

IsVehicleRcTram( vehicleid ){
new model = GetVehicleModel(vehicleid);
switch(model)
{
case D_TRAM, RC_GOBLIN, RC_BARON, RC_BANDIT, RC_RAIDER, RC_TANK: return 1;
default: return 0;
}
return 0;
}

Link to comment
Share on other sites

  • 0
DObře :

 

Řádky:

	GetVehicleWithinDistance( playerid, Float:x1, Float:y1, Float:z1, Float:dist, &veh)
{
for(new i = 1; i < MAX_VEHICLES; i++)
{
if(GetVehicleModel(i) > 0)
{
if(GetPlayerVehicleID(playerid) != i )
{
new Float:x, Float:y, Float:z;
new Float:x2, Float:y2, Float:z2;
GetVehiclePos(i, x, y, z);
x2 = x1 - x; y2 = y1 - y; z2 = z1 - z;
new Float:vDist = (x2*x2+y2*y2+z2*z2);
if( vDist < dist)
{
veh = i;
dist = vDist;
}}}}}

IsVehicleRcTram( vehicleid ){
new model = GetVehicleModel(vehicleid);
switch(model)
{
case D_TRAM, RC_GOBLIN, RC_BARON, RC_BANDIT, RC_RAIDER, RC_TANK: return 1;
default: return 0;
}
return 0;
}

 

myslim ze ten stock tam mas 2x

Link to comment
Share on other sites

  • 0

Dobře už to píše

C:\Documents and Settings\Svoboda\Plocha\czeworld.pwn(4385) : error 025: function heading differs from prototype
C:\Documents and Settings\Svoboda\Plocha\czeworld.pwn(4386) : error 021: symbol already defined: "GetVehicleWithinDistance"

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...