playMaker

Author Topic: playmaker+photon  (Read 1811 times)

drakwon

  • Playmaker Newbie
  • *
  • Posts: 34
playmaker+photon
« on: April 24, 2016, 11:53:34 PM »
hi im pretty new to unity playmaker and photon, im trying to activate a game object over a network but am not sure how to go about that, any help thanks

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: playmaker+photon
« Reply #1 on: April 25, 2016, 01:22:43 AM »
Hi,

You'll need to send an RPC event using the action :

PhotonViewRpcBroadcastFsmEvent
or
PhotonViewRpcBroadcastFsmEventToPlayer

But I would strongly recommand you first learn about the basics via the wiki with the fully documented example:

https://hutonggames.fogbugz.com/default.asp?W927

Study how the chat system was created and you'll see that you apply the same technic to send event across the network around very easily.

Bye,

 Jean


drakwon

  • Playmaker Newbie
  • *
  • Posts: 34
Re: playmaker+photon
« Reply #2 on: April 25, 2016, 10:19:20 AM »
thanks for your reply, I have read through and looked at the example, but im still unsure how i would set it up to activate a particle effect, Not sure what I send the event to or how i should build the rest of the fsm after setting up the rpc

edit, to be more specific im trying to enable a flame particle effect during an ability
« Last Edit: April 25, 2016, 10:35:57 AM by drakwon »

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: playmaker+photon
« Reply #3 on: May 06, 2016, 01:57:01 AM »
Hi,

Study how I created the Chat system, it's purely about sending a event across the network, you can define who's catching the event,

so in the case of your particle, create a similar system based on the chat logic and instead of sending a text, send some information about the effect itself

So, the key is to understand the chat system and understand that this is actually totally generic and can be used to communicate between components of your game, not necessarly for players to communicate.

bye,

 Jean