how can I check
#1

Im using object editor it saves objects as:
pawn Код:
format(string1, sizeof(string1), "%d, %f,%f,%f, %f,%f,%f,%d\r\n",inputtext, X+1,Y+1,Z+1, 0,0,0,object);
"object" variable is the ID (new object = 0; object++)

If you type /load ID
eg /load 2, how ca I create the object that has 2 at the end ?
("%d, %f,%f,%f, %f,%f,%f,2\r\n) <--
Reply
#2

oh comon, there must be a way of checking?
Reply
#3

it happens when you create the object

https://sampwiki.blast.hk/wiki/CreateObject
pawn Код:
new myobj = CreateObject(2587, 2001.195679, 1547.113892, 14.283400, 0.0, 0.0, 96.0);
myobj will hold the id of the object to be used in script
Reply
#4

Ok different story.

im trying to do this
pawn Код:
public OnPlayerEditObject(playerid, playerobject, objectid, response, Float:fX, Float:fY, Float:fZ, Float:fRotX, Float:fRotY, Float:fRotZ)
{
    if(response == 1)
    {
        new File:hFile;
        hFile = fopen("Ustawienia/obiekty.txt", io_write);
        new line[128];
        format(line, sizeof(line), "%d, %f,%f,%f, %f,%f,%f,%d\r\n",Selected1[playerid], fX,fY,fZ,fRotX,fRotY,fRotZ,SelectedO[playerid]);
        fwrite(hFile, line);
    }
}
so after You click save in the new 0.3e editor, I want the created object to be updated, but to do that it has to overwrite this, but how without checking?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)