The Photon Forum
is Closed Permanently.

After many dedicated years of service, we have made the decision to retire our Forum and switch to read-only: we´ve saved the best to last! Your search result can be found below. Plus, we offer support via these channels:

Try Our

Please check if you can find an answer in our extensive documentation on Fusion.

Join Us
on Discord

Meet and talk to our staff and the entire Photon-Community via Discord.

Stack Overflow

Find more information on Stack Overflow (for Circle members only).

Write Us
an E-Mail

Feel free to send your question directly to our developers.

Using Input System with Fusion

2021-10-19 09:11:43

Basically it should be possible to use the Input System from Unity with Fusion without much to worry about but i can't figure out how.

In this example i use the Fusion 102 Approach but want to switch this with the Input System.

In the Fusion 102 BasicSpawner the Input is managed like this:

In my old project i used the input system like this:

And Added it in the old project to my Player Prefab so i could use it in the script like this:

Just using OnMove, OnShoot, etc etc to geht the Player Moving.

So i assumed i had to get the information out ouf moveVal into OnInput. But i don't know how.

It is important that the movable Object acts correctly in the network.


2021-10-20 11:21:13

Fusion does not really mind the input system you use. With the new one, yes, you want to register key-presses and use them OnInput() to get them networked. How that's done is up to your project, which we don't know.

2021-10-21 09:41:19

in this case i get a vector 2, everytime the players presses (W,A,S,D)

yes its more of a transfer problem in this case. I know that it is doable but i couldn't find anyone using the input system with Fusion so i used the older system for the time beeing.

its just that can't figure out how to get it basically like this:

Because in the example of the Fusion 102 tutorial i get one value for every key i press while here i trigger the function OnMove when one of the key is pressed and have to get that information correctly connected to OnInput.

2022-10-15 17:22:47

I think this is a bit late but in case someone else Is wondering about the same thing, Now the documentation is having specific section for that for the input as whole and specifically for unity new Input system.

2022-12-20 14:55:28

Hi there,

I also tried to use the new input system and followed the tutorial that Gameaning Studio recommended:

This tutorial uses the script PlayerActionMap which is not included in the photon fusion sdk anymore. I would like to know what to use instead?

I tried to instanciate the input Actions of unity instead. By using

PlayerInputActions _inputActions = new PlayerInputAction()

And set my movement values with

public void OnInput(NetworkRunner runner, NetworkInput input)



My NetworkInputData looks like this:

public struct NetworkInputData : INetworkInput



This is working but only very very slow and the player movement is extremly laggy.

Is it possible to use the new input system with photon fusion?

Back to top