Skip to content

This is our CS4240 VR Scarecrow shooter and teleportation game! :D

Notifications You must be signed in to change notification settings

CS4240-Group6/assignment03-vrshooter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

56 Commits
 
 
 
 
 
 

Repository files navigation

Assignment 3

This is our CS4240 VR Scarecrow shooter and teleportation game! :D

You are a farmer in a rural farmland. You are tasked with destroying all the evil scarecrows that plague that farm. With the fruits you have grown in your farm, destory all the scarecrows with as little fruits as possible.

Environment Scene

image

Platform

Best run on Oculus Quest / Oculus Quest 2.

Scene

The main scene that we have developed the project on is Main2.

Setting Up

  1. Go to Assets > Import Package > Custom Package
  2. Navigate to where you have downloaded our unity package and select it
  3. Project is optimized for PC build on Oculus (if this option doesn't work, try building it as an android apk)

Features

1. Grabbing object

A fruit is grabbed by pressing A(joystick button 0) on RIGHT CONTROLLER. A fruit can be grabbed if it is one meter distance away from the controller. When a fruit is successfully grabbed, a grabbing sound effect is played.

Grabbing Script

GunController.cs

2. Throwing object

The fruit that is grabbed can be thrown by pressing A(joystick button 0) on RIGHT CONTROLLER. Throwing will be done only when a fruit is successfully grabbed. When the fruit hits a scarecrow, a sound effect will be played on impact and the fruit will disappear. Throwable objects include: The eggplants placed on the ground all over the world.

Throwing Script

GunController.cs
ProjectileController.cs

3. Teleportation

Teleportation is done by pushing the JOYSTICK forward + 11th AXIS BUTTON on LEFT CONTROLLER. A green line will be displayed that goes into the distance. This line shows the destination that user will teleport to. When the line is pointed to towards an area that you cannot teleport to, it will turn red.

Teleportation Script

Teleportation.cs

4. Show scoreboard

Scoreboard is shown by pressing 2ND TRIGGER(12th Axis) on RIGHT CONTROLLER. A sound effect will be played a scoreboard appears on screen. The scoreboard contains the following:

  • Scarecrows Remaining
  • Fruits Thrown
  • Progress (in terms of the numbe of scarecrows hit out of the total number)

image

Scoreboard Script


ScoreController.cs ScoreScript.cs

Assets Used

  • Oculus XR Plugin (Oculus Integration)
  • XR Plugin Management
  • OpenVR/XR Plugin
  • Polygon Farm
  • SteamVR (Not Used)

About

This is our CS4240 VR Scarecrow shooter and teleportation game! :D

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •