Joystick controlled camera ingame

Joystick controlled camera ingame

Discuss Lua based Spring scripts (LuaUI widgets, mission scripts, gaia scripts, mod-rules scripts, scripted keybindings, etc...)

Moderator: Moderators

Post Reply
User avatar
Beherith
Moderator
Posts: 5045
Joined: 26 Oct 2007, 16:21

Joystick controlled camera ingame

Post by Beherith »

You can control the rotateable overhead (ctrl+F4) camera ingame with a little bit of helper crud around it(python script using pygame to query gamepad and forward it to a TCP server that game can connect to via LuaSockets):

https://github.com/Beherith/camera_joystick_springrts
User avatar
PicassoCT
Journeywar Developer & Mapper
Posts: 10385
Joined: 24 Jan 2006, 21:12

Re: Joystick controlled camera ingame

Post by PicassoCT »

Reminds me of the AR-Cam, i used a cellphone to controll the camera:

https://github.com/PicassoCT/Journeywar ... _arCam.lua

Needed a modfied version of engine to work:
https://github.com/PicassoCT/spring/com ... 2ace9b167e


You could move the spring camera with a cellphone. Never worked out how to drop the frame of the spring world though, so you could vid-stream spring to the device and have spring as a tabletop. Good times.

So you now can control spring cam via joystick.. now it needs a virtual joystick. center of screen. and the players head as the joystick. Seasick madness ensues..
User avatar
Beherith
Moderator
Posts: 5045
Joined: 26 Oct 2007, 16:21

Re: Joystick controlled camera ingame

Post by Beherith »

User avatar
PicassoCT
Journeywar Developer & Mapper
Posts: 10385
Joined: 24 Jan 2006, 21:12

Re: Joystick controlled camera ingame

Post by PicassoCT »

Looks awesome, like drone-cam footage. All you need now is replays and a "heavy battle fast-forwarder" and you got a CC Generals like main screen..
User avatar
Beherith
Moderator
Posts: 5045
Joined: 26 Oct 2007, 16:21

Re: Joystick controlled camera ingame

Post by Beherith »

Ive toyed with that idea, but the loadtime overhead is too much ( youdont need to fast forward replay anyway :)
Post Reply

Return to “Lua Scripts”