We're on Discord! Please join our server now if you don't want to miss anything! (More info) | Join the UCC4 contest! (More info)

* WalrusIRC (More rooms available on our Discord server)

Author Topic: Village  (Read 1336 times)

0 Members and 1 Guest are viewing this topic.

Offline _iPhoenix_

  • Custom title
  • Super User
  • Join Date: Mar 2017
  • Location: Location
  • Posts: 675
  • Post Rating Ratio: +16/-1
  • ███████ ▼ ♪ Best music ♫
    • @dj_iPhoenix
    • @UCytgMNPxAMDsxjimvxHf01w
    • Legend-of-iPhoenix
    • @the-legend-of-iphoenix
    • My website.
  • Gender: Male
Village
« on: October 15, 2018, 11:13:02 am »
So apparently I don't have a thread for my current project here. Dang.


Village is my long-term project. It's an Esolang where you are a village chief and you get to command people around and do things. It's a lot of fun.


Here's a basic "hello, world" program:
Code: [Select]
Call for the villager named Ada.
Tell Ada to write the text "Hello, World!" on her scroll.
Tell Ada to post her scroll to the Community Message Board


Pretty simple!


Villagers can have occupations.
Code: [Select]
Call for the villager named Alan.
Teach Alan how to gather wood.


Note: This next task takes 3 successful lines of code to complete.
Tell Alan to gather 20 wood.


Note: waste 3 commands.
Call for the villager named Ken.
Teach Ken how to draft blueprints.
Tell Ken to make a blueprint for a railroad to the North village.


Note: At this point, Alan's done getting wood.
Tell Alan to write the text "I have " on his scroll.
Tell Alan to write the amount of wood he has on his scroll.
Tell Alan to write the text " wood." on his scroll.
Tell Alan to post his scroll to the Community Message board.

Not all of the features are officially documented yet, with the main undocumented feature being Ask commands, aka conditionals. They are explained pretty well in my Cemetech topic:
(click to show/hide)



There's more stuff in the docs.

Link to interpreter

The console messages (when debug mode is on) will help explain the examples and should help you.

Enjoy!


  • Calculators owned: Two TI-84+ CE's
Please spam here: https://legend-of-iphoenix.github.io/spam/

"walruses are better than tuxedo chickens, all hail the great :walrii:" ~ me
Evolution of my avatar:

Offline _iPhoenix_

  • Custom title
  • Super User
  • Join Date: Mar 2017
  • Location: Location
  • Posts: 675
  • Post Rating Ratio: +16/-1
  • ███████ ▼ ♪ Best music ♫
    • @dj_iPhoenix
    • @UCytgMNPxAMDsxjimvxHf01w
    • Legend-of-iPhoenix
    • @the-legend-of-iphoenix
    • My website.
  • Gender: Male
Re: Village
« Reply #1 on: March 17, 2019, 11:34:36 pm »
Well I've forgotten to post updates here and the language has completely changed so yay. Most recent update post.

I'm thinking of picking up this project again. I finally wrote documentation for Ask. I'm trying to keep the documentation understandable for someone with only a marginal programming ability (i.e. may have touched a C-based programming language or similar in the past or just started.)

I'm looking for feedback on this documentation (suggestions via post, ping, or PR are welcome!)

I'm also looking for clean (as clean as you can get with this language >.>) demo programs.

You can easily relocate your input (In lieu of input commands, I'm using the "modify this program with input values" technique) to the top of the program using Skip commands. I created a trivial multiplication program here. It's a model Village program, about as clean as it gets. I'm playing with the idea of named labels at some point, so that users viewing without line numbers don't have to count. You can just load it into the interpreter though.

Code: [Select]
Skip to line 22.
Note: ==========
Note: Trivial multiplication program
Note: Results: A*B -> output
Note: Author: _iPhoenix_
Note: ==========

Note: Inputs:
Note: =======

Note: MODIFY THIS LINE FOR A
Tell Ada to mine 16 stone.

Note: MODIFY THIS LINE FOR B
Tell Alan to mine 16 stone.

Note: =======

Tell Ken to write the text "waiting..." on his scroll.
Skip to line 40.

Note: Init:
Note: =====

Call for the villager named Ada.
Teach Ada how to mine stone.

Call for the villager named Alan.
Teach Alan how to mine stone.

Call for the villager named Ken.
Teach Ken how to mine stone.

Call for the villager named John.
Teach John how to mine stone.

Skip to line 9.

Note: Main program:
Note: =============

Tell Ken to mine 1 stone.
Tell Ada to double her stone.

Tell Alan to write the text "waiting..." on his scroll.
Tell Alan to write the text "waiting..." on his scroll.

Tell Alan to clear his scroll.

Tell Ada to give John half of her stone.

Ask Ken if he has less stone than Alan.
 - If he does:
  + Skip to line 40.

Note: Output:
Note: =======
Tell John to write the amount of stone he has on his scroll.
Tell John to post his scroll to the Community Message Board.
  • Calculators owned: Two TI-84+ CE's
Please spam here: https://legend-of-iphoenix.github.io/spam/

"walruses are better than tuxedo chickens, all hail the great :walrii:" ~ me
Evolution of my avatar:

 


You can also use the following HTML or bulletin board code to share it on your page or forum signature!


Also do not forget to check our affiliates below.
Planet Casio TI-Planet Calc.news BroniesQC BosaikNet Velocity Games