[How-to] Stream addon props


#1

You need OpenIV, nodejs, npm and this tool :

npm install -g ymap-utils

If you installed it at the time I written my previous tutorial [How-to] Load YMAP inside interior you have to update it to 2.1.1

npm update -g

Create a props folder inside resources then add start props in your server.cfg.
Create a stream folder inside props and a file named __resource.lua with this content :

resource_manifest_version "44febabe-d386-4d18-afbe-5e627f4af937"

data_file 'DLC_ITYP_REQUEST' 'stream/props.ytyp'

Add your props and texures to the stream folder.

If you have a file named the_prop.ydr rename its texture to the_prop.ytd, this is important, ydr and ytd must have the same file name before extension so we can automate the process.

Using four favorite file explorer, grab the full path to the stream\props folder, for me this is C:\Users\NGD\Desktop\fxserver\resources\props

now open a command prompt and type :

ytyp --genprops --directory "C:\Users\NGD\Desktop\fxserver\resources\props\stream"

The program generate a file named props.ytyp.xml

Put OpenIV in Edit Mode and drop the file in it, then drop it back to the stream folder, now you have props.ytyp

You can now spawn the object

  • With your favorite map editor
  • Using CreateObject
  • Using ESX : /spawnobject the_prop

Streaming Addon Props
#2

Very Nice Tutorial! Thanks, GiZz


#3

Tutorial rewritten as it was not working properly with previous method.


#4

Thanks for the Tuto GiZz!


#5

would u happen to have a tutorial to addon peds by chance?


#6

How does this work? I cant seem to continue “ytyp --genprops --directory “D:\FiveMServer\resources\props\stream”” on that code. It doesnt create any props.ytyp.xml? =/

NVM It sent the File to another location? :o But getting another error when putting the file in OpenIV = “Failed to initialize Direct3D”


#7

@GiZz Can you confirm this is still working on latest versions because I have not been able to accomplish it as of late.


Streaming Props for YMAP
#8

Thx very much for this tutorial, and if you have an .yft there is a way to do the same?
I tried to change “yft” to “ydr” , do the same process and the model spawn but when I touch it the model go under the ground. Do you know how to do properly or how to fix that? Thx


#9

When I did this method, the addon-props on the map are invisible, meaning you can walk on them but can’t see them. How can I fix this? Also all the files in my stream folder are .ydr files.


#10

Do you need to have ytd files? I have had no luck trying to get this to work.


#11

If you cant find the props.ytyp.xml use the search feature in File Explorer because it may be located somewhere else