-
Notifications
You must be signed in to change notification settings - Fork 5
Update Markdown of OSS. #27
Changes from 30 commits
e954160
490f89a
43136db
15e66f2
72eb781
4b295f5
78715cf
51a4b5e
1bb0f83
7092e16
1e5c73b
4184332
a7958d2
44c789c
558e085
8351aed
0499ca7
8c56d32
da75ffd
0c9908c
e8981a3
d35beb9
b05d047
d2db358
f9e8ca6
a84419d
fad63ed
b8d77fc
78290a1
9f13d77
3e38905
07899b2
71f39a4
d99a661
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,19 @@ | ||
--- | ||
layout: ../../../../layouts/Main.astro | ||
title: 'Open Source Shop' | ||
title: "Open Source Shop" | ||
description: "Bringing Shops to the Athena Framework, absolute free and open source! Licensed under MIT" | ||
author: 'Der Lord!' | ||
version: '3.0.4+' | ||
images: ['https://user-images.githubusercontent.com/82890183/148626519-5dc1ced7-a4d9-4f86-a349-26e58729cea8.png', 'https://user-images.githubusercontent.com/82890183/148910952-470985fe-5fed-41ed-8b87-08c9977f71c2.png'] | ||
keywords: ['free', 'player', 'server', 'client', 'interface', 'system', 'item'] | ||
url: 'https://github.com/Booster1212/OpenSourceShop' | ||
discord: 'Der Lord!#6021' | ||
author: "Der Lord!" | ||
version: "3.0.4+" | ||
images: | ||
[ | ||
"https://user-images.githubusercontent.com/82890183/148626519-5dc1ced7-a4d9-4f86-a349-26e58729cea8.png", | ||
"https://user-images.githubusercontent.com/82890183/148910952-470985fe-5fed-41ed-8b87-08c9977f71c2.png", | ||
] | ||
keywords: ["free", "player", "server", "client", "interface", "system", "item"] | ||
url: "https://github.com/Booster1212/OpenSourceShop" | ||
discord: "Der Lord!#6021" | ||
--- | ||
|
||
# OpenSourceShop | ||
|
||
<img src="https://user-images.githubusercontent.com/82890183/148142146-ba173e98-4c11-47d9-95da-6d83de2608af.png" width="650" /> | ||
|
@@ -36,71 +41,66 @@ So feel free to do whatever you want! | |
- Drop server/client files into athena-oss -> src/core/client-plugins, client stuff here -> src/core/server-plugins -> server stuff here. | ||
|
||
```typescript | ||
Imports (Client) -> | ||
import './OSS/view'; | ||
import './OSS/src/client-events'; | ||
- Imports (Client) -> | ||
- import './athena-oss/view'; | ||
- import './athena-oss/src/client-events'; | ||
|
||
Imports (Server) -> | ||
import './OSS/index'; | ||
|
||
// src-webviews/pages/components.ts -> | ||
import ShopUI from './shopUI/ShopUI.vue'; | ||
ShopUI: shallowRef(ShopUI) | ||
``` | ||
# Setup (Buying Shop - 24/7) | ||
```typescript | ||
export const BUYERS: alt.Vector3[] = [ | ||
{ x: 25.980966567993164, y: -1345.6417236328125, z: 28.497024536132812 } as alt.Vector3, // Index 0 | ||
]; | ||
|
||
// Used to give all the shops are different blip, just copy the line as often as you need it. | ||
export const buyerBlips = [ | ||
{ sprite: 59, color: 2, text: '24/7 Shop', scale: 1 }, // Index 0 | ||
]; | ||
|
||
// In OSS each Shop can hold individual items or you can add the same list to a few more stores over and over again. | ||
// Default List for all 24/7 & LTD Stores. | ||
const shopList = [ | ||
{ name: 'Bread', dbName: 'bread', price: 75, image: 'crate' }, | ||
{ name: 'Hotdog', dbName: 'Shophotdog', price: 375, image: 'crate' }, | ||
{ name: 'Waterbottle', dbName: 'Shopwater', price: 250, image: 'crate' }, | ||
{ name: 'Cola', dbName: 'Shopcola', price: 250, image: 'crate'}, | ||
{ name: 'Energy Drink', dbName: 'Shopenergy', price: 300, image: 'crate'} | ||
]; | ||
- import './OSS/index'; | ||
|
||
export const buyLists = [ | ||
shopList, | ||
]; // ADD YOUR LISTS HERE! | ||
src-webviews/pages/components.ts -> | ||
- import ShopUI from './shopUI/ShopUI.vue'; | ||
- ShopUI: shallowRef(ShopUI) | ||
``` | ||
|
||
# Setup (Drugsellers) | ||
# Setup (Shops / TYPE ) | ||
```typescript | ||
import * as alt from 'alt-server'; | ||
|
||
// Shops are based on the index of arrays so -> First index -> First sellList | ||
export const SELLERS: alt.Vector3[] = [ | ||
{ x: 1163.400634765625, y: -323.938232421875, z: 68.20509338378906 } as alt.Vector3 // SELLER (SHOP-POS) INDEX -> 0 | ||
// { Add stuff yourself } Just another seller, INDEX 1 -> The secoond list will get into this position. | ||
]; | ||
|
||
// Used to give all the shops are different blip, just copy the line as often as you need it. | ||
export const sellersBlips = [ | ||
{ sprite: 52, color: 1, text: 'Seller Example - Index 0', scale: 1 }, // Index 0 | ||
export const coreShopLocations: IShopLocation[] = [ | ||
{ x: 25.980966567993164, y: -1345.6417236328125, z: 28.497024536132812, isBlip: true } as IShopLocation, | ||
{ x: 374.3475341796875, y: 328.112060546875, z: 102.56637573242188, isBlip: true } as IShopLocation, | ||
{ x: -3041.32763671875, y: 585.155029296875, z: 6.908928871154785, isBlip: true } as IShopLocation, | ||
{ x: -3243.743408203125, y: 1001.3903198242188, z: 11.830706596374512, isBlip: true } as IShopLocation, | ||
{ x: 548.0447387695312, y: 2669.48876953125, z: 41.156490325927734, isBlip: true } as IShopLocation, | ||
{ x: 1960.2322998046875, y: 3742.317138671875, z: 31.343746185302734, isBlip: true } as IShopLocation, | ||
{ x: 1730.01171875, y: 6416.22021484375, z: 34.03722381591797, isBlip: true } as IShopLocation, | ||
{ x: 2555.4609375, y: 382.1643371582031, z: 107.62295532226562, isBlip: true } as IShopLocation, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is there a specific purpose why you used as I don't see the point in overtyping. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. See in playground There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Overtypes is resolved soon as well, thanks. 👍 |
||
]; | ||
|
||
const burgerBuyer = [ | ||
{ name: 'Burger', dbName: 'burger', price: 330, image: 'crate' }, // SellList INDEX -> 0 | ||
// { Add stuff yourself. } Second Items for SELLERS Index -> 0 | ||
]; | ||
const anotherExampleList = [ | ||
// { Fill me! } -> Index 1 | ||
export const ShopRegistry: Array<IShop> = [ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same here, where's the type There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Will be resolved soon. Thanks 👍 |
||
// BUY SHOP | ||
{ | ||
name: '24/7 Shop', | ||
dbName: '24-7-Shop', | ||
blipSprite: 59, | ||
blipColor: 2, | ||
blipScale: 1, | ||
data: { | ||
items: [ | ||
{ dbName: 'bread', price: 75 }, | ||
{ dbName: 'Shophotdog', price: 375 }, | ||
{ dbName: 'Shopwater', price: 250 }, | ||
{ dbName: 'Shopcola', price: 250 }, | ||
{ dbName: 'Shopenergy', price: 300 }, | ||
], | ||
}, | ||
locations: coreShopLocations, | ||
}, | ||
// SELL SHOP | ||
{ | ||
name: 'Seller Example', | ||
dbName: 'SellerExample', | ||
shopType: shopType.SELL, | ||
blipSprite: 52, | ||
blipColor: 1, | ||
blipScale: 1, | ||
data: { | ||
items: [{ dbName: 'burger', price: 330 }], | ||
}, | ||
locations: sellerExampleLocations, | ||
}, | ||
]; | ||
|
||
export const sellLists = [burgerBuyer, /*anotherExampleList*/]; // Dont forget to add custom item lists here | ||
|
||
``` | ||
|
||
<img src="https://user-images.githubusercontent.com/82890183/148910952-470985fe-5fed-41ed-8b87-08c9977f71c2.png" width="500"/> | ||
<img src="https://user-images.githubusercontent.com/82890183/148910952-470985fe-5fed-41ed-8b87-08c9977f71c2.png" width="6500"/> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why is this 6500? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fixd |
||
|
||
![image](https://user-images.githubusercontent.com/82890183/148634183-00270cd2-ba69-4a46-94ba-58434967c890.png) | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't we also define the types themselves?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unsure what this exactly means? 🤔