Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - c4ooo

Pages: 1 [2]
16
Web Programming and Design / Help with github and .TK
« on: June 15, 2015, 09:35:37 pm »
I recently decided to use .TK to create a domain for my website, currently hosted on github. c4ooo.github.io, is URL of the website. However, ever sense i attempted to link the .TK domain to the github website, c4ooo.github.io has a blue "FN" logo as its icon. I cant seem to be able to remove it. Ive deleted my CNAME file in my github repository, but it still cant remove it. testing987654321.tk , the domain i set up with TK no longer works. Any help on how to remobe the blue "FN" icon from my websites tab,as well as on how to properly set up TP with github,would be highly appreciated. I am really lost :banghead:

17
Minecraft Discussion / 32 Bit Redstone Computer
« on: June 15, 2015, 03:38:02 pm »
Today i wanted to alert the omnimaga community of my 32 Bit Redstone (/command block :P ) Computer. I consider it one of the most power full (for example it is one of the only two MC computers i know of that can do multiplication in less then two seconds). Some other stats: (sorry if i seem like i am bragging :( )
  • 32 bit cpu
  • 64*64 pixel gpu that supports 16 colours
  • 4kb of memory (1024 32-bit memory cells)
So, here is a link to the main thread on mc forums: http://www.minecraftforum.net/forums/minecraft-discussion/redstone-discussion-and/2116999-computer-command-block-computer-now-running-with?page=3
A lot of the content there is outdated and need to be updated. If you have questions/comments and don't have a MC forums account, you can post here :) If you do i prefer if you post there for me to get more momentum :P
Here is a video: (sorry for bad quality)

18
Community Contests / [ENDED] Code Golf - The Reboot #3
« on: June 15, 2015, 12:00:02 am »
Hello ladies, gentleman, and welcome to the third iteration of...
:evillaugh: Code Golf Rebooted! :evillaugh:
...not that its evil or anything... But any way, as you can see i am neither @JWinslow23 nor @pimathbrainiac,for my name is c4ooo, and if you are confused as to what is happening, I will explain. Basically, me Pimath and Winslow as well as others, will all be hosting the challenges in succession. If you are confused because you do not know what code golf is, please check out this thread: https://www.omnimaga.org/community-contests/code-golf-the-reboot-1/

So, as to begin, here is this weeks challenge:
Challenge #3: Cellular automation
You must wright a program that infinitely computes Conway's Game of Life. What is this Conway's Game of Life you may be asking? The Game (no not that game, Conway's Game) is "zero person" game in which the board is split into an infinite grid of square cells. Based on four specific rules, cell die or are reborn. These are the four rules, taken from wikipidia:
Quote
  • Any live cell with fewer than two live neighbours dies, as if caused by under-population.
  • Any live cell with two or three live neighbours lives on to the next generation.
  • Any dead cell with exactly three live neighbours becomes a live cell, as if by reproduction.
  • Any live cell with more than three live neighbours dies, as if by overcrowding.

Thus, a every pixel is a cell, and every turn the four rules must be applied to every pixel/cell to generate the new state of the game board. A cell is a "neighbouring cell" if it is adjacent to the cell, diagonals included. To know more about The Game, I highly suggest Wikipedia (It might be necessary for you to read the article, my summery of The Game is very brief): https://en.wikipedia.org/wiki/Conway's_Game_of_Life. Mostly to give an advantage to calculators, i will add several rules your program must follow:
  • Every pixel on the screen must be an individual cell, white being dead and black being alive or vice verse.
  • The game board must consist of every pixel on the screen. eg "full screen"., However, the rule does not apply if there is a significant limitation in your language where this is simply not possible, like in Silver Edition TI-BASIC, or PICO-8.
  • The outer pixels do not have to follow the rules,If you want you make make them dead forever. Alternatively, you can make the board wrap around.
  • The game must start in a pseudo random configuration, loophole fix, courtesy @Runer112 "every cell's initial state must have a nonzero chance of being in each state and must be independent (barring reasonable PRNG limitations) of every other cell's initial state." No user input / cell manipulation is required.
  • Every iteration the program must obviously update the screen.
Ranking
Solutions
Runer112:
Spoiler For Spoiler:

.L
For(ClrDraw)
Pxl-Change(,rand
End
Repeat StorePic DispGraphClrDrawgetKey
For(X,,"
For(9→Z)
-pxl-Test(Z--^3+X-1,Z/3+Xʳʳ-1)ʳ
End
Pxl-On( or pxl-Test(X,Xʳʳ)ʳ=5*X,Xʳʳ
End
End

lirtosiast:
Spoiler For Spoiler:

0
For(F,1,E9
For(X,0,93
Ans/7+49seq(pxl-Test(Y,X+1),Y,0,62
For(Y,1,61
If 2rand<F=pxl-Test(Y,X)+int(3fPart(3cosh(fPart(6-1iPart(sum(Ans,Y,Y+2
Pxl-Change(Y,X
End
End
End

Haobo:
Spoiler For Spoiler:

Copy(rand
While
StorePicDispGraphClrDraw
For(Y,0,63
For(X,0,95
For(Z,0->B,8
pxl-Test(Z^3+X-1,Z/3+Y-1)^^r->A
Z=4?A->C,A+B->B
End
If B=3+(C?B=2
Pxl-On(X,Y
End
End
End
End

ben_g:
Spoiler For Spoiler:

*COMING*

Scipi:
Spoiler For Spoiler:

#include<tonc.h>
#define l for(x=0;++x<239;)for(y=0;++y<159;)
main(){R=1028;*P=32767;u8 x,y,s,m,p;for(;!(S=~K&1023););l M(x,y,Q()&1);for(;u8*v=(u8*)V;){F();l{for(m=-1,p=v[x+y*240],s=-p;++m<9;)s+=v[x+m%3-1+(y+m/3-1)*240];M(x,y,p?s<4&s>1:s==3);}}}

pbfy0:
Spoiler For Spoiler:

.string "PRG"
 
   lcd_ptr .req r4
   active_fb .req r5
   inactive_fb .req r6
   orig_fb .req r7
   new_fb .req r8
 
   @ start
   push {r4-r8, r12, lr}
   
   ldr lcd_ptr, =0xC0000000
   adr r9, offsets
   @mov r0, #0x10000
   @sub r0, r0, #0x11
   ldrh r0, [r9, #6] @ 0xffff is already in the offset table because of -1
   str r0, [lcd_ptr, #0x200]
   
   @ldr r2, [lcd_ptr, #0x18]
   @bic r2, #14
   @orr r2, #6 @ 8 bpp, paletted
   ldrh r2, [r9, #18]
   str r2, [lcd_ptr, #0x18]
   
   @add lcd_ptr, r1, #0x10 @ to 0xC0000010
   ldr orig_fb, [lcd_ptr, #0x10] @ original framebuffer
   mov active_fb, orig_fb @ active framebuffer
   add new_fb, orig_fb, #76800
   mov inactive_fb, new_fb
   
   ldr r10, =76800
   mov r11, #0
1:   subs r10, r10, #1
   strb r11, [active_fb, r10]
   @ldrb r3, [inactive_fb, r10]
   svc #206 @ rand
   and r0, r0, #1
   strb r0, [inactive_fb, r10]
   bne 1b
   
   mov r2, #320
   mov r1, #0
   mov r0, inactive_fb
   push {r1,r2}
   svc #7
   pop {r1,r2}
   ldr r3, =76480
   add r0, r0, r3
   svc #7
   
3:   ldr r0, =76480 @ 320 * 239
   str inactive_fb, [lcd_ptr, #0x10]
   mov inactive_fb, active_fb
   ldr active_fb, [lcd_ptr, #0x10]
 
2:   mov r1, #18 @ 9 * 2
   mov r2, #0
   sub r0, #1
   
1:   sub r1, #2
   ldrsh r3, [r9, r1] @ won't let me use lsl #1
   add r3, r3, r0
   cmp r3, #76800
   ldrltb r3, [active_fb, r3] @ no lt?
   addlt r2, r2, r3
   teq r1, #0
   bne 1b @ at end of loop, r1 and r3 can be discarded
   
   ldrb r1, [active_fb, r0]
   @add r2, r2, r1
   teq r2, #3
   moveq r1, #1
   teqne r2, #4
   movne r1, #0
   strb r1, [inactive_fb, r0]
   teq r0, #320
   bne 2b
   
   ldr r0, =0x900E001C
   ldr r1, [r0]
   tst r1, #0x80
   beq 3b
   
   str orig_fb, [lcd_ptr, #0x10]
   pop {r4-r8, r12, pc}

offsets:
   .hword -321, -320, -319, -1, 1, 319, 320, 321, 0 @ actual offsets
   .hword 0x927 @ misc data

Juju:
Spoiler For Spoiler:

function e(i)x=i%128y=i/128n=pget(x,y)z=-n
for j=-3,5 do z+=pget(x+j/3,y+j%3-1) end
if(z<9 or z>21)n=0
if(z==21)n=7
return n
end
for i=0,8191 do poke(i,112*flr(rnd(2))+7*flr(rnd(2)))end
function _update()end
function _draw()memcpy(24576,0,8192)for i=0,8191 do
poke(i,16*e(i*2+1)+e(i*2))end
end

My solution:
Spoiler For Spoiler:

*COMING*

Scoring
All non-calculator programs will be scored through this counter: http://juju2143.ca/golf/
Assembly programs will be scored on binary size (excluding the header), and Basic/Axe programs will be scored based on-calc source size (once again, excluding the header).
Good luck, and may this contest automate you!
Submission:  
To submit, ether send me a PM with a the/link to code, or electronically mail me at kuznetsov4000[at]gmail[dot]com.
Want to host to?
Just ask me, pimathbrainiac or JWinslow about it, preferably by replying in here: https://www.omnimaga.org/community-contests/code-golf-the-informationdiscussionplanning-thread/.

19
TI Z80 / [ti-basic] Lazer I: bringing attention to an old game.
« on: May 05, 2015, 04:08:03 pm »
Ages ago, when i got my first calc in algebra, i made a game (and never bothered to learn how to solve quadratic equations, but then again i can just make a program to do it for me :P ). It was a laser simulater/puzzle game written in pure basic. When i got my own calc a few months ago, as i had been inactive for more then half a year, i decided to polish up the old game and start making a new version in axe. As i learned about omnimaga when i re-imagrated to the calcs as my main programming platform, the game was previously only available on ticalc.org . Link: http://www.ticalc.org/archives/files/fileinfo/459/45934.html
The ticalc entry has more screenshots and a read me, but i will quote the readme here:
Code: [Select]
A fun game-position  mirrors to bounce a laser(s) and hit the target(s). current version (v 0_45) includes emitters, detectors, mirrors , walls , and portals!!!
HOW TO PLAY:
1) use keypad and [enter] to select play.
2) use keypad and [enter] to select the level.
3) now finaly you can actualy play!!
4) here are the controls:
keypad-move
[enter]-shoot
[clear]-rotate mirror
[2nd]-retry/reset level
[alpha]-level selection
 ___  ___  ________  ___      ___ _______           ________ ___  ___  ________   ___  ___  ___       
|\  \|\  \|\   __  \|\  \    /  /|\  ___ \         |\  _____\\  \|\  \|\   ___  \|\  \|\  \|\  \     
\ \  \\\  \ \  \|\  \ \  \  /  / | \   __/|        \ \  \__/\ \  \\\  \ \  \\ \  \ \  \ \  \ \  \     
 \ \   __  \ \   __  \ \  \/  / / \ \  \_|/__       \ \   __\\ \  \\\  \ \  \\ \  \ \  \ \  \ \  \   
  \ \  \ \  \ \  \ \  \ \    / /   \ \  \_|\ \       \ \  \_| \ \  \\\  \ \  \\ \  \ \__\ \__\ \__\   
   \ \__\ \__\ \__\ \__\ \__/ /     \ \_______\       \ \__\   \ \_______\ \__\\ \__\|__|\|__|\|__|   
    \|__|\|__|\|__|\|__|\|__|/       \|_______|        \|__|    \|_______|\|__| \|__|   ___  ___  ___
                                                                                       |\__\|\__\|\__\
                                                                                       \|__|\|__|\|__|
                                                                                                     
screenshot: more screenshots at link

Once again, this is an old game made by me only now brought to omnimaga!  :thumbsup:

20
Other / Controlling motors using calc?
« on: May 02, 2015, 09:14:44 pm »
So does anyone have any thoughts about controlling 2 motors using a ti84+? Would it be possible to do it with just a few wires and maybe some relays? i know its possible to use the arduino as a "bridge" between the motors and calcs, but i don't want to use an arduino. I just want to use a calculator and some wires.
PS imd very tired right now so pls exuse me if the post seems ranting or seems to use unnatural language.

21
Axe / Why does axe greyscale look so bad at very high speeds?
« on: April 18, 2015, 05:50:08 pm »
So this has been bugging me fore some time so I desised to ask about it. As I've mentioned in title, at very fast speeds greyscale looks like greyscale would look at very slow speeds. Can someone explain what couses this and how axe implements greyscale in the first place? Also why can't you just render the 1st and 2nd buffer in rapid succession, instead of doing this weird diagonal line thing axe does now?

22
Axe / Help with greyscale tile engine?
« on: April 09, 2015, 11:34:33 am »
So i was working in a grayscale tile engine, and i finished to the point where it works. Having made tiloe enginges in java before it was not even that hard. The problem is it is just to slow. So i have the code here:
Code: [Select]
Repeat getKey(41)
If getKey(1)
Y++
End
If getKey(2)
x--
End
if getkey(3)
x++
End
if getkey(4)
y--
End
RENDER()
DispGraph^RR
End
Return
Lbl Render
cLrDraw^RR
0->G
For(E,0,H
for(D,0,w
Pt-Mask(D-x,E-y.{G+str1MAP}*16+Pic1TILES
D+7->D
G++
End
E+7->E
End
Return
Now as ive said before, it works, but it is to slow for a platformer i had in mind, and the gray scale also looks bad. Is there any way i can speed it up? I have consired using Verticle and Horisontal to shift the buffer left/right/up/down when the player moves, but there is the problem that another entity could move while the player stands still. Any suggestions?

23
Axe / My Axe flood fill algorithm. [tutorial WIP]
« on: March 10, 2015, 10:03:06 pm »
This was originally intended as a tutorial, but it never worked out like a tutorial so lie just post the code and comment on what it does.

So i was bored in math class and decided to implement a flood fill algorithm. It was actually much easier then i though  :w00t:
This is probably not the most efficient flood fill out there, as i thought of it myself . So yea: (ps the algorithm requires a second 768 (786?) byte buffer.) (pps i thought of the algorithm my self but it may be pretty standard  :-\ )
It seems pretty fast to me, but i don't know how fast it is compared to others. Ile try to post pics soon. So here is the code:
Code: [Select]
.FloodFill
.PROGRAM START, CALLS FLOOD FILL ON CORDS 48,32
DiagnosticOff
Full
ClrDraw^rr
FLOODFILL(48,32)
DispGraph
Text(0,0,"Over"
Repeat getKey
End
Return
Lbl FLOODFILL
r1->X
r2->Y
0->D+1->Z
Pxl-On(X,Y)
Pxl-On(X,Y)^r
Repeat getKey(1)
If HIT(Z)
TURN()->Z
!If Z
JUMP()
!If Z
Return
End
End
End
MOVEX()->X
MOVEY()->Y
D+1^1024-D
!If D
DispGraph
End
End
Return
Lbl JUMP
For(F,0,95)
For(G,0,63)
If pal-Test(F,G)^r
F->X
G->Y
TURN()->Z
if Z
Return
End
End
End
End
0->Z
Return
Lbl TURN
For(T,1,4
!If HIT(T)
T
Return
End
End
0
Return
Lbl HIW
MOVEX(r1)->I
MOVEY(r1)->J
If pxl-Test(I,J)??I<0??I>95??J<0??J>63
1
Return
End
0
Return
Lbl MOVEX
If r1=1
x+1
Return
ElseIf r1=3
X-1
Return
End
x
Return
Lbl MOVEY
if r1=2
Y-1
Return
ElseIf r1=4
Y+1
Return
End
Y
Return
Few that was long… now i have to indent and comment the code!  :P

24
If i know the flash page of a file, how can a read/write to it without using Y1 or GetCalc()?

25
TI Z80 / [Axe] Lazer II
« on: March 08, 2015, 08:41:24 pm »
Lazer (with an Z!) II is a sequel to Lazer I (also with an Z!), a cool Lazer simulator puzzle game where you spin mirrors to make lasers hit Targets. The original version was made in Ti-Basic, and can still be found http://www.ticalc.org/archives/files/fileinfo/459/45934.html]here.
Lazer 2 will add the following to Lazer 1:
Lazer v2.1 download: http://www.ticalc.org/archives/files/fileinfo/464/46490.html
  • Re-Writen in axe, every thing faster!
  • Greyscale
  • Level packs (sorof there)
  • A level editor (coming)
  • More tiles
Thanks to @chickendude  there is now an animated screen shot. Thanks chickendude :3 Also remember that every thing you see is still alpha :P

I have released the third version, v2.2.
Here is a changelog:
+MAD optimization
+Over 20 new levels, but maybe more ;)
+Pressing [ + ] will make the lasers go 2 pixels at a time, and [Enter] will pause it.
+The game now requires only 1500 bytes at run time, which is a less arbitrary number then 2000B was :P
+Minor visual improvements
+Level name can be seen in the level selection menu.
The game itself looks relatively the same as before... so no need for a screenie.
 
I would like to thank@Runer112 for the greyscale code and @chickendude for bug testing :)

26
I wanted to make a custom text drawer, overall better then  the defualt OS one. Ime guessing that the OS stores the sprite sheet with all the symbols on it somewhere in mem ,and as Google sherches revealed nothing, does anyone know the address? 

27
Axe / How to calculate (using trig) rotation in axe?
« on: March 04, 2015, 07:14:46 am »
i wanted to make a 3d game, but as ime not sure how to use the sin and cos function in axe as they return unexpected values.
How would i go about implementing rotation (for now, if i know haw to rotate round y i can rotate around any thing) around the y axis?
Thank you;

Pages: 1 [2]