playMaker

Author Topic: PUN FPS Sample  (Read 4413 times)

Meka Games

  • Junior Playmaker
  • **
  • Posts: 61
PUN FPS Sample
« on: December 14, 2020, 03:52:00 PM »
Hello,

I had no experience with multiplayer before. I really want to learn now.  I'm trying to do it myself but haven't made any progress.  :(

Can anyone make a sample demo scene for me? I just want to see 2 players shooting each other with guns using raycasts. I'm using free pun classic

I would be very glad if anyone could help.

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7623
    • jinxtergames
Re: PUN FPS Sample
« Reply #1 on: December 16, 2020, 05:34:27 AM »
Hi.
I have no experience yet with pun.

But i believe that there are some tutorials on youtube.

also you can find a Demo on the Ecosystem (search 'Pun')

Meka Games

  • Junior Playmaker
  • **
  • Posts: 61
Re: PUN FPS Sample
« Reply #2 on: December 16, 2020, 05:36:38 AM »
Hi.
I have no experience yet with pun.

But i believe that there are some tutorials on youtube.

also you can find a Demo on the Ecosystem (search 'Pun')

This is not the thing I want.  :( I just want to see 2 players shooting each other with guns using raycasts. Thanks anyway.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15537
  • Official Playmaker Support
Re: PUN FPS Sample
« Reply #3 on: December 18, 2020, 01:21:23 AM »
Hi,

 these tutorials are key for you to acquire the necessary knowledge to achieve what you want.

 - can you already manage pun connection, create and manage room, player?

 once you master that, making the additional hit system requires:

- understanding fsm network variables ( covered in the tutorial)

when player A start firing, all your player A instances will start raycasting, on the player B owner instance ( when ismine is true), you will watch if you are being hit and deduce health to yourself, health will be a network variable, and all players adjust their respective hud to visualyze their health, using this network variable.

so it's critical that you go through the tutorial fully, because everything is covered for you to then implement this shooting feature.

Bye,

 Jean

Meka Games

  • Junior Playmaker
  • **
  • Posts: 61
Re: PUN FPS Sample
« Reply #4 on: December 21, 2020, 05:30:46 AM »
Hi,

 these tutorials are key for you to acquire the necessary knowledge to achieve what you want.

 - can you already manage pun connection, create and manage room, player?

 once you master that, making the additional hit system requires:

- understanding fsm network variables ( covered in the tutorial)

when player A start firing, all your player A instances will start raycasting, on the player B owner instance ( when ismine is true), you will watch if you are being hit and deduce health to yourself, health will be a network variable, and all players adjust their respective hud to visualyze their health, using this network variable.

so it's critical that you go through the tutorial fully, because everything is covered for you to then implement this shooting feature.

Bye,

 Jean

Thank you so much for your help. I can do create rooms, movement sync etc. But

Quote
when player A start firing, all your player A instances will start raycasting, on the player B owner instance ( when ismine is true), you will watch if you are being hit and deduce health to yourself, health will be a network variable, and all players adjust their respective hud to visualyze their health, using this network variable.
Can you create a demo scene for this? :(
When I try to do this, the characters get damaged 2 times. Or the character dies in Player A but continues to live in Player B. I am really confused.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15537
  • Official Playmaker Support
Re: PUN FPS Sample
« Reply #5 on: December 24, 2020, 02:22:49 AM »
Hi,

that means you are not far off.

I unfortunatly don't have time right now to do a sample, early january likely, so ping me then,

but meanwhile, it's likely because you don't handle autority properly, check the ismine property and only apply damage when "IsMine" is true, and let other instance of that player adjust the hud based on the health property that was changed by the owner ( when ismine is true).

Bye,

 Jean

Meka Games

  • Junior Playmaker
  • **
  • Posts: 61
Re: PUN FPS Sample
« Reply #6 on: January 01, 2021, 12:45:03 PM »
Hi,

that means you are not far off.

I unfortunatly don't have time right now to do a sample, early january likely, so ping me then,

but meanwhile, it's likely because you don't handle autority properly, check the ismine property and only apply damage when "IsMine" is true, and let other instance of that player adjust the hud based on the health property that was changed by the owner ( when ismine is true).

Bye,

 Jean

Still waiting. :P

Meka Games

  • Junior Playmaker
  • **
  • Posts: 61
Re: PUN FPS Sample
« Reply #7 on: January 19, 2021, 04:52:38 PM »
Bump. Can anyone help :(

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15537
  • Official Playmaker Support
Re: PUN FPS Sample
« Reply #8 on: January 20, 2021, 09:19:20 AM »
Hi,

 I'll see what I can do before the end of this week.

 Thanks for your patience, I need it, it's ectic at the moment.. I am sorry I can't allocate more time...

Bye,

 Jean

Meka Games

  • Junior Playmaker
  • **
  • Posts: 61
Re: PUN FPS Sample
« Reply #9 on: January 21, 2021, 12:08:13 PM »
Hi,

 I'll see what I can do before the end of this week.

 Thanks for your patience, I need it, it's ectic at the moment.. I am sorry I can't allocate more time...

Bye,

 Jean

Okay, thank you. If you give the example I want, I am sure I will understand everything.

RAVEN001

  • Junior Playmaker
  • **
  • Posts: 66
  • BANNED
Re: PUN FPS Sample
« Reply #10 on: January 22, 2021, 06:11:15 AM »
search "Romi Fauzi" on you tube, his accent is bad but his tut's are good, explains photon 1 in depth, upgrading to photon 2 isn't a big hassle once you know the basics.
BANNED

RAVEN001

  • Junior Playmaker
  • **
  • Posts: 66
  • BANNED
Re: PUN FPS Sample
« Reply #11 on: January 22, 2021, 06:23:01 AM »
Quote from: jeanfabre on January 20, 2021, 09:19:20 AM

Hi,
I'll see what I can do before the end of this week.
Thanks for your patience, I need it, it's ectic at the moment.. I am sorry I can't allocate more time...
Bye,
Jean

Okay, thank you. If you give the example I want, I am sure I will understand everything.

WOW, what exactly do you expect for 80USD??? Maybe jean fabre should just make games for you? There are certain aspects of the Unity API that YES playmaker need to take responsibility for, BUT TEACHING YOU NETWORKING???? No that isn't their responsibility.

Read above and subscribe, Romi Fauzi has done the leg work NOT expected of playmaker, so support him and leave jean fabre alone.
BANNED

RAVEN001

  • Junior Playmaker
  • **
  • Posts: 66
  • BANNED
Re: PUN FPS Sample
« Reply #12 on: January 22, 2021, 06:34:21 AM »
Ultimately what im trying to say here is that the PUN1 example scene only shows how to setup a room. If hutong published a full featured photon 2 example (perhaps with mirror playmaker actions), I'd pay money for that. By all means include all the photon actions you have painstakingly made for free, but A FULLY WORKING PROJECT bundled into an asset(using a dummy server), well i'd happily pay 80usd again.
« Last Edit: January 22, 2021, 06:36:13 AM by RAVEN001 »
BANNED

Meka Games

  • Junior Playmaker
  • **
  • Posts: 61
Re: PUN FPS Sample
« Reply #13 on: January 22, 2021, 08:31:18 AM »
Quote from: jeanfabre on January 20, 2021, 09:19:20 AM

Hi,
I'll see what I can do before the end of this week.
Thanks for your patience, I need it, it's ectic at the moment.. I am sorry I can't allocate more time...
Bye,
Jean

Okay, thank you. If you give the example I want, I am sure I will understand everything.

WOW, what exactly do you expect for 80USD??? Maybe jean fabre should just make games for you? There are certain aspects of the Unity API that YES playmaker need to take responsibility for, BUT TEACHING YOU NETWORKING???? No that isn't their responsibility.

Read above and subscribe, Romi Fauzi has done the leg work NOT expected of playmaker, so support him and leave jean fabre alone.

There is nothing that concerns you here. You can't speak for Jean Fabre. This is between him and me, and I just made a request from him. You have no idea what you are talking about. I don't want him to make games. I want to learn how to shoot using Raycast via server. This is what this place is for.

« Last Edit: January 22, 2021, 08:33:37 AM by haratman »

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15537
  • Official Playmaker Support
Re: PUN FPS Sample
« Reply #14 on: February 09, 2021, 01:08:08 AM »
Hi,

 It's ok :) don't worry guys. I sure would like to have more time to make more samples and cover some of these typical questions, but from experience, it seems indeed that it's the combination of both learning from docs ( unity, photon, playmaker) and samples that is the key. Extrapolation on features is what is difficult, so that one can look at a sample/doc and understand how to apply this in another case, that's the difficult part.


Indeed though, have you checked raumi's tutorials online, he covers exactly that, shooting with playmaker and pun:


his series is the most complete coverage of playmaker and pun, so I strongly suggest you go through that patiently. you will learn a lot.

meanwhile, just so you know. I have to update PUN 2 support for PlayMaker for end of this month, there will be a shooting demo with it.

Bye,

 Jean