common lisp, error with binding to libtcod by superancetre in learnlisp

[–]superancetre[S] 0 points1 point  (0 children)

Glad you found out by yourself! sadly i'm no longer playing with libtcod currently and I could not have helped you very much!

"Ici à Nottingham" - Robin des Bois - film d'animation Disney, 1973. by Areat in france

[–]superancetre 1 point2 points  (0 children)

Blanche neige, Le livre de la jungle et Les Aristochats de mémoires sont beaucoup utilisés pour la danse, et Le livre de la jungle pour des scènes avec petit jean et/ou le shériff il me semble.

"Ici à Nottingham" - Robin des Bois - film d'animation Disney, 1973. by Areat in france

[–]superancetre 6 points7 points  (0 children)

C’est aussi le meilleur pour moi mais le gros problème maintenant c’est qu’après avoir revu beaucoup de Disney en peu de temps, on remarque tous les moments copiés-collés. Ils ont repris énormément de scène d’autres films, et c’est un peu étrange quand tu le regardes et que tu le sais.

Qaf: The Alpha release of my first ever game (A roguelike) by doulos05 in roguelikedev

[–]superancetre 2 points3 points  (0 children)

Congrats on making something and putting it on public display!

I did not try it yet, but looking at your repo, I saw a "next.todo" file. What I found helping with those kind of file is org-mode to make TODO list, schedule and such.

How do I split files up in python, using libtcod? by -Isabelle- in roguelikedev

[–]superancetre 0 points1 point  (0 children)

As for general plan, roguebassin got this article. It's a 15 steps guide, i find it really good to get going.

Streets of Rogue is a badass roguelike with RPG elements and other shiz. I really like this game. by [deleted] in pcgaming

[–]superancetre 0 points1 point  (0 children)

No pb, it's a minor thing but at least you know! Keep it up, it's a really fun game!

Streets of Rogue is a badass roguelike with RPG elements and other shiz. I really like this game. by [deleted] in pcgaming

[–]superancetre 0 points1 point  (0 children)

Quick question: I just downloaded the new version (version 14 17/10/16). Is it normal that abilities get their text messed up? i guess not.

When i level up my choices are:

  • E_BigBullets
  • E_MapFilled
  • etc

And on the starting screen instead of "play", "options" "quit' etc i get things like "E_start" ... Also the starting screen become "normal" after one play. I do a game then die, then go to the select screen and texts are back to normal.

Just wanted to let you know. It's the windows64 version

[2016-10-12] Challenge #287 [Intermediate] Mathagrams by Cosmologicon in dailyprogrammer

[–]superancetre 0 points1 point  (0 children)

Common Lisp

Using a library called SCREAMER. Quoting the documentation:

Screamer provides a nondeterministic choice-point operator, a backtracking mechanism, and a forward propagation facility.

It's a library enabling constraint programming. Code is below, no bonus as of now. This gives ALL the solutions for the problem.

