The PokéCommunity Forums

The PokéCommunity Forums (https://www.pokecommunity.com/index.php)
-   Binary Hack Tutorials (https://www.pokecommunity.com/forumdisplay.php?f=66)
-   -   Sierra's MEGA-HUGE XSE Scripting Tutorial (https://www.pokecommunity.com/showthread.php?t=164276)

mattattack February 9th, 2010 5:59 PM

I have some questions:

1. What exacly IS a variable and what does it do

2. How to you make a script where the player stops and a person moves towards him (I would also like to know about those green script tiles i a-map and how you trigger them)

Skull Guardian February 12th, 2010 10:55 AM

Script?
 
Hello, I read your tutorial and tried to make a script with it. Here it is:

Quote:

#dynamic 0xE3D080

#org @start
lock
checkflag 0x828
if 0x1 goto $done
faceplayer
msgbox $begin 6
applymovement 0x02 $move
waitmovement 0x0
msgbox $mom 6
givepokemon 0x133 0x5 0x371 0x0 0x0 0x0
fanfare 0x13E
msgbox $evee 6
waitfanfare
closeonkeypress
setflag 0x828
msgbox $name 5
compare LASTRESULT 0x1
if 0x1 gosub $nameapp
applymovement 0x02 $back
waitmovement 0x0
release
end

#org $done
release
end

#org $begin
= \h01\!

#org $move
#raw 0x01
#raw 0x56
#raw 0x05
#raw 0x30
#raw 0x01
#raw 0xFE

#org $mom
= Hello my son.\n\Where are you \l\going? \p\...\p\...\p\Oh.\p\You want to\n\go on an \l\adventure?\p\Well, I guess\n\you will need\l\a pokemon,\p\right? Don't\n\look so\l\suprised! I\p\ knew you\n\would also go\l\someday.\p\So, here!

#org $evee
= You received \n\an Evee!

#org $name
= [black_fr]Would you like to give a\n\nickname to Evee?

#org $nameapp
call 0x1A74EB
return

#org $back
#raw 0x08
#raw 0x2F
#raw 0xFE
So, I tried to compile it. After a few minor errors, I did, but it said this:
Quote:

Not enough free space found. Cannot compile.
I don't get it. I thought that the offset didn't have space, but even 10,000 bits didn't work. Can you please help me??

Muffin™ February 12th, 2010 11:54 AM

Quote:

Originally Posted by Skull Guardian (Post 5544933)
Hello, I read your tutorial and tried to make a script with it. Here it is:



So, I tried to compile it. After a few minor errors, I did, but it said this:

I don't get it. I thought that the offset didn't have space, but even 10,000 bits didn't work. Can you please help me??

Do you have FSF? Maybe that can help you.


EDIT: Pokescript? This is a tutorial for XSE. I recommend downloading XSE in Hackmew's ToolBox to get XSE.

Quote:

Originally Posted by mattattack (Post 5537844)
I have some questions:

1. What exacly IS a variable and what does it do

2. How to you make a script where the player stops and a person moves towards him (I would also like to know about those green script tiles i a-map and how you trigger them)


*cough* Look up ApplyMovement *cough*

simdu68 February 12th, 2010 11:58 AM

wow!! its really very well explained! congrats^^
i think i know now much more than before about scripting :D
but its stil very complivated, i think i'll not at once be able to script without reading your tutorial in the same time^^

thanx anyway :D

Skull Guardian February 13th, 2010 1:37 AM

Tried that
 
Quote:

Do you have FSF? Maybe that can help you.
Well, I do and thats where the dynamic offset is from.
Again, it says not enough free space, so could you please tell me how to fix that?


Quote:

EDIT: Pokescript? This is a tutorial for XSE. I recommend downloading XSE in Hackmew's ToolBox to get XSE.
Well, this is from XSE, but I also use pokescript commands so could you also tell me if this is a wrong script for XSE? I didnt really figure out how to use pokescript in the first place...

altariaking February 14th, 2010 9:06 AM

what command do i use in a movement script so that a sprite disappears forever?

Buizark February 14th, 2010 2:15 PM

Just use hidesprite after the movement.

mikocoon February 15th, 2010 4:15 AM

rokrdude,thanks for the values it really helped

Satoshi Ookami February 15th, 2010 9:11 AM

Quote:

Originally Posted by altariaking (Post 5550646)
what command do i use in a movement script so that a sprite disappears forever?

setflag 0x(variable number from 1 to 3FFF)
And the same number must be put into ID bar of person in A-Map

Reygok February 16th, 2010 6:57 AM

I want a picture of Charmander showing up. With 'showpokepic', it works but the Pic is Black and Blue! Charmander looks cool in Black, but it's not what I want xD How can I solve this?
It's the same case with Mudkip and Bulbasaur, but only the one I click first in the game, the other ones are normal then.

And I really don't know which flags to take! All the ones I choose seem to be already taken by the game, because when I enter the Pokémon Menu, the flags are cleared again! So, in Pokémon Sapphire, which Flags are free??

BurnNBlast February 18th, 2010 3:22 PM

Is there a limitation to how much text you can put on a single chat box?
I did
Spoiler:
Conium: Ahh [player], you\nknow what day it is today?\pOf course you do! It's the day\nI said I'd give you your first\npokemon!\pHere you go.

But it only goes up the " said I'd give you your first"
Is it some type of limitation of how many \n and \p I can use in a single box?

Reygok February 19th, 2010 2:43 AM

No, there is no limitation as such, because I have Textboxes 5 times longer than yours and they work. Your problem is only that your offset has not enough space. I'm pretty sure when you open your script, you'll see that your text disappeared, at least that part which is missing.
You'll have to put this at the beginning of your script:
#dynamic 0x800000
#org @start (you can replace start by anything you want)

Then replace the offset of your incomplete textbox with @text or something like that, and rewrite the textbox.

Then compile the script and put he new offset of '@start' in A-Map. Then it should work.

Darkerm February 19th, 2010 5:00 AM

How make a triner who will give me a pokemon or item after battle. Please help me. I am learning scripting.

Satoshi Ookami February 19th, 2010 5:46 AM

Quote:

Originally Posted by Darkerm (Post 5564595)
How make a triner who will give me a pokemon or item after battle. Please help me. I am learning scripting.

You must put this command to your script.
trainerbattle 0x1 0x(number of trainer) 0x0 @before (msgbox of what trainer says before battle) @after (offset of what will happen after battle)

#org @after
Put here giveitem, givepokemon or whatever you want ;)

Here's example
Spoiler:
#dynamic 0x800000
#org @start
trainerbattle 0x1 0x5 0x0 @before @after
msgbox @1 0x6
release
end

#org @after
msgbox @2 0x6
givepokemon/item command
release
end

And strings of msgboxes ;)

