SA-MP Forums Archive
Model Collision - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP DL Edition (https://sampforum.blast.hk/forumdisplay.php?fid=92)
+--- Forum: SA-MP 0.3.DL (https://sampforum.blast.hk/forumdisplay.php?fid=90)
+--- Thread: Model Collision (/showthread.php?tid=650673)



Model Collision - Max_Andolini - 04.03.2018

Guys I am trying conversion gta sa to samp map but i need a collision extractor?

I would be glad if you can help with information.


Re: Model Collision - NaS - 04.03.2018

https://sampforum.blast.hk/showthread.php?tid=644075

Use KDFF to generate a SAMP col from the objects (if they don't have a seperate .col file already), then use it again to attach them to the Models.

The usage should be explained in the thread


Re: Model Collision - Max_Andolini - 04.03.2018

Quote:
Originally Posted by NaS
Посмотреть сообщение
https://sampforum.blast.hk/showthread.php?tid=644075

Use KDFF to generate a SAMP col from the objects (if they don't have a seperate .col file already), then use it again to attach them to the Models.

The usage should be explained in the thread
Empty box mesh faces. what is difference?

And how to make coll with kdff.exe 2k files dff


Re: Model Collision - Sew_Sumi - 04.03.2018

Quote:
Originally Posted by Max_Andolini
Посмотреть сообщение
And how to make coll with kdff.exe 2k files dff
batch files work wonders. xD (If it allows command line options)


Re: Model Collision - Kasis - 04.03.2018

Quote:
Originally Posted by Max_Andolini
Посмотреть сообщение
Empty box mesh faces. what is difference?

And how to make coll with kdff.exe 2k files dff
you have to use kdff.exe tho i dont know cmd lines for it. Also you have to use mesh faces when generating coll's. Anyways there should be thread about cmds in kdff.exe somewhere around lol i just couldnt find it


Re: Model Collision - Max_Andolini - 04.03.2018

Quote:
Originally Posted by Kasis
Посмотреть сообщение
you have to use kdff.exe tho i dont know cmd lines for it. Also you have to use mesh faces when generating coll's. Anyways there should be thread about cmds in kdff.exe somewhere around lol i just couldnt find it
I tried this code but it did not.

kdff -g mesh

I want to make coll all files sane time.


Re: Model Collision - Sew_Sumi - 04.03.2018

Seems like https://sampforum.blast.hk/showthread.php?tid=647421 has more info maybe... I just found it by searching for "kdff command line", and it may help out a bit in some way.


Re: Model Collision - Max_Andolini - 05.03.2018

Quote:
Originally Posted by Sew_Sumi
Посмотреть сообщение
Seems like https://sampforum.blast.hk/showthread.php?tid=647421 has more info maybe... I just found it by searching for "kdff command line", and it may help out a bit in some way.
I tried this code but it did not.

kdff -g mesh

I want to make coll all files sane time.


Re: Model Collision - Sew_Sumi - 05.03.2018

Код:
[usage] Modes: -i (info) -a (append col) -p (process all) -v (night vertex)
[usage] Modes: -g [mode] (generate col for dff) -g modes: empty, box, mesh
[usage] Input: -d [dff file] -c [collision file] (col ver3) -o [output file]
[usage] Example (append col to dff):  kdff.exe -a -d MyHouse.dff -c MyHouse.col -o MyHouseC.dff
[usage] Example (show info for dff):  kdff.exe -i -d MyHouse.dff
[usage] Example (generate empty col): kdff.exe -g empty -d MyHouse.dff -o MyHouse.col
[usage] Example (import NVC from -n): kdff.exe -v -d MyHouseDT.dff -n MyHouseNT.dff -o MyHouseNVC.dff
[usage] Example (all in current dir): kdff.exe -p (process *.dff in cwd and attach *.col)
I think you need

Код:
kdff -g mesh -d Example.dff -o Example.col
?

And from there, you'd simply make a batch file.


Re: Model Collision - Max_Andolini - 05.03.2018

Quote:
Originally Posted by Sew_Sumi
Посмотреть сообщение
Код:
[usage] Modes: -i (info) -a (append col) -p (process all) -v (night vertex)
[usage] Modes: -g [mode] (generate col for dff) -g modes: empty, box, mesh
[usage] Input: -d [dff file] -c [collision file] (col ver3) -o [output file]
[usage] Example (append col to dff):  kdff.exe -a -d MyHouse.dff -c MyHouse.col -o MyHouseC.dff
[usage] Example (show info for dff):  kdff.exe -i -d MyHouse.dff
[usage] Example (generate empty col): kdff.exe -g empty -d MyHouse.dff -o MyHouse.col
[usage] Example (import NVC from -n): kdff.exe -v -d MyHouseDT.dff -n MyHouseNT.dff -o MyHouseNVC.dff
[usage] Example (all in current dir): kdff.exe -p (process *.dff in cwd and attach *.col)
I think you need

Код:
kdff -g mesh -d Example.dff -o Example.col
?

And from there, you'd simply make a batch file.
I need one command and all files 3k files generate coll


Re: Model Collision - NaS - 05.03.2018

Quote:
Originally Posted by Max_Andolini
Посмотреть сообщение
I need one command and all files 3k files generate coll
Quote:

Console option -p will scan all *.dff files in the current directory and attach the *.col with the same name.

Or, to generate the col files you need to use a BAT file.

Код:
@ECHO OFF

(for %%f in (*.dff) do (
	echo kdff.exe -g mesh -d %%~nf.dff -o col\%%~nf.col
	echo kdff.exe -a -d %%~nf.dff -c col\%%~nf.col -o gen\%%~nf.dff

)
echo pause
) > !run_kdff.bat
Create 2 subfolders called "gen" and "col", the .col files will be placed in the col folder and the final models in the gen folder.

This BAT file generates another BAT file for

- Generating .col file for all DFFs in its directory in MESH mode
- Attaching the new col files to the model

However you should see for which Models there are .col files already, if it exists it's better than the generated one (KDFF generates a collision for all vertices, even plants and bushes, that's why the original collision is better).
For all other models this should work well.


Re: Model Collision - SoNic94 - 05.03.2018

make col for 3k files? or you can just attach all this objects(if they have small mesh, this is props?) in 3ds max and use 1 dff file