Jump to content

Object's components, IFP file and non-download files


tatusmen

Recommended Posts

Hi everyone,

I have three problems:

1. I have a object's model which have a components. Component's names are the same as vehicle's components. This is: door_if_ok, door_if_dam, bonnet_dummy etc. I want to change rotation or position selected components but I can't. Functions: getVehicleComponents, setVehicleComponentRotation, setVehicleComponentPosition don't work with an object. It must be vehicle. But i don't want use the vehicle.

Look at screenshot:

utdu8FA.png

and here is error in debugscript:

mci8m7f.png

here is lua code:

  
local dff=engineLoadDFF("dummytest1.dff", 3426) 
engineReplaceModel(dff, 3426) 
  
local obj=createObject(3426,-2405.01,-597.54,134.70) 
  
addCommandHandler("comp", 
    function() 
        local getComponent = getVehicleComponents(obj) 
        for k in pairs (getComponent) do 
            local rx, ry, rz = getVehicleComponentRotation(obj, k) 
            setVehicleComponentRotation(obj, k, rx+10, ry+10, rz+10) 
        end 
    end 
) 

I exported it also as vehicle but both DFF files behave the same.

You can download dummytest1.dff from:

https://www.dropbox.com/s/bjg8i8kt05a3p ... 1.dff?dl=0

and help me. :)

2. Can in replace a IFP file? I know about this function https://wiki.multitheftauto.com/wiki/EngineLoadIFP

but it is disabled.

Do you know any other way to replace this file?

3. Can i add to server files .dff, .txd and other so that they don't download my users' disc? I want to secure my files but i can't when they download it to their computers...

I know that is some way but i don't know what i can do this. The CIT server have this funcion.

Please help me! :D

Thanks for help. :)

Link to comment

1. getVehicleComponents cannot get object's components. I don't know if there's such function as "getObjectComponents". Or it's not implemented yet.

2. IFP was disabled because it was bugging internal GTA animations.

3. To keep them from dirty hands and still use cache (so they don't download it every time they join), you can encrypt them with teaEncode and base64Encode and then decrypt them when they join and load them. If you really want to not have them downloaded to their computers, use cache attribute in meta (Really bad idea in my opinion as users will have to download 100 MB or so every time they join your server).

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...