wiki.sine.space | sinespace

Difference between revisions of "The safe zone lobby"

From wiki.sine.space
Jump to: navigation, search
(Created page with "The Safe Zone Lobby is a game lobby inside the region. It is where players are moved when they first arrive in the scene and it is where they respawn when they die. Players ca...")
(No difference)

Revision as of 12:26, 1 March 2019

The Safe Zone Lobby is a game lobby inside the region. It is where players are moved when they first arrive in the scene and it is where they respawn when they die. Players cannot shoot or be take damage in the safe zone. Leaderboards, game instructions and other game options can be made available to players in the game lobby.

The core mechanics of the game are governed though the Combat Meter which is part of the Safe Zone Lobby.

The public variables on the Combat Meter allow developers and players to configure game settings including player health and max bullets.

This video tutorial shows how to wire up and publish your own Safe Zone Lobby as a spawnable item players can in place in their own customised multi-player maps in Sinespace;


PENDING


Combat meter

The core functions of the game are managed by the Combat Meter.

IMAGE

Public variables The public variables can be made available inworld if you want to you can allow individual players to configure these in their regions.

If you want to expose the public variables inworld, when you upload to Sinespace, on the virtual goods component set the Customisation Capabilities to Full. If you want to hide the public variables set the Customisation Capabilities to Basic or Disallowed.

IMAGE

PlayerSpawnMinRange and PlayerSpawnMaxRange defines a radius from the centre of the safe zone where players will spawn and respawn. It defaults to 5 meters.

PlayerMaxHealth allows you to set the player max health.

PlayerMaxBullets allows you to set the max bullets per gun. This is currently a universal value across guns.

DeathSequenceDuration sets the time from dying to arriving back at the safe zone. It defaults to five seconds which is time to play a death animation and change camera angles during the player death event.

TeleportEffectDuration This sets the amount of time for particles you can trigger when the player teleports from the safe zone to a spawn point in the game.

PlayerStartHealth is the amount of health a player has when they spawn into the game.

Channel. This is the channel the components communicate on. You should not need to alter this from the defaults.

Resources There is one resource referenced on the Combat Meter; the gunBarIcon. This is a canvas element that sits behind the individual gun icons in the gun bar when players have one or more guns enabled during gameplay.

Events There are seven events referenced on the Combat Meter;

  • damage
  • die
  • teleportStart
  • teleportEnd
  • AmmoAdd
  • hpUp
  • showOwnerControl
  • npcKill
  • avatarKill

The damage and die events trigger animation events in the Animation Controller attached to the Combat Meter. These events are both canvas based; a damage vignette when the player is hit and a message on screen when they die.

These canvas events occur in parallel with the animations triggered in the player’s Animation Override, which is part of the gun the player has enabled during gameplay.

teleportStart and teleportEnd can trigger particles or other events at the Safe Zone Lobby and at the spawn point when a player leaves the lobby and enters the playable map.

AmmoAdd and hpUp events trigger when the player collects ammo or health from the Health or Ammo Givers.

showOwnerControl exposes a canvas based toggle inworld that players can use to disable the game when in room edit mode.

npcKill and avatarKill are events that can be triggered when NPCs or other players are killed by the player.

Object references The 11 object references on the Combat Meter reference the various active canvas elements in the player HUD. The references do not require manual configuration.

Player HUD

The PlayerHUD presents the number of kills, the health bar, game points and ammo levels. You can move elements on the canvas around, change fonts, colour, etc. to bring the HUD in line with your art.

Nav mesh obstacle

The Nav Mesh Obstacle on the base of the Safe Zone ensures that when a player places the Safe Zone Lobby in their region, any NPCs in the region will not walk through it.

IMAGE

Proximity activator

The Proximity Activator on the base of the safe zone is triggered when the player within a certain radius of it. It switches the combat HUD off and disables gameplay when the player is inside the Safe Zone Lobby. It should be set to Client Only – if unticked, whenever one player entered the safe zone the game would stop for everyone!

IMAGE

Bullet pool manager

The Bullet Pool Manager creates a pool of reused bullets in the viewer, as a more efficient method of managing bullets than creating and destroying individual game objects. The pool defaults to a pool of 20 bullets. If you are creating a gun with a very high fire rate you might need to expand that pool but we limit network messages to 12 per second so you will hit performance issues if you go too high. The poolItemTtl field is the lifetime of the bullet, in seconds.

IMAGE

Owner control panel

The Owner Control Panel allows the map owner to set the Safe Zone Lobby to be inactive while they move it around in the scene and spawn other game items.


IMAGE