Reygok February 19th, 2010 9:49 AM

Quote:

Originally Posted by Reygok (Post 5556912)
I want a picture of Charmander showing up. With 'showpokepic', it works but the Pic is Black and Blue! Charmander looks cool in Black, but it's not what I want xD How can I solve this?
It's the same case with Mudkip and Bulbasaur, but only the one I click first in the game, the other ones are normal then.

And I really don't know which flags to take! All the ones I choose seem to be already taken by the game, because when I enter the Pokémon Menu, the flags are cleared again! So, in Pokémon Sapphire, which Flags are free??

Nobody has an idea why this is happening? In other hacks i've played and of course in the original games, all of the pokepics showing up are diplayed correctly... Why does mine not :S

helloNL February 19th, 2010 3:19 PM

just use flags above the 1000

Matteron (96) February 19th, 2010 3:33 PM

Quote:

Originally Posted by Reygok (Post 5565157)
Nobody has an idea why this is happening? In other hacks i've played and of course in the original games, all of the pokepics showing up are diplayed correctly... Why does mine not :S

is your actual sprite correctly colored? check it in unlz

Reygok February 22nd, 2010 1:26 PM

I've got 2 problems:
First, every flag I set is unset again as soon as I leave the map or enter the pokémon menu or something.

Second, I have 3 Pokéball lying on a table, at the beginning of the game, the starters. I implemented a 'showpokepic' there, but my problem is that the first pokémon I select has alway messed up colours. It has nothing to do with the sprites themselweves, because I never edited them, and as I said, it's alway the first one I select, when I restart the game and select another, that on is messed up, but the others are normally displayed.

