View Issue Details

IDProjectCategoryView StatusLast Update
0009791Multi Theft Auto : San Andreaspublic2018-01-12 08:51
ReporterJokersajtAssigned To 
PrioritylowSeverityminorReproducibilityalways
Status confirmedResolutionopen 
PlatformWindowsOS10 x64OS Version?
Product Version 
Target VersionConfirmed IssuesFixed in Version 
Summary0009791: triggerServerEvent breaks with oop vector
Description

When triggerserverevent has oop argument such as Vector or Matrix then triggerServerEvent doesn't run and don't send any error.

Example:
pos = localPlayer:getPosition() (Or Vector3(getElementPosition(localPlayer))
triggerServerEvent("Player->Spawn", localPlayer, localPlayer, pos)
No error, no run.
When i change the pos argument in triggerServerEvent to x,y,z the TriggerServerEvent works.

Example:
triggerServerEvent("Player->Spawn", localPlayer, localPlayer, pos.x, pos.y, pos.z)

TagsNo tags attached.

Activities

Bonus1702

2017-12-26 00:13

viewer   ~~0026369

"You can pass any lua data type (except functions). You can also pass elements."
I think "pos" is neither a lua data type nor an element.

Well, should still output an error or a warning.

thisdp

2018-01-01 09:43

viewer   ~~0026374

triggerServerEvent doesn't work well with vector

arranTuna

2018-01-03 17:22

manager   ~~0026383

Executing client-side command: pos = localPlayer:getPosition()
Executing client-side command: triggerServerEvent("Player->Spawn", localPlayer, localPlayer, pos)
Command results: false [boolean]

AlexTMjugador

2018-01-11 17:00

viewer   ~~0026391

As a workaround, you can use the example in this Wiki page to transfer vectors safely in triggerServer/ClientEvent: https://wiki.multitheftauto.com/wiki/GetUserdataType#Example

Inspirator

2018-01-12 08:51

viewer   ~~0026392

Same for any object. I really hope they will add support for it.

Issue History

Date Modified Username Field Change