The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Fan Games > Binary ROM Hacking
Reload this Page Script How To Write a "Trade Script"? (Advance Map/XSE)

Notices
For all updates, view the main page.

Binary ROM Hacking Need a helping hand or just want to talk about binary ROM hacks? Get comments and answers to any ROM Hacking-related problems, questions or thoughts you have here.

Ad Content
Reply
 
Thread Tools
  #1   Link to this post, but load the entire thread.  
Old May 16th, 2020 (11:08 PM).
JustinCG2807 JustinCG2807 is offline
 
Join Date: May 2020
Posts: 2
Hello Community!

I started hacking Gen 3 games about a week ago. I already wrote many scripts. Some with the help of tutorials and some with the help of decompiling already existing offsets. Now I want to add a NPC in Pokémon Emerald who wants to Trade a Pokémon (I don't know which Pokémon to trade yet). I also decompiled an already existing offset of a NPC who wants to trade. But I don't know what exactly happens in this script. There are many setvar, copyvar and special commands. And I didn't see any numbers which specify the requested and given Pokémon...

Do anyone know how to write such a script? And can someone explain what all these commands cause?
Reply With Quote
  #2   Link to this post, but load the entire thread.  
Old May 17th, 2020 (8:47 AM).
Team Embrace's Avatar
Team Embrace Team Embrace is offline
Team Embrace Boss
 
Join Date: Jan 2019
Gender: Male
Nature: Jolly
Posts: 30
The trading scripts used by the game use assembly language (also called ASM) code to both verify you have selected the right Pokémon for trading and to set which Pokémon will be traded to you. I'm actually in the process of trying to unravel the trading script secrets as well. Until I figured it out you may want to take a look at this tutorial (https://www.pokecommunity.com/showthread.php?p=9775737). This will allow you to do a kind of trading in the game by letting you take a Pokémon from the players party and showing them another Pokémon which is then inserted into their party. But it does not check for a specific species of Pokémon and instead lets the player trade away any Pokémon they want.
Reply With Quote
  #3   Link to this post, but load the entire thread.  
Old May 17th, 2020 (1:28 PM).
kalarie kalarie is offline
 
Join Date: Jun 2008
Posts: 760
@JustinCG2807

In XSE, go to -> Help -> Guide -> Practical Classrom -> In-Game Trades. That section explains how to make a script for something like that;)
Reply With Quote
  #4   Link to this post, but load the entire thread.  
Old May 19th, 2020 (7:49 AM).
Team Embrace's Avatar
Team Embrace Team Embrace is offline
Team Embrace Boss
 
Join Date: Jan 2019
Gender: Male
Nature: Jolly
Posts: 30
Quote:
Originally Posted by kalarie View Post
@JustinCG2807

In XSE, go to -> Help -> Guide -> Practical Classrom -> In-Game Trades. That section explains how to make a script for something like that;)
@JustinCG2807 to follow the Guide in XSE you need a program to edit/add to the trades in your ROM.

Here's a link:
http://www.mediafire.com/?e6i197rjo2jp2jc
Reply With Quote
Reply

Quick Reply

Join the conversation!

Create an account to post a reply in this thread, participate in other discussions, and more!

Create a PokéCommunity Account
Ad Content

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 9:18 AM.