capitalex / zombie-more-vera.nv
0 лайк(-ов)
0 форк(-ов)
1 файл(-ов)
Последняя активность 2 years ago
| 1 | |#port, on draw zombie |
| 2 | , needs, @draw zombie |
| 3 | , reads, @zombie index| |
| 4 | |#port body, on draw zombie, lua| |
| 5 | print("DRAWING ZOMBIE", zombie_index) |
| 6 | local zombie = state.zombies[zombie_index] |
| 7 | love.graphics.setColor(0.145, 0.133, 0.169) |
| 8 | love.graphics.circle("fill", zombie.x + 5, zombie.y + 5, zombie.r) |
| 9 | |
| 10 | love.graphics.setColor(0.882, 0.314, 0.282) |
capitalex / linear-multiset-catlang.txt
0 лайк(-ов)
0 форк(-ов)
3 файл(-ов)
Последняя активность 2 years ago
| 1 | |
| 2 | function run_rules(state) |
| 3 | if state["flour"] >= 1 and state["sugar"] >= 1 and state["apples"] >= 1 then |
| 4 | emit(state, "apple cake") |
| 5 | return run_rules(state) |
| 6 | elseif state["apples"] >= 1 and state["oranges"] >= 1 and state["cherries"] >= 1 then |
| 7 | emit(state, "fruit salad") |
| 8 | return run_rules(state) |
| 9 | elseif state["fruit salad"] >= 1 and state["apple cake"] >= 1 then |
| 10 | emit(state, "fruit cake") |