Author Topic: [ENDED] Code Golf Contest #5  (Read 21275 times)

0 Members and 1 Guest are viewing this topic.

Offline ben_g

  • Hey cool I can set a custom title now :)
  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +125/-4
  • Asm noob
    • View Profile
    • Our programmer's team: GameCommandoSquad
Re: Code Golf Contest #5
« Reply #15 on: August 11, 2014, 07:16:25 pm »

It's slow and huge, but it's a start.
My projects
 - The Lost Survivors (Unreal Engine) ACTIVE [GameCommandoSquad main project]
 - Oxo, with single-calc multiplayer and AI (axe) RELEASED (screenshot) (topic)
 - An android version of oxo (java)  ACTIVE
 - A 3D collision detection library (axe) RELEASED! (topic)(screenshot)(more recent screenshot)(screenshot of it being used in a tilemapper)
Spoiler For inactive:
- A first person shooter with a polygon-based 3d engine. (z80, will probably be recoded in axe using GLib) ON HOLD (screenshot)
 - A java MORPG. (pc) DEEP COMA(read more)(screenshot)
 - a minecraft game in axe DEAD (source code available)
 - a 3D racing game (axe) ON HOLD (outdated screenshot of asm version)

This signature was last updated on 20/04/2015 and may be outdated

Offline JWinslow23

  • Coder Of Tomorrow
  • LV7 Elite (Next: 700)
  • *******
  • Posts: 556
  • Rating: +43/-6
  • I make quality calculator games...when I have time
    • View Profile
Re: Code Golf Contest #5
« Reply #16 on: August 11, 2014, 07:17:42 pm »

It's slow and huge, but it's a start.
I believe I had something like that, except 100 bytes smaller.
Did you know that "Ammonia Gas" rearranged is "As Omnimaga"?
Click here for the only set of games you'll ever need
= ?

Offline Adriweb

  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1708
  • Rating: +229/-17
    • View Profile
    • TI-Planet.org
Re: Code Golf Contest #5
« Reply #17 on: August 11, 2014, 07:51:34 pm »
down to 500 bytes with no true-randomness as well as no check for spawn location

With both, 613 bytes >.<

Anyway, submitted.

GL HF


Edit : 596 bytes;
« Last Edit: August 12, 2014, 08:39:47 am by Adriweb »
My calculator programs
TI-Planet.org co-admin.
TI-Nspire Lua programming : Tutorials  |  API Documentation

Offline JWinslow23

  • Coder Of Tomorrow
  • LV7 Elite (Next: 700)
  • *******
  • Posts: 556
  • Rating: +43/-6
  • I make quality calculator games...when I have time
    • View Profile
Re: Code Golf Contest #5
« Reply #18 on: August 12, 2014, 10:25:26 am »
Anyway, submitted.
...then where's the PM? :P
Did you know that "Ammonia Gas" rearranged is "As Omnimaga"?
Click here for the only set of games you'll ever need
= ?

Offline Adriweb

  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1708
  • Rating: +229/-17
    • View Profile
    • TI-Planet.org
Re: Code Golf Contest #5
« Reply #19 on: August 12, 2014, 10:29:48 am »
It was the pastebin on the IRC PM :P

But anyway, I forum-PM'd you ^^
My calculator programs
TI-Planet.org co-admin.
TI-Nspire Lua programming : Tutorials  |  API Documentation

Offline JWinslow23

  • Coder Of Tomorrow
  • LV7 Elite (Next: 700)
  • *******
  • Posts: 556
  • Rating: +43/-6
  • I make quality calculator games...when I have time
    • View Profile
Re: Code Golf Contest #5
« Reply #20 on: August 12, 2014, 10:31:06 am »
It was the pastebin on the IRC PM :P

But anyway, I forum-PM'd you ^^
Oh, that's why you sent it to me there. :-\ Well, I mean forum PM from now on. Just like last contest. :P

Also, check that your board is square.
Did you know that "Ammonia Gas" rearranged is "As Omnimaga"?
Click here for the only set of games you'll ever need
= ?

