Mobile::cellCamActivate: Difference between revisions
(yay) |
MrPancakers (talk | contribs) No edit summary |
||
| (One intermediate revision by one other user not shown) | |||
| Line 1: | Line 1: | ||
{{ClientsideJsFunction}} | |||
Enables the camera view from your phone | |||
'''NOTE:''' This does not enable taking photos, this is only the VIEW. | |||
==Syntax== | ==Syntax== | ||
< | <pre>mp.game.mobile.cellCamActivate(enable, p1);</pre> | ||
=== Required Arguments === | === Required Arguments === | ||
*''' | *'''enable:''' {{RageType|Boolean}} | ||
*'''p1:''' Boolean | *'''p1:''' {{RageType|Boolean}} | ||
===Return value=== | ===Return value=== | ||
*'''Undefined''' | *'''Undefined''' | ||
==Example== | ==Example== | ||
< | Up arrow to enable the camera, down arrow to disable the camera | ||
{{ClientsideCode| | |||
</ | <pre> | ||
mp.keys.bind(0x28, true, function() { // Down Arrow | |||
mp.game.mobile.cellCamActivate(false, false); | |||
}); | |||
mp.keys.bind(0x26, true, function() { // Up Arrow | |||
mp.game.mobile.cellCamActivate(true, true); | |||
}); | |||
</pre> | |||
}} | |||
==See also== | ==See also== | ||
{{ | {{Mobile_s_function_c}} | ||
[[Category:Clientside API]] | [[Category:Clientside API]] | ||
[[Category: | [[Category:Mobile API]] | ||
Latest revision as of 00:21, 23 January 2019
Client-Side Function
Enables the camera view from your phone
NOTE: This does not enable taking photos, this is only the VIEW.
Syntax
mp.game.mobile.cellCamActivate(enable, p1);
Required Arguments
- enable: Boolean
- p1: Boolean
Return value
- Undefined
Example
Up arrow to enable the camera, down arrow to disable the camera
Client-Side
mp.keys.bind(0x28, true, function() { // Down Arrow
mp.game.mobile.cellCamActivate(false, false);
});
mp.keys.bind(0x26, true, function() { // Up Arrow
mp.game.mobile.cellCamActivate(true, true);
});
See also
- mp.game.mobile.cellCamActivate
- mp.game.mobile.createMobilePhone
- mp.game.mobile.getMobilePhonePosition
- mp.game.mobile.getMobilePhoneRenderId
- mp.game.mobile.getMobilePhoneRotation
- mp.game.mobile.moveFinger
- mp.game.mobile.scriptIsMovingMobilePhoneOffscreen
- mp.game.mobile.setMobilePhonePosition
- mp.game.mobile.setMobilePhoneRotation
- mp.game.mobile.setMobilePhoneScale
- mp.game.mobile.setPhoneLean