[HELP] Objects - VERY IMPORTANT
#1

Hey there.
I have a problem in my server, sometimes I can't create an object ingame, I mean when I try /roadblock for example it doesn't show the object but it says blablabla, and when I do something else I know something happens but I can't see the object. I'm going to add an object streamer soon, will it solve the problem?
Thank you.
Reply
#2

Are you in a different world than the object is?

Anyway, show us the /roadblock command.
Reply
#3

Quote:
Originally Posted by _Xerxes_
Are you in a different world than the object is?

Anyway, show us the /roadblock command.
Thank you, but this is not my problem.
I think that there is an object limit, I also tried to add an object streamer and it worked but sometimes when I come ingame I can't create a new objects as I said.
Reply
#4

Well then show the command.
Reply
#5

Quote:
Originally Posted by _Xerxes_
Well then show the command.
It's not the command, it's the objects..
Here is the code:
pawn Код:
if(strcmp(cmdtext, "/roadblock", true)==0 || strcmp(cmdtext, "/rb", true)==0)
    {
        if (PlayerInfo[playerid][pMember] != 1 && PlayerInfo[playerid][pLeader] != 1)
        {
          if(PlayerInfo[playerid][pMember] != 2 && PlayerInfo[playerid][pLeader] != 2)
          {
            return SendClientMessage(playerid, COLOR_GREY, "You are not a cop!");
            }
        }

        if (PlayerInfo[playerid][pRoadblock] != 0) return SendClientMessage(playerid, COLOR_GREY, "You can only deploy 1 roadblock at a time, type /rrb to remove your existing one.");
        if (roadblocktimer != 0) return SendClientMessage(playerid, COLOR_GREY, "Please wait before trying to spawn another roadblock!");
        new Float:X, Float:Y, Float:Z, Float:A;
        GetPlayerPos(playerid, X, Y, Z);
        GetPlayerFacingAngle(playerid, A);
        PlayerInfo[playerid][pRoadblock] = CreateStreamedObject(981, X, Y, Z, 0.0, 0.0, A+180,100);//981
        SetPlayerPos(playerid, X, Y, Z+4);
        GameTextForPlayer(playerid, "~w~Roadblock ~r~Placed", 5000, 5);
        SendClientMessage(playerid, COLOR_GREEN, "Roadblock deployed successfully, type /rrb or /roadunblock to remove it.");
        roadblocktimer = 1;
        GetPlayerName(playerid, sendername, sizeof(sendername));
        format(string, sizeof(string), "HQ: A roadblock has been deployed by %s, it has been marked on the map by a checkpoint.", sendername);
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                if(PlayerInfo[i][pMember] == 1 || PlayerInfo[i][pLeader] == 1)
                {
                    SetPlayerCheckpoint(playerid, X, Y, Z-10, 1.0);
                    SendClientMessage(i, TEAM_BLUE_COLOR, string);
                    if (PlayerInfo[i][pRank] >= 5 && PlayerInfo[i][pMember] || PlayerInfo[i][pLeader] == 1)
                    {
                        SendClientMessage(i, COLOR_YELLOW, "You can remove all roadblocks by typing /rrball");
                    }
                }
            }
        }
        SetTimer("ResetRoadblockTimer", 10000, false);
        return 1;
    }
Reply
#6

Quote:
Originally Posted by MaykoX[PSYCHO
]
What streamer you use ?
rStreamer, others just didn't work at all.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)