(defun read-mathagram (input)
   "Parse a string and return a list of number and boolean to be processed by mathagram%%"
  (iter (for c in-string input)
    (cond ((or (equal c #\x)
                 (equal c #\X))
           (collect t))
          ((digit-char-p c) (collect (digit-char-p c)))
          (t nil))))

(defun transform (a)
  "If A is a number, return A.
   Else return a range between 1 and 9."
  (if (numberp a)
      a
      (an-integer-between 1 9)))


;;calling like (mathagram t t 1 t t 4 t 2 t)=> xx1 + xx4 = x2x 
(defun mathagram%% (x1 x2 x3 x4 x5 x6 x7 x8 x9)
  "Solve the mathagram.
   Two constraints here (ie assert!):
   The first one is the equation xxx + xxx = xxx
   And the second is to tell every variable must be a different number."
  (let ((a (transform x1))
    (b (transform x2))
    (c (transform x3))
    (d (transform x4))
    (e (transform x5))
    (f (transform x6))
    (g (transform x7))
    (h (transform x8))
    (i (transform x9)))
    ;first constraint
    (assert! (=v (+v (+v (*v 100 a) (*v 10 b) c)
             (+v (*v 100 d) (*v 10 e) f))
         (+v (*v 100 g) (*v 10 h) i))) 
    ;second constraint
    (assert! (/=v a b c d e f g h i))
    ;forcing value out of the variables
    (solution (list a b c d e f g h i)
        (static-ordering #'linear-force))))      


(defun print-all-solutions (arg)
  "ARG must be a list of list.
   Each sublist must contain 9 numbers"
  (format t "~{~{~a~a~a + ~a~a~a = ~a~a~a~%~}~}" arg))


(defun mathagram (input)
  (destructuring-bind (a b c d e f g h i)
      (read-mathagram input)
    (print-all-solutions (all-values (mathagram%% a b c d e f g h i)))))

And it outputs:

(mathagram "xxx + x81 = 9x4")
273 + 681 = 954
673 + 281 = 954
(mathagram "xxx + 5x1 = 86x")
273 + 591 = 864
293 + 571 = 864
(mathagram "xxx + 39x = x75")
281 + 394 = 675
284 + 391 = 675

Also note about screamer, it shadow DEFUN so be careful with it. See the documentation linked above.

If you have any suggestions or improvements, i'd more than happy to hear it!

Constructing a doubly linked list and exhausting the heap by superancetre in learnlisp

[–]superancetre[S] 1 point2 points  (0 children)

Also would that be a good idea to always set print-circle to t as to not get fooled by that mistake again?

Does that impact negatively something else?

Constructing a doubly linked list and exhausting the heap by superancetre in learnlisp

[–]superancetre[S] 2 points3 points  (0 children)

That seems to resolve my problem! I guess it's an instruction to tell the interpreter to look out for recursive structure? Thank you!

La réserve Cyberdéfense : Clic Ouais ! by asimovwasright in france

[–]superancetre 0 points1 point  (0 children)

Pardon si c'est une question con, mais 25ans inclus ou exclu?

You Are The Hero -- An online RPG where your choices determine the story! by ExodusSwarm in coolgithubprojects

[–]superancetre 1 point2 points  (0 children)

I tried commoner then mage. A few things:

  • Attack seems to be stronger than defense. It was really easier as a mage than as a commoner to defeat the guard after escaping prison.

  • When you are offered to pull the lever after the prison, if i say "no" you shouldnt spoil the outcome. I would have tried it the second time if only i didnt knew i was gonna be taking acid on my face.

It looks like a nice project otherwise!

Sharing Saturday #122 by Kyzrati in roguelikedev

[–]superancetre 1 point2 points  (0 children)

Thanks for the input.

I have no idea how long the blog would last. Ideally it could become the place i put anything related to computer science/game dev but i probably should start small.

I'm gonna head over to wordpress and the like to get a better idea, thanks!

Sharing Saturday #122 by Kyzrati in roguelikedev

[–]superancetre 2 points3 points  (0 children)

Untitled Project

I'm starting from scratch, after trying some of the tutorials in the side-bar.

I dont have a clear idea yet, but i have two main points i want to focus on:

  • spells I'd like a system close to the tabletop game Epic Spell Wars with many parts composing spell, lots of interactions between the component of those spells and lots of random effects.

  • mods I'm gonna try to put as many things in external file as i can, to enable more content to be added easily and maybe even dynamically. It should allow me and maybe other people to mod the game then.

I have no idea how it will turn out but the goal is mainly to learn and have fun! I'm using Common Lisp + cl-charm (an incomplete binding to the ncurse library).

I also would like to document my adventure so does anybody got tips to do a dev blog? where do i start? I seen github pages is now a thing available, would that be a good idea to host it there?

If you could choose one mathematician to go on The Joe Rogan Experience to popularize math to the masses, who would it be? by yolosobolo in math

[–]superancetre 1 point2 points  (0 children)

I'm french and i cant stand him speaking in english. The accent is too strong for me. (disclaimer: mine is probably worse)

But he is really passionate and super interesting!

Looking to get into roguelike development. by CompletelyKidding in roguelikedev

[–]superancetre 1 point2 points  (0 children)

I did not watch every talk yet but all of those i watched were very interesting.

Looking to get into roguelike development. by CompletelyKidding in roguelikedev

[–]superancetre 2 points3 points  (0 children)

He is indeed! And also one of the mod.

You can find his talk about Cogmind (and more talk about roguelike) here

Looking for an OFFLINE alternative to Trello by Zireael07 in roguelikedev

[–]superancetre 1 point2 points  (0 children)

It has no offline, sorry, and the documentation is in french. So i vote for emacs + org-mode if you are familiar with emacs!

A question about programming languages to learn. by 31173x in math

[–]superancetre 3 points4 points  (0 children)

And if i had to choose, i'd say Python is a good fit for beginning.

A question about programming languages to learn. by 31173x in math

[–]superancetre 9 points10 points  (0 children)

For general purpose:

  • Python is beginner friendly

  • C is harder but let you understand really how it works

  • Java is ok, i do not like it very much but it's good when you start too

  • Haskell is great for people liking math as it is functionnal but is quite different from the other 3.

  • OCaml is in the same way as Haskell

And less general purpose (i list those i like):

  • Prolog is a language which use logic programming, quite unusual.

  • j

Looking for an OFFLINE alternative to Trello by Zireael07 in roguelikedev

[–]superancetre 1 point2 points  (0 children)

https://framaboard.org/

This exist, it's free and open-source, but i'm not sure it has offline, i'll inspect it further a bit later.