Offline Adriweb

  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1708
  • Rating: +229/-17
    • View Profile
    • TI-Planet.org
Re: Code Golf Contest #5
« Reply #21 on: August 12, 2014, 10:48:52 am »
it is. 9x9.

Got the PM, btw ?
My calculator programs
TI-Planet.org co-admin.
TI-Nspire Lua programming : Tutorials  |  API Documentation

Offline JWinslow23

  • Coder Of Tomorrow
  • LV7 Elite (Next: 700)
  • *******
  • Posts: 556
  • Rating: +43/-6
  • I make quality calculator games...when I have time
    • View Profile
Re: Code Golf Contest #5
« Reply #22 on: August 12, 2014, 11:02:33 am »
it is. 9x9.

Got the PM, btw ?
Should've responded to you. :)

Oh, and I have 2 entries of my own. They are board size 21*21 and 165*165, respectively. They are the largest square boards for their platforms that fit the rules.
Did you know that "Ammonia Gas" rearranged is "As Omnimaga"?
Click here for the only set of games you'll ever need
= ?

Offline ben_g

  • Hey cool I can set a custom title now :)
  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +125/-4
  • Asm noob
    • View Profile
    • Our programmer's team: GameCommandoSquad
Re: Code Golf Contest #5
« Reply #23 on: August 12, 2014, 12:15:02 pm »
...
You must make a game of Snake (or Nibbles, if you know it as that). It must follow all of these guidelines:
  • It must be played on an square "grid" (each space being the width of one snake segment) as large as possible
  • The graphics for the food and the snake segments must each be different
  • The border must be clearly defined, and have different graphics from the food or the snake
   [li]The food must spawn randomly, Adriweb :P [/li]
   [li]The snake is moved with interactive input (such as a getKey-like command) if possible; if not supported, you may enter a direction each frame[/li]
   [li]Your snake must wrap around the sides of the board[/li]
   [li]At game's end, the program must display however many pieces of food were eaten in some way[/li]
   [li]Your game, above all, must be playable :P [/li]
[/list]
...
It's not clearly mentioned in the rules, but shouldn't the food always spawn in an empty space as well (not on the snake)?
My projects
 - The Lost Survivors (Unreal Engine) ACTIVE [GameCommandoSquad main project]
 - Oxo, with single-calc multiplayer and AI (axe) RELEASED (screenshot) (topic)
 - An android version of oxo (java)  ACTIVE
 - A 3D collision detection library (axe) RELEASED! (topic)(screenshot)(more recent screenshot)(screenshot of it being used in a tilemapper)
Spoiler For inactive:
- A first person shooter with a polygon-based 3d engine. (z80, will probably be recoded in axe using GLib) ON HOLD (screenshot)
 - A java MORPG. (pc) DEEP COMA(read more)(screenshot)
 - a minecraft game in axe DEAD (source code available)
 - a 3D racing game (axe) ON HOLD (outdated screenshot of asm version)

This signature was last updated on 20/04/2015 and may be outdated

Offline Adriweb

  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1708
  • Rating: +229/-17
    • View Profile
    • TI-Planet.org
Re: Code Golf Contest #5
« Reply #24 on: August 12, 2014, 12:50:37 pm »
Yes indeed, it must.

