View Single Post
  #1335    
Old June 10th, 2009 (02:27 PM).
Quickster's Avatar
Quickster Quickster is offline
Dream or Drop?
 
Join Date: Oct 2007
Gender: Male
Nature: Quiet
Posts: 350
Quote originally posted by PI Hudson:
QUESTION: Is there a way to check if a pokemon is holding an item?




It works like this
-When you enter a map, it looks for level scripts
-In Oaks Lab, the script your looking for is #2
-If it is a #2 or 4 script, it looks at the Variable Flag (for this, it is 4055)
-It checks that this Variable for its Value (set previously, default is 0000) and if it isn't equal to the number given in the Map script, it doesn't activate. But if it is equal, it does activate.
(if MAP-VALUE>VAR-VALUE=not activate, if MAP-VALUE<VAR-VALUE=not activate, if MAP-VALUE=VAR-VALUE=activate)

In the script tile that we step on in Pallet Town to activate the script, we see this.


This means the next time we enter the Oaks Lab, the script will activate.

But, why doesn't it activate again?
In the Oaks Lab Level script, we observe this


This make it so you don't see this script again until the Var Value is equal again.

People kind of act the same way, but with flags.




Your welcome.

Ive been trying to make a script using this but its just not working. I can enter the area and it does the script,not supposed to do that.If i talk to the person and then warp to it, it doesnt work at all.
First is a person event.
Spoiler:

#dynamic 0x8006F3

#org @start
applymovement 0x8 @m1
msgbox @1 0x6
cry 0x11E 0x0
showsprite 0x9
applymovement 0x9 @m1
waitmovement 0x0
applymovement 0xFF @m2
waitmovement 0x0
warp 0xF 0x0 0x1 0x0 0x0
setvar 0x7000 0x1
release
end

#org @1
= POOCHYENA: Rawrr!

#org @m1
#raw 0x11
#raw 0x60
#raw 0xFE

#org @m2
#raw 0x11
#raw 0x11
#raw 0xFE

Second is a level script.
Spoiler:

#dynamic 0x8007D1

#org @start
LOCKALL
setvar 0x7001 0x1
setvar 0x7000 0x2
applymovement 0x4 @m1
applymovement 0x3 @m1
waitmovement 0x0
applymovement 0xFF @m2
waitmovement 0x0
warp 0x3 0x15 0x0 0x0 0x0
end

#org @m1
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x60
#raw 0xFE

#org @m2
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0x11
#raw 0xFE

It also continues to a third,which is another level script.
Spoiler:

#dynamic 0x80112A

#org @start
applymovement 0xFF @m1
waitmovement 0x0
msgbox @1 0x6
hidesprite 0xD
applymovement 0xE @m2
waitmovement 0x0
trainerbattle 0x1 0x001 0x0 @before @after @later
release
end

#org @before
= Is this your PIKACHU?\p......\pI see.\nMy POOCHYENA ran off when I ran\linto a bug POKeMON.\pBy the way, my name is SAM. Your\nPIKACHU looks like it wants to\lbattle, how bout it?\p...\pGreat, lets go!

#org @after
= You're pretty strong!

#org @later
hidesprite 0xC
msgbox @2 0x5
compare lastresult 0x1
if 0x1 gosub @give
msgbox @3 0x6
applymovement 0xE @m3
hidesprite 0xE
setflag 0x1006
release
end

#org @give
givepokemon 0x11E 0x4 0x0 0x0 0x0 0x0
return

#org @1
= Return, POOCHYENA!

#org @2
= That was a tough battle!\pI only lost because my POOCHYENA\nwent easy on you,heh heh...\pSince it seems to like you so\nmuch, how bout taking him for me?

#org @3
= Well, I'll be seeing you around\nthen!

#org @m1
#raw 0x11
#raw 0xFE

#org @m2
#raw 0x10
#raw 0xFE

#org @m3
#raw 0x13
#raw 0x13
#raw 0x13
#raw 0x13
#raw 0x13
#raw 0x13
#raw 0x13
#raw 0x13
#raw 0x13
#raw 0x13
#raw 0xFE
__________________
I laugh looking at this.

But sometimes I want to come back to it...