< >
Hello, guest! Please log in or register.

The PokéCommunity

Go Back     The PokéCommunity Forums > ROM Hacking > Tools, Tutorials & Resources Tutorial GBA ASM Programming

Notices

Tools, Tutorials & Resources Various tools to help you develop your hacks can be found here.
New threads in this forum are to be approved by a moderator before they are displayed.

Reply Post Reply
 
Thread Tools
  #51    
Old October 23rd, 2014 (10:33 AM).
eugarps eugarps is offline
 
Join Date: Oct 2014
Posts: 2
The Dropbox link seems to be broken. Could I get a mirror/email ([email protected])with the files? Thank you
Reply With Quote

Relevant Advertising!

  #53    
Old November 24th, 2014 (7:20 AM).
Volt-Ikazuchi Volt-Ikazuchi is offline
 
Join Date: Dec 2013
Gender: Male
Posts: 19
Just curious here, I would need to use ASM to block players from challenging certain trainers (Gym Leaders, Rivals) with pokémons above a certain level, right?
What if I need to block items during a certain battle?

I'm just starting out, so I wanted to make my first hack more simple to understand mapping and scripting better, but if I need ASM to get some level and item caps then I'll have to learn it as well.

Thanks for the tutorial, looks very interesting, I'll definitely read it later.
Reply With Quote
  #54    
Old November 24th, 2014 (8:27 AM).
FBI's Avatar
FBI FBI is offline
Very bias and unfair judge
 
Join Date: Jan 2013
Location: Unknown Island
Gender: Male
Posts: 1,125
Quote:
Originally Posted by Volt-Ikazuchi View Post
Just curious here, I would need to use ASM to block players from challenging certain trainers (Gym Leaders, Rivals) with pokémons above a certain level, right?
What if I need to block items during a certain battle?

I'm just starting out, so I wanted to make my first hack more simple to understand mapping and scripting better, but if I need ASM to get some level and item caps then I'll have to learn it as well.

Thanks for the tutorial, looks very interesting, I'll definitely read it later.
For blocking players from challenging certain trainers depending on party pokemon level you need some asm, but it's just function calls, nothing down and dirty.

For the item one, you'd need a battle script (look up Jambo's battle script tutorial/tool). Though admittedly, battle scripts are also very technical P:
...

Some of my stuff:
ASM request/resource thread
ASM tutorials thread
ASM Workshop
Pokémon Journeys
Reply With Quote
  #55    
Old November 26th, 2014 (7:48 AM).
Volt-Ikazuchi Volt-Ikazuchi is offline
 
Join Date: Dec 2013
Gender: Male
Posts: 19
Quote:
Originally Posted by FBI agent View Post
For blocking players from challenging certain trainers depending on party pokemon level you need some asm, but it's just function calls, nothing down and dirty.

For the item one, you'd need a battle script (look up Jambo's battle script tutorial/tool). Though admittedly, battle scripts are also very technical P:
Really? That's great news!

Mind to elaborate what asm routines I would need to do the level caps?
I really don't want to go in blind and break the game.
And are you saying that locking the items mid-battle require just some scripting? Can it be done in XSE or would I need Jambo's tool?

Thanks for the answers. Really helped.
Reply With Quote
  #56    
Old November 26th, 2014 (8:11 AM).
FBI's Avatar
FBI FBI is offline
Very bias and unfair judge
 
Join Date: Jan 2013
Location: Unknown Island
Gender: Male
Posts: 1,125
Quote:
Originally Posted by Volt-Ikazuchi View Post
Really? That's great news!

Mind to elaborate what asm routines I would need to do the level caps?
I really don't want to go in blind and break the game.
And are you saying that locking the items mid-battle require just some scripting? Can it be done in XSE or would I need Jambo's tool?

Thanks for the answers. Really helped.
Sure, for the prevention of player challenging trainers, it's 90% handled by the trainer script.

I would do this:
Code:
#dyn 0x740000
#org @start
lock
faceplayer
setvar 0x4011 0x[max level of trainer]
callasm 0x[asm that returns max pokemon level in party]
compare 0x4001 LASTRESULT
if > jump @ignore
trainerbattle 0x0 0xID 0x0 @intro @defeat
msgbox @afterwards
callstd MSG_NORMAL
release
end

#org @ignore
msgbox @noThanks
callstd MSG_NORMAL
release
end

#org @noThanks
= Sorry, you wouldn't be a\nchallenge to me!

#org @intro
= Battle started, say something

#org @defeat
= defeat text

#org @afterwards
= Nice battle.
For the item blocking, I have no idea. I think Jambo's tutorial on Battle scripts covers it iirc.
...

Some of my stuff:
ASM request/resource thread
ASM tutorials thread
ASM Workshop
Pokémon Journeys
Reply With Quote
  #57    
Old December 30th, 2014 (10:56 AM).
DizzyEgg's Avatar
DizzyEgg DizzyEgg is offline
 
Join Date: Feb 2014
Age: 18
Gender: Male
Nature: Quiet
Posts: 158
Some images in the tutorial are missing. Could someone upload them?
Reply With Quote
  #58    
Old January 2nd, 2015 (1:19 AM).
ZapdosMan's Avatar
ZapdosMan ZapdosMan is offline
The Principality
 
Join Date: Jun 2014
Gender: Male
Posts: 48
Wow I think this is a really good tutorial
though i find it hard to understand but finally someone posted a tutorial on this

Thanks

ZapdosMan
Feel free to add me to your friends list! Just send me a request :D
If anyone needs help with his or her hack, PM me, I will see to your request :0
Also i am making hack banners for people as long as they put me in their team as the "Banner Artist". I might not make the best banners but i put my heart and soul into it.