(it's what takes me ~90 bytes :P)
My calculator programs
TI-Planet.org co-admin.
TI-Nspire Lua programming : Tutorials  |  API Documentation

Offline JWinslow23

  • Coder Of Tomorrow
  • LV7 Elite (Next: 700)
  • *******
  • Posts: 556
  • Rating: +43/-6
  • I make quality calculator games...when I have time
    • View Profile
Re: Code Golf Contest #5
« Reply #25 on: August 12, 2014, 01:31:10 pm »
...
You must make a game of Snake (or Nibbles, if you know it as that). It must follow all of these guidelines:
  • It must be played on an square "grid" (each space being the width of one snake segment) as large as possible
  • The graphics for the food and the snake segments must each be different
  • The border must be clearly defined, and have different graphics from the food or the snake
  • The food must spawn on a random EMPTY square, Adriweb :P
  • The snake is moved with interactive input (such as a getKey-like command) if possible; if not supported, you may enter a direction each frame
  • Your snake must wrap around the sides of the board
  • At game's end, the program must display however many pieces of food were eaten in some way
  • Your game, above all, must be playable :P
...

It's not clearly mentioned in the rules, but shouldn't the food always spawn in an empty space as well (not on the snake)?

What unclear rule? :P

Also, this:
« Last Edit: August 12, 2014, 01:33:43 pm by JWinslow23 »
Did you know that "Ammonia Gas" rearranged is "As Omnimaga"?
Click here for the only set of games you'll ever need
= ?

Offline ben_g

  • Hey cool I can set a custom title now :)
  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +125/-4
  • Asm noob
    • View Profile
    • Our programmer's team: GameCommandoSquad
Re: Code Golf Contest #5
« Reply #26 on: August 12, 2014, 01:46:49 pm »
Also:
...
You must make a game of Snake (or Nibbles, if you know it as that). It must follow all of these guidelines:
  • It must be played on an square "grid" (each space being the width of one snake segment) as large as possible
  • ...
...


Large enough for you?  :P
(it automatically adjusts to the screen size, and that at only 1580 bytes)
« Last Edit: August 12, 2014, 02:09:00 pm by ben_g »
My projects
 - The Lost Survivors (Unreal Engine) ACTIVE [GameCommandoSquad main project]
 - Oxo, with single-calc multiplayer and AI (axe) RELEASED (screenshot) (topic)
 - An android version of oxo (java)  ACTIVE
 - A 3D collision detection library (axe) RELEASED! (topic)(screenshot)(more recent screenshot)(screenshot of it being used in a tilemapper)
Spoiler For inactive:
- A first person shooter with a polygon-based 3d engine. (z80, will probably be recoded in axe using GLib) ON HOLD (screenshot)
 - A java MORPG. (pc) DEEP COMA(read more)(screenshot)
 - a minecraft game in axe DEAD (source code available)
 - a 3D racing game (axe) ON HOLD (outdated screenshot of asm version)

This signature was last updated on 20/04/2015 and may be outdated

Offline Adriweb

  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1708
  • Rating: +229/-17
    • View Profile
    • TI-Planet.org
Re: Code Golf Contest #5
« Reply #27 on: August 12, 2014, 04:23:56 pm »
Hum, as large as possible now.... mkay

I'm down to 551 bytes btw in Lua, not with this new rule though

Edit : nevermind, 555 bytes for a well defined grid (which is now 23x23)
« Last Edit: August 12, 2014, 04:40:18 pm by Adriweb »
My calculator programs
TI-Planet.org co-admin.
TI-Nspire Lua programming : Tutorials  |  API Documentation

Offline JWinslow23

  • Coder Of Tomorrow
  • LV7 Elite (Next: 700)
  • *******
  • Posts: 556
  • Rating: +43/-6
  • I make quality calculator games...when I have time
    • View Profile
Re: Code Golf Contest #5
« Reply #28 on: August 12, 2014, 05:13:58 pm »
I would have a 63*63 board for TI-83+ BASIC, but that would break the rule of "border, food, and snake graphics must be different". And I have a ~280 byte one in TI-83+ BASIC, but it breaks the rule of "largest possible board". Oh, the things I do to myself...
Did you know that "Ammonia Gas" rearranged is "As Omnimaga"?
Click here for the only set of games you'll ever need
= ?

Offline Adriweb

  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1708
  • Rating: +229/-17
    • View Profile
    • TI-Planet.org
Re: Code Golf Contest #5
« Reply #29 on: August 12, 2014, 05:17:36 pm »
That's also true for the Nspire, can't really see anything with a 1px thing (especially on clickpads) so I've made the biggest square that's enjoyable to play with I guess (not confusing at least)
making it bigger wouldn't take more bytes for me though, I believe, so it's not really the point ^^
My calculator programs
TI-Planet.org co-admin.
TI-Nspire Lua programming : Tutorials  |  API Documentation