This is an archived, read-only copy of the United-TI subforum , including posts and topic from May 2003 to April 2012. If you would like to discuss any of the topics in this forum, you can visit Cemetech's Your Projects subforum. Some of these topics may also be directly-linked to active Cemetech topics. If you are a Cemetech member with a linked United-TI account, you can link United-TI topics here with your current Cemetech topics.

This forum is locked: you cannot post, reply to, or edit topics. Final Fantasy => Your Projects
Author Message
Babyboy


Advanced Member


Joined: 11 Jun 2003
Posts: 499

Posted: 30 Sep 2005 04:33:54 pm    Post subject:

ok, here is the code to my first battle screen, the HP bars are handled by an equasion, right now they do the same thing but yea. the moving sword is kinda cool, and it doesnt skip like i though it might, so thats cool i think. the code is LONG though so thats a minus. i was thinking that maybe the pointer could change depending on what weapon you have, like an axe or something, what do you think? or maybe the sword should turn?


Code:
ClrDraw
ClrHome
Line(42,62,1,62
Line(42,58,1,58
Line(0,59,0,61
Line(43,61,43,59
Line(49,59,49,61
Line(50,62,93,62
Line(94,61,94,58
Line(93,58,50,58
Line(0,15,94,15
Line(0,12,94,12
Pt-On(0,14
Pt-On(2,14
Pt-On(4,14
Pt-On(6,14
Pt-On(8,14
Pt-On(10,14
Pt-On(12,14
Pt-On(14,14
Pt-On(16,14
Pt-On(18,14
Pt-On(20,14
Pt-On(22,14
Pt-On(24,14
Pt-On(26,14
Pt-On(28,14
Pt-On(30,14
Pt-On(32,14
Pt-On(34,14
Pt-On(36,14
Pt-On(38,14
Pt-On(40,14
Pt-On(42,14
Pt-On(44,14
Pt-On(46,14
Pt-On(48,14
Pt-On(50,14
Pt-On(52,14
Pt-On(54,14
Pt-On(56,14
Pt-On(58,14
Pt-On(60,14
Pt-On(62,14
Pt-On(64,14
Pt-On(66,14
Pt-On(68,14
Pt-On(70,14
Pt-On(72,14
Pt-On(74,14
Pt-On(76,14
Pt-On(78,14
Pt-On(80,14
Pt-On(82,14
Pt-On(84,14
Pt-On(86,14
Pt-On(88,14
Pt-On(90,14
Pt-On(92,14
Pt-On(94,14
Pt-On(1,13
Pt-On(3,13
Pt-On(5,13
Pt-On(7,13
Pt-On(9,13
Pt-On(11,13
Pt-On(13,13
Pt-On(15,13
Pt-On(17,13
Pt-On(19,13
Pt-On(21,13
Pt-On(23,13
Pt-On(25,13
Pt-On(27,13
Pt-On(29,13
Pt-On(31,13
Pt-On(33,13
Pt-On(35,13
Pt-On(37,13
Pt-On(39,13
Pt-On(41,13
Pt-On(43,13
Pt-On(45,13
Pt-On(47,13
Pt-On(49,13
Pt-On(51,13
Pt-On(53,13
Pt-On(55,13
Pt-On(57,13
Pt-On(59,13
Pt-On(61,13
Pt-On(63,13
Pt-On(65,13
Pt-On(67,13
Pt-On(69,13
Pt-On(71,13
Pt-On(73,13
Pt-On(75,13
Pt-On(77,13
Pt-On(79,13
Pt-On(81,13
Pt-On(83,13
Pt-On(85,13
Pt-On(87,13
Pt-On(89,13
Pt-On(91,13
Pt-On(93,13
Text(51,13,"ATTACK
Text(57,13,"BAGXOR
Text(57,50,"RUN!
Text(57,77,"INFO
Text(51,50,"MAGIC
randInt(1,2->O
If O=1
Then
{10,2,3}->L
Output(4,5,"RABBITY"
End

If O=2
Then
{100,50,12}->L
Output(4,5,"DEMIGOD"
End

If OSTAT(14)=3
Then
End


42/(OSTAT(2)/OSTAT(1))
Line(1,60,Ans,60
Line(1,61,Ans,61
Line(1,59,Ans,59


43/(OSTAT(2)/OSTAT(1))+50
Line(50,60,Ans,60
Line(50,59,Ans,59
Line(50,61,Ans,61


OSTAT(1)+1->OSTAT(1)
A->M
B->N
11->A
8->B

For(Z,5,9
While Z
getKey->O

Pt-On(A,B
Line(A-1,B+1,A-10,B+1
Line(A-1,B-1,A-10,B-1
Line(A-7,B,A-11,B
Pt-On(A-7,B+2
Pt-On(A-7,B-2

If O
Then
Pt-Off(A,B
Line(A-1,B+1,A-10,B+1,0
Line(A-1,B-1,A-10,B-1,0
Line(A-7,B,A-11,B,0
Pt-Off(A-7,B+2
Pt-Off(A-7,B-2

If O=26 and A=11
Then
48->A
0->O
End

If O=24 and A=48
11->A

If O=25 and B=2 and Aø75
8->B


If O=34 and B=8
2->B

If (O=26 and A=48 and B=2)
75->A

If (O=24 and A=75 and B=2)
48->A
End
End


YAY!

this will be in my file as soon as i remember my password/ how to use filezilla
Back to top
DarkerLine
ceci n'est pas une |


Super Elite (Last Title)


Joined: 04 Nov 2003
Posts: 8328

Posted: 30 Sep 2005 04:39:47 pm    Post subject:

For the pt-on('s:

For(I,0,94
Pt-On(I,13+not(fPart(I/2
End

Or if you want to preserve the effect of the top part being drawn first

For(I,0,94,2
Pt-On(I,14
End
For(I,1,93,2
Pt-On(I,13
End

Also, using Pxl-on instead of Pt-on would improve speed.
Back to top
Babyboy


Advanced Member


Joined: 11 Jun 2003
Posts: 499

Posted: 30 Sep 2005 10:44:23 pm    Post subject:

that has the award for biggest optimisation EVER
Back to top
DarkerLine
ceci n'est pas une |


Super Elite (Last Title)


Joined: 04 Nov 2003
Posts: 8328

Posted: 30 Sep 2005 11:03:26 pm    Post subject:

Oh, there will be more.
Back to top
Babyboy


Advanced Member


Joined: 11 Jun 2003
Posts: 499

Posted: 01 Oct 2005 05:59:17 pm    Post subject:

Sad
Back to top
DJ Omnimaga
http://i-lost-the-ga.me


Calc Guru


Joined: 14 Nov 2003
Posts: 1196

Posted: 01 Oct 2005 07:01:26 pm    Post subject:

Sir Robin wrote:
Oh, there will be more.
[post="57530"]<{POST_SNAPBACK}>[/post]

post /me is lazy


Last edited by Guest on 01 Oct 2005 07:02:20 pm; edited 1 time in total
Back to top
DarkerLine
ceci n'est pas une |


Super Elite (Last Title)


Joined: 04 Nov 2003
Posts: 8328

Posted: 01 Oct 2005 07:58:29 pm    Post subject:

Quote:
getKey -> O
Pt-On(A,B
Line(A-1,B+1,A-10,B+1
Line(A-1,B-1,A-10,B-1
Line(A-7,B,A-11,B
Pt-On(A-7,B+2
Pt-On(A-7,B-2

If O
Then
Pt-Off(A,B
Line(A-1,B+1,A-10,B+1,0
Line(A-1,B-1,A-10,B-1,0
Line(A-7,B,A-11,B,0
Pt-Off(A-7,B+2
Pt-Off(A-7,B-2
..



Code:
(initialize K to nonzero value outside loop)
getKey
If Ans!=K:Then
Pt-Chg(A,B
Line(A-1,B+1,A-10,B+1,K
Line(A-1,B-1,A-10,B-1,K
Line(A-7,B,A-11,B,K
Pt-Chg(A-7,B+2
Pt-Chg(A-7,B+2
Ans->K
End
If K:Then
..
I replaced O with K because it was hard to tell whether it was O or 0.
Back to top
elfprince13
Retired


Super Elite (Last Title)


Joined: 11 Apr 2005
Posts: 3500

Posted: 03 Oct 2005 12:19:40 pm    Post subject:

check out prgmBATTLNGN from the example RPG engine in my sprites/maps tutorial
Back to top
Babyboy


Advanced Member


Joined: 11 Jun 2003
Posts: 499

Posted: 03 Oct 2005 05:45:42 pm    Post subject:

i took a look at that tutorial, wow, that seems to high end for me, you guys are geniouses!

i never though of using a var for on and off lines! that is really good, there are alot of places i can use that. be prepared for a whole new version! (mua ha ha ha ha)
Back to top
Display posts from previous:   
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
    »
» View previous topic :: View next topic  
Page 1 of 1 » All times are UTC - 5 Hours

 

Advertisement