View Single Post
  #23708    
Old February 4th, 2013 (03:29 PM).
FBI agent's Avatar
FBI agent
If my PM box is full, VM instead :x
 
Join Date: Jan 2013
Location: Unknown Island
Gender: Male
Quote originally posted by Zanny77:
Hey everyone!
I started scripting 4 years ago(!) when I was working on a hack, but ended up leaving it because of other issues.
I'm back and trying to work on a new hack with my girlfriend, and I'm trying to remember how to script.
Here is my script:
Spoiler:

#dynamic 0x2D538A
#org @start
lock
faceplayer
checkflag 0x888
if 0x1 goto @done
msgbox @1 0x6
release
end

#org @1
= Vivian's House. \p...What's this?
givepokemon 0x25 0x5D 0x0 0x0 0x0 0x0
fanfare 0x13E
msgbox @3 0x4
waitfanfare
closeonkeypress
setflag 0x888
msgbox @4 0x5
compare LASTRESULT 0x1
if 0x1 call @name
release
end


#org @name
call 0x1A74EB <- What's this? :O
return

#org @3
= [blue_fr]IT'S A\nHAUNTER!

#org @4
= [blue_fr]Give this dood\na name?

#org @done
msgbox @2 0x6
release
end

#org @2
= Vivian's House.

and I think it looks good, and I think I compiled it right, but when I go in game I get nothing when I click on the mailbox. I don't know if there was a problem compiling it or putting the offset in AdvanceMap (the dynamic offset in the script and the AdvanceMap script are the same). Can someone help me out? I also am not sure about how to properly compile, I just batch compile each time and it says it gets saved. Help!
The part of your script I bolded goes after the green part, and the orange stuff are things that I think is wrong. Red are changes I made. Look at the spoiler in the quote for the script.
__________________
...

My name forum name is FBI Agent, though you can call me FBI because it's shorter.

Some of my stuff:
ASM request/resource thread
ASM tutorials thread
ASM Workshop