Project:
RSS

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0009500Multi Theft Auto : San AndreasScriptingpublic2016-12-20 09:462016-12-21 05:43
ReporterAfterAll14 
Assigned Toccw 
PrioritynormalSeverityminorReproducibilityalways
StatusresolvedResolutionfixed 
PlatformMTA:SAOSwindowsOS Version7
Product Version1.5.3 
Target Version1.5.4Fixed in Version1.5.4 
Summary0009500: attachElements doesn't work for camera in non-zero dimensions
DescriptionattachElements(getCamera(), someVehicle, x, y, z) returns "false" in any dimension except 0.
Steps To ReproduceYou can reproduce it using runcode:
1. SERVERSIDE
me=getPlayerFromName("your name")
vehicle=getPedOccupiedVehicle(me)
setElementDimension(me, 1)
setElementDimension(vehicle, 1)
2. CLIENTSIDE
vehicle=getPedOccupiedVehicle(localPlayer)
success=attachElements(getCamera(), vehicle, 0, -10, 1) --> return false
Additional InformationattachElements is the only way to make properly-working custom cameras for vehicles. (setCameraMatrix and setElementMatrix will result in camera flickering).
I personally need this to make cameras for the new vehicle physics I'm working on atm (cause standart camera behavior is bugged when I replace car physics).
New physics:
https://www.youtube.com/watch?v=39dTwzF11qY [^]
Camera bug:
https://www.youtube.com/watch?v=jIp0RjDiueg [^]
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0025512)
arranTuna (manager)
2016-12-20 17:12

I tried it and it returned false, then I tried it in dimension 0 and it also returned false.

I then tried localPlayer instead of vehicle in attachElements and it works, is this actually a feature request to make camera attachable to a vehicle?
(0025520)
StifflersMom (viewer)
2016-12-20 23:13

v1.5.3-release-10966
Executing client-side command: test=getPedOccupiedVehicle(localPlayer)
Command executed!
Executing client-side command: attachElements(getCamera(),test,0,10,1)
Command results: true [boolean]

It works in dimension 0 as described by AfterAll14
If it works in dimension 0, it *should* work in every dimension :)
(0025522)
AfterAll14 (viewer)
2016-12-21 01:19

arranTuna, make sure you follow steps I described in "Steps to reproduce". You have to set dimensions server-side only, cause setting it client-side causes some bugs. I wasn't able to attach camera to localPlayer by doing it in correct order.
As for you question - I just want to be able attach camera to vehicle (and any other element) in non-zero dimensions. Idk if this missing feature or a bug.
(0025523)
ccw (administrator)
2016-12-21 01:34

Fixed in https://github.com/multitheftauto/mtasa-blue/commit/b04291b8c7a0caa937efbd9fda70843b91dcaab8 [^]
(0025524)
AfterAll14 (viewer)
2016-12-21 05:43

Nice, thanks!

- Issue History
Date Modified Username Field Change
2016-12-20 09:46 AfterAll14 New Issue
2016-12-20 17:12 arranTuna Note Added: 0025512
2016-12-20 17:12 arranTuna Status new => feedback
2016-12-20 23:13 StifflersMom Note Added: 0025520
2016-12-21 01:19 AfterAll14 Note Added: 0025522
2016-12-21 01:19 AfterAll14 Status feedback => new
2016-12-21 01:34 ccw Note Added: 0025523
2016-12-21 01:34 ccw Status new => resolved
2016-12-21 01:34 ccw Resolution open => fixed
2016-12-21 01:34 ccw Assigned To => ccw
2016-12-21 01:34 ccw Project New issues => Multi Theft Auto : San Andreas
2016-12-21 01:35 ccw Product Version => 1.5.3
2016-12-21 01:35 ccw Fixed in Version => 1.5.4
2016-12-21 01:35 ccw Target Version => 1.5.4
2016-12-21 05:43 AfterAll14 Note Added: 0025524


Copyright © 2000 - 2017 MantisBT Team
Powered by Mantis Bugtracker