Hacks I am supporti:
Reply With Quote
  #59    
Old February 16th, 2015 (12:02 AM).
Sounak's Avatar
Sounak Sounak is offline
Black Charizard
 
Join Date: Oct 2014
Gender: Male
Nature: Careful
Posts: 6
The download link to your ASM pack is not working.
Can you re-upload it please.
Reply With Quote
  #60    
Old February 20th, 2015 (11:42 AM).
DizzyEgg's Avatar
DizzyEgg DizzyEgg is offline
 
Join Date: Feb 2014
Age: 18
Gender: Male
Nature: Quiet
Posts: 158
I have a problem with your first routine. Here's what I got http://i.imgur.com/obuckLm.png
My code:
Spoiler:
.align 2
.thumb
main:
push {r0-r1,lr}
ldr r0, pokemon_data
ldrh r0, [r0]
ldr r1, var
strh r0, [r1]
pop {r0-r1, pc}

.align 2
pokemon_data: .word 0x02024284 + 0x54
var: .word 0x20370D0

I also tried those ( 03 B5 02 48 80 88 02 49 08 80 03 BD 84 42 02 02 D0 70 03 02 ) assembled numbers and still got the same result. Why is this happening?
Reply With Quote
  #61    
Old February 20th, 2015 (1:15 PM).
GoGoJJTech's Avatar
GoGoJJTech GoGoJJTech is offline
http://GoGoJJTech.com (WIP!)
Gold Tier
 
Join Date: Nov 2012
Location: Earth
Age: 17
Gender: Female
Nature: Jolly
Posts: 2,362
Quote:
Originally Posted by DizzyEgg View Post
I have a problem with your first routine. Here's what I got http://i.imgur.com/obuckLm.png
My code:
Spoiler:
.align 2
.thumb
main:
push {r0-r1,lr}
ldr r0, pokemon_data
ldrh r0, [r0]
ldr r1, var
strh r0, [r1]
pop {r0-r1, pc}

.align 2
pokemon_data: .word 0x02024284 + 0x54
var: .word 0x20370D0

I also tried those ( 03 B5 02 48 80 88 02 49 08 80 03 BD 84 42 02 02 D0 70 03 02 ) assembled numbers and still got the same result. Why is this happening?
That routine seems to be a failure. You're trying to load the level but you're loading a halfword (two bytes).
Change "ldrh r0, [r0]" to "ldrb r0, [r0]"
Reply With Quote
  #62    
Old February 20th, 2015 (1:32 PM).
FBI's Avatar
FBI FBI is offline
Very bias and unfair judge
 
Join Date: Jan 2013
Location: Unknown Island
Gender: Male
Posts: 1,125
Quote:
Originally Posted by DizzyEgg View Post
I have a problem with your first routine. Here's what I got http://i.imgur.com/obuckLm.png
My code:
Spoiler:
.align 2
.thumb
main:
push {r0-r1,lr}
ldr r0, pokemon_data
ldrh r0, [r0]
ldr r1, var
strh r0, [r1]
pop {r0-r1, pc}

.align 2
pokemon_data: .word 0x02024284 + 0x54
var: .word 0x20370D0

I also tried those ( 03 B5 02 48 80 88 02 49 08 80 03 BD 84 42 02 02 D0 70 03 02 ) assembled numbers and still got the same result. Why is this happening?
Hi. If I'm understanding this correctly, you're trying to check the Pokemon's level (hence 0x02024284 + 0x54) ? Well a Pokemon's level is 0-100, which can be represented in hex as 1 byte (0x64 being 100)

Code:
    ldr r0, pokemon_data
    ldrh r0, [r0]
You're loading a half word (2 bytes) which is going to load something extra as well. Try ldrb instead of ldrh.
...

Some of my stuff:
ASM request/resource thread
ASM tutorials thread
ASM Workshop
Pokémon Journeys
Reply With Quote
  #63    
Old February 21st, 2015 (12:14 AM).
DizzyEgg's Avatar
DizzyEgg DizzyEgg is offline
 
Join Date: Feb 2014
Age: 18
Gender: Male
Nature: Quiet
Posts: 158
Quote:
Originally Posted by FBI agent View Post
Hi. If I'm understanding this correctly, you're trying to check the Pokemon's level (hence 0x02024284 + 0x54) ? Well a Pokemon's level is 0-100, which can be represented in hex as 1 byte (0x64 being 100)

Code:
    ldr r0, pokemon_data
    ldrh r0, [r0]
You're loading a half word (2 bytes) which is going to load something extra as well. Try ldrb instead of ldrh.
Quote:
Originally Posted by GoGoJJTech View Post
That routine seems to be a failure. You're trying to load the level but you're loading a halfword (two bytes).
Change "ldrh r0, [r0]" to "ldrb r0, [r0]"
It worked perfectly. Thank you!
Reply With Quote
  #64    
Old March 21st, 2015 (11:20 AM).
WishMaker004 WishMaker004 is offline
Dragon WishMaker
 
Join Date: Feb 2015
Gender: Male
Posts: 1
The link is broken, I'd love to try this out, could somebody post a working link or file? I'll give you my email if I have to.
Reply With Quote
  #65    
Old March 28th, 2015 (9:12 AM).
technickal's Avatar
technickal technickal is offline
 
Join Date: Sep 2014
Location: United States
Gender: Male
Nature: Relaxed
Posts: 69
To those talking about the broken link, I have a mirror for the compiler (but the compiler only):
https://cloud.openmailbox.org/public...021c95306a192e

Unova Pokémon are great. Got an Isshu with that?
Reply With Quote
Reply Post Reply
Quick Reply

Sponsored Links
Thread Tools

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 7:22 AM.


Contact Us Archive Privacy Statement Terms of Service Top