Alpha Posted January 22, 2011 Author Posted January 22, 2011 I'm not looking at any scripts right now, but I'm pretty sure that you need to have a post-battle handler. It ends up being something where if you lose, you go to the pokemon center and whatnot. You probably should take a look to see if you can find another double battle to copy that data. There's a good example in the Dragon's Den with the rival, Claire, and Lance.
basher11 Posted January 22, 2011 Posted January 22, 2011 i've checked that example before, and it looks difficult to reproduce. it has a lot of script thingys and functions.
aninymouse Posted January 23, 2011 Posted January 23, 2011 Haha, well, just because it's difficult doesn't mean it's impossible. At least you have something to go by!
basher11 Posted January 23, 2011 Posted January 23, 2011 ok, i looked it up, and it seems that it uses functions heavily. i need a tutorial or something for this >_>
Roihu Posted January 23, 2011 Posted January 23, 2011 Question: Why does the Double Battle have 3 numbers? (Not counting 1) Which one of them are the trainers?
basher11 Posted January 23, 2011 Posted January 23, 2011 737 736 735 1 1st number is partner and the other 2 are opponents.
Team Fail Posted August 13, 2011 Posted August 13, 2011 Ok. I can't seem to save my scripts, so I opened it in an older version of PPRE. This is what it looks like in PPRE Beta 10b (It's a backup version in case the newer version freezes on use of movements) : ===scr_0 PlaySound 0x5dc Setvarhero 0x1 Setvarrival 0x2 Lockall Faceplayer Message 0x0 Closemsgonkeypress Applymovement 0x0 mov_0 Waitmovement Message 0x1 Closemsgonkeypress Faceplayer Message 0x2 Yesnobox 0x800c If 0x800c 0x1 COMPARELASTRESULT 0x1 func_0 Jump func_2 ===scr_1 PlaySound 0x5dc Lockall Faceplayer Message 0xa Waitbutton Closemsgonkeypress Releaseall End ===scr_2 PlaySound 0x5dc Lockall Faceplayer Message 0xb Waitbutton Closemsgonkeypress Releaseall End ===scr_3 PlaySound 0x5dc Lockall Faceplayer Message 0xc Waitbutton Closemsgonkeypress Releaseall End ===scr_4 End =mov_0 Seeleft 0x1 003F 0x1 End =mov_1 Walkrightfst 0x5 Walkupfst 0x1 Walkrightfst 0x6 003F 0x4 Walkleftfst 0xb Walkdownfst 0x1 End ==func_0 Releaseall End ==func_1 Message 0x3 Yesnobox 0x800c If 0x800c 0x1 COMPARELASTRESULT 0x1 func_0 Jump func_2 ==func_2 Message 0x4 Applymovement 0x0 mov_2 Waitmovement Faceplayer Message 0x5 Closemsgonkeypress Releaseall End When I save it, I get this in PPRE.log: Traceback (most recent call last): File "ppre.pyw", line 2110, in updateMap UnboundLocalError: local variable 'e' referenced before assignment When I edit it in the latest version, I put this in: scr_1 Fanfare 1500 Setvarhero 1 Setvarrival 2 Lockall Faceplayer Message 0 CloseMsgOnKeyPress Applymovement 0 mov_1 Waitmovement Message 1 CloseMsgOnKeyPress Faceplayer Message 2 Yesnobox CheckLR 1 func_1 Jump func_2 func_1 Message 3 Yesnobox CheckLR 1 func_1 Jump func_2 func_2 Message 4 Applymovement 0 mov_2 Waitmovement Faceplayer Message 5 CloseMsgOnKeyPress Releaseall End But when I save it, I get this: Traceback (most recent call last): File "ppre.pyw", line 2274, in updateMap File "ascript.pyc", line 484, in writeScript IndexError: sequence index out of range And it reverts back my script (Not saving) and deletes my functions. Is there anything wrong with my script? And if you need it, here are the text strings: text_0="Oh, \v0103\z0001, is it?\rI’ve been expecting you.\r" text_1="My name is Prof. Birch. I am\na Pokémon researcher.\rI saw that you moved here yesterday.\rI was compelled to give you a Pokémon,\nseeing as your dad is\x25BDa gym leader.\rEver since the arrival of \v0103\z0002,\nI’ve been wanting to see if I can\x25BDfind her someone to visit.\r" text_2="Now, let me ask you.\rWould you like to become friends\nwith Pokémon?\r" text_3="Well, that’s what I didn’t want\nto hear. Let me ask again.\rWould you like to become friends\nwith Pokémon?\r" text_4="Splendid! That’s what I want\nto hear!\r" text_5="I have three Pokémon here, Torchic,\nTreeko, and Mudkip.\rI want you to have all three.\r" text_6="\v0103\z0001 received the three Pokémon!\r" text_7="Prof. Birch: Okay. Now that you have\nsome Pokémon, why don’t you go\rbattle \v0103\z0002?\nShe might have some fun with you.\r" text_8="The Professor spends his time\ndoing field work.\r...What is it?\rIt’s when you go out in\nthe world and experience things\rinstead of reading it out of\na book.\rIt’s his idea of studying." I did find this thread after some searching, and I didn't see any thread revival rules, so I am sorry if there are any.
†Nømura Posted July 18, 2013 Posted July 18, 2013 (edited) I'm sorry about bumping this thread, but I thought it would have been worst if I opened a new topic for this question. I've got a problem with an event. I use a trigger to start the event. MecScript SetvarHero 0 Lockall SwitchMusic 0 3 Callstd 249 7 SetOverworldPosition 4 965 0 267 2 CheckLR 5 func_7 End Applymovement 4 mov_29Waitmovement Message 25 WaitButton CloseMsgOnKeyPress TrainerBattle 354 0 1 Message 26 WaitButton CloseMsgOnKeyPress Applymovement 4 mov_30 Waitmovement End If i test it, the game crashes as soon as I step on the trigger. But what's weird is that if i erase the messages commands it works. It happened even with other scripts i made. It looks like if I add a message on a trigger script the game freezes on the applymovement. What can i do about it? Edited July 26, 2013 by †Nømura
DragonNight Posted October 15, 2014 Posted October 15, 2014 Can someone explain why flags doesn't works here? Map: 34 - Route 30 Script 11 Fanfare 1500 Lockall Faceplayer Checkflag 310 -- check flag value and store it in Last Result CheckLR 1 func_4 -- case be 'false or 1' (I believe) func_4 will be called Message 4 -- I’m not a Trainer. But if you look one in the eyes, prepare to battle. WaitButton CloseMsgOnKeyPress Releaseall End I've changed this script for test, below the func_4 Message 0 -- Go, RATTATA! Tackle! WaitButton CloseMsgOnKeyPress Setflag 310 -- set the flag Releaseall End What I've done here was if flag 310 is not checked or set value 1 the function 4 will be called and the message 0 will be showed. When the script is runned again, the checkflag must put 0 (or a diferente value I believe) in LR and the function must not be executed, instead the message 4 will appear. But when I talk to girl, she only says "Go, RATTATA! Tackle!" like if the flag isn't be setted in function 4: Someone here can show me a light how flags works in the right way?
ZephyrosDS Posted February 4, 2015 Posted February 4, 2015 So I'm coming along with my Spirit Silver hack pretty nicely and I have implemented a lot of new content, as well as, many new trainer battles. One such being able to fight a Battle Frontier Brain early on. He blocks the gym from being used and you must battle him before entering as a test (per se). Now I have scripted this whole scenario. He will walk away from the gym and not block your path however when you exit the map and go back in he reappears. Now I know this issue can be solved by using Flags but I am not quite sure how to utilize Flags in this instance. PPRE gets rid of my flag when I add it onto the script. (I would go to another map on PPRE to edit, then come back and it will have been removed). So my question is, How do you use Flags in PPRE correctly for Pokemon Soul Silver? This is my script. Lockall Faceplayer Message 28 WaitButton CloseMsgOnKeyPress TrainerBattle 80 0 1 CheckTrainerLost 0x800c If 0x800c 0 Message 29 WaitButton CloseMsgOnKeyPress Applymovement 13 mov_7 Waitmovement Removepeople 13 Releaseall End
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now