Jump to content
  • 0

Problem with a custom sign


BetterDeadThanZed

Question

I am using the following script, called from init.sqf, to make a custom sign for my traders:

diag_log format['Custom %1 - Starting billboards.sqf',time];

_pos = [4635.4492, 1855.5695, 3.8146973e-006];
_object = createVehicle ["WarfareBunkerSign", _pos, [], 0, "CAN_COLLIDE"];
_object setDir 96.052811;
_object setPosATL _pos;
_object setObjectTexture [0, "zedtrading.jpg"];
_object allowDamage false;

However, the result is not what I want. Here's what I see:

20180114183045_1.jpg

There is a flickering at the dividing line between the flag and the custom image. Any suggestions?

Link to comment
Share on other sites

17 answers to this question

Recommended Posts

  • 0

In the sanford and son trader mod i released, I have this server side. in a file called sanford.sqf

_vehicle_121= objNull;
if (true) then
{
  _this = createVehicle ["WarfareBunkerSign", [9919.52, 5422.02, 0.490173], [], 0, "CAN_COLLIDE"];
  _vehicle_121 = _this;
  _this setDir 288.201;
  _this setVehicleInit "this SetObjectTexture [0,""graphics\sandfordandson.jpg""]";
};

I call this file in the server functions. (server side)

And the image goes into the mission pbo.

Also, if your pixels are off by 1, it will throw things off. you can use the picture in the sanford mod as a template.

Link to comment
Share on other sites

  • 0
  On 1/17/2018 at 1:31 AM, theduke said:

In the sanford and son trader mod i released, I have this server side. in a file called sanford.sqf

_vehicle_121= objNull;
if (true) then
{
  _this = createVehicle ["WarfareBunkerSign", [9919.52, 5422.02, 0.490173], [], 0, "CAN_COLLIDE"];
  _vehicle_121 = _this;
  _this setDir 288.201;
  _this setVehicleInit "this SetObjectTexture [0,""graphics\sandfordandson.jpg""]";
};

I call this file in the server functions. (server side)

And the image goes into the mission pbo.

Also, if your pixels are off by 1, it will throw things off. you can use the picture in the sanford mod as a template.

Expand  

There's no sense in putting only a few kb of code into the server files. It's so small it'll hardly affect the mission download size. I prefer to have it in the mission folder with the image. It's neater and more convenient to me that way. The image is fine. It's the same one I used in Arma 3 on a sign just like I'm trying to do in Arma 2.

Link to comment
Share on other sites

  • 0
  On 1/17/2018 at 1:41 AM, BetterDeadThanZed said:

There's no sense in putting only a few kb of code into the server files. It's so small it'll hardly affect the mission download size. I prefer to have it in the mission folder with the image. It's neater and more convenient to me that way. The image is fine. It's the same one I used in Arma 3 on a sign just like I'm trying to do in Arma 2.

Expand  

you're asking in the forums for a solution. I gave you a solution. Suit yourself.

Ill refrain from helping you in the future ;) don't seem to appreciate it

Link to comment
Share on other sites

  • 0
  On 1/17/2018 at 1:50 AM, theduke said:

you're asking in the forums for a solution. I gave you a solution. Suit yourself.

Ill refrain from helping you in the future ;) don't seem to appreciate it

Expand  

Yes, you gave me a solution and it didn't work.

You also didn't provide a link for this "sanford mod".

Link to comment
Share on other sites

  • 0

I also do it server side... because it works.

_vehicle_617 = objNull;
if (true) then
{
  _this = createVehicle ["SignM_UN_Base_EP1", [6269.9287, 7828.3516, 0], [], 0, "CAN_COLLIDE"];
  _vehicle_617 = _this;
  _this setDir 63.965408;
   _this setVehicleInit "this setObjectTexture [0,""img\billboard.jpg""]";
  _this setPos [6269.9287, 7828.3516, 0];
  _this allowDamage false;
};

Link to comment
Share on other sites

  • 0
  On 1/17/2018 at 1:56 AM, theduke said:

lol i provided you with the info needed. the snippet of code is all you need, from that whole mod. anyways GL with your projects

Expand  

I appreciate your time. Hopefully someone will see this post and maybe have another suggestion, as yours didn't work for me. Perhaps someone else has had the same thing happen and found a way to fix it.

Link to comment
Share on other sites

  • 0

You need to insure that the file you are putting Duke's code in processes the command.

 

This is done via:

processInitCommands;

 

Example:

_vehicle_121= objNull;
if (true) then
{
  _this = createVehicle ["WarfareBunkerSign", [9919.52, 5422.02, 0.490173], [], 0, "CAN_COLLIDE"];
  _vehicle_121 = _this;
  _this setDir 288.201;
  _this setVehicleInit "this SetObjectTexture [0,""graphics\sandfordandson.jpg""]";
};

processInitCommands;

 

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...