Hope somebody can help. Thanks in advance.

BBs0n February 22nd, 2010 1:43 PM

I've got a problem as well...

I'm busy with a script which will trigger an event.
During the event the script will move a sprite to the scene.
I'm trying to accomplish this with movesprite.

For some odd reason though, I can't move the sprite when it's too far away.
With too far away, I mean more than two tiles away from the screen.
When I place the sprite closer, it does work, when I place it further, it doesn't.

Code:

movesprite 0x03 0x10 0x0F


That's the command I use with there respective parameters. (I don't think the error is in there).

Here is the script, I haven't scripted the part after the first movesprite yet. Everything till the movesprite works!

Code:

#dynamic 0x800000

#org @start
lock
checkflag 0x50B
if 0x1 goto @done
checkflag 0x50C
if 0x1 goto @unav
playsong 0x0112 0x0
sound 0x21
applymovement 0xFF @1moveme
waitmovement 0x0
waitkeypress
sound 0x12
setdooropened 0x10 0x0E
doorchange
movesprite 0x03 0x10 0x0F
release
end

#org @done
release
end

#org @unav
msgbox @1 0x06
release
end

#org @1
= blabla

#org @1moveme
#raw 0x62
#raw 0x50
#raw 0x03
#raw 0xFE



Anyone who knows the solution? (I've been trying for over an hour now, and I'm out of solutions :()

Reygok February 23rd, 2010 11:34 AM

I have done the same thing, but simply with applymovement, and this works perfectly. You could try it that way.

An no one knows an answer to my question, 2 posts above... :(

Lanzar February 24th, 2010 2:22 PM

Hey, can someone help me with a little thing? I just wonder how I make a script where a trainer comes from like 4 steps right, and challenge you, then he/she leaves? Just like in the beginning of Pokémon ShinyGold, the first battle with Carlos.

Please help. ^^

Matteron (96) February 24th, 2010 5:21 PM

@Lanzar
Have you ever heard of applymovement??

Lanzar February 25th, 2010 12:05 AM

Quote:

Originally Posted by Matteron (96) (Post 5577793)
@Lanzar
Have you ever heard of applymovement??

Yeah, but I don't know how to put in a trainer battle script in an applymovement script. D:

Satoshi Ookami February 25th, 2010 5:52 AM

applymovement
trainerbattle 0x1 (The 1 is important) 0x(number of trainer) 0x0 @b4 @after

#org @after
Put applymovements here.

And you have to use tile script since you want movement before battle.

Lanzar February 25th, 2010 6:20 AM

Quote:

Originally Posted by Ash493 (Post 5578520)
applymovement
trainerbattle 0x1 (The 1 is important) 0x(number of trainer) 0x0 @b4 @after

#org @after
Put applymovements here.

And you have to use tile script since you want movement before battle.

Thanks! :D
Well, I'm kinda noob at this, but whats a tile script?


All times are GMT -8. The time now is 8:11 PM.


Like our Facebook Page Follow us on Twitter © 2002 - 2018 The PokéCommunity™, pokecommunity.com.
Pokémon characters and images belong to The Pokémon Company International and Nintendo. This website is in no way affiliated with or endorsed by Nintendo, Creatures, GAMEFREAK, The Pokémon Company or The Pokémon Company International. We just love Pokémon.
All forum styles, their images (unless noted otherwise) and site designs are © 2002 - 2016 The PokéCommunity / PokéCommunity.com.
PokéCommunity™ is a trademark of The PokéCommunity. All rights reserved. Sponsor advertisements do not imply our endorsement of that product or service. User generated content remains the property of its creator.

Acknowledgements
Use of PokéCommunity Assets
vB Optimise by DragonByte Technologies Ltd © 2023.