Moving the Viking

I am trying to (massively) modify the Viking Demo to make my own demo, for trying to attract a little funding, mostly to afford to pay a developer for a bit. Im no coder..

I have 2 main tasks (apart from replace all the graphics with my own)
I think one is probably easy, and one is probably a bit huge..

1. Move the Vikings spawn point. I can of course move ALL my graphics + terrain around to get him in my required start position, but surely this must be an easy task. I notice that moving the Charprefab does not work, and he spawns the same place everytime.

(By the way, whats the point of a sneaky extra guy being spawned a little way away, probaly not seen in the original demo, as hes over the hills past the collidors... but why is here there, cos in MY demo, I find him standing lonely in a street!!!) I KNOW this was originally Unitys demo, but as my second question is DEFINITELY Photon related, I post this easy one here too.

2. More tricky this...
In my demo, I want to give the illusion of a MMO, not a chat-room, so I dont really want ALL the info on the menu page.
Name is OK.. I intend to re-instate the name on the head that is in the Unity versions, but weirdly missing from the Photon version.. is this on purpose--- anyway, not my question now...)

But the Create room / Join Room stuff. Here I would rather make 2 versions ONe that I would launch the same as now... and one where the Room name is hard coded and therfore missing. SO menu on this version would just be NAME field and JOIN button.

How can I do this.. Its surly just to remove the Create room functionality, and remove the Room list... just have the join button... Can someone "hand-hold" me thru this?

The plan for the demo, is eventually to do a fly thru animation with music and voiceover, finaly coming to rest on the character. (WoW homage.. ha ha) Title appears and you can Name him and join game. Don't know if I need to load a new Scene here, maybe to keep it separate and tidy. Then the character can move about, I will pop in on my own character and be able to take the user on a virtual tour ( or virtual sales pitch if you will) of the city in which my game is set.



  • Tobias
    1: The dude is spawned by PhotonNetwork.Instantiate. We pass in a position to spawn at and this happens to be the location of the scenes "Code" object. Exchange this! Create a array of positions as spawnpoints and use a randomly selected one. You can place empty game objects into the world. I'm not sure if that's "best practice" but for a demo surely ok.

    2: Names are not missing deliberately but somewhere in the process, they got kicked it seems. Should be no issue to add them again. Photon gives you names per player, if you set those in the first place.
    How you join a room without menu is described, e.g., in the Marco Polo Tutorial. This is a basic one to get you started with PUN in general and it has a clever way of not choosing any room which should fit.
    The tutorial code is also part of the PUN package but in PUN v1.14 it's not completely up to date and working out of the box.
    Better read it online and work through each step: ... 0Tutorials
  • Tobias
    "whats the point of a sneaky extra guy being spawned a little way away"
    I have no clue what you are talking about. Extra guy? Where? How? :)
    Never seen him.
  • markfrancombe
    Thanks for response, Moving the code object does it for me.. you lost me with
    Create a array of positions
    But I dont need that so... thanks..

    Names, I can now see how they were in the original and not yours. IN Unity they are only on the NPC heads, entered in the inspector. Somehow yourd have to grab the name entered in the Photon login and stick it there... Ive seen a thrid party namespace pack so I might investigate that... I guess I need to know how to snag the name from Photon?

    The no menu option might be beyond me.. but Ill see if Im ever awake enough to run through the doc you linked, looks like I need that... bad...

    And as far as the extra dude showing up.. OK my bad.. weirdly I had dragged in a copy of the prefab by accident...
  • Tobias
    > Somehow yourd have to grab the name entered in the Photon login and stick it there

    Yes, because each player will only enter his own name. The others will want to grab whatever you entered to display your name.
    You can combine PUN with some namespace plugin or just have a input field for that before the client joins a game.

    The tutorial is really simple. Give it a try. Maybe you notice you're able to code :)
  • markfrancombe
    Hey .. months later, Im back at the same thing... and NOW want to finally ready to go thru the tut...
    but seems to be broken link.. where is it please?
    Tobias wrote:
    Better read it online and work through each step: ... lotutorial