Well, coding for the party pokemon to use items will always cause some form of brain bending :p Simply because it always has to be able to write to the lists dynamically. Coding item usage for the battling pokemon is very easy though Smile
http://tifreakware.net/tifreak8x/pokemon/files/Pic3.8xi

Sadly, the code just errored out with a dimension error, I think. :<

I figured at this point, might be best for you to see what you need to do. As was stated before,


Code:
0->Xmin:0->Ymin
94->Xmax:62->Ymax


:< I know I must have misunderstood what you wanted me to change.

Edit:

Until we can figure out about getting this fixed (and seeing what this does, I'm still not sure what it is supposed to do :p) we shall use the firewall against pokemon for evolution. :p
I think Weregoose once lectured me that this is preferred:


Code:
0->Xmin:1->deltaX
0->Ymin:1->deltaY
My code implicitly assigns Xmin=-47, Xmax=47, Ymin=-31, and Ymax=31 – a mere geometrical translation from the window that PP uses. The only changes you would need to make is to exchange ZDecimal:ZInteger for your settings, and then to counter that by adding 47 and 31 to the respective X and Y drawing coordinates.

Code:
:U+.1V
:Pt-Off(47+AnsL1(31-V),31+AnsL2(31-V),2
:Pt-Off(47-AnsL1(31-V),31-AnsL2(31-V),2
:Else
:U-.1V
:Pt-On(47+AnsL1(V),31+AnsL2(V),2
:Pt-On(47-AnsL1(V),31-AnsL2(V),2


@Kerm: I haven't used that in ages!

Code:
:ZStandard
:84→Xmin
:52→Ymin
:ZInteger

This gives the same setup in five fewer bytes. Smile
Whoa, crazy. Shock That's a very handy trick; you never, ever cease to amaze and impress.


Now to move it into position Smile And figure out how to do a keypress in there to interrupt it..
Wait, how is it so fast? I just realized that it's un-erasing the sprite in super-fast speed.
tifreak8x wrote:


Now to move it into position Smile And figure out how to do a keypress in there to interrupt it..
Your evolvetest2.gif is redirecting back to evolvetest1.gif, so I'm afraid I'm seeing the same picture as in your October 10 post. Also, given the location of your Pokémon on the screen, part of my animation will probably be drawn outside of the region unless your sprite can be moved more towards the center.

Next, unless you're sprinkling in some library wizardry, I'll assume the preservation of the sprite while lines are erased is accomplished through a RecallPic. In that case, my code should also be fitted with one after the second Pt-Off( and before the Else.
*head desk repeatedly*

I KNOW I dropped that file in the screenshot folder last night :/ Why it wasn't there, I've no clue. Anyways, reuploaded, you should see it properly now.

le-sigh..


This shows what things look like when you cancel the evolution of a pokemon when you press the Alpha key.



And this is what I have so far of the completed evolution. I know the pokemon needs to be moved over a couple more pixels. But otherwise, what do you all think? Better than the firewall, huh? :p

Thank Weregoose for that.

Code:
If Tmin>0:Then:For(F,0,17:Line(0,F,94,F,0:End:"0ZBD":prgmZRS:{94,0,3,15:prgmTEMP:prgmZC1:Text(47,4,"CANNOT USE ITEM":Text(53,4,"DURING BATTLES!":prgmZWT:ClrDraw:1->W:End:If W=1:Return:
If Tmin=0:Then:"|LP"+sub("123456",Z,1)+"(43"->Str7:"ZTMP2"->Str0:4->theta:prgmZCE:"UnArchive |LP"+sub("123456",Z,1)->Str9:1->theta:1:prgmZCE:prgmZTMP2:expr(Str7)->K:"rowSwap(ZPMA"->Str0:0->theta:expr(Str7):prgmZCE:Str9->Str4:"rowSwap(ZPNA"->Str0:expr(Str7):prgmZCE:"0ZBD":prgmZRS:{94,0,3,15:prgmTEMP:prgmZC1:
34->I:15->J:Asm(prgmZSP2:StorePic Pic2:Text(47,4,"USED FIRE STONE!":rand(99:For(F,4,14:Line(4,F,90,F,0:End:Text(47,4,"WHAT?! ",Str9:Text(53,4,"IS EVOLVING!":
15->W

While W>5
W-5->W

6cumSum(binomcdf(29,0->L2
cos(Ans^^o->L1
sin(L2^^o->L2
For(X,0,1
For(U,15-15X,9X+3,6X-3
For(V,1,30
getKey->K:
If K=31:Then:ClrDraw
RecallPic Pic2:
For(F,4,14:Line(4,F,90,F,0:End:
Text(47,4,"AWW, ",Str9:
Text(53,4,"STOPPED EVOLVING!":prgmZWT:2->W:2->X
ClrDraw:6->theta:"ZTMP2"->Str0:prgmZCE:End
If X=1
Then
U+.1V
Pt-Off(47+AnsL1(31-V),37+AnsL2(31-V),2
Pt-Off(47+~AnsL1(31-V),37+~AnsL2(31-V),2
If W>5:RecallPic Pic2
End:If X=0:Then
U-.1V
Pt-On(47+AnsL1(V),37+AnsL2(V),2
Pt-On(47+~AnsL1(V),37+~AnsL2(V),2
End
End
End
End

End

If X=2:Return

(code here starts the dealings with evolutions)


This is mainly to show Weregoose the changes made to his code to make it work so I could cancel the evolution process.

Also, remember, this all ends up on one line in the end. :p
Nothing huge or big or otherwise. Took some time this weekend to update http://tifreakware.net/tifreak8x/pokemon/ss.php with all the screenshots that I never linked. There are now 109 screenshots linked on that page! Enjoy!

Code:
If Tmin>0:Then:For(F,0,17:Line(0,F,94,F,0:End:"0ZBD":prgmZRS:{94,0,3,15:prgmTEMP:prgmZC1:Text(47,4,"CANNOT USE ITEM":Text(53,4,"DURING BATTLES!":prgmZWT:ClrDraw:1->W:End:If W=1:Return:
If Tmin=0:Then:"|LP"+sub("123456",Z,1)+"(43"->Str7:"ZTMP2"->Str0:4->theta:prgmZCE:"UnArchive |LP"+sub("123456",Z,1)->Str9:1->theta:1:prgmZCE:prgmZTMP2:expr(Str7)->K:"rowSwap(ZPMA"->Str0:0->theta:expr(Str7):prgmZCE:Str9->Str4:"rowSwap(ZPNA"->Str0:expr(Str7):prgmZCE:"0ZBD":prgmZRS:{94,0,3,15:prgmTEMP:prgmZC1:
34->I:15->J:Asm(prgmZSP2:StorePic Pic2:Text(47,4,"USED FIRE STONE!":rand(99:For(F,4,14:Line(4,F,90,F,0:End:Text(47,4,"WHAT?! ",Str9:Text(53,4,"IS EVOLVING!":
15->W

While W>5
W-5->W

6cumSum(binomcdf(29,0->L2
cos(Ans^^o->L1
sin(L2^^o->L2
For(X,0,1
For(U,15-15X,9X+3,6X-3
For(V,1,30
getKey->K:
If K=31:Goto A
If X
Then
U+.1V
Pt-Off(47+AnsL1(31-V),37+AnsL2(31-V),2
Pt-Off(47+~AnsL1(31-V),37+~AnsL2(31-V),2
If W>5:RecallPic Pic2
Else
U-.1V
Pt-On(47+AnsL1(V),37+AnsL2(V),2
Pt-On(47+~AnsL1(V),37+~AnsL2(V),2
End
End
End
End

End
Goto B
Lbl A
ClrDraw
RecallPic Pic2:
For(F,4,14:Line(4,F,90,F,0:End:
Text(47,4,"AWW, ",Str9:
Text(53,4,"STOPPED EVOLVING!":prgmZWT:2->W:2->X
ClrDraw:6->theta:"ZTMP2"->Str0:prgmZCE
Return
Lbl B
DelVar Pic2
3->theta:prgmZCE
Str7+")+1"+sub(Str9,1,1)+Str7->Str9
1->theta:"ZTMP2"->Str0:1:prgmZCE:prgmZTMP2
"rowSwap(ZPMA"->Str0:0->theta:expr(Str7):prgmZCE
34->I:15->J:Asm(prgmZSP2
For(F,4,14:Line(4,F,90,F,0:End:
"rowSwap(ZPNA"->Str0:expr(Str7+")-1"):prgmZCE
Text(47,4,Str9," EVOLVED INTO"
expr(Str7):prgmZCE
Text(53,4,Str9,"!"
prgmZWT


So far, this is the code I have for the Fire Stone evolution. I added in a bit of code this morning to take it beyond the pretty animation courtesy of Weregoose, and hopefully it all works properly. I still need to add a value to the pokedex list to make the new pokemon show up. Problem is, I don't remember what value did what. I think I can get that information from the pokedex file I have hosted on ticalc/tifw.
Excellent, great to hear both about your progress and your screenshot organization. I'm sad to see that you didn't update the first post in this thread with your full set of screenies, unless I'm looking in the wrong thread.
I think anyone's connection/browser that tries to process 109 screenshots at once will most likely die and not like me anymore :p

And yes, can't wait to get done with this 'template' code so I can move on to more items being finished.
Then you should pick a few recent representative screenshots! And I agree with your latter sentiment.
Managed to get Fire Stone evolution working properly:



Now to go add some error checking to make sure it isn't just used on any pokemon to evolve.


Reduced the looping to just once, removed the need to recall the pic which sped things up. Checked and verified that exiting the loop still functions.
That looks amazing! I wonder if you could make it spiral in, then switch sprites while it's "covered", then reveal the new one as it unspirals?
Not without the assistance of ASM, since I'd have no way of storing the sprite to a pic var and recalling it as the spiraling reversed. At least, at this point, I'm not sure there's a way to do it.
  
Page 16 of 17
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement