• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
  • Our weekly protagonist poll is now up! Vote for your favorite Trading Card Game 2 protagonist in the poll by clicking here.
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

Help Thread: Script Help Thread

Status
Not open for further replies.
Close I guess I will explain it in more detail.

EDIT: Also I know I can use flags for this but I was almost certain I could just use the function that JPAN added in his fire red hack applier to make it so I didn't have to use flags.

When you first walk past a trainer he will walk up to you like normal, however what battle happens depends on what badge you have (Those are the variables I have set). If you have one badge then it will play the first battle, if you have two badges it will play the second battle and if you have three badges it will play the third battle.

Once you battle the trainer and win, great you will never battle that trainer again. You can walk up to him and talk to him and he will say a little "Oh you beat me" type of deal (I just made that talking 3 in my script). However if you lose to him, when you walk by he will want to battle you again.

It's the exact same as a normal trainer in the game but this time it will change the difficulty depending on your progress in the game.

Okay. I'm afraid I can't really help you with the FR engine part, I scarcely used it. Also, as you say, this is just like trainer battle, except with badge checks, so I think they are only thing you really have to check. Also, use the badge flags instead of variables. Wastes less space and we'll, they're already in the game, so why make aup a whole new variable for them?
 
Okay. I'm afraid I can't really help you with the FR engine part, I scarcely used it. Also, as you say, this is just like trainer battle, except with badge checks, so I think they are only thing you really have to check. Also, use the badge flags instead of variables. Wastes less space and we'll, they're already in the game, so why make aup a whole new variable for them?

Because the whole point of this is because I want to make it possible for the player to beat the first three gyms in any order. However thanks for trying! I guess i'll play around with it a bit more!
 
I Also need bit of help i want to design following scripts can u help me...

1) a quiz where u answer correctly and get a item or pokemon

2)person blocking road and disappear when u get 2 badges

3)2nd rival

4) more pokemon to be given as starters

Thank You :D
 
I Also need bit of help i want to design following scripts can u help me...

1) a quiz where u answer correctly and get a item or pokemon

2)person blocking road and disappear when u get 2 badges

3)2nd rival

4) more pokemon to be given as starters

Thank You :D


I'm afraid this is the help thread, not a request thread. If you'd like to learn scripting have a look at diegoisawesome's XSE scripting tutorial in the tutorials section! It's very helpful, will help you make these scripts above and more.
 
Spoiler:


This was working before when I did it. (Had to repeat this many times as I am an idiot and do not make backups regularly), but now it just freezes when I talk to the guy. I use the same exact script. What is wrong?
 
Spoiler:


This was working before when I did it. (Had to repeat this many times as I am an idiot and do not make backups regularly), but now it just freezes when I talk to the guy. I use the same exact script. What is wrong?

it doesn't look like there's any obvious errors but I would change the flag you're using. Any flag above 900 is not safe to use (unless you're using a flag expansion hack) and could be what's causing the problem.
 
I know we can create a sprite dynamically using the createsprite command.

My question is how to control the created sprite with a script ?
 
it doesn't look like there's any obvious errors but I would change the flag you're using. Any flag above 900 is not safe to use (unless you're using a flag expansion hack) and could be what's causing the problem.

I actually figured out my problem. The ID was the same as Oak's. Making it freeze and when I went to the wild area, he showed up instead of Oak.
 
Several days ago I intended to improve my level script written last time, but I encountered a problem that an "applymovement" event did not occur.

The move script was @move8 in the following level script: (As we all know, the level script is type2) (As @move8 didn't occur, @move9 also wouldn't occur, which was designed to be associated with @move10. (Looks like the 0xA(10) OW leading the player))


Spoiler:


And of course there's also a type3 level script about movesprite2)

Spoiler:

The flags of OWs will be cleared outside the cave.
I hope somebody could help. Great thanks.
 
Spoiler:

I am guessing that NPC #A is still offscreen before @move8, right? If that's the case, then NPC #A is possibly too far for the script to include him/her/it.

Spoiler:


An NPC should only be around 1 to 6 (or 7) tiles vertically away from the center of the screen for a script to include them. Counting the down steps in @move8, there are 8 and more, possible beyond the reach of the script to include NPC #A. :/
 
I am guessing that NPC #A is still offscreen before @move8, right? If that's the case, then NPC #A is possibly too far for the script to include him/her/it.

Spoiler:


An NPC should only be around 1 to 6 (or 7) tiles vertically away from the center of the screen for a script to include them. Counting the down steps in @move8, there are 8 and more, possible beyond the reach of the script to include NPC #A. :/

Thank you greatly, DJG! The bug was fixed! You are really a veteran hacker!
Another question1: Would you please tell me how do you get that piece of information or just simply tell me the crossrange limit? I have never seen this in any of script tutorials.
Another question2: What's the difference between movesprite & movesprite2? The script didn't work if I use movesprite instead of movesprite2.
It will be appreciated if you could answer these two questions. :D
 
Thank you greatly, DJG! The bug was fixed! You are really a veteran hacker!
Another question1: Would you please tell me how do you get that piece of information or just simply tell me the crossrange limit? I have never seen this in any of script tutorials.
Another question2: What's the difference between movesprite & movesprite2? The script didn't work if I use movesprite instead of movesprite2.
It will be appreciated if you could answer these two questions. :D

Well, for 1, through trial and error. *shrugs*
For 2, I dunno as well. :/ Someone else who's more knowledgeable should be able to answer that question.
 
Well, for 1, through trial and error. *shrugs*
For 2, I dunno as well. :/ Someone else who's more knowledgeable should be able to answer that question.

Oh, that's really disappointing. Anyway, thank you very much for solving my problem. :) (I'm a foreign fan of your ruby destiny series, looking forward to your future progress on Broken Timeline!)
 
Well, for 1, through trial and error. *shrugs*
For 2, I dunno as well. :/ Someone else who's more knowledgeable should be able to answer that question.

Oh, that's really disappointing. Anyway, thank you very much for solving my problem. :) (I'm a foreign fan of your ruby destiny series, looking forward to your future progress on Broken Timeline!)

I'm not more knowledgeable than, jagold, because he's the great Ruby Destiny Creator!!, but I can answer question 2. According to XSE's command help, if you use movesprite2, it will be there ... permanently.
 
I'm not more knowledgeable than, jagold, because he's the great Ruby Destiny Creator!!, but I can answer question 2. According to XSE's command help, if you use movesprite2, it will be there ... permanently.

Actually I have sought XSE's command help for information and I have known that movesprite2 is a "permanent" one. My problem is that I cannot thoroughly understand what it really means. Anyway, thank you for your help. :D
 
Actually I have sought XSE's command help for information and I have known that movesprite2 is a "permanent" one. My problem is that I cannot thoroughly understand what it really means. Anyway, thank you for your help. :D
It should mean that it will permanently stay on the new position even if you leave and re-enter the map.
 
What's the script in firered that checks if the player pressed A in Left, Up, Down, or Rigjt
 
Well, for 1, through trial and error. *shrugs*
For 2, I dunno as well. :/ Someone else who's more knowledgeable should be able to answer that question.

Hello, DJG! If you have spare time, could you please help me with my new script problem?
Here's my code(Not a level script)
Spoiler:

As the movements and strings worked, I didn't give it out. My problem was that some of the "setmaptile" command didn't work (Their y-axis values are relatively smaller) .Could you please tell me why? Maybe the map fail to load them in time?
 
Hello, DJG! If you have spare time, could you please help me with my new script problem?
Here's my code(Not a level script)
Spoiler:

As the movements and strings worked, I didn't give it out. My problem was that some of the "setmaptile" command didn't work (Their y-axis values are relatively smaller) .Could you please tell me why? Maybe the map fail to load them in time?

I did a quick check on it (currently busy at work :P).
Anyway...

Code:
...
setmaptile 0xB 0x14 0x282 0x1
special 0x8E
applymovement 0x1 @move3
applymovement 0xFF @move4
[I][COLOR="Red"](no waitmovement command)[/COLOR][/I]
special 0x136
setmaptile 0x8 0x10 0x282 0x1
...

Code:
...
pause 0x30
setmaptile 0xD 0xE 0x281 0x1
special 0x8E
[I][COLOR="Red"]waitmovement 0x0 (<— what is this doing here? o.o)[/COLOR][/I]
special 0x136
...

I am unsure of those two I've pointed out will fix your issue. :/
 
I did a quick check on it (currently busy at work :P).
Anyway...

Code:
...
setmaptile 0xB 0x14 0x282 0x1
special 0x8E
applymovement 0x1 @move3
applymovement 0xFF @move4
[I][COLOR="Red"](no waitmovement command)[/COLOR][/I]
special 0x136
setmaptile 0x8 0x10 0x282 0x1
...

Code:
...
pause 0x30
setmaptile 0xD 0xE 0x281 0x1
special 0x8E
[I][COLOR="Red"]waitmovement 0x0 (<— what is this doing here? o.o)[/COLOR][/I]
special 0x136
...

I am unsure of those two I've pointed out will fix your issue. :/

Errrr, actually I moved the "waitmovement" command to the end of the 10 "setmaptile" commands so I think it isn't a problem. I wanted to make the maptile change along with the 2 movement and the earthquake.
 
Status
Not open for further replies.
Back
Top