Label & Pickup problems.
#1

Hello.
I've few problems.
I'm trying to create a label & a pickup from a filterscript.
This is not working, I still don't know why.
PHP код:
    Pickup_ID CreateDynamicPickup(12391708.8225, -775.7249POINT_Z+2.0WORLDIDINTERIOR);
    
Label_ID CreateDynamic3DTextLabel("text"GOLD708.8225, -775.7249POINT_Z+2.0LABEL_DISTANCE+10.0WORLDIDINTERIOR); 
POINT_Z is a float. WORLDID & INTERIOR are -1. LABEL_DISTANCE is 12.0.
Yes I'm going to the right coordinates because I'm teleporting to the same.
Код:
708.8225, -775.7249, POINT_Z+2.0
Reply
#2

I always include the full parameters* even though you don't intend them to be there. Before worldid there are 3 parameters. I usually just place the following:

Код:
CreateDynamic3DTextLabel("text", GOLD, 708.8225, -775.7249, POINT_Z+2.0, LABEL_DISTANCE+10.0, INVALID_PLAYER_ID, INVALID_VEHICLE_ID, 0, WORLDID, INTERIOR);
What the current one is reading is the following:
text[] = "text"
color = GOLD
Float:x = 708.8225
Float:y = -775.7249
Float:z = POINT_Z+2.0
Float:drawdistance = LABEL_DISTANCE+10.0
attachedplayer = WORLDID
attachedvehicle = INTERIOR

If that makes any sense.

*Only to the point where I need to change something, obviously, if your last parameter is interior id, then you don't have to continue with more parameters unless you want to.
Reply
#3

Is there any warnings / errors from streamer plugin in your server log?
Also for your CreateDynamic3DTextLabel, 7th and 8th parameters are for attachedplayer and attachedvehicle.
Here's the fixed version of your CreateDynamic3DTextLabel code:
Код:
Label_ID = CreateDynamic3DTextLabel("text", GOLD, 708.8225, -775.7249, POINT_Z+2.0, LABEL_DISTANCE+10.0, .worldid=WORLDID, .interiorid=INTERIOR);
Edit: Hansrutger was faster
Reply
#4

Quote:
Originally Posted by X337
Посмотреть сообщение
Is there any warnings / errors from streamer plugin in your server log?
Also for your CreateDynamic3DTextLabel, 7th and 8th parameters are for attachedplayer and attachedvehicle.
Here's the fixed version of your CreateDynamic3DTextLabel code:
Код:
Label_ID = CreateDynamic3DTextLabel("text", GOLD, 708.8225, -775.7249, POINT_Z+2.0, LABEL_DISTANCE+10.0, .worldid=WORLDID, .interiorid=INTERIOR);
Edit: Hansrutger was faster
I had no idea you could do ".parameter=..." to assign it? That's way more convenient if that works?
Reply
#5

Alright, my bad. Thanks. What mean ".parameter=..." like you did?
Also, this one should work no?
PHP код:
    Pickup_ID CreateDynamicPickup(12391708.8225, -775.7249POINT_Z+2.0WORLDIDINTERIOR);
    
// CreateDynamicPickup(modelid, type, Float:x, Float:y, Float:z, worldid = -1, interiorid = -1, playerid = -1, Float:streamdistance = STREAMER_PICKUP_SD, STREAMER_TAG_AREA areaid = STREAMER_TAG_AREA -1, priority = 0); 
Reply
#6

Quote:
Originally Posted by Dayrion
Посмотреть сообщение
Alright, my bad. Thanks. What mean ".parameter=..." like you did?
Also, this one should work no?
PHP код:
    Pickup_ID CreateDynamicPickup(12391708.8225, -775.7249POINT_Z+2.0WORLDIDINTERIOR);
    
// CreateDynamicPickup(modelid, type, Float:x, Float:y, Float:z, worldid = -1, interiorid = -1, playerid = -1, Float:streamdistance = STREAMER_PICKUP_SD, STREAMER_TAG_AREA areaid = STREAMER_TAG_AREA -1, priority = 0); 
Yes it should work, check your server log. Maybe there's a problem with your streamer plugin.

Quote:
Originally Posted by Hansrutger
Посмотреть сообщение
I had no idea you could do ".parameter=..." to assign it? That's way more convenient if that works?
Yes you can use .parameter=value if you want to skip any other optional parameters.
Reply
#7

All is fine with the plugin
Код:
[17:10:52] Server Plugins
[17:10:52] --------------
[17:10:52]  Loading plugin: crashdetect.dll
[17:10:52]   CrashDetect v4.15.1 is OK.
[17:10:52]   Loaded.
[17:10:52]  Loading plugin: mysql.dll
[17:10:52]  >> plugin.mysql: R41 successfully loaded.
[17:10:52]   Loaded.
[17:10:52]  Loading plugin: streamer.dll
[17:10:52] 

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

[17:10:52]   Loaded.
[17:10:52]  Loading plugin: sscanf.dll
[17:10:52] 

[17:10:52]  ===============================

[17:10:52]       sscanf plugin loaded.     

[17:10:52]          Version:  2.8.1        

[17:10:52]    © 2012 Alex "******" Cole  

[17:10:52]  ===============================

[17:10:52]   Loaded.
[17:10:52]  Loading plugin: FCNPC.dll
[17:10:52] 
[17:10:52] -------------------------------------------------
[17:10:52]      FCNPC - Fully Controllable NPC v1.6.1
[17:10:52]          Windows SA-MP 0.3.7 R2-1
[17:10:52]           Dec 25 2016 at 14:07:43
[17:10:52] 
[17:10:52]   Author:       OrMisicL (2013 - 2015)
[17:10:52]   Continued by: ziggi (2016 - present)
[17:10:52]   Contributors: kurta999, Neutralneu
[17:10:52] -------------------------------------------------
Edit:
Even if I put the code in my GameMode
PHP код:
    CreateDynamicPickup(12391708.8225, -775.72494253.3760+1.0); 
Reply
#8

Pickup doesn't get created when they are not on the ground or what?
I made differents tests:
PHP код:
    Pickup_ID CreatePickup(12391708.3482,-775.0904,4255.3760WORLDID); // doesn't work
    
Pickup_ID CreatePickup(12391, -1391.6177,-66.3652,14.1484WORLDID); // work fine 
Reply
#9

Bump
Reply
#10

Pickups above height of 4000 will not show up. I don't know why, but i think it's SA:MP bug.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)