mtasa-blue icon indicating copy to clipboard operation
mtasa-blue copied to clipboard

Add setElementCollidableWith server-side

Open Proxy-99 opened this issue 9 months ago • 3 comments

#3681

test code

vehicle1 = createVehicle ( 411, 2044.65942, 1526.35352, 10.67188)
object = createObject( 3578, 2044.40405, 1510.24036, 10.67188)

setTimer(function()
  res = setElementCollidableWith(vehicle1,object,false)
  print(res)
end, 2000, 1)

Proxy-99 avatar Mar 14 '25 09:03 Proxy-99

The function doesn't work for a new connected players and after reconnect

TheNormalnij avatar Mar 14 '25 11:03 TheNormalnij

The function doesn't work for a new connected players and after reconnect

What packet file should I write the info? is it Server\mods\deathmatch\logic\packets\CPlayerJoinCompletePacket.cpp

Proxy-99 avatar Mar 18 '25 14:03 Proxy-99

The function doesn't work for a new connected players and after reconnect

What packet file should I write the info? is it Server\mods\deathmatch\logic\packets\CPlayerJoinCompletePacket.cpp

I think you should store informations on the server side and then send it in the CMapInfoPacket. Check how it's done, for example, with setJetpackWeaponEnabled (CGame::SetJetpackWeaponEnabled & CGame::GetJetpackWeaponEnabled)

FileEX avatar Mar 18 '25 15:03 FileEX