Object move
#1

is there anyway to check if an object move do something? i mean if i hit a small thing like cone with a car and moved can i check that? and another simillar one. i want to check if i hit with car even if the object didnt moved.
Reply
#2

There was an callback, but i'm not sure if client pass this information to server, and then there's no actual way, except one dumb one, which i'm not going to tell


Won't checking like 20 objects each 0.1 sec with comparing positions make a great overflow? And.. add an limiter if object has already moved.
VVV
Reply
#3

Give the object a name, e.g. and get the position
This must be the general (not in a public function!)

pawn Код:
new object, objectmovet, Float:x, Float:y, Float:z;
object = CreateObject(...);
objectmovet = SetTimer("ObjectMove", 100, true);
Create a forward

pawn Код:
forward ObjectMove(objectid);
with a public function

pawn Код:
public ObjectMove(objectid)
{
    new bool:moved;
    moved = false;
    if(GetObjectPos(object, x, y, z) != [the x-y-z coordinates from createobject])
    {
        moved = true;
    }
    else moved = false;
    return 1;
}
Might give some errors but ye, give it a try
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)