Join us on Discord!
You can help CodeWalrus stay online by donating here.

UtilPack/ UtilComp [hp prime][lib]

Started by alexgt, June 20, 2015, 11:33:47 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Unicorn

Milliseconds? That's quite a specific function! What would it be used for?
  • Calculators owned: I own all of them: PICKACHUP TI 84+ CSE TI 83+ SE TI something something ??? ??? ??? ??? ???
  • Consoles, mobile devices and vintage computers owned: PICKACHUP ??? ??? ??? ??? ???



??? ??? ??? ??? ???

alexgt

In MinePrime I had a wait function for walking/running and I had the wait to 0.0001 in a for loop that ran 16 times for the smooth scrolling so it was more like 0.0016 seconds but usually WAIT() is fine.

I think my function is pretty exact since it only uses two short lines of code so there is no extra time added from running code :)
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Snektron

Quote from: Unicorn on July 02, 2015, 05:38:50 PM
Milliseconds? That's quite a specific function! What would it be used for?

Milliseconds is quite anormal thing for these kind of functions. if you for instance want to run something at 60 fps, you need to wait about 16 ms each loop.
Also in Java you can get the current time in nanoseconds O.O
  • Calculators owned: TI-84+
Legends say if you spam more than DJ Omnimaga, you will become a walrus...


alexgt

I didn't know that about Java O.O
Speaking of java I need to learn it <_<
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Snektron

It's not that hard. Though there are a few more advanced things that can be quite hard :P (like lambda functions <_< hough ive not looked into them that much)
  • Calculators owned: TI-84+
Legends say if you spam more than DJ Omnimaga, you will become a walrus...


Unicorn

Nano seconds? Next it'll be noseconds O.O
  • Calculators owned: I own all of them: PICKACHUP TI 84+ CSE TI 83+ SE TI something something ??? ??? ??? ??? ???
  • Consoles, mobile devices and vintage computers owned: PICKACHUP ??? ??? ??? ??? ???



??? ??? ??? ??? ???

alexgt

Next thing to add is a large matrix maker. With MAKEMAT() you will get an insufficient memory error if your matrix is too big. All you have to do is make two for loops with the size you want your matrix:

FOR A FROM 1 TO 500 DO //this is how many coloms you want here there will be 500
FOR B FROM 1 TO 100 DO //this is how many rows you want here there will be 100
MatrixName(B,A):=0 //it is B,A Because the coordinates are in row,col form
END;
END;

I still have to code it but it will be in the next update :)
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Unicorn

Nice, I like how you are just updating this with functions as you come torequire them :)
  • Calculators owned: I own all of them: PICKACHUP TI 84+ CSE TI 83+ SE TI something something ??? ??? ??? ??? ???
  • Consoles, mobile devices and vintage computers owned: PICKACHUP ??? ??? ??? ??? ???



??? ??? ??? ??? ???

alexgt

Quote from: Unicorn on July 06, 2015, 09:43:45 PM
Nice, I like how you are just updating this with functions as you come torequire them :)
That is the only time I think of them :P

Also updates will be less frequent now (I want to add more than one function to it :))
And remember everyone can come up with ideas :)
I also am designing this so you can copy/paste the code out of here and put it into a sub if you want and modify them to fit your needs, of course if you don't need to modify them stick to compiling them with UtilComp when I get around to coding it <_<
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

alexgt

How does a custom rectangle/ polygon sound!!
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Unicorn

oo oo oo! That would be pretty nice!  make sure you can invert the rects colors! :)
  • Calculators owned: I own all of them: PICKACHUP TI 84+ CSE TI 83+ SE TI something something ??? ??? ??? ??? ???
  • Consoles, mobile devices and vintage computers owned: PICKACHUP ??? ??? ??? ??? ???



??? ??? ??? ??? ???

alexgt

Quote from: Unicorn on July 18, 2015, 02:57:16 AM
oo oo oo! That would be pretty nice!  make sure you can invert the rects colors! :)
I could do that with rect because there is actually a invert command but it is not polygon compatible :(, I don't think but I will check ;)
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Unicorn

Awe...But its still awesome! could you make a specialeffects thing too? Like a screen shift?
  • Calculators owned: I own all of them: PICKACHUP TI 84+ CSE TI 83+ SE TI something something ??? ??? ??? ??? ???
  • Consoles, mobile devices and vintage computers owned: PICKACHUP ??? ??? ??? ??? ???



??? ??? ??? ??? ???

Strontium

Quote from: Cumred_Snektron on July 02, 2015, 06:48:24 PM
It's not that hard. Though there are a few more advanced things that can be quite hard :P (like lambda functions <_< hough ive not looked into them that much)

lambda functions being quite hard? I never had a very hard time grasping them, unless Java has a different idea of what a lambda function is than a lot of other languages.
  • Calculators owned: TI Nspire CX, HP Prime
  • Consoles, mobile devices and vintage computers owned: NES

alexgt

Quote from: Unicorn on July 19, 2015, 01:06:49 AM
Awe...But its still awesome! could you make a specialeffects thing too? Like a screen shift?
I could replicate the Horizontal+ and - function in Axe :)
  • Calculators owned: Ti-84+, Ti-Nspire, Hp Prime, Broken HP Prime, HP 48SX

Powered by EzPortal