battle programming a forum for elite programmers with extreme will power to sharpen theire skills
 
HomeCalendarFAQSearchMemberlistUsergroupsRegisterLog in
Post new topic   Reply to topicShare
 

 DHungry skill

Go down 
AuthorMessage
Moti Barski

Moti Barski

Posts : 330
Join date : 2011-08-02

DHungry skill Empty
PostSubject: DHungry skill   DHungry skill EmptySat Jun 01, 2019 3:37 am

Code:
import java.util.ArrayList;

public class DHungry extends AbsCmdReq implements Neuronable {
   // basic skill created, lets add it to the living grimoire :D
   /*
    * this is some new skill I made for the MGTOW Artificial General Intelligence
    * this agi platform enables the programmer to finish a project with one code
    * line by simply adding the skill new skills are published to the site, pick
    * skills and add them to your agi instance ok so watch how easy it is
    */
   private int powerLv;
   private int threshHold = 60;
   private RegexUtil regexUtil = new RegexUtil();

   @Override
   public void output(Neuron noiron) {
      // TODO Auto-generated method stub
      if (powerLv > 90) {
         threshHold = 60;
      }
      if (powerLv < threshHold) {
         threshHold = ((powerLv / 10) - 1) * 10;
         AbsAlgPart itte = new APSay(1, "I am hungry power level at" + powerLv + " percent");
         String representation = "hungry";
         ArrayList<AbsAlgPart> algParts1 = new ArrayList<>();
         algParts1.add(itte);
         Algorithm algorithm = new Algorithm("eat", representation, algParts1);
         noiron.algParts.add(algorithm);
      }
   }

   @Override
   public void input(String command) {
      // TODO Auto-generated method stub
      String myString = regexUtil.regexChecker("(\\d+)(?= charge)", command);
      if (myString != "") {
         powerLv = Integer.parseInt(myString);
      }
   }

}

not done with this one yet. grimoire

_________________
MB over and out emp it up
Back to top Go down
View user profile
 
DHungry skill
Back to top 
Page 1 of 1

Permissions in this forum:You can reply to topics in this forum
battle programmers alliance :: battle programming alliance :: the LivinGrimoire-
Post new topic   Reply to topicJump to: