New controller

Place to ask discuss and request the modding support of Factorio. Don't request mods here.
Post Reply
yagaodirac
Fast Inserter
Fast Inserter
Posts: 152
Joined: Sun Jun 16, 2019 4:04 pm
Contact:

New controller

Post by yagaodirac »

I work on a mod recently. I need to make a new kind of controller. When player press wasd, the character should move around in the scene, but I want the viewport to stay. When player presses some key, say spacebar, the viewport aligns with the character. With the api available now, I have to combine a character entity with a god mod controller in code.
This kind of controller benefits some specific mode. It works way better when player needs to dodge any moving object.

User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12888
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: New controller

Post by ssilk »

moved from suggestions to modding requests— ssilk
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...

yagaodirac
Fast Inserter
Fast Inserter
Posts: 152
Joined: Sun Jun 16, 2019 4:04 pm
Contact:

Re: New controller

Post by yagaodirac »

ssilk wrote:
Sun Nov 29, 2020 8:20 am
moved from suggestions to modding requests— ssilk
Thanks. If this feature finally added, it would probably help with the bullet-hell-game mode for the modders.

User avatar
eradicator
Smart Inserter
Smart Inserter
Posts: 5206
Joined: Tue Jul 12, 2016 9:03 am
Contact:

Re: New controller

Post by eradicator »

In the mean time you could also try using a full-screen camera gui element with the default controller.
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.

yagaodirac
Fast Inserter
Fast Inserter
Posts: 152
Joined: Sun Jun 16, 2019 4:04 pm
Contact:

Re: New controller

Post by yagaodirac »

eradicator wrote:
Tue Dec 01, 2020 12:52 am
In the mean time you could also try using a full-screen camera gui element with the default controller.
But, in this way, it is possible to keep more ui as what we see in general cases?
My plan is that a god mod controller, a separated character entity, and they work together via lua. But I need one more short cut to move the view port. Which might occupy one short cut for items, and I have to code for it.

User avatar
eradicator
Smart Inserter
Smart Inserter
Posts: 5206
Joined: Tue Jul 12, 2016 9:03 am
Contact:

Re: New controller

Post by eradicator »

yagaodirac wrote:
Tue Dec 01, 2020 2:15 am
But, in this way, it is possible to keep more ui as what we see in general cases?
Overlapping guis are always difficult. Making the cam not full-screen but a bit smaller might work.
yagaodirac wrote:
Sun Nov 29, 2020 7:02 am
I have to combine a character entity with a god mod controller in code.
It's just that from my experience using LuaEntity.walking_state doesn't really work in multiplayer due to lag hiding mechanisms - if you are indeed using walking_state.
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.

yagaodirac
Fast Inserter
Fast Inserter
Posts: 152
Joined: Sun Jun 16, 2019 4:04 pm
Contact:

Re: New controller

Post by yagaodirac »

eradicator wrote:
Tue Dec 01, 2020 1:30 pm
yagaodirac wrote:
Tue Dec 01, 2020 2:15 am
But, in this way, it is possible to keep more ui as what we see in general cases?
Overlapping guis are always difficult. Making the cam not full-screen but a bit smaller might work.
yagaodirac wrote:
Sun Nov 29, 2020 7:02 am
I have to combine a character entity with a god mod controller in code.
It's just that from my experience using LuaEntity.walking_state doesn't really work in multiplayer due to lag hiding mechanisms - if you are indeed using walking_state.
Thanks. I didn't start with this part yet. I'm gonna try it out. Actually I don't mean to make something look like factorio, maybe I would do entity.teleport or something without animation in order to make multiple looks for players to choose from. Don't know if that works well.

Post Reply

Return to “Modding interface requests”