Skeetendo

’Cause all games were better on the GBC

You are not logged in.

#1 2014-05-12 08:16:03

Drake|Seawood
Member
From: Cerulean City
Registered: 2014-03-06
Post 16/27
Website

[HELP] Editing item prices on RBY

Hello everyone. I know Yellow offsets could vary from the Red/Blue ones but that's not a problem for me.

I found this code into the Pokered disassembly but I don't really understand what every byte stands for, specially If I'm about to edit the price from some comsumables like Potions, Antidotes (and maybe some TMs), etc.

ItemPrices: ; 4608 (1:4608)
    db $00,$00,$00
    db $00,$12,$00
    db $00,$06,$00
    db $00,$02,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$10,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$01,$00
    db $00,$02,$50
    db $00,$02,$50
    db $00,$02,$00
    db $00,$02,$00
    db $00,$30,$00
    db $00,$25,$00
    db $00,$15,$00
    db $00,$07,$00
    db $00,$03,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$05,$50
    db $00,$03,$50
    db $00,$00,$00
    db $00,$21,$00
    db $00,$21,$00
    db $00,$21,$00
    db $00,$98,$00
    db $00,$98,$00
    db $00,$98,$00
    db $00,$98,$00
    db $00,$98,$00
    db $00,$48,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$09,$50
    db $00,$21,$00
    db $00,$00,$00
    db $01,$00,$00
    db $00,$98,$00
    db $00,$10,$00
    db $00,$06,$00
    db $00,$15,$00
    db $00,$40,$00
    db $00,$07,$00
    db $00,$05,$00
    db $00,$07,$00
    db $00,$06,$50
    db $00,$00,$10
    db $00,$02,$00
    db $00,$03,$00
    db $00,$03,$50
    db $00,$00,$00
    db $00,$00,$00
    db $00,$05,$00
    db $00,$05,$50
    db $00,$03,$50
    db $00,$03,$50
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00
    db $00,$00,$00

Anyone can explain? Thanks you very much :)

Last edited by Drake|Seawood (2014-05-12 08:16:52)

Offline

#2 2014-05-12 11:30:53

Crystal_
Member
From: Spain
Registered: 2012-09-16
Post 188/411
Website

Re: [HELP] Editing item prices on RBY

As simple as:

db $00,$12,$00 (ultraball) costs 1200 coins
db $00,$06,$00 (superball) costs 600 coins
(...)
db $01,$00,$00 (nugget) costs 10000 coins

While we are at it, refer to the table at 0x7bfa7 in Red/Blue for TM prizes.

TechnicalMachinePrices: ; 7bfa7 (1e:7fa7)
; In thousands (nybbles).
db $32, $21, $34, $24, $34
db $21, $45, $55, $32, $32
db $55, $52, $54, $52, $41
db $21, $12, $42, $25, $24
db $22, $52, $24, $34, $42

Each digit (nybble) refers to different TM, for a total of 50 TMs. Multiply each nybble by 1000 to get the prize of the corresponding TM (they are ordered)

Offline

#3 2014-05-12 14:33:25

ShantyTown
Member
Registered: 2013-12-04
Post 62/340

Re: [HELP] Editing item prices on RBY

Another thing is that the price that you can sell items for is exactly half of what you would buy it for.  In other words, there isn't a separate table for "ItemSellPrices", it's just calculated from the entries in the "ItemPrices" table.  (I would assume this is also true for the TMs.)

Offline

Board footer

Powered by FluxBB