Problem mit Streamer

Wichtiger Hinweis: Bitte ändert nicht manuell die Schriftfarbe auf schwarz sondern belasst es bei der Standardeinstellung. Somit tragt ihr dazu bei dass euer Text auch bei Verwendung unseren dunklen Forenstils noch lesbar ist!

Tipp: Ihr wollt längere Codeausschnitte oder Logfiles bereitstellen? Benutzt unseren eigenen PasteBin-Dienst Link
  • Hallo,
    ich habe ein kleines Problem,
    es werden Objekte nicht angezeigt obwohl Objekte im Script eingefügt sind.
    Wegen dem Streamer stürzt der Server auch oft ab.


    Hier die Logs:





    Ich hab den Verdacht das der Streamer die Objekte nicht lädt..


    Hier der Streamer:


    #include <a_samp>


    #define MAX_P 200 // Set to the maximum ammount of players on your server
    #define MAX_CP 50 // Set the the maximum ammount of Checkpoints you will have
    #define UPDATE_AMMOUNT 23 // Set to the ammount of player updates this is called in (eg. eveyr 23 OnPlayerUpdateCalles the checkpoints are updates)
    // OnPlayerUpdate is called 5-20 times a second depending on multiple factors.
    #define PRINT_ERROR_MESSAGES false // Set to 'true' to enable printing of all error messages


    #define INVALID_CP_X 5555.0


    forward StreamCheckpointsForPlayer(playerid);
    forward YCP_OnPlayerUpdate(playerid);
    forward OnPlayerEnterStreamCheckpoint(playerid, checkpointid);
    forward OnPlayerExitStreamCheckpoint(playerid, checkpointid);


    new
    CPCount,
    PlayerUpdates[MAX_P],
    CPShown[MAX_P],
    bool:InCP[MAX_P];


    /*
    native SetStreamCheckpoint(Float:x, Float:y, Float:z, Float:size, Float:View_Distance);
    native DisableStreamCheckpoint(checkpointid);
    native SetPlayerStreamCheckpoint(playerid, Float:x, Float:y, Float:z, Float:size, Float:View_Distance);
    native DisablePlayerStreamCheckpoint(playerid, checkpointid);
    native SetStreamCheckpointPos(checkpointid, Float:x, Float:y, Float:z);
    native SetStreamCheckpointSize(checkpointid, Float:radius);
    native SetStreamCheckpointViewDistance(checkpointid, Float:View_Distance);
    native StreamCheckpointsForPlayer(playerid);
    native GetDistanceToCheckpoint(Float:X, Float:Y, Float:Z, checkpointid);
    native IsPlayerInStreamCheckpoint(playerid, checkpointid);
    */


    enum CPInfo
    {
    Float:cX,
    Float:cY,
    Float:cZ,
    Float:Radius,
    Float:ViewDistance,
    ForPlayer = INVALID_PLAYER_ID
    }
    new Checkpoints[MAX_CP][CPInfo];


    stock SetStreamCheckpoint(Float:x, Float:y, Float:z, Float:size, Float:View_Distance)
    {
    CPCount++;
    Checkpoints[CPCount][cX] = x;
    Checkpoints[CPCount][cY] = y;
    Checkpoints[CPCount][cZ] = z;
    Checkpoints[CPCount][Radius] = size;
    Checkpoints[CPCount][ViewDistance] = View_Distance;
    return CPCount;
    }


    stock DisableStreamCheckpoint(checkpointid)
    {
    Checkpoints[checkpointid][cX] = INVALID_CP_X;
    for(new i; i < MAX_P; i++)
    {
    if(CPShown[i] == checkpointid)
    {
    DisablePlayerCheckpoint(i);
    CPShown[i] = 0;
    }
    }
    return 0;
    }



    stock SetPlayerStreamCheckpoint(playerid, Float:x, Float:y, Float:z, Float:size, Float:View_Distance)
    {
    CPCount++;
    Checkpoints[CPCount][cX] = x;
    Checkpoints[CPCount][cY] = y;
    Checkpoints[CPCount][cZ] = z;
    Checkpoints[CPCount][Radius] = size;
    Checkpoints[CPCount][ViewDistance] = View_Distance;
    Checkpoints[CPCount][ForPlayer] = playerid;
    return CPCount;
    }


    stock DisablePlayerStreamCheckpoint(playerid, checkpointid)
    {
    Checkpoints[checkpointid][cX] = INVALID_CP_X;
    if(CPShown[playerid] == checkpointid)
    {
    DisablePlayerCheckpoint(playerid);
    CPShown[playerid] = 0;
    }
    return 0;
    }
    stock Float:GetDistanceToCheckpoint(Float:X, Float:Y, Float:Z, checkpointid)
    return floatsqroot((((X - Checkpoints[checkpointid][cX]) * (X - Checkpoints[checkpointid][cX])) + ((Y - Checkpoints[checkpointid][cY]) * (Y - Checkpoints[checkpointid][cY]) + ((Z - Checkpoints[checkpointid][cZ]) * (Z - Checkpoints[checkpointid][cZ])))));


    stock YCP_OnGameModeInit()
    {
    CPCount = 0;
    for(new i; i < MAX_CP; i++)
    {
    Checkpoints[i][cX] = 0;
    Checkpoints[i][cY] = 0;
    Checkpoints[i][cZ] = 0;
    Checkpoints[i][Radius] = 0;
    Checkpoints[i][ViewDistance] = 0;
    }
    }


    stock YCP_OnPlayerConnect(playerid)
    {
    CPShown[playerid] = 0;
    PlayerUpdates[playerid] = 0;
    InCP[playerid] = false;
    return 1;
    }


    public YCP_OnPlayerUpdate(playerid)
    {
    PlayerUpdates[playerid]++;
    if(PlayerUpdates[playerid] >= UPDATE_AMMOUNT && CPCount)
    {
    StreamCheckpointsForPlayer(playerid);
    PlayerUpdates[playerid] = 0;
    }
    return 1;
    }


    stock YCP_OnPlayerEnterCheckpoint(playerid)
    {
    OnPlayerEnterStreamCheckpoint(playerid, CPShown[playerid]);
    }


    public StreamCheckpointsForPlayer(playerid)
    {
    if(InCP[playerid] && !IsPlayerInCheckpoint(playerid))
    {
    InCP[playerid] = false;
    CallRemoteFunction("OnPlayerExitStreamCheckpoint", "ii", playerid, CPShown[playerid]);
    }


    new Float:X, Float:Y, Float:Z;
    GetPlayerPos(playerid, X, Y, Z);
    for(new i; i < MAX_CP; i++)
    {
    if(Checkpoints[i][ForPlayer] != INVALID_PLAYER_ID && Checkpoints[i][ForPlayer] != playerid)
    {
    return 1;
    }
    new Float:Dist = GetDistanceToCheckpoint(X, Y, Z, i);


    if(Dist < Checkpoints[i][ViewDistance] && Checkpoints[i][cX] != INVALID_CP_X)
    {
    if(!CPShown[playerid])
    {
    SetPlayerCheckpoint(playerid, Checkpoints[i][cX], Checkpoints[i][cY], Checkpoints[i][cZ], Checkpoints[i][Radius]);
    CPShown[playerid] = i;
    }
    else
    {
    if(Dist < GetDistanceToCheckpoint(X, Y, Z, CPShown[playerid]) && i != CPShown[playerid])
    {
    DisablePlayerCheckpoint(playerid);
    SetPlayerCheckpoint(playerid, Checkpoints[i][cX], Checkpoints[i][cY], Checkpoints[i][cZ], Checkpoints[i][Radius]);
    CPShown[playerid] = i;
    }
    #if PRINT_ERROR_MESSAGES
    if(CPShown[playerid] != i) printf("[YCP]ERROR: Checkpoint %d could not be shown because a different checkpoint is already being shown.", i);
    #endif
    }
    }


    if(Dist > Checkpoints[i][ViewDistance] && CPShown[playerid] == i)
    {
    DisablePlayerCheckpoint(playerid);
    CPShown[playerid] = 0;
    }
    }
    return 1;
    }


    stock SetStreamCheckpointPos(checkpointid, Float:x, Float:y, Float:z)
    {
    for(new i; i < MAX_P; i++)
    {
    if(CPShown[i] == checkpointid)
    {
    DisablePlayerCheckpoint(i);
    SetPlayerCheckpoint(i, x, y, z, Checkpoints[checkpointid][Radius]);
    }
    }


    Checkpoints[checkpointid][cX] = x;
    Checkpoints[checkpointid][cY] = y;
    Checkpoints[checkpointid][cZ] = z;
    return 1;
    }


    stock SetStreamCheckpointSize(checkpointid, Float:radius)
    {
    InCP[playerid] = true;


    for(new i; i < MAX_P; i++)
    {
    if(CPShown[i] == checkpointid)
    {
    DisablePlayerCheckpoint(i);
    SetPlayerCheckpoint(i, Checkpoints[checkpointid][cX], Checkpoints[checkpointid][cY], Checkpoints[checkpointid][cZ], radius);
    }
    }


    Checkpoints[checkpointid][Radius] = radius;
    return 1;
    }


    stock SetStreamCheckpointViewDistance(checkpointid, Float:View_Distance)
    Checkpoints[checkpointid][ViewDistance] = View_Distance;


    stock IsPlayerInStreamCheckpoint(playerid, checkpointid)
    {
    if(!CPShown[playerid] || CPShown[playerid] != checkpointid || !IsPlayerInCheckpoint(playerid)) return false;
    return true;
    }


    Wo ist der Fehler??

  • Du musst auch den Streamer bei "#include <streamer>" und bei "pawno-include-streamer.inc" und bei "plugins" sehr Wichtig bei "server.cfg-<plugins-streamer" Dan solte es gehen und immer die neuste Version nehmen.

  • Bin mir da nicht sicher ob es die aktuelle Version ist..
    Ich habe mal etwas gegoogelt und habe da den " streamer_plugin_v2_6_r38.rar " Streamer gefunden, soll der "neuste" für 0.3d sein...


    Auf jeden Fall gibt es weiterhin noch Probleme beim laden von Objekte,
    hier einige Srceens:


    http://www.fotos-hochladen.net/uploads/samp062c20ymxwtj8.png - Man sieht an diesem Screen das nur die "Hälfte" der Objekte lädt.
    http://img3.fotos-hochladen.ne…ads/samp063qb1e9zp6yu.png - Bei manchen Objekten ist es so das dies nicht zu sehen sind, durchlaufen kann man aber auch nicht.



    //Edit:


    Im Script steht "#include <streamer>"
    Im Include vom Server-/Pawno ist die Datei vorhanden.
    In der Server.cfg ist sie eingetragen "plugins streamer.so

  • Ja hast du auch CreateObject zu CreateDynamicObject gemacht?


    da der streamer sonst nix bringt

  • Ja hast du auch CreateObject zu CreateDynamicObject gemacht?


    da der streamer sonst nix bringt


    Hallo,
    ich habe in der Streamer.inc nach dem Begriff CreateObject gesucht, hab aber gar nichts gefunden.
    Dann hab ich den Begriff "CreateDynamicObject" gesucht, da habe ich 2 Sachen gefunden namens "CreateDynamicObject" und "CreateDynamichObjectEx"
    und des weiteren. Daher zeigt er auch die Tore aber nicht das gemappte, da "CreateObject" noch nicht eingetragen wurde..


    Wo finde ich die Option "CreateObject"?


    Außerdem hatte ich ja den neuen Streamer heruntergeladen wie oben schon erwähnt, der ist so aufgebaut:


    /*
    SA-MP Streamer Plugin v2.6
    Copyright © 2012 Incognito


    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.


    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    GNU General Public License for more details.


    You should have received a copy of the GNU General Public License
    along with this program. If not, see <http://www.gnu.org/licenses/>.
    */


    #include <a_samp>


    // Definitions


    #define STREAMER_TYPE_OBJECT (0)
    #define STREAMER_TYPE_PICKUP (1)
    #define STREAMER_TYPE_CP (2)
    #define STREAMER_TYPE_RACE_CP (3)
    #define STREAMER_TYPE_MAP_ICON (4)
    #define STREAMER_TYPE_3D_TEXT_LABEL (5)
    #define STREAMER_TYPE_AREA (6)


    #define STREAMER_AREA_TYPE_CIRCLE (0)
    #define STREAMER_AREA_TYPE_RECTANGLE (1)
    #define STREAMER_AREA_TYPE_SPHERE (2)
    #define STREAMER_AREA_TYPE_CUBE (3)
    #define STREAMER_AREA_TYPE_POLYGON (4)


    #if !defined FLOAT_INFINITY
    #define FLOAT_INFINITY (Float:0x7F800000)
    #endif


    // Enumerator


    enum
    {
    E_STREAMER_ATTACHED_PLAYER,
    E_STREAMER_ATTACHED_VEHICLE,
    E_STREAMER_COLOR,
    E_STREAMER_DRAW_DISTANCE,
    E_STREAMER_EXTRA_ID,
    E_STREAMER_INTERIOR_ID,
    E_STREAMER_MAX_X,
    E_STREAMER_MAX_Y,
    E_STREAMER_MAX_Z,
    E_STREAMER_MIN_X,
    E_STREAMER_MIN_Y,
    E_STREAMER_MIN_Z,
    E_STREAMER_MODEL_ID,
    E_STREAMER_MOVE_R_X,
    E_STREAMER_MOVE_R_Y,
    E_STREAMER_MOVE_R_Z,
    E_STREAMER_MOVE_SPEED,
    E_STREAMER_MOVE_X,
    E_STREAMER_MOVE_Y,
    E_STREAMER_MOVE_Z,
    E_STREAMER_NEXT_X,
    E_STREAMER_NEXT_Y,
    E_STREAMER_NEXT_Z,
    E_STREAMER_PLAYER_ID,
    E_STREAMER_R_X,
    E_STREAMER_R_Y,
    E_STREAMER_R_Z,
    E_STREAMER_SIZE,
    E_STREAMER_STREAM_DISTANCE,
    E_STREAMER_STYLE,
    E_STREAMER_TEST_LOS,
    E_STREAMER_TYPE,
    E_STREAMER_WORLD_ID,
    E_STREAMER_X,
    E_STREAMER_Y,
    E_STREAMER_Z
    }


    // Setting Natives


    native Streamer_TickRate(rate);
    native Streamer_MaxItems(type, items);
    native Streamer_VisibleItems(type, items);
    native Streamer_CellDistance(Float:distance);
    native Streamer_CellSize(Float:size);


    // Update Natives


    native Streamer_Update(playerid);
    native Streamer_UpdateEx(playerid, Float:x, Float:y, Float:z, worldid = -1, interiorid = -1);
    native Streamer_ToggleIdleUpdate(playerid, toggle);


    // Data Manipulation Natives


    native Streamer_GetFloatData(type, {Text3D,_}:id, data, &Float:result);
    native Streamer_SetFloatData(type, {Text3D,_}:id, data, Float:value);
    native Streamer_GetIntData(type, {Text3D,_}:id, data);
    native Streamer_SetIntData(type, {Text3D,_}:id, data, value);
    native Streamer_GetArrayData(type, {Text3D,_}:id, data, dest[], maxlength = sizeof dest);
    native Streamer_SetArrayData(type, {Text3D,_}:id, data, const src[], maxlength = sizeof src);
    native Streamer_IsInArrayData(type, {Text3D,_}:id, data, value);
    native Streamer_AppendArrayData(type, {Text3D,_}:id, data, value);
    native Streamer_RemoveArrayData(type, {Text3D,_}:id, data, value);
    native Streamer_GetUpperBound(type);


    // Miscellaneous Natives


    native Streamer_IsItemVisible(playerid, type, {Text3D,_}:id);
    native Streamer_DestroyAllVisibleItems(playerid, type);
    native Streamer_CountVisibleItems(playerid, type);


    // Object Natives


    native CreateDynamicObject(modelid, Float:x, Float:y, Float:z, Float:rx, Float:ry, Float:rz, worldid = -1, interiorid = -1, playerid = -1, Float:streamdistance = 300.0);
    native DestroyDynamicObject(objectid);
    native IsValidDynamicObject(objectid);
    native SetDynamicObjectPos(objectid, Float:x, Float:y, Float:z);
    native GetDynamicObjectPos(objectid, &Float:x, &Float:y, &Float:z);
    native SetDynamicObjectRot(objectid, Float:rx, Float:ry, Float:rz);
    native GetDynamicObjectRot(objectid, &Float:rx, &Float:ry, &Float:rz);
    native MoveDynamicObject(objectid, Float:x, Float:y, Float:z, Float:speed, Float:rx = -1000.0, Float:ry = -1000.0, Float:rz = -1000.0);
    native StopDynamicObject(objectid);
    native IsDynamicObjectMoving(objectid);
    native DestroyAllDynamicObjects();
    native CountDynamicObjects();


    // Pickup Natives


    native CreateDynamicPickup(modelid, type, Float:x, Float:y, Float:z, worldid = -1, interiorid = -1, playerid = -1, Float:streamdistance = 100.0);
    native DestroyDynamicPickup(pickupid);
    native IsValidDynamicPickup(pickupid);
    native DestroyAllDynamicPickups();
    native CountDynamicPickups();


    // Checkpoint Natives


    native CreateDynamicCP(Float:x, Float:y, Float:z, Float:size, worldid = -1, interiorid = -1, playerid = -1, Float:streamdistance = 100.0);
    native DestroyDynamicCP(checkpointid);
    native IsValidDynamicCP(checkpointid);
    native TogglePlayerDynamicCP(playerid, checkpointid, toggle);
    native TogglePlayerAllDynamicCPs(playerid, toggle);
    native IsPlayerInDynamicCP(playerid, checkpointid);
    native DestroyAllDynamicCPs();
    native CountDynamicCPs();


    // Race Checkpoint Natives


    native CreateDynamicRaceCP(type, Float:x, Float:y, Float:z, Float:nextx, Float:nexty, Float:nextz, Float:size, worldid = -1, interiorid = -1, playerid = -1, Float:streamdistance = 100.0);
    native DestroyDynamicRaceCP(checkpointid);
    native IsValidDynamicRaceCP(checkpointid);
    native TogglePlayerDynamicRaceCP(playerid, checkpointid, toggle);
    native TogglePlayerAllDynamicRaceCPs(playerid, toggle);
    native IsPlayerInDynamicRaceCP(playerid, checkpointid);
    native DestroyAllDynamicRaceCPs();
    native CountDynamicRaceCPs();


    // Map Icon Natives


    native CreateDynamicMapIcon(Float:x, Float:y, Float:z, type, color, worldid = -1, interiorid = -1, playerid = -1, Float:streamdistance = 100.0);
    native DestroyDynamicMapIcon(iconid);
    native IsValidDynamicMapIcon(iconid);
    native DestroyAllDynamicMapIcons();
    native CountDynamicMapIcons();


    // 3D Text Label Natives


    native Text3D:CreateDynamic3DTextLabel(const text[], color, Float:x, Float:y, Float:z, Float:drawdistance, attachedplayer = INVALID_PLAYER_ID, attachedvehicle = INVALID_VEHICLE_ID, testlos = 0, worldid = -1, interiorid = -1, playerid = -1, Float:streamdistance = 100.0);
    native DestroyDynamic3DTextLabel(Text3D:id);
    native IsValidDynamic3DTextLabel(Text3D:id);
    native UpdateDynamic3DTextLabelText(Text3D:id, color, const text[]);
    native DestroyAllDynamic3DTextLabels();
    native CountDynamic3DTextLabels();


    // Area Natives


    native CreateDynamicCircle(Float:x, Float:y, Float:size, worldid = -1, interiorid = -1, playerid = -1);
    native CreateDynamicRectangle(Float:minx, Float:miny, Float:maxx, Float:maxy, worldid = -1, interiorid = -1, playerid = -1);
    native CreateDynamicSphere(Float:x, Float:y, Float:z, Float:size, worldid = -1, interiorid = -1, playerid = -1);
    native CreateDynamicCube(Float:minx, Float:miny, Float:minz, Float:maxx, Float:maxy, Float:maxz, worldid = -1, interiorid = -1, playerid = -1);
    native CreateDynamicPolygon(Float:points[], Float:minz = -FLOAT_INFINITY, Float:maxz = FLOAT_INFINITY, maxpoints = sizeof points, worldid = -1, interiorid = -1, playerid = -1);
    native DestroyDynamicArea(areaid);
    native IsValidDynamicArea(areaid);
    native TogglePlayerDynamicArea(playerid, areaid, toggle);
    native TogglePlayerAllDynamicAreas(playerid, toggle);
    native IsPlayerInDynamicArea(playerid, areaid);
    native IsPlayerInAnyDynamicArea(playerid);
    native AttachDynamicAreaToPlayer(areaid, playerid);
    native AttachDynamicAreaToVehicle(areaid, vehicleid);
    native DestroyAllDynamicAreas();
    native CountDynamicAreas();


    // Extended Natives


    native CreateDynamicObjectEx(modelid, Float:x, Float:y, Float:z, Float:rx, Float:ry, Float:rz, Float:drawdistance = 0.0, Float:streamdistance = 200.0, worlds[] = { -1 }, interiors[] = { -1 }, players[] = { -1 }, maxworlds = sizeof worlds, maxinteriors = sizeof interiors, maxplayers = sizeof players);
    native CreateDynamicPickupEx(modelid, type, Float:x, Float:y, Float:z, Float:streamdistance = 100.0, worlds[] = { -1 }, interiors[] = { -1 }, players[] = { -1 }, maxworlds = sizeof worlds, maxinteriors = sizeof interiors, maxplayers = sizeof players);
    native CreateDynamicCPEx(Float:x, Float:y, Float:z, Float:size, Float:streamdistance = 100.0, worlds[] = { -1 }, interiors[] = { -1 }, players[] = { -1 }, maxworlds = sizeof worlds, maxinteriors = sizeof interiors, maxplayers = sizeof players);
    native CreateDynamicRaceCPEx(type, Float:x, Float:y, Float:z, Float:nextx, Float:nexty, Float:nextz, Float:size, Float:streamdistance = 100.0, worlds[] = { -1 }, interiors[] = { -1 }, players[] = { -1 }, maxworlds = sizeof worlds, maxinteriors = sizeof interiors, maxplayers = sizeof players);
    native CreateDynamicMapIconEx(Float:x, Float:y, Float:z, type, color, style = MAPICON_LOCAL, Float:streamdistance = 100.0, worlds[] = { -1 }, interiors[] = { -1 }, players[] = { -1 }, maxworlds = sizeof worlds, maxinteriors = sizeof interiors, maxplayers = sizeof players);
    native Text3D:CreateDynamic3DTextLabelEx(const text[], color, Float:x, Float:y, Float:z, Float:drawdistance, attachedplayer = INVALID_PLAYER_ID, attachedvehicle = INVALID_VEHICLE_ID, testlos = 0, Float:streamdistance = 100.0, worlds[] = { -1 }, interiors[] = { -1 }, players[] = { -1 }, maxworlds = sizeof worlds, maxinteriors = sizeof interiors, maxplayers = sizeof players);
    native CreateDynamicCircleEx(Float:x, Float:y, Float:size, worlds[] = { -1 }, interiors[] = { -1 }, players[] = { -1 }, maxworlds = sizeof worlds, maxinteriors = sizeof interiors, maxplayers = sizeof players);
    native CreateDynamicRectangleEx(Float:minx, Float:miny, Float:maxx, Float:maxy, worlds[] = { -1 }, interiors[] = { -1 }, players[] = { -1 }, maxworlds = sizeof worlds, maxinteriors = sizeof interiors, maxplayers = sizeof players);
    native CreateDynamicSphereEx(Float:x, Float:y, Float:z, Float:size, worlds[] = { -1 }, interiors[] = { -1 }, players[] = { -1 }, maxworlds = sizeof worlds, maxinteriors = sizeof interiors, maxplayers = sizeof players);
    native CreateDynamicCubeEx(Float:minx, Float:miny, Float:minz, Float:maxx, Float:maxy, Float:maxz, worlds[] = { -1 }, interiors[] = { -1 }, players[] = { -1 }, maxworlds = sizeof worlds, maxinteriors = sizeof interiors, maxplayers = sizeof players);
    native CreateDynamicPolygonEx(Float:points[], Float:minz = -FLOAT_INFINITY, Float:maxz = FLOAT_INFINITY, maxpoints = sizeof points, worlds[] = { -1 }, interiors[] = { -1 }, players[] = { -1 }, maxworlds = sizeof worlds, maxinteriors = sizeof interiors, maxplayers = sizeof players);


    // Internal Natives


    native Streamer_CallbackHook(callback, ...);


    // Callbacks


    forward OnDynamicObjectMoved(objectid);
    forward OnPlayerPickUpDynamicPickup(playerid, pickupid);
    forward OnPlayerEnterDynamicCP(playerid, checkpointid);
    forward OnPlayerLeaveDynamicCP(playerid, checkpointid);
    forward OnPlayerEnterDynamicRaceCP(playerid, checkpointid);
    forward OnPlayerLeaveDynamicRaceCP(playerid, checkpointid);
    forward OnPlayerEnterDynamicArea(playerid, areaid);
    forward OnPlayerLeaveDynamicArea(playerid, areaid);


    // Callback Hook Section


    #define STREAMER_OPC (0)
    #define STREAMER_OPDC (1)
    #define STREAMER_OPPP (2)
    #define STREAMER_OPEC (3)
    #define STREAMER_OPLC (4)
    #define STREAMER_OPERC (5)
    #define STREAMER_OPLRC (6)


    static bool:Streamer_g_OPC = false;
    static bool:Streamer_g_OPDC = false;
    static bool:Streamer_g_OPPP = false;
    static bool:Streamer_g_OPEC = false;
    static bool:Streamer_g_OPLC = false;
    static bool:Streamer_g_OPERC = false;
    static bool:Streamer_g_OPLRC = false;


    public OnFilterScriptInit()
    {
    Streamer_g_OPC = funcidx("Streamer_OnPlayerConnect") != -1;
    Streamer_g_OPDC = funcidx("Streamer_OnPlayerDisconnect") != -1;
    Streamer_g_OPPP = funcidx("Streamer_OnPlayerPickUpPickup") != -1;
    Streamer_g_OPEC = funcidx("Streamer_OnPlayerEnterCP") != -1;
    Streamer_g_OPLC = funcidx("Streamer_OnPlayerLeaveCP") != -1;
    Streamer_g_OPERC = funcidx("Streamer_OnPlayerEnterRaceCP") != -1;
    Streamer_g_OPLRC = funcidx("Streamer_OnPlayerLeaveRaceCP") != -1;
    if (funcidx("Streamer_OnFilterScriptInit") != -1)
    {
    return CallLocalFunction("Streamer_OnFilterScriptInit", "");
    }
    return 1;
    }


    #if defined _ALS_OnFilterScriptInit
    #undef OnFilterScriptInit
    #else
    #define _ALS_OnFilterScriptInit
    #endif
    #define OnFilterScriptInit Streamer_OnFilterScriptInit


    forward Streamer_OnFilterScriptInit();


    public OnGameModeInit()
    {
    Streamer_g_OPC = funcidx("Streamer_OnPlayerConnect") != -1;
    Streamer_g_OPDC = funcidx("Streamer_OnPlayerDisconnect") != -1;
    Streamer_g_OPPP = funcidx("Streamer_OnPlayerPickUpPickup") != -1;
    Streamer_g_OPEC = funcidx("Streamer_OnPlayerEnterCP") != -1;
    Streamer_g_OPLC = funcidx("Streamer_OnPlayerLeaveCP") != -1;
    Streamer_g_OPERC = funcidx("Streamer_OnPlayerEnterRaceCP") != -1;
    Streamer_g_OPLRC = funcidx("Streamer_OnPlayerLeaveRaceCP") != -1;
    if (funcidx("Streamer_OnGameModeInit") != -1)
    {
    return CallLocalFunction("Streamer_OnGameModeInit", "");
    }
    return 1;
    }


    #if defined _ALS_OnGameModeInit
    #undef OnGameModeInit
    #else
    #define _ALS_OnGameModeInit
    #endif
    #define OnGameModeInit Streamer_OnGameModeInit


    forward Streamer_OnGameModeInit();


    public OnPlayerConnect(playerid)
    {
    if (!IsPlayerNPC(playerid))
    {
    Streamer_CallbackHook(STREAMER_OPC, playerid);
    }
    if (Streamer_g_OPC)
    {
    return CallLocalFunction("Streamer_OnPlayerConnect", "d", playerid);
    }
    return 1;
    }


    #if defined _ALS_OnPlayerConnect
    #undef OnPlayerConnect
    #else
    #define _ALS_OnPlayerConnect
    #endif
    #define OnPlayerConnect Streamer_OnPlayerConnect


    forward Streamer_OnPlayerConnect(playerid);


    public OnPlayerDisconnect(playerid, reason)
    {
    if (!IsPlayerNPC(playerid))
    {
    Streamer_CallbackHook(STREAMER_OPDC, playerid, reason);
    }
    if (Streamer_g_OPDC)
    {
    return CallLocalFunction("Streamer_OnPlayerDisconnect", "dd", playerid, reason);
    }
    return 1;
    }


    #if defined _ALS_OnPlayerDisconnect
    #undef OnPlayerDisconnect
    #else
    #define _ALS_OnPlayerDisconnect
    #endif
    #define OnPlayerDisconnect Streamer_OnPlayerDisconnect


    forward Streamer_OnPlayerDisconnect(playerid, reason);


    public OnPlayerPickUpPickup(playerid, pickupid)
    {
    if (!IsPlayerNPC(playerid))
    {
    Streamer_CallbackHook(STREAMER_OPPP, playerid, pickupid);
    }
    if (Streamer_g_OPPP)
    {
    return CallLocalFunction("Streamer_OnPlayerPickUpPickup", "dd", playerid, pickupid);
    }
    return 1;
    }


    #if defined _ALS_OnPlayerPickUpPickup
    #undef OnPlayerPickUpPickup
    #else
    #define _ALS_OnPlayerPickUpPickup
    #endif
    #define OnPlayerPickUpPickup Streamer_OnPlayerPickUpPickup


    forward Streamer_OnPlayerPickUpPickup(playerid, pickupid);


    public OnPlayerEnterCheckpoint(playerid)
    {
    if (!IsPlayerNPC(playerid))
    {
    Streamer_CallbackHook(STREAMER_OPEC, playerid);
    }
    if (Streamer_g_OPEC)
    {
    return CallLocalFunction("Streamer_OnPlayerEnterCP", "d", playerid);
    }
    return 1;
    }


    #if defined _ALS_OnPlayerEnterCheckpoint
    #undef OnPlayerEnterCheckpoint
    #else
    #define _ALS_OnPlayerEnterCheckpoint
    #endif
    #define OnPlayerEnterCheckpoint Streamer_OnPlayerEnterCP


    forward Streamer_OnPlayerEnterCP(playerid);


    public OnPlayerLeaveCheckpoint(playerid)
    {
    if (!IsPlayerNPC(playerid))
    {
    Streamer_CallbackHook(STREAMER_OPLC, playerid);
    }
    if (Streamer_g_OPLC)
    {
    return CallLocalFunction("Streamer_OnPlayerLeaveCP", "d", playerid);
    }
    return 1;
    }


    #if defined _ALS_OnPlayerLeaveCheckpoint
    #undef OnPlayerLeaveCheckpoint
    #else
    #define _ALS_OnPlayerLeaveCheckpoint
    #endif
    #define OnPlayerLeaveCheckpoint Streamer_OnPlayerLeaveCP


    forward Streamer_OnPlayerLeaveCP(playerid);


    public OnPlayerEnterRaceCheckpoint(playerid)
    {
    if (!IsPlayerNPC(playerid))
    {
    Streamer_CallbackHook(STREAMER_OPERC, playerid);
    }
    if (Streamer_g_OPERC)
    {
    return CallLocalFunction("Streamer_OnPlayerEnterRaceCP", "d", playerid);
    }
    return 1;
    }


    #if defined _ALS_OnPlayerEnterRaceCP
    #undef OnPlayerEnterRaceCheckpoint
    #else
    #define _ALS_OnPlayerEnterRaceCP
    #endif
    #define OnPlayerEnterRaceCheckpoint Streamer_OnPlayerEnterRaceCP


    forward Streamer_OnPlayerEnterRaceCP(playerid);


    public OnPlayerLeaveRaceCheckpoint(playerid)
    {
    if (!IsPlayerNPC(playerid))
    {
    Streamer_CallbackHook(STREAMER_OPLRC, playerid);
    }
    if (Streamer_g_OPLRC)
    {
    return CallLocalFunction("Streamer_OnPlayerLeaveRaceCP", "d", playerid);
    }
    return 1;
    }


    #if defined _ALS_OnPlayerLeaveRaceCP
    #undef OnPlayerLeaveRaceCheckpoint
    #else
    #define _ALS_OnPlayerLeaveRaceCP
    #endif
    #define OnPlayerLeaveRaceCheckpoint Streamer_OnPlayerLeaveRaceCP


    forward Streamer_OnPlayerLeaveRaceCP(playerid);

  • ich meine im Script selber -.-


    alles Objekte im Sxript von CreateObject zu CreateDynamicObject machen

  • Ok,
    ich habe "CreateObject" zu "CreateDynamicObject" umgeschrieben.


    Objekte werden geladen :)


    Danke!



    //EDIT:
    Objekte werden geladet, aber Server crasht nach der Zeit... o_O



    SA-MP Dedicated Server
    ----------------------
    v0.3d-R2, (C)2005-2011 SA-MP Team


    [16:34:16]
    [16:34:16] Server Plugins
    [16:34:16] --------------
    [16:34:16] Loading plugin: streamer.so
    [16:34:16]


    *** Streamer Plugin v2.6 by Incognito loaded ***


    [16:34:16] Loaded.
    [16:34:16] Loaded 1 plugins.


    [16:34:16]
    [16:34:16] Ban list
    [16:34:16] --------
    [16:34:16] Loaded: samp.ban
    [16:34:16]
    [16:34:16]
    [16:34:16] Filterscripts
    [16:34:16] ---------------
    [16:34:16] Loading filterscript 'Blinker.amx'...
    [16:34:16] *** Streamer Plugin: Obsolete or invalid native found (script needs to be recompiled with the latest include file)
    [16:34:16]
    --------------------------------------
    [16:34:16] Blank Filterscript by your name here
    [16:34:16] --------------------------------------


    [16:34:16] Loaded 1 filterscripts.


    [16:34:16] AllowAdminTeleport() : function is deprecated. Please see OnPlayerClickMap()
    [16:34:16] Pickups Max = 2048, Current Pickups = 436
    [16:34:17] _______________________________________
    [16:34:17] Das Script wurde Vollständig geladen!
    [16:34:17] German Reallife: LS/SF/LV
    [16:34:17] _______________________________________
    [16:34:17]
    [16:34:17] Number of vehicle models: 73
    [17:27:17] [join] raphi has joined the server (2:91.15.10.218)
    [17:27:28] raphi has logged in.
    [17:27:39] Puma hat sich zu raphi geportet.
    [17:27:39] Puma hat sich zu raphi geportet.
    [17:27:40] [death] raphi died 255
    [17:27:44] Puma hat sich zu raphi geportet.
    [17:27:44] Puma hat sich zu raphi geportet.
    [17:27:47] Puma hat sich zu raphi geportet.
    [17:27:47] Puma hat sich zu raphi geportet.
    [17:27:59] [chat] [raphi]: ^^
    [17:28:07] [chat] [Puma]: :)
    [17:28:10] [chat] [raphi]: Was das für oldtimer?
    [17:28:27] [chat] [Puma]: Ist ein Fehler
    [17:28:34] [chat] [raphi]: ah Okay
    [17:28:45] [chat] [Puma]: Mom
    [17:28:55] [part] raphi has left the server (2:2)
    [17:29:25] --- Server Shutting Down.
    [17:29:25] [part] Roach has left the server (0:0)
    [17:29:25] [part] Puma has left the server (1:0)
    [17:29:25]


    *** Streamer Plugin v2.6 by Incognito unloaded ***


    //Edit4:
    Er hört mitten drin auf den Streamer zu laden, an was liegt es?

    4 Mal editiert, zuletzt von SA:MP () aus folgendem Grund: Edit2-/3: Fehler verbessert.