Skip to content

Commit 046b51f

Browse files
authored
[3D First person] Add a camera icon and tweak speeds (#534)
* Don't show in changelog
1 parent ae0d401 commit 046b51f

File tree

2 files changed

+33
-31
lines changed

2 files changed

+33
-31
lines changed

examples/3d-first-person/3d-first-person.json

Lines changed: 33 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -404,6 +404,15 @@
404404
"identifier": "https://asset-resources.gdevelop.io/public-resources/Multitouch joysticks/13d8225be69d0f11b6de965cac0d840e7e63e2510a638af89ae42b052caa2460_Shaded dark joystick thumb.png",
405405
"name": "Shaded dark joystick thumb.png"
406406
}
407+
},
408+
{
409+
"alwaysLoaded": false,
410+
"file": "Camera.png",
411+
"kind": "image",
412+
"metadata": "",
413+
"name": "Camera.png",
414+
"smoothed": true,
415+
"userAdded": true
407416
}
408417
],
409418
"resourceFolders": []
@@ -476,20 +485,20 @@
476485
],
477486
"instances": [
478487
{
479-
"angle": 180,
488+
"angle": 202,
480489
"customSize": true,
481-
"height": 20,
490+
"height": 40,
482491
"layer": "",
483492
"name": "Camera",
484493
"persistentUuid": "b47b3320-fbbb-473d-8e2a-9eb5497c56f0",
485-
"width": 20,
494+
"width": 40,
486495
"x": 475,
487-
"y": 301,
496+
"y": 325,
488497
"zOrder": 2,
489498
"numberProperties": [
490499
{
491500
"name": "depth",
492-
"value": 0
501+
"value": 1
493502
},
494503
{
495504
"name": "z",
@@ -1022,14 +1031,14 @@
10221031
"depth": 100,
10231032
"enableTextureTransparency": false,
10241033
"facesOrientation": "Y",
1025-
"frontFaceResourceName": "",
1034+
"frontFaceResourceName": "Camera.png",
10261035
"backFaceResourceName": "",
10271036
"backFaceUpThroughWhichAxisRotation": "X",
10281037
"leftFaceResourceName": "",
10291038
"rightFaceResourceName": "",
10301039
"topFaceResourceName": "",
10311040
"bottomFaceResourceName": "",
1032-
"frontFaceVisible": false,
1041+
"frontFaceVisible": true,
10331042
"backFaceVisible": false,
10341043
"leftFaceVisible": false,
10351044
"rightFaceVisible": false,
@@ -1295,8 +1304,7 @@
12951304
"textG": 0,
12961305
"textR": 0
12971306
},
1298-
"comment": "Camera object rotates along with the player's cursor, and the in game camera rotates based on the position of the Camera object",
1299-
"comment2": ""
1307+
"comment": "Camera object rotates along with the player's cursor, and the in game camera rotates based on the position of the Camera object"
13001308
},
13011309
{
13021310
"type": "BuiltinCommonInstructions::Standard",
@@ -1402,7 +1410,7 @@
14021410
"parameters": [
14031411
"Camera",
14041412
"+",
1405-
"LookJoystick.StickForceX()"
1413+
"LookJoystick.StickForceX() * 4"
14061414
]
14071415
},
14081416
{
@@ -1412,7 +1420,7 @@
14121420
"parameters": [
14131421
"Camera",
14141422
"+",
1415-
"LookJoystick.StickForceY()"
1423+
"LookJoystick.StickForceY() * 2"
14161424
]
14171425
}
14181426
]
@@ -1439,7 +1447,7 @@
14391447
"parameters": [
14401448
"Camera",
14411449
"+",
1442-
"Gamepads::StickForceX(1, \"Right\")"
1450+
"Gamepads::StickForceX(1, \"Right\") * 4"
14431451
]
14441452
},
14451453
{
@@ -1449,7 +1457,7 @@
14491457
"parameters": [
14501458
"Camera",
14511459
"+",
1452-
"Gamepads::StickForceY(1, \"Right\")"
1460+
"Gamepads::StickForceY(1, \"Right\") * 2"
14531461
]
14541462
}
14551463
]
@@ -1464,8 +1472,7 @@
14641472
"textG": 0,
14651473
"textR": 0
14661474
},
1467-
"comment": "Make sure the camera doesn't get upsidedown.",
1468-
"comment2": ""
1475+
"comment": "Make sure the camera doesn't get upsidedown."
14691476
},
14701477
{
14711478
"type": "BuiltinCommonInstructions::Standard",
@@ -1522,8 +1529,7 @@
15221529
"textG": 0,
15231530
"textR": 0
15241531
},
1525-
"comment": "To allow player to walk under an object, it needs to be neglected from picking when separating from obstacles",
1526-
"comment2": ""
1532+
"comment": "To allow player to walk under an object, it needs to be neglected from picking when separating from obstacles"
15271533
},
15281534
{
15291535
"type": "BuiltinCommonInstructions::Standard",
@@ -1562,8 +1568,7 @@
15621568
"textG": 0,
15631569
"textR": 0
15641570
},
1565-
"comment": "Moving the Camera object along the X/Y plane with forces",
1566-
"comment2": ""
1571+
"comment": "Moving the Camera object along the X/Y plane with forces"
15671572
},
15681573
{
15691574
"type": "BuiltinCommonInstructions::Standard",
@@ -1599,7 +1604,7 @@
15991604
"parameters": [
16001605
"Camera",
16011606
"Camera.Angle()",
1602-
"200",
1607+
"400",
16031608
""
16041609
]
16051610
}
@@ -1626,7 +1631,7 @@
16261631
"parameters": [
16271632
"Camera",
16281633
"Camera.Angle()+180",
1629-
"200",
1634+
"400",
16301635
""
16311636
]
16321637
}
@@ -1653,7 +1658,7 @@
16531658
"parameters": [
16541659
"Camera",
16551660
"Camera.Angle() + 90",
1656-
"200",
1661+
"400",
16571662
""
16581663
]
16591664
}
@@ -1680,7 +1685,7 @@
16801685
"parameters": [
16811686
"Camera",
16821687
"Camera.Angle() - 90",
1683-
"200",
1688+
"400",
16841689
""
16851690
]
16861691
}
@@ -1715,7 +1720,7 @@
17151720
"parameters": [
17161721
"Camera",
17171722
"WalkJoystick.StickAngle() + Camera.Angle() + 90",
1718-
"200",
1723+
"400",
17191724
""
17201725
]
17211726
}
@@ -1756,7 +1761,7 @@
17561761
"parameters": [
17571762
"Camera",
17581763
"Gamepads::StickAngle(1, \"Left\") + Camera.Angle() + 90",
1759-
"200",
1764+
"400",
17601765
""
17611766
]
17621767
}
@@ -6371,8 +6376,7 @@
63716376
"textG": 0,
63726377
"textR": 0
63736378
},
6374-
"comment": "Make sure the joystick has moved from center",
6375-
"comment2": ""
6379+
"comment": "Make sure the joystick has moved from center"
63766380
},
63776381
{
63786382
"type": "BuiltinCommonInstructions::Standard",
@@ -6452,8 +6456,7 @@
64526456
"textG": 0,
64536457
"textR": 0
64546458
},
6455-
"comment": "Make sure the joystick has moved from center",
6456-
"comment2": ""
6459+
"comment": "Make sure the joystick has moved from center"
64576460
},
64586461
{
64596462
"type": "BuiltinCommonInstructions::Standard",
@@ -7085,8 +7088,7 @@
70857088
"textG": 0,
70867089
"textR": 0
70877090
},
7088-
"comment": "Move thumb back to center when not being pressed (acts like a spring on a real controller)",
7089-
"comment2": ""
7091+
"comment": "Move thumb back to center when not being pressed (acts like a spring on a real controller)"
70907092
},
70917093
{
70927094
"type": "BuiltinCommonInstructions::Standard",

examples/3d-first-person/Camera.png

408 Bytes
Loading

0 commit comments

Comments
 (0)