GithubHelp home page GithubHelp logo

leslija / gg-frisbeegolf Goto Github PK

View Code? Open in Web Editor NEW

This project forked from gubner/gg-frisbeegolf

0.0 0.0 0.0 117 KB

Frisbee Golf for FiveM

License: GNU General Public License v3.0

JavaScript 4.63% Lua 86.15% CSS 4.15% HTML 5.07%

gg-frisbeegolf's Introduction

gg-frisbeegolf: Frisbee Golf by Gubner

A FiveM resource to add Frisbee Golf to your server. Use as Standalone or QB-Core. Includes custom props: Frisbees with physics, Tee Pads, and Frisbee Golf Baskets. Ability to customize locations of tees and holes, and even use alternative props for the hole targets.

Installation:

Install gg-frisbeegolf in your resources folder and ensure in your server.cfg file

Install gg-frisbeeprops in your resources folder and ensure in your server.cfg file

Optional:

Install gg-frisbeegolfstand in your resources folder and ensure in your server.cfg file. If you decide not to use this ymap, update gg-frisbeegolf\config.lua Config.UsingMap.

Dependencies:

PolyZone

Setting up for QB-Core:

1. Add items to qb-core\shared\items.lua:

	['frisbee'] 				 	 = {['name'] = 'frisbee', 						['label'] = 'Frisbee', 							['weight'] = 100, 		['type'] = 'item', 		['image'] = 'frisbee.png', 					['unique'] = true, 		['useable'] = true, 	['shouldClose'] = false, 	['combinable'] = nil, 	['description'] = 'A flying disc'},
	['frisbee_r'] 				 	 = {['name'] = 'frisbee_r', 					['label'] = 'Red Frisbee', 						['weight'] = 100, 		['type'] = 'item', 		['image'] = 'frisbee_r.png', 				['unique'] = true, 		['useable'] = true, 	['shouldClose'] = false, 	['combinable'] = nil, 	['description'] = 'A flying disc'},
	['frisbee_g'] 				 	 = {['name'] = 'frisbee_g', 					['label'] = 'Green Frisbee', 					['weight'] = 100, 		['type'] = 'item', 		['image'] = 'frisbee_g.png', 				['unique'] = true, 		['useable'] = true, 	['shouldClose'] = false, 	['combinable'] = nil, 	['description'] = 'A flying disc'},
	['frisbee_b'] 				 	 = {['name'] = 'frisbee_b', 					['label'] = 'Blue Frisbee', 					['weight'] = 100, 		['type'] = 'item', 		['image'] = 'frisbee_b.png', 				['unique'] = true, 		['useable'] = true, 	['shouldClose'] = false, 	['combinable'] = nil, 	['description'] = 'A flying disc'},
	['frisbee_y'] 				 	 = {['name'] = 'frisbee_y', 					['label'] = 'Yellow Frisbee', 					['weight'] = 100, 		['type'] = 'item', 		['image'] = 'frisbee_y.png', 				['unique'] = true, 		['useable'] = true, 	['shouldClose'] = false, 	['combinable'] = nil, 	['description'] = 'A flying disc'},

2. Add items to qb-shops\config.lua Config.Products:

	["frisbee"] = {
		[1] = {
			name = "frisbee",
			price = 500,
			amount = 10,
			info = {},
			type = "item",
			slot = 1,
		},
		[2] = {
			name = "frisbee_r",
			price = 500,
			amount = 10,
			info = {},
			type = "item",
			slot = 2,
		},
		[3] = {
			name = "frisbee_g",
			price = 500,
			amount = 10,
			info = {},
			type = "item",
			slot = 3,
		},
		[4] = {
			name = "frisbee_b",
			price = 500,
			amount = 10,
			info = {},
			type = "item",
			slot = 4,
		},
		[5] = {
			name = "frisbee_y",
			price = 500,
			amount = 10,
			info = {},
			type = "item",
			slot = 5,
		},
	},

3. Add shop to qb-shops\config.lua Config.Locations (if you are not using the provided map, switch coords commenting):

	["frisbeeshop"] = {
		["label"] = "Frisbee Shop",
		["coords"] = vector4(279.3, 6790.43, 15.94, 270.37), -- using ymap
		--["coords"] = vector4(281.93, 6789.18, 15.7, 270.37), -- not using ymap
		["ped"] = 'cs_omega',
		["scenario"] = "WORLD_HUMAN_STAND_IMPATIENT",
		["radius"] = 1.5,
		["targetIcon"] = "fa-solid fa-cart-shopping",
		["targetLabel"] = "What frisbees do you have?",
		["products"] = Config.Products["frisbee"],
		["showblip"] = true,
		["blipsprite"] = 540,
		["blipscale"] = 0.6,
		["blipcolor"] = 0
	},

4. Add provided images to qb-inventory\html\images

5. Update gg-frisbeegolf\config.lua

Config.Standalone = false

Commands

In Standalone, you may retrieve your frisbee from your inventory using:

/frisbee

If your frisbee is stuck in a place you cannot get to (up a tree, on a roof, under the map), get as close as possible and use:

/frisbeestuck

If a client does not want to play and is concerned about the resource running, the main thread loop can be deactivated with:

/nofg

gg-frisbeegolf's People

Contributors

gubner avatar scriptpunkio avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.