danreeves / dt-exchange

39 stars 18 forks source link

rounding errors vs game #3

Closed danreeves closed 1 year ago

Coconutcoo commented 1 year ago

Internal logic for display is at https://github.com/Cortex-Network/Darkmass-Data-Mining/blob/main/All%20.lua%20Scripts/scripts/foundation/utilities/math.lua#L98

Coconutcoo commented 1 year ago

Example; image image

{
    "offerId": "768e16ab-f5b9-4324-872f-34f7a0bc6185",
    "sku": {
        "id": "6ee9c6a5-7d91-4a1d-9663-c72b55a0e108",
        "displayPriority": 0,
        "internalName": "credit_store_all_rewards_psyker_psykinetic",
        "name": "credit_store_all_rewards_psyker_psykinetic",
        "description": "credit_store_all_rewards_psyker_psykinetic",
        "category": "item_instance",
        "assetId": "",
        "tags": [],
        "dlcReq": []
    },
    "entitlement": {
        "id": "1b64298e-5ae0-4b90-90fe-5bb65937f615",
        "limit": 0,
        "type": "Permanent"
    },
    "price": {
        "amount": {
            "amount": 17020,
            "type": "credits"
        },
        "id": "de60baa6-7376-4605-afb7-c27e7cc5cdf7",
        "priority": 1,
        "priceFormula": "dynamic_price_formula"
    },
    "state": "active",
    "description": {
        "id": "content/items/weapons/player/ranged/autogun_p1_m3",
        "gearId": "5ba10131-240b-442d-a22f-b4a6a1f98d53",
        "rotation": "day",
        "type": "weapon",
        "properties": {},
        "overrides": {
            "ver": 2,
            "rarity": 3,
            "characterLevel": 30,
            "itemLevel": 415,
            "baseItemLevel": 360,
            "traits": [
                {
                    "id": "content/items/traits/bespoke_autogun_p1/followup_shots_ranged_damage",
                    "rarity": 2
                }
            ],
            "perks": [
                {
                    "id": "content/items/perks/ranged_common/wield_reduce_sprint_cost",
                    "rarity": 3
                }
            ],
            "base_stats": [
                {
                    "name": "autogun_p1_m1_dps_stat",
                    "value": 0.79
                },
                {
                    "name": "autogun_p1_m1_stability_stat",
                    "value": 0.73
                },
                {
                    "name": "autogun_p1_m1_power_stat",
                    "value": 0.61
                },
                {
                    "name": "autogun_p1_m1_mobility_stat",
                    "value": 0.72
                },
                {
                    "name": "autogun_p1_m1_ammo_stat",
                    "value": 0.76
                }
            ]
        }
    },
    "media": []
}