Jump to content

suloku

Innovator
  • Posts

    742
  • Joined

  • Last visited

  • Days Won

    26

Posts posted by suloku

  1. There's a fact: even an obvious hack like morfeo's code does the same job as the official event.

    For what we know, If you toss the wondercard there's no way of telling if you received mystyc ticket from the official nintendo event (on usa savegame of course) or from morfeo's wondercard.

    In the end, there would be not much difference from a really accurate wondercard, gamewise. The lugia and hoho received from the event would also be 100% legit (legal?) as they are generated in-game.

    Same happens with eon ticket, were even the script is deleted after triggering the event.

  2. First of all, thank you for researching this! This is very exciting, I'm adding this to the editor and checking if the surskit swarm on emerald is always the same after mixing records.

    Second, I've checked my emerald save with surskit swarm ongoing, and it starts at section 3 0x980. At 0x980 there seem to be se 36 byte slots, each with a different ID. Some are from record mixing, as I can see the ID of the game I mixed with, and some are mine (interviews I think). They may hold data like bough items, pokemon catched and with which ball... that info that you see when you mix records.

    Aslo, at 0xC50 in this save I currently have 3 tv announcements: 1 for the outbreak (already seen) and two more that will pop up the following day, as the counter is still at 3 (IDs 0x01 and 0x03).

    EDIT: on another save I have 4 announcements, may test later how many they are actually.

    I agree the only interesting tv event are outbreaks, but still seems interesting.

    BTW, surskit swarm data (the save is just after watching the event on tv):

    29 00 00 00 91 00 62 00 00 00 00 00 37 01 00 00
    11 00 00 32 03 00 00 00 07 00 00 00 00 00 00 00
    AA AA BB BB
    
    AAAA: Game TID
    BBBB: TID of the game it was mixed from
    
    Swarm extra data :
    37 01 11 00 03 00 00 00 91 00 62 00 00 00 00 00
    00 32 02 00

    EDIT: Ok, the mix records outbreak doesn't get added to 0x8CC (emerald), but I've checked another save with a normal seedot swarm and it is there. At 0x980 it seems there's room to store 7 (need to check if there can be more) TV programs, the ones that get stored via mix records and other that get generated in-game (like the interview battle). The record mixing surskit swarm gets added to this list and not to the common pokemon outbreak region that is generated in-game.

    For the surskit mixed swarm save, it would seem the normal outbreak region (0x8cc in emerald) is all 0x00, except for species, which is 0x0059. I don't know if this is relevant in any way, I'll have to mix records and check the before and after savegames.

    It would also seem that when the "in-game" outbreak gets seen, the data at 0x8cc gets erased (again, needs confirmation).

    Other TV program IDs I've seen in my saves:

    16 - in game or mixed
    18 - in game or mixed
    19 - in game or mixed
    1A
    1C
    21
    25
    29 - outbreak ( appears as program at 0x980 region for mix records, at 0x8CC for in-game outbreak)
    
    In game or mixed: the TV program appears when mixing records referring to the mixed OT or in-game referring to the Game's OT

    The structure for what I've seen (each tv program is 36 bytes long)

    0x00 - Program ID
    0x01 - Status?
    0x02 - 0x12: Program data? TV program 0x21 has data in all these bytes, other programs use less data.
    0x13 - 0x1D: Trainer name
    0x1E-0x1F: Game's TID
    0x20-21: Record mixing game TID / Game's TID if not from record mixing
    0x22-23: Record mixing game TID / Game's TID if not from record mixing
    

    Note: remember all offsets I mention are for emerald

  3. Wow, those are really complete, thank you very much! I guess I'll have to add all languages then.

    Edit: I've seen there's tv show structure too, which is something I also wanted to investigate, which is pretty awesome that there's already so much info. I'm interested in surskit swarm in emerald, and I actually have a save file with one, which for what I've seen, happens a day after mixing records with r/s.

    Also, how did you obtain obsetts for mistery gift/event in emerald? I'm using other offsets fine, in fact I think mistery event and mistery gift share the same offset for the script (the ones you have also overlap).

  4. The editor is mostly finished. Berry editor should be fine. The inner works of the "usage by trainer" depend on the game itself. I could add checks to prevent impossible combinations, like making a berry that heals pp and hp, but I'm leaving that to the user (editor already has a warning about these things).

    Bugfixing may need people using the editor as I can't find them all.

    Trainer cards: I haven't tried to figure out the values for pokemon and moves, they aren't stored as index number (I think) and it's a tedious job.

    Also, there's only the english list of words.

    We are waiting to get at least the remaining events from italy for a release. I may start working on nds code meanwhile, but I won't have my nds to test until next week.

  5. I've updated first post.

    Split the folders according to region, proceeded by languages.

    That was quick, thanks for actually doing it, I really think it is more clear this way.

    Also, I've checked the file, and maybe for the sake of completion you'd like to include the pokémon link ESP Johto starters file. I also uploaded a Glalie from the ESP Demo. The files are here: https://projectpokemon.org/forums/showthread.php?47509-XY-ORAS-Pok%E9mon-Link-tool-0-1

    The Glalie's from the ORAS Demo are actually generated in the demo and are transfered to ORAS as they are in the demo, so in that sense they are more like a .pkm file because every time you run the demo a different glalie is generated, but may still be interesting for those that for some reason can't access the demo.

  6. I can get my spanish carts (emerald and rubi) probably sent by next wednesday/thursday morning.

    I hope we make it in time...

    But even if people are aware, they still need someone from italy to send and receive the cartridges...so I don't think they will be getting that many carts.

    Also, maybe then the saves popup somewhere? I don't think so though...

    pressing the A button to talk to the man in blue this shows the icon of latios as 2 times and then shows the icon of latias

    You can not continue the game when shown latias

    Mmm... I had some problems too, but I thought it was due to another problem. In any case my current script works fine for that. Nlt that people have to use them anyway. The good thing is that if the game isn't saved, you can test it, then toss the wondercard and the save is like there was never a custom script there.

  7. [video=youtube;UUOM8R6v-tc]https://www.youtube.com/watch?v=UUOM8R6v-tc&feature=youtu.be

    I personally like the changes in the wc

    be careful with scripts since they can lock.

    Sorry, I can't see the video. What do you mean by they can "lock"? Break the game?

    Custom scripting is not the goal of this thread, it is still to preserve the legit events and provide a way to distribute them.

    I've agreed with ajxpkm that alongside with the full tool, I'll made a more simple tool that has the real legit events embedded, just like taka's tools. That's also what the gc/wii versions (and hopefully a NDS version) will do.

  8. Now that you mention WC naming, how do we differentiate between EUR released wondercards and USA released ones for different languages? They have different wondercard ID#, but I think it would be helpful to actually include the region in the filename, or maybe include them in different subfolders in the compilation file:

    JAP

    KOR

    USA (includes ENG, ITA, ESP, GER, FRE)

    EUR (includes ENG, ITA, ESP, GER, FRE)

    I think it would be helpful, for example, if the shiny xerneas ESP wondercard released in USA never gets released in europe, one may think that it was due to the wondercard being in spanish. On the other hand if it gets released in EUR and is the very same wondercard, there's no problem, but if they decide to release it under a different WC ID the ESP folder in the archive would end up with two shiny xerneas wondercards, one from US and one from EUR.

    Or am I wrong and can an EUR console receive the USA event if using a proxy/connecting in the US?

  9. I tried starting at 0x02029514 and the data was written, but 0x7C bytes before the correct offset.

    Also, more data is written to the save besides the item data, which results in script corruption since the checksum is no longer valid. Maybe it's writebytetooffset's fault? Or maybe I'm doing it wrong.

    EDIT: nevermind, there's something wrong in my end, will try at some other time.

  10. You could do that with writebytetooffset "value" "RAM offset"

    For example the US Eon Ticket.

    writebytetooffset 0x33 0x20291B0
    writebytetooffset 0x00 0x20291B1
    writebytetooffset 0x00 0x20291B2
    writebytetooffset 0x00 0x20291B3
    writebytetooffset 0x01 0x20291B4
    writebytetooffset 0x1E 0x20291B5
    writebytetooffset 0x13 0x20291B6
    writebytetooffset 0x01 0x20291B7

    I actually tried something similar, but I couldn't find the offsets! How did you find them? Are those for emerald? I searched but couldn't find any information about it.

    On a side note, record mixing in emerald works fine, and I'm pretty sure that both the mistery event script and wonder card script go to the same offset, so they are mutually exclusive. Since a script was never released for emerald we can't be sure, but since record mixing item data comes just after the script ends I think they used the same region for it.

  11. I've crafted a simple script for emerald to be used on a custom wondercard that enables the EON Ticket event, that in emerald is coded in-game.

    When you talk to the person in blue, a picture of the missing lati is shown and its roar played, then the flag for the event is enabled and you can talk again to the man in blue to receive the Eon ticket.

    This is not how it was meant to be in any way, but I though it was fun to do while learning a little how scripting works, and as it is a wondercard it can be shared via WiFi to other emeralds. I wouldn't recomend if you worry about the full legitimacy of the savegame though.

    http://puu.sh/oMY0J/db012179f0.png

    http://puu.sh/oMXYJ/7a9603be13.png

    '---------------
    #org 0x4
    setvirtualaddress 0x8000004
    lock
    faceplayer
    checkflag 0x16B0
    virtualgotoif 0x1 0x50
    showpokepic 0x198 0x0A 0x03
    cry 0x198 0x2
    waitcry
    waitkeypress
    hidepokepic
    checkflag 0xD50
    virtualgotoif 0x1 0x80
    setflag 0xD50
    release
    end
    
    '---------------
    #org 0x50
    showpokepic 0x197 0x0A 0x03
    cry 0x197 0x2
    waitcry
    waitkeypress
    hidepokepic
    checkflag 0xD50
    virtualgotoif 0x1 0x80
    setflag 0xD50
    release
    end
    
    '---------------
    #org 0x80
    release
    end
    

    Some flags for emerald I've gathered while researching, just so they don't get lost into nothingness:

    - badges flags are stored at 0x3fB section 2, badge 1 flag# is 0x867 and badge 8 flag# is 0x86E

    - Selected lati is stored at 0x5c6 section 2 (bit 0, or 0x01), the flag# is 0x16B0

    - EON ticket event flag is stored at 0x49A section 2 (bit 0, or 0x01), the flag# is 0xD50.

    I know custom scripting in wondercards/mistery event is not the goal of this thread, but I though it was a good example to show what the research has lead to, and also a good example of what the tool I've coded can do.

  12. So, back to scripting: I made a mistery event script for emerald that enables the eon ticket event (which is hardcoded to the rom). It's flag 0xD50 if anyone wonders.

    Also, I made a wondercard for emerald that enables the eon ticket flag. Yep. A shearable wondercard that allows access to the in-game event for the eon ticket. Only downside is that I don't think there's a way to add the record mixing item data trough scripting (in jap emerald, the mistery event for eon ticket enables the flag and also puts the item record mixing data, or that's how I have been told the event worked and what taka's tools do).

    EDIT: it was flag 0xD50, I misstyped

  13. Thank you very much for the information.

    Some things about berries:

    * Region 0xC-0x13 (8 bytes) is 0x00 in the e-card data, but once in the save it has data (unknown meaning)

    * Region 0xC-0x13 (8 bytes) is interpreted as being 0x00 when the berry checksum is calculated (same method as for RS mistery event).

    * USA berries work on jap games, but description won't shown. More info on what makes them different is needed, but I've read it has to do with text string lengths, but the other data for the berry might be in the same offsets.

    Export/import berry has been added (0x41A set to 0x01 when injecting). Berry editor coming.

    I also need to add handling of the different checksum calculation for mistery event in emerald. Is there any information about what mistery event was used for in JAP Emerald and FRLG? Besides eon ticket on emerald I know nothing.

    EDIT: http://puu.sh/oL61R/0fd6e7af9e.png

    http://puu.sh/oL6BM/42a4d0a9a0.png

    Only the "usage by trainer" field is missing from editor, but it is rather complicated, so I'm leaving it for later.. It'd be great if I could convert png files to berry sprites and vice versa, but it's probably too complicated for me and there's surely some gen 3 sprite editors out there. If I get the file format I could export/import berry sprite from that format.

    There seems to be some upper/down limits to the berry propierties, as I set all to max and the berry wasn't recognized by the game. I'll check what the values are tomorrow.

  14. I might be coding this, but I'm no experienced coder at all, less in C# and windows forms, so since this is how I did it and it works, I'm not changing it :P

    Btw, here's the RS script for regidolls from Morfeo:

    '---------------
    #org 0x4
    setvirtualaddress 0x8000004
    lock
    faceplayer
    virtualmsgbox 0x8000080 '"PAPÁ["][player]! Me alegro de vert..."
    checkflag 0xFB00
    virtualgotoif 0x1 0x8000035
    callstd 0x4
    giveitem3 0x76
    compare LASTRESULT 0x0
    virtualgotoif 0x1 0x8000077
    setflag 0xFB00
    virtualcall 0x8000037
    callstd 0x4
    checkflag 0xFB01
    virtualgotoif 0x1 0x8000055
    giveitem3 0x77
    compare LASTRESULT 0x0
    virtualgotoif 0x1 0x8000077
    setflag 0xFB01
    giveitem3 0x78
    compare LASTRESULT 0x0
    virtualgotoif 0x1 0x8000077
    clearflag 0xFB00
    clearflag 0xFB01
    virtualmsgbox 0x800014A '"La nota del paquete dice:\nSi dese..."
    callstd 0x4
    release
    killscript
    
    '---------------
    #org 0x35
    callstd 0x4
    checkflag 0xFB01
    virtualgotoif 0x1 0x8000055
    giveitem3 0x77
    compare LASTRESULT 0x0
    virtualgotoif 0x1 0x8000077
    setflag 0xFB01
    giveitem3 0x78
    compare LASTRESULT 0x0
    virtualgotoif 0x1 0x8000077
    clearflag 0xFB00
    clearflag 0xFB01
    virtualmsgbox 0x800014A '"La nota del paquete dice:\nSi dese..."
    callstd 0x4
    release
    killscript
    
    '---------------
    #org 0x77
    virtualmsgbox 0x80001B8 '"¡Que mal! No tienes especio para o..."
    callstd 0x4
    release
    end
    
    '---------------
    #org 0x37
    checkflag 0xFB01
    virtualgotoif 0x1 0x8000055
    giveitem3 0x77
    compare LASTRESULT 0x0
    virtualgotoif 0x1 0x8000077
    setflag 0xFB01
    giveitem3 0x78
    compare LASTRESULT 0x0
    virtualgotoif 0x1 0x8000077
    clearflag 0xFB00
    clearflag 0xFB01
    virtualmsgbox 0x800014A '"La nota del paquete dice:\nSi dese..."
    callstd 0x4
    release
    killscript
    
    '---------------
    #org 0x55
    giveitem3 0x78
    compare LASTRESULT 0x0
    virtualgotoif 0x1 0x8000077
    clearflag 0xFB00
    clearflag 0xFB01
    virtualmsgbox 0x800014A '"La nota del paquete dice:\nSi dese..."
    callstd 0x4
    release
    killscript
    
    
    '---------
    ' Strings
    '---------
    #org 0x80
    = PAPÁ["][player]! Me alegro de verte!\nPero seguro viniste solo porque ya\pte enteraste de que me llegó un\npaquete para ti de parte de MORFEO.\p¡INCREIBLE!, contiene estos POKé DOLL.\n¡Solo míralos!, aquí tienes...
    
    #org 0x14A
    = La nota del paquete dice:\nSi deseas contactar a MORFEO,\ppuedes escribirle a su correo:\n["]pkmnmorfeoœgmail.com"
    
    #org 0x1B8
    = ¡Que mal! No tienes especio para otro\nPOKé DOLL.\pPrimero haz espacio en tu PC y\ndespués regresa conmigo.
    

    From what he did, I've deduced how to create the script and make the pointers relative to the script, so with XSE it will be a piece of cake.

    Also, it seems morfeo didn't know there's a command to check if the dolls are already in the decoration inventory, as he sets some flags to make sure he gives the 3 dolls instead of doing it the "right" way.

    Also, the checksum used in mistery event for Emerald is the very same used for wondercards. GF probably implemented it on emerald and used it for ME too.

    EDIT:

    Re-reading this: http://forums.glitchcity.info/index.php?topic=7114.0

    What I thought to be some kind of header for the script in mistery event, may be the person to whom the script is associated:

    Offset Len  Description
    $00    1    Map bank
    $01    1    Map number
    $02    1    Person event number
    $03    4    Pointer to script start
    $07    4    Pointer to script end
    

    I may be wrong, but advancemap (an editing tool) may tell us if Norman at petalburg gym has something to do with "33 08 01 01"

    EDIT 2:

    After comparing USA save after transfering enigma berry with e-reader:

    Section 2: 0x41A bit 0 has been set (changed from 0x00 to 0x01) --> maybe this is the flag that triggers norman to give an enigma berry

    Section 4: 0x2E0 - 0x80F e-Card Berry data inserted.

    There's no more changes, gonna see if that bit in section 2 really is a flag for enigma berry.

  15. Uh,? But... I already know how to make scripts for gen 3, there's plenty tutorials and documentation out there (and inside the game). I want to check morfeo codes because I'm curious about them, for the scripts I mentioned I want to do I don't need to steal anyones work.

    Ps: did I mention the official give egg event has already been added and works wonders?

  16. OK, current feature list and a little todo list:

    * export/injectWC3 to all games (woncercards)

    * export/inject WN3 to all games (wondernews)

    * export/inject trainers to all games (it is the same offset for jap/international, no difference with what an e-reader does to the savefile)

    * export mistery event+script for RS/E (not sure about the uses for emerald, same changes when injected with e-reader and with changes via official nintendo Italy and taka's tools)

    * enable eon ticket in emerald the same way as taka's tool does (not legit in anything else than JAP)

    * enable mistery event and mistery gift in the save (just for convenience, but in-game enabling is recommended)

    * Editors for WC3 (eng), WN3 (eng), trainer and mistery event (can modify item and cuantity, as well as change the script)

    * Secret base decoration editor (I would need someone to test with JAP RS and emerald, but should be the same) --> this can be used to get the regi dolls, changes in the save are the same as when using the e-reader card.

    * fix checksums and also export a "sorted" current save and old save for easy hex compare

    To do:

    * Investigate how enigma berry works (luckily, we have the e-cards, should be easy. The best would be that only the e-berry data is put in the save)and make an editor (structure already researched before, so easy to do)

    * Export trainer as vpk for e-reader savegame injection? Ideally I may be able to export as e-reader save... but maybe there would be copyright problems?

    * WC3 Editor:

    - add the give egg experimental script from the roms and allow customizing pokemon and move (all languages, Emerald and FRLG, maybe would work on RS?)

    - allow to unset the flag that gets set by the give gg script

    - add custom give egg script that kills itself and allows customizing all 4 moves, met location and maybe something else? (only english, Emerald and FRLG, maybe would work on RS?)

    - add custom configurable give pokemon script (only english, Emerald and FRLG, maybe would work on RS?)

    - add custom configurable give item script (only english, Emerald and FRLG, maybe would work on RS?)

    * Check what morfeo codes actually do to the savegame (specially for trainer, berry and regi dolls events), also check what the scripts do.

    * Check trainer card, trainer survey and stamp card scripts, see what they were intended to do and if we can do something with them.

    * Create wc3 files for altering cave event for all languages using the rom script.

    About mistery event in emerald: I would need to make sure about the offsets/sizes, since there was no event done on emerald, we don't know were the script is supposed to be activated. Maybe they scrapped the mistery event scripts (eon ticket does not have a script, but a flag is enabled and an in-game event starts) and enigma berry occupies the place of the script. Are there enigma berry e-cards for emerald?

  17. I've compared the Eon ticket + Emerald aurora ticket before and after savefiles.

    It seems nintendo re-saved at pokemon center before eon ticket injection. It seems like their protocol to inject the events tells them to go to the nearest pokemon center, get to that certain spot and save, then inject the WC.

    In any case, differente before-after the card is given is exactly the same we are doing with an artificial injection (script+ wondercard, script+item).

    That means that, for the legit events collected, injecting the wc/eon ticket has the same output as nintendo.

    It would be really awesome if we could get all legit events (specially eon ticket scripts) trough nintendo italy!

    Has anyone contacted nintendo america? Maybe someone could get Mystic ticket this way.

    ps: jap support for wondercard/wondernews fully working now :)

    EDIT: I had hope the text in italian eon ticket script would be the same as in the debug rom, but nope :( (https://projectpokemon.org/forums/showthread.php?46883-GEN-3-Mystery-Gift-Research&p=209331&viewfull=1#post209331)

  18. Great! You don't have a backup before the trade then? Anyways, the sectionr regarding wondercard data should be untouched even if you made a trade (I guess).

    BTW, I noticed pkhex already had gen 3 language functions, both for international and japanesse encoding, so I've switched to its functions and I have jap support for wondercard editing with no effort :P

×
×
  • Create New...