API: Standardize names of Stock APIs (#2173)

This commit is contained in:
catloversg
2025-06-02 16:36:36 +07:00
committed by GitHub
parent 856ce9a5c9
commit 7d2686ed1b
16 changed files with 104 additions and 57 deletions

View File

@@ -453,9 +453,9 @@ interface StockMarketConstants {
/** An internal constant used while determining when to flip a stock's forecast */
TicksPerCycle: number;
/** Cost of the WSE account */
WSEAccountCost: number;
WseAccountCost: number;
/** Cost of the TIX API */
TIXAPICost: number;
TixApiCost: number;
/** Cost of the 4S Market Data */
MarketData4SCost: number;
/** Cost of the 4S Market Data TIX API integration */
@@ -1219,19 +1219,22 @@ export interface NetscriptPort {
* @public
*/
export interface TIX {
/** Get game constants for the stock market mechanic.
* @remarks RAM cost: 0 GB */
/**
* Get game constants for the stock market mechanic.
*
* @remarks RAM cost: 0 GB
*/
getConstants(): StockMarketConstants;
/**
* Returns true if the player has access to a WSE Account
* @remarks RAM cost: 0.05 GB
*/
hasWSEAccount(): boolean;
hasWseAccount(): boolean;
/**
* Returns true if the player has access to the TIX API
* @remarks RAM cost: 0.05 GB
*/
hasTIXAPIAccess(): boolean;
hasTixApiAccess(): boolean;
/**
* Returns true if the player has access to the 4S Data
* @remarks RAM cost: 0.05 GB
@@ -1241,7 +1244,7 @@ export interface TIX {
* Returns true if the player has access to the 4SData TIX API
* @remarks RAM cost: 0.05 GB
*/
has4SDataTIXAPI(): boolean;
has4SDataTixApi(): boolean;
/**
* Returns an array of the symbols of the tradable stocks
*
@@ -1259,9 +1262,9 @@ export interface TIX {
* The stocks price is the average of its bid and ask prices. This function requires
* that you have the following:
*
* 1. WSE Account
* - WSE Account
*
* 1. TIX API Access
* - TIX API Access
*
* @example
* ```js
@@ -1287,9 +1290,9 @@ export interface TIX {
* The organization associated with the corresponding stock symbol. This function
* requires that you have the following:
*
* 1. WSE Account
* - WSE Account
*
* 1. TIX API Access
* - TIX API Access
*
* @example
* ```js