query
stringlengths
7
33.1k
document
stringlengths
7
335k
metadata
dict
negatives
listlengths
3
101
negative_scores
listlengths
3
101
document_score
stringlengths
3
10
document_rank
stringclasses
102 values
Verify is object is equal to this AbsorberInfo.
@Override public boolean equals(final Object obj) { if (this == obj) { return true; } if (obj instanceof AbsorberInfo) { return ((AbsorberInfo) obj).absorber == absorber; } return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n protected boolean doEquals(Object obj) {\n if (obj instanceof BsUserInfo) {\n BsUserInfo other = (BsUserInfo)obj;\n if (!xSV(_id, other._id)) { return false; }\n return true;\n } else {\n return false;\n }\n }", "public boolean equal(Object obj) {\n\t\tif((super.equal(obj))==false) {return false;}\n\t\tif (!(this.purpose).equals(((Airborne)obj).purpose)) {return false;}\n\t\treturn true;\n\t}", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof BlInfo)) {\n return false;\n }\n BlInfo other = (BlInfo) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Override\n public boolean equals(Object obj) {\n\n return id.equals(((BacInfo) obj).id);\n\n }", "@Test\n public void checkEquals() {\n EqualsVerifier.forClass(GenericMessageDto.class).usingGetClass()\n .suppress(Warning.NONFINAL_FIELDS).verify();\n }", "@Override\n public boolean equals(Object obj) {\n return this == obj;\n }", "@Test\n\tpublic void testEqualsObject_True() {\n\t\tbook3 = new Book(DEFAULT_TITLE, DEFAULT_AUTHOR, DEFAULT_YEAR, DEFAULT_ISBN);\n\t\tassertEquals(book1, book3);\n\t}", "public boolean equals(Object obj) {\n\t\tMercator p;\n\t\ttry {\n\t\t\tp = (Mercator)obj;\n\t\t} catch (ClassCastException ex) {\n\t\t\treturn false;\n\t\t}\n\t\tif(!super.equals(p))return false;\n\t\treturn (refY==p.refY) && (scaleY==p.scaleY);\n\t}", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof BandInfo)) {\n return false;\n }\n BandInfo other = (BandInfo) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Test\n public void testEquals() {\n System.out.println(\"equals\");\n Object object = null;\n Reserva instance = new Reserva();\n boolean expResult = false;\n boolean result = instance.equals(object);\n assertEquals(expResult, result);\n \n }", "@Override\n public boolean equals(Object obj) {\n return this == obj;\n }", "public void testEqualsObject()\n {\n Mana meme = new Mana( myMise );\n Assert.assertEquals( myMise, meme );\n \n System.out.println( myMise.toString());\n Mana autre = new Mana( 49 );\n Assert.assertFalse( myMise.equals( autre ));\n autre = new Mana( 50 );\n Assert.assertTrue( myMise.equals( autre ));\n }", "public void testObjEqual()\n {\n assertEquals( true, Util.objEqual(null,null) );\n assertEquals( false,Util.objEqual(this,null) );\n assertEquals( false,Util.objEqual(null,this) );\n assertEquals( true, Util.objEqual(this,this) );\n assertEquals( true, Util.objEqual(\"12\",\"12\") );\n }", "public void testEqualsObject() {\n\t\t\tTipoNodoLeisure tipo1 = new TipoNodoLeisure(Messages.getString(\"TipoNodoLeisureTest.0\")); //$NON-NLS-1$\n\t\t\tTipoNodoLeisure tipo2= new TipoNodoLeisure(Messages.getString(\"TipoNodoLeisureTest.1\")); //$NON-NLS-1$\n\t\t\tTipoNodoLeisure tipo3= new TipoNodoLeisure(Messages.getString(\"TipoNodoLeisureTest.2\")); //$NON-NLS-1$\n\t\t\tif (tipo1 != tipo1)\n\t\t\t\tfail(Messages.getString(\"TipoNodoLeisureTest.3\")); //$NON-NLS-1$\n\t\t\tif (!tipo1.equals(tipo2))\n\t\t\t\tfail(Messages.getString(\"TipoNodoLeisureTest.4\"));\t\t\t //$NON-NLS-1$\n\t\t\tif (tipo1.equals(tipo3))\n\t\t\t\tfail(Messages.getString(\"TipoNodoLeisureTest.5\"));\t //$NON-NLS-1$\n\t\t}", "@Override\n public boolean equals(Object object)\n {\n if (!(object instanceof VehiculoInfoA))\n {\n return false;\n }\n VehiculoInfoA other = (VehiculoInfoA) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id)))\n {\n return false;\n }\n return true;\n }", "@Test\r\n\tpublic void testEquality(){\n\t\t assertEquals(object1, object2);\r\n\t}", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof Acarsdata)) {\r\n return false;\r\n }\r\n Acarsdata other = (Acarsdata) object;\r\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof Infoentity)) {\r\n return false;\r\n }\r\n Infoentity other = (Infoentity) object;\r\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof CompteBancaire)) {\r\n return false;\r\n }\r\n CompteBancaire other = (CompteBancaire) object;\r\n if (this.id != other.id) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Test\n public void testEquals() {\n System.out.println(\"equals\");\n Receta instance = new Receta();\n instance.setNombre(\"nom1\");\n Receta instance2 = new Receta();\n instance.setNombre(\"nom2\");\n boolean expResult = false;\n boolean result = instance.equals(instance2);\n assertEquals(expResult, result);\n }", "@Override\n public boolean equals(Object obj) {\n \n //TODO: Complete Method\n \n return true;\n }", "public boolean equals(Object obj){\r\n\t\tif(!(obj instanceof BaseballCard))\r\n\t\t\treturn false;\r\n\t\tBaseballCard compareable = (BaseballCard) obj;\r\n\t\t\r\n\t\treturn(this.getPrice()==(compareable.getPrice())&&this.getYear()==\r\n\t\t\t\t(compareable.getYear())&&this.getSizeX()==(compareable.getSizeX())\r\n\t\t\t\t&&this.getSizeY()==(compareable.getSizeY())&&this.getName()==\r\n\t\t\t\tcompareable.getName()&&this.getManufacturer()==compareable.getManufacturer());\r\n\t\t\r\n\t}", "@Override public boolean equals(Object object);", "public void testEqualsObject()\n {\n EtatJeu meme = new EtatJeu( myEtat );\n Assert.assertEquals( myEtat, meme );\n \n EtatJeu autre = new EtatJeu();\n \n System.out.println( myEtat.toString());\n Assert.assertTrue( myEtat.equals( autre ));\n }", "@Override\r\n\t\tpublic boolean implementEquals(Object obj) {\n\t\t\treturn false;\r\n\t\t}", "@Override\n public final boolean equals( Object obj ) {\n return super.equals(obj);\n }", "@Override\n public boolean equals(final Object obj) {\n return getClass().isInstance(obj);\n }", "@Override\n public abstract boolean equals(Object obj);", "@Override\r\n public boolean equals(Object obj) {\r\n return super.equals(obj);\r\n }", "@Override\n protected boolean doEquals(Object obj) {\n if (obj instanceof BsAccessResultDiff) {\n BsAccessResultDiff other = (BsAccessResultDiff)obj;\n if (!xSV(_id, other._id)) { return false; }\n if (!xSV(_sessionId, other._sessionId)) { return false; }\n if (!xSV(_ruleId, other._ruleId)) { return false; }\n if (!xSV(_url, other._url)) { return false; }\n if (!xSV(_parentUrl, other._parentUrl)) { return false; }\n if (!xSV(_status, other._status)) { return false; }\n if (!xSV(_httpStatusCode, other._httpStatusCode)) { return false; }\n if (!xSV(_method, other._method)) { return false; }\n if (!xSV(_mimeType, other._mimeType)) { return false; }\n if (!xSV(_contentLength, other._contentLength)) { return false; }\n if (!xSV(_executionTime, other._executionTime)) { return false; }\n if (!xSV(_createTime, other._createTime)) { return false; }\n return true;\n } else {\n return false;\n }\n }", "@Override\n public boolean equals(Object obj) {\n return super.equals(obj);\n }", "@Test\n @DisplayName(\"Test should detect equality between equal states.\")\n public void testShouldResultInEquality() {\n ObjectBag os1 = new ObjectBag(null, \"Hi\");\n ObjectBag os2 = new ObjectBag(null, \"Hi\");\n\n Assertions.assertThat(os1).isEqualTo(os2);\n }", "@Test\n public void testEquals() {\n System.out.println(\"equals\");\n Object outroObjecto = new RegistoExposicoes();\n RegistoExposicoes instance = new RegistoExposicoes();\n assertTrue(instance.equals(outroObjecto));\n }", "public boolean equals(Object anotherObj) {\n if(!(anotherObj instanceof UMarkerSetDTO))\n throw new ClassCastException(\"Object is of wrong class. UMarkerSetDTO object expected but not found.\");\n return umsid == ((UMarkerSetDTO)anotherObj).getUmsid(); \n }", "@Override\n public boolean equals(Object o) {\n return this == o;\n }", "@Override\n boolean equals(Object obj);", "@Test\n public void equals() {\n CsvAdaptedPatient alice = new CsvAdaptedPatient(ALICE);\n CsvAdaptedPatient aliceCopy = new CsvAdaptedPatient(new PatientBuilder(ALICE).build());\n\n assertTrue(alice.equals(aliceCopy));\n\n // same object -> returns true\n assertTrue(alice.equals(alice));\n\n // null -> returns false\n assertFalse(alice.equals(null));\n\n // different type -> returns false\n assertFalse(alice.equals(5));\n\n // different patient -> returns false\n assertFalse(alice.equals(new CsvAdaptedPatient(BOB)));\n\n // different name -> returns false\n Patient editedAlice = new PatientBuilder(ALICE).withName(VALID_NAME_BOB).build();\n assertFalse(alice.equals(new CsvAdaptedPatient(editedAlice)));\n\n // different phone -> returns false\n editedAlice = new PatientBuilder(ALICE).withPhone(VALID_PHONE_BOB).build();\n assertFalse(alice.equals(new CsvAdaptedPatient(editedAlice)));\n\n // different address -> returns false\n editedAlice = new PatientBuilder(ALICE).withAddress(VALID_ADDRESS_BOB).build();\n assertFalse(alice.equals(new CsvAdaptedPatient(editedAlice)));\n\n // different remark -> returns false\n editedAlice = new PatientBuilder(ALICE).withRemark(VALID_REMARK_BOB).build();\n assertFalse(alice.equals(new CsvAdaptedPatient(editedAlice)));\n }", "@Test\n\tpublic void test_TCM__boolean_equals_Object() {\n\t\tfinal Attribute attribute = new Attribute(\"test\", \"value\");\n\n assertFalse(\"attribute equal to null\", attribute.equals(null));\n\n final Object object = attribute;\n assertTrue(\"object not equal to attribute\", attribute.equals(object));\n assertTrue(\"attribute not equal to object\", object.equals(attribute));\n\n // current implementation checks only for identity\n// final Attribute clonedAttribute = (Attribute) attribute.clone();\n// assertTrue(\"attribute not equal to its clone\", attribute.equals(clonedAttribute));\n// assertTrue(\"clone not equal to attribute\", clonedAttribute.equals(attribute));\n\t}", "public boolean equals(Object other){\r\n Car nuCar = (Car)other;\r\n if(super.equals(nuCar)){\r\n if(this.model==nuCar.model&&this.AWD==nuCar.AWD){\r\n return true;\r\n }else{\r\n return false;\r\n }\r\n }else{\r\n return false;\r\n }\r\n\t}", "@Test\n @DisplayName(\"Matched\")\n public void testEqualsMatched() throws BadAttributeException {\n Settings settings = new Settings();\n assertEquals(new Settings().hashCode(), settings.hashCode());\n }", "@Test\n public void testEquals() {\n System.out.println(\"equals\");\n Object object = null;\n Paciente instance = new Paciente();\n boolean expResult = false;\n boolean result = instance.equals(object);\n assertEquals(expResult, result);\n\n }", "@Override\n public boolean equals(final Object obj) {\n return super.equals(obj);\n }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof Brating)) {\r\n return false;\r\n }\r\n Brating other = (Brating) object;\r\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Override\n public final boolean equals(Object obj) {\n return super.equals(obj);\n }", "@Override\n\t\tpublic boolean equals(Object obj) {\n\t\t\treturn super.equals(obj);\n\t\t}", "public boolean equals(Object obj) {\n return (obj instanceof Car) && ((Car) obj).registrationNumber.equals(registrationNumber);\n }", "@Override\n public boolean equals(Object obj) {\n return super.equals(obj);\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof TbAnimalPecuario)) {\n return false;\n }\n TbAnimalPecuario other = (TbAnimalPecuario) object;\n if ((this.idAnimalPecuario == null && other.idAnimalPecuario != null) || (this.idAnimalPecuario != null && !this.idAnimalPecuario.equals(other.idAnimalPecuario))) {\n return false;\n }\n return true;\n }", "@Test\n public void testEquals() {\n \n Beneficiaire instance = ben2;\n Beneficiaire unAutreBeneficiaire = ben3;\n boolean expResult = false;\n boolean result = instance.equals(unAutreBeneficiaire);\n assertEquals(expResult, result);\n\n unAutreBeneficiaire = ben2;\n expResult = true;\n result = instance.equals(unAutreBeneficiaire);\n assertEquals(expResult, result);\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Membre)) {\n return false;\n }\n Membre other = (Membre) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Test\n\tpublic void equalsContract()\n\t{\n\t\tEqualsVerifier.forClass(ExperienceChangedReport.class).verify();\n\t}", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof Structure)) {\r\n return false;\r\n }\r\n Structure other = (Structure) object;\r\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Override\n\tpublic boolean equalsEntity(ACLDriver object) {\n\t\treturn false;\n\t}", "@Test\n void equals1() {\n Student s1=new Student(\"emina\",\"milanovic\",18231);\n Student s2=new Student(\"emina\",\"milanovic\",18231);\n assertEquals(true,s1.equals(s2));\n }", "public final void testSameObjectEquals() {\n final Transaction copy = testTransaction1;\n assertTrue(testTransaction1.equals(copy)); // pmd doesn't like either\n // way\n\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Car)) {\n return false;\n }\n Car other = (Car) object;\n return (this.id != null || other.id == null) && (this.id == null || this.id.equals(other.id));\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof UserInfo)) {\n return false;\n }\n UserInfo other = (UserInfo) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof UserInfo)) {\n return false;\n }\n UserInfo other = (UserInfo) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof UserInfo)) {\n return false;\n }\n UserInfo other = (UserInfo) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Test\n public void equalsSameTest() {\n Device device2 = new Device(deviceID, token);\n assertEquals(device, device2);\n }", "@Override\r\n \tpublic boolean equals(final Object obj) {\r\n \t\t// Insert code to compare the receiver and obj here.\r\n \t\t// This implementation forwards the message to super. You may replace or supplement this.\r\n \t\t// NOTE: obj might be an instance of any class\r\n \t\treturn super.equals(obj);\r\n \t}", "@Override\r\n\tpublic boolean equals(Object obj) {\n\t\treturn super.equals(obj);\r\n\t}", "@Override\r\n\tpublic boolean equals(Object obj) {\n\t\treturn super.equals(obj);\r\n\t}", "@Override\r\n\tpublic boolean equals(Object obj) {\n\t\treturn super.equals(obj);\r\n\t}", "@Override\n public boolean equals(Object obj) {\n if (obj instanceof UsageInfo) {\n UsageInfo info = (UsageInfo)obj;\n return info.getPhysicalMachine().getID() == pm.getID();\n }\n return false;\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Brand)) {\n return false;\n }\n Brand other = (Brand) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof SuppliesMatToFac)) {\r\n return false;\r\n }\r\n SuppliesMatToFac other = (SuppliesMatToFac) object;\r\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof GrnRetrunDetail)) {\n return false;\n }\n GrnRetrunDetail other = (GrnRetrunDetail) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Abstract)) {\n return false;\n }\n Abstract other = (Abstract) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Override\n public boolean equals(Object obj) {\n if (obj == null) {\n return false;\n }\n\n if (TkRefexAbstractMember.class.isAssignableFrom(obj.getClass())) {\n TkRefexAbstractMember<?> another = (TkRefexAbstractMember<?>) obj;\n\n // =========================================================\n // Compare properties of 'this' class to the 'another' class\n // =========================================================\n // Compare refsetUuid\n if (!this.refexUuid.equals(another.refexUuid)) {\n return false;\n }\n\n // Compare componentUuid\n if (!this.componentUuid.equals(another.componentUuid)) {\n return false;\n }\n\n // Compare their parents\n return super.equals(obj);\n }\n\n return false;\n }", "@Override \n boolean equals(Object obj);", "public boolean equals(Object obj)\n {\n //first, make sure objects are equal at the base\n //which also handles null and type for person check\n boolean baseResult = super.equals(obj);\n if (!baseResult)\n {\n return false;\n }\n \n //next, make sure it's a commander, and not just any old person\n if (!(obj instanceof Commander))\n {\n return false;\n }\n \n //cast and compare specific properties for equality:\n Commander c = (Commander)obj;\n return (this.getSerialNumber().equals(c.getSerialNumber())\n && this.getRank().equals(c.getRank()));\n }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof TransportClientInfo)) {\r\n return false;\r\n }\r\n TransportClientInfo other = (TransportClientInfo) object;\r\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Test\n public void testEquals() {\n System.out.println(\"equals\");\n Commissioner instance = new Commissioner();\n Commissioner instance2 = new Commissioner();\n instance.setLogin(\"genie\");\n instance2.setLogin(\"genie\");\n boolean expResult = true;\n boolean result = instance.equals(instance2);\n assertEquals(expResult, result);\n }", "public void testEqualsObject()\n {\n // Null check\n assertFalse(b1.equals(null));\n // Type mismatch\n assertFalse(b1.equals(\"a\"));\n\n // Reflexive\n assertTrue(b1.equals(b1));\n\n // In general, two empty boards\n assertTrue(b1.equals(b2));\n\n // Different contents\n b1.setCell(0, 0, Cell.RED1);\n assertFalse(b1.equals(b2));\n\n // Same Contents\n b2.setCell(0, 0, Cell.RED1);\n assertTrue(b1.equals(b2));\n\n // Some more complex cases\n b1.fromString(\"RRRBEEBBE\");\n assertFalse(b1.equals(b2));\n b2.fromString(\"RRRBEEBBE\");\n assertTrue(b1.equals(b2));\n\n }", "@NeededForTesting\n public static boolean areObjectsEqual(Object a, Object b) {\n return a == b || (a != null && a.equals(b));\n }", "@Test\n public void testEqualsReturnsTrueOnSelfArg() {\n boolean equals = record.equals(record);\n\n assertThat(equals, is(true));\n }", "@Override\n public boolean equals(Object o) {\n return true;\n }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof CarPayment)) {\r\n return false;\r\n }\r\n CarPayment other = (CarPayment) object;\r\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Sacrificio)) {\n return false;\n }\n Sacrificio other = (Sacrificio) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Override\n\tpublic boolean equals(TestObject obj) {\n\t\treturn false;\n\t}", "public abstract boolean equals(Object o);", "@Override\n\tpublic boolean equals(Object obj){\n\t\treturn super.equals(obj);\n\t}", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof BancosTO)) {\n return false;\n }\n BancosTO other = (BancosTO) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "public boolean equals(Object inputObj) {\n\t\t\tboolean eredmeny = false;\n\t\t\tif (this.hashCode() == inputObj.hashCode()) {\n\t\t\t\teredmeny = true;\n\t\t\t}\n\t\t\treturn eredmeny;\n\t\t}", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof MejObra)) {\n return false;\n }\n MejObra other = (MejObra) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Rolistafit)) {\n return false;\n }\n Rolistafit other = (Rolistafit) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "@Override\n public boolean equals(Object object) {\n if (!(object instanceof Matiere)) {\n return false;\n }\n Matiere other = (Matiere) object;\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\n return false;\n }\n return true;\n }", "public boolean equals(Object object);", "@Test\n public void testEquals01() {\n System.out.println(\"equals\");\n Object otherObject = new SocialNetwork();\n SocialNetwork sn = new SocialNetwork();\n boolean result = sn.equals(otherObject);\n assertTrue(result);\n }", "@Test\n public void testEquals02() {\n System.out.println(\"equals\");\n Object otherObject = new SocialNetwork();\n boolean result = sn10.equals(otherObject);\n assertFalse(result);\n }", "public boolean equals( Object obj );", "@Override\r\n public boolean equals(Object o){\r\n boolean equals=false;\r\n if (o!=null) {\r\n equals=(this.id==((Car)o).id)&&\r\n this.currentPosition.equals(((Car)o).currentPosition)\r\n &&this.orientation==((Car)o).orientation&&this.size==((Car)o).size;\r\n }\r\n return equals;\r\n }", "@Override\n\tpublic boolean equals(Object obj) {\n\t\treturn this.hashCode() == obj.hashCode();\n\t}", "@Override\n\tpublic boolean equals(Object obj) {\n\t\treturn this.hashCode() == obj.hashCode();\n\t}", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof Utilisateur)) {\r\n return false;\r\n }\r\n Utilisateur other = (Utilisateur) object;\r\n if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {\r\n return false;\r\n }\r\n return true;\r\n }", "@Override\r\n\tpublic boolean equals(Object ob){\n\t\tItem itemob=(Item)ob;\t//transfer object type to Item type\r\n\t\tif(this.UID==itemob.UID && this.TITLE==itemob.TITLE && this.NOOFCOPIES==itemob.NOOFCOPIES) {\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "public boolean equals(Object obj) {\n if (!super.equals(obj)) {\n return false;\n }\n\n if (obj.getClass() != getClass()) {\n return false;\n }\n \n return true;\n }", "public final boolean equals(Object obj) {\r\n return this == obj;\r\n }", "@Test\n public void equals() {\n Beneficiary animalShelterCopy = new BeneficiaryBuilder(ANIMAL_SHELTER).build();\n assertTrue(ANIMAL_SHELTER.equals(animalShelterCopy));\n\n // same object -> returns true\n assertTrue(ANIMAL_SHELTER.equals(ANIMAL_SHELTER));\n\n // null -> returns false\n assertFalse(ANIMAL_SHELTER.equals(null));\n\n // different type -> returns false\n assertFalse(ANIMAL_SHELTER.equals(5));\n\n // different beneficiary -> returns false\n assertFalse(ANIMAL_SHELTER.equals(BABES));\n\n // same name -> returns true\n Beneficiary editedAnimalShelter = new BeneficiaryBuilder(BABES).withName(VALID_NAME_ANIMAL_SHELTER).build();\n assertTrue(ANIMAL_SHELTER.equals(editedAnimalShelter));\n\n // same phone and email -> returns true\n editedAnimalShelter = new BeneficiaryBuilder(BABES)\n .withPhone(VALID_PHONE_ANIMAL_SHELTER).withEmail(VALID_EMAIL_ANIMAL_SHELTER).build();\n assertTrue(ANIMAL_SHELTER.equals(editedAnimalShelter));\n }" ]
[ "0.6658906", "0.66270715", "0.65986484", "0.65181756", "0.6424391", "0.64228094", "0.64119714", "0.63973033", "0.63678515", "0.6356584", "0.628636", "0.62790716", "0.62727714", "0.6210926", "0.6199248", "0.61782545", "0.6175177", "0.61645633", "0.6160269", "0.61283994", "0.61247313", "0.61217964", "0.6119354", "0.6118619", "0.60983247", "0.6096462", "0.6077887", "0.60752463", "0.60742366", "0.6062986", "0.6055094", "0.6052186", "0.6031353", "0.60198945", "0.6011897", "0.6011216", "0.60066766", "0.6006594", "0.60062116", "0.60043484", "0.5996507", "0.5991826", "0.5983449", "0.5982162", "0.5981507", "0.5980368", "0.5968003", "0.59659207", "0.59598553", "0.59550637", "0.59502804", "0.59499514", "0.593426", "0.5930626", "0.59277666", "0.5917812", "0.59156036", "0.59156036", "0.59156036", "0.5913985", "0.5912131", "0.5910583", "0.5910583", "0.5910583", "0.5900739", "0.5893076", "0.58867985", "0.5884208", "0.58836603", "0.5882904", "0.58807194", "0.58774203", "0.5875806", "0.58753794", "0.58724785", "0.58591974", "0.5855447", "0.5855133", "0.5853951", "0.58537483", "0.5852121", "0.5851704", "0.58513856", "0.58488125", "0.58482844", "0.5847772", "0.58456534", "0.58441806", "0.5842512", "0.5840545", "0.5838598", "0.58376086", "0.5837473", "0.5831415", "0.5831415", "0.58269006", "0.58239865", "0.5813774", "0.58134", "0.58106416" ]
0.72465515
0
Return the Identifier of the absorber L2Character.
@Override public int hashCode() { return absorber.getObjectId(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "java.lang.String getIdentifier();", "int getIdentifier();", "public char getId() {\n return id;\n }", "long getLetterId();", "long getLetterId();", "public char getId() {\n return this.id;\n }", "public int getIdentifier();", "String getIdentifier();", "String getIdentifier();", "String getIdentifier();", "String getIdentifier();", "String getIdentifier();", "String getIdentifier();", "String getIdentifier();", "public String getIdentifierString();", "I getIdentifier();", "public int charNum() {\n return myId.charNum();\n }", "public int getCharacterId() {\n return characterId;\n }", "public Character Id() {\n return null;\n }", "public char getID() {\n return this.id;\n }", "public String getIdentifier();", "public String getIdentifier();", "public ConstellationIdentifier identifier();", "public int identifier();", "protected abstract String getIdentifier();", "public long getCharacterId() {\n return this.characterId;\n }", "@Override\r\n public final Integer getIdentifier() {\r\n return getIdent();\r\n }", "public String getId() {\n String id = name.replaceAll(\" \", \"-\");\n id = id.replaceAll(\"_\", \"-\");\n return id.toLowerCase();\n }", "public char getId(){return this.id;}", "public byte get_charId(){\n return character_id;\n }", "java.lang.String getAoisId();", "Identifier getId();", "public java.lang.String getIdentifier() {\n java.lang.Object ref = identifier_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n identifier_ = s;\n }\n return s;\n }\n }", "public String asIdentifier() {\n\t\treturn this.keyword.toLowerCase().replace(' ', '_').replace('.', '_');\n\t}", "public String code() {\n\t\treturn (\"ID\"+this.hashCode()).replace(\"-\", \"M\");\n\t}", "ELEMENTIDENTIFIER getIdentifier();", "org.hl7.fhir.Identifier getIdentifier();", "Character getCode();", "public CWE getAdministeredBarcodeIdentifier() { \r\n\t\tCWE retVal = this.getTypedField(25, 0);\r\n\t\treturn retVal;\r\n }", "@NonNull String identifier();", "public java.lang.String getIdentifier() {\n java.lang.Object ref = identifier_;\n if (!(ref instanceof java.lang.String)) {\n java.lang.String s = ((com.google.protobuf.ByteString) ref)\n .toStringUtf8();\n identifier_ = s;\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }", "public String identifier(){\n\n if (currentTokenType == TYPE.IDENTIFIER){\n\n return currentToken;\n\n }else {\n throw new IllegalStateException(\"Current token is not an identifier! current type:\" + currentTokenType);\n }\n }", "public int getIdentifier()\n {\n return identifier;\n }", "public String getIdentifier() {\n/* 222 */ return getValue(\"identifier\");\n/* */ }", "@XmlElement(name = \"identifier\", namespace = Namespaces.SRV)\n final String getIdentifier() {\n if (LEGACY_XML) {\n final ScopedName name = getScopedName();\n if (name != null) {\n return name.tip().toString();\n }\n }\n return null;\n }", "private String getIdentifierToken(char[] characters) \n\t{\n\t\tString currentToken = \"\";\n\t\t//pos of current character\n\t\tint i;\n\t\t//look at each character\n\t\tfor (i=0; i<characters.length; i++)\n\t\t{\n\t\t\t//working with char ch\n\t\t\tchar ch = characters[i];\n\t\t\t//check if whitespace\n\t\t\tboolean ws = Character.isWhitespace(ch);\n\t\t\t//check type\n\t\t\tString type = getType(ch);\n\n\t\t\tif ( !ws && Objects.equals(type, \"uppercase\"))\n\t\t\t{\n\t\t\t\tcurrentToken = currentToken.concat(String.valueOf(ch));\n\t\t\t}\n\t\t\t//not whitespace and special ch, token found, must be valid token\n\t\t\telse if ( !ws && Objects.equals(type, \"special\"))\n\t\t\t{\n\t\t\t\treturn currentToken;\n\t\t\t}\n\t\t\t//whitespace found\n\t\t\telse if ( ws )\n\t\t\t{\n\t\t\t\treturn currentToken;\n\t\t\t}\n\t\t\telse if (Objects.equals(type, \"int\"))\n\t\t\t{\n\t\t\t\tcurrentToken = currentToken.concat(String.valueOf(ch));\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tSystem.out.println(\"\\n\"+\"not a valid identifier!\");\n\t\t\t\tSystem.exit(0);\n\t\t\t}\n\t\t}\n\t\t//ran out of tokens to process (end of line)\n\t\treturn currentToken;\n\t}", "public String nextIdentifier()\n {\n int end = scanForIdentifier();\n if (end == position)\n return null;\n String result = input.substring(position, end);\n position = end;\n return result;\n }", "public String getIdentifier() {\n\t\treturn config.getUIName()+\"[\"+getIndex()+\"]\";\n\t}", "@Override\n\tpublic String getIdentifier() {\n\t\treturn \"identifier: \" + this.identifier + \" From B implementation\";\n\t}", "public StrColumn getRange2BegLabelAtomId() {\n return delegate.getColumn(\"range_2_beg_label_atom_id\", DelegatingStrColumn::new);\n }", "int toIdentifier() {\n return 1000 * y + x;\n }", "public StrColumn getRange2BegAuthAtomId() {\n return delegate.getColumn(\"range_2_beg_auth_atom_id\", DelegatingStrColumn::new);\n }", "public String getIdentifier()\n\t{\n\t\treturn mIdentifier;\n\t}", "public String getIdentifier() {\r\n\t\treturn this.identifier;\r\n\t}", "public String getId()\r\n\t{\n\t\treturn id.substring(2, 5);\r\n\t}", "public StrColumn getRange2EndLabelAtomId() {\n return delegate.getColumn(\"range_2_end_label_atom_id\", DelegatingStrColumn::new);\n }", "public StrColumn getRange2EndAuthAtomId() {\n return delegate.getColumn(\"range_2_end_auth_atom_id\", DelegatingStrColumn::new);\n }", "public final ASN1Identifier getIdentifier()\n {\n return content.getIdentifier();\n }", "public int getID() {\r\n // Bouml preserved body begin 00040D02\r\n\t System.out.println(ID);\r\n\t return ID;\r\n // Bouml preserved body end 00040D02\r\n }", "@Override\n public String getIdentifier() {\n return myIdentity.getIdentifier();\n }", "@AutoEscape\n\tpublic String getIdCanal();", "CharacterInfo getCharacter();", "public String getIdentifier() {\n try {\n return keyAlias + \"-\" + toHexString(\n MessageDigest.getInstance(\"SHA1\").digest(keyStoreManager.getIdentifierKey(keyAlias).getEncoded()));\n } catch (Exception e) {\n throw new RuntimeException(e);\n }\n }", "public String getIdentifier()\n {\n return identifier;\n }", "public String getCharName(){return charName;}", "public native String getIdentifier();", "public byte[] id() {\n return Token.concat(Token.DOLLAR, name.internal());\n }", "public String getIdentifier() {\n return identifier;\n }", "public java.lang.String getIdentifierValue() {\r\n return localIdentifierValue;\r\n }", "public int getCharno() {\n return charno;\n }", "public java.lang.String getIdentifier()\n {\n synchronized (monitor())\n {\n check_orphaned();\n org.apache.xmlbeans.SimpleValue target = null;\n target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(IDENTIFIER$0, 0);\n if (target == null)\n {\n return null;\n }\n return target.getStringValue();\n }\n }", "ManifestIdentifier getIdentifier();", "public CWE getRxa25_AdministeredBarcodeIdentifier() { \r\n\t\tCWE retVal = this.getTypedField(25, 0);\r\n\t\treturn retVal;\r\n }", "public String getIdentifier() {\n return identifier;\n }", "public String getIdentifier() {\n return identifier;\n }", "public String getIdentifier() {\n return identifier;\n }", "public String getIdentifier() {\n return identifier;\n }", "public String getIdentifier() {\n return identifier;\n }", "public String getIdentifier() {\n return identifier;\n }", "public String getIdentifier() {\n return identifier;\n }", "public String getIdentifier() {\n return identifier;\n }", "java.lang.String getID();", "java.lang.String getSymbolId();", "String getIdentifierName(String name, String type);", "public byte getId() {\n return 2;\n }", "public StrColumn getAsymId() {\n return (StrColumn) (isText ? textFields.computeIfAbsent(\"asym_id\", StrColumn::new) :\n getBinaryColumn(\"asym_id\"));\n }", "public T getIdentifier();", "public String getIdentifier() {\n\t\treturn identifier;\n\t}", "public java.lang.String getSecondEscCuid() {\n return secondEscCuid;\n }", "@AutoEscape\n\tpublic String getIdSubCanal();", "public StrColumn getLabelAsymId() {\n return (StrColumn) (isText ? textFields.computeIfAbsent(\"label_asym_id\", StrColumn::new) :\n getBinaryColumn(\"label_asym_id\"));\n }", "public String readS2ChipID() {\r\n return mFactoryBurnUtil.readS2ChipID();\r\n }", "public String getCharacter()\n\t\t{\n\t\t\treturn characterName;\n\t\t}", "public abstract java.lang.String getIdpc();", "Rule Identifier() {\n // Push 1 IdentifierNode onto the value stack\n return Sequence(\n Sequence(\n FirstOf(Letter(), \"_\"),\n ZeroOrMore(IndentChar())),\n actions.pushIdentifierNode(),\n WhiteSpace());\n }", "String mo10312id();", "public long getLetterId() {\n return letterId_;\n }", "public long getLetterId() {\n return letterId_;\n }", "public StrColumn getRange2BegAuthSeqId() {\n return delegate.getColumn(\"range_2_beg_auth_seq_id\", DelegatingStrColumn::new);\n }", "public StrColumn getRange2EndAuthSeqId() {\n return delegate.getColumn(\"range_2_end_auth_seq_id\", DelegatingStrColumn::new);\n }", "private String idString(int occurrence) {\n if (occurrence == 0) {\n return null;\n }\n String stringRep = \"\";\n while (occurrence > 0) {\n // generate character from A-Z and add to stringRep\n char nextChar = (char) ((occurrence - 1) % 26 + 'A');\n stringRep = nextChar + stringRep;\n occurrence = (occurrence - 1) / 26;\n }\n return stringRep;\n }" ]
[ "0.66616374", "0.6420981", "0.6405575", "0.6355067", "0.6355067", "0.6335264", "0.6335245", "0.6302969", "0.6302969", "0.6302969", "0.6302969", "0.6302969", "0.6302969", "0.6302969", "0.62942684", "0.6285131", "0.6260383", "0.62189543", "0.62179846", "0.6217972", "0.61548567", "0.61548567", "0.61319065", "0.6119557", "0.6101088", "0.6034074", "0.6024874", "0.6011912", "0.60063326", "0.59224063", "0.59063196", "0.58939815", "0.58843076", "0.5881444", "0.5861114", "0.5854926", "0.5853387", "0.58461773", "0.5834609", "0.58324736", "0.581684", "0.580714", "0.58029205", "0.5796437", "0.5774925", "0.57715297", "0.5750607", "0.5747406", "0.5747018", "0.5745146", "0.57103485", "0.57029307", "0.5692876", "0.56839645", "0.5675582", "0.5671596", "0.56692505", "0.5662463", "0.5660751", "0.56587917", "0.5650331", "0.5647148", "0.5644853", "0.5641147", "0.56333566", "0.56310964", "0.56292826", "0.5609191", "0.5589783", "0.5586593", "0.558506", "0.55826956", "0.55814666", "0.5580478", "0.5580478", "0.5580478", "0.5580478", "0.5580478", "0.5580478", "0.5580478", "0.5580478", "0.556162", "0.55589056", "0.5553496", "0.55393016", "0.55374897", "0.55349123", "0.5527683", "0.5508397", "0.55004257", "0.54983413", "0.54886085", "0.54857814", "0.54643553", "0.5446663", "0.5445128", "0.54434156", "0.54434156", "0.544231", "0.54412925", "0.5441215" ]
0.0
-1
Use this to Read or Put Object to this Map
public final Map<L2Character, AggroInfoHolder> getAggroListRP() { return aggroList; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Object objectAt(Position position){\n return mapElement.get(position);\n }", "private void readObject() {}", "private void readObject() {}", "private void readObject() {}", "public boolean put( KEY key, OBJECT object );", "private void readObject() {\n }", "@Override\r\n\tpublic void putObject(Object key, Object value) {\n\t\t\r\n\t}", "public Object get(String key) {\n return objectMap.get(key);\n }", "public Object get(String key) {\r\n\t\treturn objectMap.get(key);\r\n\t}", "@Override\n\tpublic void read(Object entidade) {\n\t\t\n\t}", "protected abstract Object read ();", "@Override\r\n public void store(long key, O object) throws OBException {\n }", "void put(String key, Object obj);", "Object put(Object key, Object value);", "Object put(Object key, Object value) throws NullPointerException;", "public boolean put(T obj);", "public Object get(Object oKey)\n {\n Map.Entry entry = getEntry(oKey);\n return (entry == null ? null : entry.getValue());\n }", "private void method_278(ObjectInputStream var1) {\n var1.defaultReadObject();\n this.a = (Map)var1.readObject();\n }", "public abstract <T> T readObject();", "@Override\n public void put(Object o, Person person) {\n \n }", "private void readObject(final ObjectInputStream in) throws IOException, ClassNotFoundException\n\t{\n\t\t// read values\n\t\tin.defaultReadObject();\n\n\t\tOutputStream output = getOutputStream();\n\t\tif (cachedContent != null)\n\t\t{\n\t\t\toutput.write(cachedContent);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tFileInputStream input = new FileInputStream(dfosFile);\n\t\t\tStreams.copy(input, output);\n\t\t\tFiles.remove(dfosFile);\n\t\t\tdfosFile = null;\n\t\t}\n\t\toutput.close();\n\n\t\tcachedContent = null;\n\t}", "ISObject get(String key);", "public abstract CacheKey put(Vector primaryKey, Object object, Object writeLockValue, long readTime);", "private void writeObject(final ObjectOutputStream out) throws IOException\n\t{\n\t\t// Read the data\n\t\tif (dfos.isInMemory())\n\t\t{\n\t\t\tcachedContent = get();\n\t\t}\n\t\telse\n\t\t{\n\t\t\tcachedContent = null;\n\t\t\tdfosFile = dfos.getFile();\n\t\t}\n\n\t\t// write out values\n\t\tout.defaultWriteObject();\n\t}", "@Override\r\n\tpublic void updateCar(HashMap carMap) throws DataAccessException {\n\t\t\r\n\t}", "void put(String key, Object value);", "public static Object put(String name, Object object) {\n // Make sure the name and object are both in persistent memory first\n object = makePersistentCopy(object);\n name = (String)makePersistentCopy(name);\n\n PersistentRootEntry entry = (PersistentRootEntry)Native.getPersistentMemoryTable();\n PersistentRootEntry unusedEntry = null;\n while (entry != null) {\n String ename = entry.name;\n if (ename != null) {\n if (ename.equals(name)) {\n Object o = entry.value;\n entry.value = object;\n return o;\n }\n } else if (unusedEntry == null) {\n // Re-use first available unused entry\n unusedEntry = entry;\n }\n entry = entry.next;\n }\n\n if (unusedEntry == null) {\n unusedEntry = new PersistentRootEntry();\n unusedEntry.value = object;\n unusedEntry.name = name;\n\n PersistentRootEntry table = (PersistentRootEntry)Native.getPersistentMemoryTable();\n if (table != null) {\n unusedEntry.next = table;\n }\n table = (PersistentRootEntry)makePersistentCopy(unusedEntry);\n Native.setPersistentMemoryTable(table);\n } else {\n // Must write object first as writing the name essentially\n // links this entry into the roots and therefore must be\n // atomic.\n unusedEntry.value = object;\n unusedEntry.name = name;\n }\n return null;\n }", "public Object Get(String objectName)\n\t{\n\t\tif(storage.containsKey(objectName))\n\t\t\treturn storage.get(objectName);\n\t\tlog.debug(\"The object [\"+objectName+\"] doesn't exist in the room, return Null\");\n\t\treturn null;\n\t}", "public Object put(String aName, Object anObj)\n{\n // If map shared, clone it for real\n if(_attrMap.isShared())\n _attrMap = _attrMap.cloneX();\n \n // Put value (or remove if null)\n return anObj!=null? _attrMap.put(aName, anObj) : _attrMap.remove(aName);\n}", "void put(String name, Object value);", "public Object read();", "public EncogPersistedObject readObject(final String name) {\r\n\r\n\t\t// did we find the object?\r\n\t\tif (advance(name)) {\r\n\t\t\tfinal String objectType = this.in.getTag().getName();\r\n\t\t\tfinal Persistor persistor = PersistorUtil\r\n\t\t\t\t\t.createPersistor(objectType);\r\n\r\n\t\t\tif (persistor == null) {\r\n\t\t\t\tthrow new PersistError(\"Do not know how to load: \" + objectType);\r\n\t\t\t}\r\n\t\t\treturn persistor.load(this.in);\r\n\t\t} else {\r\n\t\t\treturn null;\r\n\t\t}\r\n\t}", "@Override\n\tpublic String update(Map<String, Object> entityMap)\n\t\t\tthrows DataAccessException {\n\t\treturn null;\n\t}", "private void readObject(java.io.ObjectInputStream s)\n throws java.io.IOException, ClassNotFoundException {\n s.defaultReadObject();\n\n // Read in size (number of Mappings)\n int size = s.readInt();\n if (size < 0)\n throw new java.io.StreamCorruptedException\n (\"Illegal mappings count: \" + size);\n int cap = capacity(size);\n SharedSecrets.getJavaOISAccess().checkArray(s, Object[].class, cap);\n init(cap);\n\n // Read the keys and values, and put the mappings in the table\n for (int i=0; i<size; i++) {\n @SuppressWarnings(\"unchecked\")\n K key = (K) s.readObject();\n @SuppressWarnings(\"unchecked\")\n V value = (V) s.readObject();\n putForCreate(key, value);\n }\n }", "public void put(T data){\r\n\t\tthis.data = data;\r\n\t}", "public Storable readStorable() throws IOException {\n Storable storable;\n String s = readString();\n\n if (s.equals(\"NULL\"))\n return null;\n\n if (s.equals(\"REF\")) {\n int ref = readInt();\n return (Storable) retrieve(ref);\n }\n\n storable = (Storable) makeInstance(s);\n map(storable);\n storable.read(this);\n return storable;\n }", "public void map()\n\t{\n\t // key is the documentId\n\t\t// value is the url\n\t\t//fetch the document using the documentId\n\t\t\n\t}", "<T> void put(String key, T data);", "void writeObject(Map<Object, Object> map);", "@Override\n\tpublic Object readObject() {\n\t\treturn super.readObject();\n\t}", "T put(T obj) throws DataElementPutException, RepositoryAccessDeniedException;", "@PUT\n @Consumes({\"application/xml\", \"application/json\"})\n public void put(SourceInterestMapConverter data) {\n PersistenceService persistenceSvc = PersistenceService.getInstance();\n try {\n persistenceSvc.beginTx();\n EntityManager em = persistenceSvc.getEntityManager();\n updateEntity(getEntity(), data.resolveEntity(em));\n persistenceSvc.commitTx();\n } finally {\n persistenceSvc.close();\n }\n }", "public Object get(Object key) {\n IEntry e = map.get(key);\n if (e == null) {\n return null;\n }\n if (currentMode == Scope.APPLICATION) {\n if (e.scope == Scope.APPLICATION) {\n return e.obj;\n } else {\n return null;\n }\n } else {\n return e.obj;\n }\n }", "@SuppressWarnings(\"unchecked\")\r\n private void newMap() throws IOException, ClassNotFoundException {\r\n this.music_map.clear();\r\n if (needNewMap()) {\r\n if (!save_file.exists()) {\r\n System.out.println(\"DIZIONARIO NON PRESENTE\");\r\n System.out.println(\"CREAZIONE NUOVO DIZIONARIO IN CORSO...\");\r\n\r\n this.setTarget();\r\n\r\n this.recoursiveMapCreation(this.music_root);\r\n this.saveMap();\r\n } else {\r\n System.out.println(\"DIZIONARIO NON AGGIORNATO\");\r\n if (!UtilFunctions.newDictionaryRequest(this.save_file, this.music_root)) {\r\n System.out.println(\"AGGIORNAMENTO DIZIONARIO RIFIUTATO\");\r\n FileInputStream f = new FileInputStream(this.save_file);\r\n ObjectInputStream o = new ObjectInputStream(f);\r\n this.music_map.putAll((Map<String, String[]>) o.readObject());\r\n current.set(ProgressDialog.TOTAL.get());\r\n } else {\r\n System.out.println(\"CREAZIONE NUOVO DIZIONARIO IN CORSO...\");\r\n this.setTarget();\r\n this.recoursiveMapCreation(this.music_root);\r\n this.saveMap();\r\n }\r\n }\r\n } else {\r\n System.out.println(\"DIZIONARIO GIA' PRESENTE\");\r\n FileInputStream f = new FileInputStream(this.save_file);\r\n ObjectInputStream o = new ObjectInputStream(f);\r\n this.music_map.putAll((Map<String, String[]>) o.readObject());\r\n current.set(ProgressDialog.TOTAL.get());\r\n }\r\n }", "public ObjectMap put(String key, String value) throws JsonException {\r\n\t\tobjectMap.put(check_Key(key), value);\r\n\t\treturn this;\r\n\t}", "public synchronized Object put( Object key, Object object ) {\n\t\tObject oldPos = mapKeyPos.get(key);\n\t\tif ( oldPos != null ) {\n\t\t\tint pos = ((Integer)oldPos).intValue();\n\t\t\tObject oldObject = values[pos];\n\t\t\tvalues[pos] = object;\n\t\t\tstatus[pos] = LRU_NEW;\n\t\t\tdispose( oldObject );\n\t\t\treturn oldObject;\n\t\t} else {\n\t\t\t// skip to new pos -- for Cache, change walkStatus() to get lock....\n\t\t\twhile (walkStatus() != LRU_OLD) {}\n\n\t\t\tObject intvalue;// = null;\n\t\t\tif ( keys[cur] != null ) {\n\t\t\t\tintvalue = mapKeyPos.remove(keys[cur]);\n//\t\t\t\tif ( intvalue == null )\n//\t\t\t\t\tintvalue = new Integer(cur);\n\t\t\t} else {\n\t\t\t\tintvalue = new Integer(cur);\n\t\t\t}\n\t\t\tObject oldObject = values[cur];\n\t\t\tkeys[cur] = key;\n\t\t\tvalues[cur] = object;\n\t\t\tstatus[cur] = LRU_NEW;\n\t\t\t//System.out.println(\"mapKeyPos, key: \"+key+\" intvalue: \"+intvalue);\n\t\t\tmapKeyPos.put(key, intvalue);\n\t\t\tcur++;\n\t\t\tif ( cur >= size ) cur = 0;\n\t\t\tif ( oldObject != null )\n\t\t\t\tdispose( oldObject );\n\t\t\treturn oldObject;\n\t\t}\n\t}", "public abstract <T> void update(String id, Map<String, Object> objectMap, Class<T> clazz);", "public void setMapObject(Map<String, Object> mapObject) {\r\n\t\tthis.objectMap = mapObject;\r\n\t}", "public Object get(Map<Prop, Object> map) {\n Object o = map.get(this);\n return o != null ? o : defaultValue;\n }", "@Override\r\n\tpublic void read(Object id) {\n\t\t\r\n\t}", "@Override\n\tpublic String put(KomisyonModel model) throws IOException {\n\t\treturn null;\n\t}", "Object read(Object inputObject, Settings settings);", "public Object putItem (String key, Object item);", "public interface MapResource {\n\n\t/**\n\t * @return true if the resource is valid\n\t */\n\tpublic boolean isValid();\n\t\n\t/**\n\t * @return null or a short string summary of the resource's state (suitable for an etag)\n\t */\n\tpublic String getIdentityTag();\n\t\n\t/**\n\t * Create a new map or return a recycled one\n\t * @return map\n\t */\n\tpublic abstract mapnik.Map createMap(Object recycleTag);\n\n\t/**\n\t * Recycle a map instance\n\t * @param m\n\t */\n\tpublic abstract void recycleMap(Object recycleTag, mapnik.Map m);\n\n}", "public synchronized final Object readObject() {\n\t\tif (!inQueue.isEmpty())\n\t\t\treturn inQueue.dequeue();\n\t\telse return null;\n\t}", "private int setValue(final PdfObject pdfObject,int i, final byte[] raw, final int length, final boolean map) {\n final boolean ignoreRecursion=pdfObject.ignoreRecursion();\n \n if(debugFastCode) {\n System.out.println(padding + pdfObject.getObjectRefAsString() + \" =================Reading value for key=\" + PDFkey + \" (\" + PDFkeyInt + \") type=\" + PdfDictionary.showAsConstant(pdfKeyType) + \" ignorRecursion=\" + ignoreRecursion + ' ' + pdfObject);\n }\n \n //resolve now in this case as we need to ensure all parts present\n if(pdfKeyType==PdfDictionary.VALUE_IS_UNREAD_DICTIONARY && pdfObject.isDataExternal()) {\n pdfKeyType = PdfDictionary.VALUE_IS_DICTIONARY;\n }\n \n \n switch(pdfKeyType){\n \n //read text stream (this is text) and also special case of [] in W in CID Fonts\n case PdfDictionary.VALUE_IS_TEXTSTREAM:{\n i = TextStream.setTextStreamValue(pdfObject, i, raw, ignoreRecursion,PDFkeyInt, objectReader);\n break;\n \n }case PdfDictionary.VALUE_IS_NAMETREE:{\n i = Name.setNameTreeValue(pdfObject, i, raw, length, ignoreRecursion,PDFkeyInt,objectReader);\n break;\n \n //readDictionary keys << /A 12 0 R /B 13 0 R >>\n }case PdfDictionary.VALUE_IS_DICTIONARY_PAIRS:{\n i = Dictionary.setDictionaryValue(pdfObject, i, raw, length, ignoreRecursion,objectReader,PDFkeyInt);\n break;\n \n //Strings\n }case PdfDictionary.VALUE_IS_STRING_ARRAY:{\n final Array objDecoder=new Array(objectReader,i, endPt, PdfDictionary.VALUE_IS_STRING_ARRAY);\n i=objDecoder.readArray(ignoreRecursion, raw, pdfObject, PDFkeyInt);\n break;\n \n //read Object Refs in [] (may be indirect ref)\n }case PdfDictionary.VALUE_IS_BOOLEAN_ARRAY:{\n final Array objDecoder=new Array(objectReader, i, endPt, PdfDictionary.VALUE_IS_BOOLEAN_ARRAY);\n i=objDecoder.readArray(false, raw, pdfObject, PDFkeyInt);\n break;\n \n //read Object Refs in [] (may be indirect ref)\n }case PdfDictionary.VALUE_IS_KEY_ARRAY:{\n final Array objDecoder=new Array(objectReader, i, endPt, PdfDictionary.VALUE_IS_KEY_ARRAY);\n i=objDecoder.readArray(ignoreRecursion, raw, pdfObject, PDFkeyInt);\n break;\n \n //read numbers in [] (may be indirect ref)\n }case PdfDictionary.VALUE_IS_MIXED_ARRAY:{\n final Array objDecoder=new Array(objectReader, i, endPt, PdfDictionary.VALUE_IS_MIXED_ARRAY);\n i=objDecoder.readArray(ignoreRecursion, raw, pdfObject, PDFkeyInt);\n break;\n \n //read numbers in [] (may be indirect ref) same as Mixed but allow for recursion and store as objects\n }case PdfDictionary.VALUE_IS_OBJECT_ARRAY:{\n final Array objDecoder=new Array(objectReader, i, endPt, PdfDictionary.VALUE_IS_OBJECT_ARRAY);\n i=objDecoder.readArray(false, raw, pdfObject, PDFkeyInt);\n break;\n \n //read numbers in [] (may be indirect ref)\n }case PdfDictionary.VALUE_IS_DOUBLE_ARRAY:{\n final Array objDecoder=new Array(objectReader, i, endPt, PdfDictionary.VALUE_IS_DOUBLE_ARRAY);\n i=objDecoder.readArray(false, raw, pdfObject,PDFkeyInt);\n break;\n \n //read numbers in [] (may be indirect ref)\n }case PdfDictionary.VALUE_IS_INT_ARRAY:{\n final Array objDecoder=new Array(objectReader, i, endPt, PdfDictionary.VALUE_IS_INT_ARRAY);\n i=objDecoder.readArray(false, raw, pdfObject, PDFkeyInt);\n break;\n \n //read numbers in [] (may be indirect ref)\n }case PdfDictionary.VALUE_IS_FLOAT_ARRAY:{\n final Array objDecoder=new Array(objectReader, i, endPt, PdfDictionary.VALUE_IS_FLOAT_ARRAY);\n i=objDecoder.readArray(false, raw, pdfObject, PDFkeyInt);\n break;\n \n //read String (may be indirect ref)\n }case PdfDictionary.VALUE_IS_NAME:{\n i = Name.setNameStringValue(pdfObject, i, raw, map,PDFkey, PDFkeyInt, objectReader);\n break;\n \n //read true or false\n }case PdfDictionary.VALUE_IS_BOOLEAN:{\n i = BooleanValue.set(pdfObject, i, raw, PDFkeyInt);\n break;\n \n //read known set of values\n }case PdfDictionary.VALUE_IS_STRING_CONSTANT:{\n i = StringValue.setStringConstantValue(pdfObject, i, raw,PDFkeyInt);\n break;\n \n //read known set of values\n }case PdfDictionary.VALUE_IS_STRING_KEY:{\n i = StringValue.setStringKeyValue(pdfObject, i, raw,PDFkeyInt);\n break;\n \n //read number (may be indirect ref)\n }case PdfDictionary.VALUE_IS_INT:{\n \n //roll on\n i++;\n \n //move cursor to start of text\n while(raw[i]==10 || raw[i]==13 || raw[i]==32 || raw[i]==47) {\n i++;\n }\n \n i = NumberValue.setNumberValue(pdfObject, i, raw, PDFkeyInt,objectReader);\n break;\n \n //read float number (may be indirect ref)\n }case PdfDictionary.VALUE_IS_FLOAT:{\n i = FloatValue.setFloatValue(pdfObject, i, raw, length,PDFkeyInt,objectReader);\n break;\n \n //read known Dictionary object which may be direct or indirect\n }case PdfDictionary.VALUE_IS_UNREAD_DICTIONARY:{\n i = setUnreadDictionaryValue(pdfObject, i, raw);\n break;\n \n }case PdfDictionary.VALUE_IS_VARIOUS:{\n if(raw.length-5>0 && raw[i+1]=='n' && raw[i+2]=='u' && raw[i+3]=='l' && raw[i+4]=='l'){ //ignore null value and skip (ie /N null)\n i += 5;\n }else{\n i = setVariousValue(pdfObject, i, raw, length, PDFkeyInt, map, ignoreRecursion,objectReader);\n }\n break;\n \n }case PdfDictionary.VALUE_IS_DICTIONARY:{\n i = setDictionaryValue(pdfObject, i, raw, ignoreRecursion);\n break;\n }\n }\n return i;\n }", "void put(MongoDBEntry<K, V> entry);", "public <T> T readKey() {\n return readObject();\n }", "private void method_980(ObjectInputStream var1) {\n var1.defaultReadObject();\n this.a = new HashMap();\n this.b = new HashMap();\n Map var2 = (Map)var1.readObject();\n this.putAll(var2);\n }", "public Object putTransient(Object key, Object value);", "@Override\n\tpublic V get(Object key) {\n\t\treturn map.get(key);\n\t}", "public MapReader getIo() {\n\t\treturn io;\n\t}", "@Override\r\n \tpublic void setMap(Map m) {\n \t\t\r\n \t}", "@Override\n\tpublic String addOrUpdate(Map<String, Object> entityMap)\n\t\t\tthrows DataAccessException {\n\t\treturn null;\n\t}", "public ObjectMap put(String key, Object value) throws JsonException {\r\n\r\n\t\tif (value == null) {\r\n\t\t\tobjectMap.remove(key);\r\n\t\t\treturn this;\r\n\t\t}\r\n\r\n\t\tif (value instanceof Number) {\r\n\t\t\tPrimitiveDataTypeConvertor.checkDouble(((Number) value).doubleValue());\r\n\t\t}\r\n\r\n\t\tobjectMap.put(check_Key(key), value);\r\n\t\treturn this;\r\n\t}", "private void readObject(final ObjectInputStream in) throws IOException, ClassNotFoundException {\n try {\n location = IOHelper.readData(new StreamInputSource(in));\n } catch (final IOException | ClassNotFoundException e) {\n throw e;\n } catch (final Exception e) {\n throw new IOException(e);\n }\n }", "public void setIo(MapReader io) {\n\t\tthis.io = io;\n\t}", "public Value put(Key key, Value thing) ;", "public Object map(String key, Object input);", "public ObjectMap put(String key, boolean value) throws JsonException {\r\n\t\tobjectMap.put(check_Key(key), value);\r\n\t\treturn this;\r\n\t}", "public V get(Object key) { return _map.get(key); }", "public T setObject(int key, T ob) throws PersistenceException, NullObjectException {\n if(ob == null) {\n throw new NullObjectException(\"Unable to save object. The object passed is null\");\n }\n return (super.setObjectInKey(key, ob));\n }", "public Object put(short key, Object obj) {\n\t\tObject result = get(key);\n\t\ttheList.add(new Entry(key, obj));\n\t\treturn result;\n\t}", "protected Object putElement(int key, Object value) {\n int index = key % capacity;\n if (index < 0) {\n index = -index;\n }\n if (map[index] == null) {\n //.... This is a new key since no bucket exists\n objectCounter++;\n map[index] = create(key, value);\n contents++;\n if (contents > maxLoad) {\n rehash();\n }\n return null;\n } else {\n //.... A bucket already exists for this index: check whether \n // we already have a mapping for this key\n MapElement me = map[index];\n while (true) {\n if (me.getKey() == key) {\n return me.atInsert(value);\n } else {\n if (me.getNext() == null) {\n // No next element: so we have no mapping for this key\n objectCounter++;\n MapElement result = create(key, value);\n me.setNext(result);\n contents++;\n if (contents > maxLoad) {\n rehash();\n }\n return null;\n } else {\n me = me.getNext();\n }\n }\n }\n }\n }", "public ContentObject put(ContentObject co) throws IOException, InterruptedException {\n _stats.increment(StatsEnum.Puts);\n try {\n write(co);\n } catch (ContentEncodingException e) {\n Log.warning(Log.FAC_NETMANAGER, formatMessage(\"Exception in lowest-level put for object {0}! {1}\"), co.name(), e);\n }\n return co;\n }", "T getObject() {\n\t\t\treturn data;\n\t\t}", "public void put(String key, T value);", "@Override\n\tpublic Map<String, Object> read(int id) {\n\t\treturn rolDao.read(id);\n\t}", "@SuppressWarnings(\"unchecked\")\r\n private void readObject(java.io.ObjectInputStream s)\r\n throws java.io.IOException, ClassNotFoundException {\r\n // Read in any hidden serialization magic\r\n s.defaultReadObject();\r\n\r\n // Read in HashMap capacity and load factor and create backing HashMap\r\n // int capacity = s.readInt();\r\n // float loadFactor = s.readFloat();\r\n this.map = new HashMap<Integer, E>();\r\n\r\n // Read in size\r\n int size = s.readInt();\r\n\r\n // Read in all elements in the proper order.\r\n for (int i = 0; i < size; i++) {\r\n E e = (E) s.readObject();\r\n this.map.put(e.hashCode(), e);\r\n }\r\n }", "public interface MapStore extends Closeable {\n\n /**\n * Creates a table with the given key.\n *\n * Note that this operation is idempotent\n * so a true response means that the table\n * exists after execution.\n *\n * @return true iff the table exists after execution\n */\n boolean createTable(\n String tableName,\n MapStoreTableKey tableKey\n );\n\n /**\n * Drops a table.\n *\n * @return true iff the drop was successful\n */\n boolean dropTable(String tableName);\n\n /**\n * Delete an item from the given table\n * with the give key.\n *\n * This should be idempotent if the item\n * does not exist.\n */\n void deleteItem(\n String tableName,\n MapStoreKey key\n );\n\n /**\n * Retrieves all items from the given table\n * with all keys.\n */\n List<Map<String, Object>> getAllItems(String tableName);\n\n /**\n * Retrieves an item from the given table\n * with the given key.\n *\n * Returns {@link Optional#empty()} if no\n * item exists with the given key.\n */\n Optional<Map<String, Object>> getItem(\n String tableName,\n MapStoreKey key\n );\n\n /**\n * Queries all items from the given table\n * which match the given {@link MapStoreKey}\n * range key operator.\n */\n List<Map<String, Object>> getItems(\n String tableName,\n MapStoreKey key,\n MapQueryOptions options\n );\n\n /**\n * Adds an item to the given table\n * under the given key.\n */\n Map<String, Object> putItem(\n String tableName,\n MapStoreKey key,\n Map<String, Object> payload\n );\n\n /**\n * Updates an item in the given table\n * under the given key.\n *\n * If no item exists at the given key,\n * this will fallback to {@link #putItem(String, MapStoreKey, Map)}\n * semantics.\n */\n Map<String, Object> updateItem(\n String tableName,\n MapStoreKey key,\n Map<String, Object> payload\n );\n}", "@Override\r\n\tpublic void saveMap() {\n\r\n\t}", "public Object getObject(int columnIndex, Map map) throws SQLException {\n\n try {\n if (isDebugEnabled()) {\n debugCode(\"getObject(\" + columnIndex + \", map);\");\n }\n throw Message.getUnsupportedException();\n }\n catch (Exception e) {\n throw logAndConvert(e);\n }\n }", "public Object transform(Object input) {\n return iMap.get(input);\n }", "T get(String key) throws IOException;", "public Object get(String key);", "public <T> T readValue() {\n return readObject();\n }", "public abstract org.omg.CORBA.Object read_Object();", "void readObject(InputSerializer in) throws java.io.IOException;", "@Override\n\tpublic void put(String name, Serializable key, Serializable value) throws CacheException {\n\t\t\n\t}", "protected Object readResolve() {\n calculateHashCode(keys);\n return this;\n }", "@Override\r\n protected ICacheElement<K, V> processGet(final K key)\r\n {\r\n if (!isAlive())\r\n {\r\n log.error(\"{0}: No longer alive so returning null for key = {1}\",\r\n logCacheName, key);\r\n return null;\r\n }\r\n\r\n log.debug(\"{0}: Trying to get from disk: {1}\", logCacheName, key);\r\n\r\n ICacheElement<K, V> object = null;\r\n try\r\n {\r\n storageLock.readLock().lock();\r\n try\r\n {\r\n object = readElement(key);\r\n }\r\n finally\r\n {\r\n storageLock.readLock().unlock();\r\n }\r\n\r\n if (object != null)\r\n {\r\n hitCount.incrementAndGet();\r\n }\r\n }\r\n catch (final IOException ioe)\r\n {\r\n log.error(\"{0}: Failure getting from disk, key = {1}\", logCacheName, key, ioe);\r\n reset();\r\n }\r\n return object;\r\n }", "@SuppressWarnings(\"unchecked\")\n public void put(final T object) {\n data.add(object);\n }", "public abstract void Put(WriteOptions options, Slice key, Slice value) throws IOException, BadFormatException, DecodeFailedException;", "public Object get(String path)\n {\n return DataObjectUtil.get(this, path);\n }", "protected abstract Object _get(String key);", "@Override\n\tpublic GenericMapInfo get(PK id) {\n\t\treturn null;\n\t}", "private void readObject(ObjectInputStream stream) throws IOException, ClassNotFoundException {\n/* 210 */ stream.defaultReadObject();\n/* 211 */ this.store = new TreeMap();\n/* 212 */ int keyCount = stream.readInt();\n/* 213 */ for (int i = 0; i < keyCount; i++) {\n/* 214 */ Comparable key = (Comparable)stream.readObject();\n/* 215 */ Stroke stroke = SerialUtilities.readStroke(stream);\n/* 216 */ this.store.put(key, stroke);\n/* */ } \n/* */ }", "@Override\n\tpublic String add(Map<String, Object> entityMap) throws DataAccessException {\n\t\treturn null;\n\t}", "private void writeObject(final ObjectOutputStream out) throws IOException {\n try {\n if (location == null) location = IOHelper.serializeData(object);\n IOHelper.writeData(location, new StreamOutputDestination(out));\n } catch (final IOException e) {\n throw e;\n } catch (final Exception e) {\n throw new IOException(e);\n }\n }", "public void put(final Serializable key, final Serializable value) {\n Mutex lock = checkLockExistsForKey(key);\n try {\n if (value != null) {\n final Element element = new Element(key, value);\n cache.put(element);\n } else {\n cache.remove(key);\n }\n } finally {\n //Release the readlock here. This will have been acquired in the get, where the element was null\n lock.release();\n }\n }", "public abstract Object put(String oid, Object obj) throws OIDAlreadyExistsException, ObjectNotSupportedException;" ]
[ "0.5860858", "0.5758766", "0.5758766", "0.5758766", "0.5735213", "0.5538603", "0.5525569", "0.54782397", "0.54042804", "0.5344171", "0.5302494", "0.5269298", "0.5268798", "0.5264201", "0.5226172", "0.5214399", "0.5212721", "0.5197118", "0.5185006", "0.5182254", "0.516455", "0.5159305", "0.515827", "0.5112102", "0.5111353", "0.51029056", "0.5099986", "0.50927496", "0.5091749", "0.5074049", "0.5063099", "0.5062726", "0.5053695", "0.50528634", "0.50515234", "0.5046745", "0.50391614", "0.50389314", "0.5037182", "0.5031571", "0.5027581", "0.5025395", "0.50181717", "0.5010189", "0.50079226", "0.5002157", "0.49959773", "0.49849004", "0.4972397", "0.49617365", "0.49548563", "0.4954015", "0.49516687", "0.49453712", "0.49407262", "0.49371764", "0.49245548", "0.49084243", "0.4904401", "0.4903248", "0.49031112", "0.4899644", "0.48988858", "0.48946983", "0.4888813", "0.4873533", "0.48626113", "0.4861229", "0.4852672", "0.48451865", "0.48423347", "0.48407763", "0.4840122", "0.4835647", "0.48337704", "0.48217517", "0.4821271", "0.4820871", "0.4820641", "0.4818661", "0.48184744", "0.481807", "0.4811774", "0.4811614", "0.48110303", "0.48091242", "0.48044214", "0.47987884", "0.47945306", "0.47891182", "0.47889715", "0.47881058", "0.47871467", "0.47791502", "0.47774744", "0.47754923", "0.47751397", "0.4774352", "0.47727934", "0.47719827", "0.4768798" ]
0.0
-1
Use this to Remove Object from this Map This Should be Synchronized While Interacting over This Map ie u cant Interacting and removing object at once
public final Map<L2Character, AggroInfoHolder> getAggroList() { return aggroList; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract void removeFromMap();", "public Object remove(Map<Prop, Object> map) {\n return map.remove(this);\n }", "public void removeMapObject(MapObject obj) {\n markers.remove(obj);\n if(internalNative != null) {\n internalNative.removeMapElement(obj.mapKey);\n } else {\n if(obj.lines != null) {\n if(internalLightweightCmp != null) {\n internalLightweightCmp.removeLayer(obj.lines);\n } else {\n // TODO: Browser component\n }\n } else {\n points.removePoint(obj.point);\n }\n }\n }", "@Override\r\n\tpublic Object removeObject(Object key) {\n\t\treturn null;\r\n\t}", "public void remove(Object key){\n map.remove(key);\n }", "@Override\n\tpublic V remove(Object key) {\n\t\tkeys.remove(key);\n\t\treturn map.remove(key);\n\t}", "public synchronized V remove(Object oKey)\n {\n // COH-6009: map mutations must be synchronized with event dispatch\n // to ensure in-order delivery\n Entry<K, V> entry = (Entry<K, V>) getEntryInternal(oKey);\n if (entry == null)\n {\n return null;\n }\n else\n {\n removeEntryInternal(entry);\n entry.onRemove();\n return entry.getValue();\n }\n }", "public Object remove();", "public void removeByObject()\r\n\t{\n\t}", "public void removeObject( SharedObjectInterface sharedObject ) {\n SharedEntry key = new SharedEntry( sharedObject.getClass().getName(), sharedObject.getName() );\n objectsMap.remove( key );\n }", "private void removeObjectFromMaps(Object obj)\r\n {\r\n String name = (String) objectNames.remove(obj);\r\n\r\n // if multiple objects have registered under the same prefix, ensure\r\n // that only this object is removed from that mapping\r\n try\r\n {\r\n // retrieve the object that the weak reference refers to, if any\r\n WeakReference ref = (WeakReference) nameObjects.get(name);\r\n if (System.identityHashCode(obj) == System.identityHashCode(ref.get()))\r\n nameObjects.remove(name);\r\n }\r\n catch(NullPointerException e0)\r\n {\r\n // ignore\r\n }\r\n }", "public boolean remove(Object o) {\r\n return this.map.remove(o.hashCode()) != null;\r\n }", "@Override\n public void remove() {\n }", "@Override\n\t\tpublic void remove() {\n\t\t\t\n\t\t}", "@Override\n\t\tpublic void remove() {\n\t\t\t\n\t\t}", "Object remove();", "@Override\n\t\t\t\tpublic void remove() {\n\t\t\t\t\t\n\t\t\t\t}", "@Override\n public void remove() {\n }", "@Override\r\n\t\tpublic void remove() {\r\n\t\t\t// YOU DO NOT NEED TO WRITE THIS\r\n\t\t}", "public void remove(GeometricalObject object);", "@Override\n\tpublic void remove(Object o) {\n\t\t\n\t}", "public boolean remove(Object o) {\n\t\treturn map.remove(o) == PRESENT;\n\t}", "@SuppressWarnings(\"unchecked\")\n protected void onRemove()\n {\n // issue remove notification\n ObservableHashMap map = ObservableHashMap.this;\n if (map.hasListeners())\n {\n map.dispatchEvent(new MapEvent(map, MapEvent.ENTRY_DELETED,\n getKey(), getValue(), null));\n }\n }", "@Override\r\n\tpublic boolean remove(Object o) {\n\t\treturn set.remove(o);\r\n\t}", "@Override\r\n\tpublic void remove() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void remove() {\n\t\t\r\n\t}", "void remove(GeometricalObject object);", "@Override\r\n public void remove(IMObject object) {\r\n cache.remove(object);\r\n }", "public void remove() {\n\n }", "@Override\n\tpublic void remove() { }", "public ObjectMap remove(String key, Object value) {\r\n\t\tif (hasKey(key) && hasValue(value))\r\n\t\t\tobjectMap.remove(key, value);\r\n\t\treturn this;\r\n\t}", "public void remove(Object key, Object value) {\n map.get(key).remove(value);\n }", "public void remove() {\n\t }", "public void remove() {\n\t }", "public void remove() {\n\t }", "public void removeMaps(GridMap map){\n mapsList.remove(map);\n //Observer pattern\n setChanged();\n notifyObservers(this);\n }", "@Override\n public Object remove(int k) {\n long startTime = System.currentTimeMillis();\n Object value = super.remove(k);\n long endTime = System.currentTimeMillis();\n if (value == null) {\n elements--;\n startTime = System.currentTimeMillis();\n for (int i = 1; i < super.size() && value == null; i++) {\n int hash = (k + i) % size();\n MapElement me = hashTable[hash];\n if (me == null) {\n value = null;\n } else if (me.getKey() != k) {\n value = null;\n } else {\n hashTable[hash] = null;\n value = me.getValue();\n }\n }\n endTime = System.currentTimeMillis();\n }\n System.out.println(\"------REMOVE------\");\n System.out.println(\"TIME: \" + (endTime - startTime));\n return value;\n }", "@Override\n\tpublic void remove() {\n\t\t\n\t}", "@Override\n\tpublic void remove() {\n\t\t\n\t}", "@Override\n\tpublic void remove() {\n\t\t\n\t}", "@Override\n\tpublic void remove() {\n\t\t\n\t}", "@Override\n\tpublic void remove() {\n\t\t\n\t}", "@Override\n\tpublic void remove() {\n\t\t\n\t}", "@Override\n\tpublic void remove() {\n\t\t\n\t}", "@Override\n\tpublic void remove() {\n\t\t\n\t}", "@Override\r\n public void clear() {\r\n map.clear();\r\n }", "private void removeObject() {\n\t\tif(this.curr_obj != null) {\n this.canvas.uRemove(this.curr_obj);\n\t\t\tthis.canvas.remove(this.transformPoints);\n this.transformPoints.clear();\n\n this.curr_obj = null;\n }\n\t}", "@Override\n\tpublic void removeInUse() {\n\t\theldObj.removeInUse();\n\t}", "public void remove () {}", "@Override\r\n void removeStarMap(StarMapComponent starMap) {\n\r\n }", "@Override\r\n\t\tpublic void remove() {\n\r\n\t\t}", "public final void remove () {\r\n }", "public Object remove(String key);", "public synchronized void unRegisterObject(Object object)\r\n {\r\n removeObjectFromMaps(object);\r\n }", "@Override\n\tpublic boolean delete(Eleve o) {\n\t\tmap.remove(o.getId(), o);\n\t\treturn true;\n\t}", "public void remove();", "public void remove();", "public void remove();", "public void remove();", "public void remove();", "public void remove() {\r\n super.remove();\r\n }", "public Object removeItem (String key);", "public Collection<V> remove(Object obj) {\n Collection collection = (Collection) this.Pu.remove(obj);\n if (collection == null) {\n return null;\n }\n Collection<V> ry = AbstractMapBasedMultimap.this.ry();\n ry.addAll(collection);\n AbstractMapBasedMultimap.this.Ps = AbstractMapBasedMultimap.this.Ps - collection.size();\n collection.clear();\n return ry;\n }", "public Object removeObject(int par1)\n {\n this.keySet.remove(Integer.valueOf(par1));\n IntHashMapEntry inthashmapentry = this.removeEntry(par1);\n return inthashmapentry == null ? null : inthashmapentry.valueEntry;\n }", "@Override\n\t\tpublic void remove() {\n\t\t\tif ( _expectedSize != TOrderedHashMap.this.size() ) { throw new ConcurrentModificationException(); }\n\n\t\t\t// Disable auto compaction during the remove. This is a workaround\n\t\t\t// for bug 1642768.\n\t\t\ttry {\n\t\t\t\tTOrderedHashMap.this.tempDisableAutoCompaction();\n\t\t\t\tTOrderedHashMap.this.removeAt(_indicesByInsertOrder[_index]);\n\t\t\t} finally {\n\t\t\t\tTOrderedHashMap.this.reenableAutoCompaction(false);\n\t\t\t}\n\n\t\t\t_expectedSize--;\n\t\t}", "@Override\n public T remove(Object key) {\n // Do I have an entry for it?\n Map.Entry<String, T> entry = entries.get((String) key);\n if (entry != null) {\n entries.remove(key);\n // Change the underlying map.\n return map.remove(prefix + key);\n }\n return null;\n }", "public void clear()\n\t{\n\t\tthrow new UnsupportedOperationException(\"Read Only Map\");\n\t}", "public void remove() {\n super.remove();\n }", "public void remove() {\n super.remove();\n }", "public void remove() {\n super.remove();\n }", "public void remove() {\n super.remove();\n }", "public void remove() {\n super.remove();\n }", "public void remove() {\n super.remove();\n }", "public void remove() {\n super.remove();\n }", "public void remove() {\r\n //\r\n }", "public final void clear() { _map.clear(); }", "@Override\n\t\t\tpublic AnalysisResult remove(Object key) {\n\t\t\t\treturn null;\n\t\t\t}", "public void remove() {\r\n\t\t\trequireModificationCountUnchanged();\r\n\r\n\t\t\tif (currentEntry == null) {\r\n\t\t\t\tthrow new IllegalStateException();\r\n\t\t\t}\r\n\r\n\t\t\tSimpleHashtable.this.remove(currentEntry.key);\r\n\t\t\titeratorModificationCount++;\r\n\t\t\tcurrentEntry = null;\r\n\t\t}", "@Override\r\n\tpublic void removeEntry(String key) {\n\t\t\r\n\t}", "@Override\n\tpublic V remove(Object key) {\n\t\treturn null;\n\t}", "@Override\n\tpublic V remove(Object key) {\n\t\treturn null;\n\t}", "protected void discard()\n {\n if (!isDiscarded())\n {\n OldOldCache map = OldOldCache.this;\n synchronized (map)\n {\n int cUnits = m_cUnits;\n if (cUnits == -1)\n {\n // entry is discarded; avoid repetitive events\n return;\n }\n\n if (cUnits > 0)\n {\n map.adjustUnits(-cUnits);\n }\n\n m_cUnits = -1;\n }\n\n // issue remove notification\n if (map.hasListeners())\n {\n map.dispatchEvent(map.instantiateMapEvent(\n MapEvent.ENTRY_DELETED, getKey(), getValue(), null));\n }\n }\n }", "public void remove() {\r\n return;\r\n }", "public Object remove(Object oKey)\n {\n // check if the cache needs flushing\n checkFlush();\n\n synchronized (this)\n {\n // determine if the key is in the cache\n Entry entry = (Entry) getEntryInternal(oKey);\n if (entry == null)\n {\n return null;\n }\n else\n {\n entry.discard();\n removeEntryInternal(entry);\n return entry.getValue();\n }\n }\n }", "@Override\n public synchronized Object remove(Object key) {\n String strkey = key.toString();\n if (this.ignoreCase) {\n strkey = (String) this.keyMap.remove(strkey.toLowerCase());\n if (strkey == null)\n return null;\n }\n return super.remove(strkey);\n }", "public void clear() {\r\n this.map.clear();\r\n }", "public void removeObject(T object) {\r\n\t\tif(cache.contains(object) == false) //if not found in cache\r\n\t\t{\r\n\t\t\tSystem.out.println(\"Object not found.\");\r\n\t\t}\r\n\t\t\r\n\t\telse\r\n\t\t{\r\n\t\t\tcache.remove(cache.indexOf(object));\r\n\t\t}\r\n\t\t\r\n\t}", "public void remove(int idTarget){ \r\n cjtMap.remove(idTarget); \r\n }", "@Override\n\t\tpublic boolean remove(Object o) {\n\t\t\treturn false;\n\t\t}", "MapComp<K, V> remove(K k);", "public void clear() {\n map.clear();\n }", "public void remove() {\n\t}", "public void remove() {\n\t}", "@Override\n\tpublic void removeFromCache(T obj) {\n\t\tcache.remove(obj);\n\t}", "@Override\r\n\tpublic void removeElement(K key) {\n\t\tque.remove(key);\r\n\t\thashMap.remove(key);\r\n\t}", "public void clear() {\n map.clear();\n }", "public synchronized Object remove( Object key ) {\n\t\tObject intvalue = mapKeyPos.remove(key);\n\t\tif ( intvalue != null ) {\n\t\t\tint pos = ((Integer)intvalue).intValue();\n\t\t\tObject temp = values[pos];\n\t\t\tkeys[pos] = null;\n\t\t\tvalues[pos] = null;\n\t\t\tstatus[pos] = LRU_OLD;\n\t\t\t//System.out.println(\"CountLimiteLRU: remove(\"+key+\") = \"+temp);\n\t\t\treturn temp;\n\t\t}\n\t\treturn null;\n\t}", "public ObjectMap remove(String key) {\r\n\t\tif (hasKey(key))\r\n\t\t\tobjectMap.remove(key);\r\n\t\treturn this;\r\n\t}", "protected abstract void remove(E entry);", "@Override\r\n\tpublic void perform() {\n\t\tview.removeMapMonster(toremove);\r\n\t}", "public void remove(int key) {\n map.remove(key);\n }" ]
[ "0.7469888", "0.7224101", "0.72113115", "0.7104335", "0.7086421", "0.6981843", "0.6928267", "0.6928131", "0.6878325", "0.6873314", "0.6788494", "0.6786999", "0.6759932", "0.6753934", "0.6753934", "0.6748727", "0.6737371", "0.67203766", "0.6717708", "0.67157364", "0.669512", "0.6694936", "0.66750145", "0.66602755", "0.66526365", "0.66526365", "0.6642576", "0.6609332", "0.6595506", "0.6580135", "0.65633845", "0.65572214", "0.65516996", "0.65516996", "0.65516996", "0.6521019", "0.650759", "0.6500754", "0.6500754", "0.6500754", "0.6500754", "0.6500754", "0.6500754", "0.6500754", "0.6500754", "0.6495217", "0.64826685", "0.6477156", "0.6476447", "0.64569116", "0.6454227", "0.64507943", "0.64400744", "0.6427856", "0.64211553", "0.64194345", "0.64194345", "0.64194345", "0.64194345", "0.64194345", "0.64187515", "0.64089566", "0.6404339", "0.63986635", "0.6395512", "0.6379308", "0.6367909", "0.6351534", "0.6351534", "0.6351534", "0.6351534", "0.6351534", "0.6351534", "0.6351534", "0.63485223", "0.6309783", "0.630823", "0.630642", "0.6302364", "0.62967956", "0.62967956", "0.6291972", "0.62913924", "0.6287373", "0.6284821", "0.62642395", "0.6259447", "0.6257148", "0.62566054", "0.6248053", "0.62475705", "0.6247306", "0.6247306", "0.62294614", "0.6227805", "0.622686", "0.6225266", "0.62210757", "0.6214178", "0.6211583", "0.62113744" ]
0.0
-1
Constructor of L2Attackable (use L2Character and L2NpcInstance constructor). Actions : Call the L2Character constructor to set the template of the L2Attackable (copy skills from template to object and link calculators to NPC_STD_CALCULATOR) Set the name of the L2Attackable Create a RandomAnimation Task that will be launched after the calculated delay if the server allow it
public L2Attackable(final int objectId, final L2NpcTemplate template) { super(objectId, template); getKnownList(); // init knownlist mustGiveExpSp = true; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public L2FortCommanderInstance(L2NpcTemplate template)\n\t{\n\t\tsuper(template);\n\t\tsetInstanceType(InstanceType.L2FortCommanderInstance);\n\t\t_canTalk = true;\n\t}", "public void attack(){\n activity = CreatureActivity.ATTACK;\n createWeapon();\n endAttack = new CountDown(20); //100\n endAnimationAttack = new CountDown(100);\n }", "public skills(){\n\t\tname = \"tempName\";\n\t\tmanaCost =0;\n\t\tskillDmg = 0;\n\t\tcritFactor = 0;\n\t\tcritChance = 0;\n\t\tnoOfTargets = 1;\n\t\thitChance = 0;\n\t\tmyAttribute = null;\n\t\t\n\t\t//instantiates the original values, prob will have no need\n\t\torigSkillDmg = 0;\n\t\torigCritFac = 0;\n\t\torigCritChan = 0;\n\t\torigHitChan =0;\n\t\t\n\t\t//stores the current buffs on the person\n\t\tcurrBuff = null;\n\t}", "public InitiateAttackNonCreatureAction() {\n super(new CreatureAttacksNonCreatureRule());\n }", "public L2GuardInstance(int objectId, L2NpcTemplate template)\n\t{\n\t\tsuper(objectId, template);\n\t\tsetIsMortal(true);\n\t\tThreadPoolManager.getInstance().scheduleAiAtFixedRate(new ReturnTask(), RETURN_INTERVAL, RETURN_INTERVAL + Rnd.get(60000));\n\t}", "public Program7()\n { \n _tc = new TravelingCreature( 200, 200 );\n }", "PlayableCharacter(int health, int attack, int intelligence, int defence, int speed, String type, String name, String description, Move[] moveset, String ability, StatItem heldItem, StatItem hatItem, StatItem shirtItem, StatItem pantsItem, StatItem shoesItem, BufferedImage[] sprites) {\n super(health, attack, intelligence, defence, speed, type, name, moveset, ability, heldItem, sprites);\n this.description = description;\n this.status = null;\n this.fainted = false;\n this.experience = 0;\n this.level = 1;\n this.hatItem = hatItem;\n this.shirtItem = shirtItem;\n this.pantsItem = pantsItem;\n this.shoesItem = shoesItem;\n }", "public LovelyKiss() {\n super(SkillFactory.LOVELY_KISS, \"Lovely Kiss\", SkillDescription.LOVELY_KISS,10,\n Pokemon.Type.NORMAL, 75);\n effects.add(new SleepEffect(SecondaryEffect.Target.ENEMY));\n }", "public Lunge() {\n super(SkillFactory.LUNGE, \"Lunge\", SkillDescription.lunge, 15, Pokemon.Type.BUG,\n SkillCategory.PHYSICAL, 100, 80, 1, 1.0);\n secondaryEffects.add(new AttackEffect(SecondaryEffect.Target.ENEMY, 1,\n SecondaryEffect.StatDirection.DECREASE));\n makesPhysicalContact = true;\n }", "@Override\n protected void init() {\n lastHorizontalDirection = direction = Math.random() < 0.5 ? Direction.LEFT : Direction.RIGHT;\n lastVerticalDirection = Direction.UP;\n setBody(new PolygonShape(BODY_WIDTH2, BODY_HEIGHT2), Body.Mode.CHARACTER);\n body().restitution = 0.0;\n size().set(WIDTH, HEIGHT);\n\n this.addAnimation(\"walk\")\n .addFrames(\"smick\", 4, 5, 0, 2)\n .setSpeed(10)\n .loop(true);\n this.addAnimation(\"eatRadish\")\n .addFrames(\"smick\", 4, 5, 8, 9)\n .setSpeed(10)\n .loop(true);\n this.addAnimation(\"eatHector\")\n .addFrames(\"smick\", 4, 5, 10, 10)\n .setSpeed(10)\n .loop(true);\n this.addAnimation(\"jump\")\n .addFrames(\"smick\", 4, 5, 11, 11)\n .setSpeed(10)\n .loop(false);\n this.addAnimation(\"climb\")\n .addFrames(\"smick\", 4, 5, 12, 13)\n .setSpeed(10)\n .loop(false);\n this.addAnimation(\"eatHectorOnRope\")\n .addFrames(\"smick\", 4, 5, 14, 14)\n .setSpeed(10)\n .loop(false);\n this.addAnimation(\"crushing\")\n .addFrames(\"smick\", 4, 5, 16, 16)\n .setSpeed(10)\n .loop(false);\n }", "public Athlete()\r\n{\r\n this.def = \"An athlete is said to be running when he/she is accelerating in a certain direction during which his legs and the rest of his body are moving\";\r\n}", "Bullet(int posX,int posY,int velX,int velY,int classOfObejct,int attack){\n this.posX = posX;\n this.posY = posY;\n this.velX = velX;\n this.velY = velY;\n this.classOfObejct = classOfObejct;\n this.attack = attack;\n\n }", "public Skill() {\n\t\tsuper();\n\t}", "public Warrior(Point3D position, int speed) {\r\n super(\"img/Ants/warrior.png\", position, speed);\r\n currentBehaviour = WarriorBehaviour.PATROL;\r\n }", "public void initCreature() {\n }", "public void actionCombat(Party p1) {\n System.out.println(\"______________________________________________________________________________\\n\");\n System.out.println(this.Name + \" is attacking ...\");\n int choice = (int)(Math.random() * p1.getTeam().size());\n Character target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n\n if (this.SPEED - target.getSPEED() < 5) {\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n }\n else {\n int n = 0;\n while ((target.actualHP != 0) && (n < 2)) {\n if (n == 1) {\n choice = (int)(Math.random() * p1.getTeam().size() + 1);\n target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n }\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n if (n == 0) System.out.println(this.Name + \" attacks again ...\");\n n++;\n }\n }\n }", "public LanguageSkill() {\n\t}", "public EnemyGunBullet1() {\n super(DAMAGE, SPEED);\n setEnemyBullet(true);\n setShootSound(\"enemyShot.wav\");\n try {\n image = ImageIO.read(new File(\"res/images/tanks/bullets/enemyBullet1.png\"));\n }\n catch (IOException e) { }\n }", "public Water_Hero(RefLinks refLink, float x, float y)\r\n {\r\n ///Apel al constructorului clasei de baza\r\n super(refLink, x,y, Character.DEFAULT_CREATURE_WIDTH, Character.DEFAULT_CREATURE_HEIGHT);\r\n\r\n ///Seteaza imaginea de start a eroului\r\n image = Assets.heroLeft;\r\n\r\n ///Stabilieste pozitia relativa si dimensiunea dreptunghiului de coliziune, starea implicita(normala)\r\n normalBounds.x = 16;\r\n normalBounds.y = 16;\r\n normalBounds.width = 16;\r\n normalBounds.height = 32;\r\n\r\n ///Stabilieste pozitia relativa si dimensiunea dreptunghiului de coliziune, starea de atac\r\n attackBounds.x = 10;\r\n attackBounds.y = 10;\r\n attackBounds.width = 38;\r\n attackBounds.height = 38;\r\n\r\n jumpingTimer = new Timer();\r\n\r\n lista_dinamic_element = new ArrayList<CollisionItem>();\r\n\r\n lista_static_element = new ArrayList<CollisionItem>();\r\n list_fire = new ArrayList<CollisionItem>();\r\n }", "public abstract void attack(Vector2 spawnPos, Vector2 target);", "public void attackTargetCharacter() {\n }", "public Tower(Tower template) {\n this.name = template.getName();\n this.cost = template.getCost();\n this.position = template.getPosition();\n this.attack = template.getAttack();\n this.currTime = System.currentTimeMillis();\n this.active = true;\n this.sprite = GameApp.getAssetManager().get(this.name + \".png\", Texture.class);\n }", "@Override\n\tprotected List<AbilityImpl> initAbility2() {\n\t\tint[] tilesChangedByLevel = {3, 3, 4, 4, 5};\n\t\t// TODO Auto-generated method stub\n\t\tList<AbilityImpl> abilityList = new ArrayList<>();\n\n\t\tfor (int i = 0; i < 5; i++) {\n\n\t\t\tAbilityComponent changeTiles = new ChangeTileColorAbilityComponent(tilesChangedByLevel[i], TileColor.BLUE);\n\t\t\tAbilityImpl ability = new AbilityImpl();\n\t\t\tability.addComponent(changeTiles);\n\t\t\tabilityList.add(ability);\n\t\t}\n\t\treturn abilityList;\n\t}", "public Skill(String skillName, double skillDamage, int skillManaCost, double skillHeal){\n name = skillName;\n damage = skillDamage;\n manaCost = skillManaCost;\n heal = skillHeal;\n//sets up skills to return as their name.\n }", "public Person(String victim, int aType, int lvl)\r\n {\r\n items = new ArrayList<Thing>();\r\n name = victim;\r\n type = aType;\r\n level = lvl;\r\n attack = 0;\r\n defense = 0;\r\n \r\n if (aType == HERO) makeHero();\r\n else if (aType>=1 && aType<=5) makeRobot(level);\r\n else if (aType>=6 && aType<=9) makeMonster(level);\r\n else makeBoss();\r\n }", "public Skill(Player player){\n this.player = player;\n this.name = player.name;\n this.intellect = player.intellect;\n this.defense = player.defense;\n this.attack = player.attack;\n this.weapon = player.weapon;\n this.armor = player.armor;\n this.defense = player.defense;\n\n }", "public Weapon(WeaponType type, int level) {\n \tthis.effects = new ArrayList<>();\n this.type = type;\n this.level = level;\n this.effects.add(new AttackEffect(getWeaponDamage(), getWeaponSpeed(), getWeaponRange(), Target.SELF));\n }", "DnDCharacter2() {\n strength = ability();\n dexterity = ability();\n constitution = ability();\n intelligence = ability();\n wisdom = ability();\n charisma = ability();\n hitpoints = 10 + modifier(constitution);\n }", "private void default_init(){\n id = 0;\n xPos = 0;\n yPos = 0;\n hp = 100;\n name=\"\";\n character_id = 1;\n weapons = new ArrayList<>();\n weaponEntryTracker = new LinkedList<>();\n isJumping = false;\n isFalling = false;\n initial_y= -1;\n stateOfMovement = 0;\n for(int i = 0; i < 3; i++){\n this.weapons.add(new Pair<>(NO_WEAPON_ID, (short) 0));\n }\n this.weapons.set(0,new Pair<>(PISTOL_ID,DEFAULT_PISTOL_AMMO));\n currentWeapon = this.weapons.get(0);\n bulletsFired = new ArrayList<>();\n shootingDirection = 1;\n energy = 0;\n sprint = false;\n score = 0;\n roundsWon = 0;\n ready = false;\n audioHandler = new AudioHandler();\n }", "protected GameObject() {\r\n\t\tid = \"na\";\r\n\t\tkey = \"_na\";\r\n\t\tname = \"N/A\";\r\n\t\tdrops = false;\r\n\t\tprotection = 0;\r\n\t\tplaysSound = false;\r\n\t\tattackAttempts = 0;\r\n\t\tattackFrequency = 4;\r\n\t\ttakesTwoCells = false;\r\n\t\tmovementFrequency = 10;\r\n\t\tstate = new Basic(this);\r\n\t\tresetAttackAttempts();\r\n\t\tresetMovementAttempts();\r\n\t}", "@Override\n\tpublic Attack makeAttack() {\n\t\tattack = new Attack();\n\t\tunit = getRandomListUnit();\n\t\t/*\n\t\tobliczenie wartosci ataku od losowo wybranej jednostki oraz\n\t\tustawienie tej wartosci w obiekcie Attack\n\t\tDOdatkowo zostaje przeslane informacje do loggera. Inofrmacje zawieraja, jaka jednostka, wartosc ataku, ilosc jednostek w armii\n\t\t*/\n\t\tint attackValue = (unit.getDefense()+unit.getHp())/2;\n\t\tattack.setAttack(attackValue);\n\t\tlogger.add(\"attacker\",attackValue, unitListSize());\n\n\t\treturn attack;\n\t}", "public void spawnCreature(){\n\t\tif(spawnType.equalsIgnoreCase(\"worm\")){\n\t\t\tRuntimeObjectFactory.getObjectFromPool(\"worm\"+spawnId);\n\t\t}else if(spawnType.equalsIgnoreCase(\"antorc\")){\n\t\t\tGdx.app.debug(TamerGame.LOG, this.getClass()\n\t\t\t\t\t.getSimpleName() + \" :: Ant entered\");\t\t\t\n\t\t\t//CHANGE SPAWNING IMPLEMENTATION\n\t\t\tAntOrc orc = new AntOrc();\n\t\t\torc.setPosition(getPosition());\n\t\t\torc.setWaypoint(waypoint);\n\t\t\tenvironment.addNewObject(orc);\n\t\t\tEventPool.addEvent(new tEvent(this,\"spawnCreature\",sleepTime,1));\n\t\t}\n\t\t\t\n\t}", "private void createEnemyHelicopter()\n\t {\n\t \t\tRandNum = 0 + (int)(Math.random()*700);\n\t\t \t\tint xCoordinate = 1400;\n\t int yCoordinate = RandNum; \n\t eh = new Enemy(xCoordinate,yCoordinate);\n\t \n\t // Add created enemy to the list of enemies.\n\t EnemyList.add(eh);\n\t \n\t }", "@Override\n\tpublic void create () {\n\t\tmBatch = new SpriteBatch();\n mFont = new BitmapFont();\n\t\tmCamera = new OrthographicCamera();\n\t\tmCamera.setToOrtho(false, 800, 480); // Regardless of resolution, project screen onto 800 x 480 orthographic matrix\n\n\t\tmGameBackgrounds = new Texture[6]; // Six frames describing six states of damage to the castle, from pristine to broken\n\t\tmGameBackgrounds[0] = new Texture(\"castle_v1.png\");\n\t\tmGameBackgrounds[1] = new Texture(\"castle_v1_dam1.png\");\n\t\tmGameBackgrounds[2] = new Texture(\"castle_v1_dam2.png\");\n\t\tmGameBackgrounds[3] = new Texture(\"castle_v1_dam3.png\");\n\t\tmGameBackgrounds[4] = new Texture(\"castle_v1_dam4.png\");\n\t\tmGameBackgrounds[5] = new Texture(\"castle_v1_dam5.png\");\n\n\t\t// Assign value to list so it may be given objects to store\n\t\tmAttackers = new Attacker[ATTACKER_ARRAY_SIZE];\n\t\tmButtons = new DefenderButtons[7];\n\t\tmButtons[0] = new DefenderButtons(DefenderButtons.TYPE_NEW_GAME);\n\t\tmButtons[1] = new DefenderButtons(DefenderButtons.TYPE_RESUME_SAVED_GAME);\n\t\tmButtons[2] = new DefenderButtons(DefenderButtons.TYPE_PAUSE_GAME);\n\t\tmButtons[3] = new DefenderButtons(DefenderButtons.TYPE_RESUME_PAUSED_GAME);\n\t\tmButtons[4] = new DefenderButtons(DefenderButtons.TYPE_REPAIR_CASTLE);\n\t\tmButtons[5] = new DefenderButtons(DefenderButtons.TYPE_CONTINUE_NEXT_ROUND);\n\t\tmButtons[6] = new DefenderButtons(DefenderButtons.TYPE_SAVE_GAME);\n\n\t\tmButtons[0].setTexture(new Texture(\"button1.png\"));\n\t\tmButtons[1].setTexture(new Texture(\"button1.png\"));\n\t\tmButtons[2].setTexture(new Texture(\"button2.png\"));\n\t\tmButtons[3].setTexture(new Texture(\"button2.png\"));\n\t\tmButtons[4].setTexture(new Texture(\"button3.png\"));\n\t\tmButtons[5].setTexture(new Texture(\"button3.png\"));\n\t\tmButtons[6].setTexture(new Texture(\"button3.png\"));\n\n\t\t// Create the object that tracks the touch coordinates\n\t\tmLastTouch = new Vector3();\n\n // Assign value to miscellaneous game variables\n mRoundTimeElapsed = 0;\n mRoundMaxTime = 25f; // Counted in SECONDS\n\t\tmCastleMaxHealth = 1000f;\n mCastleHealth = mCastleMaxHealth; // Will last 1,000 frames if attacked by one single standard attacker constantly\n\t\tmCastleDamageStage = 0;\n mRoundScore = 0f;\n mTotalScore = 0f;\n mRoundNumber = 1;\n\t\tmGameState = STATE_PRE_GAME;\n\t\tmAttackerDelay = 0;\n mRoundMaxAttackers = 5;\n\t\tmRepairCost = 1000f;\n\t\tmLivingAttackerCount = 0;\n\t\tmKnightSpawnChance = 0.35f; // 35% chance to spawn a knight instead of normal under regular circumstances\n mPaused = false;\n\t\tmRoundSaved = false;\n mHealthText = \"Castle Strength: \" + mCastleHealth;\n mRoundScoreText = \"This Round Score: \" + mRoundScore;\n\t\tmTotalScoreText = \"Total Game Score: \" + mTotalScore;\n\t\tmGameTitle = \"Castle Defender\";\n\t\tmGameSavedText = \"Game Saved!\";\n\t\tmRoundText = \"Round :\" + mRoundNumber;\n\t\tmRandom = new Random();\n\t\t//TEMPORARY! Will change the logic later\n mSpawnTime = 100;\n\t\tmMonsterHouseSpawn = 10;\n\n\t\t// Pull out the normal attacker's frames through temporary objects\n\t\tTexture walkTexture = new Texture(\"attackerSheet.png\");\n\t\tTextureRegion[][] walkTempArray = TextureRegion.split(walkTexture, 64, 64);\n\t\tTextureRegion[] walkFrames = new TextureRegion[16];\n\n\t\tint index = 0; // Cut the animation's frames up using this temporary jagged array (8 by 2 matches the image file rows / cols)\n\t\tfor (int i = 0; i < 2; i++) {\n\t\t\tfor (int j = 0; j < 8; j++) {\n\t\t\t\twalkFrames[index++] = walkTempArray[i][j];\n\t\t\t}\n\t\t}\n\n\t\tmStandardAttackerWalk = new Animation(0.055f, walkFrames);\n\n\t\t// Do the same process for the knight animations\n\t\tTexture knightWalk = new Texture(\"knight_sheet_walk.png\");\n\t\tTexture knightAttack = new Texture(\"knight_sheet_attack.png\");\n\n\t\tTextureRegion[][] knightWalkTemp = TextureRegion.split(knightWalk, 64, 128);\n\t\tTextureRegion[][] knightAtkTemp = TextureRegion.split(knightAttack, 64, 128);\n\n\t\tTextureRegion[] knightWalkFrames = new TextureRegion[8];\n\t\tTextureRegion[] knightAtkFrames = new TextureRegion[4];\n\n\t\tindex = 0;\n\t\tfor(int i = 0; i < 2; i++) {\n\t\t\tfor(int j = 0; j < 4; j++) {\n\t\t\t\tknightWalkFrames[index++] = knightWalkTemp[i][j];\n\t\t\t}\n\t\t}\n\n\t\tindex = 0;\n\t\tfor(int i = 0; i < 4; i++) {\n\t\t\tknightAtkFrames[index++] = knightAtkTemp[0][i];\n\t\t}\n\n\t\tmKnightAttackerAttack = new Animation(0.25f, knightAtkFrames);\n\t\tmKnightAttackerWalk = new Animation(0.125f, knightWalkFrames);\n\n\t\t// Populate the mAttackers array with 50 total attackers, 25 of each\n\t\tfor(int i = 0; i < ATTACKER_ARRAY_SIZE; i++){\n\t\t\t// Grab a walk speed between constant minimum and maximum\n\t\t\tfloat walkSpeed = mRandom.nextFloat() * MAX_SPEED_VARIANCE;\n\t\t\twalkSpeed += MIN_SPEED; // Ensures the speed is AT LEAST 60 \"units\"\n\t\t\t// Spawn at a random y coordinate starting at MIN_SPAWN_Y, varying by MAX_SPAWN_Y_VARIANCE\n\t\t\tfloat spawnY = mRandom.nextFloat() * MAX_SPAWN_Y_VARIANCE;\n\t\t\tspawnY += MIN_SPAWN_Y;\n\n\t\t\tif(i < ATTACKER_HALF_SIZE) {\n\t\t\t\t// The first half of the array are normal attackers\n\t\t\t\tmAttackers[i] = new Attacker(1f, walkSpeed, -100f, spawnY, 64f, 64f, \"normal\");\n\t\t\t\tmAttackers[i].addAnimation(mStandardAttackerWalk, \"walk\");\n\t\t\t} else {\n\t\t\t\t// The second half of the array are \"knight\" attackers\n\t\t\t\tmAttackers[i] = new Attacker(2f, walkSpeed * 0.75f, -100f, spawnY, 64f, 128f, \"knight\");\n\t\t\t\tmAttackers[i].addAnimation(mKnightAttackerWalk, \"walk\");\n\t\t\t\tmAttackers[i].addAnimation(mKnightAttackerAttack, \"attack\");\n\t\t\t}\n\t\t}\n\t}", "public PassiveAbility(boolean onSelf, Effects effects) {\r\n\t\t// will be false if from buff;\r\n\t\tsuper(new FixedTargeting((onSelf) ? \"SOURCE\" : \"TARGET\"),\r\n\t\t\t\teffects);\r\n\t}", "public static void init() {\n // BEGIN AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=CONSTRUCTORS\n\n frisbeeRollerFrisbeeRoller = new Talon(FRISBEE_ROLLER_CHANNEL);\n\n conveyorMotor = new Talon(CONV_MOTOR_CHANNEL);\n\n spatulaMotor = new Relay(SPATULA_MOTOR_CHANNEL);\n\n loadTalon = new Talon(LOADER_TALON);\n\n elevateTalon = new Talon(ELEVATE_TALON);\n\n try {\n driveTrainrearRightTalon = new CANJaguar(REAR_RIGHT_JAG_CHANNEL);\n\n driveTrainfrontRightTalon = new CANJaguar(FRONT_RIGHT_JAG_CHANNEL);\n\n driveTrainfrontLeftTalon = new CANJaguar(FRONT_LEFT_JAG_CHANNEL);\n\n driveTrainrearLeftTalon = new CANJaguar(REAR_LEFT_JAG_CHANNEL);\n\n shootershooterJag = new CANJaguar(SHOOTER_JAG_CHANNEL);\n } catch (CANTimeoutException ex) {\n ex.printStackTrace();\n }\n // END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=CONSTRUCTORS\n }", "public Ability(String effectDescription, Card sourceCard) {\n this(\"\", effectDescription, sourceCard);\n }", "public Torpedo(Board mygame, StarShip owner, int attack, StarShip target) {\n super(mygame, owner, attack);\n this.target = target;\n this.setSprite(\"torpedo\");\n }", "public GameV2() {\n\t\t// ** List for choose character */\n\t\tthis.characters = new ArrayList<Gladiator>();\n\n\t\tSystem.out.println(\n\t\t\t\t\"===================================================================================================\");\n\t\tSystem.out.println(\"# -[Character List]-\");\n\t\tSystem.out.println(\"#\");\n\t\tPaladin pala = new Paladin(\"Paladinosaur\", 50, 10);\n\t\tSystem.out.println(\"#\");\n\t\tMage mage = new Mage(\"Magestro\", 50, 10);\n\t\tSystem.out.println(\"#\");\n\t\tWarrior wari = new Warrior(\"Warrithor\", 50, 10);\n\t\tSystem.out.println(\"#\");\n\t\tPaladin pala2 = new Paladin(\"Palazite\", 50, 10);\n\t\tSystem.out.println(\"#\");\n\t\tMage mage2 = new Mage(\"Magenhoe\", 50, 10);\n\t\tSystem.out.println(\"#\");\n\t\tWarrior wari2 = new Warrior(\"Warrirraw\", 50, 10);\n\t\tSystem.out.println(\"#\");\n\t\tSystem.out.println(\"# SKILL[ q ]: Use like basic. \");\n\t\tSystem.out.println(\"# SKILL[ w ]: Use for more Atk dmg. \");\n\t\tSystem.out.println(\"# SKILL[ e ]: Use for plus your Def. \");\n\t\tSystem.out.println(\"# SKILL[ r ]: Use like Ultimate. \");\n\t\tSystem.out.println(\"#\");\n\t\tSystem.out.println(\n\t\t\t\t\"===================================================================================================\");\n\t\t// ** Add Characters to List */\n\t\tthis.characters.add(pala);\n\t\tthis.characters.add(pala2);\n\t\tthis.characters.add(wari);\n\t\tthis.characters.add(wari2);\n\t\tthis.characters.add(mage);\n\t\tthis.characters.add(mage2);\n\t\tSystem.out.println();\n\n\t}", "public void initMission() {\n\t\tinitNumOfMoves();\t//reset counter\n\t\t//Begin by creating a random board.\n\t\t/* 1st parameter: is the cell at (0,0) always empty?\n\t\t * 2nd parameter: will this board be accessed by the AI?\n\t\t * See the constructor comments in Board.java for more details. */\n\n\t\tboard = new Board(this.options.toUpperCase().contains(\"00\") ? true : false, false);\n\n\t\t//TODO OPTIONAL: instead of spawning a random board, we can customize\n\t\t//our own board! Just un-comment any of the below boards or paste your own!\n\n\t\t//Wastes to the right AND to the south! Watch how the AI would react.\n\t\t//try one-player AI version (aggressive or not, doesn't matter)\n//\t\tboard = new Board(new String[][]\n//\t\t\t\t{{\"\", \"P\", \"W\", \"\", \"\", \"\"},\n//\t\t\t\t {\"W\", \"\", \"\", \"\", \"G\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"P\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"\", \"P\", \"\", \"\", \"\"},\n//\t\t\t\t});\n\t\t//What's the most efficient way for the AI to find the victim?\n\t\t//Note there are no wastes or fire pits in this scenario.\n//\t\t\tboard = new Board(new String[][]\n//\t\t\t\t{{\" \", \" \", \" \", \" \", \" \", \" \" },\n//\t\t\t\t{\" \", \" \", \" \", \" \", \" \", \" \" },\n//\t\t\t\t{\" \", \" \", \" \", \" \", \" \", \" \" },\n//\t\t\t\t{\" \", \" \", \"G\", \" \", \" \", \" \" },\n//\t\t\t\t{\" \", \" \", \" \", \" \", \" \", \" \" },\n//\t\t\t\t{\" \", \" \", \" \", \" \", \" \", \" \" }\n//\t\t\t\t});\n\n\t\t//Impossible one. Useful for explaining probability during presentation.\n//\t\t\t\t\t\tboard = new Board(new String[][]\n//\t\t\t\t\t\t\t\t{{\"\", \"\", \"P\", \"\", \"\", \"\"},\n//\t\t\t\t\t\t\t\t{\"\", \"P\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t\t\t\t\t{\"P\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t\t\t\t\t{\"W\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t\t\t\t\t{\"\", \"\", \"\", \"W\", \"\", \"\"},\n//\t\t\t\t\t\t\t\t{\"\", \"G\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t\t\t\t\t});\n\n\t\t/* Very tough board, but the AI is up to the task. */\n//\t\tboard = new Board(new String[][]\n//\t\t\t\t{{\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"P\", \"P\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"W\", \"\", \"P\", \"\", \"\", \"\"},\n//\t\t\t\t {\"G\", \"\", \"\", \"W\", \"\", \"\"},\n//\t\t\t\t});\n\n\t\t//tough tough tough. The victim is surrounded by a wall of fire!\n\t\t//try it with 2 AI's, starting in random cell. One of them might die!\n//\t\tboard = new Board(new String[][]\n//\t\t\t\t{{\"\", \"P\", \"\", \"G\", \"\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"P\", \"W\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"W\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"P\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t});\n\n\t\t//with aggressiveModeOn set to true, the AI will disinfect both wastes.\n\t\t//if set to false, the AI will disinfect only one.\n\t\t//Either way, AI gets the victim.\n\t\t//\t\t\t\tboard = new Board(new String[][]\n\t\t//\t\t\t\t\t\t{{\"\", \"\", \"\", \"\", \"\", \"\"},\n\t\t//\t\t\t\t\t\t{\"\", \"\", \"\", \"P\", \"\", \"\"},\n\t\t//\t\t\t\t\t\t{\"\", \"W\", \"\", \"\", \"\", \"\"},\n\t\t//\t\t\t\t\t\t{\"\", \"W\", \"\", \"G\", \"\", \"P\"},\n\t\t//\t\t\t\t\t\t{\"\", \"\", \"\", \"\", \"\", \"\"},\n\t\t//\t\t\t\t\t\t{\"P\", \"\", \"\", \"\", \"\", \"\"},\n\t\t//\t\t\t\t\t\t});\n\n\n\t\t//RARE situation (one-player mode) where setting aggressiveModeOn to true will result in death.\n\t\t//Non-aggressive mode will get the victim. Start at cell (0,0).\n//\t\tboard = new Board(new String[][]\n//\t\t\t\t{{\"\", \"\", \"\", \"P\", \"G\", \"P\"},\n//\t\t\t\t{\"\", \"\", \"P\", \"W\", \"W\", \"\"},\n//\t\t\t\t{\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t{\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t{\"\", \"\", \"\", \"P\", \"P\", \"\"},\n//\t\t\t\t{\"P\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t});\n\n\n\t\t//Very rare instance. if both players are AI and start at cell (0,0),\n\t\t//they will BOTH die. However, note that it's not the AI's fault.\n\t\t//The AI still managed to MINIMIZE risk. They just got unlucky.\n//\t\tboard = new Board(new String[][]\n//\t\t\t\t{{\"\", \"\", \"\", \"\", \"P\", \"\"},\n//\t\t\t\t{\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t{\"\", \"W\", \"P\", \"\", \"\", \"\"},\n//\t\t\t\t{\"W\", \"\", \"\", \"\", \"G\", \"\"},\n//\t\t\t\t{\"P\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t{\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t});\n\n\t\t/* Use custom method in Board class to print the board to the console and save it to a text file.\n\t\t * See the method comments in Board.java class for more details. */\n\t\tboard.printBoard();\n\n\t\t/* Initialize the cell in which the players will start the mission. */\n\t\tCell startRoom;\n\t\tCellAsPerceivedByAI startRoomAI;\n\t\tCell[] startRooms = this.setStartRoomAndBoardAI(this.options.toUpperCase().contains(\"00\"));\n\t\tstartRoom = startRooms[0];\n\t\tstartRoomAI = (CellAsPerceivedByAI)startRooms[1];\n\n\t\tthis.createPlayers(startRoom, startRoomAI, this.p1Name, this.p2Name,\n\t\t\t\tthis.options.toUpperCase().contains(\"A1\"), this.options.toUpperCase().contains(\"A2\"), this.options.toUpperCase().contains(\"S\"),\n\t\t\t\tthis.options.toUpperCase().contains(\"H\") ? \"H\" : this.options.toUpperCase().contains(\"R\") ? \"R\" : \"B\");\t//create players\n\n\t\tthis.hideAllPics();\n\t\tgreyOutCell(startRoomAI.getX(), startRoomAI.getY());\n\t\trepaint();\n\t}", "public AIScript(Creature owner){\n _aiOwner = owner;\n _states = new HashMap<>();\n _variables = new HashMap<>();\n _aiVariables = _aiOwner.getActionStorage().getAiParameters();\n _currentStateHandler = (int) HashUtil.generateHashA(\"InitialState\");\n _isRunning = false;\n AIScriptLoader.getInstance().loadScript(this);\n _isRunning = true;\n }", "public Flame_Tank(int defx, int defy) {\n\t\tsuper(defx,defy);\n\t\twidth = 58;\n\t\theight = 31;\n\t\thitBox = new Rectangle(defx, defy, width, height); // fix this\n\t\txMaxSpeed = 0.3f;\n\t\tfriction = 0.01f;\n\t\tjumpStrength = 0.5f;\n\t\telasticity = 0.2f;\n\t\thp = 1000;\n\t\t\n\t\ttry {\n\t\t\tblank = new Image (\"res/blank.png\");\n\t\t\tft1 = new Image (\"res/Flare_Tank1.png\");\n\t\t\tft2 = new Image (\"res/Flare_Tank2.png\");\n\t\t\tftb1 = new Image (\"res/Flare_Tank_b1.png\");\n\t\t\tftb2 = new Image (\"res/Flare_Tank_b2.png\");\n\t\t\tftb3 = new Image (\"res/Flare_Tank_b3.png\");\n\t\t\tftb4 = new Image (\"res/Flare_Tank_b4.png\");\n\t\t} catch (SlickException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\tftank[0] = ft1;\n\t\tftank[1] = ft2;\n\t\tftank[2] = ft2;\n\t\tftank[3] = ftb1;\n\t\tftank[4] = ftb2;\n\t\tftank[5] = ftb3;\n\t\tftank[6] = ftb4;\n\t\tftank[7] = blank;\n\t\tFlame_tank = new Animation(ftank,200,true);\n\t\t\n\t\tweapons.add(new Weapon(Weapon.getWeapons().get(7)));\n\t\tfor(Weapon w : weapons) {\n\t\t\tw.setEnemy(true);\n\t\t}\n\t\tcurrentWeapon = weapons.get(1);\n\t}", "public AbilityEffect() {\n\t\tsuper();\n\t}", "public Weapon()\n {\n name = \"None\";\n speed = 2;\n damage = 1;\n range = 1;\n }", "public TestEnemy(Vector2 spawnPoint) {\n super(spawnPoint);\n this.health = MAX_HEALTH;\n this.speed = MAX_SPEED;\n this.damage = DAMAGE;\n this.moneyOnKill = MONEY_ON_KILL;\n this.bounds = new Circle(spawnPoint, RADIUS);\n this.ai = new RunnerAi(this);\n }", "public Creature() {\r\n\t\tname = \"\";\r\n\t\tdescription = \"\";\r\n\t\thp = 0;\r\n\t\tdmg = 0;\r\n//\t\troom = null;\r\n\t}", "@Override\n void planted() {\n super.planted();\n TimerTask Task = new TimerTask() {\n @Override\n public void run() {\n\n for (Drawable drawables : gameState.getDrawables()) {\n if (drawables instanceof Zombie) {\n int distance = (int) Math.sqrt(Math.pow((drawables.x - x), 2) + Math.pow((drawables.y - y), 2));\n if (distance <= explosionradious) {\n ((Zombie) drawables).hurt(Integer.MAX_VALUE);\n }\n }\n }\n\n life = 0;\n }\n\n };\n\n Timer timer = new Timer();\n timer.schedule(Task, 2000);\n }", "public AutonomousCommand(LiftSubsystem m_lift, ArmSubsystem m_arm, Shooter m_shooter, DriveSubsystem m_drive,\n HopperSubsystem m_hopper, Intake m_intake) {\n // Add your commands in the super() call, e.g.\n // super(new FooCommand(), new BarCommand());\n // alongwith- birlikte çalıştırmak için // withtimeout-- girdigin sure kadar\n // yapar\n // (new RunShooter(m_shooter, 1).withTimeout(0.75),new RunLift(m_lift,\n // 0.5).raceWith(new RunHopper(m_hopper, 0.8)),\n // new AutonomousDrive(m_drive, 0.8, 300).withTimeout(3));\n\n super(new RunShooter(m_shooter, 0.8).withTimeout(0.75),\n new RunShooter(m_shooter, 0.8).raceWith(new RunHopper(m_hopper, 0.8)).withTimeout(2.5),\n new AutonomousDrive(m_drive, -0.8, -300).raceWith(new RunIntake(m_intake, 0.8)\n .raceWith(new RunHopper(m_hopper, 0.8).raceWith(new RunShooter(m_shooter, 0.3),\n new AutonomousDrive(m_drive, 0.8, 300), new RunShooter(m_shooter, 0.8).withTimeout(0.75),\n new RunShooter(m_shooter, 0.8).raceWith(new RunHopper(m_hopper, 0.8).withTimeout(2.5))))));\n\n }", "@Override\n public L2Attackable getActiveChar() { return (L2Attackable)super.getActiveChar(); }", "public Cargo(){\n super(\"Cargo\");\n intake = new WPI_TalonSRX(RobotMap.cargoIntake);\n shoot = new WPI_TalonSRX(RobotMap.cargoShoot);\n }", "UsabilityGoal createUsabilityGoal();", "public Tower(int price, double damage, double range, double x, double y,\n\t\t\tdouble angle, int cooldown, Image[] imgs){\n\t\tthis.price = price;\n\t\tthis.damage = damage;\n\t\tthis.range = range;\n\t\tthis.imgs = imgs;\n\t\tthis.image = 0;\n\t\tthis.img = imgs[image];\n\t\tthis.temp = new ArrayList<Movable>();\n\t\tthis.initCooldown = cooldown;\n\t\tthis.cooldown = 0;\n\t\tthis.x = x;\n\t\tthis.y = y;\n\t\tthis.angle = angle;\n\t\tthis.level = 0;\n\t}", "public static void init() {\n // BEGIN AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=CONSTRUCTORS\n drivetrainSpeedController1 = new CANTalon(1);\n LiveWindow.addActuator(\"Drivetrain\", \"Speed Controller 1\", (CANTalon) drivetrainSpeedController1);\n \n drivetrainSpeedController2 = new CANTalon(2);\n LiveWindow.addActuator(\"Drivetrain\", \"Speed Controller 2\", (CANTalon) drivetrainSpeedController2);\n drivetrainSpeedController3 = new CANTalon(3);\n LiveWindow.addActuator(\"Drivetrain\", \"Speed Controller 2\", (CANTalon) drivetrainSpeedController3);\n drivetrainSpeedController4 = new CANTalon(4);\n LiveWindow.addActuator(\"Drivetrain\", \"Speed Controller 2\", (CANTalon) drivetrainSpeedController4);\n drivetrainSpeedController5 = new CANTalon(5);\n LiveWindow.addActuator(\"Drivetrain\", \"Speed Controller 2\", (CANTalon) drivetrainSpeedController5);\n drivetrainSpeedController6 = new CANTalon(6);\n LiveWindow.addActuator(\"Drivetrain\", \"Speed Controller 2\", (CANTalon) drivetrainSpeedController6);\n \n drivetrainRobotDrive21 = new RobotDrive(drivetrainSpeedController1, drivetrainSpeedController2, drivetrainSpeedController3, drivetrainSpeedController4, drivetrainSpeedController5, drivetrainSpeedController6);\n \n drivetrainRobotDrive21.setSafetyEnabled(true);\n drivetrainRobotDrive21.setExpiration(0.1);\n drivetrainRobotDrive21.setSensitivity(0.5);\n drivetrainRobotDrive21.setMaxOutput(1.0);\n\n\n // END AUTOGENERATED CODE, SOURCE=ROBOTBUILDER ID=CONSTRUCTORS\n }", "@Override\n public void init() {\n GetSprite(\"/images/bullet.png\");\n MusicUtils.StopASounds(\"/music/Laser_Shoot.wav\");\n Level().play(\"/music/Laser_Shoot.wav\");\n }", "protected void attack() {\n int[] dir = orientationToArray(orientation);\n int newX = positionX + dir[0];\n int newY = positionY + dir[1];\n Skill currentSkill = grid.getPlayer().getBattleSkill();\n if (\n currentSkill != null\n && grid.valid(newX, newY)\n && grid.getPlayer().hasEnoughMp(currentSkill.getCost())\n && System.currentTimeMillis() - currentSkill.getLastUsed() > currentSkill.getCooldown()\n ) {\n Token token = new SkillToken(\n currentSkill.getImage(),\n newX,\n newY,\n grid,\n dir[0],\n dir[1],\n currentSkill\n );\n token.orientation = orientation;\n grid.addTokenAt(token, newX, newY);\n currentSkill.use(System.currentTimeMillis());\n new Thread(token).start();\n }\n grid.repaint();\n }", "public Othello(String strategieP1, int niveauP1, String strategieP2, int niveauP2) {\n\t\tpropertySupport = new PropertyChangeSupport(this);\n\t\tmyBoard = new Board(8);\n\t\tpropertySupport = new PropertyChangeSupport(this);\n\t\tinitialisationBoard();\n\t\tfoeHasPlay = true;\n\t\taiPlay = false;\n\t\tplayerBlack = spawnAI(Color.BLACK, strategieP1, niveauP1);\n\t\tplayerWhite = spawnAI(Color.WHITE, strategieP2, niveauP2);\n\t\tcurrentPlayer = playerBlack;\n\t}", "Player attackingPlayer(int age, int overall, int potential) {\r\n Player newPlayer = new Player(this.nameGenerator.generateName(), age, overall, potential, 'C' , 'F');\r\n\r\n\r\n\r\n\r\n }", "public Weapon(){\n \n name = \"Claw\"; // will be treated as a sword\n type = 'R';\n advType = 'G';\n disType = 'B';\n mt = 4;\n hit = 85;\n crit = 0;\n wt = 1;\n isMagic = true;\n \n }", "@Override\n\tpublic boolean doDie(final L2Character killer)\n\t{\n\t\t// Kill the L2NpcInstance (the corpse disappeared after 7 seconds)\n\t\tif (!super.doDie(killer))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\t// Enhance soul crystals of the attacker if this L2Attackable had its soul absorbed\n\t\ttry\n\t\t{\n\t\t\tif (killer instanceof L2PcInstance)\n\t\t\t{\n\t\t\t\tlevelSoulCrystals(killer);\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t\t\n\t\t// Notify the Quest Engine of the L2Attackable death if necessary\n\t\ttry\n\t\t{\n\t\t\tif (killer instanceof L2PcInstance || killer instanceof L2Summon)\n\t\t\t{\n\t\t\t\tfinal L2PcInstance player = killer instanceof L2PcInstance ? (L2PcInstance) killer : ((L2Summon) killer).getOwner();\n\t\t\t\t\n\t\t\t\tEngineModsManager.onKill(killer, this, killer instanceof L2Summon);\n\t\t\t\t\n\t\t\t\t// only 1 randomly choosen quest of all quests registered to this character can be applied\n\t\t\t\tfor (final Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_KILL))\n\t\t\t\t{\n\t\t\t\t\tquest.notifyKill(this, player, killer instanceof L2Summon);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t\t\n\t\tsetChampion(false);\n\t\tif (Config.L2JMOD_CHAMPION_ENABLE && Config.L2JMOD_CHAMPION_FREQUENCY > 0)\n\t\t{\n\t\t\t// Set champion on next spawn\n\t\t\tif (this.getClass().getSimpleName().equalsIgnoreCase(\"L2MonsterInstance\") && getLevel() >= Config.L2JMOD_CHAMP_MIN_LVL && getLevel() <= Config.L2JMOD_CHAMP_MAX_LVL)\n\t\t\t{\n\t\t\t\tint random = ThreadLocalRandom.current().nextInt(100);\n\t\t\t\tif (random < Config.L2JMOD_CHAMPION_FREQUENCY)\n\t\t\t\t{\n\t\t\t\t\tsetChampion(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn true;\n\t}", "Hero()\n\t{\n\t\t\n\t\tsuper(152,500,97,124);\n\t\tlife = 3;\n\t\tdoubleFire = 0;\n\t\t\n\t}", "public SysSkillConferpo()\n {\n }", "public AI(){\n super();\n }", "public InitiateAttackNonCreatureAction(final PhysicalCard creature) {\n super(new CreatureAttacksNonCreatureRule(), creature);\n _creature = creature;\n }", "public void Attack(){\n float randomx = (float)(Math.random()-0.5)*attackRange*GameView.instance.cameraSize/10;\n float randomy = (float)(Math.random()-0.5)*attackRange*GameView.instance.cameraSize/5;\n Vector2 target = GameView.instance.player.aimFor();\n float dx = target.x-creationPoint.x;\n float dy =target.y-creationPoint.y;\n float l= (float)Math.sqrt(dx*dx+dy*dy);\n dx = dx/l-((float)Math.random()-0.5f)/2;\n dy = dy/l-(float)(Math.random())/10;\n ProjectilePool.instance.shootArrow(creationPoint.x, creationPoint.y, 1, dx, dy, 3);\n }", "public SniperEnemy()\n { \n scoreBoost = 15;\n moneyBoost = 300;\n healthPoints = 500; \n fireRate = 45; \n movementCounter = 20;\n movementMod = 20;\n }", "public Creature(String name, String description, int hp, int dmg) {\r\n\t\tthis.name = name;\r\n\t\tthis.description = description;\r\n\t\tthis.hp = hp;\r\n\t\tthis.dmg = dmg;\r\n//\t\tthis.room = null;\r\n\t}", "Mission createMission();", "@Override\n\tprotected List<AbilityImpl> initAbility1() {\n\t\tint[] tilesDestroyedByLevel = {9, 13, 21, 29, DestroyTileAbilityComponent.DESTROY_ALL_TILES};\n\t\tList<AbilityImpl> abilityList = new ArrayList<>();\n\n\t\t// TODO: figure out how to use DestroySpecificTilesAbilityComponent here instead to blow up \n\t\t// MNMags' specific shapes\n\t\tfor (int i = 0; i < 5; i++) {\n\t\t\tAbilityComponent destroyTiles = new DestroyTileAbilityComponent\n\t\t\t\t\t(tilesDestroyedByLevel[i], AbilityComponent.ALL_COLORS_LIST);\n\t\t\tAbilityImpl ability = new AbilityImpl();\n\t\t\tability.addComponent(destroyTiles);\n\t\t\tabilityList.add(ability);\n\t\t}\n\t\treturn abilityList;\n\t}", "protected Human(String name, char displayChar, int hitPoints) {\n\t\tsuper(name, displayChar, hitPoints, ZombieCapability.ALIVE);\n\t}", "Mission(int i, String str, boolean z, boolean z2) {\n this.mActivityType = i;\n this.mOfferId = str;\n this.mEnsureSuccess = z;\n this.mShowUiNotification = z2;\n }", "public Warrior(String n)\n {\n\tname = n;\n\tHP = 1300;\n\tstr = 1000;\n\tdef = 400;\n\tdmg = 0.5;\n }", "public Node() {\n\t\tnumberOfAttacks = Integer.MAX_VALUE;\n\t\tstate = new State(); // Generate a random state.\n\t\t// Calculate its number of attacks.\n\t\tnumberOfAttacks = state.calculatenumberOfAttacks();\n\t}", "public Game() \n {\n parser = new Parser();\n name = new String();\n player = new Player();\n ai = new AI();\n createRooms();\n rand = -1;\n enemyPresent = false;\n wantToQuit = false;\n alive = true;\n createItems();\n createWeapons();\n createEnemy();\n setEnemy();\n setItems();\n setWeapons();\n setExits();\n }", "@Override\n\tprotected void loadAttackRight() {\n\t\tthis.attackRight = new SequenceAnimation(RenderableHolder.getInstance().skullMonsterSprite, frameWidth,\n\t\t\t\tframeHeight, attackFrameCount, 2, 2);\n\t\tthis.attackRight.setOffset(offsetX, offsetY);\n\t\tthis.attackRight.setPosition(this.logicalX, this.logicalY);\n\n\t}", "public void init(){\n hp = DEFAULT_MAX_HEALTH;\n bulletsFired = new ArrayList<>();\n initial_y = -1;\n\n //Sets the byte to identify the state of movement\n //For animation purposes in the renderer\n //0 = stationary\n //1 = jumping\n //2 = moving left\n //3 = jumping left\n //4 = right\n //5 = Jumping right\n //6 = crouching\n //8 = crouching left\n //10 = crouching right\n stateOfMovement = 0;\n }", "public void randomWalkingAI(boolean hostile, ArrayList<Bullet> projectileList, ArrayList<ZOrderableSprite> zOrderableSpriteList) {\n if(aiTimer > aiTimeToChangeDecision) {\n currentDecision = (int)(Math.random()*3);\n aiTimer = 0;\n }\n // Randomize angle to walk\n if(aiTimer2 > aiTimeToAction) {\n\n angleToWalk = (float)(Math.random()*360);\n if(angleToWalk >= 270 || angleToWalk < 90) {\n direction = \"right\";\n } else {\n direction = \"left\";\n }\n\t\t\tanimation.setxFlipped(direction);\n aiTimer2 = 0f;\n }\n // Decisions and courses of action\n if(currentDecision == 0) {\n isMoving = false;\n } else if(currentDecision >= 1) {\n isMoving = true;\n float fpsBoundMoveSpeed = moveSpeed * (Gdx.graphics.getDeltaTime() * 60);\n float offsetX = (float)(fpsBoundMoveSpeed * Math.cos(Math.toRadians(angleToWalk)));\n float offsetY = (float)(fpsBoundMoveSpeed * Math.sin(Math.toRadians(angleToWalk)));\n if(offsetX < 0) {\n \tupdateMovementStepByStep(0, offsetX);\n\t\t\t} else if(offsetX > 0) {\n\t\t\t\tupdateMovementStepByStep(2, offsetX);\n\t\t\t}\n\t\t\tif(offsetY < 0) {\n\t\t\t\tupdateMovementStepByStep(1, offsetY);\n\t\t\t} else if(offsetY > 0) {\n\t\t\t\tupdateMovementStepByStep(3, offsetY);\n\t\t\t}\n }\n\n // hostile is true fs aiType = 1, false if aiType = 0\n // Verify is player is close enough to attack\n if(hostile && euclidianDistance(hitbox.getCenterX(), hitbox.getCenterY(), player.getHitbox().getCenterX(), player.getHitbox().getCenterY()) < hostileRange) {\n // Face player\n if(player.getHitbox().getX() <= hitbox.getCenterX()) {\n direction = \"left\";\n } else {\n direction = \"right\";\n }\n\t\t\tanimation.setxFlipped(direction);\n updateAttack(projectileList, zOrderableSpriteList);\n\n }\n }", "public Tower(String name, int cost, TowerAttack attack) {\n this.name = name;\n this.cost = cost;\n this.attack = attack;\n this.active = false;\n this.sprite = GameApp.getAssetManager().get(this.name + \".png\", Texture.class);\n }", "public ArcherTower() {\n\t\tsuper(defaultAttack, defaultRange, defaultAttackSpeed, name);\n\t}", "public Corpse(String name) {\n\t\tsuper(name,'%');\n\t\t// TODO Auto-generated constructor stub\n\t\tRandom rand=new Random();\n\t\tturnsToZombify=rand.nextInt(5)+6;\n\t\t\n\t}", "public StatusAbility(StatusEffect effect, AnimatedSprite animation, String name, String desc, double energyCost, int cooldown, int xRange, int yRange, boolean enemyTarget, boolean friendTarget) {\n super(animation, name, desc, energyCost, cooldown, xRange, yRange, enemyTarget, friendTarget);\n\n this.effect = effect;\n }", "public BattleWeaponsSegmentAction() {\n }", "public Level3(Game game)\n {\n super(game);\n \n // set game var\n g = game;\n \n // set world\n world = game.getWorld();\n //set player\n player = game.getPlayer();\n // set default enemy exists state\n enemyExist = true;\n // set frame\n frame = g.getFrame();\n\n }", "public MagineerStrike() {\n super(ID, NAME, IMG, COST, DESCRIPTION, TYPE, COLOR, RARITY, TARGET);\n artistNames.add(\"Jake Berry\");\n flavorText = \"There is a reason that spears are one of the oldest weapons known to man. \" +\n \"You may not be a swordfighter, but at the very least you /will/ learn to use a spear.\";\n\n MagineerMod.logger.info(\"ID: \"+ID);\n MagineerMod.logger.info(\"cardStrings: \"+cardStrings);\n MagineerMod.logger.info(CardCrawlGame.languagePack);\n MagineerMod.logger.info(\"CardCrawlGame.languagePack: \"+CardCrawlGame.languagePack);\n\n\n // Aside from baseDamage/MagicNumber/Block there's also a few more.\n // Just type this.base and let intelliJ auto complete for you, or, go read up AbstractCard\n\n baseDamage = DAMAGE;\n\n this.tags.add(BaseModCardTags.BASIC_STRIKE); //Tag your strike, defend and form (Shadow form, demon form, echo form, etc.) cards so that they function correctly.\n this.tags.add(CardTags.STRIKE);\n\n cardArtLayers512.add(new RenderImageLayer(TextureLoader.getTexture(cardArt512+portraitFilename)));\n cardArtLayers1024.add(new RenderImageLayer(TextureLoader.getTexture(cardArt1024+portraitFilename)));\n\n actionList.add(new DamageDescAction(this));\n\n updateDescription();\n }", "public Target()\n\t{\n\t\tx = 2.0;\n\t\ty = 2.0;\n\t\tangle = 0.0;\n\t\tdistance = 0.0;\n\t\tnullTarget=true;\n\t}", "public Observant() {\n super(ID, 1, CardType.SKILL, CardRarity.UNCOMMON, CardTarget.SELF);\n }", "public void attack()\n {\n getWorld().addObject(new RifleBullet(player.getX(), player.getY(), 1, 6, true), getX(), getY()); \n }", "public void spawnNew() {\n\t\tif (tier> 1) {\n\t\t\ttier--;\n\t\t\thealth = tier;\n\t\t\tdamage = tier;\n\t\t\tspeed = 5;\n\t\t\timg = getImage(updateImage(tier)); // converted getImage to protected b/c it wasn't accessible by Balloon class (child class)\n\t\t}\n\t\telse {\n\t\t\tisAlive = false;\n\t\t\tdeletePath();\t\t\t\n\t\t}\n\t}", "AttackResult randomAttack();", "public void attack() {\n\n }", "@Override\n\tpublic void startCooldown() {\n\t\tthis.setSpecialAttackCooldown(HunterKillerConstants.SOLDIER_COOLDOWN);\n\t}", "public Boss() {\n\t\tlife = 3;\n\t\timage = new Image(\"/Model/boss3.png\", true);\n\t\tboss = new ImageView(image);\n\t\tRandom r = new Random();\n\t\tboss.setTranslateX(r.nextInt(900));\n\t\tboss.setTranslateY(0);\n\t\tisAlive = true;\n\t}", "public Weapon(MainPlayer p, ArrayList<MainPlayer> enemies, ArrayList<StaticObjects> s,\r\n\t\t\tArrayList<ReactiveObjects> r, boolean l, double velocity,\r\n\t\t\tdouble angle) {\r\n\t\ttrajectoryIncrements = calculateTrajectory(velocity, angle);\r\n\t\tvisible = true;\r\n\t\tstaticobjects = s;\r\n\t\treactiveobjects = r;\r\n\t\tthis.enemies = enemies;\r\n\t\tthis.velocity = velocity;\r\n\t\tthis.angle = angle;\r\n\r\n\t\tloadAnnimationImages();\r\n\t\tloadDestructionImages();\r\n\t\tthis.player = p;\r\n\t\tthis.player.setGrenadesAvailable(player.getGrenadesAvailable() - 1);\t\t\r\n\t\tif (l == true) {\r\n\t\t\tx = p.x + p.playerImage.getWidth(null);\r\n\t\t\ty = p.y;\r\n\t\t} else {\r\n\t\t\tx = p.x;\r\n\t\t\ty = p.y;\r\n\t\t}\r\n\r\n\t\tlaunchDirectionRight = l;\r\n\t\trectangle = new Rectangle(x, y, currentImage.getWidth(null),\r\n\t\t\t\tcurrentImage.getHeight(null));\r\n\t\timageHeight = currentImage.getHeight(null);\r\n\t\timageWidth = currentImage.getWidth(null);\r\n\t\ttimer = new Timer(20, this);\r\n\t\ttimer.start();\r\n\t}", "protected TwoInputGate( String name, float delay ) {\n\tsuper( name, delay );\n }", "@Override\n\tpublic void onAction(L2PcInstance player, boolean interact)\n\t{\n\t\tif(!canTarget(player))\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tplayer.setLastFolkNPC(this);\n\n\t\t// Check if the L2PcInstance already target the L2GuardInstance\n\t\tif(getObjectId() != player.getTargetId())\n\t\t{\n\t\t\t// Send a Server->Client packet MyTargetSelected to the L2PcInstance player\n\t\t\t// The color to display in the select window is White\n\t\t\tMyTargetSelected my = new MyTargetSelected(getObjectId(), 0);\n\t\t\tplayer.sendPacket(my);\n\n\t\t\t// Set the target of the L2PcInstance player\n\t\t\tplayer.setTarget(this);\n\n\t\t\t// Send a Server->Client packet ValidateLocation to correct the L2NpcInstance position and heading on the client\n\t\t\tplayer.sendPacket(new ValidateLocation(this));\n\t\t}\n\t\telse if(interact)\n\t\t{\n\t\t\t// Check if the L2PcInstance is in the _aggroList of the L2GuardInstance\n\t\t\tif(containsTarget(player))\n\t\t\t{\n\t\t\t\t// Set the L2PcInstance Intention to AI_INTENTION_ATTACK\n\t\t\t\tplayer.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, this);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// Calculate the distance between the L2PcInstance and the L2NpcInstance\n\t\t\t\tif(canInteract(player))\n\t\t\t\t{\n\t\t\t\t\t// Send a Server->Client packet SocialAction to the all L2PcInstance on the _knownPlayer of the L2NpcInstance\n\t\t\t\t\t// to display a social action of the L2GuardInstance on their client\n\t\t\t\t\t// Если НПЦ не разговаривает, то слать социалку приветствия собственно и не имеет смысла\n\t\t\t\t\tif(!Config.NON_TALKING_NPCS.contains(getNpcId()))\n\t\t\t\t\t{\n\t\t\t\t\t\tbroadcastPacket(new SocialAction(getObjectId(), Rnd.get(8)));\n\t\t\t\t\t}\n\n\t\t\t\t\tList<Quest> qlsa = getTemplate().getEventQuests(Quest.QuestEventType.QUEST_START);\n\t\t\t\t\tList<Quest> qlst = getTemplate().getEventQuests(Quest.QuestEventType.ON_FIRST_TALK);\n\n\t\t\t\t\tif(qlsa != null && !qlsa.isEmpty())\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.setLastQuestNpcObject(getObjectId());\n\t\t\t\t\t}\n\n\t\t\t\t\tif(qlst != null && qlst.size() == 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tqlst.get(0).notifyFirstTalk(this, player);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tshowChatWindow(player, 0);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t// Set the L2PcInstance Intention to AI_INTENTION_INTERACT\n\t\t\t\t\tplayer.getAI().setIntention(CtrlIntention.AI_INTENTION_INTERACT, this);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t// Send a Server->Client ActionFail to the L2PcInstance in order to avoid that the client wait another packet\n\t\tplayer.sendActionFailed();\n\t}", "public void useItem(L2PlayableInstance playable, L2ItemInstance item)\r\n\t{\r\n\t\tif (!(playable instanceof L2PcInstance))\r\n\t\t\treturn;\r\n\r\n\t\tL2PcInstance activeChar = (L2PcInstance) playable;\r\n\t\tL2Object target = activeChar.getTarget();\r\n\t\tif (!(target instanceof L2MonsterInstance))\r\n\t\t{\r\n\t\t\t// Send a System Message to the caster\r\n\t\t\tSystemMessage sm = new SystemMessage(SystemMessageId.INCORRECT_TARGET);\r\n\t\t\tactiveChar.sendPacket(sm);\r\n\r\n\t\t\t// Send a Server->Client packet ActionFailed to the L2PcInstance \r\n\t\t\tactiveChar.sendPacket(ActionFailed.STATIC_PACKET);\r\n\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\t// u can use soul crystal only when target hp goes below <50%\r\n\t\tif (((L2MonsterInstance) target).getStatus().getCurrentHp() > ((L2MonsterInstance) target).getMaxHp() / 2.0)\r\n\t\t{\r\n\t\t\tactiveChar.sendPacket(ActionFailed.STATIC_PACKET);\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tint crystalId = item.getItemId();\r\n\r\n\t\t// Soul Crystal Casting section\r\n\t\tL2Skill skill = SkillTable.getInstance().getInfo(2096, 1);\r\n\t\tactiveChar.useMagic(skill, false, true);\r\n\t\t// End Soul Crystal Casting section\r\n\r\n\t\t// Continue execution later\r\n\t\tCrystalFinalizer cf = new CrystalFinalizer(activeChar, target, crystalId);\r\n\t\tThreadPoolManager.getInstance().scheduleEffect(cf, skill.getHitTime());\r\n\r\n\t}", "public Ant(){ // The position and direction of the ant is completely randomizated in it's creation\n this.position[0] = (int)Math.floor(Math.random() * 20); \n this.position[1] = (int)Math.floor(Math.random() * 20);\n this.image = (int)Math.floor(Math.random() * 4);\n }", "public Player(byte id, short xPos, short yPos, byte hp, String name, ArrayList<Pair<Byte, Short>> weapons, ArrayList<Bullet> bullets, LinkedList<Byte> trakedWeapons, boolean jumpState, boolean fallState, short initial_y, byte currentWeapon,short currWeaponammo, short shootingDirection, boolean sprint, int score, byte roundsWon, boolean ready,int stateOfMovement,byte charId){\n this.id =id;\n this.score = score;\n this.ready = ready;\n this.xPos = xPos;\n this.yPos = yPos;\n this.hp = hp;\n this.weapons = weapons;\n this.name = name;\n character_id = 1;\n this.weaponEntryTracker = trakedWeapons;\n this.isJumping=jumpState;\n this.isFalling=fallState;\n this.bulletsFired = bullets;\n this.currentWeapon = new Pair<>(currentWeapon,currWeaponammo);\n this.initial_y = initial_y;\n this.shootingDirection = shootingDirection;\n this.sprint = sprint;\n this.roundsWon = roundsWon;\n this.stateOfMovement = stateOfMovement;\n this.character_id = charId;\n audioHandler = new AudioHandler();\n }", "@Override\n\tpublic L2CharacterAI getAI()\n\t{\n\t\tif (aiCharacter == null)\n\t\t{\n\t\t\tsynchronized (this)\n\t\t\t{\n\t\t\t\tif (aiCharacter == null)\n\t\t\t\t{\n\t\t\t\t\taiCharacter = new L2AttackableAI(new AIAccessor());\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn aiCharacter;\n\t}", "public PlayerImplementation(String name) {\n super(name);\n p1 = this; // hack for easy access to player\n\n // TODO find a better place to put these\n this.getDispatcher().getRole().addBehaviorTemplate(FrankKillsVictim.makeLatent());\n\n // prevent player from making toasts or random approaches\n removeBehavior(GroupChat.class);\n removeBehavior(ApproachBehavior.class);\n removeBehavior(RandomizedMoveTo.class);\n removeBehavior(UseRandomAnnotatedItem.class);\n }", "private void createEnemy()\n {\n scorpion = new Enemy(\"Giant Scorpion\", 5, 10); \n rusch = new Enemy(\"Mr. Rusch\", 10, 1000);\n skeleton = new Enemy(\"Skeleton\", 10, 50);\n zombie = new Enemy(\"Zombie\", 12, 25);\n ghoul = new Enemy(\"Ghoul\", 15, 45);\n ghost = new Enemy(\"Ghost\", 400, 100);\n cthulu = new Enemy(\"Cthulu\", 10000000, 999999);\n concierge = new Enemy(\"Concierge\", 6, 100);\n wookie = new Enemy(\"Savage Wookie\", 100, 300);\n }" ]
[ "0.60049176", "0.5800527", "0.5691604", "0.5609265", "0.554044", "0.550708", "0.5444377", "0.54387033", "0.5428253", "0.5412384", "0.5348875", "0.53149855", "0.52921486", "0.526878", "0.5265499", "0.52493805", "0.52313614", "0.52157664", "0.5208797", "0.5208277", "0.52014583", "0.5199129", "0.51951015", "0.5194769", "0.51820004", "0.5168207", "0.51506054", "0.5137537", "0.51350045", "0.51211345", "0.5118706", "0.51094174", "0.510482", "0.50907147", "0.5085392", "0.50637656", "0.5055726", "0.5045646", "0.5039076", "0.5034953", "0.50243753", "0.50197214", "0.5003188", "0.50021696", "0.49990287", "0.49969462", "0.49902663", "0.49897406", "0.49882242", "0.49881646", "0.4982865", "0.4979561", "0.49770218", "0.4968091", "0.49653205", "0.49629992", "0.49624342", "0.49619853", "0.49565393", "0.4956427", "0.49538946", "0.49534193", "0.4953063", "0.49520686", "0.49484372", "0.49475753", "0.49355718", "0.49320778", "0.49300918", "0.4927433", "0.49240094", "0.49102974", "0.4902352", "0.48990396", "0.48956147", "0.48922062", "0.48902723", "0.48848206", "0.4884415", "0.48765072", "0.48752344", "0.48734367", "0.48683396", "0.48662114", "0.48606858", "0.48599622", "0.4857914", "0.48572123", "0.4847006", "0.4843392", "0.48327518", "0.48320752", "0.4830532", "0.4829394", "0.48244157", "0.4817377", "0.48151365", "0.48060435", "0.4806028", "0.48042047" ]
0.65544176
0
Return the L2Character AI of the L2Attackable and if its null create a new one.
@Override public L2CharacterAI getAI() { if (aiCharacter == null) { synchronized (this) { if (aiCharacter == null) { aiCharacter = new L2AttackableAI(new AIAccessor()); } } } return aiCharacter; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public L2Attackable getActiveChar() { return (L2Attackable)super.getActiveChar(); }", "private EntityLivingBase findPlayerToAttack() {\n EntityPlayer player = entity.worldObj.getClosestVulnerablePlayerToEntity(entity, aggroRange);\n if ( player != null && !player.capabilities.isCreativeMode && entity.canEntityBeSeen(player) )\n \treturn player;\n\n EntityLivingBase target = entity.getLastAttacker();\n if ( isTargetValid(target) && entity.canEntityBeSeen(target) )\n \treturn target;\n\n \treturn null;\n }", "public interface AI {\n\n /**\n * Sets the new enemy position.\n * @param pos the new enemy position\n */\n void setEnemyPos(Point2D pos);\n\n /**\n * Returns the new position for the enemy to\n * move to.\n * @param target the position that wants to be tracked\n * @param pursuit the state in which the enemy is in\n * @param map\n * @return the position to move to\n */\n Point2D getNextMove(Point2D target, boolean pursuit, Set<Point2D> map);\n\n /**\n * Returns the new enemy rotation based on the\n * state in which the enemy is in.\n * @param target the position that wants to be tracked\n * @param pursuit the state in which the enemy is in\n * @return the angle that the enemy should face\n */\n double getRotation(Point2D target, boolean pursuit);\n\n /**\n * Returns if the enemy is in pursuit of the target\n * by calculating if the noise radius overlap with the\n * two.\n * @param target the position that wants to be tracked\n * @param noise the radius of the noise made by a player action\n * @return the state in which the enemy will be in\n * @see Player\n */\n boolean isInPursuit(Point2D target, double noise);\n\n /**\n * Returns if the enemy has the {@code target} in line of\n * sight and is close enough to get the enemy attention\n * to shoot.\n * @param target the position that wants to be tracked\n * @return the action that should be performed by the enemy\n */\n boolean isShooting(Point2D target);\n\n /**\n * Returns the collection of all position to check\n * if target is obscured by a wall used to JUnit\n * tests purpose.\n * @return the collections of all wall objects position\n */\n Set<Point2D> getWallSet();\n\n}", "public PlayerCharacter createAscio() {\n\t\t\n\t\t\n\t\treturn null;\n\t}", "public void attackTargetCharacter() {\n }", "public boolean isAI() {\r\n\t\treturn AI;\r\n\t}", "public Character getOpponent() {\n Character result = null;\n if (this.enemies.getAdversaries().size() > 0) {\n Collections.shuffle(this.enemies.getAdversaries());\n result = this.enemies.getAdversaries().get(0);\n this.enemies.getAdversaries().remove(result);\n }\n return result;\n }", "AbilityTarget getAbilityTarget();", "public L2Character getMostHated()\n\t{\n\t\tif (getAggroListRP().isEmpty() || isAlikeDead())\n\t\t{\n\t\t\treturn null;\n\t\t}\n\t\t\n\t\tL2Character mostHated = null;\n\t\t\n\t\tint maxHate = 0;\n\t\t\n\t\t// While Interating over This Map Removing Object is Not Allowed\n\t\tsynchronized (getAggroList())\n\t\t{\n\t\t\t// Go through the aggroList of the L2Attackable\n\t\t\tfor (final AggroInfoHolder ai : getAggroListRP().values())\n\t\t\t{\n\t\t\t\tif (ai == null)\n\t\t\t\t{\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (ai.getAttacker().isAlikeDead() || !getKnownList().knowsObject(ai.getAttacker()) || !ai.getAttacker().isVisible() || ai.getAttacker() instanceof L2PcInstance && !((L2PcInstance) ai.getAttacker()).isOnline() && !((L2PcInstance) ai.getAttacker()).isInOfflineMode()) // if player go\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// in offline\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// mode, he\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// must be hated\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// however\n\t\t\t\t{\n\t\t\t\t\tai.initHate();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (ai.getHate() > maxHate)\n\t\t\t\t{\n\t\t\t\t\tmostHated = ai.getAttacker();\n\t\t\t\t\tmaxHate = ai.getHate();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (mostHated != null)\n\t\t{\n\t\t\tthis.mostHated = mostHated;\n\t\t}\n\t\t\n\t\treturn mostHated;\n\t}", "private String makeAIMove() {\n switch (level) {\n case 1:\n return easyMove();\n case 2:\n return mediumMove();\n case 3:\n return hardMove();\n default:\n //unreachable statement\n return null;\n }\n }", "protected Entity findPlayerToAttack()\n {\n EntityPlayer var1 = this.worldObj.getClosestVulnerablePlayerToEntity(this, 16.0D);\n return var1 != null && this.canEntityBeSeen(var1) ? var1 : null;\n }", "AttackResult randomAttack();", "@Override\n\tpublic Attack makeAttack() {\n\t\tattack = new Attack();\n\t\tunit = getRandomListUnit();\n\t\t/*\n\t\tobliczenie wartosci ataku od losowo wybranej jednostki oraz\n\t\tustawienie tej wartosci w obiekcie Attack\n\t\tDOdatkowo zostaje przeslane informacje do loggera. Inofrmacje zawieraja, jaka jednostka, wartosc ataku, ilosc jednostek w armii\n\t\t*/\n\t\tint attackValue = (unit.getDefense()+unit.getHp())/2;\n\t\tattack.setAttack(attackValue);\n\t\tlogger.add(\"attacker\",attackValue, unitListSize());\n\n\t\treturn attack;\n\t}", "public Battleable getOpponent()\n\t{\n\t\t/* TODO: Inherited function from Character Interface, requires implementation! */\n\t\treturn null;\n\t}", "Player attackingPlayer(int age, int overall, int potential) {\r\n Player newPlayer = new Player(this.nameGenerator.generateName(), age, overall, potential, 'C' , 'F');\r\n\r\n\r\n\r\n\r\n }", "public Player getAiPlayer() {\n return aiPlayer;\n }", "AttackResult smartAttack();", "@Override\n protected Entity findPlayerToAttack() {\n EntityPlayer player = this.worldObj.getClosestVulnerablePlayerToEntity(this, 64.0);\n if (player != null) {\n if (this.shouldAttackPlayer(player)) {\n if (this.lookDelay++ == 5) {\n this.lookDelay = 0;\n return player;\n }\n }\n else {\n this.lookDelay = 0;\n }\n }\n return null;\n }", "public L2Character getOverhitAttacker()\n\t{\n\t\treturn overhitAttacker;\n\t}", "public Attack getBestOpponentAttack()\n\t{\n\t\treturn bestOpponentAttack;\n\t}", "protected PlayerLogicComponent getAIUnit() {\r\n return _aiUnit;\r\n }", "private static void defineInitialAttackTarget() {\n\t\tUnit buildingToAttack = MapExploration.getNearestEnemyBuilding();\n\n\t\t// We know some building of CPU that we can attack.\n\t\tif (buildingToAttack != null) {\n\t\t\tchangeNextTargetTo(buildingToAttack);\n\t\t}\n\n\t\t// No building to attack found, safely decide not to attack.\n\t\telse {\n\t\t\tchangeStateTo(STATE_PEACE);\n\t\t}\n\t}", "private static Image getAttackPoint()\n\t{\n\t\ttry {\n\t\t\treturn ImageIO.read(new File(guiDirectory + attack));\n\t\t} catch (IOException ioe) {\n\t\t}\n\t\treturn null;\n\t}", "public interface AttackableNPC {\n\t// Logic for determining what the next action or set of actions for the NPC should be\n\tvoid determineNextAction();\n\n\t// For now will almost always be Player, but needed for when allies/depth of NPCs are introduced\n\tEntity determinePriorityTarget();\n\n}", "private Player aiRequestTarget(Player ai){\n // generates a random player index\n int index = (int) (Math.random() * GoFish.Players.length);\n\n // prevents the logic from outputting and index that is equal\n // to the player object\n while (GoFish.Players[index]==ai){\n index = (int) (Math.random() * GoFish.Players.length);\n }// end while\n\n return GoFish.Players[index];\n }", "public int makeAIMove(Player player) {\n\t\tint input = -1;\n\t\tboolean validMove = false;\n\n\t\tSystem.out.println(\"Current player is: \" + player.color);\n\n\t\t// Get all the valid moves if there are any\n\t\tArrayList<ArrayList<Integer>> validMoves = getValidMoves(board, player.color);\n\t\tprintValidMoves(validMoves, board);\n\t\t// As long as the input isn't correct, this will loop\n\t\twhile (validMove == false) {\n\t\t\t// Check if there are any possible moves\n\t\t\tif (!validMoves.isEmpty()) {\n\t\t\t\t// Als er een blocking move gedaan kan worden, wordt dit gedaan. Dit heeft\n\t\t\t\t// nummer 1 prioriteit.\n\t\t\t\tint blockMove = player.ai.blockingMove(validMoves, board, player);\n\t\t\t\tif (blockMove != -1) {\n\t\t\t\t\tinput = blockMove;\n\t\t\t\t\t// Random zet, gebeurt op dit moment nooit\n\t\t\t\t} else if (turn < 0) {\n\t\t\t\t\tinput = player.ai.random(board, player);\n\t\t\t\t\t// Zet gebaseerd op boardweight, gebeurt op dit moment nooit\n\t\t\t\t} else if (turn < 0) {\n\t\t\t\t\tinput = player.ai.boardWeighting(board, player);\n\t\t\t\t\t// Minimax, 8 diep, gebeurt tussen beurt 0 en 30\n\t\t\t\t} else if (turn < 30) {\n\t\t\t\t\tinput = player.ai.minimaxAvailableMoves(board, player, 0, 8, 0, 0, Integer.MIN_VALUE,\n\t\t\t\t\t\t\tInteger.MAX_VALUE, 0);\n\t\t\t\t\t// Minimax, 9 diep, gebeurt tussen beurt 30 en 40\n\t\t\t\t} else if (turn < 40) {\n\t\t\t\t\tinput = player.ai.minimaxAvailableMoves(board, player, 0, 9, 0, 0, Integer.MIN_VALUE,\n\t\t\t\t\t\t\tInteger.MAX_VALUE, 0);\n\t\t\t\t\t// Minimax, 10 diep, gebeurt tussen beurt 40 en 45\n\t\t\t\t} else if (turn < 45) {\n\t\t\t\t\tinput = player.ai.minimaxAvailableMoves(board, player, 0, 10, 0, 0, Integer.MIN_VALUE,\n\t\t\t\t\t\t\tInteger.MAX_VALUE, 0);\n\t\t\t\t\t// Minimax, 16 diep, gebeurt tussen beurt 45 en 60\n\t\t\t\t} else {\n\t\t\t\t\tinput = player.ai.minimaxTest(board, player, 0, 16, 0, 0, Integer.MIN_VALUE, Integer.MAX_VALUE, 0);\n\t\t\t\t}\n\n\t\t\t\t// Voer de move die gevonden is uit.\n\t\t\t\tvalidMove = setMove(input, validMoves, player.color, board);\n\n\t\t\t\tif (validMove == true) {\n\t\t\t\t\tturn++;\n\t\t\t\t}\n\t\t\t\t// Reset noWinnerCount\n\t\t\t\tnoWinnerCount = 0;\n\t\t\t} else {\n\t\t\t\t// 1 player can't move, if this counter reaches 2, that means both players can't\n\t\t\t\t// move and the game will end\n\t\t\t\tnoWinnerCount++;\n\t\t\t\tSystem.out.println(\"Out of moves + Count = \" + noWinnerCount);\n\t\t\t\tvalidMove = true;\n\t\t\t}\n\t\t}\n\n\t\t// Input is last player player\n\t\tArrayList<ArrayList<Integer>> validMovesOpponent = getValidMoves(board, player.opponent);\n\t\tif (validMovesOpponent.size() > 0) {\n\t\t\tswitchTurn(player);\n\t\t}\n\n\t\treturn input;\n\t}", "public AIPlayer getAIPlayer(Player player) {\n AIObject aio = getAIObject(player.getId());\n return (aio instanceof AIPlayer) ? (AIPlayer) aio : null;\n }", "public void initMission() {\n\t\tinitNumOfMoves();\t//reset counter\n\t\t//Begin by creating a random board.\n\t\t/* 1st parameter: is the cell at (0,0) always empty?\n\t\t * 2nd parameter: will this board be accessed by the AI?\n\t\t * See the constructor comments in Board.java for more details. */\n\n\t\tboard = new Board(this.options.toUpperCase().contains(\"00\") ? true : false, false);\n\n\t\t//TODO OPTIONAL: instead of spawning a random board, we can customize\n\t\t//our own board! Just un-comment any of the below boards or paste your own!\n\n\t\t//Wastes to the right AND to the south! Watch how the AI would react.\n\t\t//try one-player AI version (aggressive or not, doesn't matter)\n//\t\tboard = new Board(new String[][]\n//\t\t\t\t{{\"\", \"P\", \"W\", \"\", \"\", \"\"},\n//\t\t\t\t {\"W\", \"\", \"\", \"\", \"G\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"P\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"\", \"P\", \"\", \"\", \"\"},\n//\t\t\t\t});\n\t\t//What's the most efficient way for the AI to find the victim?\n\t\t//Note there are no wastes or fire pits in this scenario.\n//\t\t\tboard = new Board(new String[][]\n//\t\t\t\t{{\" \", \" \", \" \", \" \", \" \", \" \" },\n//\t\t\t\t{\" \", \" \", \" \", \" \", \" \", \" \" },\n//\t\t\t\t{\" \", \" \", \" \", \" \", \" \", \" \" },\n//\t\t\t\t{\" \", \" \", \"G\", \" \", \" \", \" \" },\n//\t\t\t\t{\" \", \" \", \" \", \" \", \" \", \" \" },\n//\t\t\t\t{\" \", \" \", \" \", \" \", \" \", \" \" }\n//\t\t\t\t});\n\n\t\t//Impossible one. Useful for explaining probability during presentation.\n//\t\t\t\t\t\tboard = new Board(new String[][]\n//\t\t\t\t\t\t\t\t{{\"\", \"\", \"P\", \"\", \"\", \"\"},\n//\t\t\t\t\t\t\t\t{\"\", \"P\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t\t\t\t\t{\"P\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t\t\t\t\t{\"W\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t\t\t\t\t{\"\", \"\", \"\", \"W\", \"\", \"\"},\n//\t\t\t\t\t\t\t\t{\"\", \"G\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t\t\t\t\t});\n\n\t\t/* Very tough board, but the AI is up to the task. */\n//\t\tboard = new Board(new String[][]\n//\t\t\t\t{{\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"P\", \"P\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"W\", \"\", \"P\", \"\", \"\", \"\"},\n//\t\t\t\t {\"G\", \"\", \"\", \"W\", \"\", \"\"},\n//\t\t\t\t});\n\n\t\t//tough tough tough. The victim is surrounded by a wall of fire!\n\t\t//try it with 2 AI's, starting in random cell. One of them might die!\n//\t\tboard = new Board(new String[][]\n//\t\t\t\t{{\"\", \"P\", \"\", \"G\", \"\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"P\", \"W\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"W\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"P\"},\n//\t\t\t\t {\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t});\n\n\t\t//with aggressiveModeOn set to true, the AI will disinfect both wastes.\n\t\t//if set to false, the AI will disinfect only one.\n\t\t//Either way, AI gets the victim.\n\t\t//\t\t\t\tboard = new Board(new String[][]\n\t\t//\t\t\t\t\t\t{{\"\", \"\", \"\", \"\", \"\", \"\"},\n\t\t//\t\t\t\t\t\t{\"\", \"\", \"\", \"P\", \"\", \"\"},\n\t\t//\t\t\t\t\t\t{\"\", \"W\", \"\", \"\", \"\", \"\"},\n\t\t//\t\t\t\t\t\t{\"\", \"W\", \"\", \"G\", \"\", \"P\"},\n\t\t//\t\t\t\t\t\t{\"\", \"\", \"\", \"\", \"\", \"\"},\n\t\t//\t\t\t\t\t\t{\"P\", \"\", \"\", \"\", \"\", \"\"},\n\t\t//\t\t\t\t\t\t});\n\n\n\t\t//RARE situation (one-player mode) where setting aggressiveModeOn to true will result in death.\n\t\t//Non-aggressive mode will get the victim. Start at cell (0,0).\n//\t\tboard = new Board(new String[][]\n//\t\t\t\t{{\"\", \"\", \"\", \"P\", \"G\", \"P\"},\n//\t\t\t\t{\"\", \"\", \"P\", \"W\", \"W\", \"\"},\n//\t\t\t\t{\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t{\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t{\"\", \"\", \"\", \"P\", \"P\", \"\"},\n//\t\t\t\t{\"P\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t});\n\n\n\t\t//Very rare instance. if both players are AI and start at cell (0,0),\n\t\t//they will BOTH die. However, note that it's not the AI's fault.\n\t\t//The AI still managed to MINIMIZE risk. They just got unlucky.\n//\t\tboard = new Board(new String[][]\n//\t\t\t\t{{\"\", \"\", \"\", \"\", \"P\", \"\"},\n//\t\t\t\t{\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t{\"\", \"W\", \"P\", \"\", \"\", \"\"},\n//\t\t\t\t{\"W\", \"\", \"\", \"\", \"G\", \"\"},\n//\t\t\t\t{\"P\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t{\"\", \"\", \"\", \"\", \"\", \"\"},\n//\t\t\t\t});\n\n\t\t/* Use custom method in Board class to print the board to the console and save it to a text file.\n\t\t * See the method comments in Board.java class for more details. */\n\t\tboard.printBoard();\n\n\t\t/* Initialize the cell in which the players will start the mission. */\n\t\tCell startRoom;\n\t\tCellAsPerceivedByAI startRoomAI;\n\t\tCell[] startRooms = this.setStartRoomAndBoardAI(this.options.toUpperCase().contains(\"00\"));\n\t\tstartRoom = startRooms[0];\n\t\tstartRoomAI = (CellAsPerceivedByAI)startRooms[1];\n\n\t\tthis.createPlayers(startRoom, startRoomAI, this.p1Name, this.p2Name,\n\t\t\t\tthis.options.toUpperCase().contains(\"A1\"), this.options.toUpperCase().contains(\"A2\"), this.options.toUpperCase().contains(\"S\"),\n\t\t\t\tthis.options.toUpperCase().contains(\"H\") ? \"H\" : this.options.toUpperCase().contains(\"R\") ? \"R\" : \"B\");\t//create players\n\n\t\tthis.hideAllPics();\n\t\tgreyOutCell(startRoomAI.getX(), startRoomAI.getY());\n\t\trepaint();\n\t}", "public Board AISelect(Board board) {\n return board.getChildren().isEmpty() || AILevel == 0 ? null : AISelect(board, AILevel);\n }", "public void AIDamage() {\r\n\t\tif (attackStyle == 2) {\r\n\t\t\tfor(int i = 0; i < AIObject.length; i++) {\r\n\t\t\t\tif ((inFlight) && (Math.abs(aX-AIObject[i].getAIX()) < 5) && (Math.abs(aY-AIObject[i].getAIY())) < 4 ) {\r\n\t\t\t\t\tAIObject[i].setHealth(-25 * damageReduction);\r\n\t\t\t\t\tdrawArrow = false;\r\n\t\t\t\t\tcooldown = 15;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}else {\r\n\t\t\tif (mouseLeft) {\r\n\t\t\t\tfor(int i = 0; i < AIObject.length; i++){\r\n\t\t\t\t\tif ((drawSword) && (cooldown == 0) && (playerObject[0].getX() -AIObject[i].getAIX() <85) && (playerObject[0].getX()-AIObject[i].getAIX() >-1) && (playerObject[0].getY() - AIObject[i].getAIY() < 20) && (playerObject[0].getY()-AIObject[i].getAIY()>-5)) {\r\n\t\t\t\t\t\tAIObject[i].setHealth(-50 * damageReduction);\r\n\t\t\t\t\t\tcooldown = 5;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}else {\r\n\t\t\t\tfor(int i=0; i < AIObject.length; i++){\r\n\t\t\t\t\tif ((drawSword) && (cooldown == 0) && (AIObject[i].getAIX()-playerObject[0].getX() <85) && (AIObject[i].getAIX() - playerObject[0].getX() > -1) && (playerObject[0].getY() - AIObject[i].getAIY() < 20) && (playerObject[0].getY()-AIObject[i].getAIY()>-5)) {\r\n\t\t\t\t\t\tAIObject[i].setHealth(-50 * damageReduction);\r\n\t\t\t\t\t\tcooldown = 5;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\tfor(int i=0; i < AIObject.length; i++){\r\n\t\t\t//checks if AI is close enough to attack with melee\r\n\t\t\tfor (int j = 0; j < playerObject.length; j++) {\r\n\t\t\t\tif ((!shield) && (Math.abs(AIObject[i].getAIX() - playerObject[j].getX()) <= 10) && (Math.abs(AIObject[i].getAIY() - playerObject[j].getY())) <= 3) {\r\n\t\t\t\t\tplayerObject[j].setHealth(DAMAGE_AMOUNT * difficulty);\r\n\t\t\t\t\tif (playerObject[j].getHealth() <= 0) {\r\n\t\t\t\t\t\tdead = true;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public Warrior checkWarrior(){\n Object obj=charactersOccupiedTheLocation[0];\n if(obj!=null){\n return (Warrior)obj;\n }\n return null;\n }", "public AttackableKnownList(L2Attackable activeChar)\n {\n super(activeChar);\n }", "public void abilityOne() {\n ability(map.getCurrentTurnHero().getAbilities().get(0));\n }", "private void activateTraitByAI() {\n\t\tChampion AI = currentTask.getCurrentChamp();\n\t\t\n\t\tif(AI instanceof GryffindorWizard){\n\t\t\tactivateGryffindorTrait();\n\t\t\t\n\t\t}else if(AI instanceof HufflepuffWizard){\n\t\t\tactivateHufflepuffTrait();\n\t\t\t\n\t\t}else if(AI instanceof SlytherinWizard){\n\t\t\tint randomDirection = (int) (Math.random()*3);\n\t\t\tDirection direction;\n\t\t\tswitch(randomDirection){\n\t\t\tcase 0: direction = Direction.FORWARD; break;\n\t\t\tcase 1: direction = Direction.BACKWARD; break;\n\t\t\tcase 2: direction = Direction.RIGHT; break;\n\t\t\tdefault: direction = Direction.LEFT;\n\t\t\t}\n\t\t\tdirectionsInAction = new ArrayList<Direction>();\n\t\t\tdirectionsInAction.add(direction);\n\t\t\tactivateSlytherinTrait();\n\t\t\n\t\t}else if(AI instanceof RavenclawWizard){\n\t\t\tactivateRavenclawTrait();\t\n\t\t\t\n\t\t}\n\t\t\n\t}", "void basicAttack(Character attacked);", "public void randomWalkingAI(boolean hostile, ArrayList<Bullet> projectileList, ArrayList<ZOrderableSprite> zOrderableSpriteList) {\n if(aiTimer > aiTimeToChangeDecision) {\n currentDecision = (int)(Math.random()*3);\n aiTimer = 0;\n }\n // Randomize angle to walk\n if(aiTimer2 > aiTimeToAction) {\n\n angleToWalk = (float)(Math.random()*360);\n if(angleToWalk >= 270 || angleToWalk < 90) {\n direction = \"right\";\n } else {\n direction = \"left\";\n }\n\t\t\tanimation.setxFlipped(direction);\n aiTimer2 = 0f;\n }\n // Decisions and courses of action\n if(currentDecision == 0) {\n isMoving = false;\n } else if(currentDecision >= 1) {\n isMoving = true;\n float fpsBoundMoveSpeed = moveSpeed * (Gdx.graphics.getDeltaTime() * 60);\n float offsetX = (float)(fpsBoundMoveSpeed * Math.cos(Math.toRadians(angleToWalk)));\n float offsetY = (float)(fpsBoundMoveSpeed * Math.sin(Math.toRadians(angleToWalk)));\n if(offsetX < 0) {\n \tupdateMovementStepByStep(0, offsetX);\n\t\t\t} else if(offsetX > 0) {\n\t\t\t\tupdateMovementStepByStep(2, offsetX);\n\t\t\t}\n\t\t\tif(offsetY < 0) {\n\t\t\t\tupdateMovementStepByStep(1, offsetY);\n\t\t\t} else if(offsetY > 0) {\n\t\t\t\tupdateMovementStepByStep(3, offsetY);\n\t\t\t}\n }\n\n // hostile is true fs aiType = 1, false if aiType = 0\n // Verify is player is close enough to attack\n if(hostile && euclidianDistance(hitbox.getCenterX(), hitbox.getCenterY(), player.getHitbox().getCenterX(), player.getHitbox().getCenterY()) < hostileRange) {\n // Face player\n if(player.getHitbox().getX() <= hitbox.getCenterX()) {\n direction = \"left\";\n } else {\n direction = \"right\";\n }\n\t\t\tanimation.setxFlipped(direction);\n updateAttack(projectileList, zOrderableSpriteList);\n\n }\n }", "@Nullable\r\n public AnimalTamer getSecondTrustedPlayer();", "public Othello(String strategieP1, int niveauP1, String strategieP2, int niveauP2) {\n\t\tpropertySupport = new PropertyChangeSupport(this);\n\t\tmyBoard = new Board(8);\n\t\tpropertySupport = new PropertyChangeSupport(this);\n\t\tinitialisationBoard();\n\t\tfoeHasPlay = true;\n\t\taiPlay = false;\n\t\tplayerBlack = spawnAI(Color.BLACK, strategieP1, niveauP1);\n\t\tplayerWhite = spawnAI(Color.WHITE, strategieP2, niveauP2);\n\t\tcurrentPlayer = playerBlack;\n\t}", "AttackResult userAttack();", "protected Entity findPlayerToAttack() {\n/* 339 */ double var1 = 8.0D;\n/* 340 */ return getIsSummoned() ? null : this.field_70170_p.func_72890_a(this, var1);\n/* */ }", "public void actionCombat(Party p1) {\n System.out.println(\"______________________________________________________________________________\\n\");\n System.out.println(this.Name + \" is attacking ...\");\n int choice = (int)(Math.random() * p1.getTeam().size());\n Character target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n\n if (this.SPEED - target.getSPEED() < 5) {\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n }\n else {\n int n = 0;\n while ((target.actualHP != 0) && (n < 2)) {\n if (n == 1) {\n choice = (int)(Math.random() * p1.getTeam().size() + 1);\n target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n }\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n if (n == 0) System.out.println(this.Name + \" attacks again ...\");\n n++;\n }\n }\n }", "public void abilityTwo() {\n if(map.getCurrentTurnHero().getAbilities().size() < 2){\n return;\n }\n ability(map.getCurrentTurnHero().getAbilities().get(1));\n }", "public void basicEnemyAI(){\n if(enemyMana == enemyManaMax){\n applyCard(enemyPlayCard(), \"enemy\");\n }\n }", "public void enemyAttack() {\n Log.i(\"enemyAttack\", \"Begins\");\n AIisAttacking = true;\n setHit(false);\n\n // Loop until A.I. selects a cell it has not chosen before.\n int counter = 0;\n int myRow = 0, myCol = 0;\n boolean selectionFound = false;\n String aiSelectedHit = \"Empty\";\n Random newRow, newCol;\n\n while (selectionFound || counter < aiAttacks.size()) {\n selectionFound = false;\n // Select random row and col\n newRow = new Random();\n myRow = newRow.nextInt(maxN);\n newCol = new Random();\n myCol = newCol.nextInt(maxN);\n\n aiSelectedHit = myRow + \", \" + myCol;\n\n while (counter < aiAttacks.size()) {\n // Check if grid has been selected before\n if (aiAttacks.get(counter).equals(aiSelectedHit)) {\n selectionFound = true;\n counter = 0;\n break;\n }\n counter++;\n }\n }\n aiAttacks.add(aiSelectedHit);\n\n checkIfOccupied(myRow, myCol);\n\n if (getHit()) {\n ivCell[myRow][myCol].setImageResource(R.drawable.mushroom);\n Log.i(\"AI getHit\", \"\" + getHit() + \", (\" + myRow + \", \" + myCol + \")\");\n } else {\n ivCell[myRow][myCol].setImageResource(R.drawable.crater);\n Log.i(\"AI getHit\", \"\" + getHit() + \", (\" + myRow + \", \" + myCol + \")\");\n }\n AIisAttacking = false;\n Log.i(\"enemyAttack\", \"Ends\");\n }", "public boolean getAI(){return ai;}", "public void battleAllyAttack() {\n if(battleAlly instanceof Character){\n battleTickStatuses();\n updateBattleSides();\n }\n\n // battleAlly now attacks targetEnemy or preference based on the type of battleAlly\n if(battleAlly != null){ // If all allies have attacked, they cannot attack anymore for this round\n MovingEntity target = battleAlly.getAttackPreference(targetEnemies);\n // if not picky, get preference is the default next target\n if(target == null) {\n target = targetEnemy;\n }\n battleAlly.attack(target, targetAllies, targetEnemies);\n //System.out.println(battleAlly.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still unfriendly\n targetEnemy = checkSideSwap(targetEnemy, true, battleAllies, targetAllies, battleEnemies, targetEnemies);\n }\n battleAlly = nextAttacker(battleAlly, battleAllies);\n\n }\n }", "void useInBattle(PlayerCharacter player, Opponent enemy) {\n\t}", "private Attack consoleGetAttack(int player) {\n int row, col;\n System.out.println(\"Player \" + player + \", it is your turn to attack.\");\n while (true) {\n\t while (true) {\n\t System.out.print(\"Row (0 through 9): \");\n\t row = scan.nextInt();\n\t if (row < 0) continue;\n\t if (row > 9) continue;\n\t break;\n\t }\n\t while (true) {\n\t System.out.print(\"Column (0 through 9): \");\n\t col = scan.nextInt();\n\t if (col < 0) continue;\n\t if (col > 9) continue;\n\t break;\n\t }\n\t if (grids[1].peek(row, col) != Grid.UNKNOWN) continue;\n\t break;\n }\n return new Attack(row, col);\n }", "public void battleEnemyAttack() {\n if(battleEnemy != null){ // If all enemies have attacked, they cannot attack anymore for this round\n\n MovingEntity target = battleEnemy.getAttackPreference(targetAllies);\n if(target == null){\n target = targetAlly;\n }\n\n battleEnemy.attack(target, targetEnemies, targetAllies);\n //System.out.println(battleEnemy.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still friendly incase of zombify\n targetAlly = checkSideSwap(targetAlly, false, battleEnemies, targetEnemies, battleAllies, targetAllies);\n }\n\n battleEnemy = nextAttacker(battleEnemy, battleEnemies);\n\n }\n }", "public String getLOAI()\n {\n return this.LOAI;\n }", "public Player winner() {\n Player result = null;\n boolean humanResult = board.fiveInARow(humanPlayer.getPiece());\n boolean player2Result = board.fiveInARow(aiPlayer.getPiece());\n if(humanResult && player2Result) {\n result = new Player(\"Tie\", 'T');\n } else if (humanResult && !player2Result) {\n result = humanPlayer;\n } else if (!humanResult && player2Result) {\n result = aiPlayer;\n }\n return result;\n }", "DnDCharacter2() {\n strength = ability();\n dexterity = ability();\n constitution = ability();\n intelligence = ability();\n wisdom = ability();\n charisma = ability();\n hitpoints = 10 + modifier(constitution);\n }", "public interface IAttackAbility\n{\n public void attack(Entity target, EntityLivingBase source);\n}", "public int heroAttack(int i) {\n switch (i) {\n case 1:\n return rand.nextInt(2) + 1;\n case 2:\n return rand.nextInt(2) + 2;\n case 3:\n return rand.nextInt(2) + 3;\n case 4:\n return rand.nextInt(4) + 4;\n default:\n return 0;\n }\n }", "public PlayerInfo(int playerID, boolean AI) {\r\n\t\tthis.playerID = playerID;\r\n\t\tthis.AI = AI;\r\n\t\tthis.robots = new ArrayList<Robot>(3);\r\n\t\t\r\n\t\t/* 0 = scout , 1 = sniper, 2 = tank */\r\n\t\tthis.robots.add(new Robot(playerID, 0));\r\n\t\tthis.robots.add(new Robot(playerID, 1));\r\n\t\tthis.robots.add(new Robot(playerID, 2));\r\n\t\t\r\n\t\tthis.curRobotType = 0;\r\n\t}", "public Position attackCell() {\n if (this.strategy == null) {\n return null;\n } else {\n return this.strategy.generateAttackPosn(this.battleMap);\n }\n }", "int getIndividualAttack();", "public MonsterAilment getAilment()\n {\n if (isBeforeFirst() || isAfterLast())\n return null;\n\n MonsterAilment ailment = new MonsterAilment();\n\n long monster_id = getLong(getColumnIndex(S.COLUMN_AILMENT_MONSTER_ID));\n // String monster_name = getString(getColumnIndex(S.COLUMN_AILMENT_MONSTER_NAME)); Not used\n String strailment = getString(getColumnIndex(S.COLUMN_AILMENT_AILMENT));\n\n ailment.setId(monster_id);\n // ailment.setMonstername(monster_name);\n ailment.setAilment(strailment);\n\n return ailment;\n }", "private void addAI(){\n\n }", "public AI(){\n super();\n }", "CharacterInfo getCharacter();", "Optional<AttackAction> inDuel(final String userName);", "public Character pickOpponent()\n {\n int oppIndex = random.nextInt(characterList.size());\n opponent = characterList.get(oppIndex);\n return opponent;\n }", "public void attack();", "private HumanGamePlayerOnKeyboard initializePlayer() {\n\t\tHumanGamePlayerOnKeyboard player = new HumanGamePlayerOnKeyboard();\n\t\tplayer.setPlayerName(HUMAN_PLAYER_NAME);\n\t\treturn player;\n\t}", "public abstract String forceAttack(Humanoid enemy);", "public Enemy getEnemy(int whichEnemy);", "protected boolean isAIEnabled()\n {\n return true;\n }", "public void setPlayer2(ElementalCharacter c)\n\t{\n\t\tec=c;\n\t}", "public abstract boolean attack(TemporaryCharm i);", "@Override\n\tpublic int calculateAttackType(Entity attacker, Entity defender) {\n\t\tif (attacker.getType() != EntityType.NPC || defender.getType() != EntityType.PLAYER) {\n\t\t\treturn ServerConstants.MELEE_ICON;\n\t\t}\n\t\tNpc attackerAsNpc = (Npc) attacker;\n\n\t\tint randomChanceOfAttack = ThreadLocalRandom.current().nextInt(0, 100);\n\n\t\tif (phase == AbyssalSirePhase.AWAKE) {\n\t\t\tif (randomChanceOfAttack <= 80 || spawns.stream().filter(n -> n != null && !n.isDead()).count() >= 2) {\n\t\t\t\tattack = AbyssalSireAttack.POISON;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.SPAWN;\n\t\t\t}\n\t\t} else if (phase == AbyssalSirePhase.MELEE_COMBAT) {\n\t\t\tif (randomChanceOfAttack <= 50) {\n\t\t\t\tattack = AbyssalSireAttack.SWIPE;\n\t\t\t} else if (randomChanceOfAttack <= 85) {\n\t\t\t\tattack = AbyssalSireAttack.TENDRIL_SWIPE;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.DOUBLE_TENDRIL_SWIPE;\n\t\t\t}\n\t\t} else if (phase == AbyssalSirePhase.MAGIC_COMBAT) {\n\t\t\tif (explosionState == AbyssalSireExplosionState.NONE && attackerAsNpc.getCurrentHitPoints() <= 139) {\n\t\t\t\tattack = AbyssalSireAttack.PORTAL;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.POISON;\n\t\t\t}\n\t\t}\n\t\treturn ServerConstants.MELEE_ICON;\n\t}", "public L2Attackable(final int objectId, final L2NpcTemplate template)\n\t{\n\t\tsuper(objectId, template);\n\t\tgetKnownList(); // init knownlist\n\t\tmustGiveExpSp = true;\n\t}", "public static Image attackPoint()\n\t{\n\t\treturn attackPoint;\n\t}", "public Card getActivePlayerTwoCard()\n\t{\n\t\treturn activePlayerTwoCard;\n\t}", "private int createAbilityIndex() {\n if (this.getPokemonInfo().numAbilities() == 2) {\n return RandomUtils.getRandomInt(2);\n } else {\n return RandomUtils.getRandomInt(3);\n }\n }", "public Creature getAiOwner() {\n return _aiOwner;\n }", "public Object ai() {\n try {\n return this.ad.newInstance();\n } catch (IllegalAccessException | InstantiationException e) {\n throw new RuntimeException();\n }\n }", "public EntityCroco spawnBabyAnimal(EntityAgeable par1EntityAgeable)\n {\n return new EntityCroco(this.worldObj);\n }", "public AIObject getAIObject(FreeColGameObject fcgo) {\n return getAIObject(fcgo.getId());\n }", "public static void main(String args[]) throws IOException {\n Character Jill = new Character(\"red\", \"brown:\", \"female\", \"green\", \"Jill\");\n Character Sean = new Character(\"red\", \"green\", \"male\", \"green\", \"Sean\");\n Character Becky = new Character(\"brown\", \"brown\", \"female\", \"blue\", \"Becky\");\n Character Tom = new Character(\"brown\", \"green\", \"male\", \"blue\", \"Tom\");\n Character Caroline = new Character(\"blonde\", \"blue\", \"female\", \"blue\", \"Caroline\");\n Character Curtis = new Character(\"brown\", \"blue\", \"male\", \"red\", \"Curtis\");\n Character Steph = new Character(\"brown\", \"brown\", \"female\", \"red\", \"Steph\");\n\n //Add characters to ArrayList\n Roster people = new Roster();\n people.addChar(Jill);\n people.addChar(Sean);\n people.addChar(Becky);\n people.addChar(Tom);\n people.addChar(Caroline);\n people.addChar(Curtis);\n people.addChar(Steph);\n\n //create AI Object and copy Roster\n Roster possChars = new Roster();\n possChars.addChar(Jill);\n possChars.addChar(Sean);\n possChars.addChar(Becky);\n possChars.addChar(Tom);\n possChars.addChar(Caroline);\n possChars.addChar(Curtis);\n possChars.addChar(Steph);\n AI aibot = new AI(possChars);\n\n //create gameplay loop\n boolean noWinner = true;\n\n //create turn loop\n boolean turn = true;\n\n //Create Random number from array for user and computer\n Random rand = new Random();\n int computerNum = rand.nextInt(people.getSize());\n int userNum = rand.nextInt(people.getSize());\n\n //Set random number from array to specific character\n //call to isPlayer and isComputer from Character class to\n // set boolean switch to true to indicate if it belongs to user or computer\n people.getChar(computerNum).setAsComputer();\n people.getChar(userNum).setAsPlayer();\n\n //These values are for the buffered reader input for AI response\n String q = \"\";\n int answer = 2;\n\n\n //Create Menu and character names\n System.out.println(\"Welcome to Guess Who!\");\n System.out.println(\"You will be assigned a random character from the list of created characters\");\n System.out.println(\"You can either guess who the computer has, or ask a question\");\n System.out.println(\"Once you have either made a guess or asked a question, you turn ends and the computer will go\");\n System.out.println(\"Your goal is to guess who the computer has before it guesses your character first!\");\n System.out.println(\"Good Luck!\\n\");\n System.out.println(\"\\nYour character is: \" + people.getChar(userNum).toString());\n\n //System.out.println(\"//test this is the computer's character//\");\n //System.out.println(people.getChar(computerNum).toString());\n\n\n while (noWinner) {\n printMenu();\n do {\n String s = in.readLine().trim();\n int i = Integer.parseInt(s);\n\n switch (i) {\n //Ask question\n case 1:\n displayQuestions();\n\n String t = in.readLine().trim();\n int j = Integer.parseInt(t);\n\n\n switch (j) {\n case 1:\n //male?\n if (people.getChar(computerNum).isGender(\"male\")) {\n System.out.println(\"Yes!\");\n } else {\n System.out.println(\"No\");\n }\n turn = false;\n break;\n case 2:\n //female?\n if (people.getChar(computerNum).isGender(\"female\")) {\n System.out.println(\"Yes!\");\n } else {\n System.out.println(\"No\");\n }\n turn = false;\n break;\n case 3:\n //red hair?\n if (people.getChar(computerNum).isHair(\"brown\")) {\n System.out.println(\"Yes!\");\n } else {\n System.out.println(\"No\");\n }\n turn = false;\n break;\n case 4:\n //brown hair?\n if (people.getChar(computerNum).isHair(\"red\")) {\n System.out.println(\"Yes!\");\n } else {\n System.out.println(\"No\");\n }\n turn = false;\n break;\n case 5:\n //blonde hair?\n if (people.getChar(computerNum).isHair(\"blonde\")) {\n System.out.println(\"Yes!\");\n } else {\n System.out.println(\"No\");\n }\n turn = false;\n break;\n case 6:\n //brown eyes?\n if (people.getChar(computerNum).isEye(\"green\")) {\n System.out.println(\"Yes!\");\n } else {\n System.out.println(\"No\");\n }\n turn = false;\n break;\n case 7:\n //green eyes?\n if (people.getChar(computerNum).isEye(\"blue\")) {\n System.out.println(\"Yes!\");\n } else {\n System.out.println(\"No\");\n }\n turn = false;\n break;\n case 8:\n //blue eyes?\n if (people.getChar(computerNum).isEye(\"brown\")) {\n System.out.println(\"Yes!\");\n } else {\n System.out.println(\"No\");\n }\n turn = false;\n break;\n case 9:\n //green shirt?\n if (people.getChar(computerNum).isShirt(\"green\")) {\n System.out.println(\"Yes!\");\n\n } else {\n System.out.println(\"No\");\n }\n turn = false;\n break;\n case 10:\n //blue shirt?\n if (people.getChar(computerNum).isShirt(\"blue\")) {\n System.out.println(\"Yes!\");\n } else {\n System.out.println(\"No\");\n }\n\n turn = false;\n break;\n case 11:\n //red shirt?\n if (people.getChar(computerNum).isShirt(\"red\")) {\n\n System.out.println(\"Yes!\");\n } else {\n System.out.println(\"No\");\n }\n turn = false;\n break;\n default:System.out.println(\"Please enter a valid number\");\n }\n\n break;\n //Guess computer's character\n case 2:\n System.out.println(\"Input the character that you believe the AI has\\n First letter capitalized Please :)\");\n String guess = in.readLine().trim();\n if (people.getChar(computerNum).isName(guess)) {\n System.out.println(\"Congratulations! You guessed correctly!\\n You win!!!\\nThanks for Playing :D\");\n noWinner = false;\n } else {\n System.out.println(\"No, try again.\");\n }\n break;\n //See list of playable characters\n\n case 3:\n System.out.println(people.toString());\n\n break;\n //see ALL characters' attributes\n case 4:\n System.out.println(people.getAttributes());\n break;\n //See User's character and their attributes\n case 5:\n System.out.println(people.getMyCharacter(userNum));\n break;\n //Quit game\n case 6:\n System.out.println(\"Goodbye!\");\n turn = false;\n noWinner = false;\n break;\n default:System.out.println(\"Please enter a valid number\");\n }\n } while (turn);\n\n //AI takes turn\n //check for lowest h value in Hashmap to ask question\n //If yes, remove appropriate characters from aiRoster\n //Delete question from Hashmap\n //get traits from remaining characters and update question values\n //If no, do same, but with opposite answers\n if (turn == false) {\n\n if (aibot.aiRoster.getSize() == 1) {\n System.out.println(\"Your character is \" + aibot.aiRoster.getChar(0));\n noWinner = false;\n }\n else {\n String quest = aibot.bestQuestion();\n System.out.println(\"Is \" + quest + \" true?\" + \"\\nType '1' for yes, '0' for no, and 2 to see your Character's attributes\");\n\n do {\n q = in.readLine().trim();\n answer = Integer.parseInt(q);\n\n\n if (answer == 1) {\n aibot.activateBrain(1, quest);\n turn = true;\n } else if (answer == 0) {\n aibot.activateBrain(0, quest);\n turn = true;\n } else if(answer == 2){\n System.out.println(people.getMyCharacter(userNum));\n }\n else {\n System.out.println(\"Please enter a '1' or '0' to answer\");\n }\n } while(turn == false);\n\n }\n\n }\n }\n }", "public abstract boolean attack(KillableItem i);", "public abstract void attack(Vector2 spawnPos, Vector2 target);", "public interface Attacks {\n // gives a character object ability (behavior) to attack with a weapon\n // and deal damage to opponent's health\n String attack();\n int attackDamage();\n}", "public static Character createCharacter () {\n\n System.out.println(\"Enter the name of your character : \");\n Scanner sc = new Scanner(System.in);\n String nameCharacter = sc.next();\n\n System.out.println(\"Enter the healpoint of your character : \");\n Scanner scan = new Scanner(System.in);\n String healPointCharacter = scan.next();\n int hpCharacter = Integer.parseInt(healPointCharacter);\n\n System.out.println(\"Enter the power of your character : \");\n Scanner sca = new Scanner(System.in);\n String powerCharacter = sca.next();\n int pcCharacter = Integer.parseInt(powerCharacter);\n\n System.out.println(\"Enter the initiative of your character : \");\n Scanner scann = new Scanner(System.in);\n String initiativeCharacter = scann.next();\n int iniCharacter = Integer.parseInt(initiativeCharacter);\n\n Character characterPlayer = new Character(nameCharacter, pcCharacter, hpCharacter, iniCharacter);\n System.out.println(\"Your character has been created with success!\");\n System.out.println(characterPlayer);\n\n return characterPlayer;\n }", "@Override\n\tpublic int attack( ){\n\t\treturn enemy.attack();\n\t}", "public abstract boolean attack(Enemy w);", "protected void attack() {\n int[] dir = orientationToArray(orientation);\n int newX = positionX + dir[0];\n int newY = positionY + dir[1];\n Skill currentSkill = grid.getPlayer().getBattleSkill();\n if (\n currentSkill != null\n && grid.valid(newX, newY)\n && grid.getPlayer().hasEnoughMp(currentSkill.getCost())\n && System.currentTimeMillis() - currentSkill.getLastUsed() > currentSkill.getCooldown()\n ) {\n Token token = new SkillToken(\n currentSkill.getImage(),\n newX,\n newY,\n grid,\n dir[0],\n dir[1],\n currentSkill\n );\n token.orientation = orientation;\n grid.addTokenAt(token, newX, newY);\n currentSkill.use(System.currentTimeMillis());\n new Thread(token).start();\n }\n grid.repaint();\n }", "public boolean isAiTurn() {\n return whosTurn() == aiPlayer;\n }", "public abstract void use(PlayerCharacter character);", "public interface AttackStrategy {\n public double attack(Player player);\n\n}", "private void createHumanPlayer() {\n humanPlayer = new Player(\"USER\");\n players[0] = humanPlayer;\n }", "public static AI newIntruderAI(IntruderAI.IntruderAIType intruderAIType, Intruder intruder, ArrayList<Area> areas)\n {\n agent = intruder;\n\n switch(intruderAIType) //New AIs should always take guard and optionally internalAreas\n {\n case STUPID:\n return new Stupid(intruder);\n case SWARM_HEURISTIC:\n coefficients = new float[]{\n /* coefficient for sound: */ 0, //SOUND REALLY FUCKS UP GUARDS\n /* coefficient for amount of visible guards: */ -150f,\n /* coefficient for amount of visible intruders: */ -17.0f,\n /* coefficient for map border: */ -1.0f,\n /* coefficient for shade: */ 0,\n /* coefficient for structures: */ 13f,\n /* coefficient for target: */ 13f\n };\n return new HeuristicIntruder(agent, coefficients);\n case A_STAR:\n return new AStarIntruderAI(intruder);\n default:\n return new Stupid(intruder);\n\n //TODO: catch aitype not supported\n }\n }", "@Override\n public boolean isAiOn()\n {\n return aiIsOn;\n }", "public int currentPlayerReachable(Player o1, Player o2){\n int range = o2.getNumberMoveRemaining()+o2.getBombRange();\n ArrayList<Cell> reachableCells = new ArrayList<Cell>();\n reachableCells = getReacheableCellsInRange(o2.getCell(), range);\n // the current player is not safe from the enemy considered\n if(reachableCells.contains(o1.getCell())){\n return -1;\n }\n // the current player is safe from the enemy considered\n else {\n return 1;\n }\n }", "private void getAI(){\n\n }", "CharacterStatistic getBasedOn();", "public static void spawnEnemy(){\n RNG.D100();\n if(PlayerStats.LVL <= 2){\n if(RNG.num <= 90){\n enemy = \"imp\";\n }else{\n enemy = \"IMP LORD\";\n }\n }else if(PlayerStats.LVL > 2 && PlayerStats.LVL <= 3){\n if(RNG.num <= 20){\n enemy = \"imp\";\n }else if(RNG.num > 20 && RNG.num <= 90){\n enemy = \"toadman\";\n }else{\n enemy = \"IMP LORD\";\n }\n }else if(PlayerStats.LVL > 3 && PlayerStats.LVL <= 5){\n if(RNG.num <= 10){\n enemy = \"toadman\";\n }else if(RNG.num > 10 && RNG.num <= 90){\n enemy = \"giant spider\";\n }else{\n enemy = \"BROODMOTHER\";\n }\n }else if (PlayerStats.LVL > 5 && PlayerStats.LVL <= 8){\n if(RNG.num <= 30){\n enemy = \"goblin sorceror\";\n }else if(RNG.num > 30 && RNG.num <= 60){\n enemy = \"goblin warrior\";\n }else if(RNG.num >60 && RNG.num <= 90){\n enemy = \"goblin archer\";\n }else if(RNG.num > 90 && RNG.num <= 100){\n enemy = \"GOBLIN CHIEFTAN\"; \n }\n } \n }", "public synchronized String computeMove() {\n if (game == null) {\n System.err.println(\"CODE ERROR: AI is not attached to a game.\");\n return \"0,0\";\n }\n\n char[] board = (char[]) game.getStateAsObject();\n\n //Choose a smart move if that AI is set to \"Smart\" or if the random value equals 2\n if (aiType == 1) {\n if(useHeat && ((int) (Math.random() * heat)) == 2){\n return \"\" + getRandomMove(board);\n }\n else{\n return \"\" + getSmartMove(board);\n }\n } else {\n return \"\" + getRandomMove(board);\n }\n }", "@Override\r\n\tpublic EnemySprites getEnemy(int level) {\r\n \tint enemyCount = 3;\r\n \tRandom rand = new Random();\r\n \tint enemyNum = rand.nextInt(enemyCount);\r\n \tswitch(enemyNum){\r\n \tcase 0:\r\n \t\t//return new goblin(level);\r\n \t\tbreak;\r\n \tcase 1:\r\n \t\t//return new kobold(level);\r\n \t\tbreak;\r\n \tcase 2:\r\n \t\t//return new Bandit(level);\r\n \t\tbreak;\r\n \tdefault:\r\n \t\treturn null; \t\t\r\n \t}\r\n \treturn null;\r\n }", "public void attack()\n {\n getWorld().addObject(new RifleBullet(player.getX(), player.getY(), 1, 6, true), getX(), getY()); \n }" ]
[ "0.6729918", "0.53751826", "0.52467126", "0.5245199", "0.5175181", "0.5162183", "0.513882", "0.511311", "0.50704736", "0.50466967", "0.5022408", "0.5016767", "0.50057375", "0.49423742", "0.49373397", "0.49278", "0.48950127", "0.4886383", "0.48793748", "0.48514676", "0.4840854", "0.4823286", "0.4806952", "0.4801882", "0.47947276", "0.47900566", "0.47864985", "0.47728774", "0.47715813", "0.47707182", "0.47584486", "0.47537455", "0.475366", "0.47448444", "0.47313416", "0.47303888", "0.47298416", "0.47201908", "0.47091538", "0.46908483", "0.4668972", "0.46673983", "0.46565738", "0.4646476", "0.4632643", "0.46193576", "0.46104774", "0.46103343", "0.46090338", "0.46017307", "0.45987698", "0.45872706", "0.45804104", "0.4577046", "0.4576608", "0.45759648", "0.45710436", "0.45696217", "0.45625922", "0.4559851", "0.4559135", "0.45508063", "0.45483574", "0.45465857", "0.45389265", "0.45050982", "0.4497421", "0.44953552", "0.44942948", "0.4489101", "0.4485832", "0.44814286", "0.4480145", "0.44745418", "0.44680113", "0.44590768", "0.44572306", "0.4456281", "0.44554606", "0.44546786", "0.44485754", "0.4445597", "0.44448534", "0.44432145", "0.44401997", "0.44365084", "0.4427603", "0.44265705", "0.44105938", "0.4407088", "0.44063038", "0.43939233", "0.43915263", "0.43891022", "0.43847218", "0.43714547", "0.43660176", "0.43644154", "0.43583924", "0.43577546" ]
0.74776626
0
get condition to hate, actually isAggressive() is checked by monster and karma by guards in motheds that overwrite this one. Not used.
@Deprecated public boolean getCondition2(final L2Character target) { if (target instanceof L2FolkInstance || target instanceof L2DoorInstance) { return false; } if (target.isAlikeDead() || !isInsideRadius(target, getAggroRange(), false, false) || Math.abs(getZ() - target.getZ()) > 100) { return false; } return !target.isInvul(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void checkIfHungry(){\r\n\t\tif (myRC.getEnergonLevel() * 2.5 < myRC.getMaxEnergonLevel()) {\r\n\t\t\tmission = Mission.HUNGRY;\r\n\t\t}\r\n\t}", "int getMinigameDefenseChancesLeft();", "@Override\r\n\tpublic boolean isAggressive() {\n\t\treturn true;\r\n\t}", "public ASTNode getCondition() {\n \treturn (ASTNode)getChildNode(ChooseRulePlugin.GUARD_NAME);\n }", "double getCritChance();", "@Override\r\n\t\tpublic int threat() {\n\t\t\treturn state.getThreat();\r\n\t\t}", "private void calculateCrit(Monster target, MonsterParts part, Weapon weapon, double motionValue) throws InvalidPartException {\n \n if (target.isWeakness(part)) {\n if (Math.random() < (Math.abs((weapon.getAffinity() + weaknessExploit)/100.0)) && (weapon.getAffinity() + weaknessExploit) < 0) {\n critDamage -= weapon.getAttack()/weapon.getInflation() * 0.25 * weapon.getRawSharpness() * target.getPartMultiplierRaw(part, weapon) * motionValue;\n }\n if (Math.random() < ((weapon.getAffinity() + weaknessExploit)/100.0) && (weapon.getAffinity() + weaknessExploit) > 0) {\n critDamage += weapon.getAttack()/weapon.getInflation() * (0.25 + critBoost/100.0) * weapon.getRawSharpness() *target.getPartMultiplierRaw(part, weapon) * motionValue;\n if (criticalElement) {\n elementalCritDamage += weapon.getElementStatusDmg()/10 * 0.25 * weapon.getElementalSharpness() * target.getPartMultiplierElemental(part, weapon);\n }\n }\n } else {\n if (Math.random() < (Math.abs(weapon.getAffinity()/100.0)) && weapon.getAffinity() < 0) {\n critDamage -= weapon.getAttack()/weapon.getInflation() * 0.25 * weapon.getRawSharpness() * target.getPartMultiplierRaw(part, weapon) * motionValue;\n }\n if (Math.random() < (weapon.getAffinity()/100.0) && weapon.getAffinity() > 0) {\n critDamage += weapon.getAttack()/weapon.getInflation() * (0.25 + critBoost/100.0) * weapon.getRawSharpness() * target.getPartMultiplierRaw(part, weapon) * motionValue;\n if (criticalElement) {\n elementalCritDamage += weapon.getElementStatusDmg()/10 * 0.25 * weapon.getElementalSharpness() * target.getPartMultiplierElemental(part, weapon);\n }\n }\n }\n\n }", "boolean getGodPower();", "public Condition degrade() {\r\n Condition degraded;\r\n switch(this) {\r\n case MINT:\r\n degraded = NEAR_MINT;\r\n break;\r\n case NEAR_MINT:\r\n degraded = VERY_GOOD;\r\n break;\r\n case VERY_GOOD:\r\n degraded = GOOD;\r\n break;\r\n case GOOD:\r\n degraded = FAIR;\r\n break;\r\n case FAIR:\r\n degraded = POOR;\r\n break;\r\n default:\r\n case POOR:\r\n degraded = BROKEN;\r\n }\r\n return degraded;\r\n }", "private void checkLoosePLayer(){\n if (hero.getHp()<=0){\n loose();\n }\n\n }", "@Override\n\tpublic int getMetricInternal() {\n// Util.runToAddressNoLimit(0, 0, 0x3d702, 0x3e77f);\n// missed_ = curGb.readMemory(curGb.pokemon.fightAttackMissedAddress);\n// System.out.println(\"missed: \" + missed_);\n\n\t\tEflUtil.runToAddressNoLimit(0, 0, curGb.pokemon.fightBattleCommand0a);\n\t\tint crit = curGb.readMemory(curGb.pokemon.fightCriticalHitAddress);\n\t\tint missed = curGb.readMemory(curGb.pokemon.fightAttackMissedAddress);\n//\t\tSystem.out.println(\"EflCheckMoveDamage crit: \" + crit + \" missed: \" + missed);\n\t\tif (missed != 0 || criticalHit != (crit != 0))\n\t\t return Integer.MIN_VALUE;\n\t\tif (thrashAdditionalTurns > 0 && curGb.readMemory(curGb.pokemon.thrashNumTurnsAddress) < thrashAdditionalTurns) {\n\t\t\tSystem.out.println(\"caught bad thrash \"+ curGb.readMemory(curGb.pokemon.thrashNumTurnsAddress));\n return Integer.MIN_VALUE;\n\t\t}\n\t\tif (PokemonUtil.isGen2()) {\n\t\t\tint effectMissed = curGb.readMemory(curGb.pokemon.fightEffectMissedAddress);\n\t\t\tif (this.effectMiss != (effectMissed != 0))\n\t\t\t return Integer.MIN_VALUE;\n\t\t}\n\t\tint dmg = Util.getMemoryWordBE(curGb.pokemon.fightCurDamageAddress);\n// System.out.println(\"EflCheckMoveDamage dmg: \" + dmg);\n\t\tif (dmg < minDamage || dmg > maxDamage)\n return Integer.MIN_VALUE;\n//\t\t\tSystem.out.println(crit+\" \"+missed+\" \"+effectMissed+\" \"+dmg);\n//\t\tSystem.out.println(\"atk: \"+atk+\", def: \"+def+\", pow: \"+pow+\", lvl: \"+lvl);\n//\t\tSystem.out.println(\"max damage: \"+maxdmg+\", dmg: \"+dmg);\n\t\treturn negateOutputDamage ? -dmg : dmg;\n\t}", "boolean hasDamage();", "boolean hasDamage();", "boolean hasDamage();", "boolean hasDamage();", "boolean hasDamage();", "public static void damageStep () {\r\n // rough plan:\r\n // #1: flip defending monster, if face down -> see flipMonster(...);\r\n // #2: Ask CPU and player for possible effect negation! (For an attack negation it is too late!) -> see below in this method\r\n // #3: calculate damage, kill monsters, if needed\r\n // (consider also banishing and immunity, also copied passive effect of (Holy) Lance)\r\n // -> see makeDamageCalculation(...);\r\n // #4: decrease life points, if needed -> see isDealingBattleDamageAndContinuingGame(...);\r\n // #5: consider passive (also copied) trap monster effects -> see possibleSuicideEffect(...);\r\n // #6: display Win/Lose dialog and end match, if needed -> see Game.over(...);\r\n // #7: finally end the attack (consider the effects that happen afterwards), thus allowing the next attack -> endDamageStep(...);\r\n \r\n // about #1:\r\n if (Game.ActiveGuardingMonster.isFaceDown) {flipMonster(Game.ActiveGuardingMonster);}\r\n // about #2:\r\n if (Game.ActiveAttackingMonster.canBeNegated() || Game.ActiveGuardingMonster.canBeNegated()) {\r\n AIinterrupts.cpuIsUsingEffectNegateDuringBattlePhase(); // ask CPU to negate effects first\r\n // ask player to negate effect here\r\n boolean isCanceling = false;\r\n boolean hasEffectNegateHandTrap = Hand.lookForEffectNegateOnHand(true);\r\n boolean hasEffectNegateOnField = Hand.lookForEffectNegateOnField(true);\r\n if (hasEffectNegateHandTrap || hasEffectNegateOnField) {\r\n if (hasEffectNegateHandTrap && !hasEffectNegateOnField) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, true);\r\n }\r\n else if (!hasEffectNegateHandTrap && hasEffectNegateOnField) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, false);\r\n }\r\n else {\r\n int intDialogResult = YuGiOhJi.multipleChoiceDialog(\"Do you want to negate effects on the field?\", \"You can negate passive effects.\", new String[]{\"yes, by discarding Neutraliser\", \"yes, by paying the cost worth 1 card\", \"no (default)\"}, \"no (default)\");\r\n if (intDialogResult==0) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, true);\r\n }\r\n else if (intDialogResult==1) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, false);\r\n }\r\n }\r\n }\r\n if (!isCanceling) {\r\n makeDamageCalculation(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster); // whole rest of battle\r\n }\r\n }\r\n else {\r\n makeDamageCalculation(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster); // whole rest of battle\r\n }\r\n \r\n }", "float shouldAggroOnHit(IGeneticMob geneticMob, EntityLiving attacker);", "private int heavyAttack() {\n return attack(6, 2);\n }", "static boolean getMauled(){\n\t\t\tif (Person.player.inventory.contains(Item.repellent)) //if you have the goose repellent...\n\t\t\t\treturn (MainFile.getRandomNumber(240) == 12); //drastically lowers your chance of being mauled.\n\t\t\treturn (MainFile.getRandomNumber(20) == 12);//generates a random number for if you don't have it, and if it's 12 you get mauled\n\t\t}", "boolean getHealthy();", "public boolean isOnFight();", "public int throwRandomStrategy(int[] fighter) {\n Random rnd = new Random();\n int defenseLimit = 3;\n//If little life left, he defends 50% of the blows\n if (fighter[LIFE] < 2) {\n defenseLimit = 1;\n }\n int accio = rnd.nextInt(10);\n if ((accio >= 0) && (accio < defenseLimit)) {\n return Combat.ATTACK;\n } else if ((defenseLimit >= 3) && (accio < 6)) {\n return Combat.DEFENSE;\n } else if ((accio >= 6) && (accio < 8)) {\n return Combat.CHEATING;\n } else {\n return Combat.MANEUVER;\n }\n }", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "private static void decisionWhenAttacking() {\n\t\tif (isNewAttackState()) {\n\t\t\tchangeStateTo(STATE_ATTACK_PENDING);\n\n\t\t\t// We will try to define place for our army where to attack. It\n\t\t\t// probably will be center around a crucial building like Command\n\t\t\t// Center. But what we really need is the point where to go, not the\n\t\t\t// unit. As long as the point is defined we can attack the enemy.\n\n\t\t\t// If we don't have defined point where to attack it means we\n\t\t\t// haven't yet decided where to go. So it's the war's very start.\n\t\t\t// Define this assault point now. It would be reasonable to relate\n\t\t\t// it to a particular unit.\n\t\t\t// if (!isPointWhereToAttackDefined()) {\n\t\t\tStrategyManager.defineInitialAttackTarget();\n\t\t\t// }\n\t\t}\n\n\t\t// Attack is pending, it's quite \"regular\" situation.\n\t\tif (isGlobalAttackInProgress()) {\n\n\t\t\t// Now we surely have defined our point where to attack, but it can\n\t\t\t// be so, that the unit which was the target has been destroyed\n\t\t\t// (e.g. just a second ago), so we're standing in the middle of\n\t\t\t// wasteland.\n\t\t\t// In this case define next target.\n\t\t\t// if (!isSomethingToAttackDefined()) {\n\t\t\tdefineNextTarget();\n\t\t\t// }\n\n\t\t\t// Check again if continue attack or to retreat.\n\t\t\tboolean shouldAttack = decideIfWeAreReadyToAttack();\n\t\t\tif (!shouldAttack) {\n\t\t\t\tretreatsCounter++;\n\t\t\t\tchangeStateTo(STATE_RETREAT);\n\t\t\t}\n\t\t}\n\n\t\t// If we should retreat... fly you fools!\n\t\tif (isRetreatNecessary()) {\n\t\t\tretreat();\n\t\t}\n\t}", "boolean hasDefense();", "boolean hasDefense();", "boolean hasDefense();", "boolean hasDefense();", "boolean hasDefense();", "boolean hasDefense();", "public boolean getStatus() {\n return (rnd.nextInt(obstructionChanceBound) <= obstructionChance);\n }", "public Object getCondition();", "public boolean getDamage(){\n\t\tdie();\n\t\treturn false;\n\t}", "public Optimizer getOptimizedCriteria() {\r\n\r\n\t\tLog.d(\"Criteria\", \"Inside getOC:\" + isIntelligenceOverridden);\r\n\r\n\t\tif (!isIntelligenceOverridden) {\r\n\r\n\t\t\t/* BATTERY LEVEL - \"HIGH\" */\r\n\t\t\tif (batteryLevel > Constants.BATTERY_LEVEL.HIGH) {\r\n\t\t\t\tLog.d(\"Test\", \"Entered High\");\r\n\t\t\t\toptimizer.setFrequency(Constants.FREQUENCY_LEVEL.HIGH);\r\n\t\t\t\toptimizer.setPriority(Constants.PRIORITY_LEVEL.HIGH);\r\n\t\t\t}\r\n\r\n\t\t\t/* BATTERY LEVEL - \"MEDIUM\" */\r\n\t\t\telse if (batteryLevel > Constants.BATTERY_LEVEL.MEDIUM\r\n\t\t\t\t\t&& batteryLevel <= Constants.BATTERY_LEVEL.HIGH) {\r\n\t\t\t\tLog.d(\"Criteria\", \"Entered Medium\");\r\n\t\t\t\toptimizer.setFrequency(Constants.FREQUENCY_LEVEL.MEDIUM);\r\n\t\t\t\toptimizer.setPriority(Constants.PRIORITY_LEVEL.MEDIUM);\r\n\t\t\t}\r\n\r\n\t\t\t/* BATTERY LEVEL - \"LOW\" */\r\n\t\t\telse if (batteryLevel <= Constants.BATTERY_LEVEL.MEDIUM) {\r\n\t\t\t\tLog.d(\"Criteria\", \"Checking Moderate Mode\");\r\n\t\t\t\tmModerateMode();\r\n\t\t\t}\r\n\t\t\tLog.d(\"Criteria\", \"Returning Op obj\");\r\n\t\t\treturn optimizer;\r\n\t\t}\r\n\r\n\t\tLog.d(\"Criteria\", \"Then continuing\");\r\n\t\tswitch (userScheme) {\r\n\t\tcase \"moderate\":\r\n\t\t\tLog.d(\"Test\", \"Entered Moderate\");\r\n\t\t\tmModerateMode();\r\n\t\t\tbreak;\r\n\t\tcase \"lazy\":\r\n\t\t\tLog.d(\"Test\", \"Lazy\");\r\n\t\t\tmLazyMode();\r\n\t\t\tbreak;\r\n\t\tdefault:\r\n\t\t\tmModerateMode();\r\n\t\t\tbreak;\r\n\t\t}\r\n\t\treturn optimizer;\r\n\t}", "condition getConditionAllocution();", "private boolean checkGreedyIronCurtain() {\r\n return (myself.health < 30 || enTotal.get(0) >= 8 || opponent.isIronCurtainActive || this.myTotal.get(0) < this.enTotal.get(0));\r\n }", "public boolean hitOrStand(){\r\n\t\treturn hitOrStand;\r\n\t}", "public static boolean calcHitMiss(L2Character attacker, L2Character target)\n\t{\n\t\tdouble chance = 800 + 20 * (attacker.getAccuracy() - target.getEvasionRate(attacker));\n\n\t\t//if (attacker instanceof L2PcInstance && target instanceof L2PcInstance)\n\t\t//\tLog.info(\"P: \" + attacker.getAccuracy() + \" \" + target.getEvasionRate(attacker) + \": \" + chance);\n\n\t\t// Get additional bonus from the conditions when you are attacking\n\t\tchance *= hitConditionBonus.getConditionBonus(attacker, target);\n\n\t\tchance = Math.max(chance, 200);\n\t\tchance = Math.min(chance, 980);\n\n\t\tif (attacker instanceof L2PcInstance)\n\t\t{\n\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\tif (player.getExpertiseWeaponPenalty() != 0)\n\t\t\t{\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\treturn chance < Rnd.get(1000);\n\t}", "double getMissChance();", "public int fight() {\r\n\t\treturn -this.randomObject.nextInt(50);\r\n\t}", "private boolean shouldBecomeCombatEngineer() {\r\n\t\tdouble machineUnitsCount = this.getNumberOfMachineUnits();\r\n\t\tdouble combatEngineers = this.informationStorage.getWorkerConfig().getTotalCombatEngineerCount();\r\n\r\n\t\treturn combatEngineers / machineUnitsCount <= this.combatEngineerTriggerPercentageEnroll;\r\n\t}", "@Override\n\tpublic boolean isHungry() {\n\t\treturn false;\n\t}", "@Override\r\n\tpublic int attack() {\r\n\t\treturn rnd.nextInt(MAX_MONSTER_ATTACK_DAMAGE);\r\n\t}", "private boolean checkGreedyWinRate() {\r\n return myTotal.get(0) > enTotal.get(0)+2 && (myself.health > 50 || myself.health > opponent.health);\r\n }", "boolean canCrit();", "public int attack(boolean weakness){\r\n\t\tint damage = 0;\r\n\t\t\r\n\t\tif (energy <= 0) {\r\n\t\t\tSystem.out.println(\"no energy to attack\");\r\n\t\t\tenergy = 0;\r\n\t\t}\r\n\t\telse {\r\n\t\t\tif (weakness == true) {\r\n\t\t\t\tenergy -= 2;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tenergy -= 1;\r\n\t\t\t}\r\n\t\t\texp += 1;\r\n\t\t\tdamage = 1;\r\n\t\t}\r\n\t\treturn damage;\r\n\t}", "AbilityDamage getAbilityDamage();", "public static boolean monsterDeathCheck(){\n if (currentMonster.currentHp <= 0){\n return true;\n }\n return false;\n }", "int getWinCondition();", "public int basicAttack() {\n\t\t// lots of logic\n\t\treturn 5;\n\t}", "protected abstract float _getGrowthChance();", "@Override\n public int getEngineCritHeat() {\n int engineCritHeat = 0;\n if (!isShutDown() && getEngine().isFusion()) {\n engineCritHeat += 5 * getHitCriticals(CriticalSlot.TYPE_SYSTEM, Mech.SYSTEM_ENGINE, Mech.LOC_CT);\n engineCritHeat += 5 * getHitCriticals(CriticalSlot.TYPE_SYSTEM, Mech.SYSTEM_ENGINE, Mech.LOC_LT);\n engineCritHeat += 5 * getHitCriticals(CriticalSlot.TYPE_SYSTEM, Mech.SYSTEM_ENGINE, Mech.LOC_RT);\n }\n return engineCritHeat;\n }", "int getDefense();", "int getDefense();", "int getDefense();", "int getDefense();", "int getDefense();", "int getDefense();", "protected boolean isMovementNoisy() {\n/* 1861 */ return (!this.abilities.flying && (!this.onGround || !isDiscrete()));\n/* */ }", "public static void makeDamageCalculation (SummonedMonster AttackingMonster, SummonedMonster GuardingMonster) {\r\n AttackingMonster.canStillAttackThisTurn = false; // Just in case this might be missed somewhere, erase its one attack per turn, because now there is no turning back.\r\n AttMonster.rememberPropertiesOfMonster(AttackingMonster);\r\n GuardMonster.rememberPropertiesOfMonster(GuardingMonster);\r\n // get the 2 relevant values for the attack calculation\r\n int relevantAttValue = AttackingMonster.att;\r\n int releventGuardingValue = GuardingMonster.relevantValue();\r\n // get some relevant properties of the involved monsters\r\n boolean attackingMonsterIndestructible = AttackingMonster.isIndestructibleByBattle();\r\n boolean attackingMonsterImmuneWhileWinning = AttackingMonster.isImmuneWhileWinning();\r\n boolean attackingMonsterImmune = AttackingMonster.isImmune();\r\n boolean attackingMonsterBanishes = AttackingMonster.isBanishingOpposingMonster(GuardingMonster);\r\n boolean attackingMonsterBanishesBoth = AttackingMonster.isBanishingBothMonsters(GuardingMonster);\r\n \r\n boolean guardingMonsterIndestructible = GuardingMonster.isIndestructibleByBattle();\r\n boolean guardingMonsterImmuneWhileWinning = GuardingMonster.isImmuneWhileWinning();\r\n boolean guardingMonsterImmune = GuardingMonster.isImmune();\r\n boolean guardingMonsterBanishes = GuardingMonster.isBanishingOpposingMonster(AttackingMonster);\r\n boolean guardingMonsterBanishesBoth = GuardingMonster.isBanishingBothMonsters(AttackingMonster);\r\n // let monsters clash here\r\n if (relevantAttValue == releventGuardingValue) {\r\n if (relevantAttValue==0) {\r\n YuGiOhJi.informationDialog(\"Nothing happens, because of zero attack.\", \"\");\r\n endAttack(false);\r\n }\r\n else {\r\n if (GuardingMonster.isInAttackMode) { // usually both monsters kill each other\r\n if (attackingMonsterBanishesBoth) {\r\n banishingDialogBanisher(AttackingMonster);\r\n getNthSummonedMonster(AttackingMonster.sumMonsterNumber, AttackingMonster.isPlayersMonster).banishMonster();\r\n if (!guardingMonsterImmuneWhileWinning && !guardingMonsterImmune) {\r\n banishingDialogBanisher(GuardingMonster);\r\n getNthSummonedMonster(GuardingMonster.sumMonsterNumber, GuardingMonster.isPlayersMonster).banishMonster();\r\n }\r\n else {\r\n getNthSummonedMonster(GuardingMonster.sumMonsterNumber, GuardingMonster.isPlayersMonster).killMonster();\r\n }\r\n }\r\n else if (guardingMonsterBanishesBoth) {\r\n banishingDialogBanisher(GuardingMonster);\r\n getNthSummonedMonster(GuardingMonster.sumMonsterNumber, GuardingMonster.isPlayersMonster).banishMonster();\r\n if (!attackingMonsterImmuneWhileWinning && !attackingMonsterImmune) {\r\n banishingDialogBanisher(AttackingMonster);\r\n getNthSummonedMonster(AttackingMonster.sumMonsterNumber, AttackingMonster.isPlayersMonster).banishMonster();\r\n }\r\n else {\r\n getNthSummonedMonster(AttackingMonster.sumMonsterNumber, AttackingMonster.isPlayersMonster).killMonster();\r\n }\r\n }\r\n else {\r\n if (!guardingMonsterIndestructible) {\r\n if (attackingMonsterBanishes && !guardingMonsterImmuneWhileWinning && !guardingMonsterImmune) {\r\n banishingDialogBigBanisher(GuardingMonster);\r\n getNthSummonedMonster(GuardingMonster.sumMonsterNumber, GuardingMonster.isPlayersMonster).banishMonster();\r\n }\r\n else {\r\n getNthSummonedMonster(GuardingMonster.sumMonsterNumber, GuardingMonster.isPlayersMonster).killMonster();\r\n }\r\n }\r\n if (!attackingMonsterIndestructible) {\r\n if (guardingMonsterBanishes && !attackingMonsterImmuneWhileWinning && !attackingMonsterImmune) {\r\n banishingDialogBigBanisher(AttackingMonster);\r\n getNthSummonedMonster(AttackingMonster.sumMonsterNumber, AttackingMonster.isPlayersMonster).banishMonster();\r\n }\r\n else {\r\n getNthSummonedMonster(AttackingMonster.sumMonsterNumber, AttackingMonster.isPlayersMonster).killMonster();\r\n }\r\n }\r\n }\r\n if (!guardingMonsterIndestructible && attackingMonsterIndestructible) {\r\n possibleSuicideEffect(false, false);\r\n }\r\n else if (guardingMonsterIndestructible && !attackingMonsterIndestructible) {\r\n possibleSuicideEffect(true, false); // suicide effect of attacking monster\r\n }\r\n else if (!guardingMonsterIndestructible && !attackingMonsterIndestructible) {\r\n possibleSuicideEffect(false, true); // double kill here\r\n }\r\n else { // if both are indestructible, none of them has a suicide effect\r\n endDamageStep(false); // here both survive\r\n }\r\n } // else nothing happens\r\n }\r\n }\r\n else if (relevantAttValue > releventGuardingValue) { // here the attacking monster usually kills the guarding one\r\n // look if attacking monster is either piercing by itself or copies Lance or Holy Lance\r\n boolean isEffectivelyPiercing = (AttackingMonster.hasPiercingDamageAbility() && !guardingMonsterImmune);\r\n boolean isContinuingGame = true;\r\n if (GuardingMonster.isInAttackMode || isEffectivelyPiercing) {\r\n isContinuingGame = isDealingBattleDamageAndContinuingGame(false, relevantAttValue-releventGuardingValue, GuardingMonster.isPlayersMonster);\r\n } // else no damage\r\n if (isContinuingGame) {\r\n if (guardingMonsterBanishesBoth) { // definitely banishes itself\r\n banishingDialogBanisher(GuardingMonster);\r\n getNthSummonedMonster(GuardingMonster.sumMonsterNumber, GuardingMonster.isPlayersMonster).banishMonster();\r\n if (!attackingMonsterImmuneWhileWinning && !attackingMonsterImmune) { // banishes opponent only, if it not immune against it\r\n banishingDialogBanisher(AttackingMonster);\r\n getNthSummonedMonster(AttackingMonster.sumMonsterNumber, AttackingMonster.isPlayersMonster).banishMonster();\r\n }\r\n }\r\n else if (!guardingMonsterIndestructible) {\r\n if (attackingMonsterBanishes && !guardingMonsterImmune) {\r\n banishingDialogBigBanisher(GuardingMonster);\r\n getNthSummonedMonster(GuardingMonster.sumMonsterNumber, GuardingMonster.isPlayersMonster).banishMonster();\r\n }\r\n else {\r\n getNthSummonedMonster(GuardingMonster.sumMonsterNumber, GuardingMonster.isPlayersMonster).killMonster();\r\n }\r\n possibleSuicideEffect(false, false);\r\n }\r\n else {\r\n endDamageStep(false);\r\n }\r\n }\r\n }\r\n else { // here: relevantAttValue < releventGuardingValue\r\n // rare case in which attacker gets the damage\r\n boolean isContinuingGame = isDealingBattleDamageAndContinuingGame(false, releventGuardingValue-relevantAttValue, AttackingMonster.isPlayersMonster);\r\n if (isContinuingGame) {\r\n if (GuardingMonster.isInAttackMode) {\r\n if (attackingMonsterBanishesBoth) {\r\n banishingDialogBanisher(AttackingMonster);\r\n getNthSummonedMonster(AttackingMonster.sumMonsterNumber, AttackingMonster.isPlayersMonster).banishMonster();\r\n if (!guardingMonsterImmuneWhileWinning && !guardingMonsterImmune) {\r\n banishingDialogBanisher(GuardingMonster);\r\n getNthSummonedMonster(GuardingMonster.sumMonsterNumber, GuardingMonster.isPlayersMonster).banishMonster();\r\n }\r\n }\r\n else if (!attackingMonsterIndestructible) {\r\n if (guardingMonsterBanishes && !attackingMonsterImmune) {\r\n banishingDialogBigBanisher(AttackingMonster);\r\n getNthSummonedMonster(AttackingMonster.sumMonsterNumber, AttackingMonster.isPlayersMonster).banishMonster();\r\n }\r\n else {\r\n getNthSummonedMonster(AttackingMonster.sumMonsterNumber, AttackingMonster.isPlayersMonster).killMonster();\r\n }\r\n }\r\n possibleSuicideEffect(true, false);\r\n }\r\n else {\r\n endDamageStep(false);\r\n }\r\n }\r\n }\r\n \r\n }", "public boolean isGoal() {\n return humming() = 0;\n }", "boolean hasMaxHP();", "boolean hasMaxHP();", "boolean hasMaxHP();", "boolean hasMaxHP();", "boolean hasMaxHP();", "boolean hasMaxHP();", "@Override\n\tpublic void decide() {\n\t\tif (this.isDead) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tif(this.age >= this.lifeSpan) {\n\t\t\t// DIE\n\t\t\tthis.environment.removeAgent(this.getPosX(), this.getPosY());\n\t\t\tthis.isDead = true;\n\n\t\t\t// Print if required\n\t\t\tif (this.appConfig.hasTrace()) {\n\t\t\t\tSystem.out.println(\"Agent;Death;Fish;\" + this.getPosX() + \";\" + this.getPosY());\n\t\t\t}\n\t\t\t\n\t\t\treturn;\n\t\t}\n\t\tthis.age++;\n\t\tthis.color = Color.GREEN;\n\t\tboolean canFuck = this.breedTime == 0;\n\n\t\tint[] coordinates = this.chooseCoordinates();\n\n\t\t// fish cannot move or fuck because there is no place to do so\n\t\tif (coordinates == null) {\n\t\t\tthis.breedTime = this.breedTime > 0 ? this.breedTime - 1 : this.breedTime;\n\t\t\treturn;\n\t\t}\n\n\t\tthis.environment.moveAgent(this, coordinates[0], coordinates[1]);\n\n\t\t// Time to fuck-zer\n\t\tif (canFuck) {\n\t\t\tthis.fuck(this.getPosX(), this.getPosY());\n\t\t}\n\t\t// Update breedtime in order to wait the holy fuck time\n\t\telse {\n\t\t\tthis.breedTime = this.breedTime > 0 ? this.breedTime - 1 : this.breedTime;\n\t\t}\n\t\tthis.posX = coordinates[0];\n\t\tthis.posY = coordinates[1];\n\t}", "Collection<String> getPossibleDefeatConditions();", "@Test\n\tpublic void testWarm_DetailedThenTechnologyAverageElseAbort_FallbackNotNeeded() {\n\t\tEmissionModule emissionModule = setUpScenario(EmissionsConfigGroup.DetailedVsAverageLookupBehavior.tryDetailedThenTechnologyAverageElseAbort);\n\n\t\tdouble travelTimeOnLink = 21; //sec. approx freeSpeed of link12 is : (200 m) / (9.72.. m/s) approx 20.57 s\n\t\tMap<Pollutant, Double> warmEmissions = emissionModule.getWarmEmissionAnalysisModule().checkVehicleInfoAndCalculateWarmEmissions(vehicleFull, link, travelTimeOnLink);\n\n\t\tdouble expectedValue = 30.34984742; // = 200m * 151.7492371 g/km\n\t\tAssert.assertEquals( expectedValue, warmEmissions.get(Pollutant.CO2_TOTAL ), MatsimTestUtils.EPSILON );\n\t}", "public boolean isGoal() {\n return hamming == 0;\n }", "boolean hasGemReward();", "private static int monsterDamageDealt(int monsterAttack, int playerDefense){\r\n int monsterDamageDealt;\r\n monsterDamageDealt = (monsterAttack - playerDefense);\r\n if(monsterDamageDealt < 0){\r\n monsterDamageDealt = 0;\r\n return monsterDamageDealt;\r\n }else{\r\n return monsterDamageDealt;\r\n }\r\n }", "private static boolean runAway(Critter foo){\n\t\tif(foo.moved) {\n\t\t\tfoo.energy = foo.getEnergy() - Params.walk_energy_cost;\n\t\t\tif (foo.getEnergy() <= 0) {\n\t\t\t\tfoo.isAlive=false;\n\t\t\t}\n\t\t\treturn false;\n\t\t} else {\n\t\t\tint dir = getRandomInt(8);\n\t\t\tif(canMove(foo, dir)) {\n\t\t\t\tfoo.walk(dir);\n\t\t\t\treturn true;\n\t\t\t}else{\n\t\t\t\tfoo.energy = foo.getEnergy() - Params.walk_energy_cost;\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t}", "boolean canFall();", "String getCondition();", "@java.lang.Override\n public int getMinigameDefenseChancesLeft() {\n return minigameDefenseChancesLeft_;\n }", "public int getAttack() { return this.attack; }", "public int getAtk()\r\n {\r\n return attack;\r\n }", "public void attack() {\n energy = 2;\n redBull = 0;\n gun = 0;\n target = 1;\n // if Player is in range take off a life.\n if (CharacterTask.ghostLocation == GameWindow.playerLocation) {\n playerLives = playerLives - 1;\n System.out.println(\"Player Lives: \" + playerLives);\n }\n }", "public OverallCondition getCondition() {\n return condition;\n }", "public double getAttack() {\n return attack;\n }", "public boolean isAlive(){\n if(this.hp <= 0){\n return false;\n }\n else{\n return true;\n }\n }", "public byte getGoodMaternal() {\n if (maternal >= 0)\n return maternal; //not missing\n //GT is missing, we try our best to return correct one\n //however there is no guarantee that only one ALT is specified\n //for a variant on MT\n if (chr.isMT()) {\n return (byte) (Math.min(1, alts.length));\n }\n //maternal genome does not have Y chromosome\n if (chr.isY()) {\n return (byte) -1;\n }\n /*chr=X or autosomal\n we try to return a correct one\n and make it work with getGoodPaternal(),i.e.\n getGoodPaternal() returns 1 by default,\n getGoodMaternal() returns 2 by default.\n */\n return (byte) (Math.min(2, alts.length));\n }", "public int seppuku(Monster monster) {\n double orginalAttackRating = getAttackRating();\n int damage = (int) Math.pow(getRotundness(), getKungFuSkill());\n setAttackRating(damage);\n setHp(1);\n int damageDone = attack(monster);\n setAttackRating(orginalAttackRating);\n return damageDone;\n }", "public String agileOrWaterfallDecider() {\n String decision = \"Agile.\";\n int x = 0;\n if (numberOfProgrammersOnCheckBox.isSelected())\n x += 1;\n if (needForAFixedCheckBox.isSelected())\n x += 1;\n if (doTeammateHaveExperienceCheckBox.isSelected())\n x += 1;\n if (stringentQualityControlRequirementsCheckBox.isSelected())\n x += 1;\n if (earlyIntegrationNOTDesirableCheckBox.isSelected())\n x += 1;\n if (earlyWorkingModelsNOTCheckBox.isSelected())\n x += 1;\n if (x > 3)\n decision = \"Waterfall.\";\n else if (x == 3) {\n decision = \"either one.\";\n }\n return decision;\n }", "public boolean eat() {\n\n if (this.hungerLevel > 0) {\n --this.hungerLevel; // Lower hunger after eating.\n return true;\n }\n return false;\n }", "public boolean canAttackWithItem() {\n/* 215 */ return false;\n/* */ }", "@java.lang.Override\n public int getMinigameDefenseChancesLeft() {\n return minigameDefenseChancesLeft_;\n }", "@Override\n public int doDamage() {\n if (difficulty <5)\n return damage;\n else \n return damage*2;\n }", "public void attack(Person victim)\r\n { \r\n int victimDef = 0;\r\n int hits = 0;\r\n String weaponName = \"bare hands\";\r\n \r\n victimDef = victim.getDef();\r\n \r\n //1/4 chance of critical or twice damage \r\n hits = (attack - victimDef) + (int)((Math.random()*(attack*.3))-(attack*.15));\r\n if (hits < 0)\r\n hits = 0;\r\n \r\n if (weapon!=null)\r\n weaponName = weapon.getName();\r\n \r\n //1/6 chance of missing when attacking\r\n if (!victim.equals(this))\r\n {\r\n if(Game.random(6)!=0)\r\n {\r\n //1/4 chance of double damage\r\n if (Game.random(8)!=0)\r\n say(\"I attack \" + victim.getName() + \" with my \" + weaponName);\r\n else \r\n {\r\n say(\"I inflict critical damage on \" + victim.getName() + \" with my \" + weaponName);\r\n hits += hits;\r\n }\r\n victim.suffer(hits);\r\n }\r\n else\r\n say(\"AHHH I attacked, but \" + victim.getName() + \" dodged my attack!\");\r\n }\r\n \r\n //if victim dies, hero's maxHealth increases\r\n if (victim.getHealth()<=0)\r\n {\r\n maxHealth += 10;\r\n attack += 2;\r\n defense += 1;\r\n }\r\n }", "private boolean canMageHarrasing(Creature m) {\n return (heroC.getX() - m.getX()) * (heroC.getX() - m.getX()) == (heroC.getY() - m.getY()) * (heroC.getY() - m.getY());\n }", "@Override\n protected int strengthViability(Creature c){\n int baseViability = super.strengthViability(c);\n if (Elements.elementDamageMultiplier(c,bossFormation.getFrontCreature().getElement()) > 1){\n baseViability = (int)(baseViability * (double)Elements.DAMAGE_BOOST * 3);\n }\n if (Elements.elementDamageMultiplier(bossFormation.getFrontCreature(),c.getElement()) > 1){\n baseViability = (int)(baseViability * (double)Elements.DAMAGE_BOOST / 3);\n }\n return baseViability;\n }", "public static void evaluateMassiveAttackOptions() {\n\n\t\t// Always attack?\n\t\tif (FORCE_CRAZY_ATTACK) {\n\t\t\tcurrentState = STATE_ATTACK_PENDING;\n\t\t\tallowedDistanceFromSafePoint = 999;\n\t\t\treturn;\n\t\t}\n\n\t\t// Currently we are nor attacking, nor retreating.\n\t\tif (!isGlobalAttackInProgress()) {\n\t\t\tdecisionWhenNotAttacking();\n\t\t}\n\n\t\t// We are either attacking or retreating.\n\t\telse {\n\t\t\tallowedDistanceFromSafePoint += MOVE_FORWARD_SPEED;\n\t\t\tdecisionWhenAttacking();\n\t\t}\n\t}", "@Override UpodCondition getConditionTest(UpodProgram pgm) {\n return null;\n }", "@Override\n\tpublic float desireability() {\n\t\tAgentSpace agentSpace = Blackboard.inst().getSpace(AgentSpace.class, _obj.getName());\n\t\tMap<String,FoodEntry> map = agentSpace.getScentMemories().getFirst();\n\t\tif (map == null || map.size() == 0) { \n\t\t\t// we don't smell anything\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tAgentSpace space = Blackboard.inst().getSpace(AgentSpace.class, _obj.getName());\n\t\tBoundedEntry bounded = space.getBounded(Variable.energy);\n\t\tfloat pct = bounded.getValue() / bounded.getMax();\n\t\treturn 1 - (pct*pct);\n\t}", "public boolean whatNow (String action, player friday, player you){ // Method which will allow the ia to choose his action\n\t\tString testAction = \"Tank\"; // Create a String we will use a lot to test other string\n\t\tint actionIa; // If the ia is a Tank, forbid him to use his special attack. The purpose is to prevent him from useless turns\n\t\tif (friday.getName().equals(testAction)){ // If the name of the ia's class is Tank\n\t\t\t actionIa = (int)(Math.random() * 2); // His random will be between 0 or 1\n\t\t}\n\t\t\n\t\telse {\n\t\t\t actionIa = (int)(Math.random() * 3); // Else, his random will be between 0, 1 and 2\n\t\t}\n\t\t\n\t\ttestAction = \"attack\"; // Will be use to test if you attacked\n\t\t\n\t\t\n\t\tswitch (actionIa){ // Test ia's action\n\t\t\tcase 0: // 0, the enemy attack\n\t\t\t\tfriday.setSprite(\"attack\");\n\t\t\t\tSystem.out.println(\"The enemy attack\\n\"); // Warns the user\n\t\t\t\ttestAction = \"block\"; // Will be use to test if you block\n\t\t\t\tif (action.equals(testAction)){ // If you block\n\t\t\t\t\tSystem.out.println(\"You blocked the enemy's attack.\"); // Warns the user\n\t\t\t\t\tyou.setHp(you.getHp() - you.getDp()); // You loose as much hp as your dp\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\telse{\n\t\t\t\t\tyou.setHp(you.getHp() - friday.getAp()); // Else, you loose as much hp as your enemy's ap\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t\n\t\t\tcase 1: // 1, the enemy block\n\t\t\t\tfriday.setSprite(\"block\");\n\t\t\t\tif (action.equals(testAction)){ // If you attacked\n\t\t\t\t\tfriday.setHp(friday.getHp() - friday.getDp()); // The enemy loose as much hp as his dp\n\t\t\t\t\taction = \"\"; // Prevent you from attack a second time\n\t\t\t\t}\n\t\t\t\tSystem.out.println(\"The enemy blocked your attack\\n\"); // Warns the user\n\t\t\t\tbreak;\n\t\t\t\n\t\t\tcase 2: // 2, the enemy use his special power if he isn't a tank\n\t\t\t\tfriday.setSprite(\"special\");\n\t\t\t\tSystem.out.println(\"The enemy uses his special power.\"); // Warns the user\n\t\t\t\tfriday.special(); // Execute ia's special attack\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t}\n\t\t\n\t\ttestAction = \"attack\"; // Reset testAction\n\t\t\n\t\tif (action.equals(testAction)){ // If you attacked\n\t\t\tfriday.setHp(friday.getHp() - you.getAp()); // The enemy loose as much hp as your ap\n\t\t} // Nota Bene : if the enemy blocked your attack, this won't be executed because 'action = \"\";'\n\t\t\n\t\tSystem.out.println(\"You have \" + you.getHp() + \" HP left.\"); // Warns the user\n\t\tSystem.out.println(\"The ennemy have \" + friday.getHp() + \" HP left.\\n\"); // Warns the user\n\t\t\n\t\tif(you.getHp() <= 0){ // If you or the ia has no hp left, warn the system that the fight is over by setting 'end' on true and tell who died\n\t\t\tend = true;\n\t\t\tSystem.out.println(\"You died!\");\n\t\t\tyou.setSprite(\"dead\");\n\t\t}\n\t\t\n\t\telse if(friday.getHp() <= 0){\n\t\t\tend = true;\n\t\t\tSystem.out.println(\"You killed the ennemy!\");\n\t\t\tfriday.setSprite(\"dead\");\n\t\t}\n\t\t\n\t\telse { // Else, it just asks you what you want to do\n\t\t\tSystem.out.println(\"What do you want to do, attack, block or use your special power ?\"); // Asks what you want to do\n\t\t}\n\t\treturn end;\n\t}", "public int getHating(final L2Character target)\n\t{\n\t\tif (getAggroListRP().isEmpty())\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tif (target == null)\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tfinal AggroInfoHolder ai = getAggroListRP().get(target);\n\t\t\n\t\tif (ai == null)\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tif (ai.getAttacker() instanceof L2PcInstance && (((L2PcInstance) ai.getAttacker()).getAppearance().isInvisible() || ((L2PcInstance) ai.getAttacker()).isSpawnProtected() || ((L2PcInstance) ai.getAttacker()).isTeleportProtected() || ai.getAttacker().isInvul()))\n\t\t{\n\t\t\t// Remove Object Should Use This Method and Can be Blocked While Interating\n\t\t\tgetAggroList().remove(target);\n\t\t\t\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tif (!ai.getAttacker().isVisible())\n\t\t{\n\t\t\tgetAggroList().remove(target);\n\t\t\t\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tif (ai.getAttacker().isAlikeDead())\n\t\t{\n\t\t\tai.initHate();\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\treturn ai.getHate();\n\t}", "public Condition getCondition() {\n\t\treturn new MoveDistanceCondition(5,5);\n\t}", "protected boolean IsHighExplosive()\r\n {\r\n \t// Wrapper function to make code a little cleaner.\r\n // isInvulnerable() is wrongly named and instead represents the specific\r\n // skull type the wither has launched\r\n \t\r\n \treturn isInvulnerable();\r\n }" ]
[ "0.65522695", "0.6136676", "0.5999195", "0.5987002", "0.5892547", "0.58727235", "0.5832334", "0.58311945", "0.582121", "0.58099467", "0.56982386", "0.56968546", "0.56968546", "0.56968546", "0.56968546", "0.56968546", "0.56885", "0.5685273", "0.5674794", "0.5670891", "0.5663658", "0.56110674", "0.5592472", "0.5584538", "0.5567791", "0.554081", "0.554081", "0.554081", "0.554081", "0.554081", "0.554081", "0.5531854", "0.55267805", "0.5514856", "0.5499906", "0.54861593", "0.5485575", "0.5452393", "0.54444087", "0.5428714", "0.54283917", "0.5424383", "0.5417087", "0.5408942", "0.5403065", "0.54029644", "0.53881985", "0.5386846", "0.5345693", "0.5344184", "0.5331104", "0.5325677", "0.53255445", "0.5317499", "0.5317499", "0.5317499", "0.5317499", "0.5317499", "0.5317499", "0.5314053", "0.53071886", "0.5295461", "0.52855664", "0.52855664", "0.52855664", "0.52855664", "0.52855664", "0.52855664", "0.528187", "0.52778566", "0.52777296", "0.52774256", "0.52721715", "0.5262676", "0.52602816", "0.5258409", "0.5254181", "0.5245024", "0.523968", "0.5237541", "0.52353644", "0.5234577", "0.5218125", "0.5217875", "0.52172065", "0.52017224", "0.5200644", "0.51980877", "0.5196004", "0.5195933", "0.5192628", "0.51894474", "0.518851", "0.51858336", "0.5179633", "0.51772326", "0.51762533", "0.5175094", "0.5170939", "0.5165895", "0.5164045" ]
0.0
-1
Reduce the current HP of the L2Attackable.
@Override public void reduceCurrentHp(final double damage, final L2Character attacker) { reduceCurrentHp(damage, attacker, true); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void reduceHealth(int damage){\n health -= damage;\n }", "public void reduceHealth() {\n\t}", "public void decreaseHealth(int hp) {\n this.decreaseLife();\n }", "public void reduceHealth(int ammo_damage){\n this.health -= ammo_damage;\n }", "private void strengthen(float hp) {\n this.hp += hp;\n if (this.hp > MAX_HP) {\n this.hp = MAX_HP;\n }\n }", "public void heal(){\n\t\thp += potion.getHpBoost();\n\t\tif(hp > max_hp)hp = max_hp;\n\t}", "public void resetHP(){\r\n this.currHP = this.maxHP;\r\n }", "public void takeDamage(int dmg){\r\n this.currHP -= dmg;\r\n }", "public static void setNewHP(int newHP){\r\n\t\thp -= newHP;\r\n\t}", "private void takeDamage(int damage){ health -= damage;}", "@Override\r\n\tprotected void onReduceHp()\r\n\t{\n\t}", "public void decreaseHealth() {\n setHealth(getHealth()-1);\n }", "void takeDamage(int points) {\n this.health -= points;\n }", "public void setActualHP(int hp) { this.actualHP = Math.max(0, hp); }", "public void suffer(int damage){\r\n\t\thp -= damage;\r\n\t\tinvulnerable = true;\r\n\t}", "public void reduceAnimalHealth() {\n\t\thealth -= 10;\n\t}", "@Override\n public void hp(){\n HP=50*nivel;\n }", "public void setHP(int hp) {\r\n\t\tthis.hp += hp;\r\n\t}", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "public int takeDamage(int damage) {\n damage -= ARMOR;\r\n // set new hp\r\n return super.takeDamage(damage);\r\n }", "@Override\r\n\tpublic void useSkill() {\n\t\tthis.defense+=20;\r\n\t\tthis.maxHp+=(this.maxHp/2);\r\n\t\tthis.hp+=(this.hp/2);\r\n\t\tthis.skillActive = true;\r\n\t\tthis.skillLast = 2;\r\n\t}", "public void deductHealth(int h) {\n setHealth(getHealth() - h);\n }", "public void attack(Person target) {\r\n target.setHealthPoints(target.getHealthPoints() - 1);\r\n }", "public void resetHealth(){\n curHp = healthPoint;\n }", "public void decreaseHealth(int lostBlood){\n health = health - lostBlood;\n }", "void decreaseHealth(Float damage);", "public void takeDamage(int damage) {\r\n this.health -= damage;\r\n if(this.health < 0)\r\n this.health = 0;\r\n }", "public void buyDecreaseDamage() {\n this.decreaseDamage++;\n }", "protected void takeDamage(int damage)\n {\n health = health - damage;\n \n }", "void hurt(int strength) {\n life -= strength;\n if (life < 0)\n life = 0;\n }", "public void recieveDamage(){\n this.health--;\n }", "public void handleAttack(int damage) {\n this.health -= damage;\n }", "void setCurrentHP(final int newHP);", "public void damage(int damageTaken) {\n //TODO: Create specific damage methods instead of damage calls everywhere(see damagedByBullet())\n if (!invincible) {\n this.hp -= damageTaken;\n }\n }", "@Override\n public int damage() {\n int newDamage=criticalStrike();\n return newDamage;\n }", "public void hurt (int amount) {\r\n\t\thealth -= amount;\r\n\t\tif(health <= 0) {\r\n\t\t\thealth = 0; //I will be using this later when entity is knocked out\r\n\t\t\tactive = false;\r\n//\t\t\tdestroy();\r\n\t\t}\r\n\t}", "public void resetHealth() {\n\t\tthis.health = this.getCombatDefinition().getMaxHealth();\n\t}", "private void subtractEnemySheild(int damage) {\n this.enemyShield -= damage;\n }", "public int attack(Character target){ //hw3E#0 //hw46#moreThinking\n lowerHP((int)(strength * attack / 10)); //hw3E#0 //hw46#moreThinking\n return super.attack(target); //hw3E#0 //hw44#3,4 //hw46#moreThinking\n }", "public void takedmg(int dmg){\n curHp -= dmg;\n }", "public void repair(){\n if(health < 9) {\n this.health++;\n }\n }", "public void applyDamage(int damage)\n\t{\n\t\tthis.currHP -= damage;\n\t\tif(currHP <= 0)\n\n\t\t{\n\t\t\tthis.currHP = 0;\n\t\t\tthis.kill();\n\t\t}\n\t\t\t\n\t}", "public void kill() {\n this.hp = 0;\n }", "public void takeDamage(int dmg) {\n\t\thealth -= dmg;\n\t}", "public void hurt(int damage)\n {\n \t hp -= (damage - ( damage * armor / 100 ));\n \t //System.out.println(\"hp: \" + hp);\n }", "public void updateHp(double amount);", "public void buyHealth() {\n this.healthMod++;\n heathMax += 70 * healthMod;\n }", "private void subtractEnemyMissile() {\n this.enemyMissile -= 1;\n }", "public double attack(Legendary other) {\n double effectiveness = getTypeEffectiveness(other);\n double dmg = computeDamage(effectiveness);\n String attackStatus = Mokedex.getAttackStatus(effectiveness);\n \n LockFactory.getLock(\"mok\").lock();\n other.hp -= dmg;\n System.out.println(name + \" dealt \" + dmg + \"HP to \" + other.name + \"!\\n\");\n System.out.println(attackStatus);\n other.display();\n System.out.println(other.name + \" has \" + Math.max(0, other.hp) + \" remaining health.\\n\");\n if (other.hasFainted()) {\n System.out.println(other.name + \" has fainted!\\n\");\n }\n LockFactory.getLock(\"mok\").unlock();\n other.takeRevenge(this);\n\n return dmg;\n }", "int getCurrentHP();", "@Override\r\n\tprotected void setHealth( double newHealth ) \r\n\t{\r\n\t\tthis._health = this._health - newHealth;\r\n\t}", "private void subtractEnemyHealth(int damage) {\n this.enemyShipHealth -= damage;\n }", "public void damagePlayer(int damage){\n hero.decreaseHp(damage);\n }", "public void attack() {\n energy = 2;\n redBull = 0;\n gun = 0;\n target = 1;\n // if Player is in range take off a life.\n if (CharacterTask.ghostLocation == GameWindow.playerLocation) {\n playerLives = playerLives - 1;\n System.out.println(\"Player Lives: \" + playerLives);\n }\n }", "public void resetHp();", "@Override\n\tpublic void skill2(Fightable f) {\n\t\tsuper.setDamage(super.getStrength()*2);\n\t\tsuper.setAtkRange((int)(super.getDamage()/10));\n\t\t\n\t\tthis.attack(f, 3);\n\t}", "@Override\n public void attackedByPaladin(double attack) {\n this.attack += (2 * attack) / 3;\n damageCounter = Math.max(damageCounter - (2 * attack) / 3, 0);\n }", "@Override\n public void hardMode() {\n super.setHP(1800);\n super.getFrontAttack().setBaseDamage(37.5);\n super.getRightAttack().setBaseDamage(37.5);\n super.getBackAttack().setBaseDamage(37.5);\n super.getLeftAttack().setBaseDamage(37.5);\n }", "public void takeDamage(double damage){\n damage -= this.armor;\n this.health -= damage;\n }", "public void doAction(int action){\n this.hp -= action;\n }", "public void reduceHealth(int damage, int player) {\n\t\tif (player == OPPONENT) {\n\t\t\tint currentHealth = Integer.parseInt(opponentHealth.getText());\n\t\t\tint newHealth = currentHealth - damage;\n\t\t\topponentHealth.setText(Integer.toString(newHealth));\n\t\t\tdouble reduction = opponentHealthBar.getWidth()*(((double)newHealth)/((double) currentHealth));\n\t\t\thealthBarDamageAnimation(0,reduction);\n\t\t} else if (player == LOCAL) {\n\t\t\tint currentHealth = Integer.parseInt(localHealth.getText());\n\t\t\tint newHealth = currentHealth - damage;\n\t\t\tlocalHealth.setText(Integer.toString(newHealth));\n\t\t\tdouble reduction = localHealthBar.getWidth()*(((double)newHealth)/((double) currentHealth));\n\t\t\thealthBarDamageAnimation(1,reduction);\n\t\t}\n\t}", "public void punch (int health)\n {\n\thealth -= 8;\n\thealth2 = health;\n }", "@Override\n public void attackedByShaman(double attack) {\n damageCounter += (2 * attack) / 3;\n this.attack = Math.max(this.attack - (2 * attack) / 3, 0);\n }", "public void loseHealth(int damage) {\r\n this.health -= damage;\r\n if (this.health <=0) {\r\n System.out.println(\"Player knocked out\");\r\n //Reduce number of lives remaining for the player\r\n }\r\n }", "public void healPlayer(int hp) {\n if (hero.getHp() < LabyrinthFactory.HP_PLAYER) {\n hero.increaseHP(hp);\n }\n }", "private void subtractPlayerSheild(int damage) {\n this.playerShield -= damage;\n }", "public void lowerHealth() {\n Greenfoot.playSound(\"hit.wav\");\n lives--;\n move(-100);\n if (lives == 0) {\n die();\n }\n }", "public void setMaxHealth() {\n\t\tthis.maxHealth *= level / 10;\n\t}", "private void subtractPlayerHealth(int damage) {\n this.playerShipHealth -= damage;\n }", "public void fullyHeal() {\n removeStatus();\n getActualMoves().restoreAllPP();\n healHealthFraction(1);\n }", "public void deductHealth( int amt) {\n currentHealth = currentHealth - amt;\n }", "private void setHealth() {\n eliteMob.setHealth(maxHealth = (maxHealth > 2000) ? 2000 : maxHealth);\n }", "public void unleash() {\n\t\tlocked = false;\n\t\tfloat percent = framesAccelerated/60.0f;\n\t\tif (percent > 1) percent = 2 - percent;\n\t\tif (percent < 0) percent = 0;\n\t\t\n\t\tif (player.aiControlled()) {\n\t\t\tpercent = AIcontroller.randomStartBoost();\n\t\t}\n\t\t\n\t\tspeed = MAX_SPEED * percent;\n\t}", "public void heal2()\r\n {\r\n this.health = 900;\r\n Story.healText2();\r\n }", "private void subtractPlayerMissile() {\n this.playerMissile -= 1;\n }", "@Override\n public int maxHealth() {\n return 25;\n }", "@Override\n public void setHp(int hp){\n this.hp = hp;\n }", "public void setHP(int newHP) {\n //grabs the hp\n HpComponent health = this.findHpComponent();\n\n health.setHP(newHP); //sets the hp\n }", "public void deactivateAbility(LevelManager lm){\n\n int prevDamage = lm.player.getDamage();\n int newDamage = prevDamage-12;\n lm.player.setDamage(newDamage);\n }", "public void healPokemon() {\r\n\t\tfor (Pokemon p : ownedPokemon) {\r\n\t\t\tp.resetCurrentHP();\r\n\t\t}\r\n\t}", "private void sharplyChange(){\r\n\t\t\tgovernmentLegitimacy -= 0.3;\r\n\t\t}", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "public void ability(LevelManager lm){\n\n int prevDamage = lm.player.getDamage();\n int newDamage = prevDamage+12;\n lm.player.setDamage(newDamage);\n }", "@Override\r\n\tpublic void heal() {\n\t\tSystem.out.println(\"Paladin \" + super.getName() + \" heals for 50 points.\");\r\n\t\tsuper.setHitPoints(super.getHitPoints() + 50);\r\n\t}", "public void restoreHealth()\r\n {\r\n health = maxHealth;\r\n \r\n say(\"Yay my health is now \" + maxHealth + \"!\");\r\n }", "public void setHp(int hp) {\r\n\t\tthis.hp = hp;\r\n\t}", "public void setHp(int hp){\r\n this.hp = hp;\r\n }", "@Override\n public void scaleStats() {\n this.damage = BASE_DMG + (this.getLevel() * 3);\n }", "public void decreaseHealingNumber() {\n healingNumber--;\n }", "public void move2(Pokemon enemy){\n boolean crit = false;\n boolean superEffective = false;\n boolean reduced = false;\n boolean moveHit = true;\n\n int randCrit = (int)(22 * Math.random()+1);\n\n //CHANGE ATTACK TO FALSE IF MOVE DOES NO DAMAGE<<<<<<<<<<<<<\n boolean attack = true;\n //CHANGE TYPE TO TYPE OF MOVE POWER AND ACCURACY<<<<<<<<<<<<<\n String type = \"Bug\";\n int power = 80;\n int accuracy = 100;\n\n //DO NOT CHANGE BELOW THIS\n int damage = ((CONSTANT * power * ( getAtt() / enemy.getDef() )) /50);\n if(randCrit == CONSTANT){\n damage = damage * 2;\n crit = true;\n }\n if(checkSE(type,enemy.getType())){\n damage = damage * 2;\n superEffective = true;\n }\n if(checkNVE(type, enemy.getType())){\n damage = damage / 2;\n reduced = true;\n }\n if(attack && hit(accuracy)){\n enemy.lowerHp(damage);\n }\n else{\n if(hit(accuracy)){\n //DO STATUS EFFECT STUFF HERE (ill figure out later)\n }\n }\n lowerM2PP();\n }", "public int getHP() {\r\n return currHP;\r\n }", "public double getPlayerFullHP();", "public void takeDamage()\n {\n if(getWorld()!= null)\n {\n if(this.isTouching(Enemies.class))\n {\n Life = Life - Enemies.damage;\n if(Life <=0)\n {\n getWorld().removeObject(this);\n Store.wealth += Game.credit;\n }\n }\n }\n }", "public void setHp(int hp) {\n\t\tthis.hp = hp;\n\t}" ]
[ "0.6993864", "0.69858724", "0.6928838", "0.6896141", "0.68353575", "0.676236", "0.67208236", "0.6652757", "0.6635197", "0.66351813", "0.662031", "0.6602824", "0.6498625", "0.64831567", "0.6461138", "0.6419254", "0.63821155", "0.6366195", "0.62792987", "0.6257233", "0.62550974", "0.62413394", "0.6232104", "0.62257105", "0.62255776", "0.62030536", "0.6171885", "0.6126574", "0.61185837", "0.61113673", "0.6100713", "0.60962456", "0.6094771", "0.6092284", "0.60860586", "0.6070757", "0.60674816", "0.60578966", "0.6057637", "0.6055392", "0.6053291", "0.605316", "0.6051384", "0.6049698", "0.60481983", "0.60304016", "0.6028977", "0.60106933", "0.6001512", "0.6000216", "0.5994811", "0.5960801", "0.5960732", "0.595826", "0.59575504", "0.59563464", "0.5955755", "0.595491", "0.5923426", "0.59055", "0.5892225", "0.58898324", "0.58843094", "0.58835906", "0.5877731", "0.5875046", "0.5874053", "0.58734274", "0.5841736", "0.58403766", "0.58289886", "0.5823698", "0.5815159", "0.58142287", "0.58008236", "0.58000046", "0.57974833", "0.5794617", "0.57917374", "0.5778576", "0.57779926", "0.57756484", "0.57756484", "0.57756484", "0.57756484", "0.57756484", "0.57756484", "0.57756484", "0.5769065", "0.5752177", "0.5749551", "0.57420343", "0.57244015", "0.5718468", "0.5718315", "0.5696361", "0.5693792", "0.56921655", "0.56918454", "0.56916887" ]
0.706055
0
Reduce the current HP of the L2Attackable, update its aggroList and launch the doDie Task if necessary.
@Override public void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake) { /* * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; */ if (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { if (firstCommandChannelAttacked == null) // looting right isn't set { synchronized (this) { if (firstCommandChannelAttacked == null) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel(); if (firstCommandChannelAttacked != null) { commandChannelTimer = new CommandChannelTimer(this); commandChannelLastAttack = System.currentTimeMillis(); ThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, "", "You have looting rights!")); // TODO: retail msg } } } } else if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel { commandChannelLastAttack = System.currentTimeMillis(); // update last attack time } } /* * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel(); * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, "", * "You have looting rights!")); } } */ if (isEventMob) { return; } // Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList if (attacker != null) { addDamage(attacker, (int) damage); } // If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle if (this instanceof L2MonsterInstance) { L2MonsterInstance master = (L2MonsterInstance) this; if (this instanceof L2MinionInstance) { master = ((L2MinionInstance) this).getLeader(); if (!master.isInCombat() && !master.isDead()) { master.addDamage(attacker, 1); } } if (master.hasMinions()) { master.callMinionsToAssist(attacker); } master = null; } // Reduce the current HP of the L2Attackable and launch the doDie Task if necessary super.reduceCurrentHp(damage, attacker, awake); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void attack() {\n energy = 2;\n redBull = 0;\n gun = 0;\n target = 1;\n // if Player is in range take off a life.\n if (CharacterTask.ghostLocation == GameWindow.playerLocation) {\n playerLives = playerLives - 1;\n System.out.println(\"Player Lives: \" + playerLives);\n }\n }", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker)\n\t{\n\t\treduceCurrentHp(damage, attacker, true);\n\t}", "public void heal(){\n\t\thp += potion.getHpBoost();\n\t\tif(hp > max_hp)hp = max_hp;\n\t}", "public void reduceHealth() {\n\t}", "public void suffer(int damage){\r\n\t\thp -= damage;\r\n\t\tinvulnerable = true;\r\n\t}", "public void battleEnemyAttack() {\n if(battleEnemy != null){ // If all enemies have attacked, they cannot attack anymore for this round\n\n MovingEntity target = battleEnemy.getAttackPreference(targetAllies);\n if(target == null){\n target = targetAlly;\n }\n\n battleEnemy.attack(target, targetEnemies, targetAllies);\n //System.out.println(battleEnemy.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still friendly incase of zombify\n targetAlly = checkSideSwap(targetAlly, false, battleEnemies, targetEnemies, battleAllies, targetAllies);\n }\n\n battleEnemy = nextAttacker(battleEnemy, battleEnemies);\n\n }\n }", "private void takeDamage(int damage){ health -= damage;}", "public void decreaseHealth(int hp) {\n this.decreaseLife();\n }", "public void takeDamage(int dmg){\r\n this.currHP -= dmg;\r\n }", "private void selfHeal() {\n\t\t\n\t\t//IF the Droid is carrying an item...\n\t\tif (this.getItemCarried() != null){\n\t\t\t\n\t\t\t//If the item is an oil can...\n\t\t\tif (this.getItemCarried().getShortDescription() == \"an oil can\" ) {\n\t\t\t\n\t\t\t\t//If the Droids health is LOWER than half...\n\t\t\t\tif((this.getInitialHP()/2) > this.getHitpoints()) {\n\t\t\t\t\tsay(this.getShortDescription() + \" is at or below half HP. \"\n\t\t\t\t\t\t\t+ \" Healing itself...\");\n\t\t\t\t\t\n\t\t\t\t\t//Implementing a new HealDroid method (Droid heals on itself)\n\t\t\t\t\t//public HealDroid(SWEntityInterface theTarget, MessageRenderer m) {\n\t\t\t\t\tHealDroid droidHeal = new HealDroid(this, messageRenderer);\n\t\t\t\t\t\n\t\t\t\t\tscheduler.schedule(droidHeal, this, 1);\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t}\t\t\n\t}", "public void damage(int damageTaken) {\n //TODO: Create specific damage methods instead of damage calls everywhere(see damagedByBullet())\n if (!invincible) {\n this.hp -= damageTaken;\n }\n }", "private void strengthen(float hp) {\n this.hp += hp;\n if (this.hp > MAX_HP) {\n this.hp = MAX_HP;\n }\n }", "@Override\r\n\tprotected void onReduceHp()\r\n\t{\n\t}", "void takeDamage(int points) {\n this.health -= points;\n }", "public void reduceHealth(int ammo_damage){\n this.health -= ammo_damage;\n }", "protected void takeDamage(int damage)\n {\n health = health - damage;\n \n }", "private void damage(){\n\n LevelMap.getLevel().damage(dmg);\n //System.out.println(\"died\");\n setDie();\n }", "public void takeDamage()\n {\n if(getWorld()!= null)\n {\n if(this.isTouching(Enemies.class))\n {\n Life = Life - Enemies.damage;\n if(Life <=0)\n {\n getWorld().removeObject(this);\n Store.wealth += Game.credit;\n }\n }\n }\n }", "public void doOffensiveMicro(RobotInfo[] engageableEnemies, MapLocation rallyPoint) throws GameActionException {\n\n if (engageableEnemies.length > 0) {\n // returns {is winning, is lowest health and not alone}\n int[] metrics = getBattleMetrics(engageableEnemies);\n if (metrics[0] > 0) {\n //rc.setIndicatorString(1, \"winning...\" + Clock.getRoundNum());\n\n if (metrics[1] != -1 || metrics[2] != -1) {\n Messaging.setBattleFront(new MapLocation(metrics[1], metrics[2]));\n }\n MapLocation nearestBattle = Messaging.getClosestBattleFront(rc.getLocation());\n RobotInfo[] attackableEnemies = Cache.getAttackableEnemies();\n if (attackableEnemies.length > 0) {\n if (rc.isWeaponReady()) {\n attackLeastHealthPrioritized(attackableEnemies);\n }\n } else {\n if (metrics[1] != -1 || metrics[2] != -1) {\n if (nearestBattle != null && nearestBattle.distanceSquaredTo(rc.getLocation()) <= 50) {\n //rc.setIndicatorString(1, \"Going to battlefront: \" + nearestBattle + \", \" + Clock.getRoundNum());\n Nav.goTo(nearestBattle, Engage.UNITS);\n } else {\n Nav.goTo(rallyPoint, Engage.NONE);\n }\n }\n }\n } else {\n // \"are we definitely going to die?\"\n if (metrics[1] > 0) {\n SupplyDistribution.setDyingMode();\n SupplyDistribution.manageSupply();\n if (rc.isWeaponReady()) {\n attackLeastHealthPrioritized(Cache.getAttackableEnemies());\n }\n \n // Retreat\n } else {\n if (rc.isCoreReady()) {\n int[] attackingEnemyDirs = calculateNumAttackingEnemyDirs();\n Nav.retreat(attackingEnemyDirs);\n }\n }\n }\n } else {\n if (rc.isCoreReady()) {\n MapLocation nearestBattle = Messaging.getClosestBattleFront(curLoc);\n if (nearestBattle != null ) {\n //rc.setIndicatorString(1, \"Going to battlefront: \" + nearestBattle + \", \" + Clock.getRoundNum());\n Nav.goTo(nearestBattle, Engage.UNITS);\n } else if (rallyPoint != null) {\n Nav.goTo(rallyPoint, Engage.NONE);\n }\n }\n }\n }", "public void reduceHealth(int damage){\n health -= damage;\n }", "public void resolve(){\n logger.log(Level.FINE,attacker.getName()+\" withering attacked \"+defender.getName());\n AttackState state=new AttackState();\n state.weaponDamage=weapon.getDamage();\n state.initialAttackpool=baseAttackdice+baseAccuracy-woundpenalty;\n attacker.declareWitheringAttack(state); // If the attacker wants to change the pool, he modifies the state accordingly.\n defender.declareWitheringDV(state); // Defender declares their dv against this specific attack. This sets both initialdv and changedDv\n state.initialAttackRoll= new DiceThrow(state.changedAttackpool);\n attacker.modifyWitheringAttackRollAttacker(state); //This sets stuff like modifiedAttackRollAttacker and AttackerRollValuation\n defender.modifyWitheringAttackRollDefender(state); //This sets defender modifiedAttackRollDefender\n state.attackRollSuccesses=state.modifiedAttackRollDefender.evaluateResults(state.AttackRollValuationAttacker);\n state.threshholdSuccesses=state.attackRollSuccesses-state.changedDv;\n logger.log(Level.FINE,attacker.getName()+\" rolled \"+state.changedAttackpool+\" dice against \"+defender.getName()+\"'s dv of \"+state.changedDv+\" and gained \"+state.attackRollSuccesses+\" successes.\");\n attacker.changeWitheringThreshholdAttacker(state); //This sets thresholdModifiedAttacker\n defender.changeWitheringThreshholdDefender(state); //This sets thresholdModifiedDefender\n if(state.thresholdModifiedDefender>=0) {\n logger.log(Level.FINE,attacker.getName()+\" hit \"+defender.getName()+\" with \"+state.thresholdModifiedDefender+\" threshhold successes.\");\n attacker.modifyWitheringRawDamageAttacker(state); //Sets normal raw damageType, based on strength and weapon damageType, and then sets rawDamagemModifiedAttacker\n defender.modifyWitheringRawDamageDefender(state); //this sets rawDamageModifiedDefender, and sets up the various soak values, so natural soak and armor soak.\n logger.log(Level.FINE, \"The raw damage of the attack is: \"+state.rawDamageModifiedDefender);\n state.totalSoak = Math.max(state.defenderArmorSoak - ignoredArmorSoak, 0) + state.defenderNaturalSoak; //\n attacker.modifyTotalSoakAttacker(state); //This sets totalSoakmodifiedAttacker. Don't think this actually has support in the solar charmset, but giving opportunities to work with.\n defender.modifyTotalSoakDefender(state); // This sets totalSoakmodifiedDefender.\n state.postSoakSuccesses=Math.max(state.rawDamageModifiedDefender-state.totalSoakModifiedDefender,weapon.getOverwhelming());\n logger.log(Level.FINE,state.totalSoakModifiedDefender+\" damage is soaked, leading to post soak dice of \"+state.postSoakSuccesses);\n attacker.declarePostSoakAttacker(state); //sets postSoakSuccessesModifiedAttacker\n defender.declarePostSoakDefender(state); //sets postSoakSuccessesModifiedDefender\n DiceThrow droll=new DiceThrow(state.postSoakSuccessesModifiedDefender);\n state.damageRoll=droll;\n attacker.modifyWitheringDamageRollAttacker(state); //sets damageRollmodifiedAttacker and damageRollvValuation\n defender.modifyWitheringDamageRollDefender(state); //sets damageRollmodifiedDefender\n state.initiativeDamageDone=state.damageRollModifiedDefender.evaluateResults(state.damageRollValuation);\n logger.log(Level.FINE,attacker.getName()+\" rolls \"+state.postSoakSuccessesModifiedDefender+\" dice and achieves \"+state.initiativeDamageDone+\" successes.\");\n attacker.modifyInitiativeDamageAttacker(state);\n defender.modifyInitiativeDamageDefender(state); //Since this is the last change of initiative, we can check whether the defender was crashed here.\n attacker.updateInitiativeAttacker(state);\n defender.updateInitiativeDefender(state);//Here we should handle all the initiative changes respectively, with checking if people are crashed etc.\n }\n else{\n attacker.failedWitheringAttackAttacker(state);\n defender.failedWitheringAttackDefender(state);\n }\n\n }", "public abstract int doDamage(int time, GenericMovableUnit unit, Unit target);", "public void fullyHeal() {\n removeStatus();\n getActualMoves().restoreAllPP();\n healHealthFraction(1);\n }", "@Override\n\tprotected void calculateRewards(final L2Character lastAttacker)\n\t{\n\t\t// Creates an empty list of rewards\n\t\tfinal Map<L2Character, RewardInfoHolder> rewards = new ConcurrentHashMap<>();\n\t\t\n\t\ttry\n\t\t{\n\t\t\tif (getAggroListRP().isEmpty())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (EngineModsManager.onNpcExpSp(this, lastAttacker))\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tL2PcInstance maxDealer = null;\n\t\t\tint maxDamage = 0;\n\t\t\t\n\t\t\tint damage;\n\t\t\t\n\t\t\tL2Character attacker, ddealer;\n\t\t\t\n\t\t\t// While Interacting over This Map Removing Object is Not Allowed\n\t\t\tsynchronized (getAggroList())\n\t\t\t{\n\t\t\t\t// Go through the aggroList of the L2Attackable\n\t\t\t\tfor (final AggroInfoHolder info : getAggroListRP().values())\n\t\t\t\t{\n\t\t\t\t\tif (info == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Get the L2Character corresponding to this attacker\n\t\t\t\t\tattacker = info.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Get damages done by this attacker\n\t\t\t\t\tdamage = info.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// Prevent unwanted behavior\n\t\t\t\t\tif (damage > 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (attacker instanceof L2SummonInstance || attacker instanceof L2PetInstance && ((L2PetInstance) attacker).getPetData().getOwnerExpTaken() > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = info.getAttacker();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check if ddealer isn't too far from this (killed monster)\n\t\t\t\t\t\tif (!Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, ddealer, true))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate real damages (Summoners should get own damage plus summon's damage)\n\t\t\t\t\t\tRewardInfoHolder reward = rewards.get(ddealer);\n\t\t\t\t\t\tif (reward == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward = new RewardInfoHolder(ddealer, damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward.addDamage(damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\trewards.put(ddealer, reward);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (ddealer instanceof L2PlayableInstance && ((L2PlayableInstance) ddealer).getActingPlayer() != null && reward.getDmg() > maxDamage)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tmaxDealer = ((L2PlayableInstance) ddealer).getActingPlayer();\n\t\t\t\t\t\t\tmaxDamage = reward.getDmg();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// Manage Base, Quests and Sweep drops of the L2Attackable\n\t\t\tdoItemDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\t// Manage drop of Special Events created by GM for a defined period\n\t\t\tdoEventDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\tif (!getMustRewardExpSP())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (!rewards.isEmpty())\n\t\t\t{\n\t\t\t\tL2Party attackerParty;\n\t\t\t\tlong exp;\n\t\t\t\tint levelDiff, partyDmg, partyLvl, sp;\n\t\t\t\tfloat partyMul, penalty;\n\t\t\t\tRewardInfoHolder reward2;\n\t\t\t\tint[] tmp;\n\t\t\t\t\n\t\t\t\tfor (final RewardInfoHolder reward : rewards.values())\n\t\t\t\t{\n\t\t\t\t\tif (reward == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Penalty applied to the attacker's XP\n\t\t\t\t\tpenalty = 0;\n\t\t\t\t\t\n\t\t\t\t\t// Attacker to be rewarded\n\t\t\t\t\tattacker = reward.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Total amount of damage done\n\t\t\t\t\tdamage = reward.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// If the attacker is a Pet, get the party of the owner\n\t\t\t\t\tif (attacker instanceof L2PetInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PetInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse if (attacker instanceof L2PcInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PcInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If this attacker is a L2PcInstance with a summoned L2SummonInstance, get Exp Penalty applied for the current summoned L2SummonInstance\n\t\t\t\t\tif (attacker instanceof L2PcInstance && ((L2PcInstance) attacker).getPet() instanceof L2SummonInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tpenalty = ((L2SummonInstance) ((L2PcInstance) attacker).getPet()).getExpPenalty();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// We must avoid \"over damage\", if any\n\t\t\t\t\tif (damage > getMaxHp())\n\t\t\t\t\t{\n\t\t\t\t\t\tdamage = getMaxHp();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If there's NO party in progress\n\t\t\t\t\tif (attackerParty == null)\n\t\t\t\t\t{\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\tif (attacker.getKnownList().knowsObject(this))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// Calculate the difference of level between this attacker (L2PcInstance or L2SummonInstance owner) and the L2Attackable\n\t\t\t\t\t\t\t// mob = 24, atk = 10, diff = -14 (full xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 28, diff = 4 (some xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 50, diff = 26 (no xp)\n\t\t\t\t\t\t\tlevelDiff = attacker.getLevel() - getLevel();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, damage);\n\t\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\t\texp *= 1 - penalty;\n\t\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Check for an over-hit enabled strike and VIP options\n\t\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif (player.isVIP())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\texp = (long) (exp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t\tsp = (int) (sp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Distribute the Exp and SP between the L2PcInstance and its L2Summon\n\t\t\t\t\t\t\tif (!attacker.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tattacker.addExpAndSp(Math.round(attacker.calcStat(Stats.EXPSP_RATE, exp, null, null)), (int) attacker.calcStat(Stats.EXPSP_RATE, sp, null, null));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t// share with party members\n\t\t\t\t\t\tpartyDmg = 0;\n\t\t\t\t\t\tpartyMul = 1.f;\n\t\t\t\t\t\tpartyLvl = 0;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Get all L2Character that can be rewarded in the party\n\t\t\t\t\t\tfinal List<L2PlayableInstance> rewardedMembers = new ArrayList<>();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Go through all L2PcInstance in the party\n\t\t\t\t\t\tList<L2PcInstance> groupMembers;\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getCommandChannel().getMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getPartyMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tfor (final L2PcInstance pl : groupMembers)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (pl == null || pl.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Get the RewardInfo of this L2PcInstance from L2Attackable rewards\n\t\t\t\t\t\t\treward2 = rewards.get(pl);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// If the L2PcInstance is in the L2Attackable rewards add its damages to party damages\n\t\t\t\t\t\t\tif (reward2 != null)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add L2PcInstance damages to party damages\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\trewards.remove(pl); // Remove the L2PcInstance from the L2Attackable rewards\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t// Add L2PcInstance of the party (that have attacked or not) to members that can be rewarded\n\t\t\t\t\t\t\t\t// and in range of the monster.\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfinal L2PlayableInstance summon = pl.getPet();\n\t\t\t\t\t\t\tif (summon != null && summon instanceof L2PetInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\treward2 = rewards.get(summon);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (reward2 != null) // Pets are only added if they have done damage\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, summon, true))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add summon damages to party damages\n\t\t\t\t\t\t\t\t\t\trewardedMembers.add(summon);\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tif (summon.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = summon.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\trewards.remove(summon); // Remove the summon from the L2Attackable rewards\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// If the party didn't killed this L2Attackable alone\n\t\t\t\t\t\tif (partyDmg < getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyMul = (float) partyDmg / (float) getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Avoid \"over damage\"\n\t\t\t\t\t\tif (partyDmg > getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyDmg = getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate the level difference between Party and L2Attackable\n\t\t\t\t\t\tlevelDiff = partyLvl - getLevel();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, partyDmg);\n\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\texp *= partyMul;\n\t\t\t\t\t\tsp *= partyMul;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check for an over-hit enabled strike\n\t\t\t\t\t\t// (When in party, the over-hit exp bonus is given to the whole party and splitted proportionally through the party members)\n\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Distribute Experience and SP rewards to L2PcInstance Party members in the known area of the last attacker\n\t\t\t\t\t\tif (partyDmg > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tattackerParty.distributeXpAndSp(exp, sp, rewardedMembers, partyLvl);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t}", "public void actionCombat(Party p1) {\n System.out.println(\"______________________________________________________________________________\\n\");\n System.out.println(this.Name + \" is attacking ...\");\n int choice = (int)(Math.random() * p1.getTeam().size());\n Character target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n\n if (this.SPEED - target.getSPEED() < 5) {\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n }\n else {\n int n = 0;\n while ((target.actualHP != 0) && (n < 2)) {\n if (n == 1) {\n choice = (int)(Math.random() * p1.getTeam().size() + 1);\n target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n }\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n if (n == 0) System.out.println(this.Name + \" attacks again ...\");\n n++;\n }\n }\n }", "public void repair(){\n if(health < 9) {\n this.health++;\n }\n }", "public void attack(Person target) {\r\n target.setHealthPoints(target.getHealthPoints() - 1);\r\n }", "public void handleAttack(int damage) {\n this.health -= damage;\n }", "public void punch (int health)\n {\n\thealth -= 8;\n\thealth2 = health;\n }", "public void addDamageHate(final L2Character attacker, final int damage, int aggro)\n\t{\n\t\tif (attacker == null /* || aggroList == null */)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Get the AggroInfo of the attacker L2Character from the aggroList of the L2Attackable\n\t\tAggroInfoHolder ai = getAggroListRP().get(attacker);\n\t\t\n\t\tif (ai == null)\n\t\t{\n\t\t\tai = new AggroInfoHolder(attacker);\n\t\t\tai.init();\n\t\t\tgetAggroListRP().put(attacker, ai);\n\t\t}\n\t\t\n\t\t// If aggro is negative, its comming from SEE_SPELL, buffs use constant 150\n\t\tif (aggro < 0)\n\t\t{\n\t\t\tai.decHate(aggro * 150 / (getLevel() + 7));\n\t\t\taggro = -aggro;\n\t\t}\n\t\t// if damage == 0 -> this is case of adding only to aggro list, dont apply formula on it\n\t\telse if (damage == 0)\n\t\t{\n\t\t\tai.incHate(aggro);\n\t\t\t// else its damage that must be added using constant 100\n\t\t}\n\t\telse\n\t\t{\n\t\t\tai.incHate(aggro * 100 / (getLevel() + 7));\n\t\t}\n\t\t\n\t\t// Add new damage and aggro (=damage) to the AggroInfo object\n\t\tai.incDmg(damage);\n\t\t\n\t\t// Set the intention to the L2Attackable to AI_INTENTION_ACTIVE\n\t\tif (getAI() != null && aggro > 0 && getAI().getIntention() == CtrlIntention.AI_INTENTION_IDLE)\n\t\t{\n\t\t\tgetAI().setIntention(CtrlIntention.AI_INTENTION_ACTIVE);\n\t\t}\n\t\t\n\t\tai = null;\n\t\t// Notify the L2Attackable AI with EVT_ATTACKED\n\t\tif (damage > 0)\n\t\t{\n\t\t\tif (getAI() != null)\n\t\t\t{\n\t\t\t\tgetAI().notifyEvent(CtrlEvent.EVT_ATTACKED, attacker);\n\t\t\t}\n\t\t\t\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif (attacker instanceof L2PcInstance || attacker instanceof L2Summon)\n\t\t\t\t{\n\t\t\t\t\tL2PcInstance player = attacker instanceof L2PcInstance ? (L2PcInstance) attacker : ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\n\t\t\t\t\tfor (final Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_ATTACK))\n\t\t\t\t\t{\n\t\t\t\t\t\tquest.notifyAttack(this, player, damage, attacker instanceof L2Summon);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tplayer = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\tcatch (final Exception e)\n\t\t\t{\n\t\t\t\tLOGGER.error(\"\", e);\n\t\t\t}\n\t\t}\n\t}", "public void ExecuteAction()\n {\n ActionTarget oTarget = mVecTargets.get( 0 );\n\n // Check if attack lands: compute chance of hitting the target\n if ( RandomGenerator.GetInstance().GetRandom( 1, 100 ) <=\n mSourceUnit.GetHitChance( oTarget.mCell.GetUnit() ) )\n {\n // Get the attack information from the attacking unit\n double dFinalDamage = Math.max(\n 1,\n mSourceUnit.GetUnit().GetResultingAttributes().GetStrength() -\n oTarget.mCell.GetUnit().GetUnit().GetResultingAttributes().GetPhysicalDef() );\n\n // Check critical chance\n if ( RandomGenerator.GetInstance().GetRandom( 1, 100 ) <=\n mSourceUnit.GetCritChance() )\n {\n dFinalDamage *= 1.5;\n oTarget.mActionStatus = ActionStatus.STATUS_CRITICAL;\n }\n else\n {\n oTarget.mActionStatus = ActionStatus.STATUS_SUCCESS;\n }\n\n // Add random portion to damage (10% of base damage)\n dFinalDamage = RandomGenerator.GetInstance().GetRandom(\n dFinalDamage - ( dFinalDamage / 10 ),\n dFinalDamage + ( dFinalDamage / 10 ) );\n mDamage = oTarget.mCell.GetUnit().ApplyDamage( dFinalDamage );\n\n // Add Slow status to target\n oTarget.mCell.GetUnit().SetStatus( new UnitStatusSlow(\n SLOW_TURN_DURATION,\n oTarget.mCell.GetUnit(),\n SLOW_PERCENTAGE ) );\n\n }\n else\n {\n mDamage = 0;\n oTarget.mActionStatus = ActionStatus.STATUS_MISS;\n }\n\n NotifyActionUpdate();\n ResetAttackArray();\n mSourceUnit.SetActionPerformed();\n }", "public void kill() {\n this.hp = 0;\n }", "public void autosimulateCombat() {\n\n int monstersRemainingHealth = monster.getHealth() - player.getPower();\n int playersRemainingHealth = player.getHealth() - monster.getPower();\n\n while (player.getHealth() > 0 && monster.getHealth() > 0) {\n\n monster.setHealth(monstersRemainingHealth);\n monstersRemainingHealth = monster.getHealth() - player.getPower();\n\n\n player.setHealth(playersRemainingHealth);\n playersRemainingHealth = player.getHealth() - monster.getPower();\n\n }\n isPlayerDefeated();\n return;\n }", "public void applyDamage(int damage)\n\t{\n\t\tthis.currHP -= damage;\n\t\tif(currHP <= 0)\n\n\t\t{\n\t\t\tthis.currHP = 0;\n\t\t\tthis.kill();\n\t\t}\n\t\t\t\n\t}", "public void attack() {\n if (activeWeapon == null) {\n return;\n }\n attacking = true;\n }", "public void execute() {\n\t\tif (getTargetEnemies() != null && getTargetEnemies().size() > 0) {\n\t\t\tBuff buff = new Buff(getHero().getId(), null, Buff.SPEED, getAbility().getValue(), CHARGE_DURATION, \"0\", 0);\n\t\t\tThread buffDurationThread = new Thread(() -> {\n\t\t\t\ttry {\n\t\t\t\t\tThread.sleep(CHARGE_DURATION);\n\t\t\t\t} catch (InterruptedException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t\tgetHero().removeBuff(buff);\n\t\t\t\tgetGameServer().sendGameStatus();\n\t\t\t\tLog.i(TAG, \"Removed buff, now have these many buffs left : \" + getHero().getBuffs().size());\n\t\t\t});\n\t\t\tbuffDurationThread.start();\n\n\t\t\tgetHero().getBuffs().add(buff);\n\n\t\t\t// Set the cooldown for this ability\n\t\t\tgetAbility().setMillisLastUse(getTime());\n\t\t\tgetAbility().setTimeWhenOffCooldown(\"\" + (getTime() + getAbility().calculateCooldown(getHero(), this)));\n\n\t\t\t// Send castbar information\n\t\t\tgetGameServer().sendCastBarInformation(getHero().getId(), getAbility());\n\n\t\t\t// Add animation to list\n\t\t\tgetGameServer().getAnimations().add(new GameAnimation(\"CHARGE\", 0, getHero().getId(), null, 1));\n\t\t}else{\n\t\t\tLog.i(TAG, \"Hero had no target, canceling ability\");\n\t\t}\n\t\tsuper.execute();\n\t}", "public void move2(Pokemon enemy){\n boolean crit = false;\n boolean superEffective = false;\n boolean reduced = false;\n boolean moveHit = true;\n\n int randCrit = (int)(22 * Math.random()+1);\n\n //CHANGE ATTACK TO FALSE IF MOVE DOES NO DAMAGE<<<<<<<<<<<<<\n boolean attack = true;\n //CHANGE TYPE TO TYPE OF MOVE POWER AND ACCURACY<<<<<<<<<<<<<\n String type = \"Bug\";\n int power = 80;\n int accuracy = 100;\n\n //DO NOT CHANGE BELOW THIS\n int damage = ((CONSTANT * power * ( getAtt() / enemy.getDef() )) /50);\n if(randCrit == CONSTANT){\n damage = damage * 2;\n crit = true;\n }\n if(checkSE(type,enemy.getType())){\n damage = damage * 2;\n superEffective = true;\n }\n if(checkNVE(type, enemy.getType())){\n damage = damage / 2;\n reduced = true;\n }\n if(attack && hit(accuracy)){\n enemy.lowerHp(damage);\n }\n else{\n if(hit(accuracy)){\n //DO STATUS EFFECT STUFF HERE (ill figure out later)\n }\n }\n lowerM2PP();\n }", "public double attack(Legendary other) {\n double effectiveness = getTypeEffectiveness(other);\n double dmg = computeDamage(effectiveness);\n String attackStatus = Mokedex.getAttackStatus(effectiveness);\n \n LockFactory.getLock(\"mok\").lock();\n other.hp -= dmg;\n System.out.println(name + \" dealt \" + dmg + \"HP to \" + other.name + \"!\\n\");\n System.out.println(attackStatus);\n other.display();\n System.out.println(other.name + \" has \" + Math.max(0, other.hp) + \" remaining health.\\n\");\n if (other.hasFainted()) {\n System.out.println(other.name + \" has fainted!\\n\");\n }\n LockFactory.getLock(\"mok\").unlock();\n other.takeRevenge(this);\n\n return dmg;\n }", "public void gameAttack(){\n int counter = 0;\n while (currentPlayer.wantToAttack(this)){\n counter++;\n if (counter > 100) break;\n /*In rare cases, AI players will repeatedly select the same attackers and defenders\n while also not wanting to dice fight. That will infinitely loop here and this counter will prevent it\n Under normal circumstances, no reasonable player will ever try to do more than 100 separate attacks in the same turn\n */\n\n String[] attackerDefender = {\"\",\"\"};\n //AttackStarterSelection\n attackerDefender[0] = currentPlayer.chooseAttackStarter(this);\n\n //AttackDefenderSelection\n attackerDefender[1] = currentPlayer.chooseAttackDefender(this, attackerDefender[0]);\n\n //DiceFightOrQuit\n int attackerDice, defenderDice;\n while (currentPlayer.wantToDiceFight(this, attackerDefender[0]+ \",\" + attackerDefender[1])){\n //DiceFightAttackerChoice\n attackerDice = currentPlayer.getAttackerDice(this, getTerritory(attackerDefender[0]));\n\n //DiceFightDefenderChoice\n Player defender = this.getPlayerFromList(this.getTerritory(attackerDefender[1]).getOwner());\n defenderDice = defender.getDefenderDice(this, this.getTerritory(attackerDefender[1]));\n\n\n //DiceFight results\n displayMessage(this.diceFight(attackerDefender, attackerDice,defenderDice));\n\n //Possible elimination and announcement of winner\n //Current diceFight ends if attacker has 1 troop left, or territory is conquered\n if (endDiceFight(attackerDefender, attackerDice)) break;\n\n }//End diceFightOrQuit\n\n\n }//End wantToAttack\n //Proceed to fortify stage of turn\n }", "public void recieveDamage(){\n this.health--;\n }", "public void battleAllyAttack() {\n if(battleAlly instanceof Character){\n battleTickStatuses();\n updateBattleSides();\n }\n\n // battleAlly now attacks targetEnemy or preference based on the type of battleAlly\n if(battleAlly != null){ // If all allies have attacked, they cannot attack anymore for this round\n MovingEntity target = battleAlly.getAttackPreference(targetEnemies);\n // if not picky, get preference is the default next target\n if(target == null) {\n target = targetEnemy;\n }\n battleAlly.attack(target, targetAllies, targetEnemies);\n //System.out.println(battleAlly.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still unfriendly\n targetEnemy = checkSideSwap(targetEnemy, true, battleAllies, targetAllies, battleEnemies, targetEnemies);\n }\n battleAlly = nextAttacker(battleAlly, battleAllies);\n\n }\n }", "public void heal2()\r\n {\r\n this.health = 900;\r\n Story.healText2();\r\n }", "private final void maintain(){\n\t\tif(host.getStrength()>MAINTENANCE_COST){\n\t\t\thost.expend(MAINTENANCE_COST);\n\t\t}\n\t\telse{\n\t\t\tkill();\n\t\t}\n\t}", "public void attack(User p)\n\t{\n\t\tint damage = getAttack() - p.getDefense();\n\t\tint evade = 0;\n\t\tif(damage <= 0)\n\t\t{\n\t\t\tevade = p.getDefense() - getAttack();\n\t\t\tdamage = 1;\n\t\t}\n\t\t\n\t\tif(Math.random() * 100 < evade * 5)\n\t\t{\n\t\t\tJOptionPane.showMessageDialog(null, \"Miss\");\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tp.reduce(damage);\n JOptionPane.showMessageDialog(null,\"Enemy attacked you! User's health = \" + p.getHealth() + \"\\n\" + \"Damage dealt = \" + damage); \n\t}", "public void takeDamage(int damage) {\r\n this.health -= damage;\r\n if(this.health < 0)\r\n this.health = 0;\r\n }", "@Override\n\tpublic int fight(Enemy e1) {\n\t\tint damage = 0;\n\t\tRandom randomNum = new Random();\n\t\tdamage = 6 + randomNum.nextInt(4);\n\t\ttry {\n\t\t\te1.takeDamage(damage);\n\t\t} catch (InvalidDamageException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn damage;\n\t}", "@Override\n protected void onDeath(final Creature killer) {\n getDeathPenalty().checkCharmOfLuck();\n\n if (isInStoreMode()) {\n setPrivateStoreType(Player.STORE_PRIVATE_NONE);\n }\n if (isProcessingRequest()) {\n final Request request = getRequest();\n if (isInTrade()) {\n final Player partner = request.getOtherPlayer(this);\n sendPacket(SendTradeDone.FAIL);\n partner.sendPacket(SendTradeDone.FAIL);\n }\n request.cancel();\n }\n //cubicdata\n deleteCubics();\n deleteAgathion();\n\n boolean checkPvp = true;\n if (ServerConfig.ALLOW_CURSED_WEAPONS) {\n if (isCursedWeaponEquipped()) {\n CursedWeaponsManager.getInstance().dropPlayer(this);\n checkPvp = false;\n } else if (killer != null && killer.isPlayer() && killer.isCursedWeaponEquipped()) {\n CursedWeaponsManager.getInstance().increaseKills(((Player) killer).getCursedWeaponEquippedId());\n checkPvp = false;\n }\n }\n\n if (checkPvp) {\n doPKPVPManage(killer);\n\n altDeathPenalty(killer);\n }\n\n //And in the end of process notify death penalty that owner died :)\n getDeathPenalty().notifyDead(killer);\n\n setIncreasedForce(0);\n\n if (isInParty() && getParty().isInReflection() && getParty().getReflection() instanceof DimensionalRift) {\n ((DimensionalRift) getParty().getReflection()).memberDead(this);\n }\n\n stopWaterTask();\n stopMountFeedTask();\n\n if (!isSalvation() && isOnSiegeField() && isCharmOfCourage()) {\n ask(new ConfirmDlg(SystemMsg.YOUR_CHARM_OF_COURAGE_IS_TRYING_TO_RESURRECT_YOU, 60000), new ReviveAnswerListener(this, 100, false, 60000));\n setCharmOfCourage(false);\n }\n\n if (AllSettingsConfig.AltKillAnnounce && killer != null && killer.isPlayer())\n AnnouncementUtils.announceToAll(killer.getName() + \" убил игрока \" + getName() + \"!\");\n\n super.onDeath(killer);\n }", "public void takeDamage(int dmg) {\n\t\thealth -= dmg;\n\t}", "private void enemyAttack() {\n\t\t\n\t\tRandom rand = new Random();\t\n\t\t\n\t\tint roll = rand.nextInt(101);\n\t\t\n\t\tint sroll = rand.nextInt(101);\n\t\t\n\t\tevents.appendText(e.getName() + \" attacks!\\n\");\n\t\t\n\t\tif(roll <= p.getEV()) { // Player evades\n\t\t\t\n\t\t\tevents.appendText(\"You evaded \"+e.getName()+\"\\'s Attack!\\n\");\n\t\t\t\n\t\t}else if(roll > p.getEV()) { // Player is hit and dies if HP is 0 or less\n\t\t\t\n\t\t\tp.setHP(p.getHP() - e.getDMG());\n\t\t\t\n\t\t\tString newHp = p.getHP()+\"/\"+p.getMaxHP();\n\t\t\t\n\t\t\tString effect = e.getSpecial(); // Stats are afflicted\n\t\t\t\n\t\t\tif(sroll < 51){\n\t\t\t\t\n\t\t\tif(effect == \"Bleed\") { // Bleed Special\n\t\t\t\t\n\t\t\t\tp.setHP(p.getHP() - 100);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You bleed profusely. - 100 HP\\n\");\n\t\t\t\t\n\t\t\t\tnewHp = String.valueOf(p.getHP()+\"/\"+p.getMaxHP());\n\t\t\t}\n\t\t\tif(effect == \"Break\") { // Break Special \n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You feel a bone break restricting movement. - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Fear\") { // Fear Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-40>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 40);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"A crippling fear rattles your resolve. - 40 DMG\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Rend\") { // Rend Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-30>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 30);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"Morthar unleashes a pillar of flame! - 30 DMG and - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\t\n\t\t\tif(p.getHP() <= 0) {\n\t\t\t\t\n\t\t\t\tp.setDead(true);\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(0+\"/\"+e.getMaxHP());\n\t\t\t\tplayerHPBar.setProgress((double)0);\n\t\t\t}else {\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(newHp);\n\t\t\t\tplayerHPBar.setProgress((double)p.getHP()/p.getMaxHP());\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tif(p.isDead()) { // Game over if player dies\n\t\t\t\n\t\t\ttry {\n\t\t\t\tLoadGO();\n\t\t\t} catch (IOException e1) {\n\t\t\t\n\t\t\t\te1.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t\tcombat = false;\n\t\t}\n\t}", "void updateEnemies() {\n getEnemies().forEach(e -> {\n if (!e.isAlive()) {\n e.die();\n SoundPlayer.play(SoundPlayer.enemyDestroyed);\n }\n });\n objectsInMap.removeIf(o -> o instanceof Enemy && !(((Enemy) o).isAlive()));//Removing Dead Enemies\n getEnemies().forEach(e -> e.setTarget(objectsInMap.stream().filter(p -> p.identifier.contains(\"PlayerTank0.\") &&\n p.isBlocking && ((Tank) p).isVisible()).collect(Collectors.toList())));//Giving Possible target to enemies to decide\n }", "public void attack(){\n activity = CreatureActivity.ATTACK;\n createWeapon();\n endAttack = new CountDown(20); //100\n endAnimationAttack = new CountDown(100);\n }", "public void decreaseHealth() {\n setHealth(getHealth()-1);\n }", "@Override\n\tpublic void takeDamage(GameObject other) {\n\t\tif (this.state == State.DEAD) return;\n\t\t\n\t\tif (other instanceof Bullet) {\n\t\t\tBullet bullet = (Bullet)other;\n\t\t\tif (bullet.getState() == Bullet.State.ALIVE) {\n\t\t\t\tthis.lastStateTime = lastGameUpdate;\n\t\t\t\tthis.state = State.DEAD;\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (!this.isUndead()) {\n\t\t\tif (other instanceof Human) {\n\t\t\t\tHuman human = (Human)other;\n\t\t\t\tif (human.isUndead()) {\n\t\t\t\t\tthis.lastStateTime = lastGameUpdate;\n\t\t\t\t\tthis.state = State.SHIFTING;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\n\t}", "protected void incrementHunger()\n {\n food_level--;\n if(food_level <= 0) {\n setDead();\n }\n }", "private int heavyAttack() {\n return attack(6, 2);\n }", "public int defend(boolean touchAttack)\n {\n int defense = 0;\n if (rollDefense) {\n int baseRoll = dice.roll(1, 20, 0);\n defense = baseRoll;\n }\n defense += armorClass.get(AC_Type.AC_Reg).getCurrent();\n return defense;\n }", "public void die() {\n\t\tsetDead(true);\n\t\tsetHp(0);\n\t\tgetGraphicShapes().get(stats.getBODY()).setLocation((int) getPosition().x(),\n\t\t\t\t(int) getPosition().y() + stats.getHeight() - stats.getWidth());\n\t\tgetGraphicShapes().get(stats.getBODY()).setSize(stats.getHeight(), stats.getWidth());\n\t\tgetPhysicalRectangle().setLocation((int) getPosition().x(),\n\t\t\t\t(int) getPosition().y() + stats.getHeight() - stats.getWidth());\n\t\tgetPhysicalRectangle().setSize(stats.getHeight(), stats.getWidth());\n\t\tgetGraphicShapes().remove(stats.getWEAPON());\n\t}", "public static void endDamageStep (boolean hasDefeatedOpponent) {\r\n // Exhausted Executioner effect (turn into defence mode)\r\n if (Game.ActiveAttackingMonster.isTurningIntoDef()) {\r\n Game.ActiveAttackingMonster.passiveEffectExhaustedExecutioner();\r\n }\r\n // delete free mode change per turn\r\n Game.ActiveAttackingMonster.isModeChangeableThisTurn=false;\r\n // gain attack due to fighting experience\r\n if (hasDefeatedOpponent && Game.ActiveAttackingMonster.isGainingExperience()) {\r\n // only count number of defeated monster while the Steep Learning Curve effect is active\r\n getNthSummonedMonster(Game.ActiveAttackingMonster.sumMonsterNumber, Game.ActiveAttackingMonster.isPlayersMonster).numberOfDefeatedMonsters++;\r\n Game.ActiveAttackingMonster.att = Game.ActiveAttackingMonster.att + Mon.SteepLearningCurve.SteepLearningCurveAttBoost();\r\n Game.ActiveAttackingMonster.updateAttDefDisplay();\r\n }\r\n endAttack(false); // swich off booleans remembering what monsters are currently in battle\r\n }", "public void move1(Pokemon enemy){\n int randCrit = (int)(22 * Math.random()+1);\n boolean crit = false;\n boolean superEffective = false;\n boolean reduced = false;\n boolean moveHit = true;\n\n //CHANGE ATTACK TO FALSE IF MOVE DOES NO DAMAGE<<<<<<<<<<<<<\n boolean attack = true;\n //CHANGE TYPE TO TYPE OF MOVE POWER AND ACCURACY<<<<<<<<<<<<<\n String type = \"Dark\";\n int power = 70;\n int accuracy = 100;\n\n //DO NOT CHANGE BELOW THIS\n int damage = ((CONSTANT * power * ( getAtt() / enemy.getDef() )) /50);\n if(randCrit == CONSTANT){\n damage = damage * 2;\n crit = true;\n }\n if(checkSE(type,enemy.getType())){\n damage = damage * 2;\n superEffective = true;\n }\n if(checkNVE(type, enemy.getType())){\n damage = damage / 2;\n reduced = true;\n }\n if(attack && hit(accuracy)){\n enemy.lowerHp(damage);\n }\n else{\n if(hit(accuracy)){\n //DO STATUS EFFECT STUFF HERE (ill figure out later)\n }\n\n }\n lowerM1PP();\n }", "public void dropExplosives() {\n // Updates the time elapsed for each of the explosives\n for (int i=0; i<this.explosives.size(); i++) {\n Explosive dormantExplosive = this.explosives.get(i);\n dormantExplosive.increaseTime();\n }\n // If the Airplane has reached the end, doesn't detect any enemies\n // Isn't deleted straight away as it needs to wait for explosives to detonate\n if (super.outOfBounds()) {return;}\n this.timeElapsedDrop += ShadowDefend.getTimescale()/FPS;\n //Adds a new explosive\n if (this.timeElapsedDrop >= this.dropTime) {\n this.timeElapsedDrop = 0;\n Explosive newExplosive = new Explosive(super.getCenter());\n // Centers the explosive at the airplane's current position\n newExplosive.centerRectAt(super.getCenter());\n this.explosives.add(newExplosive);\n // Generates a new drop time in range\n this.dropTime = generateDropTime();\n this.numDropped++;\n }\n\n }", "public void move4(Pokemon enemy){\n boolean crit = false;\n boolean superEffective = false;\n boolean reduced = false;\n boolean moveHit = true;\n int randCrit = (int)(22 * Math.random()+1);\n\n //CHANGE ATTACK TO FALSE IF MOVE DOES NO DAMAGE<<<<<<<<<<<<<\n boolean attack = true;\n //CHANGE TYPE TO TYPE OF MOVE POWER AND ACCURACY<<<<<<<<<<<<<\n String type = \"Steel\";\n int power = 50;\n int accuracy = 95;\n\n //DO NOT CHANGE BELOW THIS\n int damage = ((CONSTANT * power * ( getAtt() / enemy.getDef() )) /50);\n if(randCrit == CONSTANT){\n damage = damage * 2;\n crit = true;\n }\n if(checkSE(type,enemy.getType())){\n damage = damage * 2;\n superEffective = true;\n }\n if(checkNVE(type, enemy.getType())){\n damage = damage / 2;\n reduced = true;\n }\n if(attack && hit(accuracy)){\n enemy.lowerHp(damage);\n }\n else{\n if(hit(accuracy)){\n //DO STATUS EFFECT STUFF HERE (ill figure out later)\n }\n }\n lowerM4PP();\n }", "private static void attack(RobotInfo target) throws GameActionException {\n if (SOLDIER_DEBUG) {\n System.out.println(\"attacking\");\n }\n BulletInfo[] bullets = rc.senseNearbyBullets(EvasiveSoldier.BULLET_DETECT_RADIUS);\n RobotInfo[] robots = rc.senseNearbyRobots(EvasiveSoldier.ENEMY_DETECT_RADIUS);\n MapLocation targetLocation = target.getLocation();\n move(bullets, robots, targetLocation);\n //RobotUtils.tryMoveDestination(targetLocation);\n if (TargetingUtils.clearShot(here, target) || (rc.getType() == RobotType.GARDENER && rc.getOpponentVictoryPoints() > 10)) {\n if (SOLDIER_DEBUG) {\n System.out.println(\"clearShot to target\");\n }\n Direction towardsEnemy = here.directionTo(targetLocation);\n float distanceEnemy = here.distanceTo(targetLocation);\n if (distanceEnemy <= 3.5 && rc.canFirePentadShot() && rc.getTeamBullets() > 200) {\n rc.firePentadShot(towardsEnemy);\n }\n else {\n if (rc.canFireTriadShot() && rc.getTeamBullets() > 50) {\n rc.fireTriadShot(towardsEnemy);\n }\n else if (rc.canFireSingleShot()) {\n rc.fireSingleShot(towardsEnemy);\n }\n }\n }\n }", "public void resetHealth(){\n curHp = healthPoint;\n }", "public void deductHealth(int h) {\n setHealth(getHealth() - h);\n }", "public void die() {\r\n\t\tlives--;\r\n\t\thp = maxHp;\r\n\t}", "public void takedmg(int dmg){\n curHp -= dmg;\n }", "public void startExecuting() {\n this.attackTime = 20;\n ShulkerEntity.this.updateArmorModifier(100);\n }", "public void update() {\r\n super.update();\r\n life -= 1;\r\n if(life <= 0) {\r\n killBullet();\r\n }\r\n }", "public int takeDamage(int damage) {\n damage -= ARMOR;\r\n // set new hp\r\n return super.takeDamage(damage);\r\n }", "public void setCombatTask() {\n\t\tif (this.level != null && !this.level.isClientSide) {\n\t\t\tthis.goalSelector.removeGoal(this.aiAttackOnCollide);\n\t\t\tthis.goalSelector.removeGoal(this.aiShotgunAttack);\n\t\t\tItemStack itemstack = this.getItemInHand(ProjectileHelper.getWeaponHoldingHand(this, DeferredRegistryHandler.BLUNDERBUSS.get()));\n\t\t\tif (itemstack.getItem() == DeferredRegistryHandler.BLUNDERBUSS.get()) {\n\t\t\t\tint i = 25;\n\t\t\t\tif (this.level.getDifficulty() != Difficulty.HARD) {\n\t\t\t\t\ti = 45;\n\t\t\t\t}\n\n\t\t\t\tthis.aiShotgunAttack.setAttackCooldown(i);\n\t\t\t\tthis.goalSelector.addGoal(16, this.aiShotgunAttack);\n\t\t\t} else {\n\t\t\t\tthis.goalSelector.addGoal(12, this.aiAttackOnCollide);\n\t\t\t}\n\n\t\t}\n\t}", "public void healPokemon() {\r\n\t\tfor (Pokemon p : ownedPokemon) {\r\n\t\t\tp.resetCurrentHP();\r\n\t\t}\r\n\t}", "@Override\n public void hp(){\n HP=50*nivel;\n }", "public void attack() {\n\t\t\n\t\tint row = getPosition().getRow();\n\t\tint column = getPosition().getColumn();\n\t\t\n\t\tgetPosition().setCoordinates(row + 1, column);\n\t\tsetPosition(getPosition()) ;\n\t\t// restore health\n\t\tsetHealth(100);\n\t\t// end hunter mode\n\t\tthis.hunter = false;\n\t\t\n\t}", "public void takeDamage(int damage) {\r\n health -= damage;\r\n if(health<=0)setAlive(false);\r\n }", "public void buyHealth() {\n this.healthMod++;\n heathMax += 70 * healthMod;\n }", "public void damaged() {\n this.damageState = DamageState.DAMAGED;\n }", "public void cleanupBattle(List<Enemy> defeatedEnemies){\r\n Character character = world.getCharacter();\r\n updateAllies();\r\n\r\n ArrayList<MovingEntity> deadFriendlies = new ArrayList<MovingEntity>();\r\n for (MovingEntity friendly: world.getFriendlyEntities()) {\r\n if (friendly.getCurrHP() <= 0) {\r\n deadFriendlies.add(friendly);\r\n friendly.destroy();\r\n }\r\n }\r\n world.getFriendlyEntities().removeAll(deadFriendlies);\r\n\r\n \r\n //ArrayList<Enemy> defeatedEnemies = battle.getDefeated();\r\n for(Enemy defeatedEnemy : defeatedEnemies) {\r\n killEnemy(defeatedEnemy);\r\n }\r\n\r\n if (character.getCurrHP() <= 0) {\r\n world.setGameStateLose();\r\n }\r\n }", "void defendAttack(IUnit attacker, int incomingDamage);", "public void attemptAttack() {\r\n\t\tattackAttempts += 100;\r\n\t}", "@Deprecated\n/* */ protected static boolean performAttack(int pos, boolean aiming, Creature performer, Skills performerSkills, Creature defender, Skills defenderSkills, Item attWeapon, Item defPrimWeapon, double attBonus, double defBonus, Skill attackerFightSkill, Skill defenderFightSkill, int counter) {\n/* 829 */ boolean shieldBlocked = false;\n/* 830 */ boolean done = false;\n/* 831 */ Skill primWeaponSkill = null;\n/* 832 */ Skill defPrimWeaponSkill = null;\n/* 833 */ Item defShield = null;\n/* 834 */ Skill defShieldSkill = null;\n/* 835 */ int skillnum = -10;\n/* 836 */ boolean dryrun = false;\n/* */ \n/* 838 */ if (performer.isPlayer()) {\n/* */ \n/* 840 */ if (defender.isPlayer() || defender.isReborn()) {\n/* */ \n/* */ \n/* 843 */ dryrun = true;\n/* */ }\n/* 845 */ else if (defender.isKingdomGuard() || (defender\n/* 846 */ .isSpiritGuard() && defender.getKingdomId() == performer.getKingdomId())) {\n/* 847 */ dryrun = true;\n/* */ } \n/* 849 */ } else if (performer.isKingdomGuard() || (performer\n/* 850 */ .isSpiritGuard() && defender.getKingdomId() == performer.getKingdomId())) {\n/* 851 */ dryrun = true;\n/* 852 */ } if ((defender.isPlayer() && !defender.hasLink()) || (performer.isPlayer() && !performer.hasLink()))\n/* 853 */ dryrun = true; \n/* 854 */ if (defender.getStatus().getStunned() > 0.0F) {\n/* */ \n/* 856 */ defBonus -= 20.0D;\n/* 857 */ attBonus += 20.0D;\n/* */ } \n/* 859 */ if (attWeapon != null)\n/* */ {\n/* 861 */ if (attWeapon.isBodyPart()) {\n/* */ \n/* */ \n/* */ try {\n/* 865 */ skillnum = 10052;\n/* 866 */ primWeaponSkill = performerSkills.getSkill(skillnum);\n/* */ }\n/* 868 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 870 */ if (skillnum != -10)\n/* 871 */ primWeaponSkill = performerSkills.learn(skillnum, 1.0F); \n/* */ } \n/* 873 */ if (performer.isPlayer() && defender.isPlayer())\n/* */ {\n/* 875 */ if (primWeaponSkill.getKnowledge(0.0D) >= 20.0D) {\n/* 876 */ dryrun = true;\n/* */ }\n/* */ }\n/* */ } else {\n/* */ \n/* */ \n/* */ try {\n/* 883 */ skillnum = attWeapon.getPrimarySkill();\n/* 884 */ primWeaponSkill = performerSkills.getSkill(skillnum);\n/* */ }\n/* 886 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 888 */ if (skillnum != -10) {\n/* 889 */ primWeaponSkill = performerSkills.learn(skillnum, 1.0F);\n/* */ }\n/* */ } \n/* */ } \n/* */ }\n/* */ \n/* */ \n/* 896 */ skillnum = -10;\n/* 897 */ if (defPrimWeapon != null)\n/* */ {\n/* 899 */ if (defPrimWeapon.isBodyPart()) {\n/* */ \n/* */ \n/* */ try {\n/* 903 */ skillnum = 10052;\n/* 904 */ defPrimWeaponSkill = defenderSkills.getSkill(skillnum);\n/* */ }\n/* 906 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 908 */ if (skillnum != -10)\n/* 909 */ defPrimWeaponSkill = defenderSkills.learn(skillnum, 1.0F); \n/* */ } \n/* 911 */ if (performer.isPlayer() && defender.isPlayer())\n/* */ {\n/* 913 */ if (defPrimWeaponSkill.getKnowledge(0.0D) >= 20.0D) {\n/* 914 */ dryrun = true;\n/* */ }\n/* */ }\n/* */ } else {\n/* */ \n/* */ \n/* */ try {\n/* 921 */ skillnum = defPrimWeapon.getPrimarySkill();\n/* 922 */ defPrimWeaponSkill = defenderSkills.getSkill(skillnum);\n/* */ }\n/* 924 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 926 */ if (skillnum != -10) {\n/* 927 */ defPrimWeaponSkill = defenderSkills.learn(skillnum, 1.0F);\n/* */ }\n/* */ } \n/* */ } \n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 939 */ Skill attStrengthSkill = null;\n/* */ \n/* */ try {\n/* 942 */ attStrengthSkill = performerSkills.getSkill(102);\n/* */ }\n/* 944 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 946 */ attStrengthSkill = performerSkills.learn(102, 1.0F);\n/* 947 */ logger.log(Level.WARNING, performer.getName() + \" had no strength. Weird.\");\n/* */ } \n/* */ \n/* 950 */ double bonus = 0.0D;\n/* 951 */ if (primWeaponSkill != null) {\n/* */ \n/* 953 */ float mod = getMod(performer, defender, primWeaponSkill);\n/* 954 */ bonus = Math.max(-20.0D, primWeaponSkill.skillCheck(\n/* 955 */ Math.abs(primWeaponSkill.getKnowledge(0.0D) - attWeapon.getCurrentQualityLevel()), attBonus, (mod == 0.0F || dryrun), \n/* 956 */ (float)(long)Math.max(1.0F, counter * mod)));\n/* */ } \n/* */ \n/* */ \n/* 960 */ skillnum = -10;\n/* 961 */ defShield = defender.getShield();\n/* 962 */ if (defShield != null) {\n/* */ \n/* */ try {\n/* */ \n/* 966 */ skillnum = defShield.getPrimarySkill();\n/* 967 */ defShieldSkill = defenderSkills.getSkill(skillnum);\n/* */ }\n/* 969 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 971 */ if (skillnum != -10) {\n/* 972 */ defShieldSkill = defenderSkills.learn(skillnum, 1.0F);\n/* */ }\n/* */ } \n/* */ }\n/* 976 */ if (aiming) {\n/* */ \n/* 978 */ if (pos == 1) {\n/* */ \n/* 980 */ bonus = -60.0D;\n/* */ }\n/* 982 */ else if (pos == 29) {\n/* */ \n/* 984 */ bonus = -80.0D;\n/* */ }\n/* 986 */ else if (pos == 2) {\n/* */ \n/* 988 */ bonus = -40.0D;\n/* */ }\n/* 990 */ else if (pos == 3) {\n/* */ \n/* 992 */ bonus = -30.0D;\n/* */ }\n/* 994 */ else if (pos == 4) {\n/* */ \n/* 996 */ bonus = -30.0D;\n/* */ }\n/* 998 */ else if (pos == 34) {\n/* */ \n/* 1000 */ bonus = -30.0D;\n/* */ } \n/* 1002 */ pos = getRealPosition(pos);\n/* */ } else {\n/* */ \n/* */ \n/* */ try {\n/* */ \n/* 1008 */ pos = defender.getBody().getRandomWoundPos();\n/* */ }\n/* 1010 */ catch (Exception ex) {\n/* */ \n/* 1012 */ logger.log(Level.WARNING, \"Problem getting a Random Wound Position for \" + defender.getName() + \": due to \" + ex\n/* 1013 */ .getMessage(), ex);\n/* */ } \n/* */ } \n/* 1016 */ if (performer.getEnemyPresense() > 1200 && defender.isPlayer())\n/* 1017 */ bonus += 20.0D; \n/* 1018 */ double attCheck = 0.0D;\n/* 1019 */ boolean defFumbleShield = false;\n/* 1020 */ boolean defFumbleParry = false;\n/* */ \n/* 1022 */ boolean crit = false;\n/* */ \n/* 1024 */ if (defender.isPlayer()) {\n/* */ \n/* 1026 */ int critChance = attWeapon.getDamagePercent();\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1032 */ if (Server.rand.nextInt(100 - Math.min(3, critChance)) == 0)\n/* */ {\n/* 1034 */ crit = true;\n/* */ }\n/* */ } \n/* */ \n/* */ \n/* 1039 */ if (attWeapon.isBodyPartAttached()) {\n/* */ \n/* 1041 */ float mod = getMod(performer, defender, attackerFightSkill);\n/* */ \n/* 1043 */ attCheck = attackerFightSkill.skillCheck(defenderFightSkill\n/* 1044 */ .getKnowledge(defBonus) / Math.min(5, defender.getAttackers()), bonus, (mod == 0.0F || dryrun), \n/* 1045 */ (float)(long)Math.max(1.0F, counter * mod));\n/* */ }\n/* */ else {\n/* */ \n/* 1049 */ float mod = getMod(performer, defender, attackerFightSkill);\n/* 1050 */ attCheck = attackerFightSkill.skillCheck(defenderFightSkill\n/* 1051 */ .getKnowledge(defBonus) / Math.min(5, defender.getAttackers()), attWeapon, bonus, (mod == 0.0F || dryrun), \n/* 1052 */ (float)(long)Math.max(1.0F, counter * mod));\n/* */ } \n/* 1054 */ byte type = (performer.getTemplate()).combatDamageType;\n/* 1055 */ if (attWeapon.isWeaponSword()) {\n/* */ \n/* 1057 */ if (Server.rand.nextInt(2) == 0) {\n/* 1058 */ type = 1;\n/* */ } else {\n/* 1060 */ type = 2;\n/* */ } \n/* 1062 */ } else if (attWeapon.isWeaponSlash()) {\n/* 1063 */ type = 1;\n/* 1064 */ } else if (attWeapon.isWeaponPierce()) {\n/* 1065 */ type = 2;\n/* 1066 */ } else if (attWeapon.isBodyPart()) {\n/* */ \n/* 1068 */ if (attWeapon.getTemplateId() == 17) {\n/* 1069 */ type = 3;\n/* 1070 */ } else if (attWeapon.getTemplateId() == 12) {\n/* 1071 */ type = 0;\n/* */ } \n/* */ } \n/* 1074 */ String attString = getAttackString(performer, attWeapon, type);\n/* */ \n/* */ \n/* */ \n/* */ \n/* 1079 */ double defCheck = 0.0D;\n/* 1080 */ double damage = getWeaponDamage(attWeapon, attStrengthSkill);\n/* */ \n/* 1082 */ if (performer.getDeity() != null && performer.getDeity().isWarrior() && \n/* 1083 */ performer.getFaith() >= 40.0F && performer.getFavor() >= 20.0F)\n/* 1084 */ damage = Math.min(4000.0D, damage * 1.25D); \n/* 1085 */ if (performer.getEnemyPresense() > 1200 && defender.isPlayer()) {\n/* 1086 */ damage *= Math.min(4000.0F, 1.15F);\n/* */ }\n/* */ \n/* 1089 */ if (defShield != null || crit) {\n/* */ \n/* 1091 */ if (!crit)\n/* */ {\n/* 1093 */ if (pos == 9) {\n/* */ \n/* 1095 */ shieldBlocked = true;\n/* */ }\n/* 1097 */ else if (defender.getStatus().getStamina() >= 300 && !defender.isMoving()) {\n/* */ \n/* 1099 */ defCheck = 0.0D;\n/* 1100 */ if (defShieldSkill != null) {\n/* */ \n/* 1102 */ float mod = getMod(performer, defender, defShieldSkill);\n/* 1103 */ defCheck = defShieldSkill.skillCheck(attCheck, defShield, defBonus, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ } \n/* */ \n/* */ \n/* 1107 */ defCheck += (defShield.getSizeY() + defShield.getSizeZ()) / 10.0D;\n/* */ \n/* */ \n/* 1110 */ defender.getStatus().modifyStamina(-300.0F);\n/* */ } \n/* */ }\n/* 1113 */ if (defCheck > 0.0D || shieldBlocked) {\n/* */ \n/* 1115 */ shieldBlocked = true;\n/* 1116 */ if (defender.isPlayer()) {\n/* 1117 */ defShield.setDamage(defShield.getDamage() + 0.001F * (float)damage * defShield.getDamageModifier());\n/* */ }\n/* */ }\n/* 1120 */ else if (defCheck < -90.0D) {\n/* */ \n/* 1122 */ defFumbleShield = true;\n/* */ } \n/* */ } \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1134 */ if (!shieldBlocked || crit) {\n/* */ \n/* 1136 */ boolean parryPrimWeapon = true;\n/* 1137 */ defCheck = 0.0D;\n/* 1138 */ if (!crit && !defender.isMoving()) {\n/* */ \n/* 1140 */ int parryTime = 100;\n/* 1141 */ if (defender.getFightStyle() == 2) {\n/* 1142 */ parryTime = 40;\n/* 1143 */ } else if (defender.getFightStyle() == 1) {\n/* 1144 */ parryTime = 160;\n/* */ } \n/* 1146 */ if (WurmCalendar.currentTime > defender.lastParry + Server.rand.nextInt(parryTime) && \n/* 1147 */ defPrimWeapon != null && !defPrimWeapon.isWeaponAxe())\n/* */ {\n/* 1149 */ if (!defPrimWeapon.isBodyPart() || defPrimWeapon.getAuxData() == 100) {\n/* */ \n/* 1151 */ if (defender.getStatus().getStamina() >= 300) {\n/* */ \n/* 1153 */ if (defPrimWeaponSkill != null) {\n/* */ \n/* 1155 */ float mod = getMod(performer, defender, defPrimWeaponSkill);\n/* 1156 */ defCheck = defPrimWeaponSkill.skillCheck((attCheck * defender\n/* 1157 */ .getAttackers() + defPrimWeapon.getWeightGrams() / 200.0D) / \n/* 1158 */ getWeaponParryBonus(defPrimWeapon), defPrimWeapon, defBonus, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ \n/* 1160 */ defender.lastParry = WurmCalendar.currentTime;\n/* 1161 */ defender.getStatus().modifyStamina(-300.0F);\n/* */ } \n/* 1163 */ if (defCheck < -90.0D)\n/* */ {\n/* 1165 */ defFumbleParry = true;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ }\n/* 1182 */ else if (defCheck < 0.0D && Server.rand.nextInt(50) == 0)\n/* */ {\n/* 1184 */ defCheck = secondaryParry(performer, attCheck, defender, defenderSkills, defCheck, defBonus, dryrun);\n/* */ \n/* 1186 */ if (defCheck < -90.0D) {\n/* */ \n/* 1188 */ defFumbleParry = true;\n/* */ }\n/* 1190 */ else if (defCheck > 0.0D) {\n/* 1191 */ parryPrimWeapon = false;\n/* */ }\n/* */ \n/* */ }\n/* */ \n/* */ } \n/* 1197 */ } else if (defender.getStatus().getStamina() >= 300) {\n/* */ \n/* 1199 */ if (defPrimWeaponSkill != null) {\n/* */ \n/* */ \n/* */ \n/* */ \n/* 1204 */ float mod = getMod(performer, defender, defPrimWeaponSkill);\n/* 1205 */ defCheck = defPrimWeaponSkill.skillCheck(Math.min(100, 80 * defender.getAttackers()), defBonus, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ \n/* 1207 */ defender.lastParry = WurmCalendar.currentTime;\n/* 1208 */ defender.getStatus().modifyStamina(-300.0F);\n/* */ } \n/* 1210 */ if (defCheck < 0.0D && Server.rand.nextInt(50) == 0) {\n/* */ \n/* 1212 */ defCheck = secondaryParry(performer, attCheck, defender, defenderSkills, defCheck, defBonus, dryrun);\n/* */ \n/* 1214 */ if (defCheck < -90.0D) {\n/* */ \n/* 1216 */ defFumbleParry = true;\n/* */ }\n/* 1218 */ else if (defCheck > 0.0D) {\n/* 1219 */ parryPrimWeapon = false;\n/* */ } \n/* */ } \n/* */ } \n/* */ }\n/* */ } \n/* 1225 */ if (defCheck <= 0.0D || defFumbleShield || crit) {\n/* */ \n/* */ \n/* */ \n/* 1229 */ if (!defFumbleShield && !defFumbleParry && !crit)\n/* */ {\n/* 1231 */ if (defender.getStatus().getStamina() >= 300) {\n/* */ \n/* 1233 */ defender.getStatus().modifyStamina(-300.0F);\n/* 1234 */ Skill defenderBodyControl = null;\n/* */ \n/* */ try {\n/* 1237 */ defenderBodyControl = defenderSkills.getSkill(104);\n/* */ }\n/* 1239 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 1241 */ defenderBodyControl = defenderSkills.learn(104, 1.0F);\n/* 1242 */ logger.log(Level.WARNING, defender.getName() + \" no body control?\");\n/* */ } \n/* 1244 */ if (defenderBodyControl != null) {\n/* */ \n/* 1246 */ float mod = getMod(performer, defender, defenderBodyControl);\n/* 1247 */ defCheck = defenderBodyControl.skillCheck(attCheck, 0.0D, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ } else {\n/* */ \n/* 1250 */ logger.log(Level.WARNING, defender.getName() + \" has no body control!\");\n/* */ } \n/* */ } } \n/* 1253 */ if (defCheck <= 0.0D || crit) {\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1261 */ Item armour = null;\n/* */ \n/* */ \n/* 1264 */ float armourMod = defender.getArmourMod();\n/* 1265 */ float evasionChance = ArmourTemplate.calculateGlanceRate(defender.getArmourType(), armour, type, armourMod);\n/* 1266 */ if (!performer.isPlayer() && !defender.isPlayer() && !defender.isUnique())\n/* 1267 */ armourMod = 1.0F; \n/* 1268 */ if (armourMod == 1.0F) {\n/* */ \n/* */ try {\n/* */ \n/* 1272 */ byte bodyPosition = ArmourTemplate.getArmourPosition((byte)pos);\n/* 1273 */ armour = defender.getArmour(bodyPosition);\n/* 1274 */ armourMod = ArmourTemplate.calculateDR(armour, type);\n/* 1275 */ if (defender.isPlayer())\n/* 1276 */ armour.setDamage(armour.getDamage() + \n/* 1277 */ Math.min(1.0F, (float)(damage * armourMod / 80.0D) * armour\n/* */ \n/* 1279 */ .getDamageModifier() * \n/* 1280 */ ArmourTemplate.getArmourDamageModFor(armour, type))); \n/* 1281 */ checkEnchantDestruction(attWeapon, armour, defender);\n/* 1282 */ evasionChance = ArmourTemplate.calculateGlanceRate(null, armour, type, armourMod);\n/* */ }\n/* 1284 */ catch (NoArmourException nsi) {\n/* */ \n/* */ \n/* 1287 */ evasionChance = 1.0F - defender.getArmourMod();\n/* */ }\n/* 1289 */ catch (NoSpaceException nsp) {\n/* */ \n/* 1291 */ logger.log(Level.WARNING, defender.getName() + \" no armour space on loc \" + pos);\n/* */ } \n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1299 */ if (!attWeapon.isBodyPart() || attWeapon.getAuxData() == 100)\n/* */ {\n/* 1301 */ if (performer.isPlayer())\n/* 1302 */ attWeapon.setDamage(attWeapon.getDamage() + (float)(damage * (2.1D - armourMod) / 1000.0D) * attWeapon\n/* 1303 */ .getDamageModifier()); \n/* */ }\n/* 1305 */ if (defender.isUnique()) {\n/* */ \n/* 1307 */ evasionChance = 0.5F;\n/* 1308 */ damage *= armourMod;\n/* */ } \n/* 1310 */ if (Server.rand.nextFloat() < evasionChance) {\n/* */ \n/* 1312 */ if (aiming || performer.spamMode())\n/* 1313 */ performer.getCommunicator().sendNormalServerMessage(\"Your attack glances off \" + defender\n/* 1314 */ .getNameWithGenus() + \"'s armour.\"); \n/* 1315 */ if (defender.spamMode()) {\n/* 1316 */ defender.getCommunicator().sendNormalServerMessage(\"The attack to the \" + defender\n/* 1317 */ .getBody().getWoundLocationString(pos) + \" glances off your armour.\");\n/* */ }\n/* */ }\n/* 1320 */ else if (damage > (5.0F + Server.rand.nextFloat() * 5.0F) || crit) {\n/* */ \n/* 1322 */ if (crit)\n/* */ {\n/* 1324 */ armourMod = 1.0F;\n/* */ }\n/* */ \n/* */ \n/* 1328 */ Battle battle = performer.getBattle();\n/* 1329 */ boolean dead = false;\n/* 1330 */ if (defender.getStaminaSkill().getKnowledge(0.0D) < 2.0D) {\n/* */ \n/* 1332 */ defender.die(false, \"Combat Stam Check Fail\");\n/* 1333 */ dead = true;\n/* */ } else {\n/* */ \n/* 1336 */ dead = addWound(performer, defender, type, pos, damage, armourMod, attString, battle, 0.0F, 0.0F, false, false, false, false);\n/* */ } \n/* 1338 */ if (!dead && attWeapon.getSpellDamageBonus() > 0.0F)\n/* */ {\n/* 1340 */ if (damage * attWeapon.getSpellDamageBonus() / 300.0D > (Server.rand.nextFloat() * 5.0F) || crit) {\n/* 1341 */ dead = defender.addWoundOfType(performer, (byte)4, (byte)pos, false, armourMod, false, damage * attWeapon\n/* 1342 */ .getSpellDamageBonus() / 300.0D, 0.0F, 0.0F, false, false);\n/* */ }\n/* */ }\n/* 1345 */ if (!dead && attWeapon.getWeaponSpellDamageBonus() > 0.0F)\n/* */ {\n/* 1347 */ if (damage * attWeapon.getWeaponSpellDamageBonus() / 300.0D > (Server.rand.nextFloat() * 5.0F))\n/* */ {\n/* 1349 */ dead = defender.addWoundOfType(performer, (byte)6, 1, true, armourMod, false, damage * attWeapon\n/* 1350 */ .getWeaponSpellDamageBonus() / 300.0D, Server.rand\n/* 1351 */ .nextInt((int)attWeapon.getWeaponSpellDamageBonus()), 0.0F, false, false);\n/* */ }\n/* */ }\n/* 1354 */ if (armour != null)\n/* */ {\n/* 1356 */ if (armour.getSpellPainShare() > 0.0F)\n/* */ {\n/* 1358 */ if (performer.isUnique()) {\n/* 1359 */ defender.getCommunicator().sendNormalServerMessage(performer\n/* 1360 */ .getNameWithGenus() + \" ignores the effects of the \" + armour.getName() + \".\");\n/* */ \n/* */ \n/* */ }\n/* 1364 */ else if (damage * armour.getSpellPainShare() / 300.0D > 5.0D) {\n/* */ \n/* 1366 */ addBounceWound(defender, performer, type, pos, damage * armour\n/* 1367 */ .getSpellPainShare() / 300.0D, armourMod, 0.0F, 0.0F, false, true);\n/* */ } \n/* */ }\n/* */ }\n/* */ \n/* */ \n/* */ \n/* 1374 */ if (dead) {\n/* */ \n/* 1376 */ performer.getCommunicator().sendSafeServerMessage(defender.getNameWithGenus() + \" is dead!\");\n/* 1377 */ if (battle != null)\n/* 1378 */ battle.addCasualty(performer, defender); \n/* 1379 */ done = true;\n/* */ \n/* */ \n/* */ }\n/* 1383 */ else if (!defender.hasNoServerSound()) {\n/* 1384 */ SoundPlayer.playSound(defender.getHitSound(), defender, 1.6F);\n/* */ }\n/* */ \n/* */ } else {\n/* */ \n/* 1389 */ if (aiming || performer.spamMode())\n/* */ {\n/* 1391 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1392 */ .getNameWithGenus() + \" takes no real damage from the hit to the \" + defender\n/* 1393 */ .getBody().getWoundLocationString(pos) + \".\");\n/* */ }\n/* 1395 */ if (defender.spamMode()) {\n/* 1396 */ defender.getCommunicator().sendNormalServerMessage(\"You take no real damage from the blow to the \" + defender\n/* */ \n/* 1398 */ .getBody().getWoundLocationString(pos) + \".\");\n/* */ }\n/* */ } \n/* */ } else {\n/* */ \n/* 1403 */ String sstring = \"sound.combat.miss.light\";\n/* 1404 */ if (attCheck < -80.0D) {\n/* 1405 */ sstring = \"sound.combat.miss.heavy\";\n/* 1406 */ } else if (attCheck < -40.0D) {\n/* 1407 */ sstring = \"sound.combat.miss.med\";\n/* 1408 */ } SoundPlayer.playSound(sstring, defender, 1.6F);\n/* 1409 */ if (aiming || performer.spamMode())\n/* */ {\n/* 1411 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1412 */ .getNameWithGenus() + \" \" + getParryString(defCheck) + \" evades the blow to the \" + defender\n/* 1413 */ .getBody().getWoundLocationString(pos) + \".\");\n/* */ }\n/* 1415 */ if (defender.spamMode()) {\n/* 1416 */ defender.getCommunicator().sendNormalServerMessage(\"You \" + \n/* 1417 */ getParryString(defCheck) + \" evade the blow to the \" + defender\n/* 1418 */ .getBody().getWoundLocationString(pos) + \".\");\n/* */ }\n/* */ } \n/* */ } else {\n/* */ \n/* 1423 */ defender.lastParry = WurmCalendar.currentTime;\n/* 1424 */ Item weapon = defPrimWeapon;\n/* 1425 */ if (!parryPrimWeapon)\n/* 1426 */ weapon = defender.getLefthandWeapon(); \n/* 1427 */ if (aiming || performer.spamMode())\n/* */ {\n/* 1429 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1430 */ .getNameWithGenus() + \" \" + getParryString(defCheck) + \" parries with \" + weapon.getNameWithGenus() + \".\");\n/* */ }\n/* */ \n/* */ \n/* 1434 */ if (defender.spamMode())\n/* */ {\n/* 1436 */ defender.getCommunicator().sendNormalServerMessage(\"You \" + \n/* 1437 */ getParryString(defCheck) + \" parry with your \" + weapon.getName() + \".\");\n/* */ }\n/* */ \n/* 1440 */ if (!weapon.isBodyPart() || weapon.getAuxData() == 100) {\n/* */ \n/* 1442 */ if (defender.isPlayer())\n/* */ {\n/* 1444 */ if (weapon.isWeaponSword()) {\n/* 1445 */ weapon.setDamage(weapon.getDamage() + 0.001F * (float)damage * weapon.getDamageModifier());\n/* */ } else {\n/* 1447 */ weapon.setDamage(weapon.getDamage() + 0.005F * (float)damage * weapon.getDamageModifier());\n/* */ } } \n/* 1449 */ if (performer.isPlayer())\n/* */ {\n/* 1451 */ if (!attWeapon.isBodyPart() || attWeapon.getAuxData() == 100) {\n/* 1452 */ attWeapon\n/* 1453 */ .setDamage(attWeapon.getDamage() + 0.001F * (float)damage * attWeapon.getDamageModifier());\n/* */ }\n/* */ }\n/* */ } \n/* 1457 */ String sstring = \"sound.combat.parry1\";\n/* 1458 */ int x = Server.rand.nextInt(3);\n/* 1459 */ if (x == 0) {\n/* 1460 */ sstring = \"sound.combat.parry2\";\n/* 1461 */ } else if (x == 1) {\n/* 1462 */ sstring = \"sound.combat.parry3\";\n/* 1463 */ } SoundPlayer.playSound(sstring, defender, 1.6F);\n/* 1464 */ checkEnchantDestruction(attWeapon, weapon, defender);\n/* */ }\n/* */ \n/* */ } else {\n/* */ \n/* 1469 */ if (performer.spamMode()) {\n/* */ \n/* 1471 */ if (aiming) {\n/* 1472 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1473 */ .getNameWithGenus() + \" raises \" + defender.getHisHerItsString() + \" shield and parries.\");\n/* */ } else {\n/* 1475 */ performer.getCommunicator().sendNormalServerMessage(\"You try to \" + attString + \" \" + defender\n/* 1476 */ .getNameWithGenus() + \" but \" + defender.getHeSheItString() + \" raises \" + defender\n/* 1477 */ .getHisHerItsString() + \" shield and parries.\");\n/* */ } \n/* 1479 */ } else if (aiming) {\n/* 1480 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1481 */ .getNameWithGenus() + \" raises \" + defender.getHisHerItsString() + \" shield and parries.\");\n/* 1482 */ } if (defender.spamMode())\n/* 1483 */ defender.getCommunicator().sendNormalServerMessage(performer\n/* 1484 */ .getNameWithGenus() + \" tries to \" + attString + \" you but you raise your shield and parry.\"); \n/* 1485 */ if (defShield.isWood()) {\n/* 1486 */ Methods.sendSound(defender, \"sound.combat.shield.wood\");\n/* */ } else {\n/* 1488 */ Methods.sendSound(defender, \"sound.combat.shield.metal\");\n/* 1489 */ } checkEnchantDestruction(attWeapon, defShield, defender);\n/* */ } \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1510 */ return done;\n/* */ }", "private void attackPlayer()\n\t{\n\t\tif(shootTimer.done())\n\t\t{\n\t\t\tProjectile spiderWeb = new SpiderWeb(x, y);\n\t\t\tGame.objectWaitingRoom.add(spiderWeb);\n\t\t\tspiderWeb.shoot();\n\t\t\tshootTimer.setTime(200);\n\t\t}\n\t}", "public void resetHp();", "public void damagePlayer(int damage){\n hero.decreaseHp(damage);\n }", "public void breath() {\n\t\tif (alive) {\n\t\t\t_age++;\n\t\t\t// Respiration process\n\t\t\tboolean canBreath = useEnergy(Math.min((_mass - _lowmaintenance) / Utils.SEGMENT_COST_DIVISOR, _energy));\n\t\t\tif ((_age >> 8) > _geneticCode.getMaxAge() || !canBreath) {\n\t\t\t\t// It's dead, but still may have energy\n\t\t\t\tdie(null);\n\t\t\t} else {\n\t\t\t\tif (_energy <= Utils.tol) {\n\t\t\t\t\talive = false;\n\t\t\t\t\t_world.decreasePopulation();\n\t\t\t\t\t_world.organismHasDied(this, null);\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\t// The corpse slowly decays\n\t\t\tuseEnergy(Math.min(_energy, Utils.DECAY_ENERGY));\n\t\t}\n\t}", "@Override\n public void doStrategy(final Pyromancer pyromancer) {\n int hpLoss = pyromancer.getHP() / Constants.PYROMANCER_STRATEGY_HP_LOSS;\n pyromancer.reduceHP(hpLoss);\n pyromancer.increaseRaceMod(Constants.DAMAGE_MOD_70);\n }", "private void resetCooldown() {\n nextAttack = tower.getFireFrequency();\n }", "@Override\r\n\tpublic void useSkill() {\n\t\tthis.defense+=20;\r\n\t\tthis.maxHp+=(this.maxHp/2);\r\n\t\tthis.hp+=(this.hp/2);\r\n\t\tthis.skillActive = true;\r\n\t\tthis.skillLast = 2;\r\n\t}", "public void performAttack(){\r\n // For every zombie\r\n for (int i = 0 ; i < allZombies.getZombies().size(); i++) {\r\n // Variables used to prevent long getter lines\r\n int zombieX = allZombies.getZombies().get(i).getCurrX();\r\n int zombieY = allZombies.getZombies().get(i).getCurrY();\r\n Zombie zombie = allZombies.getZombies().get(i);\r\n // If the zombie is in range and alive:\r\n if(isInRange(zombieX,zombieY) && zombie.isAlive()) {\r\n // kill the zombie and increase score by 1.\r\n allZombies.getZombies().get(i).setAlive(false);\r\n increaseScore();\r\n }\r\n }\r\n }", "@Override\r\n\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\tfor (Damage damage : actionAttack.damages) {\r\n\t\t\t\t\t\t\t\tBattlerSprite attacked = damage.target.getTag();\r\n\t\t\t\t\t\t\t\tattacked.takeHit(damage.damage);\t\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}", "public void updateAllies(){\r\n List<Ally> allies = world.getAllies();\r\n ArrayList<Ally> deadAllies = new ArrayList<Ally>();\r\n for(Ally ally : allies){\r\n if(ally.getCurrHP() <= 0){\r\n deadAllies.add(ally);\r\n }\r\n }\r\n\r\n allies.removeAll(deadAllies);\r\n world.setNumAllies(allies.size());\r\n //numAllies.set(allies.size());\r\n }", "public void resetHP(){\r\n this.currHP = this.maxHP;\r\n }", "public final void applyDamage(DamageDTO damage) {\n int rolledDamage = damage.getMaxDamage();\n if (rolledDamage > 0) {\n this.currentHitPoints -= rolledDamage;\n }\n if (this.currentHitPoints <= 0) {\n this.die();\n }\n }", "protected void attack(){\n\t\tif(reloadTime-- <= 0){\n\t\t\treloadTime = 0;\n\t\t}\n\t\tif(!hostileInRange())\n\t\t\treturn;\n\t\tif(!rotate()){\n\t\t\tif(reloadTime <= 0){\n\t\t\t\tshotAt(this.target);\n\t\t\t}\n\t\t}\n\t}", "public abstract void performAction(Individual victim) {\n\tvictim.health -= this.performance;\n}", "private void subtractEnemyMissile() {\n this.enemyMissile -= 1;\n }", "@Override\n public void attackedByPaladin(double attack) {\n this.attack += (2 * attack) / 3;\n damageCounter = Math.max(damageCounter - (2 * attack) / 3, 0);\n }", "public String attack() {\r\n\t\t\tthis.getCurrentEnemy().setHealth(this.getCurrentEnemy().getHealth()-this.getPlayer().getWeapon().getAttack());\r\n\t\t\tif(this.getCurrentEnemy().isDefeated()) {\r\n\t\t\t\tthis.setInBattle(false);\r\n\t\t\t\t\r\n\t\t\t\tthis.handleQuestrelatedEnemy(this.getCurrentEnemy());\r\n\t\t\t\t\r\n\t\t\t\tif(this.getCurrentEnemy().getLoot() != null) {\r\n\t\t\t\t\tthis.getPlayer().getCurrentLocation().addItem(this.getCurrentEnemy().getLoot());\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tthis.getPlayer().gainXp(this.getCurrentEnemy().getXpYield());\r\n\t\t\t\tthis.getPlayer().getCurrentLocation().removeNpc(this.getCurrentEnemy().getName());\r\n\t\t\t\tif(this.getCurrentEnemy().getClass().getName().equals(\"game.EnemyGuardian\")) {\r\n\t\t\t\t\t// adds paths between current location and location in the guardian, path names are specified in the guardian construction\r\n\t\t\t\t\tthis.getPlayer().getCurrentLocation().addPaths(this.getPlayer().getCurrentLocation(), ((EnemyGuardian)this.getCurrentEnemy()).getPathTo(),\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t((EnemyGuardian)this.getCurrentEnemy()).getGuardedLocation(), ((EnemyGuardian)this.getCurrentEnemy()).getPathFrom());\r\n\t\t\t\t\treturn \"You defeated \" + this.getCurrentEnemy().getName() + \". \\n\"\r\n\t\t\t\t\t\t\t+ ((EnemyGuardian)this.getCurrentEnemy()).getRevelationMessage() + \"\\n\";\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\treturn \"You defeated \" + this.getCurrentEnemy().getName() + \".\";\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tthis.triggerEnemyAttack();\r\n\t\t\t\t\tif(this.getPlayer().getHealth() <= 0) {\r\n\r\n\t\t\t\t\t\tthis.gameOver();\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\treturn \"You attacked \" + this.getCurrentEnemy().getName() + \" for \" + this.getPlayer().getWeapon().getAttack() + \" damage. \\n You DIED.\";\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse {\r\n\t\t\t\t\t\treturn \"You attacked \" + this.getCurrentEnemy().getName() + \" for \" + this.getPlayer().getWeapon().getAttack() + \" damage. \\n\"\r\n\t\t\t\t\t\t\t\t+ this.getCurrentEnemy().getName() + \" attacked you for \" + this.getCurrentEnemy().getAttack() + \" damage.\\n\"\r\n\t\t\t\t\t\t\t\t\t\t+ this.getCurrentEnemy().printHealth();\r\n\t\t\t\t\t}\r\n\t\t\t}\r\n\t\t}", "public void attackMonster(World world){\n\t\tif ((UnitManager.unitNearPlayer(world.getPlayer(),this,PLAYER_RANGE) == true \n\t\t\t\t\t&& RPG.isAttacking()) && world.getPlayer().isAttack()) {\n\t\t\tthis.getUnitStats().reduceHP(world.getPlayer().damageAmount());\n\t\t\t\n\t\t}else{\n\t\t\t\n\t\t}\n\t}", "@Override\n\tpublic void startCooldown() {\n\t\tthis.setSpecialAttackCooldown(HunterKillerConstants.SOLDIER_COOLDOWN);\n\t}", "@Override\r\n public void onHit(int damage){\n if(box2body != null){\r\n hp -= damage;\r\n screen.getGameManager().get(\"Sounds/orc-34-hit.wav\", Sound.class).play();\r\n if(this.hp <= 0) {\r\n screen.bodiesToDelete.add(box2body);\r\n deleteFlag = true;\r\n screen.spawnedCreatures.remove(this);\r\n screen.getGameManager().get(\"Sounds/orc-32-death.wav\", Sound.class).play();\r\n\r\n //Award Experience\r\n screen.getPlayer().awardExperience(this.experienceValue);\r\n screen.getPlayer().increaseKillCount();\r\n }\r\n }\r\n //Attack player when damaged\r\n //Prevents player from sniping monsters using Wander AI\r\n if(currentState != State.ATTACKING){\r\n Vector2 orcPosition = new Vector2(box2body.getPosition().x, box2body.getPosition().y);\r\n Vector2 playerPosition = new Vector2(screen.getPlayer().box2body.getPosition().x, screen.getPlayer().box2body.getPosition().y);\r\n\r\n currentState = State.HASBEENATTACKED;\r\n velocity = new Vector2(playerPosition.x - orcPosition.x, playerPosition.y - orcPosition.y);\r\n box2body.setLinearVelocity(velocity.scl(speed));\r\n }\r\n }" ]
[ "0.6549416", "0.62663835", "0.6251998", "0.6176661", "0.6165011", "0.61000764", "0.6075032", "0.6067762", "0.60612345", "0.6049582", "0.60486835", "0.6017559", "0.60147285", "0.6007432", "0.59774864", "0.59561384", "0.59395856", "0.59330857", "0.59287727", "0.5912919", "0.5903173", "0.5879162", "0.58762574", "0.5846737", "0.58398604", "0.5829666", "0.5819843", "0.5813931", "0.5813681", "0.5812181", "0.57932764", "0.57856905", "0.57792217", "0.5772691", "0.5771722", "0.5770734", "0.5754889", "0.57421815", "0.57416", "0.57100964", "0.57044995", "0.5704398", "0.5699012", "0.5697179", "0.56904674", "0.5687251", "0.5684484", "0.5671", "0.56629777", "0.5662114", "0.56539404", "0.56410795", "0.563772", "0.56345534", "0.56344134", "0.5630487", "0.56304824", "0.5625242", "0.5613457", "0.5612903", "0.56076217", "0.5604464", "0.560009", "0.559367", "0.55849534", "0.5579354", "0.55769026", "0.5569214", "0.556744", "0.55666006", "0.5562396", "0.5560776", "0.5557024", "0.55510277", "0.5550611", "0.55479395", "0.5544969", "0.5543669", "0.5539861", "0.5535433", "0.55245453", "0.5522124", "0.55214894", "0.55185443", "0.55083454", "0.55043185", "0.55020183", "0.5497381", "0.5496721", "0.549493", "0.5483671", "0.548211", "0.54804164", "0.54801697", "0.5473028", "0.54725826", "0.5468575", "0.54674137", "0.5467352", "0.5466122" ]
0.6824012
0
Kill the L2Attackable (the corpse disappeared after 7 seconds), distribute rewards (EXP, SP, Drops...) and notify Quest Engine. Actions : Distribute Exp and SP rewards to L2PcInstance (including Summon owner) that hit the L2Attackable and to their Party members Notify the Quest Engine of the L2Attackable death if necessary Kill the L2NpcInstance (the corpse disappeared after 7 seconds) Caution : This method DOESN'T GIVE rewards to L2PetInstance
@Override public boolean doDie(final L2Character killer) { // Kill the L2NpcInstance (the corpse disappeared after 7 seconds) if (!super.doDie(killer)) { return false; } // Enhance soul crystals of the attacker if this L2Attackable had its soul absorbed try { if (killer instanceof L2PcInstance) { levelSoulCrystals(killer); } } catch (final Exception e) { LOGGER.error("", e); } // Notify the Quest Engine of the L2Attackable death if necessary try { if (killer instanceof L2PcInstance || killer instanceof L2Summon) { final L2PcInstance player = killer instanceof L2PcInstance ? (L2PcInstance) killer : ((L2Summon) killer).getOwner(); EngineModsManager.onKill(killer, this, killer instanceof L2Summon); // only 1 randomly choosen quest of all quests registered to this character can be applied for (final Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_KILL)) { quest.notifyKill(this, player, killer instanceof L2Summon); } } } catch (final Exception e) { LOGGER.error("", e); } setChampion(false); if (Config.L2JMOD_CHAMPION_ENABLE && Config.L2JMOD_CHAMPION_FREQUENCY > 0) { // Set champion on next spawn if (this.getClass().getSimpleName().equalsIgnoreCase("L2MonsterInstance") && getLevel() >= Config.L2JMOD_CHAMP_MIN_LVL && getLevel() <= Config.L2JMOD_CHAMP_MAX_LVL) { int random = ThreadLocalRandom.current().nextInt(100); if (random < Config.L2JMOD_CHAMPION_FREQUENCY) { setChampion(true); } } } return true; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n protected void onDeath(final Creature killer) {\n getDeathPenalty().checkCharmOfLuck();\n\n if (isInStoreMode()) {\n setPrivateStoreType(Player.STORE_PRIVATE_NONE);\n }\n if (isProcessingRequest()) {\n final Request request = getRequest();\n if (isInTrade()) {\n final Player partner = request.getOtherPlayer(this);\n sendPacket(SendTradeDone.FAIL);\n partner.sendPacket(SendTradeDone.FAIL);\n }\n request.cancel();\n }\n //cubicdata\n deleteCubics();\n deleteAgathion();\n\n boolean checkPvp = true;\n if (ServerConfig.ALLOW_CURSED_WEAPONS) {\n if (isCursedWeaponEquipped()) {\n CursedWeaponsManager.getInstance().dropPlayer(this);\n checkPvp = false;\n } else if (killer != null && killer.isPlayer() && killer.isCursedWeaponEquipped()) {\n CursedWeaponsManager.getInstance().increaseKills(((Player) killer).getCursedWeaponEquippedId());\n checkPvp = false;\n }\n }\n\n if (checkPvp) {\n doPKPVPManage(killer);\n\n altDeathPenalty(killer);\n }\n\n //And in the end of process notify death penalty that owner died :)\n getDeathPenalty().notifyDead(killer);\n\n setIncreasedForce(0);\n\n if (isInParty() && getParty().isInReflection() && getParty().getReflection() instanceof DimensionalRift) {\n ((DimensionalRift) getParty().getReflection()).memberDead(this);\n }\n\n stopWaterTask();\n stopMountFeedTask();\n\n if (!isSalvation() && isOnSiegeField() && isCharmOfCourage()) {\n ask(new ConfirmDlg(SystemMsg.YOUR_CHARM_OF_COURAGE_IS_TRYING_TO_RESURRECT_YOU, 60000), new ReviveAnswerListener(this, 100, false, 60000));\n setCharmOfCourage(false);\n }\n\n if (AllSettingsConfig.AltKillAnnounce && killer != null && killer.isPlayer())\n AnnouncementUtils.announceToAll(killer.getName() + \" убил игрока \" + getName() + \"!\");\n\n super.onDeath(killer);\n }", "@Override\n\tpublic boolean doDie(L2Character killer)\n\t{\n\t\tif(!super.doDie(killer))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\tif(killer instanceof L2Attackable)\n\t\t{\n\t\t\tif(getTemplate().getEventQuests(Quest.QuestEventType.ON_KILL) != null)\n\t\t\t{\n\t\t\t\tfor(Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_KILL))\n\t\t\t\t{\n\t\t\t\t\tThreadPoolManager.getInstance().scheduleEffect(new OnKillNotifyTask(this, quest, null, false), _onKillDelay);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn true;\n\t}", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "@EventHandler\n\tpublic void onPlayerDeath(final PlayerDeathEvent event) {\n\t\tif (event.getEntity().getKiller() != null) {\n\t\t\tif (event.getEntity().getKiller() instanceof Player && event.getEntity() instanceof Player && pli.global_players.containsKey(event.getEntity().getName()) && pli.global_players.containsKey(event.getEntity().getKiller().getName())) {\n\t\t\t\tevent.getDrops().clear();\n\t\t\t\tevent.getEntity().setHealth(20);\n\t\t\t\t// final Location l = event.getEntity().getLocation();\n\t\t\t\tfinal String killername = event.getEntity().getKiller().getName();\n\t\t\t\tfinal String entityKilled = event.getEntity().getName();\n\n\t\t\t\tBukkit.getScheduler().runTask(this, new Runnable() {\n\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\tpli.getRewardsInstance().giveKillReward(killername, 2);\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tfinal Player p1 = event.getEntity().getKiller();\n\t\t\t\tfinal Player p2 = event.getEntity();\n\n\t\t\t\tIArena a = (IArena) pli.global_players.get(p1.getName());\n\t\t\t\tUtil.teleportPlayerFixed(p2, a.getSpawns().get(r.nextInt(a.getSpawns().size())));\n\n\t\t\t\tInteger gpkiller = 2;\n\t\t\t\tInteger gploser = 0;\n\t\t\t\tif (getConfig().isSet(\"player.\" + killername)) {\n\t\t\t\t\tgpkiller = getConfig().getInt(\"player.\" + killername + \".gp\") + 2; // +2 gp\n\t\t\t\t}\n\t\t\t\tif (getConfig().isSet(\"player.\" + entityKilled)) {\n\t\t\t\t\tgploser = Math.max(getConfig().getInt(\"player.\" + entityKilled + \".gp\") - 1, 0); // -1 gp\n\t\t\t\t}\n\t\t\t\tgetConfig().set(\"player.\" + killername + \".gp\", gpkiller);\n\t\t\t\tgetConfig().set(\"player.\" + entityKilled + \".gp\", gploser);\n\t\t\t\tthis.saveConfig();\n\n\t\t\t\ttry {\n\t\t\t\t\tmainsql.updateStats(p1.getName(), 2);\n\t\t\t\t\tmainsql.updateStats(p2.getName(), -1);\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\tSystem.out.println(\"Failed updating sql gp.\");\n\t\t\t\t}\n\n\t\t\t\tBukkit.getScheduler().runTaskLater(this, new Runnable() {\n\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\tp2.getInventory().clear();\n\t\t\t\t\t\tp2.getInventory().setHelmet(null);\n\t\t\t\t\t\tp2.getInventory().setChestplate(null);\n\t\t\t\t\t\tp2.getInventory().setLeggings(null);\n\t\t\t\t\t\tp2.getInventory().setBoots(null);\n\t\t\t\t\t\tp2.getInventory().setArmorContents(null);\n\t\t\t\t\t\tfor (ItemStack item : start_items) {\n\t\t\t\t\t\t\tp2.getInventory().addItem(item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tp2.updateInventory();\n\t\t\t\t\t}\n\t\t\t\t}, 20L);\n\n\t\t\t\tp2.playSound(p2.getLocation(), Sound.CAT_MEOW, 1F, 1);\n\t\t\t\tlv.put(p2.getName(), 0);\n\n\t\t\t\tArrayList<String> keys = new ArrayList<String>();\n\t\t\t\tif (getConfig().isConfigurationSection(\"player.\" + p2.getName() + \".items\")) {\n\t\t\t\t\tgetConfig().set(\"player.\" + p2.getName() + \".items\", null);\n\t\t\t\t\tthis.saveConfig();\n\t\t\t\t}\n\n\t\t\t\tfor (PotionEffect effect : p2.getActivePotionEffects())\n\t\t\t\t\tp2.removePotionEffect(effect.getType());\n\n\t\t\t\tfor (PotionEffect effect : p1.getActivePotionEffects())\n\t\t\t\t\tp1.removePotionEffect(effect.getType());\n\n\t\t\t\tp1.playEffect(p1.getLocation(), Effect.POTION_BREAK, 5);\n\t\t\t\tInteger current = lv.get(p1.getName());\n\t\t\t\tlv.put(p1.getName(), current + 1);\n\t\t\t\tp1.sendMessage(im.upgrade.replaceAll(\"<level>\", Integer.toString(lv.get(p1.getName()))));\n\t\t\t\tLevel.updatelv(m, lv, p1);\n\n\t\t\t\tscoreboard.updateScoreboard(a);\n\n\t\t\t\tp1.setFoodLevel(20);\n\t\t\t\tp1.setHealth(20);\n\t\t\t\tp2.setHealth(20);\n\t\t\t\tp2.setFoodLevel(20);\n\n\t\t\t\tthis.addextraitems(p1);\n\t\t\t}\n\t\t} else {\n\t\t\t// death by something else -> respawn\n\n\t\t\tif (pli.global_players.containsKey(event.getEntity().getName())) {\n\t\t\t\tevent.getEntity().setHealth(20);\n\t\t\t\tif (event.getEntity() != null) {\n\t\t\t\t\tif (event.getEntity() instanceof Player) {\n\t\t\t\t\t\tevent.getDrops().clear();\n\t\t\t\t\t\tfinal Player p = (Player) event.getEntity();\n\t\t\t\t\t\tIArena a = (IArena) pli.global_players.get(p.getName());\n\t\t\t\t\t\tif (a != null && p != null) {\n\t\t\t\t\t\t\tUtil.teleportPlayerFixed(p, a.getSpawns().get(r.nextInt(a.getSpawns().size())));\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tp.playSound(p.getLocation(), Sound.CAT_MEOW, 1F, 1);\n\n\t\t\t\t\t\tp.setFoodLevel(20);\n\n\t\t\t\t\t\tlv.put(p.getName(), 0);\n\n\t\t\t\t\t\tBukkit.getScheduler().runTaskLater(this, new Runnable() {\n\t\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\t\tp.getInventory().clear();\n\t\t\t\t\t\t\t\tp.getInventory().setHelmet(null);\n\t\t\t\t\t\t\t\tp.getInventory().setChestplate(null);\n\t\t\t\t\t\t\t\tp.getInventory().setLeggings(null);\n\t\t\t\t\t\t\t\tp.getInventory().setBoots(null);\n\t\t\t\t\t\t\t\tp.getInventory().setArmorContents(null);\n\t\t\t\t\t\t\t\tfor (ItemStack item : start_items) {\n\t\t\t\t\t\t\t\t\tp.getInventory().addItem(item);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tp.updateInventory();\n\n\t\t\t\t\t\t\t\tm.addextraitems(p);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}, 20L);\n\n\t\t\t\t\t\tfor (PotionEffect effect : p.getActivePotionEffects())\n\t\t\t\t\t\t\tp.removePotionEffect(effect.getType());\n\n\t\t\t\t\t\tp.setHealth(20);\n\t\t\t\t\t\tp.setFoodLevel(20);\n\n\t\t\t\t\t\tthis.addextraitems(p);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public void kill()\n\t{\n\t\tthis.isDead = true;\n\t\tSystem.out.println(name + \" died!\");\n\t\t//GamePanel.player.playerCombatant.awardXP(this.getXP());\n\n\t\t//TODO: Reload last save or Exit\n\t}", "public void actionCombat(Party p1) {\n System.out.println(\"______________________________________________________________________________\\n\");\n System.out.println(this.Name + \" is attacking ...\");\n int choice = (int)(Math.random() * p1.getTeam().size());\n Character target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n\n if (this.SPEED - target.getSPEED() < 5) {\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n }\n else {\n int n = 0;\n while ((target.actualHP != 0) && (n < 2)) {\n if (n == 1) {\n choice = (int)(Math.random() * p1.getTeam().size() + 1);\n target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n }\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n if (n == 0) System.out.println(this.Name + \" attacks again ...\");\n n++;\n }\n }\n }", "@Override\n\tprotected void killReward() {\n\t\t\n\t}", "protected void kill() {\n\t\tsetDeathTime(0.6);\n\t}", "@Override\n\tpublic void execute() {\n\t\tif (!Variables.decreaseTask) {\n\t\t\tVariables.decreaseTask = true;\n\t\t} else {\n\t\t\tVariables.taskAmount--;\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Killing npcs\");\n\t\t\n\t\tif (Variables.status != \"Completing task...\") {\n\t\tVariables.status = \"Completing task...\";\n\t\t}\n\t\t\n\t\tNpc[] slayerMonster = Npcs.getNearest(slayerMonsterFilter);\n\n\t\ttry {\n\t\tslayerMonster[0].interact(1);\n\t\t} catch (ArrayIndexOutOfBoundsException | NullPointerException e) {\n\t\t\t\n\t\t} \n\t\t\n\t\tTime.sleep(new SleepCondition() {\n\t\t\t@Override\n\t\t\tpublic boolean isValid() {\n\t\t\t\treturn Players.getMyPlayer().isInCombat();\n\t\t\t}\n\t\t}, 5000);\n\t\t\n\t\tTime.sleep(new SleepCondition() {\n\t\t\t@Override\n\t\t\tpublic boolean isValid() {\n\t\t\t\treturn !Players.getMyPlayer().isInCombat();\n\t\t\t}\n\t\t}, 5000);\n\t}", "public void die() {\n\t\tSpriteObject obj = PhysicsObject.getCollidableAt(player1.getX(),player1.getY() + player1.getImage().getHeight() + 3);\n\t\tSpriteObject obj2 = PhysicsObject.getCollidableAt(player1.getX() + player1.getImage().getWidth() ,player1.getY() + player1.getImage().getHeight() + 3);\n\t\tif ((obj instanceof Tile && ((Tile) obj).getType() == TileType.spike) || (obj2 instanceof Tile && ((Tile) obj2).getType() == TileType.spike)) \n\t\t{\n\t\t\tplayer1.death();\n\t\t}\n\n\t\tif (player1.getY() > 1500) {\n\t\t\tplayer1.death();\n\t\t}\n\t}", "@Override\n\tpublic String onKill(NpcInstance npc, PlayerInstance player, boolean isPet)\n\t{\n\t\tfinal QuestState st = getClanLeaderQuestState(player, npc);\n\t\tif ((st == null) || !st.isStarted())\n\t\t{\n\t\t\treturn null;\n\t\t}\n\t\t\n\t\t// Reward only if quest is setup on good index.\n\t\tfinal int raid = st.getInt(\"raid\");\n\t\tif (REWARD_LIST[raid - 1][0] == npc.getNpcId())\n\t\t{\n\t\t\tfinal int item = REWARD_LIST[raid - 1][1];\n\t\t\tif (!st.hasQuestItems(item))\n\t\t\t{\n\t\t\t\tst.giveItems(item, 1);\n\t\t\t\tst.playSound(QuestState.SOUND_MIDDLE);\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn null;\n\t}", "private void checkForDeaths() {\n Iterator<Entity> entityIter = this.entities.iterator();\n\n //geht alle teilnehmer durch\n while ( entityIter.hasNext() ) {\n Entity entity = entityIter.next();\n\n //und entfernt sie wenn sie tot sind aus der liste und der engine\n if ( this.combatMapper.get(entity).curHealth <= 0 ) {\n entityIter.remove();\n\n //alle actions der entity entfernen, können ja nichts machen wenn sie tot sind\n Iterator<IAction> actionIter = this.actions.iterator();\n\n while ( actionIter.hasNext() ) {\n if ( actionIter.next().getOwner().equals(entity) ) {\n actionIter.remove();\n }\n }\n\n this.combatExp += this.combatMapper.get(entity).level * 5; //TODO\n\n EventSystem.getInstance().commitEvent(new Event(EventSystem.EventType.KILL_EVENT, entity));\n\n this.combatSystem.getEngine().removeEntity(entity);\n }\n }\n }", "@Override\n\tprotected void calculateRewards(final L2Character lastAttacker)\n\t{\n\t\t// Creates an empty list of rewards\n\t\tfinal Map<L2Character, RewardInfoHolder> rewards = new ConcurrentHashMap<>();\n\t\t\n\t\ttry\n\t\t{\n\t\t\tif (getAggroListRP().isEmpty())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (EngineModsManager.onNpcExpSp(this, lastAttacker))\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tL2PcInstance maxDealer = null;\n\t\t\tint maxDamage = 0;\n\t\t\t\n\t\t\tint damage;\n\t\t\t\n\t\t\tL2Character attacker, ddealer;\n\t\t\t\n\t\t\t// While Interacting over This Map Removing Object is Not Allowed\n\t\t\tsynchronized (getAggroList())\n\t\t\t{\n\t\t\t\t// Go through the aggroList of the L2Attackable\n\t\t\t\tfor (final AggroInfoHolder info : getAggroListRP().values())\n\t\t\t\t{\n\t\t\t\t\tif (info == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Get the L2Character corresponding to this attacker\n\t\t\t\t\tattacker = info.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Get damages done by this attacker\n\t\t\t\t\tdamage = info.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// Prevent unwanted behavior\n\t\t\t\t\tif (damage > 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (attacker instanceof L2SummonInstance || attacker instanceof L2PetInstance && ((L2PetInstance) attacker).getPetData().getOwnerExpTaken() > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = info.getAttacker();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check if ddealer isn't too far from this (killed monster)\n\t\t\t\t\t\tif (!Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, ddealer, true))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate real damages (Summoners should get own damage plus summon's damage)\n\t\t\t\t\t\tRewardInfoHolder reward = rewards.get(ddealer);\n\t\t\t\t\t\tif (reward == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward = new RewardInfoHolder(ddealer, damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward.addDamage(damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\trewards.put(ddealer, reward);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (ddealer instanceof L2PlayableInstance && ((L2PlayableInstance) ddealer).getActingPlayer() != null && reward.getDmg() > maxDamage)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tmaxDealer = ((L2PlayableInstance) ddealer).getActingPlayer();\n\t\t\t\t\t\t\tmaxDamage = reward.getDmg();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// Manage Base, Quests and Sweep drops of the L2Attackable\n\t\t\tdoItemDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\t// Manage drop of Special Events created by GM for a defined period\n\t\t\tdoEventDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\tif (!getMustRewardExpSP())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (!rewards.isEmpty())\n\t\t\t{\n\t\t\t\tL2Party attackerParty;\n\t\t\t\tlong exp;\n\t\t\t\tint levelDiff, partyDmg, partyLvl, sp;\n\t\t\t\tfloat partyMul, penalty;\n\t\t\t\tRewardInfoHolder reward2;\n\t\t\t\tint[] tmp;\n\t\t\t\t\n\t\t\t\tfor (final RewardInfoHolder reward : rewards.values())\n\t\t\t\t{\n\t\t\t\t\tif (reward == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Penalty applied to the attacker's XP\n\t\t\t\t\tpenalty = 0;\n\t\t\t\t\t\n\t\t\t\t\t// Attacker to be rewarded\n\t\t\t\t\tattacker = reward.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Total amount of damage done\n\t\t\t\t\tdamage = reward.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// If the attacker is a Pet, get the party of the owner\n\t\t\t\t\tif (attacker instanceof L2PetInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PetInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse if (attacker instanceof L2PcInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PcInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If this attacker is a L2PcInstance with a summoned L2SummonInstance, get Exp Penalty applied for the current summoned L2SummonInstance\n\t\t\t\t\tif (attacker instanceof L2PcInstance && ((L2PcInstance) attacker).getPet() instanceof L2SummonInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tpenalty = ((L2SummonInstance) ((L2PcInstance) attacker).getPet()).getExpPenalty();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// We must avoid \"over damage\", if any\n\t\t\t\t\tif (damage > getMaxHp())\n\t\t\t\t\t{\n\t\t\t\t\t\tdamage = getMaxHp();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If there's NO party in progress\n\t\t\t\t\tif (attackerParty == null)\n\t\t\t\t\t{\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\tif (attacker.getKnownList().knowsObject(this))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// Calculate the difference of level between this attacker (L2PcInstance or L2SummonInstance owner) and the L2Attackable\n\t\t\t\t\t\t\t// mob = 24, atk = 10, diff = -14 (full xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 28, diff = 4 (some xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 50, diff = 26 (no xp)\n\t\t\t\t\t\t\tlevelDiff = attacker.getLevel() - getLevel();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, damage);\n\t\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\t\texp *= 1 - penalty;\n\t\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Check for an over-hit enabled strike and VIP options\n\t\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif (player.isVIP())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\texp = (long) (exp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t\tsp = (int) (sp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Distribute the Exp and SP between the L2PcInstance and its L2Summon\n\t\t\t\t\t\t\tif (!attacker.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tattacker.addExpAndSp(Math.round(attacker.calcStat(Stats.EXPSP_RATE, exp, null, null)), (int) attacker.calcStat(Stats.EXPSP_RATE, sp, null, null));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t// share with party members\n\t\t\t\t\t\tpartyDmg = 0;\n\t\t\t\t\t\tpartyMul = 1.f;\n\t\t\t\t\t\tpartyLvl = 0;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Get all L2Character that can be rewarded in the party\n\t\t\t\t\t\tfinal List<L2PlayableInstance> rewardedMembers = new ArrayList<>();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Go through all L2PcInstance in the party\n\t\t\t\t\t\tList<L2PcInstance> groupMembers;\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getCommandChannel().getMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getPartyMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tfor (final L2PcInstance pl : groupMembers)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (pl == null || pl.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Get the RewardInfo of this L2PcInstance from L2Attackable rewards\n\t\t\t\t\t\t\treward2 = rewards.get(pl);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// If the L2PcInstance is in the L2Attackable rewards add its damages to party damages\n\t\t\t\t\t\t\tif (reward2 != null)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add L2PcInstance damages to party damages\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\trewards.remove(pl); // Remove the L2PcInstance from the L2Attackable rewards\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t// Add L2PcInstance of the party (that have attacked or not) to members that can be rewarded\n\t\t\t\t\t\t\t\t// and in range of the monster.\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfinal L2PlayableInstance summon = pl.getPet();\n\t\t\t\t\t\t\tif (summon != null && summon instanceof L2PetInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\treward2 = rewards.get(summon);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (reward2 != null) // Pets are only added if they have done damage\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, summon, true))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add summon damages to party damages\n\t\t\t\t\t\t\t\t\t\trewardedMembers.add(summon);\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tif (summon.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = summon.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\trewards.remove(summon); // Remove the summon from the L2Attackable rewards\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// If the party didn't killed this L2Attackable alone\n\t\t\t\t\t\tif (partyDmg < getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyMul = (float) partyDmg / (float) getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Avoid \"over damage\"\n\t\t\t\t\t\tif (partyDmg > getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyDmg = getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate the level difference between Party and L2Attackable\n\t\t\t\t\t\tlevelDiff = partyLvl - getLevel();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, partyDmg);\n\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\texp *= partyMul;\n\t\t\t\t\t\tsp *= partyMul;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check for an over-hit enabled strike\n\t\t\t\t\t\t// (When in party, the over-hit exp bonus is given to the whole party and splitted proportionally through the party members)\n\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Distribute Experience and SP rewards to L2PcInstance Party members in the known area of the last attacker\n\t\t\t\t\t\tif (partyDmg > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tattackerParty.distributeXpAndSp(exp, sp, rewardedMembers, partyLvl);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t}", "public static void damageStep () {\r\n // rough plan:\r\n // #1: flip defending monster, if face down -> see flipMonster(...);\r\n // #2: Ask CPU and player for possible effect negation! (For an attack negation it is too late!) -> see below in this method\r\n // #3: calculate damage, kill monsters, if needed\r\n // (consider also banishing and immunity, also copied passive effect of (Holy) Lance)\r\n // -> see makeDamageCalculation(...);\r\n // #4: decrease life points, if needed -> see isDealingBattleDamageAndContinuingGame(...);\r\n // #5: consider passive (also copied) trap monster effects -> see possibleSuicideEffect(...);\r\n // #6: display Win/Lose dialog and end match, if needed -> see Game.over(...);\r\n // #7: finally end the attack (consider the effects that happen afterwards), thus allowing the next attack -> endDamageStep(...);\r\n \r\n // about #1:\r\n if (Game.ActiveGuardingMonster.isFaceDown) {flipMonster(Game.ActiveGuardingMonster);}\r\n // about #2:\r\n if (Game.ActiveAttackingMonster.canBeNegated() || Game.ActiveGuardingMonster.canBeNegated()) {\r\n AIinterrupts.cpuIsUsingEffectNegateDuringBattlePhase(); // ask CPU to negate effects first\r\n // ask player to negate effect here\r\n boolean isCanceling = false;\r\n boolean hasEffectNegateHandTrap = Hand.lookForEffectNegateOnHand(true);\r\n boolean hasEffectNegateOnField = Hand.lookForEffectNegateOnField(true);\r\n if (hasEffectNegateHandTrap || hasEffectNegateOnField) {\r\n if (hasEffectNegateHandTrap && !hasEffectNegateOnField) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, true);\r\n }\r\n else if (!hasEffectNegateHandTrap && hasEffectNegateOnField) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, false);\r\n }\r\n else {\r\n int intDialogResult = YuGiOhJi.multipleChoiceDialog(\"Do you want to negate effects on the field?\", \"You can negate passive effects.\", new String[]{\"yes, by discarding Neutraliser\", \"yes, by paying the cost worth 1 card\", \"no (default)\"}, \"no (default)\");\r\n if (intDialogResult==0) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, true);\r\n }\r\n else if (intDialogResult==1) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, false);\r\n }\r\n }\r\n }\r\n if (!isCanceling) {\r\n makeDamageCalculation(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster); // whole rest of battle\r\n }\r\n }\r\n else {\r\n makeDamageCalculation(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster); // whole rest of battle\r\n }\r\n \r\n }", "public void doEventDrop(final L2Character lastAttacker)\n\t{\n\t\tL2PcInstance player = null;\n\t\t\n\t\tif (lastAttacker instanceof L2PcInstance)\n\t\t{\n\t\t\tplayer = (L2PcInstance) lastAttacker;\n\t\t}\n\t\telse if (lastAttacker instanceof L2Summon)\n\t\t{\n\t\t\tplayer = ((L2Summon) lastAttacker).getOwner();\n\t\t}\n\t\t\n\t\tif (player == null)\n\t\t{\n\t\t\treturn; // Don't drop anything if the last attacker or ownere isn't L2PcInstance\n\t\t}\n\t\t\n\t\tif (player.getLevel() - getLevel() > 9)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Go through DateDrop of EventDroplist allNpcDateDrops within the date range\n\t\tfor (final DateDrop drop : EventDroplist.getInstance().getAllDrops())\n\t\t{\n\t\t\tif (Rnd.get(L2DropData.MAX_CHANCE) < drop.chance)\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(drop.items[Rnd.get(drop.items.length)], Rnd.get(drop.min, drop.max));\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.doAutoLoot(this, item); // Give this or these Item(s) to the L2PcInstance that has killed the L2Attackable\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item); // drop the item on the ground\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t}\n\t\t}\n\t\t\n\t\tplayer = null;\n\t}", "@Override\n\tpublic void onAction(L2PcInstance player, boolean interact)\n\t{\n\t\tif(!canTarget(player))\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tplayer.setLastFolkNPC(this);\n\n\t\t// Check if the L2PcInstance already target the L2GuardInstance\n\t\tif(getObjectId() != player.getTargetId())\n\t\t{\n\t\t\t// Send a Server->Client packet MyTargetSelected to the L2PcInstance player\n\t\t\t// The color to display in the select window is White\n\t\t\tMyTargetSelected my = new MyTargetSelected(getObjectId(), 0);\n\t\t\tplayer.sendPacket(my);\n\n\t\t\t// Set the target of the L2PcInstance player\n\t\t\tplayer.setTarget(this);\n\n\t\t\t// Send a Server->Client packet ValidateLocation to correct the L2NpcInstance position and heading on the client\n\t\t\tplayer.sendPacket(new ValidateLocation(this));\n\t\t}\n\t\telse if(interact)\n\t\t{\n\t\t\t// Check if the L2PcInstance is in the _aggroList of the L2GuardInstance\n\t\t\tif(containsTarget(player))\n\t\t\t{\n\t\t\t\t// Set the L2PcInstance Intention to AI_INTENTION_ATTACK\n\t\t\t\tplayer.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, this);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// Calculate the distance between the L2PcInstance and the L2NpcInstance\n\t\t\t\tif(canInteract(player))\n\t\t\t\t{\n\t\t\t\t\t// Send a Server->Client packet SocialAction to the all L2PcInstance on the _knownPlayer of the L2NpcInstance\n\t\t\t\t\t// to display a social action of the L2GuardInstance on their client\n\t\t\t\t\t// Если НПЦ не разговаривает, то слать социалку приветствия собственно и не имеет смысла\n\t\t\t\t\tif(!Config.NON_TALKING_NPCS.contains(getNpcId()))\n\t\t\t\t\t{\n\t\t\t\t\t\tbroadcastPacket(new SocialAction(getObjectId(), Rnd.get(8)));\n\t\t\t\t\t}\n\n\t\t\t\t\tList<Quest> qlsa = getTemplate().getEventQuests(Quest.QuestEventType.QUEST_START);\n\t\t\t\t\tList<Quest> qlst = getTemplate().getEventQuests(Quest.QuestEventType.ON_FIRST_TALK);\n\n\t\t\t\t\tif(qlsa != null && !qlsa.isEmpty())\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.setLastQuestNpcObject(getObjectId());\n\t\t\t\t\t}\n\n\t\t\t\t\tif(qlst != null && qlst.size() == 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tqlst.get(0).notifyFirstTalk(this, player);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tshowChatWindow(player, 0);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t// Set the L2PcInstance Intention to AI_INTENTION_INTERACT\n\t\t\t\t\tplayer.getAI().setIntention(CtrlIntention.AI_INTENTION_INTERACT, this);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t// Send a Server->Client ActionFail to the L2PcInstance in order to avoid that the client wait another packet\n\t\tplayer.sendActionFailed();\n\t}", "public void kill() {\n // leben abziehen und geister sowie pacman respawnen\n lives--;\n pacman.respawn(level.getRandomPacmanSpawn());\n for (GameEntity entity : entities)\n if (entity instanceof Ghost)\n ((Ghost) entity).respawn(level.getNextGhostSpawn());\n }", "@Override\r\n public void onHit(int damage){\n if(box2body != null){\r\n hp -= damage;\r\n screen.getGameManager().get(\"Sounds/orc-34-hit.wav\", Sound.class).play();\r\n if(this.hp <= 0) {\r\n screen.bodiesToDelete.add(box2body);\r\n deleteFlag = true;\r\n screen.spawnedCreatures.remove(this);\r\n screen.getGameManager().get(\"Sounds/orc-32-death.wav\", Sound.class).play();\r\n\r\n //Award Experience\r\n screen.getPlayer().awardExperience(this.experienceValue);\r\n screen.getPlayer().increaseKillCount();\r\n }\r\n }\r\n //Attack player when damaged\r\n //Prevents player from sniping monsters using Wander AI\r\n if(currentState != State.ATTACKING){\r\n Vector2 orcPosition = new Vector2(box2body.getPosition().x, box2body.getPosition().y);\r\n Vector2 playerPosition = new Vector2(screen.getPlayer().box2body.getPosition().x, screen.getPlayer().box2body.getPosition().y);\r\n\r\n currentState = State.HASBEENATTACKED;\r\n velocity = new Vector2(playerPosition.x - orcPosition.x, playerPosition.y - orcPosition.y);\r\n box2body.setLinearVelocity(velocity.scl(speed));\r\n }\r\n }", "public void kill()\r\n {\n if(isTouching(TopDownPlayer.class))\r\n {\r\n health(1);\r\n\r\n getWorld().removeObject(player);\r\n //getWorld().addObject (new Test(), 20, 20);\r\n\r\n }\r\n // if(healthCount >= 1)\r\n // {\r\n // World world;\r\n // world = getWorld();\r\n // getWorld().removeObject(player);\r\n // \r\n // getWorld().addObject (new Test(), 20, 20);\r\n // }\r\n }", "@EventHandler\n void OnEntityDeath(EntityDeathEvent e){\n Entity killer = e.getEntity().getKiller();\n int exp = e.getDroppedExp();\n if(killer instanceof Player){\n GuildMCFunctions functions = new GuildMCFunctions();\n functions.spawnExperiencesInfos((Player) killer, exp);\n }\n\n }", "public void checkForDeath()\n {\n Bullet2 bullet2 = new Bullet2(getVelocity(), getRotation());\n myWorld2 world = (myWorld2)getWorld();\n Zombie2 zombie = new Zombie2();\n \n if (isTouching(Bullet2.class))\n {\n health -= bullet2.damage;\n \n if(health < 0)\n {\n world.score(2);\n world.removeObject(this);\n } \n }\n else if (getX() == 900) \n {\n world.score(-1);\n world.removeObject(this);\n } \n }", "public void killedByPlayer() {\r\n\t\tscreen.enemiesKilled++;\r\n\t\tMazeCrawler mc = screen.mazeHandler.mazeCrawler;\r\n\t\tint n = 2; //if enemy is large do movement n+1 times\r\n\t\tswitch (enemyType) {\r\n\t\tcase DOWN:\r\n\t\t\tmc.moveDown();\r\n\t\t\tif(large) {for(int i = 0; i < n; i++) mc.moveDown();}\r\n\t\t\tbreak;\r\n\t\tcase LEFT:\r\n\t\t\tmc.moveLeft();\r\n\t\t\tif(large) {for(int i = 0; i < n; i++) mc.moveLeft();}\r\n\t\t\tbreak;\r\n\t\tcase RIGHT:\r\n\t\t\tmc.moveRight();\r\n\t\t\tif(large) {for(int i = 0; i < n; i++) mc.moveRight();}\r\n\t\t\tbreak;\r\n\t\tcase UP:\r\n\t\t\tmc.moveUp();\r\n\t\t\tif(large) {for(int i = 0; i < n; i++) mc.moveUp();}\r\n\t\t\tbreak;\r\n\t\t}\r\n\r\n\t\tscreen.enemyDeath.play(.5f);\r\n\t\tdestroy();\r\n\t}", "@Override\r\n\tpublic boolean damageEntity(DamageSource damagesource, float f2) {\n\t\tboolean toReturn = super.damageEntity(damagesource, f2);\r\n\t\tif(f2>=3 && !this.isInvulnerable(damagesource) && damagesource.getEntity()!=null && damagesource.getEntity().getBukkitEntity() instanceof Player) { // prevent things like snowball damage from triggering this ability\r\n\t\t\tif(random.nextInt(100)+1<=20) { //prevent boss from getting combo'd to hard in corner\r\n\t\t\t\tif(!teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity())) {\r\n\t\t\t\t\tteleportToEnemy();\t\t\r\n\t\t\t\t\tteleportCooldown.addCooldown((Player)damagesource.getEntity().getBukkitEntity());\r\n\t\t\t\t\tLog.info(teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity()));\r\n\t\t\t\t\tLog.info(((Player)damagesource.getEntity().getBukkitEntity()).getName());\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn toReturn;\r\n\t}", "public void attack() {\n energy = 2;\n redBull = 0;\n gun = 0;\n target = 1;\n // if Player is in range take off a life.\n if (CharacterTask.ghostLocation == GameWindow.playerLocation) {\n playerLives = playerLives - 1;\n System.out.println(\"Player Lives: \" + playerLives);\n }\n }", "public void burry()\n\t{\n\t\tworld.death();\n\t\ttimerList.clear();\n\t\tif(hospitalNeed != null && hospitalNeed.isAlive())\n\t\t\thospitalNeed.interrupt();\n\t}", "public void doItemDrop(final L2NpcTemplate npcTemplate, final L2Character lastAttacker)\n\t{\n\t\tL2PcInstance player = null;\n\t\t\n\t\tif (lastAttacker instanceof L2PcInstance)\n\t\t{\n\t\t\tplayer = (L2PcInstance) lastAttacker;\n\t\t}\n\t\telse if (lastAttacker instanceof L2Summon)\n\t\t{\n\t\t\tplayer = ((L2Summon) lastAttacker).getOwner();\n\t\t}\n\t\t\n\t\t// Don't drop anything if the last attacker or ownere isn't L2PcInstance\n\t\tif (player == null)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tif (EngineModsManager.onNpcDrop(this, lastAttacker))\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tfinal int levelModifier = calculateLevelModifierForDrop(player); // level modifier in %'s (will be subtracted from drop chance)\n\t\t\n\t\t// Check the drop of a cursed weapon\n\t\tif (levelModifier == 0 && player.getLevel() > 20)\n\t\t{\n\t\t\tCursedWeaponsManager.getInstance().checkDrop(this, player);\n\t\t}\n\t\t\n\t\t// now throw all categorized drops and handle spoil.\n\t\tfor (final L2DropCategory cat : npcTemplate.getDropData())\n\t\t{\n\t\t\tRewardItem item = null;\n\t\t\tif (cat.isSweep())\n\t\t\t{\n\t\t\t\t// according to sh1ny, seeded mobs CAN be spoiled and swept.\n\t\t\t\tif (isSpoil()/* && !isSeeded() */)\n\t\t\t\t{\n\t\t\t\t\tList<RewardItem> sweepList = new ArrayList<>();\n\t\t\t\t\t\n\t\t\t\t\tfor (final L2DropData drop : cat.getAllDrops())\n\t\t\t\t\t{\n\t\t\t\t\t\titem = calculateRewardItem(player, drop, levelModifier, true);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (item == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.DEBUG)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tLOGGER.debug(\"Item id to spoil: \" + item.getItemId() + \" amount: \" + item.getCount());\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tsweepList.add(item);\n\t\t\t\t\t\t\n\t\t\t\t\t\titem = null;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Set the table sweepItems of this L2Attackable\n\t\t\t\t\tif (!sweepList.isEmpty())\n\t\t\t\t\t{\n\t\t\t\t\t\tsweepItems = sweepList.toArray(new RewardItem[sweepList.size()]);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tsweepList = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tif (isSeeded())\n\t\t\t\t{\n\t\t\t\t\tL2DropData drop = cat.dropSeedAllowedDropsOnly();\n\t\t\t\t\t\n\t\t\t\t\tif (drop == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = calculateRewardItem(player, drop, levelModifier, false);\n\t\t\t\t\tdrop = null;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\titem = calculateCategorizedRewardItem(player, cat, levelModifier);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (item != null)\n\t\t\t\t{\n\t\t\t\t\tif (Config.DEBUG)\n\t\t\t\t\t{\n\t\t\t\t\t\tLOGGER.debug(\"Item id to drop: \" + item.getItemId() + \" amount: \" + item.getCount());\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Check if the autoLoot mode is active\n\t\t\t\t\tif (Config.AUTO_LOOT)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (item_templ == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tLOGGER.info(\"ERROR: Item id to autoloot \" + item.getItemId() + \" has not template into items/armor/weapon tables.. It cannot be dropped..\");\n\t\t\t\t\t\t\t// DropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ) || !Config.AUTO_LOOT_BOSS && this instanceof L2RaidBossInstance || !Config.AUTO_LOOT_BOSS && this instanceof L2GrandBossInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.doAutoLoot(this, item); // Give this or these Item(s) to the L2PcInstance that has killed the L2Attackable\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item); // drop the item on the ground\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Broadcast message if RaidBoss was defeated\n\t\t\t\t\tif (this instanceof L2RaidBossInstance || this instanceof L2GrandBossInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tSystemMessage sm;\n\t\t\t\t\t\tsm = new SystemMessage(SystemMessageId.S1_DIED_DROPPED_S3_S2);\n\t\t\t\t\t\tsm.addString(getName());\n\t\t\t\t\t\tsm.addItemName(item.getItemId());\n\t\t\t\t\t\tsm.addNumber(item.getCount());\n\t\t\t\t\t\tbroadcastPacket(sm);\n\t\t\t\t\t\tsm = null;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\titem = null;\n\t\t}\n\t\t\n\t\t// Apply Special Item drop with rnd qty for champions\n\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion() && player.getLevel() <= getLevel() + 3 && Config.L2JMOD_CHAMPION_REWARD > 0 && Rnd.get(100) < Config.L2JMOD_CHAMPION_REWARD)\n\t\t{\n\t\t\tint champqty = Rnd.get(Config.L2JMOD_CHAMPION_REWARD_QTY);\n\t\t\tchampqty++; // quantity should actually vary between 1 and whatever admin specified as max, inclusive.\n\t\t\t\n\t\t\tRewardItem item = new RewardItem(Config.L2JMOD_CHAMPION_REWARD_ID, champqty);\n\t\t\t\n\t\t\t// Give this or these Item(s) to the L2PcInstance that has killed the L2Attackable\n\t\t\tif (Config.AUTO_LOOT)\n\t\t\t{\n\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\n\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tplayer.addItem(\"ChampionLoot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tDropItem(player, item);\n\t\t\t}\n\t\t\t\n\t\t\titem = null;\n\t\t}\n\t\t\n\t\t// Instant Item Drop :>\n\t\tfinal double rateHp = getStat().calcStat(Stats.MAX_HP, 1, this, null);\n\t\t\n\t\tif (rateHp < 2 && String.valueOf(npcTemplate.type).contentEquals(\"L2Monster\")) // only L2Monster with <= 1x HP can drop herbs\n\t\t{\n\t\t\tboolean hp = false;\n\t\t\tboolean mp = false;\n\t\t\tboolean spec = false;\n\t\t\t\n\t\t\t// ptk - patk type enhance\n\t\t\tint random = Rnd.get(1000); // note *10\n\t\t\t\n\t\t\tif (random < Config.RATE_DROP_SPECIAL_HERBS && !spec) // && !_spec useless yet\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(8612, 1); // Herb of Warrior\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t\tspec = true;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tfor (int i = 0; i < 3; i++)\n\t\t\t\t{\n\t\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\t\n\t\t\t\t\tif (random < Config.RATE_DROP_COMMON_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tRewardItem item = null;\n\t\t\t\t\t\tif (i == 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8606, 1); // Herb of Power\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (i == 1)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8608, 1); // Herb of Atk. Spd.\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (i == 2)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8610, 1); // Herb of Critical Attack\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (item == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// mtk - matk type enhance\n\t\t\trandom = Rnd.get(1000); // note *10\n\t\t\t\n\t\t\tif (random < Config.RATE_DROP_SPECIAL_HERBS && !spec)\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(8613, 1); // Herb of Mystic\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t\tspec = true;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tfor (int i = 0; i < 2; i++)\n\t\t\t\t{\n\t\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\t\n\t\t\t\t\tif (random < Config.RATE_DROP_COMMON_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tRewardItem item = null;\n\t\t\t\t\t\tif (i == 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8607, 1); // Herb of Magic\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (i == 1)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8609, 1); // Herb of Casting Speed\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (item == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// hp+mp type\n\t\t\trandom = Rnd.get(1000); // note *10\n\t\t\t\n\t\t\tif (random < Config.RATE_DROP_SPECIAL_HERBS && !spec)\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(8614, 1); // Herb of Recovery\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t\tmp = true;\n\t\t\t\thp = true;\n\t\t\t\tspec = true;\n\t\t\t}\n\t\t\t\n\t\t\t// hp - restore hp type\n\t\t\tif (!hp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(100);\n\t\t\t\tif (random < Config.RATE_DROP_MP_HP_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8600, 1); // Herb of Life\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t\thp = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!hp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_GREATER_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8601, 1); // Greater Herb of Life\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t\thp = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!hp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(1000); // note *10\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_SUPERIOR_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8602, 1); // Superior Herb of Life\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// mp - restore mp type\n\t\t\tif (!mp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_MP_HP_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8603, 1); // Herb of Mana\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t\tmp = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!mp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_GREATER_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8604, 1); // Greater Herb of Mana\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t\tmp = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!mp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(1000); // note *10\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_SUPERIOR_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8605, 1); // Superior Herb of Mana\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// speed enhance type\n\t\t\trandom = Rnd.get(100);\n\t\t\t\n\t\t\tif (random < Config.RATE_DROP_COMMON_HERBS)\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(8611, 1); // Herb of Speed\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t}\n\t\t}\n\t}", "void doNegativeEffect(Skill castSkill, double power, Creature performer, Item target) {\n/* 200 */ performer.getCommunicator().sendNormalServerMessage(\"The \" + target\n/* 201 */ .getName() + \" emits a deep worrying sound of resonance, but stays intact.\", (byte)3);\n/* */ }", "private void attackPlayer()\n\t{\n\t\tif(shootTimer.done())\n\t\t{\n\t\t\tProjectile spiderWeb = new SpiderWeb(x, y);\n\t\t\tGame.objectWaitingRoom.add(spiderWeb);\n\t\t\tspiderWeb.shoot();\n\t\t\tshootTimer.setTime(200);\n\t\t}\n\t}", "@Override\r\n\t\t\t\tpublic void run() {\n\t\t\t\t\t\r\n\t\t\t\t\tfor(Entity as: Bukkit.getWorld(\"world\").getEntities()) {\r\n\t\t\t\t\t\tif(as instanceof ArmorStand) {\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tas.remove();\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t//TOPS\r\n\t\t\t\t\r\n\t\t\t\t\tif(MetodosWarps.containsWarp(\"topkills\")) {\r\n\t\t\t\t\t getTop(locTopKILLS,\"Kills\");\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žAžlTOP KILLS ATUALIZADO COM SUCESSO! \\n \");\t\r\n\t\t\t\t\t}else {\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žcžlO TOP KILLS NAO PODE SER CARREGADO, POIS A WARP topkills NAO ESTA SETADA! \\n \");\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(MetodosWarps.containsWarp(\"topcoins\")) {\r\n\t\t\t\t\t getTop(locTopCoins,\"Coins\");\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žAžlTOP COINS ATUALIZADO COM SUCESSO! \\n \");\t\r\n\t\t\t\t\t}else {\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žcžlO TOP COINS NAO PODE SER CARREGADO, POIS A WARP topkills NAO ESTA SETADA! \\n \");\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(MetodosWarps.containsWarp(\"top1v1\")) {\r\n\t\t\t\t\t getTop(locTop1v1,\"wins\");\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žAžlTOP 1v1 ATUALIZADO COM SUCESSO! \\n \");\t\r\n\t\t\t\t\t}else {\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žcžlO TOP 1v1 NAO PODE SER CARREGADO, POIS A WARP top1v1 NAO ESTA SETADA! \\n \");\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t//Caixa misteriosa\r\n\t\t\t\t\t\r\n\t\t\t\t\tif(MetodosWarps.containsWarp(\"misteryBox\")) {\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t Spawn(misteryBox, \"žažlCAIXA MISTERIOSA\",misteryBox.getY()-1.7);\r\n\t\t\t\t\t Spawn(misteryBox, \"žežlEM BREVE!\",misteryBox.getY()-2);\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žAžlMYSTERYBOX ATUALIZADO COM SUCESSO! \\n \");\t\r\n\t\t\t\t\t}else {\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žcžlO TOP COINS NAO PODE SER CARREGADO, POIS A WARP misteryBox NAO ESTA SETADA! \\n \");\r\n\t\t\t\t\t}\r\n\t\t\t\t}", "private static void attack(RobotInfo target) throws GameActionException {\n if (SOLDIER_DEBUG) {\n System.out.println(\"attacking\");\n }\n BulletInfo[] bullets = rc.senseNearbyBullets(EvasiveSoldier.BULLET_DETECT_RADIUS);\n RobotInfo[] robots = rc.senseNearbyRobots(EvasiveSoldier.ENEMY_DETECT_RADIUS);\n MapLocation targetLocation = target.getLocation();\n move(bullets, robots, targetLocation);\n //RobotUtils.tryMoveDestination(targetLocation);\n if (TargetingUtils.clearShot(here, target) || (rc.getType() == RobotType.GARDENER && rc.getOpponentVictoryPoints() > 10)) {\n if (SOLDIER_DEBUG) {\n System.out.println(\"clearShot to target\");\n }\n Direction towardsEnemy = here.directionTo(targetLocation);\n float distanceEnemy = here.distanceTo(targetLocation);\n if (distanceEnemy <= 3.5 && rc.canFirePentadShot() && rc.getTeamBullets() > 200) {\n rc.firePentadShot(towardsEnemy);\n }\n else {\n if (rc.canFireTriadShot() && rc.getTeamBullets() > 50) {\n rc.fireTriadShot(towardsEnemy);\n }\n else if (rc.canFireSingleShot()) {\n rc.fireSingleShot(towardsEnemy);\n }\n }\n }\n }", "public void killed(ServerLevel debug1, LivingEntity debug2) {\n/* 1718 */ awardStat(Stats.ENTITY_KILLED.get(debug2.getType()));\n/* */ }", "public void act() \n {\n if(timer > 0){\n timer--;\n }else{\n Greenfoot.playSound(\"explosionSound.wav\");\n getWorld().removeObject(this);\n }\n }", "public void attackMonster(World world){\n\t\tif ((UnitManager.unitNearPlayer(world.getPlayer(),this,PLAYER_RANGE) == true \n\t\t\t\t\t&& RPG.isAttacking()) && world.getPlayer().isAttack()) {\n\t\t\tthis.getUnitStats().reduceHP(world.getPlayer().damageAmount());\n\t\t\t\n\t\t}else{\n\t\t\t\n\t\t}\n\t}", "public synchronized void Kill() {\n\t dieDieDie = true;\n\t}", "public synchronized void Kill() {\n\t dieDieDie = true;\n\t}", "@Deprecated\n/* */ public static boolean attack(Creature performer, Creature defender, int counter, int pos, Action act) {\n/* 89 */ if (!(performer.getStatus()).visible) {\n/* */ \n/* 91 */ performer.getCommunicator().sendAlertServerMessage(\"You are now visible again.\");\n/* 92 */ performer.setVisible(true);\n/* */ } \n/* */ \n/* 95 */ boolean done = false;\n/* 96 */ boolean dead = false;\n/* 97 */ boolean aiming = false;\n/* 98 */ if (performer.equals(defender)) {\n/* */ \n/* 100 */ performer.getCommunicator().sendAlertServerMessage(\"You cannot attack yourself.\");\n/* 101 */ performer.setOpponent(null);\n/* 102 */ return true;\n/* */ } \n/* */ \n/* 105 */ Item primWeapon = performer.getPrimWeapon();\n/* 106 */ performer.setSecondsToLogout(300);\n/* 107 */ if (!defender.isPlayer()) {\n/* 108 */ performer.setSecondsToLogout(180);\n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 116 */ if (defender.getAttackers() > 9) {\n/* */ \n/* 118 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 119 */ .getNameWithGenus() + \" is too crowded with attackers. You find no space.\");\n/* 120 */ performer.setOpponent(null);\n/* 121 */ return true;\n/* */ } \n/* 123 */ if (primWeapon == null) {\n/* */ \n/* 125 */ performer.getCommunicator()\n/* 126 */ .sendNormalServerMessage(\"You have no weapon to attack \" + defender.getNameWithGenus() + \" with.\");\n/* 127 */ performer.setOpponent(null);\n/* 128 */ return true;\n/* */ } \n/* */ \n/* 131 */ BlockingResult result = Blocking.getBlockerBetween(performer, defender, 4);\n/* 132 */ if (result != null) {\n/* */ \n/* 134 */ performer.getCommunicator().sendNormalServerMessage(\"The wall blocks your attempt.\");\n/* 135 */ performer.setOpponent(null);\n/* 136 */ return true;\n/* */ } \n/* 138 */ if (Creature.rangeTo(performer, defender) > Actions.actionEntrys[114].getRange()) {\n/* */ \n/* */ \n/* */ \n/* 142 */ performer.getCommunicator().sendNormalServerMessage(\"You are now too far away to \" + Actions.actionEntrys[114]\n/* 143 */ .getActionString().toLowerCase() + \" \" + defender\n/* 144 */ .getNameWithGenus() + \".\");\n/* 145 */ performer.setOpponent(null);\n/* 146 */ return true;\n/* */ } \n/* 148 */ if (performer.getLeader() != null && performer.getLeader() == defender)\n/* 149 */ performer.setLeader(null); \n/* 150 */ if (performer.getPet() != null)\n/* */ {\n/* 152 */ if ((performer.getPet()).target == -10L)\n/* */ {\n/* 154 */ performer.getPet().setTarget(defender.getWurmId(), false);\n/* */ }\n/* */ }\n/* */ \n/* 158 */ performer.staminaPollCounter = 2;\n/* 159 */ int speed = 10;\n/* 160 */ int timeMod = 2;\n/* 161 */ if (performer.getFightStyle() == 2) {\n/* 162 */ timeMod = 4;\n/* 163 */ } else if (performer.getFightStyle() == 1) {\n/* 164 */ timeMod = 0;\n/* 165 */ } if (primWeapon.isBodyPart() && primWeapon.getAuxData() != 100) {\n/* 166 */ speed = (int)performer.getBodyWeaponSpeed(primWeapon);\n/* 167 */ } else if (primWeapon.isWeaponPierce() || primWeapon.isWeaponKnife()) {\n/* 168 */ speed = primWeapon.getWeightGrams() / 1000 + 1 + timeMod;\n/* 169 */ } else if (primWeapon.isWeaponSlash() || primWeapon.isWeaponSword() || primWeapon.isWeaponAxe()) {\n/* 170 */ speed = primWeapon.getWeightGrams() / 1000 + 3 + timeMod;\n/* 171 */ } else if (primWeapon.isWeaponCrush()) {\n/* 172 */ speed = primWeapon.getWeightGrams() / 1000 + 6 + timeMod;\n/* */ } else {\n/* 174 */ speed = primWeapon.getWeightGrams() / 1000 + 6 + timeMod;\n/* 175 */ } if (pos != -1) {\n/* */ \n/* 177 */ aiming = true;\n/* 178 */ speed++;\n/* */ } \n/* 180 */ defender.addAttacker(performer);\n/* 181 */ if (!done) {\n/* */ \n/* 183 */ int posBonus = 0;\n/* 184 */ float defAngle = Creature.normalizeAngle(defender.getStatus().getRotation());\n/* 185 */ double newrot = Math.atan2((performer.getStatus().getPositionY() - defender.getStatus().getPositionY()), (performer\n/* 186 */ .getStatus().getPositionX() - defender.getStatus().getPositionX()));\n/* 187 */ float attAngle = (float)(newrot * 57.29577951308232D) + 90.0F;\n/* 188 */ attAngle = Creature.normalizeAngle(attAngle - defAngle);\n/* */ \n/* 190 */ if (attAngle > 90.0F && attAngle < 270.0F)\n/* */ {\n/* 192 */ if (attAngle > 135.0F && attAngle < 225.0F) {\n/* 193 */ posBonus = 10;\n/* */ } else {\n/* 195 */ posBonus = 5;\n/* */ } \n/* */ }\n/* */ \n/* 199 */ float diff = (performer.getPositionZ() + performer.getAltOffZ() - defender.getPositionZ() + defender.getAltOffZ()) / 10.0F;\n/* 200 */ posBonus += (int)Math.min(5.0F, diff);\n/* */ \n/* 202 */ if (counter == 1) {\n/* */ \n/* 204 */ if (!(defender instanceof Player)) {\n/* */ \n/* 206 */ defender.turnTowardsCreature(performer);\n/* 207 */ if (defender.isHunter()) {\n/* 208 */ defender.setTarget(performer.getWurmId(), false);\n/* */ }\n/* */ } \n/* 211 */ if (performer instanceof Player && defender instanceof Player) {\n/* */ \n/* 213 */ Battle battle = Battles.getBattleFor(performer, defender);\n/* 214 */ battle.addEvent(new BattleEvent((short)-1, performer.getName(), defender.getName()));\n/* */ } \n/* */ \n/* 217 */ if (aiming) {\n/* */ \n/* 219 */ String bodypartname = defender.getBody().getWoundLocationString(pos);\n/* 220 */ performer.getCommunicator().sendSafeServerMessage(\"You try to \" + \n/* 221 */ getAttackString(performer, primWeapon) + \" \" + defender.getNameWithGenus() + \" in the \" + bodypartname + \".\");\n/* */ \n/* 223 */ defender.getCommunicator().sendAlertServerMessage(performer\n/* 224 */ .getNameWithGenus() + \" tries to \" + getAttackString(performer, primWeapon) + \" you!\");\n/* */ }\n/* */ else {\n/* */ \n/* 228 */ performer.getCommunicator().sendSafeServerMessage(\"You try to \" + \n/* 229 */ getAttackString(performer, primWeapon) + \" \" + defender.getNameWithGenus() + \".\");\n/* 230 */ if (performer.isDominated())\n/* */ {\n/* 232 */ if (performer.getDominator() != null)\n/* 233 */ performer\n/* 234 */ .getDominator()\n/* 235 */ .getCommunicator()\n/* 236 */ .sendSafeServerMessage(performer\n/* 237 */ .getNameWithGenus() + \" tries to \" + getAttackString(performer, primWeapon) + \" \" + defender\n/* 238 */ .getNameWithGenus() + \".\"); \n/* */ }\n/* 240 */ defender.getCommunicator().sendAlertServerMessage(performer\n/* 241 */ .getNameWithGenus() + \" tries to \" + getAttackString(performer, primWeapon) + \" you!\");\n/* 242 */ if (defender.isDominated())\n/* */ {\n/* 244 */ if (defender.getDominator() != null) {\n/* 245 */ defender.getDominator()\n/* 246 */ .getCommunicator()\n/* 247 */ .sendAlertServerMessage(performer\n/* 248 */ .getNameWithGenus() + \" tries to \" + getAttackString(performer, primWeapon) + \" \" + defender\n/* 249 */ .getNameWithGenus() + \"!\");\n/* */ }\n/* */ }\n/* */ } \n/* */ } else {\n/* */ \n/* 255 */ Battle battle = performer.getBattle();\n/* 256 */ if (battle != null) {\n/* 257 */ battle.touch();\n/* */ }\n/* */ } \n/* 260 */ if (act.currentSecond() % speed == 0 || (counter == 1 && !(performer instanceof Player))) {\n/* */ \n/* 262 */ if (!(defender instanceof Player))\n/* */ {\n/* 264 */ defender.turnTowardsCreature(performer);\n/* */ }\n/* */ \n/* 267 */ Item defPrimWeapon = null;\n/* 268 */ Skill attackerFightSkill = null;\n/* 269 */ Skill defenderFightSkill = null;\n/* 270 */ Skills performerSkills = performer.getSkills();\n/* 271 */ Skills defenderSkills = defender.getSkills();\n/* */ \n/* */ \n/* 274 */ double attBonus = performer.zoneBonus - performer.getMovePenalty() * 0.5D;\n/* 275 */ double defBonus = (defender.zoneBonus - defender.getMovePenalty());\n/* 276 */ if (defender.isMoving() && defender instanceof Player)\n/* 277 */ defBonus -= 5.0D; \n/* 278 */ if (performer.isMoving() && performer instanceof Player) {\n/* 279 */ attBonus -= 5.0D;\n/* */ }\n/* */ \n/* 282 */ attBonus += posBonus;\n/* 283 */ defPrimWeapon = defender.getPrimWeapon();\n/* */ \n/* */ \n/* 286 */ int attSknum = 1023;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ try {\n/* 301 */ attackerFightSkill = performerSkills.getSkill(1023);\n/* */ }\n/* 303 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 305 */ attackerFightSkill = performerSkills.learn(1023, 1.0F);\n/* */ } \n/* 307 */ int defSknum = 1023;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ try {\n/* 322 */ defenderFightSkill = defenderSkills.getSkill(1023);\n/* */ }\n/* 324 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 326 */ defenderFightSkill = defenderSkills.learn(1023, 1.0F);\n/* */ } \n/* 328 */ dead = performAttack(pos, aiming, performer, performerSkills, defender, defenderSkills, primWeapon, defPrimWeapon, attBonus, defBonus, attackerFightSkill, defenderFightSkill, speed);\n/* */ \n/* 330 */ if (aiming)\n/* 331 */ done = true; \n/* 332 */ if (dead)\n/* 333 */ done = true; \n/* */ } \n/* 335 */ if (!done && !aiming) {\n/* */ \n/* 337 */ Item[] secondaryWeapons = performer.getSecondaryWeapons();\n/* 338 */ for (int x = 0; x < secondaryWeapons.length; x++) {\n/* */ \n/* 340 */ if (!done) {\n/* */ \n/* 342 */ speed = 10;\n/* 343 */ if (secondaryWeapons[x].isBodyPart() && secondaryWeapons[x].getAuxData() != 100) {\n/* 344 */ speed = Server.rand.nextInt((int)(performer.getBodyWeaponSpeed(secondaryWeapons[x]) + 5.0F)) + 1 + timeMod;\n/* */ }\n/* 346 */ else if (secondaryWeapons[x].isWeaponPierce() || secondaryWeapons[x].isWeaponKnife()) {\n/* 347 */ speed = 5 + Server.rand.nextInt(secondaryWeapons[x].getWeightGrams() / 1000 + 3) + 1 + timeMod;\n/* 348 */ } else if (secondaryWeapons[x].isWeaponSlash() || secondaryWeapons[x].isWeaponSword() || secondaryWeapons[x]\n/* 349 */ .isWeaponAxe()) {\n/* 350 */ speed = 5 + Server.rand.nextInt(secondaryWeapons[x].getWeightGrams() / 1000 + 5) + 1 + timeMod;\n/* 351 */ } else if (secondaryWeapons[x].isWeaponCrush()) {\n/* 352 */ speed = 5 + Server.rand.nextInt(secondaryWeapons[x].getWeightGrams() / 1000 + 8) + 1 + timeMod;\n/* */ } else {\n/* 354 */ speed = 5 + Server.rand.nextInt(secondaryWeapons[x].getWeightGrams() / 1000 + 10) + 1 + timeMod;\n/* 355 */ } if (act.currentSecond() % speed == 0) {\n/* */ \n/* 357 */ Item defPrimWeapon = null;\n/* 358 */ Skill attackerFightSkill = null;\n/* 359 */ Skill defenderFightSkill = null;\n/* 360 */ Skills performerSkills = performer.getSkills();\n/* 361 */ Skills defenderSkills = defender.getSkills();\n/* */ \n/* */ \n/* */ \n/* */ \n/* 366 */ double attBonus = performer.zoneBonus - performer.getMovePenalty() * 0.5D;\n/* 367 */ double defBonus = (defender.zoneBonus - defender.getMovePenalty());\n/* */ \n/* */ \n/* 370 */ if (defender.isMoving() && defender instanceof Player)\n/* 371 */ defBonus -= 5.0D; \n/* 372 */ if (performer.isMoving() && performer instanceof Player)\n/* 373 */ attBonus -= 5.0D; \n/* 374 */ attBonus += posBonus;\n/* */ \n/* */ \n/* 377 */ defPrimWeapon = defender.getPrimWeapon();\n/* */ \n/* */ \n/* */ \n/* 381 */ int attSknum = 1023;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ try {\n/* 396 */ attackerFightSkill = performerSkills.getSkill(1023);\n/* */ }\n/* 398 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 400 */ attackerFightSkill = performerSkills.learn(1023, 1.0F);\n/* */ } \n/* 402 */ int defSknum = 1023;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ try {\n/* 417 */ defenderFightSkill = defenderSkills.getSkill(1023);\n/* */ }\n/* 419 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 421 */ defenderFightSkill = defenderSkills.learn(1023, 1.0F);\n/* */ } \n/* 423 */ dead = performAttack(pos, false, performer, performerSkills, defender, defenderSkills, secondaryWeapons[x], defPrimWeapon, attBonus, defBonus, attackerFightSkill, defenderFightSkill, speed);\n/* */ \n/* */ \n/* 426 */ if (dead)\n/* 427 */ done = true; \n/* */ } \n/* */ } \n/* */ } \n/* */ } \n/* */ } \n/* 433 */ performer.getStatus().modifyStamina(-50.0F);\n/* 434 */ if (done) {\n/* */ \n/* 436 */ if (aiming) {\n/* */ \n/* 438 */ if (dead) {\n/* */ \n/* 440 */ defender.setOpponent(null);\n/* 441 */ defender.setTarget(-10L, true);\n/* 442 */ performer.setTarget(-10L, true);\n/* 443 */ performer.setOpponent(null);\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 463 */ if (performer.getCitizenVillage() != null)\n/* 464 */ performer.getCitizenVillage().removeTarget(defender); \n/* 465 */ if (defender instanceof Player && performer instanceof Player) {\n/* */ \n/* */ \n/* */ try {\n/* 469 */ Players.getInstance().addKill(performer.getWurmId(), defender.getWurmId(), defender.getName());\n/* */ }\n/* 471 */ catch (Exception ex) {\n/* */ \n/* 473 */ logger.log(Level.INFO, \"Failed to add kill for \" + performer.getName() + \":\" + defender.getName() + \" - \" + ex\n/* 474 */ .getMessage(), ex);\n/* */ } \n/* */ \n/* 477 */ if (!performer.isOnPvPServer() || !defender.isOnPvPServer()) {\n/* */ \n/* 479 */ boolean okToKill = false;\n/* 480 */ if (performer.getCitizenVillage() != null && \n/* 481 */ performer.getCitizenVillage().isEnemy(defender.getCitizenVillage()))\n/* 482 */ okToKill = true; \n/* 483 */ if (defender.getKingdomId() == performer.getKingdomId() && defender\n/* 484 */ .getKingdomTemplateId() != 3 && \n/* 485 */ defender.getReputation() >= 0 && !okToKill) {\n/* 486 */ performer.setReputation(performer.getReputation() - 20);\n/* */ }\n/* */ } \n/* */ } \n/* */ } \n/* */ } else {\n/* */ \n/* 493 */ performer.setOpponent(null);\n/* 494 */ if (dead) {\n/* */ \n/* 496 */ defender.setOpponent(null);\n/* 497 */ defender.setTarget(-10L, true);\n/* 498 */ performer.setTarget(-10L, true);\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 518 */ if (performer.getCitizenVillage() != null)\n/* */ {\n/* */ \n/* 521 */ performer.getCitizenVillage().removeTarget(defender);\n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 533 */ if (defender instanceof Player && performer instanceof Player) {\n/* */ \n/* */ \n/* */ try {\n/* 537 */ Players.getInstance().addKill(performer.getWurmId(), defender.getWurmId(), defender.getName());\n/* */ }\n/* 539 */ catch (Exception ex) {\n/* */ \n/* 541 */ logger.log(Level.INFO, \"Failed to add kill for \" + performer.getName() + \":\" + defender.getName() + \" - \" + ex\n/* 542 */ .getMessage(), ex);\n/* */ } \n/* 544 */ if (!performer.isOnPvPServer() || !defender.isOnPvPServer()) {\n/* */ \n/* 546 */ boolean okToKill = false;\n/* 547 */ if (performer.getCitizenVillage() != null && \n/* 548 */ performer.getCitizenVillage().isEnemy(defender.getCitizenVillage()))\n/* 549 */ okToKill = true; \n/* 550 */ if (defender.getKingdomId() == performer.getKingdomId() && defender\n/* 551 */ .getKingdomId() != 3 && \n/* 552 */ defender.getReputation() >= 0 && !okToKill)\n/* 553 */ performer.setReputation(performer.getReputation() - 20); \n/* */ } \n/* */ } \n/* */ } \n/* */ } \n/* 558 */ if (dead)\n/* */ {\n/* 560 */ if (!(defender instanceof Player) && performer instanceof Player) {\n/* */ \n/* */ try {\n/* */ \n/* 564 */ int tid = defender.getTemplate().getTemplateId();\n/* 565 */ if (CreatureTemplate.isDragon(tid)) {\n/* 566 */ ((Player)performer).addTitle(Titles.Title.DragonSlayer);\n/* 567 */ } else if (tid == 11 || tid == 27) {\n/* 568 */ ((Player)performer).addTitle(Titles.Title.TrollSlayer);\n/* 569 */ } else if (tid == 20 || tid == 22) {\n/* 570 */ ((Player)performer).addTitle(Titles.Title.GiantSlayer);\n/* 571 */ } if (defender.isUnique()) {\n/* 572 */ HistoryManager.addHistory(performer.getNameWithGenus(), \"slayed \" + defender.getNameWithGenus());\n/* */ }\n/* 574 */ } catch (Exception ex) {\n/* */ \n/* 576 */ logger.log(Level.WARNING, \"Defender: \" + defender.getName() + \" and attacker: \" + performer.getName() + \":\" + ex\n/* 577 */ .getMessage(), ex);\n/* */ } \n/* */ }\n/* */ }\n/* */ } \n/* 582 */ return done;\n/* */ }", "public void killAndHunt() {\n\t\tRandom random = new Random();\n\t\tint currentIndex = random.nextInt(N);\t\n\t\tkill(currentIndex);\n\t}", "private void reviveAttacker() {\n\t\tString type = (mRandom.nextFloat() > mKnightSpawnChance) ? \"normal\" : \"knight\";\n\t\treviveAttacker(type);\n\t}", "public void takeDamage()\n {\n if(getWorld()!= null)\n {\n if(this.isTouching(Enemies.class))\n {\n Life = Life - Enemies.damage;\n if(Life <=0)\n {\n getWorld().removeObject(this);\n Store.wealth += Game.credit;\n }\n }\n }\n }", "public abstract int doDamage(int time, GenericMovableUnit unit, Unit target);", "@Listener\n public void onDeath(DestructEntityEvent.Death event) {\n if (!(event.getTargetEntity() instanceof Player))\n return;\n\n Optional<EntityDamageSource> source = event.getCause().first(EntityDamageSource.class);\n if (!source.isPresent())\n return; // did not die from pvp\n\n Player killed = (Player) event.getTargetEntity();\n\n Player killer = null;\n ItemStack weapon = null;\n Entity damager = source.get().getSource();\n if (damager instanceof Player) {\n killer = (Player) damager;\n weapon = killer.getItemInHand(HandTypes.MAIN_HAND).get();\n }\n\n if (damager instanceof Projectile) {\n Projectile proj = (Projectile) damager;\n if (proj.getShooter() instanceof Player) {\n killer = (Player) proj.getShooter();\n weapon = killer.getItemInHand(HandTypes.MAIN_HAND).get();\n }\n }\n\n if (damager.get(TameableData.class).isPresent()) {\n Optional<UUID> opOwnerUUID = damager.get(TameableData.class).get().owner().get();\n if (opOwnerUUID.isPresent()) {\n UUID uuid = opOwnerUUID.get();\n if (plugin.getServer().getOfflinePlayer(uuid).map(OfflinePlayer::isOnline).orElse(false)) {\n killer = ((SpongePlayer) plugin.getServer().getPlayer(uuid).get()).getHandle();\n // Use a bone to show the case was a wolf\n weapon = ItemStack.builder().itemType(ItemTypes.BONE).quantity(1).build();\n }\n }\n }\n\n if (killer == null)\n return;\n\n // Check the killers world just incase for some reason the\n // killed player was teleported to another world\n if (plugin.getConfigManager().getPvPConfig().getNode(\"ignoredWorlds\").getCollectionValue(String.class).contains(killer.getWorld().getName()))\n return;\n\n TrackerUtil.updatePvPStats(plugin.getServer().getOfflinePlayer(killed.getUniqueId().toString()).get(),\n plugin.getServer().getOfflinePlayer(killer.getUniqueId().toString()).get());\n\n TrackerInterface pvpTracker = plugin.getTrackerManager().getPvPInterface();\n if (pvpTracker.getDeathMessageManager().isDefaultMessagesOverriden())\n event.setMessageCancelled(true);\n\n pvpTracker.getDeathMessageManager().sendItemMessage(killer.getName(), killed.getName(), weapon.getType().getName().toLowerCase());\n pvpTracker.getRecapManager().getDeathRecaps().get(killed.getName()).setVisible(true);\n }", "@EventHandler\r\n \tpublic void onEntityExplode(EntityExplodeEvent event) \r\n \t{\n \t\tif (event.getEntityType() == EntityType.PRIMED_TNT) \r\n \t\t{\r\n \t\t\tLocation eventLoc = event.getLocation();\r\n \t\t\tServer server = plugin.getServer();\r\n \t\t\t\r\n \t\t\t// Red towers\r\n \t\t\tif (redBuildings.DestroyBuilding(BuildingType.Tower, eventLoc))\r\n \t\t\t{\r\n \t\t\t\ttowerCounts.put(\"red\", redBuildings.BuildingsCount(BuildingType.Tower));\r\n\t\t\t\tserver.broadcastMessage(ChatColor.YELLOW + \"A \"+ ChatColor.RED + \"RED\" + ChatColor.YELLOW + \" Tower Has Been Destroyed! (\" + towerCounts.get(\"red\") + \" remaining)\");\r\n\r\n\t\t\t\t// Check if all towers are destroyed\r\n \t\t\t\t\r\n \t\t\t\tif (towerCounts.get(\"red\") == 0) \r\n \t\t\t\t\tserver.broadcastMessage(ChatColor.YELLOW + \"All \"+ ChatColor.RED + \"RED\" + ChatColor.YELLOW + \" Towers Are Destroyed! Defend the NEXUS!\");\r\n \t\t\t}\r\n \t\t\t\r\n \t\t\t// Blue Towers\r\n \t\t\tif (blueBuildings.DestroyBuilding(BuildingType.Tower, eventLoc))\r\n \t\t\t{\r\n \t\t\t\ttowerCounts.put(\"blue\", blueBuildings.BuildingsCount(BuildingType.Tower));\r\n\t\t\t\tserver.broadcastMessage(ChatColor.YELLOW + \"A \"+ ChatColor.BLUE + \"BLUE\" + ChatColor.YELLOW + \" Tower Has Been Destroyed! (\" + towerCounts.get(\"blue\") + \" remaining)\");\r\n \r\n \t\t\t\t// Check if all towers are destroyed\r\n \t\t\t\tif (towerCounts.get(\"blue\") == 0) \r\n \t\t\t\t\tserver.broadcastMessage(ChatColor.YELLOW + \"All \"+ ChatColor.BLUE + \"BLUE\" + ChatColor.YELLOW + \" Towers Are Destroyed! Defend the NEXUS!\");\r\n \t\t\t}\r\n \t\t\t\r\n \t\t\t\r\n \t\t\t// Nexus\r\n \t\t\tif (redBuildings.DestroyBuilding(BuildingType.Nexus, eventLoc))\r\n \t\t\t{\r\n \t\t\t\tserver.broadcastMessage(ChatColor.RED + \"The RED NEXUS Has Been Destroyed!\" + ChatColor.BLUE + \" BLUE WINS!\");\r\n \t\t\t}\r\n \t\t\telse if (blueBuildings.DestroyBuilding(BuildingType.Nexus, eventLoc))\r\n \t\t\t{\r\n \t\t\t\tserver.broadcastMessage(ChatColor.BLUE + \"The BLUE NEXUS Has Been Destroyed!\" + ChatColor.RED + \" RED WINS!\");\r\n \t\t\t}\r\n \t\t}\r\n \t\t\r\n \t}", "public void ExecuteAction()\n {\n ActionTarget oTarget = mVecTargets.get( 0 );\n\n // Check if attack lands: compute chance of hitting the target\n if ( RandomGenerator.GetInstance().GetRandom( 1, 100 ) <=\n mSourceUnit.GetHitChance( oTarget.mCell.GetUnit() ) )\n {\n // Get the attack information from the attacking unit\n double dFinalDamage = Math.max(\n 1,\n mSourceUnit.GetUnit().GetResultingAttributes().GetStrength() -\n oTarget.mCell.GetUnit().GetUnit().GetResultingAttributes().GetPhysicalDef() );\n\n // Check critical chance\n if ( RandomGenerator.GetInstance().GetRandom( 1, 100 ) <=\n mSourceUnit.GetCritChance() )\n {\n dFinalDamage *= 1.5;\n oTarget.mActionStatus = ActionStatus.STATUS_CRITICAL;\n }\n else\n {\n oTarget.mActionStatus = ActionStatus.STATUS_SUCCESS;\n }\n\n // Add random portion to damage (10% of base damage)\n dFinalDamage = RandomGenerator.GetInstance().GetRandom(\n dFinalDamage - ( dFinalDamage / 10 ),\n dFinalDamage + ( dFinalDamage / 10 ) );\n mDamage = oTarget.mCell.GetUnit().ApplyDamage( dFinalDamage );\n\n // Add Slow status to target\n oTarget.mCell.GetUnit().SetStatus( new UnitStatusSlow(\n SLOW_TURN_DURATION,\n oTarget.mCell.GetUnit(),\n SLOW_PERCENTAGE ) );\n\n }\n else\n {\n mDamage = 0;\n oTarget.mActionStatus = ActionStatus.STATUS_MISS;\n }\n\n NotifyActionUpdate();\n ResetAttackArray();\n mSourceUnit.SetActionPerformed();\n }", "public void dropExplosives() {\n // Updates the time elapsed for each of the explosives\n for (int i=0; i<this.explosives.size(); i++) {\n Explosive dormantExplosive = this.explosives.get(i);\n dormantExplosive.increaseTime();\n }\n // If the Airplane has reached the end, doesn't detect any enemies\n // Isn't deleted straight away as it needs to wait for explosives to detonate\n if (super.outOfBounds()) {return;}\n this.timeElapsedDrop += ShadowDefend.getTimescale()/FPS;\n //Adds a new explosive\n if (this.timeElapsedDrop >= this.dropTime) {\n this.timeElapsedDrop = 0;\n Explosive newExplosive = new Explosive(super.getCenter());\n // Centers the explosive at the airplane's current position\n newExplosive.centerRectAt(super.getCenter());\n this.explosives.add(newExplosive);\n // Generates a new drop time in range\n this.dropTime = generateDropTime();\n this.numDropped++;\n }\n\n }", "void willSpawnAfterDeath(List<String> powerupsInHand) throws RemoteException;", "@Override\r\n\t\tpublic void run() {\n\t\t\t\r\n\t\t\tnew BukkitRunnable() {\r\n\t\t\t\t\r\n\t\t\t\t@Override\r\n\t\t\t\tpublic void run() {\r\n\t\t\t\t\t// TODO Auto-generated method stub\r\n\t\t\t\t\t\r\n\t\t\t\t\tfor(Entity as: Bukkit.getWorld(\"world\").getEntities()) {\r\n\t\t\t\t\t\tif(as instanceof ArmorStand) {\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tas.remove();\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t//TOPS\r\n\t\t\t\t\r\n\t\t\t\t\tif(MetodosWarps.containsWarp(\"topkills\")) {\r\n\t\t\t\t\t getTop(locTopKILLS,\"Kills\");\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žAžlTOP KILLS ATUALIZADO COM SUCESSO! \\n \");\t\r\n\t\t\t\t\t}else {\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žcžlO TOP KILLS NAO PODE SER CARREGADO, POIS A WARP topkills NAO ESTA SETADA! \\n \");\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(MetodosWarps.containsWarp(\"topcoins\")) {\r\n\t\t\t\t\t getTop(locTopCoins,\"Coins\");\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žAžlTOP COINS ATUALIZADO COM SUCESSO! \\n \");\t\r\n\t\t\t\t\t}else {\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žcžlO TOP COINS NAO PODE SER CARREGADO, POIS A WARP topkills NAO ESTA SETADA! \\n \");\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(MetodosWarps.containsWarp(\"top1v1\")) {\r\n\t\t\t\t\t getTop(locTop1v1,\"wins\");\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žAžlTOP 1v1 ATUALIZADO COM SUCESSO! \\n \");\t\r\n\t\t\t\t\t}else {\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žcžlO TOP 1v1 NAO PODE SER CARREGADO, POIS A WARP top1v1 NAO ESTA SETADA! \\n \");\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t//Caixa misteriosa\r\n\t\t\t\t\t\r\n\t\t\t\t\tif(MetodosWarps.containsWarp(\"misteryBox\")) {\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t Spawn(misteryBox, \"žažlCAIXA MISTERIOSA\",misteryBox.getY()-1.7);\r\n\t\t\t\t\t Spawn(misteryBox, \"žežlEM BREVE!\",misteryBox.getY()-2);\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žAžlMYSTERYBOX ATUALIZADO COM SUCESSO! \\n \");\t\r\n\t\t\t\t\t}else {\r\n\t\t\t\t\t\tBukkit.getConsoleSender().sendMessage(\" \\n žcžlO TOP COINS NAO PODE SER CARREGADO, POIS A WARP misteryBox NAO ESTA SETADA! \\n \");\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}.runTaskLater(Main.plugin, 20);\r\n\t\t\t\r\n\t\t}", "@Override\n\tpublic void act() {\n\n\t\t//Location symbol of a Droid (Stack Overflow 2010)\n\t\tchar locationSymbol = this.world.getEntityManager().whereIs(this).getSymbol();\n\t\t\n\t\t//Begin act\n\t\tsay(describeLocation());\t\t\n\t\t\n\t\t//Check for the lose condition that R2 is disassembled\n\t\t//If R2's HP is <=0\n\t\tif (this.isDead())\n\t\t{\n\t\t\t//If R2 is disassembled\n\t\t\tif(this.getIsDisassembled())\n\t\t\t{\n\t\t\t\t//Is the symbol of the disassembled Droid is R2's\n\t\t\t\tif(this.getSymbol().contains(\"{R2}\"))\n\t\t\t\t{\n\t\t\t\t\t//Message stating R2 was disassembled\n\t\t\t\t\tthis.messageRenderer.render(\"\\n\\nR2-D2 has been disassembled!\");\n\t\t\t\t\t\n\t\t\t\t\t//Scheduler schedules the loss\n\t\t\t\t\tscheduler.lossSchedule(this.messageRenderer);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\t//If a Droid is immobile (Dead)\n\t\tif (this.getIsImmobile() == true) {\n\t\t\tsay(this.getShortDescription() + \" is immobile. \");\n\t\t\t\t\t\t\n\t\t\tif(this.getOwner() != null)\n\t\t\t{\n\t\t\t\tsay(\"Owned. checking in owners follow list\");\n\t\t\t\t\n\t\t\t\tString thisDroidNoBraces = this.getSymbol().substring(1, this.getSymbol().length()-1);\n\n\t\t\t\tint indexofDroid = this.getOwner().getFollowerList().indexOf(thisDroidNoBraces);\n\t\t\t\t\n\t\t\t\tif (this.getOwner().getFollowerList().get(indexofDroid).equals(thisDroidNoBraces))\n\t\t\t\t{\n\t\t\t\t\tsay(\"Removing\");\n\t\t\t\t\tthis.getOwner().getFollowerList().remove(thisDroidNoBraces);\n\t\t\t\t\tthis.getOwner().getFollowerListSWActors().remove(this);\n\t\t\t\t\tthis.setOwner(null);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t\n\t\t\t}\n\t\t}\n\t\t\n\t\t//If a Droid is mobile and human controlled\n\t\telse if (this.humanControlled == true) {\n\t\t\t\n\t\t\t//Following Owner - since humancontrolled.\n\t\t\t\n\t\t\t\n\t\t\tif (isDead()) \n\t\t\t{\n\t\t\t\tthis.setIsImmobile(true);\n\t\t\t\treturn;\n\t\t\t} \n\t\t\t\n\t\t\telse\n\t\t\t{\n\t\t\t\t//Get owners' location\n\t\t\t\tSWLocation ownerloc = this.world.getEntityManager().whereIs(this.getOwner());\n\t\t\t\t\n\t\t\t\t//Set Droids' position to owners' location (follow)\n\t\t\t\tthis.world.getEntityManager().setLocation(this, ownerloc);\n\t\t\t\t\n\t\t\t\t//Take damage if moving to the Badlands\n\t\t\t\tif (locationSymbol == 'b') { //IF the Droid is at the Badlands\n\t\t\t\t\tint NewHP = this.getHitpoints() - 2;\t//Take 2 from the Droids' health\n\t\t\t\t\tthis.setHitpoints(NewHP);\n\t\t\t\t\n\t\t\t\t\tsay(this.getShortDescription() + \" has lost health by moving into the Badlands!\");\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tselfHeal();\n\t\t\t}\t\n\t\t} \n\t\t\n\t\t//C-3PO Droid specific act ()code\n\t\telse if (this.getSymbol() == \"C3\") {\n\t\t\t\n\t\t\t//Double precision number to represenet C-3PO's chance of speaking\n\t\t\tdouble c3Speak = Math.random();\n\t\t\t\n\t\t\t//10% chance of occuring a 0.9 or above\n\t\t\tif (c3Speak >= 0.9) {\n\t\t\t\t//Call C-3PO speak method (he talks!)\n\t\t\t\tc3POSpeaks();\n\t\t\t}\n\t\t\telse {\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\t\n\t\t//R2-D2 Repair droid specific act() code\n\t\telse if (this.getSymbol() == \"R2\") {\n\t\t\t\n\t\t\tthis.messageRenderer.render(\"R2 DISS: \" + this.isDisassembled);\n\t\t\t\n\t\t\t//Describe who R2 can see\n\t\t\t//get the contents of the location\n\t\t\tList<SWEntityInterface> r2contents = this.world.getEntityManager().contents(this.world.getEntityManager().whereIs(this));\n\t\t\t\n\t\t\t//and describe the contents\n\t\t\tif (r2contents.size() > 1) { // if it is equal to one, the only thing here is R2, so there is nothing to report\n\t\t\t\tfor (SWEntityInterface r2entity : r2contents) {\n\t\t\t\t\tif (r2entity.getSymbol().contains(\"D\")) { // If R2 comes across a Droid (Stack Overflow 2010)\n\t\t\t\t\t\tsay(this.getShortDescription() + \" has come accross a Droid!\");\n\t\t\t\t\t\t\n\t\t\t\t\t\t//Cast target entity as a Droid for checking what it needs from R2\n\t\t\t\t\t\tDroid targetr2 = (Droid) r2entity;\n\t\t\t\t\t\t\n\t\t\t\t\t\t//R2 attempts to disassemble the Droid if its immobile\n\t\t\t\t\t\tif (targetr2.isImmobile && targetr2.isDisassembled == false) {\n\t\t\t\t\t\t\tDisassemble r2diss = new Disassemble(r2entity, messageRenderer);\n\t\t\t\t\t\t\tscheduler.schedule(r2diss, this, 1);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t//R2 tries to repair a droid who is immobile and disassembled\n\t\t\t\t\t\telse if (targetr2.isImmobile && targetr2.isDisassembled) {\n\t\t\t\t\t\t\tif (this.getItemCarried() != null) {\n\t\t\t\t\t\t\t\tRepair r2rep = new Repair(r2entity, messageRenderer);\n\t\t\t\t\t\t\t\tscheduler.schedule(r2rep, this, 1);\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t//R2 attempts to Heal a Droid if active and not disassembled\n\t\t\t\t\t\telse if (targetr2.isDisassembled == false && targetr2.isImmobile == false)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tHealDroid r2heal = new HealDroid(r2entity, messageRenderer);\n\t\t\t\t\t\t\tscheduler.schedule(r2heal, this, 1);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\t\t\n\t\t\t//Heals himself if he can\n\t\t\t\n\t\t\tHealDroid droidHealR2 = new HealDroid(this, messageRenderer);\n\t\t\tscheduler.schedule(droidHealR2, this, 1);\n\t\t\t\n\t\t\t//R2 moves\n\t\t\tDirection R2Direction = this.getDroidPatrol().getNext();\n\t\t\tsay(getShortDescription() + \" moves \" + R2Direction);\n\t\t\tMove myMove = new Move(R2Direction, messageRenderer, world);\n\n\t\t\tscheduler.schedule(myMove, this, 1);\n\t\n\t\t}\n\t\t\n\t\t//If a Droid is not immobile, and not human controlled (roaming)\n\t\telse {\t\n\t\t\t\n\t\t\t//Picking up an oil can\n\t\t\t//Get contents of the current location\n\t\t\tList<SWEntityInterface> contents = this.world.getEntityManager().contents(this.world.getEntityManager().whereIs(this));\n\t\t\t\n\t\t\t//and describe the contents\n\t\t\tif (contents.size() > 1) { // if it is equal to one, the only thing here is this Player, so there is nothing to report\n\t\t\t\tfor (SWEntityInterface entity : contents) {\n\t\t\t\t\tif (entity != this) { // don't include self in scene description\n\t\t\t\t\t\tif (entity.getSymbol() == \"x\") {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//The Droid is standing over a oil can. Does it pick it up?\n\t\t\t\t\t\t\tif (Math.random() > 0.5){ //Half a chance...\n\t\t\t\t\t\t\t\tsay(this.getShortDescription() + \" decided to pick up \" + entity.getShortDescription());\n\t\n\t\t\t\t\t\t\t\t//Droid takes the oil can. Scheduler implements the Take.\n\t\t\t\t\t\t\t\tTake droidTakes = new Take(entity, messageRenderer);\n\t\t\t\t\t\t\t\tscheduler.schedule(droidTakes, this, 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse { //The Droid passes over the oil can.\n\t\t\t\t\t\t\t\tsay(this.getShortDescription() + \" decided not to pick up\" + entity.getShortDescription());\n\t\t\t\t\t\t\t}\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\tif (Math.random() > 0.8){\n\t\t\t\trandomMovement();\n\t\t\t}\n\t\t\t\n\t\t\t//If a Roaming Droid is at the Badlands, they lose health\n\t\t\t\n\t\t\tif (locationSymbol == 'b') { //IF the Droid is at the Badlands\n\t\t\t\tint NewHP = this.getHitpoints() - 2;\t//Take 2 from the Droids' health\n\t\t\t\tthis.setHitpoints(NewHP);\n\t\t\t\n\t\t\t\tsay(this.getShortDescription() + \" has lost health by moving into the Badlands!\");\n\t\t\t}\n\t\t\t\n\t\t\t/*Self healing\n\t\t\tImplementation that if a Droids' health gets below half, they will attempt to heal themselves IF they \n\t\t\tare carrying an oil can\n\t\t\t*/\n\t\t\tselfHeal();\n\t\t\t\n\t\t\t\n\t\t}\t\n\t}", "@Override\n\tpublic void onDeath() {\n\t\tsuper.onDeath();\n\n\t\ttentacles.stream().filter(npc -> !npc.isDead()).forEach(npc -> npc.setDead(true));\n\t\trespiratorySystems.stream().filter(npc -> !npc.isDead()).forEach(npc -> npc.setDead(true));\n\t\tspawns.stream().filter(npc -> !npc.isDead()).forEach(npc -> npc.setDead(true));\n\n\t\ttentacles.clear();\n\t\trespiratorySystems.clear();\n\t\tspawns.clear();\n\t}", "public abstract void attack(Vector2 spawnPos, Vector2 target);", "public void die() {\r\n final Entity e = entity;\r\n final EnchantArrow arrow = this;\r\n Bukkit.getServer().getScheduler().scheduleSyncDelayedTask(Storage.zenchantments, () -> {\r\n if (Storage.advancedProjectiles.containsKey(e)) {\r\n if (Storage.advancedProjectiles.get(e).size() == 1) {\r\n Storage.advancedProjectiles.remove(e);\r\n } else {\r\n Storage.advancedProjectiles.get(e).remove(arrow);\r\n }\r\n }\r\n }, 1);\r\n }", "@Deprecated\n/* */ protected static boolean performAttack(int pos, boolean aiming, Creature performer, Skills performerSkills, Creature defender, Skills defenderSkills, Item attWeapon, Item defPrimWeapon, double attBonus, double defBonus, Skill attackerFightSkill, Skill defenderFightSkill, int counter) {\n/* 829 */ boolean shieldBlocked = false;\n/* 830 */ boolean done = false;\n/* 831 */ Skill primWeaponSkill = null;\n/* 832 */ Skill defPrimWeaponSkill = null;\n/* 833 */ Item defShield = null;\n/* 834 */ Skill defShieldSkill = null;\n/* 835 */ int skillnum = -10;\n/* 836 */ boolean dryrun = false;\n/* */ \n/* 838 */ if (performer.isPlayer()) {\n/* */ \n/* 840 */ if (defender.isPlayer() || defender.isReborn()) {\n/* */ \n/* */ \n/* 843 */ dryrun = true;\n/* */ }\n/* 845 */ else if (defender.isKingdomGuard() || (defender\n/* 846 */ .isSpiritGuard() && defender.getKingdomId() == performer.getKingdomId())) {\n/* 847 */ dryrun = true;\n/* */ } \n/* 849 */ } else if (performer.isKingdomGuard() || (performer\n/* 850 */ .isSpiritGuard() && defender.getKingdomId() == performer.getKingdomId())) {\n/* 851 */ dryrun = true;\n/* 852 */ } if ((defender.isPlayer() && !defender.hasLink()) || (performer.isPlayer() && !performer.hasLink()))\n/* 853 */ dryrun = true; \n/* 854 */ if (defender.getStatus().getStunned() > 0.0F) {\n/* */ \n/* 856 */ defBonus -= 20.0D;\n/* 857 */ attBonus += 20.0D;\n/* */ } \n/* 859 */ if (attWeapon != null)\n/* */ {\n/* 861 */ if (attWeapon.isBodyPart()) {\n/* */ \n/* */ \n/* */ try {\n/* 865 */ skillnum = 10052;\n/* 866 */ primWeaponSkill = performerSkills.getSkill(skillnum);\n/* */ }\n/* 868 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 870 */ if (skillnum != -10)\n/* 871 */ primWeaponSkill = performerSkills.learn(skillnum, 1.0F); \n/* */ } \n/* 873 */ if (performer.isPlayer() && defender.isPlayer())\n/* */ {\n/* 875 */ if (primWeaponSkill.getKnowledge(0.0D) >= 20.0D) {\n/* 876 */ dryrun = true;\n/* */ }\n/* */ }\n/* */ } else {\n/* */ \n/* */ \n/* */ try {\n/* 883 */ skillnum = attWeapon.getPrimarySkill();\n/* 884 */ primWeaponSkill = performerSkills.getSkill(skillnum);\n/* */ }\n/* 886 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 888 */ if (skillnum != -10) {\n/* 889 */ primWeaponSkill = performerSkills.learn(skillnum, 1.0F);\n/* */ }\n/* */ } \n/* */ } \n/* */ }\n/* */ \n/* */ \n/* 896 */ skillnum = -10;\n/* 897 */ if (defPrimWeapon != null)\n/* */ {\n/* 899 */ if (defPrimWeapon.isBodyPart()) {\n/* */ \n/* */ \n/* */ try {\n/* 903 */ skillnum = 10052;\n/* 904 */ defPrimWeaponSkill = defenderSkills.getSkill(skillnum);\n/* */ }\n/* 906 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 908 */ if (skillnum != -10)\n/* 909 */ defPrimWeaponSkill = defenderSkills.learn(skillnum, 1.0F); \n/* */ } \n/* 911 */ if (performer.isPlayer() && defender.isPlayer())\n/* */ {\n/* 913 */ if (defPrimWeaponSkill.getKnowledge(0.0D) >= 20.0D) {\n/* 914 */ dryrun = true;\n/* */ }\n/* */ }\n/* */ } else {\n/* */ \n/* */ \n/* */ try {\n/* 921 */ skillnum = defPrimWeapon.getPrimarySkill();\n/* 922 */ defPrimWeaponSkill = defenderSkills.getSkill(skillnum);\n/* */ }\n/* 924 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 926 */ if (skillnum != -10) {\n/* 927 */ defPrimWeaponSkill = defenderSkills.learn(skillnum, 1.0F);\n/* */ }\n/* */ } \n/* */ } \n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 939 */ Skill attStrengthSkill = null;\n/* */ \n/* */ try {\n/* 942 */ attStrengthSkill = performerSkills.getSkill(102);\n/* */ }\n/* 944 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 946 */ attStrengthSkill = performerSkills.learn(102, 1.0F);\n/* 947 */ logger.log(Level.WARNING, performer.getName() + \" had no strength. Weird.\");\n/* */ } \n/* */ \n/* 950 */ double bonus = 0.0D;\n/* 951 */ if (primWeaponSkill != null) {\n/* */ \n/* 953 */ float mod = getMod(performer, defender, primWeaponSkill);\n/* 954 */ bonus = Math.max(-20.0D, primWeaponSkill.skillCheck(\n/* 955 */ Math.abs(primWeaponSkill.getKnowledge(0.0D) - attWeapon.getCurrentQualityLevel()), attBonus, (mod == 0.0F || dryrun), \n/* 956 */ (float)(long)Math.max(1.0F, counter * mod)));\n/* */ } \n/* */ \n/* */ \n/* 960 */ skillnum = -10;\n/* 961 */ defShield = defender.getShield();\n/* 962 */ if (defShield != null) {\n/* */ \n/* */ try {\n/* */ \n/* 966 */ skillnum = defShield.getPrimarySkill();\n/* 967 */ defShieldSkill = defenderSkills.getSkill(skillnum);\n/* */ }\n/* 969 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 971 */ if (skillnum != -10) {\n/* 972 */ defShieldSkill = defenderSkills.learn(skillnum, 1.0F);\n/* */ }\n/* */ } \n/* */ }\n/* 976 */ if (aiming) {\n/* */ \n/* 978 */ if (pos == 1) {\n/* */ \n/* 980 */ bonus = -60.0D;\n/* */ }\n/* 982 */ else if (pos == 29) {\n/* */ \n/* 984 */ bonus = -80.0D;\n/* */ }\n/* 986 */ else if (pos == 2) {\n/* */ \n/* 988 */ bonus = -40.0D;\n/* */ }\n/* 990 */ else if (pos == 3) {\n/* */ \n/* 992 */ bonus = -30.0D;\n/* */ }\n/* 994 */ else if (pos == 4) {\n/* */ \n/* 996 */ bonus = -30.0D;\n/* */ }\n/* 998 */ else if (pos == 34) {\n/* */ \n/* 1000 */ bonus = -30.0D;\n/* */ } \n/* 1002 */ pos = getRealPosition(pos);\n/* */ } else {\n/* */ \n/* */ \n/* */ try {\n/* */ \n/* 1008 */ pos = defender.getBody().getRandomWoundPos();\n/* */ }\n/* 1010 */ catch (Exception ex) {\n/* */ \n/* 1012 */ logger.log(Level.WARNING, \"Problem getting a Random Wound Position for \" + defender.getName() + \": due to \" + ex\n/* 1013 */ .getMessage(), ex);\n/* */ } \n/* */ } \n/* 1016 */ if (performer.getEnemyPresense() > 1200 && defender.isPlayer())\n/* 1017 */ bonus += 20.0D; \n/* 1018 */ double attCheck = 0.0D;\n/* 1019 */ boolean defFumbleShield = false;\n/* 1020 */ boolean defFumbleParry = false;\n/* */ \n/* 1022 */ boolean crit = false;\n/* */ \n/* 1024 */ if (defender.isPlayer()) {\n/* */ \n/* 1026 */ int critChance = attWeapon.getDamagePercent();\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1032 */ if (Server.rand.nextInt(100 - Math.min(3, critChance)) == 0)\n/* */ {\n/* 1034 */ crit = true;\n/* */ }\n/* */ } \n/* */ \n/* */ \n/* 1039 */ if (attWeapon.isBodyPartAttached()) {\n/* */ \n/* 1041 */ float mod = getMod(performer, defender, attackerFightSkill);\n/* */ \n/* 1043 */ attCheck = attackerFightSkill.skillCheck(defenderFightSkill\n/* 1044 */ .getKnowledge(defBonus) / Math.min(5, defender.getAttackers()), bonus, (mod == 0.0F || dryrun), \n/* 1045 */ (float)(long)Math.max(1.0F, counter * mod));\n/* */ }\n/* */ else {\n/* */ \n/* 1049 */ float mod = getMod(performer, defender, attackerFightSkill);\n/* 1050 */ attCheck = attackerFightSkill.skillCheck(defenderFightSkill\n/* 1051 */ .getKnowledge(defBonus) / Math.min(5, defender.getAttackers()), attWeapon, bonus, (mod == 0.0F || dryrun), \n/* 1052 */ (float)(long)Math.max(1.0F, counter * mod));\n/* */ } \n/* 1054 */ byte type = (performer.getTemplate()).combatDamageType;\n/* 1055 */ if (attWeapon.isWeaponSword()) {\n/* */ \n/* 1057 */ if (Server.rand.nextInt(2) == 0) {\n/* 1058 */ type = 1;\n/* */ } else {\n/* 1060 */ type = 2;\n/* */ } \n/* 1062 */ } else if (attWeapon.isWeaponSlash()) {\n/* 1063 */ type = 1;\n/* 1064 */ } else if (attWeapon.isWeaponPierce()) {\n/* 1065 */ type = 2;\n/* 1066 */ } else if (attWeapon.isBodyPart()) {\n/* */ \n/* 1068 */ if (attWeapon.getTemplateId() == 17) {\n/* 1069 */ type = 3;\n/* 1070 */ } else if (attWeapon.getTemplateId() == 12) {\n/* 1071 */ type = 0;\n/* */ } \n/* */ } \n/* 1074 */ String attString = getAttackString(performer, attWeapon, type);\n/* */ \n/* */ \n/* */ \n/* */ \n/* 1079 */ double defCheck = 0.0D;\n/* 1080 */ double damage = getWeaponDamage(attWeapon, attStrengthSkill);\n/* */ \n/* 1082 */ if (performer.getDeity() != null && performer.getDeity().isWarrior() && \n/* 1083 */ performer.getFaith() >= 40.0F && performer.getFavor() >= 20.0F)\n/* 1084 */ damage = Math.min(4000.0D, damage * 1.25D); \n/* 1085 */ if (performer.getEnemyPresense() > 1200 && defender.isPlayer()) {\n/* 1086 */ damage *= Math.min(4000.0F, 1.15F);\n/* */ }\n/* */ \n/* 1089 */ if (defShield != null || crit) {\n/* */ \n/* 1091 */ if (!crit)\n/* */ {\n/* 1093 */ if (pos == 9) {\n/* */ \n/* 1095 */ shieldBlocked = true;\n/* */ }\n/* 1097 */ else if (defender.getStatus().getStamina() >= 300 && !defender.isMoving()) {\n/* */ \n/* 1099 */ defCheck = 0.0D;\n/* 1100 */ if (defShieldSkill != null) {\n/* */ \n/* 1102 */ float mod = getMod(performer, defender, defShieldSkill);\n/* 1103 */ defCheck = defShieldSkill.skillCheck(attCheck, defShield, defBonus, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ } \n/* */ \n/* */ \n/* 1107 */ defCheck += (defShield.getSizeY() + defShield.getSizeZ()) / 10.0D;\n/* */ \n/* */ \n/* 1110 */ defender.getStatus().modifyStamina(-300.0F);\n/* */ } \n/* */ }\n/* 1113 */ if (defCheck > 0.0D || shieldBlocked) {\n/* */ \n/* 1115 */ shieldBlocked = true;\n/* 1116 */ if (defender.isPlayer()) {\n/* 1117 */ defShield.setDamage(defShield.getDamage() + 0.001F * (float)damage * defShield.getDamageModifier());\n/* */ }\n/* */ }\n/* 1120 */ else if (defCheck < -90.0D) {\n/* */ \n/* 1122 */ defFumbleShield = true;\n/* */ } \n/* */ } \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1134 */ if (!shieldBlocked || crit) {\n/* */ \n/* 1136 */ boolean parryPrimWeapon = true;\n/* 1137 */ defCheck = 0.0D;\n/* 1138 */ if (!crit && !defender.isMoving()) {\n/* */ \n/* 1140 */ int parryTime = 100;\n/* 1141 */ if (defender.getFightStyle() == 2) {\n/* 1142 */ parryTime = 40;\n/* 1143 */ } else if (defender.getFightStyle() == 1) {\n/* 1144 */ parryTime = 160;\n/* */ } \n/* 1146 */ if (WurmCalendar.currentTime > defender.lastParry + Server.rand.nextInt(parryTime) && \n/* 1147 */ defPrimWeapon != null && !defPrimWeapon.isWeaponAxe())\n/* */ {\n/* 1149 */ if (!defPrimWeapon.isBodyPart() || defPrimWeapon.getAuxData() == 100) {\n/* */ \n/* 1151 */ if (defender.getStatus().getStamina() >= 300) {\n/* */ \n/* 1153 */ if (defPrimWeaponSkill != null) {\n/* */ \n/* 1155 */ float mod = getMod(performer, defender, defPrimWeaponSkill);\n/* 1156 */ defCheck = defPrimWeaponSkill.skillCheck((attCheck * defender\n/* 1157 */ .getAttackers() + defPrimWeapon.getWeightGrams() / 200.0D) / \n/* 1158 */ getWeaponParryBonus(defPrimWeapon), defPrimWeapon, defBonus, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ \n/* 1160 */ defender.lastParry = WurmCalendar.currentTime;\n/* 1161 */ defender.getStatus().modifyStamina(-300.0F);\n/* */ } \n/* 1163 */ if (defCheck < -90.0D)\n/* */ {\n/* 1165 */ defFumbleParry = true;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ }\n/* 1182 */ else if (defCheck < 0.0D && Server.rand.nextInt(50) == 0)\n/* */ {\n/* 1184 */ defCheck = secondaryParry(performer, attCheck, defender, defenderSkills, defCheck, defBonus, dryrun);\n/* */ \n/* 1186 */ if (defCheck < -90.0D) {\n/* */ \n/* 1188 */ defFumbleParry = true;\n/* */ }\n/* 1190 */ else if (defCheck > 0.0D) {\n/* 1191 */ parryPrimWeapon = false;\n/* */ }\n/* */ \n/* */ }\n/* */ \n/* */ } \n/* 1197 */ } else if (defender.getStatus().getStamina() >= 300) {\n/* */ \n/* 1199 */ if (defPrimWeaponSkill != null) {\n/* */ \n/* */ \n/* */ \n/* */ \n/* 1204 */ float mod = getMod(performer, defender, defPrimWeaponSkill);\n/* 1205 */ defCheck = defPrimWeaponSkill.skillCheck(Math.min(100, 80 * defender.getAttackers()), defBonus, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ \n/* 1207 */ defender.lastParry = WurmCalendar.currentTime;\n/* 1208 */ defender.getStatus().modifyStamina(-300.0F);\n/* */ } \n/* 1210 */ if (defCheck < 0.0D && Server.rand.nextInt(50) == 0) {\n/* */ \n/* 1212 */ defCheck = secondaryParry(performer, attCheck, defender, defenderSkills, defCheck, defBonus, dryrun);\n/* */ \n/* 1214 */ if (defCheck < -90.0D) {\n/* */ \n/* 1216 */ defFumbleParry = true;\n/* */ }\n/* 1218 */ else if (defCheck > 0.0D) {\n/* 1219 */ parryPrimWeapon = false;\n/* */ } \n/* */ } \n/* */ } \n/* */ }\n/* */ } \n/* 1225 */ if (defCheck <= 0.0D || defFumbleShield || crit) {\n/* */ \n/* */ \n/* */ \n/* 1229 */ if (!defFumbleShield && !defFumbleParry && !crit)\n/* */ {\n/* 1231 */ if (defender.getStatus().getStamina() >= 300) {\n/* */ \n/* 1233 */ defender.getStatus().modifyStamina(-300.0F);\n/* 1234 */ Skill defenderBodyControl = null;\n/* */ \n/* */ try {\n/* 1237 */ defenderBodyControl = defenderSkills.getSkill(104);\n/* */ }\n/* 1239 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 1241 */ defenderBodyControl = defenderSkills.learn(104, 1.0F);\n/* 1242 */ logger.log(Level.WARNING, defender.getName() + \" no body control?\");\n/* */ } \n/* 1244 */ if (defenderBodyControl != null) {\n/* */ \n/* 1246 */ float mod = getMod(performer, defender, defenderBodyControl);\n/* 1247 */ defCheck = defenderBodyControl.skillCheck(attCheck, 0.0D, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ } else {\n/* */ \n/* 1250 */ logger.log(Level.WARNING, defender.getName() + \" has no body control!\");\n/* */ } \n/* */ } } \n/* 1253 */ if (defCheck <= 0.0D || crit) {\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1261 */ Item armour = null;\n/* */ \n/* */ \n/* 1264 */ float armourMod = defender.getArmourMod();\n/* 1265 */ float evasionChance = ArmourTemplate.calculateGlanceRate(defender.getArmourType(), armour, type, armourMod);\n/* 1266 */ if (!performer.isPlayer() && !defender.isPlayer() && !defender.isUnique())\n/* 1267 */ armourMod = 1.0F; \n/* 1268 */ if (armourMod == 1.0F) {\n/* */ \n/* */ try {\n/* */ \n/* 1272 */ byte bodyPosition = ArmourTemplate.getArmourPosition((byte)pos);\n/* 1273 */ armour = defender.getArmour(bodyPosition);\n/* 1274 */ armourMod = ArmourTemplate.calculateDR(armour, type);\n/* 1275 */ if (defender.isPlayer())\n/* 1276 */ armour.setDamage(armour.getDamage() + \n/* 1277 */ Math.min(1.0F, (float)(damage * armourMod / 80.0D) * armour\n/* */ \n/* 1279 */ .getDamageModifier() * \n/* 1280 */ ArmourTemplate.getArmourDamageModFor(armour, type))); \n/* 1281 */ checkEnchantDestruction(attWeapon, armour, defender);\n/* 1282 */ evasionChance = ArmourTemplate.calculateGlanceRate(null, armour, type, armourMod);\n/* */ }\n/* 1284 */ catch (NoArmourException nsi) {\n/* */ \n/* */ \n/* 1287 */ evasionChance = 1.0F - defender.getArmourMod();\n/* */ }\n/* 1289 */ catch (NoSpaceException nsp) {\n/* */ \n/* 1291 */ logger.log(Level.WARNING, defender.getName() + \" no armour space on loc \" + pos);\n/* */ } \n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1299 */ if (!attWeapon.isBodyPart() || attWeapon.getAuxData() == 100)\n/* */ {\n/* 1301 */ if (performer.isPlayer())\n/* 1302 */ attWeapon.setDamage(attWeapon.getDamage() + (float)(damage * (2.1D - armourMod) / 1000.0D) * attWeapon\n/* 1303 */ .getDamageModifier()); \n/* */ }\n/* 1305 */ if (defender.isUnique()) {\n/* */ \n/* 1307 */ evasionChance = 0.5F;\n/* 1308 */ damage *= armourMod;\n/* */ } \n/* 1310 */ if (Server.rand.nextFloat() < evasionChance) {\n/* */ \n/* 1312 */ if (aiming || performer.spamMode())\n/* 1313 */ performer.getCommunicator().sendNormalServerMessage(\"Your attack glances off \" + defender\n/* 1314 */ .getNameWithGenus() + \"'s armour.\"); \n/* 1315 */ if (defender.spamMode()) {\n/* 1316 */ defender.getCommunicator().sendNormalServerMessage(\"The attack to the \" + defender\n/* 1317 */ .getBody().getWoundLocationString(pos) + \" glances off your armour.\");\n/* */ }\n/* */ }\n/* 1320 */ else if (damage > (5.0F + Server.rand.nextFloat() * 5.0F) || crit) {\n/* */ \n/* 1322 */ if (crit)\n/* */ {\n/* 1324 */ armourMod = 1.0F;\n/* */ }\n/* */ \n/* */ \n/* 1328 */ Battle battle = performer.getBattle();\n/* 1329 */ boolean dead = false;\n/* 1330 */ if (defender.getStaminaSkill().getKnowledge(0.0D) < 2.0D) {\n/* */ \n/* 1332 */ defender.die(false, \"Combat Stam Check Fail\");\n/* 1333 */ dead = true;\n/* */ } else {\n/* */ \n/* 1336 */ dead = addWound(performer, defender, type, pos, damage, armourMod, attString, battle, 0.0F, 0.0F, false, false, false, false);\n/* */ } \n/* 1338 */ if (!dead && attWeapon.getSpellDamageBonus() > 0.0F)\n/* */ {\n/* 1340 */ if (damage * attWeapon.getSpellDamageBonus() / 300.0D > (Server.rand.nextFloat() * 5.0F) || crit) {\n/* 1341 */ dead = defender.addWoundOfType(performer, (byte)4, (byte)pos, false, armourMod, false, damage * attWeapon\n/* 1342 */ .getSpellDamageBonus() / 300.0D, 0.0F, 0.0F, false, false);\n/* */ }\n/* */ }\n/* 1345 */ if (!dead && attWeapon.getWeaponSpellDamageBonus() > 0.0F)\n/* */ {\n/* 1347 */ if (damage * attWeapon.getWeaponSpellDamageBonus() / 300.0D > (Server.rand.nextFloat() * 5.0F))\n/* */ {\n/* 1349 */ dead = defender.addWoundOfType(performer, (byte)6, 1, true, armourMod, false, damage * attWeapon\n/* 1350 */ .getWeaponSpellDamageBonus() / 300.0D, Server.rand\n/* 1351 */ .nextInt((int)attWeapon.getWeaponSpellDamageBonus()), 0.0F, false, false);\n/* */ }\n/* */ }\n/* 1354 */ if (armour != null)\n/* */ {\n/* 1356 */ if (armour.getSpellPainShare() > 0.0F)\n/* */ {\n/* 1358 */ if (performer.isUnique()) {\n/* 1359 */ defender.getCommunicator().sendNormalServerMessage(performer\n/* 1360 */ .getNameWithGenus() + \" ignores the effects of the \" + armour.getName() + \".\");\n/* */ \n/* */ \n/* */ }\n/* 1364 */ else if (damage * armour.getSpellPainShare() / 300.0D > 5.0D) {\n/* */ \n/* 1366 */ addBounceWound(defender, performer, type, pos, damage * armour\n/* 1367 */ .getSpellPainShare() / 300.0D, armourMod, 0.0F, 0.0F, false, true);\n/* */ } \n/* */ }\n/* */ }\n/* */ \n/* */ \n/* */ \n/* 1374 */ if (dead) {\n/* */ \n/* 1376 */ performer.getCommunicator().sendSafeServerMessage(defender.getNameWithGenus() + \" is dead!\");\n/* 1377 */ if (battle != null)\n/* 1378 */ battle.addCasualty(performer, defender); \n/* 1379 */ done = true;\n/* */ \n/* */ \n/* */ }\n/* 1383 */ else if (!defender.hasNoServerSound()) {\n/* 1384 */ SoundPlayer.playSound(defender.getHitSound(), defender, 1.6F);\n/* */ }\n/* */ \n/* */ } else {\n/* */ \n/* 1389 */ if (aiming || performer.spamMode())\n/* */ {\n/* 1391 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1392 */ .getNameWithGenus() + \" takes no real damage from the hit to the \" + defender\n/* 1393 */ .getBody().getWoundLocationString(pos) + \".\");\n/* */ }\n/* 1395 */ if (defender.spamMode()) {\n/* 1396 */ defender.getCommunicator().sendNormalServerMessage(\"You take no real damage from the blow to the \" + defender\n/* */ \n/* 1398 */ .getBody().getWoundLocationString(pos) + \".\");\n/* */ }\n/* */ } \n/* */ } else {\n/* */ \n/* 1403 */ String sstring = \"sound.combat.miss.light\";\n/* 1404 */ if (attCheck < -80.0D) {\n/* 1405 */ sstring = \"sound.combat.miss.heavy\";\n/* 1406 */ } else if (attCheck < -40.0D) {\n/* 1407 */ sstring = \"sound.combat.miss.med\";\n/* 1408 */ } SoundPlayer.playSound(sstring, defender, 1.6F);\n/* 1409 */ if (aiming || performer.spamMode())\n/* */ {\n/* 1411 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1412 */ .getNameWithGenus() + \" \" + getParryString(defCheck) + \" evades the blow to the \" + defender\n/* 1413 */ .getBody().getWoundLocationString(pos) + \".\");\n/* */ }\n/* 1415 */ if (defender.spamMode()) {\n/* 1416 */ defender.getCommunicator().sendNormalServerMessage(\"You \" + \n/* 1417 */ getParryString(defCheck) + \" evade the blow to the \" + defender\n/* 1418 */ .getBody().getWoundLocationString(pos) + \".\");\n/* */ }\n/* */ } \n/* */ } else {\n/* */ \n/* 1423 */ defender.lastParry = WurmCalendar.currentTime;\n/* 1424 */ Item weapon = defPrimWeapon;\n/* 1425 */ if (!parryPrimWeapon)\n/* 1426 */ weapon = defender.getLefthandWeapon(); \n/* 1427 */ if (aiming || performer.spamMode())\n/* */ {\n/* 1429 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1430 */ .getNameWithGenus() + \" \" + getParryString(defCheck) + \" parries with \" + weapon.getNameWithGenus() + \".\");\n/* */ }\n/* */ \n/* */ \n/* 1434 */ if (defender.spamMode())\n/* */ {\n/* 1436 */ defender.getCommunicator().sendNormalServerMessage(\"You \" + \n/* 1437 */ getParryString(defCheck) + \" parry with your \" + weapon.getName() + \".\");\n/* */ }\n/* */ \n/* 1440 */ if (!weapon.isBodyPart() || weapon.getAuxData() == 100) {\n/* */ \n/* 1442 */ if (defender.isPlayer())\n/* */ {\n/* 1444 */ if (weapon.isWeaponSword()) {\n/* 1445 */ weapon.setDamage(weapon.getDamage() + 0.001F * (float)damage * weapon.getDamageModifier());\n/* */ } else {\n/* 1447 */ weapon.setDamage(weapon.getDamage() + 0.005F * (float)damage * weapon.getDamageModifier());\n/* */ } } \n/* 1449 */ if (performer.isPlayer())\n/* */ {\n/* 1451 */ if (!attWeapon.isBodyPart() || attWeapon.getAuxData() == 100) {\n/* 1452 */ attWeapon\n/* 1453 */ .setDamage(attWeapon.getDamage() + 0.001F * (float)damage * attWeapon.getDamageModifier());\n/* */ }\n/* */ }\n/* */ } \n/* 1457 */ String sstring = \"sound.combat.parry1\";\n/* 1458 */ int x = Server.rand.nextInt(3);\n/* 1459 */ if (x == 0) {\n/* 1460 */ sstring = \"sound.combat.parry2\";\n/* 1461 */ } else if (x == 1) {\n/* 1462 */ sstring = \"sound.combat.parry3\";\n/* 1463 */ } SoundPlayer.playSound(sstring, defender, 1.6F);\n/* 1464 */ checkEnchantDestruction(attWeapon, weapon, defender);\n/* */ }\n/* */ \n/* */ } else {\n/* */ \n/* 1469 */ if (performer.spamMode()) {\n/* */ \n/* 1471 */ if (aiming) {\n/* 1472 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1473 */ .getNameWithGenus() + \" raises \" + defender.getHisHerItsString() + \" shield and parries.\");\n/* */ } else {\n/* 1475 */ performer.getCommunicator().sendNormalServerMessage(\"You try to \" + attString + \" \" + defender\n/* 1476 */ .getNameWithGenus() + \" but \" + defender.getHeSheItString() + \" raises \" + defender\n/* 1477 */ .getHisHerItsString() + \" shield and parries.\");\n/* */ } \n/* 1479 */ } else if (aiming) {\n/* 1480 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1481 */ .getNameWithGenus() + \" raises \" + defender.getHisHerItsString() + \" shield and parries.\");\n/* 1482 */ } if (defender.spamMode())\n/* 1483 */ defender.getCommunicator().sendNormalServerMessage(performer\n/* 1484 */ .getNameWithGenus() + \" tries to \" + attString + \" you but you raise your shield and parry.\"); \n/* 1485 */ if (defShield.isWood()) {\n/* 1486 */ Methods.sendSound(defender, \"sound.combat.shield.wood\");\n/* */ } else {\n/* 1488 */ Methods.sendSound(defender, \"sound.combat.shield.metal\");\n/* 1489 */ } checkEnchantDestruction(attWeapon, defShield, defender);\n/* */ } \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1510 */ return done;\n/* */ }", "@Override\n public void doRemove()\n {\n Player target = p.getServer().getPlayer(targetID);\n if (target == null)\n return;\n\n // teleport them back to their original location\n target.teleport(originalLocation);\n\n // remove flying and immobolize effects\n for (O2EffectType effectType : additionalEffects)\n {\n Ollivanders2API.getPlayers().playerEffects.removeEffect(targetID, effectType);\n }\n }", "public static Activity kill(String npcName) {\n\n return Activity.newBuilder()\n .withName(\"Killing \" + npcName)\n .addSubActivity(attack(npcName))\n .addSubActivity(waitUntilTargetKilled())\n .thenPauseFor(Duration.ofMillis(1500))\n .onlyOnce()\n .build();\n }", "public static void kill() {\n Iterator<Recipe> recipes = tj.getServer().recipeIterator();\r\n Recipe recipe;\r\n\r\n while (recipes.hasNext()) {\r\n recipe = recipes.next();\r\n\r\n if (recipe != null && customItems.containsValue(recipe.getResult()))\r\n recipes.remove();\r\n }\r\n\r\n tj = null;\r\n messages = null;\r\n playerDataFolder = null;\r\n players = null;\r\n customItems = null;\r\n }", "protected void attackEntity(Entity par1Entity, float par2) {\n/* 310 */ if (this.attackTime <= 0 && par2 < 3.0F && (par1Entity.func_174813_aQ()).field_72337_e > (func_174813_aQ()).field_72338_b && (par1Entity.func_174813_aQ()).field_72338_b < (func_174813_aQ()).field_72337_e) {\n/* */ \n/* 312 */ if (getIsSummoned()) {\n/* 313 */ ((EntityLivingBase)par1Entity).field_70718_bc = 100;\n/* */ }\n/* */ \n/* 316 */ this.attackTime = 15 + this.field_70146_Z.nextInt(10);\n/* */ \n/* 318 */ double mx = par1Entity.field_70159_w;\n/* 319 */ double my = par1Entity.field_70181_x;\n/* 320 */ double mz = par1Entity.field_70179_y;\n/* 321 */ if (func_70652_k(par1Entity) && \n/* 322 */ !this.field_70170_p.field_72995_K && par1Entity instanceof EntityLivingBase) {\n/* 323 */ ((EntityLivingBase)par1Entity).func_70690_d(new PotionEffect(MobEffects.field_76437_t, 100, 0));\n/* */ }\n/* */ \n/* 326 */ par1Entity.field_70160_al = false;\n/* 327 */ par1Entity.field_70159_w = mx;\n/* 328 */ par1Entity.field_70181_x = my;\n/* 329 */ par1Entity.field_70179_y = mz;\n/* */ \n/* 331 */ func_184185_a(SoundsTC.swarmattack, 0.3F, 0.9F + this.field_70170_p.field_73012_v.nextFloat() * 0.2F);\n/* */ } \n/* */ }", "@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)\r\n public void onPlayerDamagedByPlayer(final EntityDamageByEntityEvent event) {\n if (!(event.getEntity() instanceof Player)) {\r\n return;\r\n }\r\n if (!(event.getDamager() instanceof Player)) {\r\n return;\r\n }\r\n \r\n final Player target = (Player)event.getEntity();\r\n final Player attacker = (Player)event.getDamager();\r\n final ItemStack is = attacker.getItemInHand();\r\n \r\n if (is != null){\r\n switch (is.getType()){\r\n case EMERALD:\r\n attacker.setItemInHand(ItemUtil.decrementItem(is, 1));\r\n \r\n // 体力・空腹回復、燃えてたら消化\r\n target.setHealth(target.getMaxHealth());\r\n target.setFoodLevel(20);\r\n target.setFireTicks(0);\r\n \r\n // ポーション効果付与\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.REGENERATION, 45 * 20, 0)); // 45 secs\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.FIRE_RESISTANCE, 7 * 60 * 20, 0)); // 7 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.INCREASE_DAMAGE, 9 * 60 * 20, 1)); // 9 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.SPEED, 9 * 60 * 20, 0)); // 9 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.FAST_DIGGING, 5 * 60 * 20, 1)); // 5 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.NIGHT_VISION, 3 * 60 * 20, 0)); // 3 mins\r\n \r\n // effect, messaging\r\n target.getWorld().playEffect(target.getLocation(), Effect.ENDER_SIGNAL, 0, 10);\r\n Util.message(target, PlayerManager.getPlayer(attacker).getName() + \" &aから特殊効果を与えられました!\");\r\n Util.message(attacker, PlayerManager.getPlayer(target).getName() + \" &aに特殊効果を与えました!\");\r\n \r\n event.setCancelled(true);\r\n event.setDamage(0);\r\n break;\r\n default: break;\r\n }\r\n }\r\n }", "private void enemyAttack() {\n\t\t\n\t\tRandom rand = new Random();\t\n\t\t\n\t\tint roll = rand.nextInt(101);\n\t\t\n\t\tint sroll = rand.nextInt(101);\n\t\t\n\t\tevents.appendText(e.getName() + \" attacks!\\n\");\n\t\t\n\t\tif(roll <= p.getEV()) { // Player evades\n\t\t\t\n\t\t\tevents.appendText(\"You evaded \"+e.getName()+\"\\'s Attack!\\n\");\n\t\t\t\n\t\t}else if(roll > p.getEV()) { // Player is hit and dies if HP is 0 or less\n\t\t\t\n\t\t\tp.setHP(p.getHP() - e.getDMG());\n\t\t\t\n\t\t\tString newHp = p.getHP()+\"/\"+p.getMaxHP();\n\t\t\t\n\t\t\tString effect = e.getSpecial(); // Stats are afflicted\n\t\t\t\n\t\t\tif(sroll < 51){\n\t\t\t\t\n\t\t\tif(effect == \"Bleed\") { // Bleed Special\n\t\t\t\t\n\t\t\t\tp.setHP(p.getHP() - 100);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You bleed profusely. - 100 HP\\n\");\n\t\t\t\t\n\t\t\t\tnewHp = String.valueOf(p.getHP()+\"/\"+p.getMaxHP());\n\t\t\t}\n\t\t\tif(effect == \"Break\") { // Break Special \n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You feel a bone break restricting movement. - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Fear\") { // Fear Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-40>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 40);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"A crippling fear rattles your resolve. - 40 DMG\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Rend\") { // Rend Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-30>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 30);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"Morthar unleashes a pillar of flame! - 30 DMG and - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\t\n\t\t\tif(p.getHP() <= 0) {\n\t\t\t\t\n\t\t\t\tp.setDead(true);\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(0+\"/\"+e.getMaxHP());\n\t\t\t\tplayerHPBar.setProgress((double)0);\n\t\t\t}else {\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(newHp);\n\t\t\t\tplayerHPBar.setProgress((double)p.getHP()/p.getMaxHP());\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tif(p.isDead()) { // Game over if player dies\n\t\t\t\n\t\t\ttry {\n\t\t\t\tLoadGO();\n\t\t\t} catch (IOException e1) {\n\t\t\t\n\t\t\t\te1.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t\tcombat = false;\n\t\t}\n\t}", "public void move2(Pokemon enemy){\n boolean crit = false;\n boolean superEffective = false;\n boolean reduced = false;\n boolean moveHit = true;\n\n int randCrit = (int)(22 * Math.random()+1);\n\n //CHANGE ATTACK TO FALSE IF MOVE DOES NO DAMAGE<<<<<<<<<<<<<\n boolean attack = true;\n //CHANGE TYPE TO TYPE OF MOVE POWER AND ACCURACY<<<<<<<<<<<<<\n String type = \"Bug\";\n int power = 80;\n int accuracy = 100;\n\n //DO NOT CHANGE BELOW THIS\n int damage = ((CONSTANT * power * ( getAtt() / enemy.getDef() )) /50);\n if(randCrit == CONSTANT){\n damage = damage * 2;\n crit = true;\n }\n if(checkSE(type,enemy.getType())){\n damage = damage * 2;\n superEffective = true;\n }\n if(checkNVE(type, enemy.getType())){\n damage = damage / 2;\n reduced = true;\n }\n if(attack && hit(accuracy)){\n enemy.lowerHp(damage);\n }\n else{\n if(hit(accuracy)){\n //DO STATUS EFFECT STUFF HERE (ill figure out later)\n }\n }\n lowerM2PP();\n }", "public static void endAttack (boolean isStillAbleToAttack) {\r\n if (Game.ActiveAttackingMonster.isExisting) {\r\n SummonedMonster SumMonster = getNthSummonedMonster(Game.ActiveAttackingMonster.sumMonsterNumber, Game.ActiveAttackingMonster.isPlayersMonster);\r\n SumMonster.canStillAttackThisTurn=isStillAbleToAttack;\r\n if (!isStillAbleToAttack && SumMonster.Monster.equals(Mon.MonsterStealer)) {\r\n SumMonster.canStillUseOncePerTurnEffect=false; // if Monster Stealer attacked, it can not use its effect for the rest of the turn, due to its own effect\r\n }\r\n Game.ActiveAttackingMonster = new SummonedMonster(true, 0);\r\n Game.ActiveGuardingMonster = new SummonedMonster(false, 0);\r\n }\r\n if (!Game.isPlayersTurn) {\r\n AIdelegate.cpuContinuesPlayingTurn();\r\n }\r\n }", "@EventHandler\r\n\tpublic void OnKill(final EntityDeathEvent event) {\n\t\tif (!plugin.getDependencyManager().getDependency(dependency.STATS)\r\n\t\t\t\t.isAvailable())\r\n\t\t\treturn;\r\n\r\n\t\tEntity e = event.getEntity();\r\n\t\tif (e.getLastDamageCause() instanceof EntityDamageByEntityEvent) {\r\n\t\t\tEntityDamageByEntityEvent nEvent = (EntityDamageByEntityEvent) e\r\n\t\t\t\t\t.getLastDamageCause();\r\n\t\t\tif (nEvent.getDamager() instanceof Player) {\r\n\r\n\t\t\t\tString extraType = null;\r\n\r\n\t\t\t\tif (e instanceof Skeleton) {\r\n\t\t\t\t\tSkeleton ske = (Skeleton) e;\r\n\r\n\t\t\t\t\tif (ske.getSkeletonType() == SkeletonType.WITHER) {\r\n\t\t\t\t\t\textraType = \"WITHER\";\r\n\t\t\t\t\t}\r\n\t\t\t\t} else if (e instanceof Creeper) {\r\n\t\t\t\t\tCreeper cre = (Creeper) e;\r\n\r\n\t\t\t\t\tif (cre.isPowered()) {\r\n\t\t\t\t\t\textraType = \"POWERED\";\r\n\t\t\t\t\t}\r\n\t\t\t\t} else if (e instanceof Chicken) {\r\n\t\t\t\t\tChicken mob = (Chicken) e;\r\n\r\n\t\t\t\t\tif (mob.getPassenger() != null) {\r\n\t\t\t\t\t\textraType = \"JOCKEY\";\r\n\t\t\t\t\t}\r\n\t\t\t\t} else if (e instanceof Rabbit) {\r\n\t\t\t\t\tRabbit mob = (Rabbit) e;\r\n\r\n\t\t\t\t\tif (mob.getRabbitType() == Type.THE_KILLER_BUNNY) {\r\n\t\t\t\t\t\textraType = \"KILLER\";\r\n\t\t\t\t\t}\r\n\t\t\t\t} else if (e instanceof Spider) {\r\n\t\t\t\t\tSpider mob = (Spider) e;\r\n\r\n\t\t\t\t\tif (mob.getPassenger() != null) {\r\n\t\t\t\t\t\textraType = \"JOCKEY\";\r\n\t\t\t\t\t}\r\n\t\t\t\t} else if (e instanceof Guardian) {\r\n\t\t\t\t\tGuardian mob = (Guardian) e;\r\n\r\n\t\t\t\t\tif (mob.isElder()) {\r\n\t\t\t\t\t\textraType = \"ELDER\";\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (extraType == null) {\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tStatsAPIHandler handler = (StatsAPIHandler) plugin\r\n\t\t\t\t\t\t.getDependencyManager().getDependency(dependency.STATS);\r\n\r\n\t\t\t\tStat mobkilled = handler.getAPI().getStatManager()\r\n\t\t\t\t\t\t.getStat(MobKilledStat.statName);\r\n\r\n\t\t\t\tStatsHolder holder = handler.getAPI().getPlayer(\r\n\t\t\t\t\t\tnEvent.getDamager().getUniqueId());\r\n\r\n\t\t\t\tholder.addEntry(mobkilled, new DefaultStatEntry(1,\r\n\t\t\t\t\t\tnew MetadataPair(\"entityType\", e.getType().toString()),\r\n\t\t\t\t\t\tnew MetadataPair(\"extraType\", extraType),\r\n\t\t\t\t\t\tnew MetadataPair(\"world\", e.getLocation().getWorld()\r\n\t\t\t\t\t\t\t\t.getName().toString())));\r\n\r\n\t\t\t}\r\n\t\t}\r\n\t}", "@EventHandler\n\tpublic void attackMobs(EntityDamageByEntityEvent e) {\n\t\tMessages messagesConfig = plugin.getMsgs();\n\n\t\tif (e.getCause().equals(EntityDamageEvent.DamageCause.PROJECTILE)) { //Just my magic code w(o.o)w\n\t\t\treturn;\n\t\t}else if (e.getDamager() instanceof Player) {\n\t\t\tPlayer p = (Player) e.getDamager();\n\t\t\tItemStack pInv = p.getInventory().getItemInMainHand();\n\n\t\t\tif (!pInv.getType().name().contains(\"SWORD\") && !pInv.getType().name().contains(\"AXE\")) {\n\t\t\t\tif (!(e.getEntity() instanceof Chicken)) {\n\t\t\t\t\te.setCancelled(true);\n\n\t\t\t\t\tif (canSendMessage(p.getUniqueId()))\n\t\t\t\t\t\tp.sendMessage(StringUtil.inColor(messagesConfig.getCantHitWithoutSword()));\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public void death(){\n World w = getWorld();\n Level l = (Level)w;\n if(l.getPlayersLives().getValue() > 0){\n l.removeLife();\n l.respawn();\n }\n else{\n if(l.getPlayersLives().getValue() == 0){\n Label text = new Label(\"You lose\",50);\n getWorld().addObject(text,(getWorld().getWidth()/2),(getWorld().getHeight()/2));\n l.addScore();\n Scoring st = new Scoring(l.getScore());\n Greenfoot.delay(50);\n Greenfoot.setWorld(st);\n }\n }\n getWorld().removeObject(this);\n }", "public void kill(Warrior w){\n\t\tif(!w.getImmortality()){\n\t\t\tSystem.out.println(w.getName()+\" caught by Violent Monster \"+ this.getName()+\" and died..\");\n\t\t\tw.die();\n\t\t\tSystem.out.println(\"The remaining no. of Warriors are \" + Warrior.getNoofWarriors());\n\t\t\tw=null;\n\t\t}\n\t}", "public void kill() {\r\n\t\t\tfor(Guerre war : aggresiveWar) {\r\n\t\t\t\twar.finalize();\r\n\t\t\t}\r\n\t\t\tfor(Guerre war : defensiveWar) {\r\n\t\t\t\twar.finalize();\r\n\t\t\t}\r\n\t\t\tfor(Case c : caseOwned) {\r\n\t\t\t\tc.liberate();\r\n\t\t\t}\r\n\r\n\t\t\tSystem.out.println(nom + \" n'a pas su s'adapter aux nombreux dangers environnants, l'Histoire oublie les faibles.\");\r\n\t\t\t\r\n\t\t\tfor(String str : saveStats()) System.out.println(str);\r\n\t\t\t//finalisation de la mort\r\n\t\t\tthis.die();\r\n\t\t\tSystem.out.println(\"Une civilisation c'est éteinte...\");\r\n\t\t\t//finalize(); //bloque la sauvegarde et case les relations avec les autres (du à la recherche de la civ par id dans l'arraylist\r\n\t\t}", "@EventHandler\n\tpublic void onEntityKill(EntityDeathEvent e) {\n\n\t\tif (!(e.getEntity().getKiller() instanceof Player)) {\n\t\t\treturn;\n\t\t}\n\n\t\tPlayerTR trPlayer = TaskRun.getPlayer(e.getEntity().getKiller());\n\t\tLivingEntity entityKilled = e.getEntity();\n\n\t\tif (entityKilled instanceof PigZombie) {\n\t\t\ttrPlayer.completeTask(4);\n\t\t} else if (entityKilled instanceof Creeper) {\n\t\t\ttrPlayer.completeTask(10);\n\t\t} else if (entityKilled instanceof Ghast) {\n\t\t\ttrPlayer.completeTask(14);\n\t\t} else if ((entityKilled instanceof Skeleton && ((Skeleton) entityKilled).getSkeletonType() == SkeletonType.WITHER)\n\t\t\t\t|| (NMSUtils.isAtLeastOneTwelve() && entityKilled.getType() == EntityType.valueOf(\"WITHER_SKELETON\"))) {\n\t\t\ttrPlayer.completeTask(29);\n\t\t}\n\t}", "public void kill(){\n agent.kill();\n killed=true;\n LinkedList<Object> list = new LinkedList<>();\n queue.add(list);\n }", "public void act()\n {\n // if (claimer ==null){\n // this.setClaim(false);\n //}\n if(claimer == null){\n setClaim(false);\n }\n if (energy>0){\n \n removeEnergy(decayRate);\n\n }\n else {\n // getWorld().removeObject(this);\n\n }\n \n //check the energy decay\n //change size and weight\n //\n }", "public void killPlayer() {\n \tdungeon.removeentity(getX(), getY(), name);\n \t\tdungeon.deleteentity(getX(),getY(),name);\n \t\t//System.out.println(\"YOU LOSE MAMA\");\n \t\t//System.exit(0);\n \t\t\n }", "public void act() \n {\n \n move(1);\n \n Player2 player2 = new Player2();\n myWorld2 world = (myWorld2)getWorld();\n \n \n checkForDeath();\n }", "@Deprecated\n/* */ public static boolean attack(Creature performer, Item target, float counter, int pos, Action act) {\n/* 3027 */ boolean done = false;\n/* 3028 */ boolean dead = false;\n/* 3029 */ boolean aiming = false;\n/* 3030 */ Item primWeapon = performer.getPrimWeapon();\n/* */ \n/* 3032 */ if (primWeapon == null || primWeapon.isBodyPart()) {\n/* */ \n/* */ \n/* 3035 */ performer.getCommunicator().sendNormalServerMessage(\"You have no weapon to attack \" + target.getNameWithGenus() + \" with.\");\n/* 3036 */ return true;\n/* */ } \n/* 3038 */ if (primWeapon.isShield()) {\n/* */ \n/* */ \n/* 3041 */ performer.getCommunicator().sendNormalServerMessage(\"You cannot practice attacks with shields on \" + target\n/* 3042 */ .getNameWithGenus() + \".\");\n/* 3043 */ return true;\n/* */ } \n/* 3045 */ if (primWeapon.isWeaponBow() || primWeapon.isBowUnstringed()) {\n/* */ \n/* */ \n/* 3048 */ performer.getCommunicator().sendNormalServerMessage(\"You cannot practice attacks with bows on \" + target\n/* 3049 */ .getNameWithGenus() + \". You need to use an archery target instead.\");\n/* */ \n/* 3051 */ return true;\n/* */ } \n/* */ \n/* 3054 */ BlockingResult result = Blocking.getBlockerBetween(performer, target, 4);\n/* 3055 */ if (result != null) {\n/* */ \n/* 3057 */ performer.getCommunicator()\n/* 3058 */ .sendCombatNormalMessage(\"You fail to reach the \" + target\n/* 3059 */ .getNameWithGenus() + \" because of the \" + result\n/* 3060 */ .getFirstBlocker().getName() + \".\");\n/* 3061 */ return true;\n/* */ } \n/* */ \n/* 3064 */ if (Creature.rangeTo(performer, target) > Actions.actionEntrys[114].getRange()) {\n/* */ \n/* 3066 */ performer.getCommunicator().sendNormalServerMessage(\"You are now too far away to \" + Actions.actionEntrys[114]\n/* 3067 */ .getActionString().toLowerCase() + \" \" + target\n/* 3068 */ .getNameWithGenus() + \".\");\n/* 3069 */ return true;\n/* */ } \n/* 3071 */ int speed = 10;\n/* 3072 */ speed = primWeapon.getWeightGrams() / 1000 + 3;\n/* 3073 */ if (pos != -1) {\n/* */ \n/* 3075 */ aiming = true;\n/* 3076 */ speed++;\n/* */ } \n/* 3078 */ if (!done) {\n/* */ \n/* */ \n/* 3081 */ if (act.justTickedSecond())\n/* 3082 */ performer.decreaseFatigue(); \n/* 3083 */ if (counter == 1.0F)\n/* */ {\n/* 3085 */ if (aiming) {\n/* */ \n/* 3087 */ String bodypartname = PracticeDollBehaviour.getWoundLocationString(pos);\n/* 3088 */ performer.getCommunicator().sendSafeServerMessage(\"You try to \" + \n/* 3089 */ getAttackString(performer, primWeapon) + \" \" + target.getNameWithGenus() + \" in the \" + bodypartname + \".\");\n/* */ \n/* */ }\n/* */ else {\n/* */ \n/* 3094 */ performer.getCommunicator().sendSafeServerMessage(\"You try to \" + \n/* 3095 */ getAttackString(performer, primWeapon) + \" \" + target.getNameWithGenus() + \".\");\n/* */ } \n/* */ }\n/* */ \n/* 3099 */ if (act.currentSecond() % speed == 0) {\n/* */ \n/* 3101 */ Skill attackerFightSkill = null;\n/* 3102 */ Skills performerSkills = performer.getSkills();\n/* */ \n/* 3104 */ double attBonus = 0.0D;\n/* */ \n/* */ \n/* 3107 */ int attSknum = 1023;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ try {\n/* 3122 */ attackerFightSkill = performerSkills.getSkill(1023);\n/* */ }\n/* 3124 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 3126 */ attackerFightSkill = performerSkills.learn(1023, 1.0F);\n/* */ } \n/* 3128 */ dead = performAttack(pos, false, performer, performerSkills, primWeapon, target, 0.0D, attackerFightSkill, speed);\n/* */ \n/* */ \n/* 3131 */ if (aiming)\n/* 3132 */ done = true; \n/* 3133 */ if (dead)\n/* 3134 */ done = true; \n/* */ } \n/* 3136 */ if (!done && !aiming) {\n/* */ \n/* 3138 */ Item[] secondaryWeapons = performer.getSecondaryWeapons();\n/* 3139 */ for (int x = 0; x < secondaryWeapons.length; x++) {\n/* */ \n/* 3141 */ if (!secondaryWeapons[x].isBodyPart()) {\n/* */ \n/* 3143 */ speed = Server.rand.nextInt(secondaryWeapons[x].getWeightGrams() / 1000 + 7) + 2;\n/* 3144 */ if (act.currentSecond() % speed == 0) {\n/* */ \n/* 3146 */ Skill attackerFightSkill = null;\n/* 3147 */ Skills performerSkills = performer.getSkills();\n/* */ \n/* 3149 */ double attBonus = 0.0D;\n/* */ \n/* */ \n/* */ \n/* 3153 */ int attSknum = 1023;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ try {\n/* 3168 */ attackerFightSkill = performerSkills.getSkill(1023);\n/* */ }\n/* 3170 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 3172 */ attackerFightSkill = performerSkills.learn(1023, 1.0F);\n/* */ } \n/* 3174 */ done = performAttack(pos, false, performer, performerSkills, secondaryWeapons[x], target, 0.0D, attackerFightSkill, speed);\n/* */ } \n/* */ } \n/* */ } \n/* */ } \n/* */ } \n/* */ \n/* 3181 */ return done;\n/* */ }", "private void onTickInGame()\n \t{\n \n \t\ttry\n \t\t{\n \n \t\t\tif(tickCount>100)\n \t\t\t{\n \t\t\t\ttickCount=0;\n \t\t\t\tint i=0;\n \n \n \t\t\t\twhile (i<15&&FMLCommonHandler.instance().getEffectiveSide()==Side.SERVER)\n \t\t\t\t{\n \t\t\t\t\ti++;\n \t\t\t\t\tLinkData link;\n \n \t\t\t\t\t//actually gets the random rift based on the size of the list\n \t\t\t\t\tlink = (LinkData) dimHelper.instance.getRandomLinkData(true);\n \n \n \n \t\t\t\t\tif(link!=null)\n \t\t\t\t\t{\n \n \t\t\t\t\t\tif(dimHelper.getWorld(link.locDimID)!=null)\n \t\t\t\t\t\t{\n \t\t\t\t\t\t\tWorld world=dimHelper.getWorld(link.locDimID);\n \n \t\t\t\t\t\t\tint blocktoReplace = world.getBlockId(link.locXCoord, link.locYCoord, link.locZCoord);\n \n \t\t\t\t\t\t\tif(!mod_pocketDim.blocksImmuneToRift.contains(blocktoReplace))//makes sure the rift doesn't replace a door or something\n \t\t\t\t\t\t\t{\n \t\t\t\t\t\t\t\tif(dimHelper.instance.getLinkDataFromCoords(link.locXCoord, link.locYCoord, link.locZCoord, link.locDimID)==null)\n \t\t\t\t\t\t\t\t{\n \t\t\t\t\t\t\t\t}\n \t\t\t\t\t\t\t\telse\n \t\t\t\t\t\t\t\t{\n \t\t\t\t\t\t\t\t\tdimHelper.getWorld(link.locDimID).setBlock(link.locXCoord, link.locYCoord, link.locZCoord, properties.RiftBlockID);\n \t\t\t\t\t\t\t\t\tTileEntityRift.class.cast(dimHelper.getWorld(link.locDimID).getBlockTileEntity(link.locXCoord, link.locYCoord, link.locZCoord)).hasGrownRifts=true;\n \t\t\t\t\t\t\t\t}\n \t\t\t\t\t\t\t}\n \t\t\t\t\t\t}\n \t\t\t\t\t}\n \t\t\t\t}\n \t\t\t}\n \n \n \t\t}\n \t\tcatch (Exception e)\n \t\t{\n \t\t\ttickCount++;\n \t\t\tSystem.out.println(\"something on tick went wrong: \" + e);\n \t\t\te.printStackTrace();\n \t\t}\n \t\ttickCount++;\n \n \t\t//this section regulates decay in Limbo- it records any blocks placed by the player and later progresss them through the decay cycle\n \t\tif(tickCount2>10&&dimHelper.blocksToDecay!=null)\n \t\t{\n \t\t\ttickCount2=0;\n \t\t\tif(!dimHelper.blocksToDecay.isEmpty()&&dimHelper.getWorld(properties.LimboDimensionID)!=null)\n \t\t\t{\n \n \n \t\t\t\tif(dimHelper.blocksToDecay.size()>rand.nextInt(400))\n \t\t\t\t{\n \t\t\t\t\tint index = rand.nextInt(dimHelper.blocksToDecay.size());\n \t\t\t\t\tPoint3D point = (Point3D) dimHelper.blocksToDecay.get(index);\n \n \t\t\t\t\tint blockID = dimHelper.getWorld(properties.LimboDimensionID).getBlockId(point.getX(), point.getY(), point.getZ());\n \t\t\t\t\tint idToSet=Block.stone.blockID;\n \n \t\t\t\t\tif(blockID==0||blockID==properties.LimboBlockID)\n \t\t\t\t\t{\n \t\t\t\t\t\tdimHelper.blocksToDecay.remove(index);\n \t\t\t\t\t}\n \t\t\t\t\telse\n \t\t\t\t\t{\n \t\t\t\t\t\tif(Block.blocksList[idToSet] instanceof BlockContainer)\n \t\t\t\t\t\t{\n \t\t\t\t\t\t\tidToSet=-1;\n \t\t\t\t\t\t\tdimHelper.blocksToDecay.remove(index); \n \t\t\t\t\t\t}\n \n \n \n \t\t\t\t\t\tif(blockID==Block.cobblestone.blockID)\n \t\t\t\t\t\t{\n \t\t\t\t\t\t\tidToSet=Block.gravel.blockID;\n \t\t\t\t\t\t}\n \t\t\t\t\t\tif(blockID==Block.stone.blockID)\n \t\t\t\t\t\t{\n \t\t\t\t\t\t\tidToSet=Block.cobblestone.blockID;\n \n \t\t\t\t\t\t}\n \t\t\t\t\t\tif(blockID==Block.gravel.blockID&&!dimHelper.getWorld(properties.LimboDimensionID).isAirBlock(point.getX(), point.getY()-1, point.getZ()))\n \t\t\t\t\t\t{\n \t\t\t\t\t\t\tidToSet=properties.LimboBlockID;\n \t\t\t\t\t\t\tdimHelper.getWorld(properties.LimboDimensionID).scheduleBlockUpdate(point.getX(), point.getY(), point.getZ(),10, idToSet);\n \n \t\t\t\t\t\t}\n \t\t\t\t\t\telse if(blockID==Block.gravel.blockID)\n \t\t\t\t\t\t{\n \t\t\t\t\t\t\tdimHelper.blocksToDecay.remove(index);\n \t\t\t\t\t\t\tidToSet=-1;\n \n \t\t\t\t\t\t}\n \n \t\t\t\t\t\tif(idToSet!=-1)\n \t\t\t\t\t\t{\n \n \t\t\t\t\t\t\tdimHelper.getWorld(properties.LimboDimensionID).setBlock(point.getX(), point.getY(), point.getZ(), idToSet);\n \n \t\t\t\t\t\t} \t\t\n \t\t\t\t\t} \t\t \t\t\n \t\t\t\t} \t\t\n \t\t\t}\n \t\t}\n \n \t\ttickCount2++;\n \n \t\tif(mod_pocketDim.teleTimer>0)\n \t\t{\n \t\t\tmod_pocketDim.teleTimer--;\n \t\t}\n \n \n \n \n \n \n \t}", "public void kill() {\n this.hp = 0;\n }", "public void familiarTick() {\n\t\tattacked = false;\n\t\tif (summonedFamiliar != null && c.getInstance().summoned != null) {\n\t\t\tif (!c.goodDistance(c.getX(), c.getY(), c.getInstance().summoned.getX(), c.getInstance().summoned.getY(),\n\t\t\t\t\t8)) {\n\t\t\t\tcallOnTeleport();\n\t\t\t}\n\t\t\tif (!c.goodDistance(c.getX(), c.getY(), c.getInstance().summoned.getX(), c.getInstance().summoned.getY(),\n\t\t\t\t\t8)) {\n\t\t\t\tc.getSummoning().callFamiliar();\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tif (c.getInstance().playerIndex != 0\n\t\t\t\t\t&& NPCHandler.npcs[c.getInstance().summoningMonsterId].spawnedBy == c.getId()) {\n\t\t\t\tNPCHandler.npcs[c.getInstance().summoningMonsterId].isAttackingAPerson = true;\n\t\t\t} else if (c.getInstance().playerIndex == 0\n\t\t\t\t\t&& NPCHandler.npcs[c.getInstance().summoningMonsterId].spawnedBy == c.getId()) {\n\t\t\t\tNPCHandler.npcs[c.getInstance().summoningMonsterId].isAttackingAPerson = false;\n\t\t\t}\n\t\t\tif (c.getInstance().underAttackBy != 0\n\t\t\t\t\t&& NPCHandler.npcs[c.getInstance().summoningMonsterId].spawnedBy == c.getId()) {\n\t\t\t\tNPCHandler.npcs[c.getInstance().summoningMonsterId].isAttackedByPerson = true;\n\t\t\t} else if (c.getInstance().underAttackBy == 0\n\t\t\t\t\t&& NPCHandler.npcs[c.getInstance().summoningMonsterId].spawnedBy == c.getId()) {\n\t\t\t\tNPCHandler.npcs[c.getInstance().summoningMonsterId].isAttackedByPerson = false;\n\t\t\t}\n\t\t\tif (c.getInstance().npcIndex != 0\n\t\t\t\t\t&& !NPCHandler.npcs[c.getInstance().summoningMonsterId].isAttackingAPerson\n\t\t\t\t\t&& NPCHandler.npcs[c.getInstance().summoningMonsterId].spawnedBy == c.getId()) {\n\t\t\t\tNPCHandler.npcs[c.getInstance().summoningMonsterId].IsAttackingNPC = true;\n\t\t\t\tNPCHandler.npcs[c.getInstance().summoningMonsterId].facePlayer(0);\n\t\t\t} else if (NPCHandler.npcs[c.getInstance().summoningMonsterId].spawnedBy == c.getId()) {\n\t\t\t\tif (NPCHandler.npcs[c.getInstance().summoningMonsterId].IsAttackingNPC == true)\n\t\t\t\t\tcallFamiliar();\n\t\t\t\tNPCHandler.npcs[c.getInstance().summoningMonsterId].IsAttackingNPC = false;\n\t\t\t}\n\t\t\tif (c.getInstance().summoned.killerId != 0 && c.getInstance().summoned.underAttackBy == 0) {\n\t\t\t\tc.getInstance().summoned.killerId = 0;\n\t\t\t\tc.getInstance().summoned.underAttackBy = 0;\n\t\t\t\tc.getSummoning().callFamiliar();\n\t\t\t}\n\t\t\tif (attacked != true) {\n\t\t\t\tif (NPCHandler.npcs[c.getInstance().summoningMonsterId].isAttackedByPerson == true) {\n\t\t\t\t\tattacked = true;\n\t\t\t\t\tPlayer o = PlayerHandler.players[c.getInstance().underAttackBy];\n\t\t\t\t\tif (o != null) {\n\t\t\t\t\t\tif (o.getInstance().inMulti()) {\n\t\t\t\t\t\t\tif (actionTimer == 0) {\n\t\t\t\t\t\t\t\tServer.npcHandler.followPlayer(c.getInstance().summoningMonsterId, o.playerId,\n\t\t\t\t\t\t\t\t\t\tc.playerId);\n\t\t\t\t\t\t\t\tNPCHandler.npcs[c.getInstance().summoningMonsterId].facePlayer(o.playerId);\n\t\t\t\t\t\t\t\tServer.npcHandler.attackPlayer(o, c.getInstance().summoningMonsterId);\n\t\t\t\t\t\t\t\tc.getInstance().summoned.updateRequired = true;\n\t\t\t\t\t\t\t\tNPCHandler.npcs[c.getInstance().summoningMonsterId].index = o.playerId;\n\t\t\t\t\t\t\t\tactionTimer = 7;\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tactionTimer--;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (attacked != true) {\n\t\t\t\tif (NPCHandler.npcs[c.getInstance().summoningMonsterId].isAttackingAPerson == true) {\n\t\t\t\t\tattacked = true;\n\t\t\t\t\tPlayer o = PlayerHandler.players[c.getInstance().playerIndex];\n\t\t\t\t\tif (o != null) {\n\t\t\t\t\t\tif (o.getInstance().inMulti()) {\n\t\t\t\t\t\t\tif (actionTimer == 0) {\n\t\t\t\t\t\t\t\tServer.npcHandler.followPlayer(c.getInstance().summoningMonsterId, o.playerId,\n\t\t\t\t\t\t\t\t\t\tc.playerId);\n\t\t\t\t\t\t\t\tNPCHandler.npcs[c.getInstance().summoningMonsterId].facePlayer(o.playerId);\n\t\t\t\t\t\t\t\tServer.npcHandler.attackPlayer(o, c.getInstance().summoningMonsterId);\n\t\t\t\t\t\t\t\tc.getInstance().summoned.updateRequired = true;\n\t\t\t\t\t\t\t\tNPCHandler.npcs[c.getInstance().summoningMonsterId].index = o.playerId;\n\t\t\t\t\t\t\t\tactionTimer = 7;\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tactionTimer--;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (attacked != true) {\n\t\t\t\tif (NPCHandler.npcs[c.getInstance().summoningMonsterId].IsAttackingNPC == true) {\n\t\t\t\t\tattacked = true;\n\t\t\t\t\tNPC n = NPCHandler.npcs[c.getInstance().npcIndex];\n\t\t\t\t\tif (n != null) {\n\t\t\t\t\t\t// if(n.inMulti()) {\n\t\t\t\t\t\tNPCHandler.npcs[c.getInstance().summoningMonsterId].IsAttackingNPC = true;\n\t\t\t\t\t\tNPCHandler.npcs[c.getInstance().npcIndex].IsUnderAttackNpc = true;\n\t\t\t\t\t\tNPCHandler.npcs[c.getInstance().npcIndex].randomWalk = false;\n\t\t\t\t\t\t// GameEngine.npcHandler.attackNPC(c.npcIndex,\n\t\t\t\t\t\t// c.getVariables().summoningMonsterId, c);\n\t\t\t\t\t\tServer.npcHandler.NpcVersusNpc(c.getInstance().summoningMonsterId,\n\t\t\t\t\t\t\t\tc.getInstance().npcIndex, c);\n\t\t\t\t\t\t// }\n\t\t\t\t\t} else {\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tspeakTimer++;\n\t\t\tif (speakTimer == 100) {\n\t\t\t\tc.getInstance().summoned.forceChat(summonedFamiliar.speakText);\n\t\t\t\tspeakTimer = 0;\n\t\t\t}\n\t\t\tc.getInstance().specRestoreTimer -= 1;\n\t\t\tint hours = (c.getInstance().specRestoreTimer / 2) / 3600;\n\t\t\tint minutes = ((c.getInstance().specRestoreTimer / 2) - hours * 3600) / 60;\n\t\t\tint seconds = ((c.getInstance().specRestoreTimer / 2) - (hours * 3600 + minutes * 60));\n\n\t\t\tString timer = String.format(\"%02d:%02d\", minutes, seconds);\n\t\t\tc.getPA().sendString(timer, 17021);\n\t\t\tif (c.getInstance().specRestoreTimer == 100) {\n\t\t\t\tc.sendMessage(\"@red@Your familiar will run out in approximately 1 minute.\");\n\t\t\t\tc.sendMessage(\"@red@Warning! Item's stored in familiar will be dropped upon death!\");\n\t\t\t} else if (c.getInstance().specRestoreTimer == 50) {\n\t\t\t\tc.sendMessage(\"@red@Your familiar will run out in approximately 30 seconds.\");\n\t\t\t\tc.sendMessage(\"@red@Warning! Item's stored in familiar will be dropped upon death!\");\n\t\t\t} else if (c.getInstance().specRestoreTimer == 25) {\n\t\t\t\tc.sendMessage(\"@red@Your familiar will run out in approximately 15 seconds.\");\n\t\t\t\tc.sendMessage(\"@blu@ You can renew your familiar with a new pouch by clicking @red@ Renew pouch\");\n\t\t\t\tc.sendMessage(\"@red@Warning! Item's stored in familiar will be dropped upon death!\");\n\t\t\t} else if (c.getInstance().specRestoreTimer <= 0) {\n\t\t\t\tdismissFamiliar(false);\n\t\t\t}\n\t\t\tif (familiarSpecialEnergy != 60) {\n\t\t\t\tspecialRestoreCycle++;\n\t\t\t\tif (specialRestoreCycle == 50) {\n\t\t\t\t\tif (familiarSpecialEnergy != 60) {\n\t\t\t\t\t\tfamiliarSpecialEnergy += 15;\n\t\t\t\t\t\tif (familiarSpecialEnergy >= 60) {\n\t\t\t\t\t\t\tfamiliarSpecialEnergy = 60;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tspecialRestoreCycle = 0;\n\t\t\t\t}\n\t\t\t}\n\t\t\tspecialTimer--;\n\t\t}\n\t\tif (renewTimer > 0) {\n\t\t\trenewTimer--;\n\t\t\tif (renewTimer == 0 && c.getInstance().summoned == null && summonedFamiliar != null) {\n\t\t\t\tc.getInstance().summoned = Server.npcHandler.summonNPC(c, summonedFamiliar.npcId, c.getX(),\n\t\t\t\t\t\tc.getY() + (summonedFamiliar.large ? 2 : 1), c.heightLevel, 0,\n\t\t\t\t\t\tSummoningData.getSummonHealth(summonedFamiliar.npcId), 1, 1, 1);\n\t\t\t\tcallFamiliar();\n\t\t\t}\n\t\t}\n\t\tif (loginCycle > 0) {\n\t\t\tloginCycle--;\n\t\t\tif (loginCycle == 0 && c.getInstance().summoned == null && summonedFamiliar != null) {\n\t\t\t\tc.getInstance().summoned = Server.npcHandler.summonNPC(c, summonedFamiliar.npcId, c.getX(),\n\t\t\t\t\t\tc.getY() + (summonedFamiliar.large ? 2 : 1), c.heightLevel, 0,\n\t\t\t\t\t\tSummoningData.getSummonHealth(summonedFamiliar.npcId), 1, 1, 1);\n\t\t\t\tcallFamiliar();\n\t\t\t}\n\t\t}\n\t}", "protected abstract void doKill();", "public void tick() {\n if (ShulkerEntity.this.world.getDifficulty() != Difficulty.PEACEFUL) {\n --this.attackTime;\n LivingEntity livingentity = ShulkerEntity.this.getAttackTarget();\n ShulkerEntity.this.getLookController().setLookPositionWithEntity(livingentity, 180.0F, 180.0F);\n double d0 = ShulkerEntity.this.getDistanceSq(livingentity);\n if (d0 < 400.0D) {\n if (this.attackTime <= 0) {\n this.attackTime = 20 + ShulkerEntity.this.rand.nextInt(10) * 20 / 2;\n ShulkerEntity.this.world.addEntity(new ShulkerBulletEntity(ShulkerEntity.this.world, ShulkerEntity.this, livingentity, ShulkerEntity.this.getAttachmentFacing().getAxis()));\n ShulkerEntity.this.playSound(SoundEvents.ENTITY_SHULKER_SHOOT, 2.0F, (ShulkerEntity.this.rand.nextFloat() - ShulkerEntity.this.rand.nextFloat()) * 0.2F + 1.0F);\n }\n } else {\n ShulkerEntity.this.setAttackTarget((LivingEntity)null);\n }\n\n super.tick();\n }\n }", "public void moveTowards(){\n \n \n \n if(!exploded){\n \n \n move(speed);\n \n if(isTouching(Enemy.class)){\n move(explosionRadius); \n \n inRange = (ArrayList) getObjectsInRange(explosionRadius + 25, Enemy.class);\n for(Enemy e : inRange){\n e.hit(damage);\n }\n \n //explode\n exploded = true;\n \n image = new GreenfootImage(\"50x50 aoe.png\");\n image.scale(explosionRadius*2, explosionRadius*2);\n setImage(image);\n //getWorld().removeObject(this);\n }\n else if (isAtEdge())\n {\n getWorld().removeObject(this);\n }\n else if ( radius < distance) {\n getWorld().removeObject(this); \n }\n }\n else{\n setImage(image);\n image.setTransparency(image.getTransparency() - 5);\n if(image.getTransparency() <= 0) getWorld().removeObject(this);\n }\n }", "@Override\r\n\tpublic void tick(){\n\t\tif(!alert){\r\n\t\t\tif(hostileToPlayer&&closeEnoughToAlert(World.player))\r\n\t\t\t\t{alert=true;target=World.player;}\r\n\t\t}\r\n\t\t\r\n\t\tif(alert&&null!=target){\r\n\t\t\t//For now, advance towards the player\r\n\t\t\tPathfinder.moveTowards(this, target);\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t//If within attacking range but not yet attacking, and not stunned, do so.\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t}", "public void onKill(EntityDeathEvent evt) {\r\n }", "@EventHandler\r\n\tpublic void run(PlayerInteractEvent e) {\n\t\tPlayer p = e.getPlayer();\r\n\t\t\tif (e.getAction()==Action.LEFT_CLICK_AIR && p.getInventory().getItemInMainHand().getType()==Material.WOOD_SWORD) {\r\n\t\t\t\tnew BukkitRunnable() {\r\n\t\t\t\tLocation loc = p.getLocation();\r\n\t\t\t\tLocation loc2 = p.getLocation();\r\n\t\t\t\tdouble t = 0.0;\r\n\t\t\t\t\r\n\t\t\t\tpublic void run() {\r\n\t\t\t\t\tint size = 5;\r\n\t\t\t\t\tfor(int i = 0; i < 360;i++) {\r\n\t\t\t\t\t\tdouble angle = (i*Math.PI/180);\r\n\t\t\t\t\t\tt+=0.25;\r\n\t\t\t\t\t\tif (t==1) {\r\n\t\t\t\t\t\t\tp.playSound(loc, Sound.ENTITY_PLAYER_ATTACK_SWEEP, 1, 0);\r\n\t\t\t\t\t\t} \r\n\t\t\t\t\t\tdouble x =(size*Math.cos(angle));\r\n\t\t\t\t\t\tdouble y = 0.1;\r\n\t\t\t\t\t\tdouble z =(size*Math.sin(angle));\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tint n = ran.nextInt(100);\r\n\t\t\t\t\t\tloc.add(x,y,z);\r\n\t\t\t\t\t\tif (t%1000==0)\r\n\t\t\t\t\t\t\tp.playSound(loc, Sound.ENTITY_IRONGOLEM_HURT, 1, 0);\r\n\t\t\t\t\t\tif(n>95) {\r\n\t\t\t\t\t\t\tParticleEffect.REDSTONE.sendColor(Bukkit.getOnlinePlayers(), loc, Color.YELLOW);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\tfor (Entity en : loc.getChunk().getEntities()){\r\n\t\t\t\t\t\t\t\tif (en.getLocation().distance(loc2) < size){\r\n\t\t\t \tif(en != p) {\r\n\t\t\t\t if(en.getType().isAlive()) { \r\n\t\t\t\t\t Damageable d = (Damageable) en;\r\n\t\t\t\t\t d.damage(5.0, p);\r\n\t\t\t\t \r\n\t\t\t\t }\r\n\t\t\t \t}\r\n\t\t\t }\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tloc.subtract(x,y,z);\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\tif(t>5000.0) {\r\n\t\t\t\t\t\tthis.cancel();\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}.runTaskTimer(plugin, 0, 1);\r\n\t\t}\t\t\r\n\t}", "public static void combatPlayer(Player atk, EnemyObject def){\n\t\tif(atk.stat.getType() != def.stat.getType() ){\n\n\t\t\t\tint atkDamage = 0;\n\t\t\t\tatkDamage = atk.stat.toDamage();\n\t\t\t\tdef.stat.getDamage(atkDamage);\n\t\t\t\t//System.out.println(\"Attack!\");\n\t\t\t\t//System.out.println(\"Enemy get \"+ atkDamage + \" Damage\");\n\t\t\t\tif(def.stat.checkAlive()==false){\n\t\t\t\t\t//check the object die or not.\t\t\n\t\t\t\t\t\n\t\t\t\t\tif(def.stat.getType()==1){\n\t\t\t\t\t//System.out.println(\"Enemy Die\");\n\t\t\t\t\t\t//def.remove(0);\n\t\t\t\t\t\t//enemy die.\n\t\t\t\t\t\t//give exp to the user.\n\t\t\t\t\t\tint exp = def.stat.giveExp();\n\t\t\t\t\t\t\n\t\t\t\t\t\tatk.stat.getExp(exp);\n\t\t\t\t\t\t//System.out.println(\"Player get \"+exp+ \" exp\");\n\t\t\t\t\t\t//destroy the enemy object.-> ??\n\t\t\t\t\t}\n\t\t\t\t}\t\t\t\n\t\t\t\t//System.out.println(\"\\n\\nEvent number : \" + atk.stat.getEventNum()+\" \\n\");\n /*\n\t\t\t\tSystem.out.println(\"Enemy Health: \" + def.stat.getHP());\n\t\t\t\tSystem.out.println(\"\\n\\n Player Stat: \");\n\t\t\t\tSystem.out.println(\"\\nPlayer HP: \"+atk.stat.getHP());\n\t\t\t\tSystem.out.println(\"Level: \"+atk.stat.getLv());\n\t\t\t\tSystem.out.println(\"STR: \"+atk.stat.getStr());\n\t\t\t\tSystem.out.println(\"DEX: \"+atk.stat.getDex());\n\t\t\t\tSystem.out.println(\"Wis: \"+atk.stat.getWis());\n\t\t\t\tSystem.out.println(\"Con: \"+atk.stat.getCon()+\"\\n\");\t*/\t\t\t\n\t\t}\n\t}", "void deathHandler(Enemy e) {\n\n if (e != null) {\n Explosion rip = new Explosion();\n rip.kaboom.moveToPoint(e.eTank.getX(), e.eTank.getY());\n // println(\"made enemy\");\n rip.kaboom.frontAngle(90);\n rip.kaboom.turn(90);\n explosion.add(rip);\n }\n for (Explosion exp: explosion) {\n if (exp.kaboomCounter > 1) {\n exp.kaboom.display();\n }\n // if (exp.kaboomCounter < 1) {\n // explosion.remove(exp);\n // }\n // else {\n exp.kaboomCounter -= 3;\n // println(exp.kaboomCounter);\n // println(explosion.size());\n // }\n }\n\n}", "public boolean killAgent(String agName, String byAg, int deadline);", "void logKill(UUID shooter, EntityType entityType);", "@Override\n protected void afterKill() {\n if (timeAfterDeath > 0) {\n --timeAfterDeath;\n } else {\n if (finalAnimation > 0) {\n --finalAnimation;\n } else {\n remove();\n }\n }\n }", "void killPlayerByPlayerMove()\n {\n movePlayerToCell(getMonsterCell());\n }", "public static void teleportAway(ClientContext ctx) {\n Item sceptre = ctx.inventory.select().id(Items.SKULL_SCEPTRE_I_21276).poll();\n\n if (sceptre.valid()) {\n sceptre.interact(\"Invoke\", sceptre.name());\n sleep(3000);\n } else {\n // Teletab\n Item tab = ctx.inventory.select().select(new Filter<Item>() {\n @Override\n public boolean accept(Item item) {\n return item.name().toLowerCase().contains(\"teleport\");\n }\n }).poll();\n\n if (tab.valid()) {\n tab.click();\n } else {\n // Glory Teleport\n ctx.game.tab(Game.Tab.EQUIPMENT);\n Item ammy = ctx.equipment.itemAt(Equipment.Slot.NECK);\n if (ammy.name().toLowerCase().contains(\"glory\")) {\n ammy.interact(\"Edgeville\");\n sleep(4000);\n }\n }\n }\n }", "public void act() \r\n {\n if(getOneIntersectingObject(Player.class)!=null)\r\n {\r\n if(MenuWorld.gamemode == 1)\r\n //marcheaza regenerarea labirintului(trecere la nivelul urmator in Modul Contra Timp)\r\n TAworld.shouldRegen=true;\r\n else\r\n { \r\n //reseteaza variabilele care tin de modul de joc\r\n MenuWorld.gamemode=-1;\r\n MenuWorld.isPlaying=false;\r\n for(int i=0;i<4;i++)\r\n ItemCounter.gems_taken[i]=0;\r\n \r\n //arata fereastra de castig \r\n PMworld.shouldShowVictoryWindow=true;\r\n }\r\n \r\n }\r\n \r\n }", "private void attack() {\n final Random rnd = new Random();\n // Создаем WorkerThread\n attackerExecutor = Executors.newScheduledThreadPool(1);\n mAttackExecuter = attackerExecutor.scheduleWithFixedDelay(new Runnable() {\n @Override\n public void run() {\n for (int i =0; i<enemyPerWave;i++){\n int x = (int) (rnd.nextInt((int) (rightBorder-leftBorder))+leftBorder);\n\n createBossBall(x,0);\n }\n attackRatee-=attackLiveRate;\n if (attackRatee < 100){\n mAttackExecuter.cancel(true);\n attackerExecutor.shutdownNow();\n\n }\n }\n }, 0,attackLiveRate , TimeUnit.MILLISECONDS);\n\n }", "@Override\n protected void doCheckEffect ()\n {\n // check all the stationary spells in the location of the projectile for a Colloportus\n List<O2StationarySpell> inside = new ArrayList<>();\n for (O2StationarySpell spell : Ollivanders2API.getStationarySpells(p).getStationarySpellsAtLocation(location))\n {\n if (spell instanceof COLLOPORTUS)\n {\n inside.add(spell);\n }\n }\n\n // remove the colloportus spells found\n if (inside.size() > 0)\n {\n for (O2StationarySpell spell : inside)\n {\n spell.kill();\n spell.flair(10);\n }\n\n kill();\n }\n\n // if the spell has hit a solid block, the projectile is stopped and wont go further so kill the spell\n if (hasHitTarget())\n kill();\n }", "void killPlayerByMonsterMove()\n {\n moveMonsterToCell(getPlayerCell());\n }", "public void breath() {\n\t\tif (alive) {\n\t\t\t_age++;\n\t\t\t// Respiration process\n\t\t\tboolean canBreath = useEnergy(Math.min((_mass - _lowmaintenance) / Utils.SEGMENT_COST_DIVISOR, _energy));\n\t\t\tif ((_age >> 8) > _geneticCode.getMaxAge() || !canBreath) {\n\t\t\t\t// It's dead, but still may have energy\n\t\t\t\tdie(null);\n\t\t\t} else {\n\t\t\t\tif (_energy <= Utils.tol) {\n\t\t\t\t\talive = false;\n\t\t\t\t\t_world.decreasePopulation();\n\t\t\t\t\t_world.organismHasDied(this, null);\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\t// The corpse slowly decays\n\t\t\tuseEnergy(Math.min(_energy, Utils.DECAY_ENERGY));\n\t\t}\n\t}", "void kill()\n\t{\n\t\tfor(GameObject G : ObjectList)\n\t\t{\n\t\t\tG.kill();\n\t\t}\n\t}", "private void checkExplosionKill() {\n\t\t\n\t\texplosion.expand();\n\t\t\n\t\tfor (ArrayList<Invader> row : enemyArray) {\n\t\t\tfor (Invader a : row) {\n\t\t\t\tif (explosion.detectDownwardCollision(a.getX(), a.getY())) {\n\t\t\t\t\ta.setVisibility(false);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "@Override\n\t\t\t\t\t\t\t\t\t\t\tpublic void execute(Object... arguments) {\n\t\t\t\t\t\t\t\t\t\t\t\tif (((Player) arguments[0])\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t.getSummoning().familiarSpecialEnergy >= 15) {\n\t\t\t\t\t\t\t\t\t\t\t\t\tServer.npcHandler.startAnimation(8288,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t((Player) arguments[0]).getInstance().summoningMonsterId);\n\t\t\t\t\t\t\t\t\t\t\t\t\t((Player) arguments[0]).getInstance().summoned.gfx0(1414);// unknown\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// wartoise\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// gfx\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// ulti\n\t\t\t\t\t\t\t\t\t\t\t\t\t((Player) arguments[0]).startAnimation(7660);\n\t\t\t\t\t\t\t\t\t\t\t\t\t((Player) arguments[0]).gfx(1313, 0);\n\t\t\t\t\t\t\t\t\t\t\t\t\t((Player) arguments[0])\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.sendMessage(\"Your defence has been boosted!\");\n\t\t\t\t\t\t\t\t\t\t\t\t\t((Player) arguments[0]).getPotions().doTortoiseSpecial(1);\n\t\t\t\t\t\t\t\t\t\t\t\t\t((Player) arguments[0]).getSummoning().specialTimer = 5;\n\t\t\t\t\t\t\t\t\t\t\t\t\t((Player) arguments[0]).getSummoning().familiarSpecialEnergy -= 15;\n\t\t\t\t\t\t\t\t\t\t\t\t\t((Player) arguments[0]).getItems()\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.deleteItem2(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t((Player) arguments[0])\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.getSummoning().summonedFamiliar.scrollId,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t1);\n\t\t\t\t\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t\t\t\t\t((Player) arguments[0]).sendMessage(\"Your familiar has \"\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t+ ((Player) arguments[0])\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t.getSummoning().familiarSpecialEnergy\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t+ \" special energy left and needs 15..\");\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t}", "public void onImpact() {\r\n die();\r\n }", "private void updatePlayerClaim(){\n if(chestProgressLevel!=1){\n return; //the chest isnt unlocked!\n }\n\n //count the total players, and the players who unlocked it.\n int totalPlayers = 0;\n int unlockedPlayers = 0;\n for(JuggernautPlayer player: JuggernautGame.getInstance().getPlayers()){\n if(!player.isSurvivor() || !player.isAlive()){\n continue; //they be dead, they dont count! (Juggy also doesnt count, he doesnt get to unlock items)\n }\n totalPlayers++; //+1 total players\n if(player.isSurvivor() && player.getChestBonus(chestID)>=level){\n unlockedPlayers++; //they unlocked it, +1 unlocked players\n }\n }\n\n //all players unlocked it\n if(totalPlayers<=unlockedPlayers && chestProgressLevel==1){\n //lock the chest before respawning.\n lockChest();\n new BukkitRunnable() {\n\n int timeTillRespawn = 3; //3 seconds to respawn a chest\n @Override\n public void run() {\n //runs every second\n for(JuggernautPlayer jp : JuggernautGame.getInstance().getAllPeople()){\n //check if the player is in the radius of the chest (ignore Y)\n if(SkyMathHelper.isInRadius(location, jp.getPlayer().getLocation(), nametagRadius, false)) {\n //show them the hologram. Update if they already have the hologram active.\n //If this chest will not respawn, we tell them \"Good Luck!\" instead of the respawning message.\n if (jp.getLoadedEntities().containsKey(armorstandResetChestID)) {\n if(level==getMaxLevel()){\n jp.updateHologram(armorstandResetChestID, \"\\u00A76Good Luck!\");\n }else {\n jp.updateHologram(armorstandResetChestID, \"\\u00A76Respawning in \" + timeTillRespawn);\n }\n } else {\n if(level==getMaxLevel()) {\n jp.displayHologram(location.getX(), location.getY() + armorstandProgressbarHeight, location.getZ(), \"\\u00A76Good Luck!\", armorstandResetChestID);\n }else{\n jp.displayHologram(location.getX(), location.getY() + armorstandProgressbarHeight, location.getZ(), \"\\u00A76Respawning in \" + timeTillRespawn, armorstandResetChestID);\n }\n }\n }else{\n //they arent in range, so we remove this entity for them\n jp.removeEntities(armorstandResetChestID);\n }\n }\n\n //check if its time to respawn.\n if(timeTillRespawn--<=0){\n //its time! respawn the chest!\n respawnChest();\n for(JuggernautPlayer jp: JuggernautGame.getInstance().getPlayers()){\n //remove the countdown armorstand for all players\n jp.removeEntities(armorstandResetChestID);\n }\n this.cancel(); //cancel this runnable, we no longer need it.\n return;\n }\n }\n }.runTaskTimer(Juggernaut.pluginInstance, 0L, 20L); //every 20 ticks (1s)\n }else{\n //not all players unlocked the item yet. Lets indicate how many did.\n String emptyDisplayText = unlockedPlayers + \"/\" + totalPlayers + \" Claimed\";\n for(JuggernautPlayer JP: JuggernautGame.getInstance().getPlayers()){\n if(!SkyMathHelper.isInRadius(location, JP.getPlayer().getLocation(), nametagRadius, false)){\n //they arent in the radius, so we remove their armorstand again (if they had it).\n if(JP.getLoadedEntities().containsKey(this.armorstandClaimProgressID)) {\n JP.removeEntities(armorstandClaimProgressID);\n }\n continue;\n }\n\n //generate the color of the display text we need to show them. green if they claimed it, otherwise red.\n String displayText;\n if(JP.getChestBonus(chestID)>=level){\n displayText = \"\\u00A72\" + emptyDisplayText;\n }else{\n displayText = \"\\u00A7c\" + emptyDisplayText;\n }\n\n //update, or show the hologram to them.\n if(JP.getLoadedEntities().containsKey(this.armorstandClaimProgressID)){\n JP.updateHologram(armorstandClaimProgressID, displayText);\n }else{\n JP.displayHologram(this.location.getX(), this.location.getY()+this.armorstandClaimProgressHeight, this.location.getZ(), displayText, armorstandClaimProgressID);\n }\n }\n }\n }", "public void attack() { \n db.attack(creatures.get(creatureId), players.get(playerId));\n creatures.set(creatureId, db.getCreature(creatures.get(creatureId).getId()));\n players.set(playerId, db.getPlayer(players.get(playerId).getId()));\n setTextFields();\n }", "public void drop() {\n\t\t// Has player waited cooldown before trying to fire again?\n\t\tif (System.currentTimeMillis() - this.lastFired > Config.WEAPON_COOLDOWN_TIME * 1000) {\n\t\t\t\n\t\t\t// Can this airship drop bombs?\n\t\t\tif (this.properties.DROPS_BOMB) {\n\t\t\t\tBlock[] cannons = getCannons();\n\t\t\t\tint numfiredcannons = 0;\n\t\t\t\tfor (int i = 0; i < cannons.length; i++) {\n\t\t\t\t\tif (cannons[i] != null && cannons[i].getRelative(0, -1, 0).getType().equals(Material.AIR) && cannonHasTnt(cannons[i], Config.NUM_TNT_TO_DROP_BOMB)) {\n\t\t\t\t\t\tif (numfiredcannons < this.properties.MAX_NUMBER_OF_CANNONS ) {\n\t\t\t\t\t\t\tnumfiredcannons++;\n\t\t\t\t\t\t\tlastFired = System.currentTimeMillis();\n\t\t\t\t\t\t\twithdrawTnt(cannons[i], Config.NUM_TNT_TO_DROP_BOMB);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Spawn primed tnt firing downwards TODO: maybe add sound effects for tnt firing? :P\n\t\t\t\t\t\t\tTNTPrimed tnt = cannons[i].getWorld().spawn(cannons[i].getLocation().clone().add(0, -1, 0), TNTPrimed.class);\n\t\t\t\t\t\t\ttnt.setVelocity(new Vector(0, -0.5, 0));\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// More cannons on ship than allowed. Not all fired - can break out of loop now.\n\t\t\t\t\t\t\tplayer.sendMessage(ChatColor.AQUA + \"Some cannons did not fire. Max cannon limit is \" + ChatColor.GOLD + this.properties.MAX_NUMBER_OF_CANNONS);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else\n\t\t\t\tplayer.sendMessage(ChatColor.GOLD + this.properties.SHIP_TYPE + \" CANNOT DROP BOMBS\");\n\t\t} else\n\t\t\tplayer.sendMessage(ChatColor.GOLD + \"COOLING DOWN FOR \" + ChatColor.AQUA + (int)(Math.round(6 - (System.currentTimeMillis() - this.lastFired) / 1000)) + ChatColor.GOLD + \" MORE SECONDS\");\n\t}", "public void OnDamage(AI ai, int aTK, float f) {\n\tif(DamagedTimer < 0.8f)\n\t\treturn;\n\tvel.x = f;\n\tvel.y = 3;\n\tDamagedTimer = 0;\n\tgrounded = false;\n\taTK -= (getDEF()*0.8f);\n\tif(aTK <= 0)\n\t\taTK = 1;\n\tHP -= aTK;\n\tInventory.CurrentInventory.dmgTxts.add(new dmgText(pos.x, pos.y+1, aTK));\n\t\n\tSoundManager.PlaySound(\"playerHurt\",3);\n\t\n\t\n}", "private void handleStandardGameplay(float deltaTime) {\n\t\t// Decrease time to next revived enemy\n\t\tmSpawnTime--;\n\n\t\t// Accumulate time elapsed while playing\n\t\tmRoundTimeElapsed += deltaTime;\n\n\t\t/**\n\t\t * Input Handling\n\t\t * When the screen is touched, kill touched attackers\n\t\t */\n\t\tif(Gdx.input.justTouched()) {\n\t\t\t// Grab the touch position, saved as a Vector3\n\t\t\tmLastTouch.set(Gdx.input.getX(), Gdx.input.getY(), 0);\n\t\t\tmCamera.unproject(mLastTouch); // Translates to game world coordinates\n\n\t\t\t// Find the first attacker located at the touch position, if any\n\t\t\tint indexOfAttacker = getFirstAttackerAt(mLastTouch.x, mLastTouch.y);\n\t\t\t// If the index is greater than negative one, kill the attacker and add points\n\t\t\tif(indexOfAttacker > -1){\n\t\t\t\tmAttackers[indexOfAttacker].kill();\n\t\t\t\tmLivingAttackerCount--;\n\t\t\t\tmMonsterHouseSpawn--;\n\t\t\t\tmRoundScore += 100f;\n\t\t\t\tif(indexOfAttacker > ATTACKER_HALF_SIZE - 1)\n\t\t\t\t\tmRoundScore += 150f; // 150 Bonus points for killing a knight\n\t\t\t}\n\t\t}\n\n\t\t// Spawns a new enemy once the respawn timer hits less than 0\n\t\tif(mSpawnTime <0) {\n\t\t\t// Revive an attacker\n\t\t\treviveAttacker();\n\n\t\t\t// Randomly select a new respawn timer within min and max bounds\n\t\t\tmSpawnTime = mRandom.nextInt(mSpawnTimeMax - mSpawnTimeMin + 1) + mSpawnTimeMin;\n\t\t}\n\n\t\t//spawns a row of enemy units if player is doing well\n\t\tif(mMonsterHouseSpawn <0) {\n\t\t\tint monsterHouseRush = 3;\n\t\t\twhile(monsterHouseRush > 0) {\n\t\t\t\tfor (float i = 0; i < 5f; i++) {\n\t\t\t\t\treviveAttacker();\n\t\t\t\t}\n\t\t\t\tmonsterHouseRush--;\n\t\t\t}\n\t\t\tmMonsterHouseSpawn = 10;\n\t\t}\n\n\t\t// Loop through the array of attackers and update each (dead attackers' update does nothing)\n\t\tfor (int i = 0; i < ATTACKER_ARRAY_SIZE; i++) {\n\t\t\tAttacker a = mAttackers[i];\n\t\t\ta.update(deltaTime);\n\n\t\t\tif(a.getX() > MIN_STOP_X) {\n\t\t\t\t// Play the attacker's \"attack\" animation\n\t\t\t\ta.play(\"attack\", true);\n\t\t\t\t// The attacker stops at the castle and the castle begins losing health\n\t\t\t\ta.setPosition(MIN_STOP_X, a.getY());\n\t\t\t\tmCastleHealth -= a.getHitDamage();\n\t\t\t\t// Only bother checking castle damage stage here - only when damage is being dealt\n\t\t\t\tfloat percentDamage = (mCastleMaxHealth - mCastleHealth) / mCastleMaxHealth;\n\t\t\t\tif(percentDamage < 0.5f) {\n\t\t\t\t\tmCastleDamageStage = 0;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tmCastleDamageStage = 1;\n\t\t\t\t}\n\t\t\t\tif(percentDamage > 0.15f) {\n\t\t\t\t\tmCastleDamageStage = 2;\n\t\t\t\t}\n\t\t\t\tif(percentDamage > 0.35f) {\n\t\t\t\t\tmCastleDamageStage = 3;\n\t\t\t\t}\n\t\t\t\tif(percentDamage > 0.65f) {\n\t\t\t\t\tmCastleDamageStage = 4;\n\t\t\t\t}\n\t\t\t\tif(percentDamage > 0.85f) {\n\t\t\t\t\tmCastleDamageStage = 5;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Check if the game is over, where mCastleHealth <= 0\n\t\tif(mCastleHealth <= 0) {\n\t\t\t// The castle has fallen to the attackers\n\t\t\t// Currently, the game will pause and add text that states the game is over\n\t\t\tmCastleHealth = 0f;\n\t\t\tmHealthText = \"Castle Strength: \" + mCastleHealth;\n\t\t\tmGameState = STATE_GAME_OVER;\n\t\t\thideAllButtons();\n\t\t}\n\n\t\t// If the round time is up, end the round and go to a new state\n\t\tif(mRoundTimeElapsed > mRoundMaxTime) {\n\t\t\tmGameState = STATE_ROUND_OVER;\n\t\t\tmTotalScore += mRoundScore;\n\t\t\tmRoundNumber++;\n\t\t\thideAllButtons();\n\t\t}\n\t}" ]
[ "0.639491", "0.611533", "0.60826015", "0.5911677", "0.5827148", "0.57843685", "0.5708848", "0.5645696", "0.56363577", "0.5636033", "0.5631186", "0.56264216", "0.5616197", "0.5609375", "0.56041515", "0.554079", "0.55150443", "0.5499494", "0.5458649", "0.5451369", "0.5436238", "0.5428912", "0.5423182", "0.53879577", "0.53510624", "0.533046", "0.5319948", "0.5289159", "0.5288279", "0.52853024", "0.5282892", "0.5282346", "0.5281523", "0.52750546", "0.52750546", "0.52676636", "0.5264779", "0.5264575", "0.5246501", "0.52448356", "0.5218154", "0.52177805", "0.5212011", "0.52076447", "0.5206098", "0.5190613", "0.51889706", "0.5178087", "0.51758015", "0.5170466", "0.5155022", "0.515335", "0.5152309", "0.5146421", "0.51411223", "0.51387876", "0.51294696", "0.5117537", "0.51126635", "0.50955623", "0.5092713", "0.50912374", "0.50765944", "0.50690234", "0.50645167", "0.50618744", "0.504292", "0.5040528", "0.50395215", "0.5032108", "0.5026408", "0.50254375", "0.50153804", "0.50084984", "0.50084555", "0.5008277", "0.50019586", "0.49921605", "0.49920362", "0.49916878", "0.49907908", "0.49885234", "0.49801487", "0.49759144", "0.49738517", "0.49620697", "0.49610028", "0.49524492", "0.49503773", "0.49492538", "0.49472606", "0.49470577", "0.49458873", "0.49430847", "0.49410576", "0.49375778", "0.49311748", "0.49274555", "0.49242392", "0.49219078" ]
0.72728777
0
Distribute Exp and SP rewards to L2PcInstance (including Summon owner) that hit the L2Attackable and to their Party members. Actions : Get the L2PcInstance owner of the L2SummonInstance (if necessary) and L2Party in progress Calculate the Experience and SP rewards in function of the level difference Add Exp and SP rewards to L2PcInstance (including Summon penalty) and to Party members in the known area of the last attacker Caution : This method DOESN'T GIVE rewards to L2PetInstance
@Override protected void calculateRewards(final L2Character lastAttacker) { // Creates an empty list of rewards final Map<L2Character, RewardInfoHolder> rewards = new ConcurrentHashMap<>(); try { if (getAggroListRP().isEmpty()) { return; } if (EngineModsManager.onNpcExpSp(this, lastAttacker)) { return; } L2PcInstance maxDealer = null; int maxDamage = 0; int damage; L2Character attacker, ddealer; // While Interacting over This Map Removing Object is Not Allowed synchronized (getAggroList()) { // Go through the aggroList of the L2Attackable for (final AggroInfoHolder info : getAggroListRP().values()) { if (info == null) { continue; } // Get the L2Character corresponding to this attacker attacker = info.getAttacker(); // Get damages done by this attacker damage = info.getDmg(); // Prevent unwanted behavior if (damage > 1) { if (attacker instanceof L2SummonInstance || attacker instanceof L2PetInstance && ((L2PetInstance) attacker).getPetData().getOwnerExpTaken() > 0) { ddealer = ((L2Summon) attacker).getOwner(); } else { ddealer = info.getAttacker(); } // Check if ddealer isn't too far from this (killed monster) if (!Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, ddealer, true)) { continue; } // Calculate real damages (Summoners should get own damage plus summon's damage) RewardInfoHolder reward = rewards.get(ddealer); if (reward == null) { reward = new RewardInfoHolder(ddealer, damage); } else { reward.addDamage(damage); } rewards.put(ddealer, reward); if (ddealer instanceof L2PlayableInstance && ((L2PlayableInstance) ddealer).getActingPlayer() != null && reward.getDmg() > maxDamage) { maxDealer = ((L2PlayableInstance) ddealer).getActingPlayer(); maxDamage = reward.getDmg(); } } } } // Manage Base, Quests and Sweep drops of the L2Attackable doItemDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker); // Manage drop of Special Events created by GM for a defined period doEventDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker); if (!getMustRewardExpSP()) { return; } if (!rewards.isEmpty()) { L2Party attackerParty; long exp; int levelDiff, partyDmg, partyLvl, sp; float partyMul, penalty; RewardInfoHolder reward2; int[] tmp; for (final RewardInfoHolder reward : rewards.values()) { if (reward == null) { continue; } // Penalty applied to the attacker's XP penalty = 0; // Attacker to be rewarded attacker = reward.getAttacker(); // Total amount of damage done damage = reward.getDmg(); // If the attacker is a Pet, get the party of the owner if (attacker instanceof L2PetInstance) { attackerParty = ((L2PetInstance) attacker).getParty(); } else if (attacker instanceof L2PcInstance) { attackerParty = ((L2PcInstance) attacker).getParty(); } else { return; } // If this attacker is a L2PcInstance with a summoned L2SummonInstance, get Exp Penalty applied for the current summoned L2SummonInstance if (attacker instanceof L2PcInstance && ((L2PcInstance) attacker).getPet() instanceof L2SummonInstance) { penalty = ((L2SummonInstance) ((L2PcInstance) attacker).getPet()).getExpPenalty(); } // We must avoid "over damage", if any if (damage > getMaxHp()) { damage = getMaxHp(); } // If there's NO party in progress if (attackerParty == null) { // Calculate Exp and SP rewards if (attacker.getKnownList().knowsObject(this)) { // Calculate the difference of level between this attacker (L2PcInstance or L2SummonInstance owner) and the L2Attackable // mob = 24, atk = 10, diff = -14 (full xp) // mob = 24, atk = 28, diff = 4 (some xp) // mob = 24, atk = 50, diff = 26 (no xp) levelDiff = attacker.getLevel() - getLevel(); tmp = calculateExpAndSp(levelDiff, damage); exp = tmp[0]; exp *= 1 - penalty; sp = tmp[1]; if (Config.L2JMOD_CHAMPION_ENABLE && isChampion()) { exp *= Config.L2JMOD_CHAMPION_REWARDS; sp *= Config.L2JMOD_CHAMPION_REWARDS; } // Check for an over-hit enabled strike and VIP options if (attacker instanceof L2PcInstance) { final L2PcInstance player = (L2PcInstance) attacker; if (isOverhit() && attacker == getOverhitAttacker()) { player.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT)); exp += calculateOverhitExp(exp); } if (player.isVIP()) { exp = (long) (exp * Config.VIP_XPSP_RATE); sp = (int) (sp * Config.VIP_XPSP_RATE); } } // Distribute the Exp and SP between the L2PcInstance and its L2Summon if (!attacker.isDead()) { attacker.addExpAndSp(Math.round(attacker.calcStat(Stats.EXPSP_RATE, exp, null, null)), (int) attacker.calcStat(Stats.EXPSP_RATE, sp, null, null)); } } } else { // share with party members partyDmg = 0; partyMul = 1.f; partyLvl = 0; // Get all L2Character that can be rewarded in the party final List<L2PlayableInstance> rewardedMembers = new ArrayList<>(); // Go through all L2PcInstance in the party List<L2PcInstance> groupMembers; if (attackerParty.isInCommandChannel()) { groupMembers = attackerParty.getCommandChannel().getMembers(); } else { groupMembers = attackerParty.getPartyMembers(); } for (final L2PcInstance pl : groupMembers) { if (pl == null || pl.isDead()) { continue; } // Get the RewardInfo of this L2PcInstance from L2Attackable rewards reward2 = rewards.get(pl); // If the L2PcInstance is in the L2Attackable rewards add its damages to party damages if (reward2 != null) { if (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true)) { partyDmg += reward2.getDmg(); // Add L2PcInstance damages to party damages rewardedMembers.add(pl); if (pl.getLevel() > partyLvl) { if (attackerParty.isInCommandChannel()) { partyLvl = attackerParty.getCommandChannel().getLevel(); } else { partyLvl = pl.getLevel(); } } } rewards.remove(pl); // Remove the L2PcInstance from the L2Attackable rewards } else { // Add L2PcInstance of the party (that have attacked or not) to members that can be rewarded // and in range of the monster. if (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true)) { rewardedMembers.add(pl); if (pl.getLevel() > partyLvl) { if (attackerParty.isInCommandChannel()) { partyLvl = attackerParty.getCommandChannel().getLevel(); } else { partyLvl = pl.getLevel(); } } } } final L2PlayableInstance summon = pl.getPet(); if (summon != null && summon instanceof L2PetInstance) { reward2 = rewards.get(summon); if (reward2 != null) // Pets are only added if they have done damage { if (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, summon, true)) { partyDmg += reward2.getDmg(); // Add summon damages to party damages rewardedMembers.add(summon); if (summon.getLevel() > partyLvl) { partyLvl = summon.getLevel(); } } rewards.remove(summon); // Remove the summon from the L2Attackable rewards } } } // If the party didn't killed this L2Attackable alone if (partyDmg < getMaxHp()) { partyMul = (float) partyDmg / (float) getMaxHp(); } // Avoid "over damage" if (partyDmg > getMaxHp()) { partyDmg = getMaxHp(); } // Calculate the level difference between Party and L2Attackable levelDiff = partyLvl - getLevel(); // Calculate Exp and SP rewards tmp = calculateExpAndSp(levelDiff, partyDmg); exp = tmp[0]; sp = tmp[1]; if (Config.L2JMOD_CHAMPION_ENABLE && isChampion()) { exp *= Config.L2JMOD_CHAMPION_REWARDS; sp *= Config.L2JMOD_CHAMPION_REWARDS; } exp *= partyMul; sp *= partyMul; // Check for an over-hit enabled strike // (When in party, the over-hit exp bonus is given to the whole party and splitted proportionally through the party members) if (attacker instanceof L2PcInstance) { final L2PcInstance player = (L2PcInstance) attacker; if (isOverhit() && attacker == getOverhitAttacker()) { player.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT)); exp += calculateOverhitExp(exp); } } // Distribute Experience and SP rewards to L2PcInstance Party members in the known area of the last attacker if (partyDmg > 0) { attackerParty.distributeXpAndSp(exp, sp, rewardedMembers, partyLvl); } } } } } catch (final Exception e) { LOGGER.error("", e); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "public void actionCombat(Party p1) {\n System.out.println(\"______________________________________________________________________________\\n\");\n System.out.println(this.Name + \" is attacking ...\");\n int choice = (int)(Math.random() * p1.getTeam().size());\n Character target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n\n if (this.SPEED - target.getSPEED() < 5) {\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n }\n else {\n int n = 0;\n while ((target.actualHP != 0) && (n < 2)) {\n if (n == 1) {\n choice = (int)(Math.random() * p1.getTeam().size() + 1);\n target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n }\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n if (n == 0) System.out.println(this.Name + \" attacks again ...\");\n n++;\n }\n }\n }", "@Override\r\n\tpublic boolean damageEntity(DamageSource damagesource, float f2) {\n\t\tboolean toReturn = super.damageEntity(damagesource, f2);\r\n\t\tif(f2>=3 && !this.isInvulnerable(damagesource) && damagesource.getEntity()!=null && damagesource.getEntity().getBukkitEntity() instanceof Player) { // prevent things like snowball damage from triggering this ability\r\n\t\t\tif(random.nextInt(100)+1<=20) { //prevent boss from getting combo'd to hard in corner\r\n\t\t\t\tif(!teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity())) {\r\n\t\t\t\t\tteleportToEnemy();\t\t\r\n\t\t\t\t\tteleportCooldown.addCooldown((Player)damagesource.getEntity().getBukkitEntity());\r\n\t\t\t\t\tLog.info(teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity()));\r\n\t\t\t\t\tLog.info(((Player)damagesource.getEntity().getBukkitEntity()).getName());\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn toReturn;\r\n\t}", "@Override\n public void onLivingUpdate() {\n if (this.lastEntityToAttack != this.entityToAttack) {\n IAttributeInstance attribute = this.getEntityAttribute(SharedMonsterAttributes.movementSpeed);\n attribute.removeModifier(EntityEnderCreeper.attackingSpeedBoost);\n if (this.entityToAttack != null) {\n attribute.applyModifier(EntityEnderCreeper.attackingSpeedBoost);\n }\n }\n this.lastEntityToAttack = this.entityToAttack;\n\n for (int i = 0; i < 2; i++) {\n this.worldObj.spawnParticle(\"portal\", this.posX + (this.rand.nextDouble() - 0.5) * this.width, this.posY + this.rand.nextDouble() * this.height - 0.25, this.posZ + (this.rand.nextDouble() - 0.5) * this.width, (this.rand.nextDouble() - 0.5) * 2.0, -this.rand.nextDouble(), (this.rand.nextDouble() - 0.5) * 2.0);\n }\n if (this.worldObj.isDaytime() && !this.worldObj.isRemote) {\n float brightness = this.getBrightness(1.0F);\n if (brightness > 0.5F && this.worldObj.canBlockSeeTheSky((int)Math.floor(this.posX), (int)Math.floor(this.posY), (int)Math.floor(this.posZ)) && this.rand.nextFloat() * 30.0F < (brightness - 0.4F) * 2.0F) {\n this.entityToAttack = null;\n this.teleportRandomly();\n }\n }\n if (this.isWet()) {\n this.attackEntityFrom(DamageSource.drown, 1);\n this.entityToAttack = null;\n this.teleportRandomly();\n }\n this.isJumping = false;\n if (this.entityToAttack != null) {\n if (this.entityToAttack.getDistanceSqToEntity(this) < 9.0 && this.canEntityBeSeen(this.entityToAttack)) {\n this.setCreeperState(1);\n }\n else {\n this.setCreeperState(-1);\n }\n this.faceEntity(this.entityToAttack, 100.0F, 100.0F);\n }\n if (!this.worldObj.isRemote && this.isEntityAlive()) {\n if (this.entityToAttack != null) {\n if (this.entityToAttack instanceof EntityPlayer && this.shouldAttackPlayer((EntityPlayer)this.entityToAttack)) {\n if (this.getCreeperState() < 0 && this.entityToAttack.getDistanceSqToEntity(this) < 16.0) {\n this.teleportRandomly();\n }\n this.teleportDelay = 0;\n }\n else if (this.entityToAttack.getDistanceSqToEntity(this) > 256.0 && this.teleportDelay++ >= 30 && this.teleportToEntity(this.entityToAttack)) {\n this.teleportDelay = 0;\n }\n }\n else {\n this.teleportDelay = 0;\n }\n }\n super.onLivingUpdate();\n }", "public abstract void attack(Vector2 spawnPos, Vector2 target);", "public static void damageStep () {\r\n // rough plan:\r\n // #1: flip defending monster, if face down -> see flipMonster(...);\r\n // #2: Ask CPU and player for possible effect negation! (For an attack negation it is too late!) -> see below in this method\r\n // #3: calculate damage, kill monsters, if needed\r\n // (consider also banishing and immunity, also copied passive effect of (Holy) Lance)\r\n // -> see makeDamageCalculation(...);\r\n // #4: decrease life points, if needed -> see isDealingBattleDamageAndContinuingGame(...);\r\n // #5: consider passive (also copied) trap monster effects -> see possibleSuicideEffect(...);\r\n // #6: display Win/Lose dialog and end match, if needed -> see Game.over(...);\r\n // #7: finally end the attack (consider the effects that happen afterwards), thus allowing the next attack -> endDamageStep(...);\r\n \r\n // about #1:\r\n if (Game.ActiveGuardingMonster.isFaceDown) {flipMonster(Game.ActiveGuardingMonster);}\r\n // about #2:\r\n if (Game.ActiveAttackingMonster.canBeNegated() || Game.ActiveGuardingMonster.canBeNegated()) {\r\n AIinterrupts.cpuIsUsingEffectNegateDuringBattlePhase(); // ask CPU to negate effects first\r\n // ask player to negate effect here\r\n boolean isCanceling = false;\r\n boolean hasEffectNegateHandTrap = Hand.lookForEffectNegateOnHand(true);\r\n boolean hasEffectNegateOnField = Hand.lookForEffectNegateOnField(true);\r\n if (hasEffectNegateHandTrap || hasEffectNegateOnField) {\r\n if (hasEffectNegateHandTrap && !hasEffectNegateOnField) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, true);\r\n }\r\n else if (!hasEffectNegateHandTrap && hasEffectNegateOnField) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, false);\r\n }\r\n else {\r\n int intDialogResult = YuGiOhJi.multipleChoiceDialog(\"Do you want to negate effects on the field?\", \"You can negate passive effects.\", new String[]{\"yes, by discarding Neutraliser\", \"yes, by paying the cost worth 1 card\", \"no (default)\"}, \"no (default)\");\r\n if (intDialogResult==0) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, true);\r\n }\r\n else if (intDialogResult==1) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, false);\r\n }\r\n }\r\n }\r\n if (!isCanceling) {\r\n makeDamageCalculation(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster); // whole rest of battle\r\n }\r\n }\r\n else {\r\n makeDamageCalculation(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster); // whole rest of battle\r\n }\r\n \r\n }", "protected void attackEntity(Entity par1Entity, float par2) {\n/* 310 */ if (this.attackTime <= 0 && par2 < 3.0F && (par1Entity.func_174813_aQ()).field_72337_e > (func_174813_aQ()).field_72338_b && (par1Entity.func_174813_aQ()).field_72338_b < (func_174813_aQ()).field_72337_e) {\n/* */ \n/* 312 */ if (getIsSummoned()) {\n/* 313 */ ((EntityLivingBase)par1Entity).field_70718_bc = 100;\n/* */ }\n/* */ \n/* 316 */ this.attackTime = 15 + this.field_70146_Z.nextInt(10);\n/* */ \n/* 318 */ double mx = par1Entity.field_70159_w;\n/* 319 */ double my = par1Entity.field_70181_x;\n/* 320 */ double mz = par1Entity.field_70179_y;\n/* 321 */ if (func_70652_k(par1Entity) && \n/* 322 */ !this.field_70170_p.field_72995_K && par1Entity instanceof EntityLivingBase) {\n/* 323 */ ((EntityLivingBase)par1Entity).func_70690_d(new PotionEffect(MobEffects.field_76437_t, 100, 0));\n/* */ }\n/* */ \n/* 326 */ par1Entity.field_70160_al = false;\n/* 327 */ par1Entity.field_70159_w = mx;\n/* 328 */ par1Entity.field_70181_x = my;\n/* 329 */ par1Entity.field_70179_y = mz;\n/* */ \n/* 331 */ func_184185_a(SoundsTC.swarmattack, 0.3F, 0.9F + this.field_70170_p.field_73012_v.nextFloat() * 0.2F);\n/* */ } \n/* */ }", "public void attack() {\n energy = 2;\n redBull = 0;\n gun = 0;\n target = 1;\n // if Player is in range take off a life.\n if (CharacterTask.ghostLocation == GameWindow.playerLocation) {\n playerLives = playerLives - 1;\n System.out.println(\"Player Lives: \" + playerLives);\n }\n }", "public void ability(LevelManager lm){\n\n int prevDamage = lm.player.getDamage();\n int newDamage = prevDamage+12;\n lm.player.setDamage(newDamage);\n }", "public void ExecuteAction()\n {\n ActionTarget oTarget = mVecTargets.get( 0 );\n\n // Check if attack lands: compute chance of hitting the target\n if ( RandomGenerator.GetInstance().GetRandom( 1, 100 ) <=\n mSourceUnit.GetHitChance( oTarget.mCell.GetUnit() ) )\n {\n // Get the attack information from the attacking unit\n double dFinalDamage = Math.max(\n 1,\n mSourceUnit.GetUnit().GetResultingAttributes().GetStrength() -\n oTarget.mCell.GetUnit().GetUnit().GetResultingAttributes().GetPhysicalDef() );\n\n // Check critical chance\n if ( RandomGenerator.GetInstance().GetRandom( 1, 100 ) <=\n mSourceUnit.GetCritChance() )\n {\n dFinalDamage *= 1.5;\n oTarget.mActionStatus = ActionStatus.STATUS_CRITICAL;\n }\n else\n {\n oTarget.mActionStatus = ActionStatus.STATUS_SUCCESS;\n }\n\n // Add random portion to damage (10% of base damage)\n dFinalDamage = RandomGenerator.GetInstance().GetRandom(\n dFinalDamage - ( dFinalDamage / 10 ),\n dFinalDamage + ( dFinalDamage / 10 ) );\n mDamage = oTarget.mCell.GetUnit().ApplyDamage( dFinalDamage );\n\n // Add Slow status to target\n oTarget.mCell.GetUnit().SetStatus( new UnitStatusSlow(\n SLOW_TURN_DURATION,\n oTarget.mCell.GetUnit(),\n SLOW_PERCENTAGE ) );\n\n }\n else\n {\n mDamage = 0;\n oTarget.mActionStatus = ActionStatus.STATUS_MISS;\n }\n\n NotifyActionUpdate();\n ResetAttackArray();\n mSourceUnit.SetActionPerformed();\n }", "@Override\n public boolean attack(Player attacker, int mode1, int[] mode2, Player[] attackedPlayers, Position[] movements, PowerupCard[] payment) {\n boolean done = false;\n if(isLoaded() && attackedPlayers.length>=1 && attacker.getPosition().reachable(attackedPlayers[0].getPosition())){\n if(mode1==0 && attackedPlayers.length==1){\n attackedPlayers[0].receivedDamages(attacker);\n attackedPlayers[0].setMarksReceived(attacker,2);\n attacker.setMarksGiven(attackedPlayers[0],2);\n attacker.setPosition(attackedPlayers[0].getPosition());\n loaded=false;\n done=true;\n }else if(mode1==1){\n if(attackedPlayers.length==1 && isPaid(attacker, payment)){\n for(int i=0; i<2; i++)\n attackedPlayers[0].receivedDamages(attacker);\n attacker.setPosition(attackedPlayers[0].getPosition());\n loaded=false;\n done=true;\n }else if(attackedPlayers.length==2 && attackedPlayers[0].getPosition().reachable(attackedPlayers[1].getPosition()) && isPaid(attacker, payment)){\n boolean sameValueOfX = attacker.getPosition().getCoordinate()[0] == attackedPlayers[1].getPosition().getCoordinate()[0];\n boolean sameValueOfY = attacker.getPosition().getCoordinate()[1] == attackedPlayers[1].getPosition().getCoordinate()[1];\n boolean sameDirection = (sameValueOfX || sameValueOfY) && attacker.getPosition() != attackedPlayers[1].getPosition();\n if(sameDirection){\n for (int i = 0; i < 2; i++) {\n attackedPlayers[i].receivedDamages(attacker);\n attackedPlayers[i].receivedDamages(attacker);\n }\n attacker.setPosition(attackedPlayers[1].getPosition());\n loaded = false;\n done = true;\n }\n }\n }\n }\n return done;\n }", "public void attack(Player p){\n p.takeDamage(damage);\n }", "@Override\n public void onTargetDamaged(LivingEntity user, Entity target, int level) {\n if(target instanceof LivingEntity) {\n\n //target.damage(DamageSource.LAVA, 3F);\n knockUp((PlayerEntity) user, (LivingEntity) target, 3F);\n }\n }", "public void resolve(){\n logger.log(Level.FINE,attacker.getName()+\" withering attacked \"+defender.getName());\n AttackState state=new AttackState();\n state.weaponDamage=weapon.getDamage();\n state.initialAttackpool=baseAttackdice+baseAccuracy-woundpenalty;\n attacker.declareWitheringAttack(state); // If the attacker wants to change the pool, he modifies the state accordingly.\n defender.declareWitheringDV(state); // Defender declares their dv against this specific attack. This sets both initialdv and changedDv\n state.initialAttackRoll= new DiceThrow(state.changedAttackpool);\n attacker.modifyWitheringAttackRollAttacker(state); //This sets stuff like modifiedAttackRollAttacker and AttackerRollValuation\n defender.modifyWitheringAttackRollDefender(state); //This sets defender modifiedAttackRollDefender\n state.attackRollSuccesses=state.modifiedAttackRollDefender.evaluateResults(state.AttackRollValuationAttacker);\n state.threshholdSuccesses=state.attackRollSuccesses-state.changedDv;\n logger.log(Level.FINE,attacker.getName()+\" rolled \"+state.changedAttackpool+\" dice against \"+defender.getName()+\"'s dv of \"+state.changedDv+\" and gained \"+state.attackRollSuccesses+\" successes.\");\n attacker.changeWitheringThreshholdAttacker(state); //This sets thresholdModifiedAttacker\n defender.changeWitheringThreshholdDefender(state); //This sets thresholdModifiedDefender\n if(state.thresholdModifiedDefender>=0) {\n logger.log(Level.FINE,attacker.getName()+\" hit \"+defender.getName()+\" with \"+state.thresholdModifiedDefender+\" threshhold successes.\");\n attacker.modifyWitheringRawDamageAttacker(state); //Sets normal raw damageType, based on strength and weapon damageType, and then sets rawDamagemModifiedAttacker\n defender.modifyWitheringRawDamageDefender(state); //this sets rawDamageModifiedDefender, and sets up the various soak values, so natural soak and armor soak.\n logger.log(Level.FINE, \"The raw damage of the attack is: \"+state.rawDamageModifiedDefender);\n state.totalSoak = Math.max(state.defenderArmorSoak - ignoredArmorSoak, 0) + state.defenderNaturalSoak; //\n attacker.modifyTotalSoakAttacker(state); //This sets totalSoakmodifiedAttacker. Don't think this actually has support in the solar charmset, but giving opportunities to work with.\n defender.modifyTotalSoakDefender(state); // This sets totalSoakmodifiedDefender.\n state.postSoakSuccesses=Math.max(state.rawDamageModifiedDefender-state.totalSoakModifiedDefender,weapon.getOverwhelming());\n logger.log(Level.FINE,state.totalSoakModifiedDefender+\" damage is soaked, leading to post soak dice of \"+state.postSoakSuccesses);\n attacker.declarePostSoakAttacker(state); //sets postSoakSuccessesModifiedAttacker\n defender.declarePostSoakDefender(state); //sets postSoakSuccessesModifiedDefender\n DiceThrow droll=new DiceThrow(state.postSoakSuccessesModifiedDefender);\n state.damageRoll=droll;\n attacker.modifyWitheringDamageRollAttacker(state); //sets damageRollmodifiedAttacker and damageRollvValuation\n defender.modifyWitheringDamageRollDefender(state); //sets damageRollmodifiedDefender\n state.initiativeDamageDone=state.damageRollModifiedDefender.evaluateResults(state.damageRollValuation);\n logger.log(Level.FINE,attacker.getName()+\" rolls \"+state.postSoakSuccessesModifiedDefender+\" dice and achieves \"+state.initiativeDamageDone+\" successes.\");\n attacker.modifyInitiativeDamageAttacker(state);\n defender.modifyInitiativeDamageDefender(state); //Since this is the last change of initiative, we can check whether the defender was crashed here.\n attacker.updateInitiativeAttacker(state);\n defender.updateInitiativeDefender(state);//Here we should handle all the initiative changes respectively, with checking if people are crashed etc.\n }\n else{\n attacker.failedWitheringAttackAttacker(state);\n defender.failedWitheringAttackDefender(state);\n }\n\n }", "@Deprecated\n/* */ protected static boolean performAttack(int pos, boolean aiming, Creature performer, Skills performerSkills, Creature defender, Skills defenderSkills, Item attWeapon, Item defPrimWeapon, double attBonus, double defBonus, Skill attackerFightSkill, Skill defenderFightSkill, int counter) {\n/* 829 */ boolean shieldBlocked = false;\n/* 830 */ boolean done = false;\n/* 831 */ Skill primWeaponSkill = null;\n/* 832 */ Skill defPrimWeaponSkill = null;\n/* 833 */ Item defShield = null;\n/* 834 */ Skill defShieldSkill = null;\n/* 835 */ int skillnum = -10;\n/* 836 */ boolean dryrun = false;\n/* */ \n/* 838 */ if (performer.isPlayer()) {\n/* */ \n/* 840 */ if (defender.isPlayer() || defender.isReborn()) {\n/* */ \n/* */ \n/* 843 */ dryrun = true;\n/* */ }\n/* 845 */ else if (defender.isKingdomGuard() || (defender\n/* 846 */ .isSpiritGuard() && defender.getKingdomId() == performer.getKingdomId())) {\n/* 847 */ dryrun = true;\n/* */ } \n/* 849 */ } else if (performer.isKingdomGuard() || (performer\n/* 850 */ .isSpiritGuard() && defender.getKingdomId() == performer.getKingdomId())) {\n/* 851 */ dryrun = true;\n/* 852 */ } if ((defender.isPlayer() && !defender.hasLink()) || (performer.isPlayer() && !performer.hasLink()))\n/* 853 */ dryrun = true; \n/* 854 */ if (defender.getStatus().getStunned() > 0.0F) {\n/* */ \n/* 856 */ defBonus -= 20.0D;\n/* 857 */ attBonus += 20.0D;\n/* */ } \n/* 859 */ if (attWeapon != null)\n/* */ {\n/* 861 */ if (attWeapon.isBodyPart()) {\n/* */ \n/* */ \n/* */ try {\n/* 865 */ skillnum = 10052;\n/* 866 */ primWeaponSkill = performerSkills.getSkill(skillnum);\n/* */ }\n/* 868 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 870 */ if (skillnum != -10)\n/* 871 */ primWeaponSkill = performerSkills.learn(skillnum, 1.0F); \n/* */ } \n/* 873 */ if (performer.isPlayer() && defender.isPlayer())\n/* */ {\n/* 875 */ if (primWeaponSkill.getKnowledge(0.0D) >= 20.0D) {\n/* 876 */ dryrun = true;\n/* */ }\n/* */ }\n/* */ } else {\n/* */ \n/* */ \n/* */ try {\n/* 883 */ skillnum = attWeapon.getPrimarySkill();\n/* 884 */ primWeaponSkill = performerSkills.getSkill(skillnum);\n/* */ }\n/* 886 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 888 */ if (skillnum != -10) {\n/* 889 */ primWeaponSkill = performerSkills.learn(skillnum, 1.0F);\n/* */ }\n/* */ } \n/* */ } \n/* */ }\n/* */ \n/* */ \n/* 896 */ skillnum = -10;\n/* 897 */ if (defPrimWeapon != null)\n/* */ {\n/* 899 */ if (defPrimWeapon.isBodyPart()) {\n/* */ \n/* */ \n/* */ try {\n/* 903 */ skillnum = 10052;\n/* 904 */ defPrimWeaponSkill = defenderSkills.getSkill(skillnum);\n/* */ }\n/* 906 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 908 */ if (skillnum != -10)\n/* 909 */ defPrimWeaponSkill = defenderSkills.learn(skillnum, 1.0F); \n/* */ } \n/* 911 */ if (performer.isPlayer() && defender.isPlayer())\n/* */ {\n/* 913 */ if (defPrimWeaponSkill.getKnowledge(0.0D) >= 20.0D) {\n/* 914 */ dryrun = true;\n/* */ }\n/* */ }\n/* */ } else {\n/* */ \n/* */ \n/* */ try {\n/* 921 */ skillnum = defPrimWeapon.getPrimarySkill();\n/* 922 */ defPrimWeaponSkill = defenderSkills.getSkill(skillnum);\n/* */ }\n/* 924 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 926 */ if (skillnum != -10) {\n/* 927 */ defPrimWeaponSkill = defenderSkills.learn(skillnum, 1.0F);\n/* */ }\n/* */ } \n/* */ } \n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 939 */ Skill attStrengthSkill = null;\n/* */ \n/* */ try {\n/* 942 */ attStrengthSkill = performerSkills.getSkill(102);\n/* */ }\n/* 944 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 946 */ attStrengthSkill = performerSkills.learn(102, 1.0F);\n/* 947 */ logger.log(Level.WARNING, performer.getName() + \" had no strength. Weird.\");\n/* */ } \n/* */ \n/* 950 */ double bonus = 0.0D;\n/* 951 */ if (primWeaponSkill != null) {\n/* */ \n/* 953 */ float mod = getMod(performer, defender, primWeaponSkill);\n/* 954 */ bonus = Math.max(-20.0D, primWeaponSkill.skillCheck(\n/* 955 */ Math.abs(primWeaponSkill.getKnowledge(0.0D) - attWeapon.getCurrentQualityLevel()), attBonus, (mod == 0.0F || dryrun), \n/* 956 */ (float)(long)Math.max(1.0F, counter * mod)));\n/* */ } \n/* */ \n/* */ \n/* 960 */ skillnum = -10;\n/* 961 */ defShield = defender.getShield();\n/* 962 */ if (defShield != null) {\n/* */ \n/* */ try {\n/* */ \n/* 966 */ skillnum = defShield.getPrimarySkill();\n/* 967 */ defShieldSkill = defenderSkills.getSkill(skillnum);\n/* */ }\n/* 969 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 971 */ if (skillnum != -10) {\n/* 972 */ defShieldSkill = defenderSkills.learn(skillnum, 1.0F);\n/* */ }\n/* */ } \n/* */ }\n/* 976 */ if (aiming) {\n/* */ \n/* 978 */ if (pos == 1) {\n/* */ \n/* 980 */ bonus = -60.0D;\n/* */ }\n/* 982 */ else if (pos == 29) {\n/* */ \n/* 984 */ bonus = -80.0D;\n/* */ }\n/* 986 */ else if (pos == 2) {\n/* */ \n/* 988 */ bonus = -40.0D;\n/* */ }\n/* 990 */ else if (pos == 3) {\n/* */ \n/* 992 */ bonus = -30.0D;\n/* */ }\n/* 994 */ else if (pos == 4) {\n/* */ \n/* 996 */ bonus = -30.0D;\n/* */ }\n/* 998 */ else if (pos == 34) {\n/* */ \n/* 1000 */ bonus = -30.0D;\n/* */ } \n/* 1002 */ pos = getRealPosition(pos);\n/* */ } else {\n/* */ \n/* */ \n/* */ try {\n/* */ \n/* 1008 */ pos = defender.getBody().getRandomWoundPos();\n/* */ }\n/* 1010 */ catch (Exception ex) {\n/* */ \n/* 1012 */ logger.log(Level.WARNING, \"Problem getting a Random Wound Position for \" + defender.getName() + \": due to \" + ex\n/* 1013 */ .getMessage(), ex);\n/* */ } \n/* */ } \n/* 1016 */ if (performer.getEnemyPresense() > 1200 && defender.isPlayer())\n/* 1017 */ bonus += 20.0D; \n/* 1018 */ double attCheck = 0.0D;\n/* 1019 */ boolean defFumbleShield = false;\n/* 1020 */ boolean defFumbleParry = false;\n/* */ \n/* 1022 */ boolean crit = false;\n/* */ \n/* 1024 */ if (defender.isPlayer()) {\n/* */ \n/* 1026 */ int critChance = attWeapon.getDamagePercent();\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1032 */ if (Server.rand.nextInt(100 - Math.min(3, critChance)) == 0)\n/* */ {\n/* 1034 */ crit = true;\n/* */ }\n/* */ } \n/* */ \n/* */ \n/* 1039 */ if (attWeapon.isBodyPartAttached()) {\n/* */ \n/* 1041 */ float mod = getMod(performer, defender, attackerFightSkill);\n/* */ \n/* 1043 */ attCheck = attackerFightSkill.skillCheck(defenderFightSkill\n/* 1044 */ .getKnowledge(defBonus) / Math.min(5, defender.getAttackers()), bonus, (mod == 0.0F || dryrun), \n/* 1045 */ (float)(long)Math.max(1.0F, counter * mod));\n/* */ }\n/* */ else {\n/* */ \n/* 1049 */ float mod = getMod(performer, defender, attackerFightSkill);\n/* 1050 */ attCheck = attackerFightSkill.skillCheck(defenderFightSkill\n/* 1051 */ .getKnowledge(defBonus) / Math.min(5, defender.getAttackers()), attWeapon, bonus, (mod == 0.0F || dryrun), \n/* 1052 */ (float)(long)Math.max(1.0F, counter * mod));\n/* */ } \n/* 1054 */ byte type = (performer.getTemplate()).combatDamageType;\n/* 1055 */ if (attWeapon.isWeaponSword()) {\n/* */ \n/* 1057 */ if (Server.rand.nextInt(2) == 0) {\n/* 1058 */ type = 1;\n/* */ } else {\n/* 1060 */ type = 2;\n/* */ } \n/* 1062 */ } else if (attWeapon.isWeaponSlash()) {\n/* 1063 */ type = 1;\n/* 1064 */ } else if (attWeapon.isWeaponPierce()) {\n/* 1065 */ type = 2;\n/* 1066 */ } else if (attWeapon.isBodyPart()) {\n/* */ \n/* 1068 */ if (attWeapon.getTemplateId() == 17) {\n/* 1069 */ type = 3;\n/* 1070 */ } else if (attWeapon.getTemplateId() == 12) {\n/* 1071 */ type = 0;\n/* */ } \n/* */ } \n/* 1074 */ String attString = getAttackString(performer, attWeapon, type);\n/* */ \n/* */ \n/* */ \n/* */ \n/* 1079 */ double defCheck = 0.0D;\n/* 1080 */ double damage = getWeaponDamage(attWeapon, attStrengthSkill);\n/* */ \n/* 1082 */ if (performer.getDeity() != null && performer.getDeity().isWarrior() && \n/* 1083 */ performer.getFaith() >= 40.0F && performer.getFavor() >= 20.0F)\n/* 1084 */ damage = Math.min(4000.0D, damage * 1.25D); \n/* 1085 */ if (performer.getEnemyPresense() > 1200 && defender.isPlayer()) {\n/* 1086 */ damage *= Math.min(4000.0F, 1.15F);\n/* */ }\n/* */ \n/* 1089 */ if (defShield != null || crit) {\n/* */ \n/* 1091 */ if (!crit)\n/* */ {\n/* 1093 */ if (pos == 9) {\n/* */ \n/* 1095 */ shieldBlocked = true;\n/* */ }\n/* 1097 */ else if (defender.getStatus().getStamina() >= 300 && !defender.isMoving()) {\n/* */ \n/* 1099 */ defCheck = 0.0D;\n/* 1100 */ if (defShieldSkill != null) {\n/* */ \n/* 1102 */ float mod = getMod(performer, defender, defShieldSkill);\n/* 1103 */ defCheck = defShieldSkill.skillCheck(attCheck, defShield, defBonus, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ } \n/* */ \n/* */ \n/* 1107 */ defCheck += (defShield.getSizeY() + defShield.getSizeZ()) / 10.0D;\n/* */ \n/* */ \n/* 1110 */ defender.getStatus().modifyStamina(-300.0F);\n/* */ } \n/* */ }\n/* 1113 */ if (defCheck > 0.0D || shieldBlocked) {\n/* */ \n/* 1115 */ shieldBlocked = true;\n/* 1116 */ if (defender.isPlayer()) {\n/* 1117 */ defShield.setDamage(defShield.getDamage() + 0.001F * (float)damage * defShield.getDamageModifier());\n/* */ }\n/* */ }\n/* 1120 */ else if (defCheck < -90.0D) {\n/* */ \n/* 1122 */ defFumbleShield = true;\n/* */ } \n/* */ } \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1134 */ if (!shieldBlocked || crit) {\n/* */ \n/* 1136 */ boolean parryPrimWeapon = true;\n/* 1137 */ defCheck = 0.0D;\n/* 1138 */ if (!crit && !defender.isMoving()) {\n/* */ \n/* 1140 */ int parryTime = 100;\n/* 1141 */ if (defender.getFightStyle() == 2) {\n/* 1142 */ parryTime = 40;\n/* 1143 */ } else if (defender.getFightStyle() == 1) {\n/* 1144 */ parryTime = 160;\n/* */ } \n/* 1146 */ if (WurmCalendar.currentTime > defender.lastParry + Server.rand.nextInt(parryTime) && \n/* 1147 */ defPrimWeapon != null && !defPrimWeapon.isWeaponAxe())\n/* */ {\n/* 1149 */ if (!defPrimWeapon.isBodyPart() || defPrimWeapon.getAuxData() == 100) {\n/* */ \n/* 1151 */ if (defender.getStatus().getStamina() >= 300) {\n/* */ \n/* 1153 */ if (defPrimWeaponSkill != null) {\n/* */ \n/* 1155 */ float mod = getMod(performer, defender, defPrimWeaponSkill);\n/* 1156 */ defCheck = defPrimWeaponSkill.skillCheck((attCheck * defender\n/* 1157 */ .getAttackers() + defPrimWeapon.getWeightGrams() / 200.0D) / \n/* 1158 */ getWeaponParryBonus(defPrimWeapon), defPrimWeapon, defBonus, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ \n/* 1160 */ defender.lastParry = WurmCalendar.currentTime;\n/* 1161 */ defender.getStatus().modifyStamina(-300.0F);\n/* */ } \n/* 1163 */ if (defCheck < -90.0D)\n/* */ {\n/* 1165 */ defFumbleParry = true;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ }\n/* 1182 */ else if (defCheck < 0.0D && Server.rand.nextInt(50) == 0)\n/* */ {\n/* 1184 */ defCheck = secondaryParry(performer, attCheck, defender, defenderSkills, defCheck, defBonus, dryrun);\n/* */ \n/* 1186 */ if (defCheck < -90.0D) {\n/* */ \n/* 1188 */ defFumbleParry = true;\n/* */ }\n/* 1190 */ else if (defCheck > 0.0D) {\n/* 1191 */ parryPrimWeapon = false;\n/* */ }\n/* */ \n/* */ }\n/* */ \n/* */ } \n/* 1197 */ } else if (defender.getStatus().getStamina() >= 300) {\n/* */ \n/* 1199 */ if (defPrimWeaponSkill != null) {\n/* */ \n/* */ \n/* */ \n/* */ \n/* 1204 */ float mod = getMod(performer, defender, defPrimWeaponSkill);\n/* 1205 */ defCheck = defPrimWeaponSkill.skillCheck(Math.min(100, 80 * defender.getAttackers()), defBonus, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ \n/* 1207 */ defender.lastParry = WurmCalendar.currentTime;\n/* 1208 */ defender.getStatus().modifyStamina(-300.0F);\n/* */ } \n/* 1210 */ if (defCheck < 0.0D && Server.rand.nextInt(50) == 0) {\n/* */ \n/* 1212 */ defCheck = secondaryParry(performer, attCheck, defender, defenderSkills, defCheck, defBonus, dryrun);\n/* */ \n/* 1214 */ if (defCheck < -90.0D) {\n/* */ \n/* 1216 */ defFumbleParry = true;\n/* */ }\n/* 1218 */ else if (defCheck > 0.0D) {\n/* 1219 */ parryPrimWeapon = false;\n/* */ } \n/* */ } \n/* */ } \n/* */ }\n/* */ } \n/* 1225 */ if (defCheck <= 0.0D || defFumbleShield || crit) {\n/* */ \n/* */ \n/* */ \n/* 1229 */ if (!defFumbleShield && !defFumbleParry && !crit)\n/* */ {\n/* 1231 */ if (defender.getStatus().getStamina() >= 300) {\n/* */ \n/* 1233 */ defender.getStatus().modifyStamina(-300.0F);\n/* 1234 */ Skill defenderBodyControl = null;\n/* */ \n/* */ try {\n/* 1237 */ defenderBodyControl = defenderSkills.getSkill(104);\n/* */ }\n/* 1239 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 1241 */ defenderBodyControl = defenderSkills.learn(104, 1.0F);\n/* 1242 */ logger.log(Level.WARNING, defender.getName() + \" no body control?\");\n/* */ } \n/* 1244 */ if (defenderBodyControl != null) {\n/* */ \n/* 1246 */ float mod = getMod(performer, defender, defenderBodyControl);\n/* 1247 */ defCheck = defenderBodyControl.skillCheck(attCheck, 0.0D, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ } else {\n/* */ \n/* 1250 */ logger.log(Level.WARNING, defender.getName() + \" has no body control!\");\n/* */ } \n/* */ } } \n/* 1253 */ if (defCheck <= 0.0D || crit) {\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1261 */ Item armour = null;\n/* */ \n/* */ \n/* 1264 */ float armourMod = defender.getArmourMod();\n/* 1265 */ float evasionChance = ArmourTemplate.calculateGlanceRate(defender.getArmourType(), armour, type, armourMod);\n/* 1266 */ if (!performer.isPlayer() && !defender.isPlayer() && !defender.isUnique())\n/* 1267 */ armourMod = 1.0F; \n/* 1268 */ if (armourMod == 1.0F) {\n/* */ \n/* */ try {\n/* */ \n/* 1272 */ byte bodyPosition = ArmourTemplate.getArmourPosition((byte)pos);\n/* 1273 */ armour = defender.getArmour(bodyPosition);\n/* 1274 */ armourMod = ArmourTemplate.calculateDR(armour, type);\n/* 1275 */ if (defender.isPlayer())\n/* 1276 */ armour.setDamage(armour.getDamage() + \n/* 1277 */ Math.min(1.0F, (float)(damage * armourMod / 80.0D) * armour\n/* */ \n/* 1279 */ .getDamageModifier() * \n/* 1280 */ ArmourTemplate.getArmourDamageModFor(armour, type))); \n/* 1281 */ checkEnchantDestruction(attWeapon, armour, defender);\n/* 1282 */ evasionChance = ArmourTemplate.calculateGlanceRate(null, armour, type, armourMod);\n/* */ }\n/* 1284 */ catch (NoArmourException nsi) {\n/* */ \n/* */ \n/* 1287 */ evasionChance = 1.0F - defender.getArmourMod();\n/* */ }\n/* 1289 */ catch (NoSpaceException nsp) {\n/* */ \n/* 1291 */ logger.log(Level.WARNING, defender.getName() + \" no armour space on loc \" + pos);\n/* */ } \n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1299 */ if (!attWeapon.isBodyPart() || attWeapon.getAuxData() == 100)\n/* */ {\n/* 1301 */ if (performer.isPlayer())\n/* 1302 */ attWeapon.setDamage(attWeapon.getDamage() + (float)(damage * (2.1D - armourMod) / 1000.0D) * attWeapon\n/* 1303 */ .getDamageModifier()); \n/* */ }\n/* 1305 */ if (defender.isUnique()) {\n/* */ \n/* 1307 */ evasionChance = 0.5F;\n/* 1308 */ damage *= armourMod;\n/* */ } \n/* 1310 */ if (Server.rand.nextFloat() < evasionChance) {\n/* */ \n/* 1312 */ if (aiming || performer.spamMode())\n/* 1313 */ performer.getCommunicator().sendNormalServerMessage(\"Your attack glances off \" + defender\n/* 1314 */ .getNameWithGenus() + \"'s armour.\"); \n/* 1315 */ if (defender.spamMode()) {\n/* 1316 */ defender.getCommunicator().sendNormalServerMessage(\"The attack to the \" + defender\n/* 1317 */ .getBody().getWoundLocationString(pos) + \" glances off your armour.\");\n/* */ }\n/* */ }\n/* 1320 */ else if (damage > (5.0F + Server.rand.nextFloat() * 5.0F) || crit) {\n/* */ \n/* 1322 */ if (crit)\n/* */ {\n/* 1324 */ armourMod = 1.0F;\n/* */ }\n/* */ \n/* */ \n/* 1328 */ Battle battle = performer.getBattle();\n/* 1329 */ boolean dead = false;\n/* 1330 */ if (defender.getStaminaSkill().getKnowledge(0.0D) < 2.0D) {\n/* */ \n/* 1332 */ defender.die(false, \"Combat Stam Check Fail\");\n/* 1333 */ dead = true;\n/* */ } else {\n/* */ \n/* 1336 */ dead = addWound(performer, defender, type, pos, damage, armourMod, attString, battle, 0.0F, 0.0F, false, false, false, false);\n/* */ } \n/* 1338 */ if (!dead && attWeapon.getSpellDamageBonus() > 0.0F)\n/* */ {\n/* 1340 */ if (damage * attWeapon.getSpellDamageBonus() / 300.0D > (Server.rand.nextFloat() * 5.0F) || crit) {\n/* 1341 */ dead = defender.addWoundOfType(performer, (byte)4, (byte)pos, false, armourMod, false, damage * attWeapon\n/* 1342 */ .getSpellDamageBonus() / 300.0D, 0.0F, 0.0F, false, false);\n/* */ }\n/* */ }\n/* 1345 */ if (!dead && attWeapon.getWeaponSpellDamageBonus() > 0.0F)\n/* */ {\n/* 1347 */ if (damage * attWeapon.getWeaponSpellDamageBonus() / 300.0D > (Server.rand.nextFloat() * 5.0F))\n/* */ {\n/* 1349 */ dead = defender.addWoundOfType(performer, (byte)6, 1, true, armourMod, false, damage * attWeapon\n/* 1350 */ .getWeaponSpellDamageBonus() / 300.0D, Server.rand\n/* 1351 */ .nextInt((int)attWeapon.getWeaponSpellDamageBonus()), 0.0F, false, false);\n/* */ }\n/* */ }\n/* 1354 */ if (armour != null)\n/* */ {\n/* 1356 */ if (armour.getSpellPainShare() > 0.0F)\n/* */ {\n/* 1358 */ if (performer.isUnique()) {\n/* 1359 */ defender.getCommunicator().sendNormalServerMessage(performer\n/* 1360 */ .getNameWithGenus() + \" ignores the effects of the \" + armour.getName() + \".\");\n/* */ \n/* */ \n/* */ }\n/* 1364 */ else if (damage * armour.getSpellPainShare() / 300.0D > 5.0D) {\n/* */ \n/* 1366 */ addBounceWound(defender, performer, type, pos, damage * armour\n/* 1367 */ .getSpellPainShare() / 300.0D, armourMod, 0.0F, 0.0F, false, true);\n/* */ } \n/* */ }\n/* */ }\n/* */ \n/* */ \n/* */ \n/* 1374 */ if (dead) {\n/* */ \n/* 1376 */ performer.getCommunicator().sendSafeServerMessage(defender.getNameWithGenus() + \" is dead!\");\n/* 1377 */ if (battle != null)\n/* 1378 */ battle.addCasualty(performer, defender); \n/* 1379 */ done = true;\n/* */ \n/* */ \n/* */ }\n/* 1383 */ else if (!defender.hasNoServerSound()) {\n/* 1384 */ SoundPlayer.playSound(defender.getHitSound(), defender, 1.6F);\n/* */ }\n/* */ \n/* */ } else {\n/* */ \n/* 1389 */ if (aiming || performer.spamMode())\n/* */ {\n/* 1391 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1392 */ .getNameWithGenus() + \" takes no real damage from the hit to the \" + defender\n/* 1393 */ .getBody().getWoundLocationString(pos) + \".\");\n/* */ }\n/* 1395 */ if (defender.spamMode()) {\n/* 1396 */ defender.getCommunicator().sendNormalServerMessage(\"You take no real damage from the blow to the \" + defender\n/* */ \n/* 1398 */ .getBody().getWoundLocationString(pos) + \".\");\n/* */ }\n/* */ } \n/* */ } else {\n/* */ \n/* 1403 */ String sstring = \"sound.combat.miss.light\";\n/* 1404 */ if (attCheck < -80.0D) {\n/* 1405 */ sstring = \"sound.combat.miss.heavy\";\n/* 1406 */ } else if (attCheck < -40.0D) {\n/* 1407 */ sstring = \"sound.combat.miss.med\";\n/* 1408 */ } SoundPlayer.playSound(sstring, defender, 1.6F);\n/* 1409 */ if (aiming || performer.spamMode())\n/* */ {\n/* 1411 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1412 */ .getNameWithGenus() + \" \" + getParryString(defCheck) + \" evades the blow to the \" + defender\n/* 1413 */ .getBody().getWoundLocationString(pos) + \".\");\n/* */ }\n/* 1415 */ if (defender.spamMode()) {\n/* 1416 */ defender.getCommunicator().sendNormalServerMessage(\"You \" + \n/* 1417 */ getParryString(defCheck) + \" evade the blow to the \" + defender\n/* 1418 */ .getBody().getWoundLocationString(pos) + \".\");\n/* */ }\n/* */ } \n/* */ } else {\n/* */ \n/* 1423 */ defender.lastParry = WurmCalendar.currentTime;\n/* 1424 */ Item weapon = defPrimWeapon;\n/* 1425 */ if (!parryPrimWeapon)\n/* 1426 */ weapon = defender.getLefthandWeapon(); \n/* 1427 */ if (aiming || performer.spamMode())\n/* */ {\n/* 1429 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1430 */ .getNameWithGenus() + \" \" + getParryString(defCheck) + \" parries with \" + weapon.getNameWithGenus() + \".\");\n/* */ }\n/* */ \n/* */ \n/* 1434 */ if (defender.spamMode())\n/* */ {\n/* 1436 */ defender.getCommunicator().sendNormalServerMessage(\"You \" + \n/* 1437 */ getParryString(defCheck) + \" parry with your \" + weapon.getName() + \".\");\n/* */ }\n/* */ \n/* 1440 */ if (!weapon.isBodyPart() || weapon.getAuxData() == 100) {\n/* */ \n/* 1442 */ if (defender.isPlayer())\n/* */ {\n/* 1444 */ if (weapon.isWeaponSword()) {\n/* 1445 */ weapon.setDamage(weapon.getDamage() + 0.001F * (float)damage * weapon.getDamageModifier());\n/* */ } else {\n/* 1447 */ weapon.setDamage(weapon.getDamage() + 0.005F * (float)damage * weapon.getDamageModifier());\n/* */ } } \n/* 1449 */ if (performer.isPlayer())\n/* */ {\n/* 1451 */ if (!attWeapon.isBodyPart() || attWeapon.getAuxData() == 100) {\n/* 1452 */ attWeapon\n/* 1453 */ .setDamage(attWeapon.getDamage() + 0.001F * (float)damage * attWeapon.getDamageModifier());\n/* */ }\n/* */ }\n/* */ } \n/* 1457 */ String sstring = \"sound.combat.parry1\";\n/* 1458 */ int x = Server.rand.nextInt(3);\n/* 1459 */ if (x == 0) {\n/* 1460 */ sstring = \"sound.combat.parry2\";\n/* 1461 */ } else if (x == 1) {\n/* 1462 */ sstring = \"sound.combat.parry3\";\n/* 1463 */ } SoundPlayer.playSound(sstring, defender, 1.6F);\n/* 1464 */ checkEnchantDestruction(attWeapon, weapon, defender);\n/* */ }\n/* */ \n/* */ } else {\n/* */ \n/* 1469 */ if (performer.spamMode()) {\n/* */ \n/* 1471 */ if (aiming) {\n/* 1472 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1473 */ .getNameWithGenus() + \" raises \" + defender.getHisHerItsString() + \" shield and parries.\");\n/* */ } else {\n/* 1475 */ performer.getCommunicator().sendNormalServerMessage(\"You try to \" + attString + \" \" + defender\n/* 1476 */ .getNameWithGenus() + \" but \" + defender.getHeSheItString() + \" raises \" + defender\n/* 1477 */ .getHisHerItsString() + \" shield and parries.\");\n/* */ } \n/* 1479 */ } else if (aiming) {\n/* 1480 */ performer.getCommunicator().sendNormalServerMessage(defender\n/* 1481 */ .getNameWithGenus() + \" raises \" + defender.getHisHerItsString() + \" shield and parries.\");\n/* 1482 */ } if (defender.spamMode())\n/* 1483 */ defender.getCommunicator().sendNormalServerMessage(performer\n/* 1484 */ .getNameWithGenus() + \" tries to \" + attString + \" you but you raise your shield and parry.\"); \n/* 1485 */ if (defShield.isWood()) {\n/* 1486 */ Methods.sendSound(defender, \"sound.combat.shield.wood\");\n/* */ } else {\n/* 1488 */ Methods.sendSound(defender, \"sound.combat.shield.metal\");\n/* 1489 */ } checkEnchantDestruction(attWeapon, defShield, defender);\n/* */ } \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 1510 */ return done;\n/* */ }", "public void move2(Pokemon enemy){\n boolean crit = false;\n boolean superEffective = false;\n boolean reduced = false;\n boolean moveHit = true;\n\n int randCrit = (int)(22 * Math.random()+1);\n\n //CHANGE ATTACK TO FALSE IF MOVE DOES NO DAMAGE<<<<<<<<<<<<<\n boolean attack = true;\n //CHANGE TYPE TO TYPE OF MOVE POWER AND ACCURACY<<<<<<<<<<<<<\n String type = \"Bug\";\n int power = 80;\n int accuracy = 100;\n\n //DO NOT CHANGE BELOW THIS\n int damage = ((CONSTANT * power * ( getAtt() / enemy.getDef() )) /50);\n if(randCrit == CONSTANT){\n damage = damage * 2;\n crit = true;\n }\n if(checkSE(type,enemy.getType())){\n damage = damage * 2;\n superEffective = true;\n }\n if(checkNVE(type, enemy.getType())){\n damage = damage / 2;\n reduced = true;\n }\n if(attack && hit(accuracy)){\n enemy.lowerHp(damage);\n }\n else{\n if(hit(accuracy)){\n //DO STATUS EFFECT STUFF HERE (ill figure out later)\n }\n }\n lowerM2PP();\n }", "private void enemyAttack() {\n\t\t\n\t\tRandom rand = new Random();\t\n\t\t\n\t\tint roll = rand.nextInt(101);\n\t\t\n\t\tint sroll = rand.nextInt(101);\n\t\t\n\t\tevents.appendText(e.getName() + \" attacks!\\n\");\n\t\t\n\t\tif(roll <= p.getEV()) { // Player evades\n\t\t\t\n\t\t\tevents.appendText(\"You evaded \"+e.getName()+\"\\'s Attack!\\n\");\n\t\t\t\n\t\t}else if(roll > p.getEV()) { // Player is hit and dies if HP is 0 or less\n\t\t\t\n\t\t\tp.setHP(p.getHP() - e.getDMG());\n\t\t\t\n\t\t\tString newHp = p.getHP()+\"/\"+p.getMaxHP();\n\t\t\t\n\t\t\tString effect = e.getSpecial(); // Stats are afflicted\n\t\t\t\n\t\t\tif(sroll < 51){\n\t\t\t\t\n\t\t\tif(effect == \"Bleed\") { // Bleed Special\n\t\t\t\t\n\t\t\t\tp.setHP(p.getHP() - 100);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You bleed profusely. - 100 HP\\n\");\n\t\t\t\t\n\t\t\t\tnewHp = String.valueOf(p.getHP()+\"/\"+p.getMaxHP());\n\t\t\t}\n\t\t\tif(effect == \"Break\") { // Break Special \n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You feel a bone break restricting movement. - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Fear\") { // Fear Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-40>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 40);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"A crippling fear rattles your resolve. - 40 DMG\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Rend\") { // Rend Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-30>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 30);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"Morthar unleashes a pillar of flame! - 30 DMG and - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\t\n\t\t\tif(p.getHP() <= 0) {\n\t\t\t\t\n\t\t\t\tp.setDead(true);\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(0+\"/\"+e.getMaxHP());\n\t\t\t\tplayerHPBar.setProgress((double)0);\n\t\t\t}else {\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(newHp);\n\t\t\t\tplayerHPBar.setProgress((double)p.getHP()/p.getMaxHP());\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tif(p.isDead()) { // Game over if player dies\n\t\t\t\n\t\t\ttry {\n\t\t\t\tLoadGO();\n\t\t\t} catch (IOException e1) {\n\t\t\t\n\t\t\t\te1.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t\tcombat = false;\n\t\t}\n\t}", "@Override\n\tpublic boolean doDie(final L2Character killer)\n\t{\n\t\t// Kill the L2NpcInstance (the corpse disappeared after 7 seconds)\n\t\tif (!super.doDie(killer))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\t// Enhance soul crystals of the attacker if this L2Attackable had its soul absorbed\n\t\ttry\n\t\t{\n\t\t\tif (killer instanceof L2PcInstance)\n\t\t\t{\n\t\t\t\tlevelSoulCrystals(killer);\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t\t\n\t\t// Notify the Quest Engine of the L2Attackable death if necessary\n\t\ttry\n\t\t{\n\t\t\tif (killer instanceof L2PcInstance || killer instanceof L2Summon)\n\t\t\t{\n\t\t\t\tfinal L2PcInstance player = killer instanceof L2PcInstance ? (L2PcInstance) killer : ((L2Summon) killer).getOwner();\n\t\t\t\t\n\t\t\t\tEngineModsManager.onKill(killer, this, killer instanceof L2Summon);\n\t\t\t\t\n\t\t\t\t// only 1 randomly choosen quest of all quests registered to this character can be applied\n\t\t\t\tfor (final Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_KILL))\n\t\t\t\t{\n\t\t\t\t\tquest.notifyKill(this, player, killer instanceof L2Summon);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t\t\n\t\tsetChampion(false);\n\t\tif (Config.L2JMOD_CHAMPION_ENABLE && Config.L2JMOD_CHAMPION_FREQUENCY > 0)\n\t\t{\n\t\t\t// Set champion on next spawn\n\t\t\tif (this.getClass().getSimpleName().equalsIgnoreCase(\"L2MonsterInstance\") && getLevel() >= Config.L2JMOD_CHAMP_MIN_LVL && getLevel() <= Config.L2JMOD_CHAMP_MAX_LVL)\n\t\t\t{\n\t\t\t\tint random = ThreadLocalRandom.current().nextInt(100);\n\t\t\t\tif (random < Config.L2JMOD_CHAMPION_FREQUENCY)\n\t\t\t\t{\n\t\t\t\t\tsetChampion(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn true;\n\t}", "private void functionalInterface2() {\n\t\tPokedex.printData(Arrays.asList(charmander));\n\n\t\tguilherme.powerUp(charmander, new BigDecimal(\"-10\"), psRestoreHp // 100\n\t\t\t\t.and(psMinimalDamage) // -10\n\t\t\t\t.and(psIncreaseHp) // +25\n\t\t\t\t.and(psMinimalDamage) // -10\n\t\t\t\t.and(psHugeDamage) // -20\n\t\t);\n\n\t\tPokedex.printData(Arrays.asList(charmander));\n\t}", "private int[] calculateExpAndSp(int diff, final int damage)\n\t{\n\t\tdouble xp;\n\t\tdouble sp;\n\t\t\n\t\tif (diff < -5)\n\t\t{\n\t\t\tdiff = -5; // makes possible to use ALT_GAME_EXPONENT configuration\n\t\t}\n\t\t\n\t\txp = (double) getExpReward() * damage / getMaxHp();\n\t\t\n\t\tif (Config.ALT_GAME_EXPONENT_XP != 0)\n\t\t{\n\t\t\txp *= Math.pow(2., -diff / Config.ALT_GAME_EXPONENT_XP);\n\t\t}\n\t\t\n\t\tsp = (double) getSpReward() * damage / getMaxHp();\n\t\t\n\t\tif (Config.ALT_GAME_EXPONENT_SP != 0)\n\t\t{\n\t\t\tsp *= Math.pow(2., -diff / Config.ALT_GAME_EXPONENT_SP);\n\t\t}\n\t\t\n\t\tif (Config.ALT_GAME_EXPONENT_XP == 0 && Config.ALT_GAME_EXPONENT_SP == 0)\n\t\t{\n\t\t\tif (diff > 5) // formula revised May 07\n\t\t\t{\n\t\t\t\tfinal double pow = Math.pow((double) 5 / 6, diff - 5);\n\t\t\t\txp = xp * pow;\n\t\t\t\tsp = sp * pow;\n\t\t\t}\n\t\t\t\n\t\t\tif (xp <= 0)\n\t\t\t{\n\t\t\t\txp = 0;\n\t\t\t\tsp = 0;\n\t\t\t}\n\t\t\telse if (sp <= 0)\n\t\t\t{\n\t\t\t\tsp = 0;\n\t\t\t}\n\t\t}\n\t\t\n\t\tfinal int[] tmp =\n\t\t{\n\t\t\t(int) xp,\n\t\t\t(int) sp\n\t\t};\n\t\t\n\t\treturn tmp;\n\t}", "public abstract int doDamage(int time, GenericMovableUnit unit, Unit target);", "public void gainExpHonors(int exp){\r\n\t\tSystem.out.println(this.getName() + \"'s XP: \" + this.getExperiencePoints() + \" ---> \" + (this.getExperiencePoints()+exp));\r\n\r\n\t\t//this.experiencePoints += exp;\r\n\t\t\t//parameters 1 == count, 0 is being used as the xp start point to evaluate\r\n\t\t\t//the intervals in the helper method\r\n\t\twhile(exp >= calcLevel(1,0)){\r\n\t\t\t//System.out.println(calcLevel(1,0));\r\n\t\t\tthis.experiencePoints = calcLevel(1,0);\r\n\t\t\t//System.out.println(this.getExperiencePoints());\r\n\t\t\tthis.levelUp();\r\n\t\t}\r\n\t\t\r\n\t\tthis.experiencePoints += (exp-this.experiencePoints);\r\n\t}", "public int giveDamage();", "@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)\r\n public void onPlayerDamagedByPlayer(final EntityDamageByEntityEvent event) {\n if (!(event.getEntity() instanceof Player)) {\r\n return;\r\n }\r\n if (!(event.getDamager() instanceof Player)) {\r\n return;\r\n }\r\n \r\n final Player target = (Player)event.getEntity();\r\n final Player attacker = (Player)event.getDamager();\r\n final ItemStack is = attacker.getItemInHand();\r\n \r\n if (is != null){\r\n switch (is.getType()){\r\n case EMERALD:\r\n attacker.setItemInHand(ItemUtil.decrementItem(is, 1));\r\n \r\n // 体力・空腹回復、燃えてたら消化\r\n target.setHealth(target.getMaxHealth());\r\n target.setFoodLevel(20);\r\n target.setFireTicks(0);\r\n \r\n // ポーション効果付与\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.REGENERATION, 45 * 20, 0)); // 45 secs\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.FIRE_RESISTANCE, 7 * 60 * 20, 0)); // 7 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.INCREASE_DAMAGE, 9 * 60 * 20, 1)); // 9 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.SPEED, 9 * 60 * 20, 0)); // 9 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.FAST_DIGGING, 5 * 60 * 20, 1)); // 5 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.NIGHT_VISION, 3 * 60 * 20, 0)); // 3 mins\r\n \r\n // effect, messaging\r\n target.getWorld().playEffect(target.getLocation(), Effect.ENDER_SIGNAL, 0, 10);\r\n Util.message(target, PlayerManager.getPlayer(attacker).getName() + \" &aから特殊効果を与えられました!\");\r\n Util.message(attacker, PlayerManager.getPlayer(target).getName() + \" &aに特殊効果を与えました!\");\r\n \r\n event.setCancelled(true);\r\n event.setDamage(0);\r\n break;\r\n default: break;\r\n }\r\n }\r\n }", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker)\n\t{\n\t\treduceCurrentHp(damage, attacker, true);\n\t}", "private void updatePlayerClaim(){\n if(chestProgressLevel!=1){\n return; //the chest isnt unlocked!\n }\n\n //count the total players, and the players who unlocked it.\n int totalPlayers = 0;\n int unlockedPlayers = 0;\n for(JuggernautPlayer player: JuggernautGame.getInstance().getPlayers()){\n if(!player.isSurvivor() || !player.isAlive()){\n continue; //they be dead, they dont count! (Juggy also doesnt count, he doesnt get to unlock items)\n }\n totalPlayers++; //+1 total players\n if(player.isSurvivor() && player.getChestBonus(chestID)>=level){\n unlockedPlayers++; //they unlocked it, +1 unlocked players\n }\n }\n\n //all players unlocked it\n if(totalPlayers<=unlockedPlayers && chestProgressLevel==1){\n //lock the chest before respawning.\n lockChest();\n new BukkitRunnable() {\n\n int timeTillRespawn = 3; //3 seconds to respawn a chest\n @Override\n public void run() {\n //runs every second\n for(JuggernautPlayer jp : JuggernautGame.getInstance().getAllPeople()){\n //check if the player is in the radius of the chest (ignore Y)\n if(SkyMathHelper.isInRadius(location, jp.getPlayer().getLocation(), nametagRadius, false)) {\n //show them the hologram. Update if they already have the hologram active.\n //If this chest will not respawn, we tell them \"Good Luck!\" instead of the respawning message.\n if (jp.getLoadedEntities().containsKey(armorstandResetChestID)) {\n if(level==getMaxLevel()){\n jp.updateHologram(armorstandResetChestID, \"\\u00A76Good Luck!\");\n }else {\n jp.updateHologram(armorstandResetChestID, \"\\u00A76Respawning in \" + timeTillRespawn);\n }\n } else {\n if(level==getMaxLevel()) {\n jp.displayHologram(location.getX(), location.getY() + armorstandProgressbarHeight, location.getZ(), \"\\u00A76Good Luck!\", armorstandResetChestID);\n }else{\n jp.displayHologram(location.getX(), location.getY() + armorstandProgressbarHeight, location.getZ(), \"\\u00A76Respawning in \" + timeTillRespawn, armorstandResetChestID);\n }\n }\n }else{\n //they arent in range, so we remove this entity for them\n jp.removeEntities(armorstandResetChestID);\n }\n }\n\n //check if its time to respawn.\n if(timeTillRespawn--<=0){\n //its time! respawn the chest!\n respawnChest();\n for(JuggernautPlayer jp: JuggernautGame.getInstance().getPlayers()){\n //remove the countdown armorstand for all players\n jp.removeEntities(armorstandResetChestID);\n }\n this.cancel(); //cancel this runnable, we no longer need it.\n return;\n }\n }\n }.runTaskTimer(Juggernaut.pluginInstance, 0L, 20L); //every 20 ticks (1s)\n }else{\n //not all players unlocked the item yet. Lets indicate how many did.\n String emptyDisplayText = unlockedPlayers + \"/\" + totalPlayers + \" Claimed\";\n for(JuggernautPlayer JP: JuggernautGame.getInstance().getPlayers()){\n if(!SkyMathHelper.isInRadius(location, JP.getPlayer().getLocation(), nametagRadius, false)){\n //they arent in the radius, so we remove their armorstand again (if they had it).\n if(JP.getLoadedEntities().containsKey(this.armorstandClaimProgressID)) {\n JP.removeEntities(armorstandClaimProgressID);\n }\n continue;\n }\n\n //generate the color of the display text we need to show them. green if they claimed it, otherwise red.\n String displayText;\n if(JP.getChestBonus(chestID)>=level){\n displayText = \"\\u00A72\" + emptyDisplayText;\n }else{\n displayText = \"\\u00A7c\" + emptyDisplayText;\n }\n\n //update, or show the hologram to them.\n if(JP.getLoadedEntities().containsKey(this.armorstandClaimProgressID)){\n JP.updateHologram(armorstandClaimProgressID, displayText);\n }else{\n JP.displayHologram(this.location.getX(), this.location.getY()+this.armorstandClaimProgressHeight, this.location.getZ(), displayText, armorstandClaimProgressID);\n }\n }\n }\n }", "public void attack(User p)\n\t{\n\t\tint damage = getAttack() - p.getDefense();\n\t\tint evade = 0;\n\t\tif(damage <= 0)\n\t\t{\n\t\t\tevade = p.getDefense() - getAttack();\n\t\t\tdamage = 1;\n\t\t}\n\t\t\n\t\tif(Math.random() * 100 < evade * 5)\n\t\t{\n\t\t\tJOptionPane.showMessageDialog(null, \"Miss\");\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tp.reduce(damage);\n JOptionPane.showMessageDialog(null,\"Enemy attacked you! User's health = \" + p.getHealth() + \"\\n\" + \"Damage dealt = \" + damage); \n\t}", "void givePlayerExp(BPlayer bPlayer, int exp);", "public void takeDamage()\n {\n if(getWorld()!= null)\n {\n if(this.isTouching(Enemies.class))\n {\n Life = Life - Enemies.damage;\n if(Life <=0)\n {\n getWorld().removeObject(this);\n Store.wealth += Game.credit;\n }\n }\n }\n }", "public void attackEntity(Entity entityToHit) {\n ItemStack item = tinkerProjectile.getItemStack();\n ItemStack launcher = tinkerProjectile.getLaunchingStack();\n\n // deal damage if we have everything\n if(item.getItem() instanceof ToolCore && this.attacker != null) {\n EntityLivingBase attacker = (EntityLivingBase) this.attacker;\n //EntityLivingBase target = (EntityLivingBase) raytraceResult.entityHit;\n\n // find the actual itemstack in the players inventory\n ItemStack inventoryItem = AmmoHelper.getMatchingItemstackFromInventory(tinkerProjectile.getItemStack(), attacker, false);\n if(inventoryItem.isEmpty() || inventoryItem.getItem() != item.getItem()) {\n // backup, use saved itemstack\n inventoryItem = item;\n }\n\n // for the sake of dealing damage we always ensure that the impact itemstack has the correct broken state\n // since the ammo stack can break while the arrow travels/if it's the last arrow\n boolean brokenStateDiffers = ToolHelper.isBroken(inventoryItem) != ToolHelper.isBroken(item);\n if(brokenStateDiffers) {\n toggleBroken(inventoryItem);\n }\n\n Multimap<String, AttributeModifier> projectileAttributes = null;\n // remove stats from held items\n if(!world.isRemote) {\n unequip(attacker, EntityEquipmentSlot.OFFHAND);\n unequip(attacker, EntityEquipmentSlot.MAINHAND);\n\n // apply stats from projectile\n if(item.getItem() instanceof IProjectile) {\n projectileAttributes = ((IProjectile) item.getItem()).getProjectileAttributeModifier(inventoryItem);\n\n if(launcher.getItem() instanceof ILauncher) {\n ((ILauncher) launcher.getItem()).modifyProjectileAttributes(projectileAttributes, tinkerProjectile.getLaunchingStack(), tinkerProjectile.getItemStack(), tinkerProjectile.getPower());\n }\n\n // factor in power\n projectileAttributes.put(SharedMonsterAttributes.ATTACK_DAMAGE.getName(),\n new AttributeModifier(PROJECTILE_POWER_MODIFIER, \"Weapon damage multiplier\", tinkerProjectile.getPower() - 1f, 2));\n\n attacker.getAttributeMap().applyAttributeModifiers(projectileAttributes);\n }\n // deal the damage\n// ToolHelper.attackEntity(item, (ToolCore) item.getItem(), attacker, entityToHit, null);\n// float speed = MathHelper.sqrt(this.motionX * this.motionX + this.motionY * this.motionY + this.motionZ * this.motionZ);\n\n boolean attack = ToolHelper.attackEntity(item, (ToolCore) item.getItem(), attacker, entityToHit, null);\n// if(attack) {\n//// for(IProjectileTrait trait : tinkerProjectile.getProjectileTraits()) {\n//// trait.afterHit(tinkerProjectile.get, this.world, inventoryItem, attacker, entityToHit, (double) 0.0);\n//// }\n//\n// // if on fire, set the entity on fire, like vanilla arrows\n//// if (this.isBurning() && !(entityToHit instanceof EntityEnderman)) {\n//// entityToHit.setFire(5);\n//// }\n// }\n if(brokenStateDiffers) {\n toggleBroken(inventoryItem);\n }\n\n // remove stats from projectile\n // apply stats from projectile\n if(item.getItem() instanceof IProjectile) {\n assert projectileAttributes != null;\n attacker.getAttributeMap().removeAttributeModifiers(projectileAttributes);\n }\n\n // readd stats from held items\n equip(attacker, EntityEquipmentSlot.MAINHAND);\n equip(attacker, EntityEquipmentSlot.OFFHAND);\n }\n }else {\n System.out.println(\"something failed with attacking.\");\n }\n }", "void takeDamage(HeroDamage enemy1, HeroDamage enemy2);", "public void doItemDrop(final L2NpcTemplate npcTemplate, final L2Character lastAttacker)\n\t{\n\t\tL2PcInstance player = null;\n\t\t\n\t\tif (lastAttacker instanceof L2PcInstance)\n\t\t{\n\t\t\tplayer = (L2PcInstance) lastAttacker;\n\t\t}\n\t\telse if (lastAttacker instanceof L2Summon)\n\t\t{\n\t\t\tplayer = ((L2Summon) lastAttacker).getOwner();\n\t\t}\n\t\t\n\t\t// Don't drop anything if the last attacker or ownere isn't L2PcInstance\n\t\tif (player == null)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tif (EngineModsManager.onNpcDrop(this, lastAttacker))\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tfinal int levelModifier = calculateLevelModifierForDrop(player); // level modifier in %'s (will be subtracted from drop chance)\n\t\t\n\t\t// Check the drop of a cursed weapon\n\t\tif (levelModifier == 0 && player.getLevel() > 20)\n\t\t{\n\t\t\tCursedWeaponsManager.getInstance().checkDrop(this, player);\n\t\t}\n\t\t\n\t\t// now throw all categorized drops and handle spoil.\n\t\tfor (final L2DropCategory cat : npcTemplate.getDropData())\n\t\t{\n\t\t\tRewardItem item = null;\n\t\t\tif (cat.isSweep())\n\t\t\t{\n\t\t\t\t// according to sh1ny, seeded mobs CAN be spoiled and swept.\n\t\t\t\tif (isSpoil()/* && !isSeeded() */)\n\t\t\t\t{\n\t\t\t\t\tList<RewardItem> sweepList = new ArrayList<>();\n\t\t\t\t\t\n\t\t\t\t\tfor (final L2DropData drop : cat.getAllDrops())\n\t\t\t\t\t{\n\t\t\t\t\t\titem = calculateRewardItem(player, drop, levelModifier, true);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (item == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.DEBUG)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tLOGGER.debug(\"Item id to spoil: \" + item.getItemId() + \" amount: \" + item.getCount());\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tsweepList.add(item);\n\t\t\t\t\t\t\n\t\t\t\t\t\titem = null;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Set the table sweepItems of this L2Attackable\n\t\t\t\t\tif (!sweepList.isEmpty())\n\t\t\t\t\t{\n\t\t\t\t\t\tsweepItems = sweepList.toArray(new RewardItem[sweepList.size()]);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tsweepList = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tif (isSeeded())\n\t\t\t\t{\n\t\t\t\t\tL2DropData drop = cat.dropSeedAllowedDropsOnly();\n\t\t\t\t\t\n\t\t\t\t\tif (drop == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = calculateRewardItem(player, drop, levelModifier, false);\n\t\t\t\t\tdrop = null;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\titem = calculateCategorizedRewardItem(player, cat, levelModifier);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (item != null)\n\t\t\t\t{\n\t\t\t\t\tif (Config.DEBUG)\n\t\t\t\t\t{\n\t\t\t\t\t\tLOGGER.debug(\"Item id to drop: \" + item.getItemId() + \" amount: \" + item.getCount());\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Check if the autoLoot mode is active\n\t\t\t\t\tif (Config.AUTO_LOOT)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (item_templ == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tLOGGER.info(\"ERROR: Item id to autoloot \" + item.getItemId() + \" has not template into items/armor/weapon tables.. It cannot be dropped..\");\n\t\t\t\t\t\t\t// DropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ) || !Config.AUTO_LOOT_BOSS && this instanceof L2RaidBossInstance || !Config.AUTO_LOOT_BOSS && this instanceof L2GrandBossInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.doAutoLoot(this, item); // Give this or these Item(s) to the L2PcInstance that has killed the L2Attackable\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item); // drop the item on the ground\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Broadcast message if RaidBoss was defeated\n\t\t\t\t\tif (this instanceof L2RaidBossInstance || this instanceof L2GrandBossInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tSystemMessage sm;\n\t\t\t\t\t\tsm = new SystemMessage(SystemMessageId.S1_DIED_DROPPED_S3_S2);\n\t\t\t\t\t\tsm.addString(getName());\n\t\t\t\t\t\tsm.addItemName(item.getItemId());\n\t\t\t\t\t\tsm.addNumber(item.getCount());\n\t\t\t\t\t\tbroadcastPacket(sm);\n\t\t\t\t\t\tsm = null;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\titem = null;\n\t\t}\n\t\t\n\t\t// Apply Special Item drop with rnd qty for champions\n\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion() && player.getLevel() <= getLevel() + 3 && Config.L2JMOD_CHAMPION_REWARD > 0 && Rnd.get(100) < Config.L2JMOD_CHAMPION_REWARD)\n\t\t{\n\t\t\tint champqty = Rnd.get(Config.L2JMOD_CHAMPION_REWARD_QTY);\n\t\t\tchampqty++; // quantity should actually vary between 1 and whatever admin specified as max, inclusive.\n\t\t\t\n\t\t\tRewardItem item = new RewardItem(Config.L2JMOD_CHAMPION_REWARD_ID, champqty);\n\t\t\t\n\t\t\t// Give this or these Item(s) to the L2PcInstance that has killed the L2Attackable\n\t\t\tif (Config.AUTO_LOOT)\n\t\t\t{\n\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\n\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tplayer.addItem(\"ChampionLoot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tDropItem(player, item);\n\t\t\t}\n\t\t\t\n\t\t\titem = null;\n\t\t}\n\t\t\n\t\t// Instant Item Drop :>\n\t\tfinal double rateHp = getStat().calcStat(Stats.MAX_HP, 1, this, null);\n\t\t\n\t\tif (rateHp < 2 && String.valueOf(npcTemplate.type).contentEquals(\"L2Monster\")) // only L2Monster with <= 1x HP can drop herbs\n\t\t{\n\t\t\tboolean hp = false;\n\t\t\tboolean mp = false;\n\t\t\tboolean spec = false;\n\t\t\t\n\t\t\t// ptk - patk type enhance\n\t\t\tint random = Rnd.get(1000); // note *10\n\t\t\t\n\t\t\tif (random < Config.RATE_DROP_SPECIAL_HERBS && !spec) // && !_spec useless yet\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(8612, 1); // Herb of Warrior\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t\tspec = true;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tfor (int i = 0; i < 3; i++)\n\t\t\t\t{\n\t\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\t\n\t\t\t\t\tif (random < Config.RATE_DROP_COMMON_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tRewardItem item = null;\n\t\t\t\t\t\tif (i == 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8606, 1); // Herb of Power\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (i == 1)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8608, 1); // Herb of Atk. Spd.\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (i == 2)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8610, 1); // Herb of Critical Attack\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (item == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// mtk - matk type enhance\n\t\t\trandom = Rnd.get(1000); // note *10\n\t\t\t\n\t\t\tif (random < Config.RATE_DROP_SPECIAL_HERBS && !spec)\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(8613, 1); // Herb of Mystic\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t\tspec = true;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tfor (int i = 0; i < 2; i++)\n\t\t\t\t{\n\t\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\t\n\t\t\t\t\tif (random < Config.RATE_DROP_COMMON_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tRewardItem item = null;\n\t\t\t\t\t\tif (i == 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8607, 1); // Herb of Magic\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (i == 1)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8609, 1); // Herb of Casting Speed\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (item == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// hp+mp type\n\t\t\trandom = Rnd.get(1000); // note *10\n\t\t\t\n\t\t\tif (random < Config.RATE_DROP_SPECIAL_HERBS && !spec)\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(8614, 1); // Herb of Recovery\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t\tmp = true;\n\t\t\t\thp = true;\n\t\t\t\tspec = true;\n\t\t\t}\n\t\t\t\n\t\t\t// hp - restore hp type\n\t\t\tif (!hp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(100);\n\t\t\t\tif (random < Config.RATE_DROP_MP_HP_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8600, 1); // Herb of Life\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t\thp = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!hp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_GREATER_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8601, 1); // Greater Herb of Life\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t\thp = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!hp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(1000); // note *10\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_SUPERIOR_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8602, 1); // Superior Herb of Life\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// mp - restore mp type\n\t\t\tif (!mp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_MP_HP_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8603, 1); // Herb of Mana\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t\tmp = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!mp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_GREATER_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8604, 1); // Greater Herb of Mana\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t\tmp = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!mp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(1000); // note *10\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_SUPERIOR_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8605, 1); // Superior Herb of Mana\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// speed enhance type\n\t\t\trandom = Rnd.get(100);\n\t\t\t\n\t\t\tif (random < Config.RATE_DROP_COMMON_HERBS)\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(8611, 1); // Herb of Speed\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t}\n\t\t}\n\t}", "@Override\n public void use(AbstractPlayer p, AbstractMonster m) {\n //give player plated armor\n AbstractDungeon.actionManager.addToBottom( // 2.Gain plated armor\n new com.megacrit.cardcrawl.actions.common.ApplyPowerAction(AbstractDungeon.player, AbstractDungeon.player,\n new com.megacrit.cardcrawl.powers.PlatedArmorPower(AbstractDungeon.player, 3), 3));\n }", "private static int experienceTally(int playerExperience, int monsterExperience){\r\n int totalExperience;\r\n totalExperience = playerExperience + monsterExperience;\r\n return totalExperience;\r\n }", "private WeightedSampler<String> getPossibleLethalActions(int team) {\n if (this.b.getCurrentPlayerTurn() != team || this.b.getWinner() != 0) {\n return null;\n }\n Player p = this.b.getPlayer(team);\n WeightedSampler<String> poss = new WeightedOrderedSampler<>();\n List<Minion> minions = this.b.getMinions(team, false, true).collect(Collectors.toList());\n for (Minion m : minions) {\n if (p.canUnleashCard(m)) {\n double totalWeight = UNLEASH_TOTAL_WEIGHT + UNLEASH_WEIGHT_PER_PRESENCE * m.getTotalEffectValueOf(e -> e.getPresenceValue(5));\n List<List<List<TargetList<?>>>> targetSearchSpace = new LinkedList<>();\n this.getPossibleListTargets(m.getUnleashTargetingSchemes(), new LinkedList<>(), targetSearchSpace);\n if (targetSearchSpace.isEmpty()) {\n targetSearchSpace.add(List.of());\n }\n for (List<List<TargetList<?>>> targets : targetSearchSpace) {\n poss.add(new UnleashMinionAction(p, m, targets).toString().intern(), totalWeight / targetSearchSpace.size());\n }\n }\n }\n if (this.b.getMinions(team * -1, false, true).anyMatch(m -> m.finalStats.get(Stat.WARD) > 0)) {\n // find ways to break through the wards\n for (Minion m : minions) {\n if (m.canAttack()) {\n double totalWeight = ATTACK_TOTAL_WEIGHT + ATTACK_WEIGHT_MULTIPLIER * m.finalStats.get(Stat.ATTACK);\n List<Minion> searchSpace = m.getAttackableTargets().collect(Collectors.toList());\n double weight = totalWeight / searchSpace.size();\n for (Minion target : searchSpace) {\n double overkillMultiplier = Math.pow(ATTACK_WEIGHT_OVERKILL_PENALTY, Math.max(0, m.finalStats.get(Stat.ATTACK) - target.health));\n poss.add(new OrderAttackAction(m, target).toString().intern(), overkillMultiplier * weight);\n }\n }\n }\n } else {\n // just go face\n this.b.getPlayer(team * -1).getLeader().ifPresent(l -> {\n for (Minion m : minions) {\n if (m.canAttack(l)) {\n double totalWeight = ATTACK_TOTAL_WEIGHT + ATTACK_WEIGHT_MULTIPLIER * m.finalStats.get(Stat.ATTACK);\n poss.add(new OrderAttackAction(m, l).toString().intern(), totalWeight);\n }\n }\n });\n }\n poss.add(new EndTurnAction(team).toString().intern(), END_TURN_WEIGHT);\n return poss;\n }", "@Deprecated\n/* */ protected static boolean performAttack(int pos, boolean aiming, Creature performer, Skills performerSkills, Item attWeapon, Item target, double attBonus, Skill attackerFightSkill, int counter) {\n/* 3189 */ if (!performer.hasLink())\n/* 3190 */ return true; \n/* 3191 */ boolean done = false;\n/* 3192 */ Skill primWeaponSkill = null;\n/* 3193 */ int skillnum = -10;\n/* 3194 */ performer.getStatus().modifyStamina(-1000.0F);\n/* 3195 */ if (attWeapon != null) {\n/* */ \n/* */ try {\n/* */ \n/* 3199 */ skillnum = attWeapon.getPrimarySkill();\n/* 3200 */ primWeaponSkill = performerSkills.getSkill(skillnum);\n/* */ }\n/* 3202 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 3204 */ if (skillnum != -10) {\n/* 3205 */ primWeaponSkill = performerSkills.learn(skillnum, 1.0F);\n/* */ }\n/* */ } \n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ try {\n/* 3215 */ Skill attStrengthSkill = performerSkills.getSkill(102);\n/* */ }\n/* 3217 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 3219 */ Skill attStrengthSkill = performerSkills.learn(102, 1.0F);\n/* 3220 */ logger.log(Level.WARNING, performer.getName() + \" had no strength. Weird.\");\n/* */ } \n/* */ \n/* 3223 */ double bonus = 0.0D;\n/* 3224 */ if (primWeaponSkill != null) {\n/* */ \n/* 3226 */ boolean dryrun = (primWeaponSkill.getKnowledge(0.0D) >= 20.0D);\n/* 3227 */ bonus = Math.max(0.0D, primWeaponSkill\n/* */ \n/* 3229 */ .skillCheck((attWeapon.getCurrentQualityLevel() + 10.0F), attBonus, dryrun, \n/* 3230 */ Math.max(1, counter / 2)));\n/* */ } \n/* */ \n/* 3233 */ if (aiming) {\n/* */ \n/* 3235 */ int rand = 10;\n/* 3236 */ if (pos == 1) {\n/* */ \n/* 3238 */ rand = Server.rand.nextInt(100);\n/* 3239 */ bonus = -60.0D;\n/* 3240 */ if (rand < 50) {\n/* 3241 */ pos = 17;\n/* */ }\n/* 3243 */ } else if (pos == 29) {\n/* */ \n/* 3245 */ rand = Server.rand.nextInt(100);\n/* 3246 */ bonus = -80.0D;\n/* 3247 */ if (rand < 98) {\n/* 3248 */ pos = 29;\n/* 3249 */ } else if (rand < 99) {\n/* 3250 */ pos = 18;\n/* 3251 */ } else if (rand < 100) {\n/* 3252 */ pos = 19;\n/* */ } \n/* 3254 */ } else if (pos == 2) {\n/* */ \n/* 3256 */ rand = Server.rand.nextInt(20);\n/* 3257 */ bonus = -40.0D;\n/* 3258 */ if (rand < 5) {\n/* 3259 */ pos = 21;\n/* 3260 */ } else if (rand < 7) {\n/* 3261 */ pos = 27;\n/* 3262 */ } else if (rand < 9) {\n/* 3263 */ pos = 26;\n/* 3264 */ } else if (rand < 12) {\n/* 3265 */ pos = 32;\n/* 3266 */ } else if (rand < 14) {\n/* 3267 */ pos = 23;\n/* 3268 */ } else if (rand < 18) {\n/* 3269 */ pos = 24;\n/* 3270 */ } else if (rand < 20) {\n/* 3271 */ pos = 25;\n/* */ } \n/* 3273 */ } else if (pos == 3) {\n/* */ \n/* 3275 */ rand = Server.rand.nextInt(10);\n/* 3276 */ bonus = -30.0D;\n/* 3277 */ if (rand < 5) {\n/* 3278 */ pos = 5;\n/* 3279 */ } else if (rand < 9) {\n/* 3280 */ pos = 9;\n/* */ } else {\n/* 3282 */ pos = 13;\n/* */ } \n/* 3284 */ } else if (pos == 4) {\n/* */ \n/* 3286 */ rand = Server.rand.nextInt(10);\n/* 3287 */ bonus = -30.0D;\n/* 3288 */ if (rand < 5) {\n/* 3289 */ pos = 6;\n/* 3290 */ } else if (rand < 9) {\n/* 3291 */ pos = 10;\n/* */ } else {\n/* 3293 */ pos = 14;\n/* */ } \n/* 3295 */ } else if (pos == 34) {\n/* */ \n/* 3297 */ rand = Server.rand.nextInt(20);\n/* 3298 */ bonus = -30.0D;\n/* 3299 */ if (rand < 5) {\n/* 3300 */ pos = 7;\n/* 3301 */ } else if (rand < 9) {\n/* 3302 */ pos = 11;\n/* 3303 */ } else if (rand < 10) {\n/* 3304 */ pos = 15;\n/* 3305 */ } if (rand < 15) {\n/* 3306 */ pos = 8;\n/* 3307 */ } else if (rand < 19) {\n/* 3308 */ pos = 12;\n/* */ } else {\n/* 3310 */ pos = 16;\n/* */ } \n/* */ } \n/* */ } else {\n/* */ \n/* */ \n/* */ try {\n/* 3317 */ pos = PracticeDollBehaviour.getRandomWoundPos();\n/* */ }\n/* 3319 */ catch (Exception ex) {\n/* */ \n/* 3321 */ logger.log(Level.WARNING, \"Could not get random wound position on \" + target\n/* 3322 */ .getName() + \" due to \" + ex.getMessage(), ex);\n/* */ } \n/* */ } \n/* 3325 */ double attCheck = 0.0D;\n/* */ \n/* */ \n/* 3328 */ if (primWeaponSkill != null) {\n/* */ \n/* 3330 */ boolean dryrun = (attackerFightSkill.getKnowledge(0.0D) >= 20.0D);\n/* 3331 */ attCheck = attackerFightSkill.skillCheck(10.0D, attWeapon, bonus, dryrun, Math.max(1, counter / 2));\n/* */ } else {\n/* */ \n/* 3334 */ attCheck = attackerFightSkill.skillCheck(10.0D, attWeapon, bonus, true, Math.max(1, counter));\n/* 3335 */ } String attString = getAttackString(performer, attWeapon);\n/* 3336 */ if (attCheck > 0.0D) {\n/* */ \n/* */ \n/* */ \n/* 3340 */ double damage = Math.max(0.1F, Server.rand.nextFloat() * Weapon.getBaseDamageForWeapon(attWeapon) / 10.0F);\n/* */ \n/* */ \n/* */ \n/* 3344 */ if (primWeaponSkill != null) {\n/* 3345 */ attWeapon.setDamage(attWeapon.getDamage() + 0.05F * Weapon.getBaseDamageForWeapon(attWeapon));\n/* */ }\n/* */ \n/* */ \n/* 3349 */ String broadCastString = performer.getNameWithGenus() + \" \" + attString + \"s \" + target.getNameWithGenus() + \" \" + getStrengthString(damage) + \" in the \" + PracticeDollBehaviour.getWoundLocationString(pos) + \".\";\n/* */ \n/* 3351 */ performer.getCommunicator().sendSafeServerMessage(\"You \" + attString + \" \" + target\n/* 3352 */ .getNameWithGenus() + \" \" + getStrengthString(damage) + \" in the \" + \n/* 3353 */ PracticeDollBehaviour.getWoundLocationString(pos) + \".\");\n/* 3354 */ Server.getInstance().broadCastAction(broadCastString, performer, 3);\n/* */ \n/* 3356 */ done = target.setDamage(target.getDamage() + (float)damage * target.getDamageModifier());\n/* */ \n/* 3358 */ int tilex = (int)target.getPosX() >> 2;\n/* 3359 */ int tiley = (int)target.getPosY() >> 2;\n/* */ \n/* 3361 */ String sstring = \"sound.combat.parry1\";\n/* 3362 */ int x = Server.rand.nextInt(3);\n/* 3363 */ if (x == 0) {\n/* 3364 */ sstring = \"sound.combat.parry2\";\n/* 3365 */ } else if (x == 1) {\n/* 3366 */ sstring = \"sound.combat.parry3\";\n/* 3367 */ } SoundPlayer.playSound(sstring, target, 1.6F);\n/* 3368 */ performer.playAnimation(\"practice_cut\", false, target.getWurmId());\n/* 3369 */ if (done)\n/* */ {\n/* 3371 */ broadCastString = target.getNameWithGenus() + \" is no more.\";\n/* 3372 */ Server.getInstance().broadCastMessage(broadCastString, tilex, tiley, performer.isOnSurface(), 3);\n/* */ }\n/* */ \n/* */ } else {\n/* */ \n/* 3377 */ String sstring = \"sound.combat.miss.light\";\n/* 3378 */ if (attCheck < -80.0D) {\n/* 3379 */ sstring = \"sound.combat.miss.heavy\";\n/* 3380 */ } else if (attCheck < -40.0D) {\n/* 3381 */ sstring = \"sound.combat.miss.med\";\n/* 3382 */ } SoundPlayer.playSound(sstring, target, 1.6F);\n/* 3383 */ if (performer.spamMode()) {\n/* */ \n/* 3385 */ if (aiming) {\n/* 3386 */ performer.getCommunicator().sendNormalServerMessage(\"You miss.\");\n/* */ } else {\n/* 3388 */ performer.getCommunicator().sendNormalServerMessage(\"You try to \" + attString + \" \" + target\n/* 3389 */ .getNameWithGenus() + \" in the \" + \n/* 3390 */ PracticeDollBehaviour.getWoundLocationString(pos) + \" but \" + \n/* 3391 */ getMissString(true, attCheck));\n/* */ } \n/* 3393 */ } else if (aiming) {\n/* 3394 */ performer.getCommunicator().sendNormalServerMessage(\"You miss.\");\n/* */ } \n/* */ } \n/* 3397 */ return done;\n/* */ }", "void takeDamage(int points) {\n this.health -= points;\n }", "public int computeDamageTo(Combatant opponent) { return 0; }", "private void levelSoulCrystals(final L2Character attacker)\n\t{\n\t\t// Only L2PcInstance can absorb a soul\n\t\tif (!(attacker instanceof L2PcInstance) && !(attacker instanceof L2Summon))\n\t\t{\n\t\t\tresetAbsorbList();\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tfinal int maxAbsorbLevel = getAbsorbLevel();\n\t\tint minAbsorbLevel = 0;\n\t\t\n\t\t// If this is not a valid L2Attackable, clears the absorbersList and just return\n\t\tif (maxAbsorbLevel == 0)\n\t\t{\n\t\t\tresetAbsorbList();\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// All boss mobs with maxAbsorbLevel 13 have minAbsorbLevel of 12 else 10\n\t\tif (maxAbsorbLevel > 10)\n\t\t{\n\t\t\tminAbsorbLevel = maxAbsorbLevel > 12 ? 12 : 10;\n\t\t}\n\t\t\n\t\t// Init some useful vars\n\t\tboolean isSuccess = true;\n\t\tboolean doLevelup = true;\n\t\tfinal boolean isBossMob = maxAbsorbLevel > 10 ? true : false;\n\t\t\n\t\tfinal L2NpcTemplate.AbsorbCrystalType absorbType = getTemplate().absorbType;\n\t\t\n\t\tL2PcInstance killer = attacker instanceof L2Summon ? ((L2Summon) attacker).getOwner() : (L2PcInstance) attacker;\n\t\t\n\t\t// If this mob is a boss, then skip some checkings\n\t\tif (!isBossMob)\n\t\t{\n\t\t\t// Fail if this L2Attackable isn't absorbed or there's no one in its absorbersList\n\t\t\tif (!isAbsorbed() /* || absorbersList == null */)\n\t\t\t{\n\t\t\t\tresetAbsorbList();\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\t// Fail if the killer isn't in the absorbersList of this L2Attackable and mob is not boss\n\t\t\tAbsorberInfo ai = absorbersList.get(killer);\n\t\t\tif (ai == null || ai.absorber.getObjectId() != killer.getObjectId())\n\t\t\t{\n\t\t\t\tisSuccess = false;\n\t\t\t}\n\t\t\t\n\t\t\t// Check if the soul crystal was used when HP of this L2Attackable wasn't higher than half of it\n\t\t\tif (ai != null && ai.absorbedHP > getMaxHp() / 2.0)\n\t\t\t{\n\t\t\t\tisSuccess = false;\n\t\t\t}\n\t\t\t\n\t\t\tif (!isSuccess)\n\t\t\t{\n\t\t\t\tresetAbsorbList();\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tai = null;\n\t\t}\n\t\t\n\t\t// ********\n\t\tString[] crystalNFO = null;\n\t\tString crystalNME = \"\";\n\t\t\n\t\tfinal int dice = Rnd.get(100);\n\t\tint crystalQTY = 0;\n\t\tint crystalLVL = 0;\n\t\tint crystalOLD = 0;\n\t\tint crystalNEW = 0;\n\t\t\n\t\t// ********\n\t\t// Now we have four choices:\n\t\t// 1- The Monster level is too low for the crystal. Nothing happens.\n\t\t// 2- Everything is correct, but it failed. Nothing happens. (57.5%)\n\t\t// 3- Everything is correct, but it failed. The crystal scatters. A sound event is played. (10%)\n\t\t// 4- Everything is correct, the crystal level up. A sound event is played. (32.5%)\n\t\t\n\t\tList<L2PcInstance> players = new ArrayList<>();\n\t\t\n\t\tif (absorbType == L2NpcTemplate.AbsorbCrystalType.FULL_PARTY && killer.isInParty())\n\t\t{\n\t\t\tplayers = killer.getParty().getPartyMembers();\n\t\t}\n\t\telse if (absorbType == L2NpcTemplate.AbsorbCrystalType.PARTY_ONE_RANDOM && killer.isInParty())\n\t\t{\n\t\t\t// This is a naive method for selecting a random member. It gets any random party member and\n\t\t\t// then checks if the member has a valid crystal. It does not select the random party member\n\t\t\t// among those who have crystals, only. However, this might actually be correct (same as retail).\n\t\t\tplayers.add(killer.getParty().getPartyMembers().get(Rnd.get(killer.getParty().getMemberCount())));\n\t\t}\n\t\telse\n\t\t{\n\t\t\tplayers.add(killer);\n\t\t}\n\t\t\n\t\tfor (final L2PcInstance player : players)\n\t\t{\n\t\t\tif (player == null)\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\tcrystalQTY = 0;\n\t\t\t\n\t\t\tL2ItemInstance[] inv = player.getInventory().getItems();\n\t\t\tfor (final L2ItemInstance item : inv)\n\t\t\t{\n\t\t\t\tfinal int itemId = item.getItemId();\n\t\t\t\tfor (final int id : SoulCrystal.SoulCrystalTable)\n\t\t\t\t{\n\t\t\t\t\t// Find any of the 39 possible crystals.\n\t\t\t\t\tif (id == itemId)\n\t\t\t\t\t{\n\t\t\t\t\t\tcrystalQTY++;\n\t\t\t\t\t\t// Keep count but make sure the player has no more than 1 crystal\n\t\t\t\t\t\tif (crystalQTY > 1)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tisSuccess = false;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Validate if the crystal has already leveled\n\t\t\t\t\t\tif (id != SoulCrystal.RED_NEW_CRYSTAL && id != SoulCrystal.GRN_NEW_CYRSTAL && id != SoulCrystal.BLU_NEW_CRYSTAL)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\ttry\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (item.getItem().getName().contains(\"Grade\"))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t// Split the name of the crystal into 'name' & 'level'\n\t\t\t\t\t\t\t\t\tcrystalNFO = item.getItem().getName().trim().replace(\" Grade \", \"-\").split(\"-\");\n\t\t\t\t\t\t\t\t\t// Set Level to 13\n\t\t\t\t\t\t\t\t\tcrystalLVL = 13;\n\t\t\t\t\t\t\t\t\t// Get Name\n\t\t\t\t\t\t\t\t\tcrystalNME = crystalNFO[0].toLowerCase();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t// Split the name of the crystal into 'name' & 'level'\n\t\t\t\t\t\t\t\t\tcrystalNFO = item.getItem().getName().trim().replace(\" Stage \", \"\").split(\"-\");\n\t\t\t\t\t\t\t\t\t// Get Level\n\t\t\t\t\t\t\t\t\tcrystalLVL = Integer.parseInt(crystalNFO[1].trim());\n\t\t\t\t\t\t\t\t\t// Get Name\n\t\t\t\t\t\t\t\t\tcrystalNME = crystalNFO[0].toLowerCase();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t// Allocate current and levelup ids' for higher level crystals\n\t\t\t\t\t\t\t\tif (crystalLVL > 9)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tfor (final int[] element : SoulCrystal.HighSoulConvert)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t// Get the next stage above 10 using array.\n\t\t\t\t\t\t\t\t\t\tif (id == element[0])\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tcrystalNEW = element[1];\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tcrystalNEW = id + 1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tcatch (final NumberFormatException nfe)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tLOGGER.warn(\"An attempt to identify a soul crystal failed, \" + \"verify the names have not changed in etcitem table.\", nfe);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tplayer.sendMessage(\"There has been an error handling your soul crystal.\" + \" Please notify your server admin.\");\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tisSuccess = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tcatch (final Exception e)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t\t\tisSuccess = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcrystalNME = item.getItem().getName().toLowerCase().trim();\n\t\t\t\t\t\t\tcrystalNEW = id + 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Done\n\t\t\t\t\t\tcrystalOLD = id;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (!isSuccess)\n\t\t\t\t{\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tinv = null;\n\t\t\t\n\t\t\t// If the crystal level is way too high for this mob, say that we can't increase it\n\t\t\tif (crystalLVL < minAbsorbLevel || crystalLVL >= maxAbsorbLevel)\n\t\t\t{\n\t\t\t\tdoLevelup = false;\n\t\t\t}\n\t\t\t\n\t\t\t// The player doesn't have any crystals with him get to the next player.\n\t\t\tif (crystalQTY < 1 || crystalQTY > 1 || !isSuccess || !doLevelup)\n\t\t\t{\n\t\t\t\t// Too many crystals in inventory.\n\t\t\t\tif (crystalQTY > 1)\n\t\t\t\t{\n\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_FAILED_RESONATION));\n\t\t\t\t}\n\t\t\t\t// The soul crystal stage of the player is way too high\n\t\t\t\t// Like L2OFF message must not appear if char hasn't crystal on inventory\n\t\t\t\telse if (!doLevelup && crystalQTY > 0)\n\t\t\t\t{\n\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_REFUSED));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tcrystalQTY = 0;\n\t\t\t\t\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\t/*\n\t\t\t * TODO: Confirm boss chance for crystal level up and for crystal breaking. It is known that bosses with FULL_PARTY crystal level ups have 100% success rate, but this is not the case for the other bosses (one-random or last-hit). While not confirmed, it is most reasonable that crystals leveled up at\n\t\t\t * bosses will never break. Also, the chance to level up is guessed as around 70% if not higher.\n\t\t\t */\n\t\t\tfinal int chanceLevelUp = isBossMob ? 70 : SoulCrystal.LEVEL_CHANCE;\n\t\t\t\n\t\t\t// If succeeds or it is a full party absorb, level up the crystal.\n\t\t\tif (absorbType == L2NpcTemplate.AbsorbCrystalType.FULL_PARTY && doLevelup || dice <= chanceLevelUp)\n\t\t\t{\n\t\t\t\t// Give staged crystal\n\t\t\t\texchangeCrystal(player, crystalOLD, crystalNEW, false);\n\t\t\t}\n\t\t\t\n\t\t\t// If true and not a last-hit mob, break the crystal.\n\t\t\telse if (!isBossMob && dice >= 100.0 - SoulCrystal.BREAK_CHANCE)\n\t\t\t{\n\t\t\t\t// Remove current crystal an give a broken open.\n\t\t\t\tif (crystalNME.startsWith(\"red\"))\n\t\t\t\t{\n\t\t\t\t\texchangeCrystal(player, crystalOLD, SoulCrystal.RED_BROKEN_CRYSTAL, true);\n\t\t\t\t}\n\t\t\t\telse if (crystalNME.startsWith(\"gre\"))\n\t\t\t\t{\n\t\t\t\t\texchangeCrystal(player, crystalOLD, SoulCrystal.GRN_BROKEN_CYRSTAL, true);\n\t\t\t\t}\n\t\t\t\telse if (crystalNME.startsWith(\"blu\"))\n\t\t\t\t{\n\t\t\t\t\texchangeCrystal(player, crystalOLD, SoulCrystal.BLU_BROKEN_CRYSTAL, true);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tresetAbsorbList();\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_FAILED));\n\t\t\t}\n\t\t}\n\t\t\n\t\tkiller = null;\n\t\tplayers = null;\n\t\tcrystalNFO = null;\n\t\tcrystalNME = null;\n\t}", "@Override\r\n public void onHit(int damage){\n if(box2body != null){\r\n hp -= damage;\r\n screen.getGameManager().get(\"Sounds/orc-34-hit.wav\", Sound.class).play();\r\n if(this.hp <= 0) {\r\n screen.bodiesToDelete.add(box2body);\r\n deleteFlag = true;\r\n screen.spawnedCreatures.remove(this);\r\n screen.getGameManager().get(\"Sounds/orc-32-death.wav\", Sound.class).play();\r\n\r\n //Award Experience\r\n screen.getPlayer().awardExperience(this.experienceValue);\r\n screen.getPlayer().increaseKillCount();\r\n }\r\n }\r\n //Attack player when damaged\r\n //Prevents player from sniping monsters using Wander AI\r\n if(currentState != State.ATTACKING){\r\n Vector2 orcPosition = new Vector2(box2body.getPosition().x, box2body.getPosition().y);\r\n Vector2 playerPosition = new Vector2(screen.getPlayer().box2body.getPosition().x, screen.getPlayer().box2body.getPosition().y);\r\n\r\n currentState = State.HASBEENATTACKED;\r\n velocity = new Vector2(playerPosition.x - orcPosition.x, playerPosition.y - orcPosition.y);\r\n box2body.setLinearVelocity(velocity.scl(speed));\r\n }\r\n }", "public void attack(Player p) {\n\t\tif (isVisible) {\n\t\t\tp.reduceHealthBy(1, x, y, width, height);\n\t\t}\n\t\tif (p.invincible) {\n\t\t\tp.receiveKnockback(x, y, width, height, 1.0);\n\t\t}\n\t}", "public void createExpReward() {\n try {\n int exp = RandomBenefitModel.getExpReward(encounter, characterVM.getDistance());\n if (exp > 0) characterVM.addExp(exp);\n } catch (JSONException e) {\n e.printStackTrace();\n }\n }", "public void attackMonster(World world){\n\t\tif ((UnitManager.unitNearPlayer(world.getPlayer(),this,PLAYER_RANGE) == true \n\t\t\t\t\t&& RPG.isAttacking()) && world.getPlayer().isAttack()) {\n\t\t\tthis.getUnitStats().reduceHP(world.getPlayer().damageAmount());\n\t\t\t\n\t\t}else{\n\t\t\t\n\t\t}\n\t}", "public void gainExperience(Combatant opponent) { }", "protected void processOffensive(World myWorld,\n\t\t\tArrayList<World> worldsInRange) {\n\t\tTreeSet<World> enemies = new TreeSet<World>(World.enemyComparator);\n\t\tTreeSet<World> allies = new TreeSet<World>(World.allyComparator);\n\t\tWorld victim = null;\n\t\tint neutralCount = 0;\n\n\t\tfor (World w : worldsInRange) {\n\t\t\tif (w.getPower() <= myWorld.getPower()) {\n\t\t\t\tswitch (w.getMode()) {\n\t\t\t\tcase OFFENSIVE:\n\t\t\t\t\tif (w.getOwner() == this) {\n\t\t\t\t\t\tallies.add(w);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tenemies.add(w);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase DEFENSIVE:\n\t\t\t\t\t// Offensive avoids attacking defensive without\n\t\t\t\t\t// advantage\n\t\t\t\t\tif (w.getOwner() != this\n\t\t\t\t\t\t\t&& (w.getPower() <= 0.5 * myWorld.getPower() || myWorld\n\t\t\t\t\t\t\t\t\t.getPower() == 100)) {\n\t\t\t\t\t\tenemies.add(w);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase EXPLORATIVE:\n\t\t\t\t\tif (w.getOwner() != this) {\n\t\t\t\t\t\tenemies.add(w);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase NEUTRAL:\n\t\t\t\t\tif (w.getOwner() != this) {\n\t\t\t\t\t\tneutralCount++;\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Attack the highest priority victim\n\t\tif (!enemies.isEmpty()) {\n\t\t\tvictim = enemies.first();\n\t\t\t// One Offensive can't defeat a Defensive, so prefer to explore\n\t\t\t// rather than attack defensive 50% of the time\n\t\t\tif (neutralCount > 0 && victim.getMode() == WorldMode.DEFENSIVE\n\t\t\t\t\t&& rand.nextInt(100) < 50) {\n\t\t\t\tmyWorld.setMode(WorldMode.EXPLORATIVE);\n\t\t\t} else {\n\t\t\t\tWorld.initializeAttack(myWorld, victim);\n\t\t\t}\n\n\t\t} else if (myWorld.getPower() == 100 && neutralCount > 0\n\t\t\t\t&& rand.nextInt(100) < 25) {\n\t\t\t// If there's nothing to attack but worlds to claim, change to\n\t\t\t// explorative, but leave chance to stay offensive for transfers\n\t\t\tmyWorld.setMode(WorldMode.EXPLORATIVE);\n\t\t}\n\n\t\tprocessTransfers(myWorld, allies);\n\t}", "public void move3(Pokemon enemy){\n boolean crit = false;\n boolean superEffective = false;\n boolean reduced = false;\n boolean moveHit = true;\n int randCrit = (int)(22 * Math.random()+1);\n\n //CHANGE ATTACK TO FALSE IF MOVE DOES NO DAMAGE<<<<<<<<<<<<<\n boolean attack = false;\n //CHANGE TYPE TO TYPE OF MOVE POWER AND ACCURACY<<<<<<<<<<<<<\n String type = \"Normal\";\n int power = 0;\n int accuracy = 100;\n\n //DO NOT CHANGE BELOW THIS\n int damage = ((CONSTANT * power * ( getAtt() / enemy.getDef() )) /50);\n if(randCrit == CONSTANT){\n damage = damage * 2;\n crit = true;\n }\n if(checkSE(type,enemy.getType())){\n damage = damage * 2;\n superEffective = true;\n }\n if(checkNVE(type, enemy.getType())){\n damage = damage / 2;\n reduced = true;\n }\n if(attack && hit(accuracy)){\n enemy.lowerHp(damage);\n }\n else{\n if(hit(accuracy)){\n //DO STATUS EFFECT STUFF HERE (ill figure out later)\n }\n }\n lowerM3PP();\n }", "@Override\n protected @Nonnull ItemStack dispenseStack(@Nonnull IBlockSource source, @Nonnull ItemStack stack) {\n ItemStack secondaryResult = Prep.getEmpty();\n EnumFacing enumfacing = source.getBlockState().getValue(BlockDispenser.FACING);\n\n CapturedMob capturedMob = CapturedMob.create(stack);\n\n if (capturedMob != null) {\n if (capturedMob.spawn(source.getWorld(), source.getBlockPos(), enumfacing, true)) {\n stack.shrink(1);\n secondaryResult = new ItemStack(ItemSoulVial.this);\n }\n } else {\n for (EntityLivingBase entity : source.getWorld().<EntityLivingBase> getEntitiesWithinAABB(EntityLivingBase.class,\n new AxisAlignedBB(source.getBlockPos().offset(enumfacing)), EntitySelectors.NOT_SPECTATING)) {\n if (!(entity instanceof IEntityOwnable) || ((IEntityOwnable) entity).getOwnerId() == null) {\n capturedMob = CapturedMob.create(entity);\n if (capturedMob != null) {\n entity.setDead();\n if (entity.isDead) {\n stack.shrink(1);\n secondaryResult = capturedMob.toStack(ItemSoulVial.this, 1, 1);\n break;\n }\n }\n }\n }\n }\n\n if (Prep.isValid(secondaryResult)) {\n if (Prep.isInvalid(stack)) {\n stack = secondaryResult;\n } else {\n TileEntity blockTileEntity = source.getBlockTileEntity();\n if (!(blockTileEntity instanceof TileEntityDispenser) || ((TileEntityDispenser) blockTileEntity).addItemStack(secondaryResult) < 0) {\n Block.spawnAsEntity(source.getWorld(), source.getBlockPos().offset(enumfacing), secondaryResult);\n }\n }\n }\n\n return stack;\n }", "public void incrementAttack(Fighter f1, Fighter f2)\r\n {\r\n if(f1.getAttacking() == 1) //if the fighter is attacking\r\n {\r\n if(f1.getAttackT() == 5) //if 5 frames have passed\r\n {\r\n int[] i = new int[4]; \r\n i = attackHitBox(f1); //gets the x,y, height, and width of the attack\r\n \r\n //if the attack position overlapps the other fighter's position and the other fighter isn't blocking\r\n if (i[0] <= f2.getPos()[0] + f2.getSize() && i[0] + i[2] >= f2.getPos()[0] && i[1] <= f2.getPos()[1] + f2.getSize() && i[1] + i[3] >= f2.getPos()[1] && f2.getBlocking() != 1)\r\n {\r\n f2.setHealth(f2.getHealth() - f1.getAttack().getDamage()); //deal damage to the fighter\r\n if(f1.getRight() == true){ \r\n f2.setKnockBackVel(f1.getAttack().getKnockBack()[0],f1.getAttack().getKnockBack()[1]); //apply knockback going right\r\n }else\r\n {\r\n f2.setKnockBackVel(-f1.getAttack().getKnockBack()[0],f1.getAttack().getKnockBack()[1]); //apply knockback going left\r\n }\r\n }\r\n f1.setAttackT(0); //reset attack timer\r\n f1.setAttacking(2); //sets the fighter to cooldown\r\n }else\r\n {\r\n f1.setAttackT(f1.getAttackT() + 1); //increments timer\r\n }\r\n }\r\n\r\n if(f1.getAttacking() == 2) //if fighter is in cooldown\r\n {\r\n if(f1.getAttackT() == f1.getAttack().getTime()) //if the timer has waited the cooldown of the last attack\r\n {\r\n f1.setAttackT(0); //resets the timer\r\n f1.setAttacking(0); //sets the fighter to \"can attack\"\r\n }\r\n else\r\n {\r\n f1.setAttackT(f1.getAttackT() + 1); //increment timer\r\n }\r\n }\r\n }", "@Override\n public void applyOnHit(LivingEntity user, LivingEntity target, int level, EntityDamageByEntityEvent event) {\n if (Math.random() * 100 > settings.get(CHANCE, level)) return;\n\n final double range = settings.get(RANGE, level);\n final double damage = settings.get(DAMAGE, level);\n final double speed = settings.get(SPEED, level);\n for (Entity entity : user.getNearbyEntities(range, range, range)) {\n if (!(entity instanceof LivingEntity) || Protection.isAlly(user, (LivingEntity)entity)) continue;\n\n ((LivingEntity) entity).damage(damage, user);\n entity.setVelocity(user.getLocation().subtract(entity.getLocation()).toVector().multiply(speed));\n }\n }", "void onRespawned(Need need, NeedLevel level, PlayerEntity player, PlayerEntity oldPlayer);", "@Override\n public void attackedByPaladin(double attack) {\n this.attack += (2 * attack) / 3;\n damageCounter = Math.max(damageCounter - (2 * attack) / 3, 0);\n }", "public void attack(ItemWeapon w, Monster target) {\n\t\ttarget.takeDamage(w.getDamage()+level*20);\n\t}", "@Override\r\n\tpublic int monsterFight(IFighter attacker, IFighter defencer, ISkill skill) {\n\t\t\r\n\t\tSkillTemplatePojo stPojo = skill.getSkillTemplatePojo();\r\n\t\tfor (SkillUnitPojo hurtPojo : stPojo.getSkillUnitPojo()) {\r\n\t\t\tBattleHurtUpdateResponse.Builder hurtBuilder = createBattleHurtUpdateResponse();\r\n\t\t\thurtBuilder.setAttackerId(attacker.getId());\r\n\t\t\thurtBuilder.setAttackerType(PbAoiEntityType.valueOf(attacker.getType()));\r\n\t\t\thurtBuilder.setSkillUnitId(hurtPojo.getId());\r\n\t\t\thurtBuilder.setSkillId(stPojo.getId());\r\n\t\t\t\r\n\t\t\t// 选 择目标\r\n\t\t\tList<IFighter> targetList = fightAoe.selectTarget(attacker, defencer, hurtPojo, stPojo);\r\n\t\t\tif (targetList.size() <= 0) {\r\n\t\t\t\ttargetList.add(defencer);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tfor (IFighter attacted : targetList) {\r\n\t\t\t\tif (!attacted.isDie()) {\r\n\t\t\t\t\tfight(attacted, attacker, hurtPojo, hurtBuilder);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// 如果有移位加移位\r\n\t\t\tif (hurtPojo.getAttakerMove() > 0) {\r\n\t\t\t\tPosition3D hitback = fightCalculate.calHitMove(attacker, hurtPojo.getAttakerMove(), defencer);\r\n\t\t\t\tif (hitback != null) {\r\n\t\t\t\t\tattacker.setX(hitback.getX());\r\n\t\t\t\t\tattacker.setY(hitback.getY());\r\n\t\t\t\t\tattacker.setZ(hitback.getZ());\r\n\t\t\t\t\tSystem.err.println(attacker.getName() + \"战斗::\" + hitback.getX() + \":::\" + hitback.getZ());\r\n\t\t\t\t\t\r\n\t\t\t\t\tPbPosition3D pbPos = PbPosition3D.newBuilder().setX(hitback.getX()).setY(hitback.getY()).setZ(hitback.getZ()).build();\r\n\t\t\t\t\thurtBuilder.setAttackerMovePos(pbPos);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tthis.sendHurtMsg(hurtBuilder.build(), attacker);\r\n\t\t\tthis.sendUpdateHp(targetList);\r\n\t\t\t\r\n\t\t\t// System.err.println(\"当前打斗时间::\"+(System.currentTimeMillis() - fighTime));\r\n\t\t\tfighTime = System.currentTimeMillis();\r\n\t\t}\r\n\t\treturn 0;\r\n\t}", "@Override\n public int doDamage() {\n if (difficulty <5)\n return damage;\n else \n return damage*2;\n }", "public void move1(Pokemon enemy){\n int randCrit = (int)(22 * Math.random()+1);\n boolean crit = false;\n boolean superEffective = false;\n boolean reduced = false;\n boolean moveHit = true;\n\n //CHANGE ATTACK TO FALSE IF MOVE DOES NO DAMAGE<<<<<<<<<<<<<\n boolean attack = true;\n //CHANGE TYPE TO TYPE OF MOVE POWER AND ACCURACY<<<<<<<<<<<<<\n String type = \"Dark\";\n int power = 70;\n int accuracy = 100;\n\n //DO NOT CHANGE BELOW THIS\n int damage = ((CONSTANT * power * ( getAtt() / enemy.getDef() )) /50);\n if(randCrit == CONSTANT){\n damage = damage * 2;\n crit = true;\n }\n if(checkSE(type,enemy.getType())){\n damage = damage * 2;\n superEffective = true;\n }\n if(checkNVE(type, enemy.getType())){\n damage = damage / 2;\n reduced = true;\n }\n if(attack && hit(accuracy)){\n enemy.lowerHp(damage);\n }\n else{\n if(hit(accuracy)){\n //DO STATUS EFFECT STUFF HERE (ill figure out later)\n }\n\n }\n lowerM1PP();\n }", "public void getAttackedByDarknessMagicBook(IEquipableItem item){item.strongAttackTo(this.getOwner());}", "public int attack(Character target){ //hw3E#0 //hw46#moreThinking\n lowerHP((int)(strength * attack / 10)); //hw3E#0 //hw46#moreThinking\n return super.attack(target); //hw3E#0 //hw44#3,4 //hw46#moreThinking\n }", "public void rechargePrayerPoints() {\r\n prayerPoints = staticLevels[PRAYER];\r\n if (entity instanceof Player) {\r\n PacketRepository.send(SkillLevel.class, new SkillContext((Player) entity, PRAYER));\r\n }\r\n }", "public void attack() {\n //Grab an attacker.\n Territory attacker = potentialAttackers.remove(0);\n \n //Find the weakest adjacent territory\n int victimStrength = Integer.MAX_VALUE;\n Territory victim = null;\n List<Territory> adjs = gameController.getBoard().getAdjacentTerritories(attacker);\n for(Territory adj : adjs){\n \n //Verify that our odds are good enough for this attack to consider it.\n int aTroops = attacker.getNumTroops() - 1;\n int dTroops = adj.getNumTroops();\n double odds = MarkovLookupTable.getOddsOfSuccessfulAttack(aTroops, dTroops);\n boolean yes = Double.compare(odds, ACCEPTABLE_RISK) >= 0;\n \n //If we have a chance of winning this fight and its the weakest opponent.\n if(yes && adj.getNumTroops() < victimStrength && !adj.getOwner().equals(this)){\n victim = adj;\n victimStrength = adj.getNumTroops();\n }\n }\n \n //Resolve the Attack by building forces and settle the winner in Victim's land\n Force atkForce = attacker.buildForce(attacker.getNumTroops() - 1);\n Force defForce = victim.buildForce(victimStrength); //Guaranteed not null\n Force winner = atkForce.attack(defForce);\n victim.settleForce(winner);\n }", "public void attack() { \n db.attack(creatures.get(creatureId), players.get(playerId));\n creatures.set(creatureId, db.getCreature(creatures.get(creatureId).getId()));\n players.set(playerId, db.getPlayer(players.get(playerId).getId()));\n setTextFields();\n }", "@Override\n\tpublic int calculateCustomDamage(Entity attacker, Entity defender, int entityAttackType) {\n\t\tif (attacker.getType() == EntityType.NPC && defender.getType() == EntityType.PLAYER) {\n\t\t\tNpc attackerAsNpc = (Npc) attacker;\n\n\t\t\tPlayer defenderAsPlayer = (Player) defender;\n\n\t\t\tif (attack == AbyssalSireAttack.SWIPE) {\n\t\t\t\tif (defenderAsPlayer.prayerActive[ServerConstants.PROTECT_FROM_MELEE]) {\n\t\t\t\t\treturn ThreadLocalRandom.current().nextInt(2, 7);\n\t\t\t\t}\n\t\t\t\treturn NpcHandler.calculateNpcMeleeDamage(attackerAsNpc, defenderAsPlayer, -1, 32);\n\t\t\t} else if (attack == AbyssalSireAttack.TENDRIL_SWIPE) {\n\t\t\t\tif (defenderAsPlayer.prayerActive[ServerConstants.PROTECT_FROM_MELEE]) {\n\t\t\t\t\treturn ThreadLocalRandom.current().nextInt(0, 13);\n\t\t\t\t}\n\t\t\t\treturn NpcHandler.calculateNpcMeleeDamage(attackerAsNpc, defenderAsPlayer, -1, 40);\n\t\t\t} else if (attack == AbyssalSireAttack.DOUBLE_TENDRIL_SWIPE) {\n\t\t\t\tif (defenderAsPlayer.prayerActive[ServerConstants.PROTECT_FROM_MELEE]) {\n\t\t\t\t\treturn ThreadLocalRandom.current().nextInt(0, 26);\n\t\t\t\t}\n\t\t\t\treturn NpcHandler.calculateNpcMeleeDamage(attackerAsNpc, defenderAsPlayer, -1, 66);\n\t\t\t}\n\t\t}\n\t\treturn -1;\n\t}", "@Override\n public void onTypeAttack(Entity target) {\n if (target instanceof EntityLivingBase) {\n int time;\n switch (target.worldObj.difficultySetting) {\n case PEACEFUL:\n return;\n case EASY:\n time = 15;\n break;\n case NORMAL:\n time = 35;\n break;\n default:\n time = 75;\n }\n time *= 20;\n ((EntityLivingBase)target).addPotionEffect(new PotionEffect(Potion.resistance.id, time, -3));\n }\n }", "private void attackPlayer()\n\t{\n\t\tif(shootTimer.done())\n\t\t{\n\t\t\tProjectile spiderWeb = new SpiderWeb(x, y);\n\t\t\tGame.objectWaitingRoom.add(spiderWeb);\n\t\t\tspiderWeb.shoot();\n\t\t\tshootTimer.setTime(200);\n\t\t}\n\t}", "@Override\n\tprotected void onPlayerDamage(EntityDamageEvent evt, Player p) {\n\t\tsuper.onPlayerDamage(evt, p);\n\t\tif(evt.getCause() == DamageCause.WITHER){\n\t\t\tGUtils.healDamageable(getOwnerPlayer(), evt.getDamage() * 1.5);\n\t\t\tVector v = Utils.CrearVector(getOwnerPlayer().getLocation(), getPlayer().getLocation()).multiply(0.5D);\n\t\t\tdouble max = 7;\n\t\t\tfor (int i = 0; i < max; i++) {\n//\t\t\t\tgetWorld().playEffect(getPlayer().getEyeLocation().add(0, -0.8, 0).add(v.clone().multiply(i/max)),\n//\t\t\t\t\t\tEffect.HEART, 0);\n\t\t\t}\n\t\t}\n\t}", "public void Hitting(Monsters opponent) throws Exception {\n\t\tassert (this != opponent);\n\t\tRandom rand = new Random();\n\t\tint hit = rand.nextInt(30);\n\t\tif(hit >= this.getHitpoints()) \n\t\t\thit = this.getHitpoints();\n\t\tif (hit >= opponent.getProtection()) {\n\t\t\tint power;\n\t\t\tif (this.getAnchor(1) == null)\n\t\t\t\tpower = this.getDamage() + (this.getStrength() - 5) / 3;\n\t\t\telse\n\t\t\t\tpower = this.getDamage() + (this.getStrength() - 5) / 3 + ((Weapons)this.getAnchor(1)).getDamage();\n\t\t\topponent.setHitpoints(opponent.getHitpoints() - power);\n\t\t\tSystem.out.println(this.getName() + \" Deals \" + power + \" damage over \" + opponent.getName());\n\t\t}\n\t\telse\n\t\t\tSystem.out.println(this.getName() + \" attack failed!\");\n\t}", "@Override\n public void attack(ArrayList<territories> PlayersTerritories,int bonusArmies ) {\n\n // placeArmy(PlayersTerritories,bonusArmies);\n\n\n territories toAttack=getTerritoryGreedyAttack(PlayersTerritories,0);\n\n territories AttackWith = GetMaximumAttacker(PlayersTerritories,toAttack);\n\n Attacking(toAttack,AttackWith);\n\n\n\n }", "private void damage(){\n\n LevelMap.getLevel().damage(dmg);\n //System.out.println(\"died\");\n setDie();\n }", "private void functionalInterface1() {\n\t\tcharmander.heal();\n\n\t\tPokedex.printData(Arrays.asList(charmander));\n\n\t\tguilherme.powerUp(charmander, new BigDecimal(\"-10\"), psMinimalDamage); // -10\n\n\t\tPokedex.printData(Arrays.asList(charmander));\n\n\t\tguilherme.powerUp(charmander, new BigDecimal(\"-10\"), psHugeDamage); // -20\n\n\t\tPokedex.printData(Arrays.asList(charmander));\n\t}", "@Override\n\tpublic void onAction(L2PcInstance player, boolean interact)\n\t{\n\t\tif(!canTarget(player))\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tplayer.setLastFolkNPC(this);\n\n\t\t// Check if the L2PcInstance already target the L2GuardInstance\n\t\tif(getObjectId() != player.getTargetId())\n\t\t{\n\t\t\t// Send a Server->Client packet MyTargetSelected to the L2PcInstance player\n\t\t\t// The color to display in the select window is White\n\t\t\tMyTargetSelected my = new MyTargetSelected(getObjectId(), 0);\n\t\t\tplayer.sendPacket(my);\n\n\t\t\t// Set the target of the L2PcInstance player\n\t\t\tplayer.setTarget(this);\n\n\t\t\t// Send a Server->Client packet ValidateLocation to correct the L2NpcInstance position and heading on the client\n\t\t\tplayer.sendPacket(new ValidateLocation(this));\n\t\t}\n\t\telse if(interact)\n\t\t{\n\t\t\t// Check if the L2PcInstance is in the _aggroList of the L2GuardInstance\n\t\t\tif(containsTarget(player))\n\t\t\t{\n\t\t\t\t// Set the L2PcInstance Intention to AI_INTENTION_ATTACK\n\t\t\t\tplayer.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, this);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// Calculate the distance between the L2PcInstance and the L2NpcInstance\n\t\t\t\tif(canInteract(player))\n\t\t\t\t{\n\t\t\t\t\t// Send a Server->Client packet SocialAction to the all L2PcInstance on the _knownPlayer of the L2NpcInstance\n\t\t\t\t\t// to display a social action of the L2GuardInstance on their client\n\t\t\t\t\t// Если НПЦ не разговаривает, то слать социалку приветствия собственно и не имеет смысла\n\t\t\t\t\tif(!Config.NON_TALKING_NPCS.contains(getNpcId()))\n\t\t\t\t\t{\n\t\t\t\t\t\tbroadcastPacket(new SocialAction(getObjectId(), Rnd.get(8)));\n\t\t\t\t\t}\n\n\t\t\t\t\tList<Quest> qlsa = getTemplate().getEventQuests(Quest.QuestEventType.QUEST_START);\n\t\t\t\t\tList<Quest> qlst = getTemplate().getEventQuests(Quest.QuestEventType.ON_FIRST_TALK);\n\n\t\t\t\t\tif(qlsa != null && !qlsa.isEmpty())\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.setLastQuestNpcObject(getObjectId());\n\t\t\t\t\t}\n\n\t\t\t\t\tif(qlst != null && qlst.size() == 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tqlst.get(0).notifyFirstTalk(this, player);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tshowChatWindow(player, 0);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t// Set the L2PcInstance Intention to AI_INTENTION_INTERACT\n\t\t\t\t\tplayer.getAI().setIntention(CtrlIntention.AI_INTENTION_INTERACT, this);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t// Send a Server->Client ActionFail to the L2PcInstance in order to avoid that the client wait another packet\n\t\tplayer.sendActionFailed();\n\t}", "public void gameAttack(){\n int counter = 0;\n while (currentPlayer.wantToAttack(this)){\n counter++;\n if (counter > 100) break;\n /*In rare cases, AI players will repeatedly select the same attackers and defenders\n while also not wanting to dice fight. That will infinitely loop here and this counter will prevent it\n Under normal circumstances, no reasonable player will ever try to do more than 100 separate attacks in the same turn\n */\n\n String[] attackerDefender = {\"\",\"\"};\n //AttackStarterSelection\n attackerDefender[0] = currentPlayer.chooseAttackStarter(this);\n\n //AttackDefenderSelection\n attackerDefender[1] = currentPlayer.chooseAttackDefender(this, attackerDefender[0]);\n\n //DiceFightOrQuit\n int attackerDice, defenderDice;\n while (currentPlayer.wantToDiceFight(this, attackerDefender[0]+ \",\" + attackerDefender[1])){\n //DiceFightAttackerChoice\n attackerDice = currentPlayer.getAttackerDice(this, getTerritory(attackerDefender[0]));\n\n //DiceFightDefenderChoice\n Player defender = this.getPlayerFromList(this.getTerritory(attackerDefender[1]).getOwner());\n defenderDice = defender.getDefenderDice(this, this.getTerritory(attackerDefender[1]));\n\n\n //DiceFight results\n displayMessage(this.diceFight(attackerDefender, attackerDice,defenderDice));\n\n //Possible elimination and announcement of winner\n //Current diceFight ends if attacker has 1 troop left, or territory is conquered\n if (endDiceFight(attackerDefender, attackerDice)) break;\n\n }//End diceFightOrQuit\n\n\n }//End wantToAttack\n //Proceed to fortify stage of turn\n }", "public static void experience(){\n PlayerStats.currentEXP += (12*AC + 8*totalHP);\n System.out.println(\"You gained \" +(12*AC + 8*totalHP)+ \" experience!\");\n }", "private void applyLvlUpCost() {\n }", "public void action(Player myPlayer)\n {\n if (getNbUtilisation() == 0) {\n System.out.println(\"Not possible\");\n } else {\n int nHealthy = getPointsHealthy();\n myPlayer.addLifePoints(nHealthy);\n\n }\n }", "@Override\r\n public int actionDelayTime(Entity attacker) {\n return 4000;\r\n }", "public void takeDamage(int damage);", "private static void attack(RobotInfo target) throws GameActionException {\n if (SOLDIER_DEBUG) {\n System.out.println(\"attacking\");\n }\n BulletInfo[] bullets = rc.senseNearbyBullets(EvasiveSoldier.BULLET_DETECT_RADIUS);\n RobotInfo[] robots = rc.senseNearbyRobots(EvasiveSoldier.ENEMY_DETECT_RADIUS);\n MapLocation targetLocation = target.getLocation();\n move(bullets, robots, targetLocation);\n //RobotUtils.tryMoveDestination(targetLocation);\n if (TargetingUtils.clearShot(here, target) || (rc.getType() == RobotType.GARDENER && rc.getOpponentVictoryPoints() > 10)) {\n if (SOLDIER_DEBUG) {\n System.out.println(\"clearShot to target\");\n }\n Direction towardsEnemy = here.directionTo(targetLocation);\n float distanceEnemy = here.distanceTo(targetLocation);\n if (distanceEnemy <= 3.5 && rc.canFirePentadShot() && rc.getTeamBullets() > 200) {\n rc.firePentadShot(towardsEnemy);\n }\n else {\n if (rc.canFireTriadShot() && rc.getTeamBullets() > 50) {\n rc.fireTriadShot(towardsEnemy);\n }\n else if (rc.canFireSingleShot()) {\n rc.fireSingleShot(towardsEnemy);\n }\n }\n }\n }", "@Override\n protected void onTypeAttack(Entity target) {\n if (target instanceof EntityLivingBase) {\n int time;\n switch (target.worldObj.difficultySetting) {\n case PEACEFUL:\n return;\n case EASY:\n time = 20;\n break;\n case NORMAL:\n time = 50;\n break;\n default:\n time = 120;\n }\n time *= 20;\n EffectHelper.stackEffect((EntityLivingBase)target, Potion.weakness, time, 0, 4);\n EffectHelper.stackEffect((EntityLivingBase)target, Potion.digSlowdown, time, 0, 4);\n }\n }", "public static byte calcShldUse(L2Character attacker, L2Character target, L2Skill skill, boolean sendSysMsg)\n\t{\n\t\tif (skill != null && (skill.ignoreShield() || skill.isMagic()))\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\n\t\tL2Item item = target.getSecondaryWeaponItem();\n\t\tif (item == null || !(item instanceof L2Armor) || ((L2Armor) item).getItemType() == L2ArmorType.SIGIL)\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\n\t\tdouble shldRate = target.calcStat(Stats.SHIELD_RATE, 0, attacker, null) * BaseStats.DEX.calcBonus(target);\n\t\tif (shldRate == 0.0)\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\n\t\tint degreeside = (int) target.calcStat(Stats.SHIELD_DEFENCE_ANGLE, 120, null, null);\n\t\tif (degreeside < 360 && !target.isFacing(attacker, degreeside))\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\n\t\t// Tenkai custom: Make shields way less effective on non-sigel awakened classes\n\t\t/*if (target instanceof L2PcInstance\n\t\t\t\t&& ((L2PcInstance)target).getClassId() > 139)\n\t\t\tshldRate *= 0.1;*/\n\n\t\tbyte result = SHIELD_DEFENSE_FAILED;\n\t\t// if attacker use bow and target wear shield, shield block rate is multiplied by 1.3 (30%)\n\t\tL2Weapon at_weapon = attacker.getActiveWeaponItem();\n\t\tif (at_weapon != null && at_weapon.getItemType() == L2WeaponType.BOW)\n\t\t{\n\t\t\tshldRate *= 1.3;\n\t\t}\n\n\t\tint rnd = Rnd.get(100);\n\t\tif (shldRate * (Config.ALT_PERFECT_SHLD_BLOCK / 100.0) > rnd)\n\t\t{\n\t\t\tresult = SHIELD_DEFENSE_PERFECT_BLOCK;\n\t\t}\n\t\telse if (shldRate > rnd)\n\t\t{\n\t\t\tresult = SHIELD_DEFENSE_SUCCEED;\n\t\t}\n\n\t\tif (sendSysMsg && target instanceof L2PcInstance)\n\t\t{\n\t\t\tL2PcInstance enemy = (L2PcInstance) target;\n\t\t\tswitch (result)\n\t\t\t{\n\t\t\t\tcase SHIELD_DEFENSE_SUCCEED:\n\t\t\t\t\tenemy.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.SHIELD_DEFENCE_SUCCESSFULL));\n\t\t\t\t\tbreak;\n\t\t\t\tcase SHIELD_DEFENSE_PERFECT_BLOCK:\n\t\t\t\t\tenemy.sendPacket(SystemMessage\n\t\t\t\t\t\t\t.getSystemMessage(SystemMessageId.YOUR_EXCELLENT_SHIELD_DEFENSE_WAS_A_SUCCESS));\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tif (result >= 1)\n\t\t{\n\t\t\t// ON_SHIELD_BLOCK\n\t\t\tif (target.getChanceSkills() != null)\n\t\t\t{\n\t\t\t\ttarget.getChanceSkills().onBlock(target);\n\t\t\t}\n\t\t}\n\n\t\treturn result;\n\t}", "@Override\n\tpublic boolean attackEntityFrom(DamageSource src, float par2) {\n\t\tif (isInvulnerableTo(src)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// don't just sit there!\n\t\taiSit.setSitting(false);\n\n\t\treturn super.attackEntityFrom(src, par2);\n\t}", "public void addExperienceNoMod(int slot, double experience) {\r\n this.experience[slot] += (experience);\r\n if (this.experience[slot] > 200_000_000) {\r\n this.experience[slot] = 200_000_000;\r\n }\r\n experienceGained = experienceGained + (int) (experience);\r\n int newLevel = getStaticLevelByExperience(slot);\r\n if (newLevel > staticLevels[slot]) {\r\n if (dynamicLevels[slot] < newLevel) {\r\n dynamicLevels[slot] += newLevel - staticLevels[slot];\r\n }\r\n if (slot == HITPOINTS) {\r\n lifepoints += newLevel - staticLevels[slot];\r\n }\r\n staticLevels[slot] = newLevel;\r\n if (entity instanceof Player) {\r\n Player p = (Player) entity;\r\n if (updateCombatLevel()) {\r\n if (!p.getSavedData().getGlobalData().hasAnnouncedCombat() && p.getProperties().getCurrentCombatLevel() == Constants.MAX_COMBAT_LEVEL) {\r\n p.getSavedData().getGlobalData().setCombatAnnounced(true);\r\n p.sendGlobalNewsMessage(\"ff8c38\", \" has reached the max combat level of \" + Constants.MAX_COMBAT_LEVEL + \"!\", 5);\r\n }\r\n p.getUpdateMasks().register(new AppearanceFlag(p));\r\n }\r\n handleMilestones(p);\r\n if (getExperience(slot) == 200_000_000) {\r\n if (!p.getSavedData().getGlobalData().getExperienceMilestone(slot)) {\r\n p.getSavedData().getGlobalData().setExperienceMilestone(slot);\r\n p.sendGlobalNewsMessage(\"ff0000\", \" has just reached 200,000,000 experience in \" + TextUtils.formatDisplayName(SKILL_NAME[slot]), 6);\r\n }\r\n }\r\n LevelUp.levelUp(p, slot);\r\n }\r\n }\r\n if (entity instanceof Player) {\r\n if (entity.asPlayer().getInterfaceState().get(InterfaceConfiguration.XP_DROP_LOCK) == 0) {\r\n entity.asPlayer().getSavedData().getGlobalData().increaseXpDrops((long) experience);\r\n }\r\n PacketRepository.send(XPDrop.class, new XPDropContext((Player) entity, slot, (int) experience));\r\n PacketRepository.send(SkillLevel.class, new SkillContext((Player) entity, slot));\r\n }\r\n }", "@EventHandler\n\tpublic void onPlayerDeath(final PlayerDeathEvent event) {\n\t\tif (event.getEntity().getKiller() != null) {\n\t\t\tif (event.getEntity().getKiller() instanceof Player && event.getEntity() instanceof Player && pli.global_players.containsKey(event.getEntity().getName()) && pli.global_players.containsKey(event.getEntity().getKiller().getName())) {\n\t\t\t\tevent.getDrops().clear();\n\t\t\t\tevent.getEntity().setHealth(20);\n\t\t\t\t// final Location l = event.getEntity().getLocation();\n\t\t\t\tfinal String killername = event.getEntity().getKiller().getName();\n\t\t\t\tfinal String entityKilled = event.getEntity().getName();\n\n\t\t\t\tBukkit.getScheduler().runTask(this, new Runnable() {\n\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\tpli.getRewardsInstance().giveKillReward(killername, 2);\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tfinal Player p1 = event.getEntity().getKiller();\n\t\t\t\tfinal Player p2 = event.getEntity();\n\n\t\t\t\tIArena a = (IArena) pli.global_players.get(p1.getName());\n\t\t\t\tUtil.teleportPlayerFixed(p2, a.getSpawns().get(r.nextInt(a.getSpawns().size())));\n\n\t\t\t\tInteger gpkiller = 2;\n\t\t\t\tInteger gploser = 0;\n\t\t\t\tif (getConfig().isSet(\"player.\" + killername)) {\n\t\t\t\t\tgpkiller = getConfig().getInt(\"player.\" + killername + \".gp\") + 2; // +2 gp\n\t\t\t\t}\n\t\t\t\tif (getConfig().isSet(\"player.\" + entityKilled)) {\n\t\t\t\t\tgploser = Math.max(getConfig().getInt(\"player.\" + entityKilled + \".gp\") - 1, 0); // -1 gp\n\t\t\t\t}\n\t\t\t\tgetConfig().set(\"player.\" + killername + \".gp\", gpkiller);\n\t\t\t\tgetConfig().set(\"player.\" + entityKilled + \".gp\", gploser);\n\t\t\t\tthis.saveConfig();\n\n\t\t\t\ttry {\n\t\t\t\t\tmainsql.updateStats(p1.getName(), 2);\n\t\t\t\t\tmainsql.updateStats(p2.getName(), -1);\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\tSystem.out.println(\"Failed updating sql gp.\");\n\t\t\t\t}\n\n\t\t\t\tBukkit.getScheduler().runTaskLater(this, new Runnable() {\n\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\tp2.getInventory().clear();\n\t\t\t\t\t\tp2.getInventory().setHelmet(null);\n\t\t\t\t\t\tp2.getInventory().setChestplate(null);\n\t\t\t\t\t\tp2.getInventory().setLeggings(null);\n\t\t\t\t\t\tp2.getInventory().setBoots(null);\n\t\t\t\t\t\tp2.getInventory().setArmorContents(null);\n\t\t\t\t\t\tfor (ItemStack item : start_items) {\n\t\t\t\t\t\t\tp2.getInventory().addItem(item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tp2.updateInventory();\n\t\t\t\t\t}\n\t\t\t\t}, 20L);\n\n\t\t\t\tp2.playSound(p2.getLocation(), Sound.CAT_MEOW, 1F, 1);\n\t\t\t\tlv.put(p2.getName(), 0);\n\n\t\t\t\tArrayList<String> keys = new ArrayList<String>();\n\t\t\t\tif (getConfig().isConfigurationSection(\"player.\" + p2.getName() + \".items\")) {\n\t\t\t\t\tgetConfig().set(\"player.\" + p2.getName() + \".items\", null);\n\t\t\t\t\tthis.saveConfig();\n\t\t\t\t}\n\n\t\t\t\tfor (PotionEffect effect : p2.getActivePotionEffects())\n\t\t\t\t\tp2.removePotionEffect(effect.getType());\n\n\t\t\t\tfor (PotionEffect effect : p1.getActivePotionEffects())\n\t\t\t\t\tp1.removePotionEffect(effect.getType());\n\n\t\t\t\tp1.playEffect(p1.getLocation(), Effect.POTION_BREAK, 5);\n\t\t\t\tInteger current = lv.get(p1.getName());\n\t\t\t\tlv.put(p1.getName(), current + 1);\n\t\t\t\tp1.sendMessage(im.upgrade.replaceAll(\"<level>\", Integer.toString(lv.get(p1.getName()))));\n\t\t\t\tLevel.updatelv(m, lv, p1);\n\n\t\t\t\tscoreboard.updateScoreboard(a);\n\n\t\t\t\tp1.setFoodLevel(20);\n\t\t\t\tp1.setHealth(20);\n\t\t\t\tp2.setHealth(20);\n\t\t\t\tp2.setFoodLevel(20);\n\n\t\t\t\tthis.addextraitems(p1);\n\t\t\t}\n\t\t} else {\n\t\t\t// death by something else -> respawn\n\n\t\t\tif (pli.global_players.containsKey(event.getEntity().getName())) {\n\t\t\t\tevent.getEntity().setHealth(20);\n\t\t\t\tif (event.getEntity() != null) {\n\t\t\t\t\tif (event.getEntity() instanceof Player) {\n\t\t\t\t\t\tevent.getDrops().clear();\n\t\t\t\t\t\tfinal Player p = (Player) event.getEntity();\n\t\t\t\t\t\tIArena a = (IArena) pli.global_players.get(p.getName());\n\t\t\t\t\t\tif (a != null && p != null) {\n\t\t\t\t\t\t\tUtil.teleportPlayerFixed(p, a.getSpawns().get(r.nextInt(a.getSpawns().size())));\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tp.playSound(p.getLocation(), Sound.CAT_MEOW, 1F, 1);\n\n\t\t\t\t\t\tp.setFoodLevel(20);\n\n\t\t\t\t\t\tlv.put(p.getName(), 0);\n\n\t\t\t\t\t\tBukkit.getScheduler().runTaskLater(this, new Runnable() {\n\t\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\t\tp.getInventory().clear();\n\t\t\t\t\t\t\t\tp.getInventory().setHelmet(null);\n\t\t\t\t\t\t\t\tp.getInventory().setChestplate(null);\n\t\t\t\t\t\t\t\tp.getInventory().setLeggings(null);\n\t\t\t\t\t\t\t\tp.getInventory().setBoots(null);\n\t\t\t\t\t\t\t\tp.getInventory().setArmorContents(null);\n\t\t\t\t\t\t\t\tfor (ItemStack item : start_items) {\n\t\t\t\t\t\t\t\t\tp.getInventory().addItem(item);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tp.updateInventory();\n\n\t\t\t\t\t\t\t\tm.addextraitems(p);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}, 20L);\n\n\t\t\t\t\t\tfor (PotionEffect effect : p.getActivePotionEffects())\n\t\t\t\t\t\t\tp.removePotionEffect(effect.getType());\n\n\t\t\t\t\t\tp.setHealth(20);\n\t\t\t\t\t\tp.setFoodLevel(20);\n\n\t\t\t\t\t\tthis.addextraitems(p);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public void takeDamage(int damage){\n\t\thealth -= damage;\n\t\tif(health<= 0) {\n\t\t\tspawnNew();\n\t\t}\n\t}", "@Override\n\tpublic void onDamageTaken(Entity attacker, Entity defender, int damage, int entityAttackType) {\n\t\tif (attacker.getType() == EntityType.PLAYER && defender.getType() == EntityType.NPC) {\n\t\t\tPlayer attackerAsPlayer = (Player) attacker;\n\n\t\t\tNpc defenderAsNpc = (Npc) defender;\n\n\t\t\tif (phase == AbyssalSirePhase.SLEEPING && phaseProgressionEvent == null) {\n\t\t\t\tphaseProgressionEvent = new AbyssalSirePhaseProgressionEvent();\n\n\t\t\t\tCycleEventContainer<Entity> container = getEventHandler().addEvent(this, phaseProgressionEvent, 6);\n\n\t\t\t\trequestAnimation(4528);\n\t\t\t\tcontainer.addStopListener(() -> {\n\t\t\t\t\tif (phase == AbyssalSirePhase.SLEEPING) {\n\t\t\t\t\t\ttarget = attackerAsPlayer;\n\t\t\t\t\t\tfirstWake();\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t} else if (phase == AbyssalSirePhase.AWAKE) {\n\t\t\t\tif (attackerAsPlayer.getOldSpellId() > -1) {\n\t\t\t\t\tint spellDisorientation = DISORIENTING_SPELLS.getOrDefault(CombatConstants.MAGIC_SPELLS[attackerAsPlayer.getOldSpellId()][0], 0);\n\n\t\t\t\t\tif (spellDisorientation > 0) {\n\t\t\t\t\t\tdisorientation += spellDisorientation;\n\n\t\t\t\t\t\tif (disorientation >= 100) {\n\t\t\t\t\t\t\tdisorient();\n\t\t\t\t\t\t\tattackerAsPlayer.getPA().sendMessage(\"Your shadow spelled disoriented the Abyssal sire.\");\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (phase != AbyssalSirePhase.DISORIENTED) {\n\t\t\t\t\tdamageDisorientation += damage;\n\n\t\t\t\t\tif (damageDisorientation >= 75) {\n\t\t\t\t\t\tdisorient();\n\t\t\t\t\t\tattackerAsPlayer.getPA().sendMessage(\"Your damage slowly disoriented the Abyssal sire.\");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\theal(ThreadLocalRandom.current().nextInt(1, Math.max(5, damage)));\n\t\t\t} else if (phase == AbyssalSirePhase.MELEE_COMBAT) {\n\t\t\t\tif ((defenderAsNpc.getCurrentHitPoints() <= 200)) {\n\t\t\t\t\twalkToCenter();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public void autosimulateCombat() {\n\n int monstersRemainingHealth = monster.getHealth() - player.getPower();\n int playersRemainingHealth = player.getHealth() - monster.getPower();\n\n while (player.getHealth() > 0 && monster.getHealth() > 0) {\n\n monster.setHealth(monstersRemainingHealth);\n monstersRemainingHealth = monster.getHealth() - player.getPower();\n\n\n player.setHealth(playersRemainingHealth);\n playersRemainingHealth = player.getHealth() - monster.getPower();\n\n }\n isPlayerDefeated();\n return;\n }", "@Deprecated\n/* */ public static boolean attack(Creature performer, Item target, float counter, int pos, Action act) {\n/* 3027 */ boolean done = false;\n/* 3028 */ boolean dead = false;\n/* 3029 */ boolean aiming = false;\n/* 3030 */ Item primWeapon = performer.getPrimWeapon();\n/* */ \n/* 3032 */ if (primWeapon == null || primWeapon.isBodyPart()) {\n/* */ \n/* */ \n/* 3035 */ performer.getCommunicator().sendNormalServerMessage(\"You have no weapon to attack \" + target.getNameWithGenus() + \" with.\");\n/* 3036 */ return true;\n/* */ } \n/* 3038 */ if (primWeapon.isShield()) {\n/* */ \n/* */ \n/* 3041 */ performer.getCommunicator().sendNormalServerMessage(\"You cannot practice attacks with shields on \" + target\n/* 3042 */ .getNameWithGenus() + \".\");\n/* 3043 */ return true;\n/* */ } \n/* 3045 */ if (primWeapon.isWeaponBow() || primWeapon.isBowUnstringed()) {\n/* */ \n/* */ \n/* 3048 */ performer.getCommunicator().sendNormalServerMessage(\"You cannot practice attacks with bows on \" + target\n/* 3049 */ .getNameWithGenus() + \". You need to use an archery target instead.\");\n/* */ \n/* 3051 */ return true;\n/* */ } \n/* */ \n/* 3054 */ BlockingResult result = Blocking.getBlockerBetween(performer, target, 4);\n/* 3055 */ if (result != null) {\n/* */ \n/* 3057 */ performer.getCommunicator()\n/* 3058 */ .sendCombatNormalMessage(\"You fail to reach the \" + target\n/* 3059 */ .getNameWithGenus() + \" because of the \" + result\n/* 3060 */ .getFirstBlocker().getName() + \".\");\n/* 3061 */ return true;\n/* */ } \n/* */ \n/* 3064 */ if (Creature.rangeTo(performer, target) > Actions.actionEntrys[114].getRange()) {\n/* */ \n/* 3066 */ performer.getCommunicator().sendNormalServerMessage(\"You are now too far away to \" + Actions.actionEntrys[114]\n/* 3067 */ .getActionString().toLowerCase() + \" \" + target\n/* 3068 */ .getNameWithGenus() + \".\");\n/* 3069 */ return true;\n/* */ } \n/* 3071 */ int speed = 10;\n/* 3072 */ speed = primWeapon.getWeightGrams() / 1000 + 3;\n/* 3073 */ if (pos != -1) {\n/* */ \n/* 3075 */ aiming = true;\n/* 3076 */ speed++;\n/* */ } \n/* 3078 */ if (!done) {\n/* */ \n/* */ \n/* 3081 */ if (act.justTickedSecond())\n/* 3082 */ performer.decreaseFatigue(); \n/* 3083 */ if (counter == 1.0F)\n/* */ {\n/* 3085 */ if (aiming) {\n/* */ \n/* 3087 */ String bodypartname = PracticeDollBehaviour.getWoundLocationString(pos);\n/* 3088 */ performer.getCommunicator().sendSafeServerMessage(\"You try to \" + \n/* 3089 */ getAttackString(performer, primWeapon) + \" \" + target.getNameWithGenus() + \" in the \" + bodypartname + \".\");\n/* */ \n/* */ }\n/* */ else {\n/* */ \n/* 3094 */ performer.getCommunicator().sendSafeServerMessage(\"You try to \" + \n/* 3095 */ getAttackString(performer, primWeapon) + \" \" + target.getNameWithGenus() + \".\");\n/* */ } \n/* */ }\n/* */ \n/* 3099 */ if (act.currentSecond() % speed == 0) {\n/* */ \n/* 3101 */ Skill attackerFightSkill = null;\n/* 3102 */ Skills performerSkills = performer.getSkills();\n/* */ \n/* 3104 */ double attBonus = 0.0D;\n/* */ \n/* */ \n/* 3107 */ int attSknum = 1023;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ try {\n/* 3122 */ attackerFightSkill = performerSkills.getSkill(1023);\n/* */ }\n/* 3124 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 3126 */ attackerFightSkill = performerSkills.learn(1023, 1.0F);\n/* */ } \n/* 3128 */ dead = performAttack(pos, false, performer, performerSkills, primWeapon, target, 0.0D, attackerFightSkill, speed);\n/* */ \n/* */ \n/* 3131 */ if (aiming)\n/* 3132 */ done = true; \n/* 3133 */ if (dead)\n/* 3134 */ done = true; \n/* */ } \n/* 3136 */ if (!done && !aiming) {\n/* */ \n/* 3138 */ Item[] secondaryWeapons = performer.getSecondaryWeapons();\n/* 3139 */ for (int x = 0; x < secondaryWeapons.length; x++) {\n/* */ \n/* 3141 */ if (!secondaryWeapons[x].isBodyPart()) {\n/* */ \n/* 3143 */ speed = Server.rand.nextInt(secondaryWeapons[x].getWeightGrams() / 1000 + 7) + 2;\n/* 3144 */ if (act.currentSecond() % speed == 0) {\n/* */ \n/* 3146 */ Skill attackerFightSkill = null;\n/* 3147 */ Skills performerSkills = performer.getSkills();\n/* */ \n/* 3149 */ double attBonus = 0.0D;\n/* */ \n/* */ \n/* */ \n/* 3153 */ int attSknum = 1023;\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ try {\n/* 3168 */ attackerFightSkill = performerSkills.getSkill(1023);\n/* */ }\n/* 3170 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 3172 */ attackerFightSkill = performerSkills.learn(1023, 1.0F);\n/* */ } \n/* 3174 */ done = performAttack(pos, false, performer, performerSkills, secondaryWeapons[x], target, 0.0D, attackerFightSkill, speed);\n/* */ } \n/* */ } \n/* */ } \n/* */ } \n/* */ } \n/* */ \n/* 3181 */ return done;\n/* */ }", "@Override\n public void use(AbstractPlayer p, AbstractMonster m) {\n addToBot(new GainBlockAction(p,block));\n if (AbstractDungeon.player.hand.contains(this)){\n if (AbstractDungeon.player.hand.group.indexOf(this)-1 >= 0){\n addToBot(new RewindAction(AbstractDungeon.player.hand.group.get(AbstractDungeon.player.hand.group.indexOf(this)-1),AbstractDungeon.player.hand));\n }\n if (AbstractDungeon.player.hand.group.indexOf(this)+1 <= AbstractDungeon.player.hand.group.size()-1){\n addToBot(new RewindAction(AbstractDungeon.player.hand.group.get(AbstractDungeon.player.hand.group.indexOf(this)+1),AbstractDungeon.player.hand));\n }\n }\n }", "protected void takeDamage(int damage)\n {\n health = health - damage;\n \n }", "private void rewardPlayer(Player player) {\n\t\tRandom number = new Random();\n\t\tint num = number.nextInt(100);\n\t\t\n\t\tif(num >= 80 && num < 90) {\n\t\t\tplayer.increaseAttacks();\n\t\t\tserver.addTextToLoggingWindow(\"Player (\" + player.getName() + \") got rewarded one attack\");\n\t\t\tserver.sendMessageToClient(player.getName(), \"@134@\" + \"0\" + \"@\");\n\t\t}\n\t\telse if(num >= 90 && num <= 100) {\n\t\t\tplayer.increaseSafeTP();\n\t\t\tserver.addTextToLoggingWindow(\"Player (\" + player.getName() + \") got rewarded one safe teleport\");\n\t\t\tserver.sendMessageToClient(player.getName(), \"@134@\" + \"1\" + \"@\");\n\t\t}\n\t}", "void evadeAttack(IUnit attacker, int incomingDamage);", "public void Reinforcements()\n{\n\tSystem.out.println(\"$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$\");\n\tSystem.out.println(\"$$$$$$$$$$$$$ REINFORCEMENTS $$$$$$$$$$$$$$$$$\\n\\n\");\n\t int answer=1;\n do\n {\n\t System.out.println(name+\", you have \"+wealth+\" gold coins.\\n\" );\n\t System.out.println(\"$$$$$$$$ RATES $$$$$$$$\");\n\t System.out.println(\"1 health potions for 1 gold coin\");\n\t System.out.println(\"An improved weapon for 150 gold coins\");\n\t System.out.println(\"Non-refundable :)\");\n\t System.out.println(\"$$$$$$$$$$$$$$$$$$$$$$$$$\\n\");\n\t\tScanner scan=new Scanner(System.in);\n\n\n\t do\n\t{\n\t if(answer!=0&&answer!=1&&answer!=2)\n\t \tSystem.out.print(\"Error in Input! \");\n\t \tSystem.out.println(\"What would you like to buy (0=nothing/done, 1=health potions, 2=better weapon)?\");\n\t answer=scan.nextInt();\n }while(answer!=0&&answer!=1&&answer!=2);\n\n\n\tif (answer==1)\n\t{\n\t\tint exchange=0;\n\t\t\tdo\n\t\t{\n\t\t\tif(exchange<0||exchange>wealth)\n\t\t\t\tSystem.out.print(\"Error in Input! \");\n\n\t\t\tSystem.out.println(\"How many health potions would you like?(cannot be negative or more than your gold coins)\");\n\t exchange=scan.nextInt();\n\t\t}while(exchange<0||exchange>wealth);\n\n\t\t\twealth-=exchange;\n\t\t\thealth+=exchange;\n\t\t\tSystem.out.println(name+\" increases health by \"+exchange+\" potions.\");\n\t\t\tSystem.out.println(name+\" decreases wealth by \"+exchange+\" gold coins.\\n\");\n\n\t}\n\telse if(answer==2)\n\t{\n\t\tif(weapon<8)\n\t {\n\n\t\t\t weapon++;\n\n\n\t\tif(wealth>=150)\n\t\t{\n\t\t\twealth-=150;\n\n\t\t\tSystem.out.println(name+\"\\'s weapon has been improved to \"+WeaponName(weapon)+\".\");\n\t\t\tSystem.out.println(name+\" decreases wealth by 150 gold coins.\\n\" );\n\t\t}\n\t\telse\n\t\t{\n\t\t\tint temp=wealth;\n\t\t\thealth+=temp-150;\n\t\t\twealth=0;\n\n\t\tSystem.out.println(name+\"\\'s weapon has been improved to \"+WeaponName(weapon));\n\t\tSystem.out.println(name+\" decreases wealth by \"+temp+\" gold coins.\" );\n\t\tSystem.out.println(name+\" decreases health by \"+(150-temp)+\" portions.\\n\");\n\t\t}\n\t }\n\t \telse\n\t {\n\t \t\tweapon=8;\n\t \t\tSystem.out.println(\"You have updated to the most powerful weapon!!!-----\"+WeaponName(weapon)+\".\\n\" );\n\t }\n\n\t }\n\t else\n\t \tanswer=0;\n\n } while(answer!=0);\n}", "private void reviveAttacker() {\n\t\tString type = (mRandom.nextFloat() > mKnightSpawnChance) ? \"normal\" : \"knight\";\n\t\treviveAttacker(type);\n\t}", "@Override\n protected void performActionResults(Action targetingAction) {\n PhysicalCard cardToSteal = targetingAction.getPrimaryTargetCard(targetGroupId);\n\n // Perform result(s)\n action.appendEffect(\n new StealCardToLocationEffect(action, cardToSteal));\n }", "private int attack(int chance, int additionalDamage) {\n if (diceRoll(10) <= chance) { //A statement where we call a diceRoll, if we hit under or equals the chance to hit, we calculate the damage\n int attackValue = player.getAttackValue() * (diceRoll(4) + additionalDamage); //Here we get the players attackValue, which then gets multiplied by a diceRoll + the additionalDamage from the chosen attack\n int damageDealt = 0;\n if (attackValue >= opponent.getArmor()) { //We check if our attackValue is greater than or equals to the opponents armor. If it is not, we don't deal any damage.\n damageDealt = (attackValue - opponent.getArmor()) + 1; //If we attack through the opponents armor, we deal the remaining damage + 1. (if we deal 1 damage and opponent has 1 armor, we still deal 1 damage)\n opponent.changeHealth(damageDealt * -1); //Changes the opponents health\n }\n return damageDealt;\n }\n return -1;\n }", "public void playerAttack() {\n if (playerTurn==true) {\n myMonster.enemHealth=myMonster.enemHealth-battlePlayer.str;\n }\n playerTurn=false;\n enemyMove();\n }", "private void takeDamage(int damage){ health -= damage;}", "public void suffer(int damage){\r\n\t\thp -= damage;\r\n\t\tinvulnerable = true;\r\n\t}", "public InteractionResult interactOn(Entity debug1, InteractionHand debug2) {\n/* 1039 */ if (isSpectator()) {\n/* 1040 */ if (debug1 instanceof MenuProvider) {\n/* 1041 */ openMenu((MenuProvider)debug1);\n/* */ }\n/* 1043 */ return InteractionResult.PASS;\n/* */ } \n/* */ \n/* 1046 */ ItemStack debug3 = getItemInHand(debug2);\n/* */ \n/* 1048 */ ItemStack debug4 = debug3.copy();\n/* 1049 */ InteractionResult debug5 = debug1.interact(this, debug2);\n/* 1050 */ if (debug5.consumesAction()) {\n/* 1051 */ if (this.abilities.instabuild && debug3 == getItemInHand(debug2) && debug3.getCount() < debug4.getCount()) {\n/* 1052 */ debug3.setCount(debug4.getCount());\n/* */ }\n/* 1054 */ return debug5;\n/* */ } \n/* */ \n/* 1057 */ if (!debug3.isEmpty() && debug1 instanceof LivingEntity) {\n/* */ \n/* 1059 */ if (this.abilities.instabuild) {\n/* 1060 */ debug3 = debug4;\n/* */ }\n/* 1062 */ InteractionResult debug6 = debug3.interactLivingEntity(this, (LivingEntity)debug1, debug2);\n/* 1063 */ if (debug6.consumesAction()) {\n/* */ \n/* 1065 */ if (debug3.isEmpty() && !this.abilities.instabuild) {\n/* 1066 */ setItemInHand(debug2, ItemStack.EMPTY);\n/* */ }\n/* 1068 */ return debug6;\n/* */ } \n/* */ } \n/* 1071 */ return InteractionResult.PASS;\n/* */ }", "@Deprecated\n/* */ public static double secondaryParry(Creature performer, double attCheck, Creature defender, Skills defenderSkills, double defCheck, double defBonus, boolean dryrun) {\n/* 2250 */ Item leftWeapon = defender.getLefthandWeapon();\n/* 2251 */ if (leftWeapon != null) {\n/* */ \n/* 2253 */ int secSkillNum = -10;\n/* 2254 */ Skill secWeaponSkill = null;\n/* 2255 */ if (leftWeapon.isBodyPart() && leftWeapon.getAuxData() != 100) {\n/* */ \n/* */ \n/* */ try {\n/* 2259 */ secSkillNum = 10052;\n/* 2260 */ secWeaponSkill = defenderSkills.getSkill(secSkillNum);\n/* */ }\n/* 2262 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 2264 */ if (secSkillNum != -10)\n/* 2265 */ secWeaponSkill = defenderSkills.learn(secSkillNum, 1.0F); \n/* */ } \n/* 2267 */ if (performer.isPlayer() && defender.isPlayer())\n/* */ {\n/* 2269 */ secWeaponSkill = null;\n/* */ }\n/* */ } else {\n/* */ \n/* */ \n/* */ try {\n/* */ \n/* 2276 */ secSkillNum = leftWeapon.getPrimarySkill();\n/* 2277 */ secWeaponSkill = defenderSkills.getSkill(secSkillNum);\n/* */ }\n/* 2279 */ catch (NoSuchSkillException nss) {\n/* */ \n/* 2281 */ if (secSkillNum != -10)\n/* 2282 */ secWeaponSkill = defenderSkills.learn(secSkillNum, 1.0F); \n/* */ } \n/* */ } \n/* 2285 */ if (secWeaponSkill != null) {\n/* */ \n/* 2287 */ float mod = getMod(performer, defender, secWeaponSkill);\n/* 2288 */ defCheck = secWeaponSkill.skillCheck((attCheck * defender.getAttackers() + leftWeapon.getWeightGrams() / 200.0D) / \n/* 2289 */ getWeaponParryBonus(leftWeapon), leftWeapon, defBonus, (mod == 0.0F || dryrun), (float)(long)mod);\n/* */ } \n/* */ } \n/* 2292 */ return defCheck;\n/* */ }", "public void move4(Pokemon enemy){\n boolean crit = false;\n boolean superEffective = false;\n boolean reduced = false;\n boolean moveHit = true;\n int randCrit = (int)(22 * Math.random()+1);\n\n //CHANGE ATTACK TO FALSE IF MOVE DOES NO DAMAGE<<<<<<<<<<<<<\n boolean attack = true;\n //CHANGE TYPE TO TYPE OF MOVE POWER AND ACCURACY<<<<<<<<<<<<<\n String type = \"Steel\";\n int power = 50;\n int accuracy = 95;\n\n //DO NOT CHANGE BELOW THIS\n int damage = ((CONSTANT * power * ( getAtt() / enemy.getDef() )) /50);\n if(randCrit == CONSTANT){\n damage = damage * 2;\n crit = true;\n }\n if(checkSE(type,enemy.getType())){\n damage = damage * 2;\n superEffective = true;\n }\n if(checkNVE(type, enemy.getType())){\n damage = damage / 2;\n reduced = true;\n }\n if(attack && hit(accuracy)){\n enemy.lowerHp(damage);\n }\n else{\n if(hit(accuracy)){\n //DO STATUS EFFECT STUFF HERE (ill figure out later)\n }\n }\n lowerM4PP();\n }", "@Override\n public void use(AbstractPlayer p, AbstractMonster m) {\n addToBot(new DamageAction(m, new DamageInfo(p, damage, damageTypeForTurn), AbstractGameAction.AttackEffect.BLUNT_LIGHT));\n int count = 0;\n for (AbstractMonster monster : AbstractDungeon.getMonsters().monsters) {\n if (!monster.isDeadOrEscaped()) {\n count++;\n }\n }\n if (count > 1) {\n addToBot(new DamageAllEnemiesAction(p, multiDamage, damageTypeForTurn, AbstractGameAction.AttackEffect.BLUNT_LIGHT));\n }\n }" ]
[ "0.6425514", "0.62369215", "0.59717673", "0.5821983", "0.58141315", "0.57949156", "0.5668893", "0.5655456", "0.5645439", "0.5616787", "0.55570334", "0.5535408", "0.54531246", "0.5441185", "0.5397732", "0.5361874", "0.53267276", "0.53246075", "0.53117305", "0.5297498", "0.52767897", "0.52473754", "0.52330565", "0.5223673", "0.5204722", "0.5203929", "0.5200241", "0.5192882", "0.5187781", "0.5169394", "0.51690197", "0.516674", "0.5154967", "0.5151262", "0.51425093", "0.5131108", "0.51245624", "0.5124083", "0.5122222", "0.5118544", "0.5111217", "0.51069325", "0.5096674", "0.5095925", "0.509564", "0.5085735", "0.5080916", "0.50745", "0.5072166", "0.50669193", "0.5063983", "0.5061103", "0.50586164", "0.50514436", "0.50495034", "0.5042318", "0.5039026", "0.50376666", "0.50333166", "0.503184", "0.5016398", "0.5014136", "0.5009064", "0.5003835", "0.49981177", "0.4994347", "0.49890137", "0.49783748", "0.49659747", "0.4963041", "0.49602062", "0.4958882", "0.49569377", "0.49532843", "0.4948976", "0.49452987", "0.49392876", "0.49371085", "0.49369767", "0.49367696", "0.49360994", "0.49301028", "0.49293992", "0.49284998", "0.49241057", "0.4922524", "0.49218175", "0.49205032", "0.49111694", "0.49108514", "0.49105963", "0.49085042", "0.49077785", "0.49048167", "0.49037617", "0.49014348", "0.49000221", "0.48976475", "0.48972872", "0.4894974" ]
0.6371221
1
Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList.
public void addDamage(final L2Character attacker, final int damage) { addDamageHate(attacker, damage, damage); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void addDamageHate(final L2Character attacker, final int damage, int aggro)\n\t{\n\t\tif (attacker == null /* || aggroList == null */)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Get the AggroInfo of the attacker L2Character from the aggroList of the L2Attackable\n\t\tAggroInfoHolder ai = getAggroListRP().get(attacker);\n\t\t\n\t\tif (ai == null)\n\t\t{\n\t\t\tai = new AggroInfoHolder(attacker);\n\t\t\tai.init();\n\t\t\tgetAggroListRP().put(attacker, ai);\n\t\t}\n\t\t\n\t\t// If aggro is negative, its comming from SEE_SPELL, buffs use constant 150\n\t\tif (aggro < 0)\n\t\t{\n\t\t\tai.decHate(aggro * 150 / (getLevel() + 7));\n\t\t\taggro = -aggro;\n\t\t}\n\t\t// if damage == 0 -> this is case of adding only to aggro list, dont apply formula on it\n\t\telse if (damage == 0)\n\t\t{\n\t\t\tai.incHate(aggro);\n\t\t\t// else its damage that must be added using constant 100\n\t\t}\n\t\telse\n\t\t{\n\t\t\tai.incHate(aggro * 100 / (getLevel() + 7));\n\t\t}\n\t\t\n\t\t// Add new damage and aggro (=damage) to the AggroInfo object\n\t\tai.incDmg(damage);\n\t\t\n\t\t// Set the intention to the L2Attackable to AI_INTENTION_ACTIVE\n\t\tif (getAI() != null && aggro > 0 && getAI().getIntention() == CtrlIntention.AI_INTENTION_IDLE)\n\t\t{\n\t\t\tgetAI().setIntention(CtrlIntention.AI_INTENTION_ACTIVE);\n\t\t}\n\t\t\n\t\tai = null;\n\t\t// Notify the L2Attackable AI with EVT_ATTACKED\n\t\tif (damage > 0)\n\t\t{\n\t\t\tif (getAI() != null)\n\t\t\t{\n\t\t\t\tgetAI().notifyEvent(CtrlEvent.EVT_ATTACKED, attacker);\n\t\t\t}\n\t\t\t\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif (attacker instanceof L2PcInstance || attacker instanceof L2Summon)\n\t\t\t\t{\n\t\t\t\t\tL2PcInstance player = attacker instanceof L2PcInstance ? (L2PcInstance) attacker : ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\n\t\t\t\t\tfor (final Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_ATTACK))\n\t\t\t\t\t{\n\t\t\t\t\t\tquest.notifyAttack(this, player, damage, attacker instanceof L2Summon);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tplayer = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\tcatch (final Exception e)\n\t\t\t{\n\t\t\t\tLOGGER.error(\"\", e);\n\t\t\t}\n\t\t}\n\t}", "public void attack()\n {\n getWorld().addObject(new RifleBullet(player.getX(), player.getY(), 1, 6, true), getX(), getY()); \n }", "@Override\n\tpublic void onDamage(WorldObj obj, Items item) {\n\n\t\tif(is_stunned) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tint dmg = (int) item.type.ATK;\n\t\t\n\t\tOnScreenText.AddText(\"\"+dmg, bounds.x , bounds.y + 1.1f);\n\t\t\n\t\tvelX = obj.direction * 5;\n\t\tvelY = 5;\n\t\tgrounded = false;\n\t\t\n\t\tHP -= dmg;\n\t\t\n\n\t\tstun_counter = 0;\n\t\t\n\t\tif(HP <= 0 && !isDead) {\n\t\t\tonDeath();\n\t\t}\n\t\t\n\t}", "public void addHabitatAttack(Habitat habitat, Habitat target) {\r\n\t\tif (!habitatToTargetList.containsKey(habitat.getID()+\"\")) habitatToTargetList.put(habitat.getID()+\"\", new ArrayList<Habitat>());\r\n\t\t\r\n\t\t// add attack\r\n\t\thabitatToTargetList.get(habitat.getID()+\"\").add(target);\r\n\t}", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "public void OnDamage(AI ai, int aTK, float f) {\n\tif(DamagedTimer < 0.8f)\n\t\treturn;\n\tvel.x = f;\n\tvel.y = 3;\n\tDamagedTimer = 0;\n\tgrounded = false;\n\taTK -= (getDEF()*0.8f);\n\tif(aTK <= 0)\n\t\taTK = 1;\n\tHP -= aTK;\n\tInventory.CurrentInventory.dmgTxts.add(new dmgText(pos.x, pos.y+1, aTK));\n\t\n\tSoundManager.PlaySound(\"playerHurt\",3);\n\t\n\t\n}", "public void AIDamage() {\r\n\t\tif (attackStyle == 2) {\r\n\t\t\tfor(int i = 0; i < AIObject.length; i++) {\r\n\t\t\t\tif ((inFlight) && (Math.abs(aX-AIObject[i].getAIX()) < 5) && (Math.abs(aY-AIObject[i].getAIY())) < 4 ) {\r\n\t\t\t\t\tAIObject[i].setHealth(-25 * damageReduction);\r\n\t\t\t\t\tdrawArrow = false;\r\n\t\t\t\t\tcooldown = 15;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}else {\r\n\t\t\tif (mouseLeft) {\r\n\t\t\t\tfor(int i = 0; i < AIObject.length; i++){\r\n\t\t\t\t\tif ((drawSword) && (cooldown == 0) && (playerObject[0].getX() -AIObject[i].getAIX() <85) && (playerObject[0].getX()-AIObject[i].getAIX() >-1) && (playerObject[0].getY() - AIObject[i].getAIY() < 20) && (playerObject[0].getY()-AIObject[i].getAIY()>-5)) {\r\n\t\t\t\t\t\tAIObject[i].setHealth(-50 * damageReduction);\r\n\t\t\t\t\t\tcooldown = 5;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}else {\r\n\t\t\t\tfor(int i=0; i < AIObject.length; i++){\r\n\t\t\t\t\tif ((drawSword) && (cooldown == 0) && (AIObject[i].getAIX()-playerObject[0].getX() <85) && (AIObject[i].getAIX() - playerObject[0].getX() > -1) && (playerObject[0].getY() - AIObject[i].getAIY() < 20) && (playerObject[0].getY()-AIObject[i].getAIY()>-5)) {\r\n\t\t\t\t\t\tAIObject[i].setHealth(-50 * damageReduction);\r\n\t\t\t\t\t\tcooldown = 5;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\tfor(int i=0; i < AIObject.length; i++){\r\n\t\t\t//checks if AI is close enough to attack with melee\r\n\t\t\tfor (int j = 0; j < playerObject.length; j++) {\r\n\t\t\t\tif ((!shield) && (Math.abs(AIObject[i].getAIX() - playerObject[j].getX()) <= 10) && (Math.abs(AIObject[i].getAIY() - playerObject[j].getY())) <= 3) {\r\n\t\t\t\t\tplayerObject[j].setHealth(DAMAGE_AMOUNT * difficulty);\r\n\t\t\t\t\tif (playerObject[j].getHealth() <= 0) {\r\n\t\t\t\t\t\tdead = true;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "private void enemyAttack() {\n\t\t\n\t\tRandom rand = new Random();\t\n\t\t\n\t\tint roll = rand.nextInt(101);\n\t\t\n\t\tint sroll = rand.nextInt(101);\n\t\t\n\t\tevents.appendText(e.getName() + \" attacks!\\n\");\n\t\t\n\t\tif(roll <= p.getEV()) { // Player evades\n\t\t\t\n\t\t\tevents.appendText(\"You evaded \"+e.getName()+\"\\'s Attack!\\n\");\n\t\t\t\n\t\t}else if(roll > p.getEV()) { // Player is hit and dies if HP is 0 or less\n\t\t\t\n\t\t\tp.setHP(p.getHP() - e.getDMG());\n\t\t\t\n\t\t\tString newHp = p.getHP()+\"/\"+p.getMaxHP();\n\t\t\t\n\t\t\tString effect = e.getSpecial(); // Stats are afflicted\n\t\t\t\n\t\t\tif(sroll < 51){\n\t\t\t\t\n\t\t\tif(effect == \"Bleed\") { // Bleed Special\n\t\t\t\t\n\t\t\t\tp.setHP(p.getHP() - 100);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You bleed profusely. - 100 HP\\n\");\n\t\t\t\t\n\t\t\t\tnewHp = String.valueOf(p.getHP()+\"/\"+p.getMaxHP());\n\t\t\t}\n\t\t\tif(effect == \"Break\") { // Break Special \n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You feel a bone break restricting movement. - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Fear\") { // Fear Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-40>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 40);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"A crippling fear rattles your resolve. - 40 DMG\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Rend\") { // Rend Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-30>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 30);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"Morthar unleashes a pillar of flame! - 30 DMG and - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\t\n\t\t\tif(p.getHP() <= 0) {\n\t\t\t\t\n\t\t\t\tp.setDead(true);\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(0+\"/\"+e.getMaxHP());\n\t\t\t\tplayerHPBar.setProgress((double)0);\n\t\t\t}else {\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(newHp);\n\t\t\t\tplayerHPBar.setProgress((double)p.getHP()/p.getMaxHP());\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tif(p.isDead()) { // Game over if player dies\n\t\t\t\n\t\t\ttry {\n\t\t\t\tLoadGO();\n\t\t\t} catch (IOException e1) {\n\t\t\t\n\t\t\t\te1.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t\tcombat = false;\n\t\t}\n\t}", "private void addEnemySheild() {\n this.enemyShield += 1;\n }", "public void battleAllyAttack() {\n if(battleAlly instanceof Character){\n battleTickStatuses();\n updateBattleSides();\n }\n\n // battleAlly now attacks targetEnemy or preference based on the type of battleAlly\n if(battleAlly != null){ // If all allies have attacked, they cannot attack anymore for this round\n MovingEntity target = battleAlly.getAttackPreference(targetEnemies);\n // if not picky, get preference is the default next target\n if(target == null) {\n target = targetEnemy;\n }\n battleAlly.attack(target, targetAllies, targetEnemies);\n //System.out.println(battleAlly.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still unfriendly\n targetEnemy = checkSideSwap(targetEnemy, true, battleAllies, targetAllies, battleEnemies, targetEnemies);\n }\n battleAlly = nextAttacker(battleAlly, battleAllies);\n\n }\n }", "public void ability(LevelManager lm){\n\n int prevDamage = lm.player.getDamage();\n int newDamage = prevDamage+12;\n lm.player.setDamage(newDamage);\n }", "public void attack() {\n energy = 2;\n redBull = 0;\n gun = 0;\n target = 1;\n // if Player is in range take off a life.\n if (CharacterTask.ghostLocation == GameWindow.playerLocation) {\n playerLives = playerLives - 1;\n System.out.println(\"Player Lives: \" + playerLives);\n }\n }", "@Override\n\tprotected void calculateRewards(final L2Character lastAttacker)\n\t{\n\t\t// Creates an empty list of rewards\n\t\tfinal Map<L2Character, RewardInfoHolder> rewards = new ConcurrentHashMap<>();\n\t\t\n\t\ttry\n\t\t{\n\t\t\tif (getAggroListRP().isEmpty())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (EngineModsManager.onNpcExpSp(this, lastAttacker))\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tL2PcInstance maxDealer = null;\n\t\t\tint maxDamage = 0;\n\t\t\t\n\t\t\tint damage;\n\t\t\t\n\t\t\tL2Character attacker, ddealer;\n\t\t\t\n\t\t\t// While Interacting over This Map Removing Object is Not Allowed\n\t\t\tsynchronized (getAggroList())\n\t\t\t{\n\t\t\t\t// Go through the aggroList of the L2Attackable\n\t\t\t\tfor (final AggroInfoHolder info : getAggroListRP().values())\n\t\t\t\t{\n\t\t\t\t\tif (info == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Get the L2Character corresponding to this attacker\n\t\t\t\t\tattacker = info.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Get damages done by this attacker\n\t\t\t\t\tdamage = info.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// Prevent unwanted behavior\n\t\t\t\t\tif (damage > 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (attacker instanceof L2SummonInstance || attacker instanceof L2PetInstance && ((L2PetInstance) attacker).getPetData().getOwnerExpTaken() > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = info.getAttacker();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check if ddealer isn't too far from this (killed monster)\n\t\t\t\t\t\tif (!Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, ddealer, true))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate real damages (Summoners should get own damage plus summon's damage)\n\t\t\t\t\t\tRewardInfoHolder reward = rewards.get(ddealer);\n\t\t\t\t\t\tif (reward == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward = new RewardInfoHolder(ddealer, damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward.addDamage(damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\trewards.put(ddealer, reward);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (ddealer instanceof L2PlayableInstance && ((L2PlayableInstance) ddealer).getActingPlayer() != null && reward.getDmg() > maxDamage)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tmaxDealer = ((L2PlayableInstance) ddealer).getActingPlayer();\n\t\t\t\t\t\t\tmaxDamage = reward.getDmg();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// Manage Base, Quests and Sweep drops of the L2Attackable\n\t\t\tdoItemDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\t// Manage drop of Special Events created by GM for a defined period\n\t\t\tdoEventDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\tif (!getMustRewardExpSP())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (!rewards.isEmpty())\n\t\t\t{\n\t\t\t\tL2Party attackerParty;\n\t\t\t\tlong exp;\n\t\t\t\tint levelDiff, partyDmg, partyLvl, sp;\n\t\t\t\tfloat partyMul, penalty;\n\t\t\t\tRewardInfoHolder reward2;\n\t\t\t\tint[] tmp;\n\t\t\t\t\n\t\t\t\tfor (final RewardInfoHolder reward : rewards.values())\n\t\t\t\t{\n\t\t\t\t\tif (reward == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Penalty applied to the attacker's XP\n\t\t\t\t\tpenalty = 0;\n\t\t\t\t\t\n\t\t\t\t\t// Attacker to be rewarded\n\t\t\t\t\tattacker = reward.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Total amount of damage done\n\t\t\t\t\tdamage = reward.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// If the attacker is a Pet, get the party of the owner\n\t\t\t\t\tif (attacker instanceof L2PetInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PetInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse if (attacker instanceof L2PcInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PcInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If this attacker is a L2PcInstance with a summoned L2SummonInstance, get Exp Penalty applied for the current summoned L2SummonInstance\n\t\t\t\t\tif (attacker instanceof L2PcInstance && ((L2PcInstance) attacker).getPet() instanceof L2SummonInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tpenalty = ((L2SummonInstance) ((L2PcInstance) attacker).getPet()).getExpPenalty();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// We must avoid \"over damage\", if any\n\t\t\t\t\tif (damage > getMaxHp())\n\t\t\t\t\t{\n\t\t\t\t\t\tdamage = getMaxHp();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If there's NO party in progress\n\t\t\t\t\tif (attackerParty == null)\n\t\t\t\t\t{\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\tif (attacker.getKnownList().knowsObject(this))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// Calculate the difference of level between this attacker (L2PcInstance or L2SummonInstance owner) and the L2Attackable\n\t\t\t\t\t\t\t// mob = 24, atk = 10, diff = -14 (full xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 28, diff = 4 (some xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 50, diff = 26 (no xp)\n\t\t\t\t\t\t\tlevelDiff = attacker.getLevel() - getLevel();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, damage);\n\t\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\t\texp *= 1 - penalty;\n\t\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Check for an over-hit enabled strike and VIP options\n\t\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif (player.isVIP())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\texp = (long) (exp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t\tsp = (int) (sp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Distribute the Exp and SP between the L2PcInstance and its L2Summon\n\t\t\t\t\t\t\tif (!attacker.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tattacker.addExpAndSp(Math.round(attacker.calcStat(Stats.EXPSP_RATE, exp, null, null)), (int) attacker.calcStat(Stats.EXPSP_RATE, sp, null, null));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t// share with party members\n\t\t\t\t\t\tpartyDmg = 0;\n\t\t\t\t\t\tpartyMul = 1.f;\n\t\t\t\t\t\tpartyLvl = 0;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Get all L2Character that can be rewarded in the party\n\t\t\t\t\t\tfinal List<L2PlayableInstance> rewardedMembers = new ArrayList<>();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Go through all L2PcInstance in the party\n\t\t\t\t\t\tList<L2PcInstance> groupMembers;\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getCommandChannel().getMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getPartyMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tfor (final L2PcInstance pl : groupMembers)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (pl == null || pl.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Get the RewardInfo of this L2PcInstance from L2Attackable rewards\n\t\t\t\t\t\t\treward2 = rewards.get(pl);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// If the L2PcInstance is in the L2Attackable rewards add its damages to party damages\n\t\t\t\t\t\t\tif (reward2 != null)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add L2PcInstance damages to party damages\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\trewards.remove(pl); // Remove the L2PcInstance from the L2Attackable rewards\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t// Add L2PcInstance of the party (that have attacked or not) to members that can be rewarded\n\t\t\t\t\t\t\t\t// and in range of the monster.\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfinal L2PlayableInstance summon = pl.getPet();\n\t\t\t\t\t\t\tif (summon != null && summon instanceof L2PetInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\treward2 = rewards.get(summon);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (reward2 != null) // Pets are only added if they have done damage\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, summon, true))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add summon damages to party damages\n\t\t\t\t\t\t\t\t\t\trewardedMembers.add(summon);\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tif (summon.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = summon.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\trewards.remove(summon); // Remove the summon from the L2Attackable rewards\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// If the party didn't killed this L2Attackable alone\n\t\t\t\t\t\tif (partyDmg < getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyMul = (float) partyDmg / (float) getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Avoid \"over damage\"\n\t\t\t\t\t\tif (partyDmg > getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyDmg = getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate the level difference between Party and L2Attackable\n\t\t\t\t\t\tlevelDiff = partyLvl - getLevel();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, partyDmg);\n\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\texp *= partyMul;\n\t\t\t\t\t\tsp *= partyMul;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check for an over-hit enabled strike\n\t\t\t\t\t\t// (When in party, the over-hit exp bonus is given to the whole party and splitted proportionally through the party members)\n\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Distribute Experience and SP rewards to L2PcInstance Party members in the known area of the last attacker\n\t\t\t\t\t\tif (partyDmg > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tattackerParty.distributeXpAndSp(exp, sp, rewardedMembers, partyLvl);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t}", "public void actionCombat(Party p1) {\n System.out.println(\"______________________________________________________________________________\\n\");\n System.out.println(this.Name + \" is attacking ...\");\n int choice = (int)(Math.random() * p1.getTeam().size());\n Character target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n\n if (this.SPEED - target.getSPEED() < 5) {\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n }\n else {\n int n = 0;\n while ((target.actualHP != 0) && (n < 2)) {\n if (n == 1) {\n choice = (int)(Math.random() * p1.getTeam().size() + 1);\n target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n }\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n if (n == 0) System.out.println(this.Name + \" attacks again ...\");\n n++;\n }\n }\n }", "public void incrementAttack(Fighter f1, Fighter f2)\r\n {\r\n if(f1.getAttacking() == 1) //if the fighter is attacking\r\n {\r\n if(f1.getAttackT() == 5) //if 5 frames have passed\r\n {\r\n int[] i = new int[4]; \r\n i = attackHitBox(f1); //gets the x,y, height, and width of the attack\r\n \r\n //if the attack position overlapps the other fighter's position and the other fighter isn't blocking\r\n if (i[0] <= f2.getPos()[0] + f2.getSize() && i[0] + i[2] >= f2.getPos()[0] && i[1] <= f2.getPos()[1] + f2.getSize() && i[1] + i[3] >= f2.getPos()[1] && f2.getBlocking() != 1)\r\n {\r\n f2.setHealth(f2.getHealth() - f1.getAttack().getDamage()); //deal damage to the fighter\r\n if(f1.getRight() == true){ \r\n f2.setKnockBackVel(f1.getAttack().getKnockBack()[0],f1.getAttack().getKnockBack()[1]); //apply knockback going right\r\n }else\r\n {\r\n f2.setKnockBackVel(-f1.getAttack().getKnockBack()[0],f1.getAttack().getKnockBack()[1]); //apply knockback going left\r\n }\r\n }\r\n f1.setAttackT(0); //reset attack timer\r\n f1.setAttacking(2); //sets the fighter to cooldown\r\n }else\r\n {\r\n f1.setAttackT(f1.getAttackT() + 1); //increments timer\r\n }\r\n }\r\n\r\n if(f1.getAttacking() == 2) //if fighter is in cooldown\r\n {\r\n if(f1.getAttackT() == f1.getAttack().getTime()) //if the timer has waited the cooldown of the last attack\r\n {\r\n f1.setAttackT(0); //resets the timer\r\n f1.setAttacking(0); //sets the fighter to \"can attack\"\r\n }\r\n else\r\n {\r\n f1.setAttackT(f1.getAttackT() + 1); //increment timer\r\n }\r\n }\r\n }", "@Override\n\tpublic void addInformation(ItemStack is, EntityPlayer player, List l, boolean b){\n\t\tl.add(\"This staff is magical!\");\n\t}", "float shouldAggroOnHit(IGeneticMob geneticMob, EntityLiving attacker);", "public void battleEnemyAttack() {\n if(battleEnemy != null){ // If all enemies have attacked, they cannot attack anymore for this round\n\n MovingEntity target = battleEnemy.getAttackPreference(targetAllies);\n if(target == null){\n target = targetAlly;\n }\n\n battleEnemy.attack(target, targetEnemies, targetAllies);\n //System.out.println(battleEnemy.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still friendly incase of zombify\n targetAlly = checkSideSwap(targetAlly, false, battleEnemies, targetEnemies, battleAllies, targetAllies);\n }\n\n battleEnemy = nextAttacker(battleEnemy, battleEnemies);\n\n }\n }", "@Override\n public void attack(Entity e) {\n e.hit(atk);\n }", "public void attack(ItemWeapon w, Monster target) {\n\t\ttarget.takeDamage(w.getDamage()+level*20);\n\t}", "@Override\n\tpublic void skill2(Fightable f) {\n\t\tsuper.setDamage(super.getStrength()*2);\n\t\tsuper.setAtkRange((int)(super.getDamage()/10));\n\t\t\n\t\tthis.attack(f, 3);\n\t}", "private float setAttackAbsorption(HashMap content) {\n\t\tfloat change = calculateAbsorption();\n this.attackDamageModifier = baseDamageModifier + change;\n//System.out.println(\"attack: \" + this.attackDamageModifier);\n content.put(\"attack_damage_modifier\", \"\" + this.attackDamageModifier);\n\t\treturn change*ABSORPTION_PRICE_MULTIPLIER;\n }", "protected void onImpact(RayTraceResult result) {\n\t\tif (result.entityHit != null) {\n\t\t\tfloat i = 2.5F;\n\n\t\t\tif (result.entityHit instanceof EntityBlizzard) {\n\t\t\t\ti = 0;\n\t\t\t}\n\n result.entityHit.attackEntityFrom(WorldsRetold.HAIL, i);\n\n\t\t\tif (result.entityHit instanceof EntityLivingBase) {\n\t\t\t\tEntityLivingBase target = (EntityLivingBase) result.entityHit;\n\t\t\t\tif (!this.world.isRemote) {\n\t\t\t\t\ttarget.addPotionEffect(new PotionEffect(HailstormPotions.FREEZING, 100, 0));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (!this.world.isRemote) {\n\t\t\tthis.world.setEntityState(this, (byte) 3);\n\t\t\tthis.setDead();\n\t\t}\n\t}", "@Override\r\n public void onHit(int damage){\n if(box2body != null){\r\n hp -= damage;\r\n screen.getGameManager().get(\"Sounds/orc-34-hit.wav\", Sound.class).play();\r\n if(this.hp <= 0) {\r\n screen.bodiesToDelete.add(box2body);\r\n deleteFlag = true;\r\n screen.spawnedCreatures.remove(this);\r\n screen.getGameManager().get(\"Sounds/orc-32-death.wav\", Sound.class).play();\r\n\r\n //Award Experience\r\n screen.getPlayer().awardExperience(this.experienceValue);\r\n screen.getPlayer().increaseKillCount();\r\n }\r\n }\r\n //Attack player when damaged\r\n //Prevents player from sniping monsters using Wander AI\r\n if(currentState != State.ATTACKING){\r\n Vector2 orcPosition = new Vector2(box2body.getPosition().x, box2body.getPosition().y);\r\n Vector2 playerPosition = new Vector2(screen.getPlayer().box2body.getPosition().x, screen.getPlayer().box2body.getPosition().y);\r\n\r\n currentState = State.HASBEENATTACKED;\r\n velocity = new Vector2(playerPosition.x - orcPosition.x, playerPosition.y - orcPosition.y);\r\n box2body.setLinearVelocity(velocity.scl(speed));\r\n }\r\n }", "@SideOnly(Side.CLIENT)\r\n @Override\r\n public void addInformation(ItemStack stack, @Nullable World playerIn, List<String> list, ITooltipFlag advanced)\r\n {\r\n if (stack.hasTagCompound() && stack.getTagCompound().hasKey(\"dyeColour\"))\r\n {\r\n int damage = stack.getTagCompound().getInteger(\"dyeColour\");\r\n EnumDyeColor colour = EnumDyeColor.byDyeDamage(damage);\r\n String s = I18n.format(colour.getUnlocalizedName());\r\n list.add(s);\r\n }\r\n }", "public void shoot(){\n // boss bullete attract to player\n int bulletPosX = PApplet.parseInt(posX + (speed * cos(angle)));\n int bulletPosY = (int)(posY + hei / 2);\n float bulletAngle = atan2(Main.player.posY - bulletPosY, Main.player.posX - bulletPosX);\n int bulletVelX = (int)(8 * cos(bulletAngle));\n int bulletVelY = (int)(8 * sin(bulletAngle));\n bossBullets.add(new Bullet(bulletPosX,bulletPosY,bulletVelX,bulletVelY,1,attack));\n }", "public void hit(int melee_dmg,int range_dmg) {\n melee_dmg=this.current_atk-30;\n range_dmg=this.current_atk-60;\n }", "void addAttack(AttackObject newAttack) {\n if (canAddAttack(newAttack)) {\n attacksToAdd.add(newAttack);\n if(newAttack.isPlayerAttack()){\n playerAttackCount++;\n }\n }\n }", "int aggroHitTimer(IGeneticMob geneticMob, EntityLiving attacker);", "public void addAbsorber(final L2PcInstance attacker, final int crystalId)\n\t{\n\t\t// This just works for targets like L2MonsterInstance\n\t\tif (!(this instanceof L2MonsterInstance))\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// The attacker must not be null\n\t\tif (attacker == null)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// This L2Attackable must be of one type in the absorbingMOBS_levelXX tables.\n\t\t// OBS: This is done so to avoid triggering the absorbed conditions for mobs that can't be absorbed.\n\t\tif (getAbsorbLevel() == 0)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// If we have no absorbersList initiated, do it\n\t\tAbsorberInfo ai = absorbersList.get(attacker);\n\t\t\n\t\t// If the L2Character attacker isn't already in the absorbersList of this L2Attackable, add it\n\t\tif (ai == null)\n\t\t{\n\t\t\tai = new AbsorberInfo(attacker, crystalId, getCurrentHp());\n\t\t\tabsorbersList.put(attacker, ai);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tai.absorber = attacker;\n\t\t\tai.crystalId = crystalId;\n\t\t\tai.absorbedHP = getCurrentHp();\n\t\t}\n\t\t\n\t\t// Set this L2Attackable as absorbed\n\t\tabsorbSoul();\n\t\t\n\t\tai = null;\n\t}", "public void attack(User p)\n\t{\n\t\tint damage = getAttack() - p.getDefense();\n\t\tint evade = 0;\n\t\tif(damage <= 0)\n\t\t{\n\t\t\tevade = p.getDefense() - getAttack();\n\t\t\tdamage = 1;\n\t\t}\n\t\t\n\t\tif(Math.random() * 100 < evade * 5)\n\t\t{\n\t\t\tJOptionPane.showMessageDialog(null, \"Miss\");\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tp.reduce(damage);\n JOptionPane.showMessageDialog(null,\"Enemy attacked you! User's health = \" + p.getHealth() + \"\\n\" + \"Damage dealt = \" + damage); \n\t}", "public void attack() {\n\t\t\n\t\tint row = getPosition().getRow();\n\t\tint column = getPosition().getColumn();\n\t\t\n\t\tgetPosition().setCoordinates(row + 1, column);\n\t\tsetPosition(getPosition()) ;\n\t\t// restore health\n\t\tsetHealth(100);\n\t\t// end hunter mode\n\t\tthis.hunter = false;\n\t\t\n\t}", "public void update(ArrayList<Bullet> projectileList, ArrayList<ZOrderableSprite> zOrderableSpriteList) {\n\n // Increment AI timer\n aiTimer += Gdx.graphics.getDeltaTime();\n aiTimer2 += Gdx.graphics.getDeltaTime();\n // Increment attack timer\n attackTimer += Gdx.graphics.getDeltaTime();\n // 0: Random Walking AI: the enemie will either stay idle or walk around randomly\n if(aiType == 0) {\n // hostile: false\n randomWalkingAI(false, null, null);\n }\n /*\n 1: Hostile random Walking AI: the enemie will attack the player is close enough,\n else the enemie will either stay idle or walk around randomly\n */\n else if(aiType == 1) {\n // Hostile\n randomWalkingAI(true, projectileList, zOrderableSpriteList);\n }\n\n // Update animations\n animation.update();\n\n // Update particles\n updateParticles();\n\n // Update enemie position\n updatePosition();\n\n // Update hp bar\n hpBar.update(currentHp, maximumHp, currentShield, maximumShield);\n hpBar.updatePosition(hitbox.getX(), hitbox.getY() - 7);\n\n // Enemie will shine red light when damaged\n\t\tif(colorValue < 1) {\n\t\t\tcolorValue += Gdx.graphics.getDeltaTime() * 2;\n\t\t}\n }", "private void UpdateBullets()\n\t {\n\t for(int i = 0; i < BulletList.size(); i++)\n\t {\n\t Bullet bullet = BulletList.get(i);\n\t \n\t // Move the bullet.\n\t bullet.Update();\n\t \n\t // checks if the bullet has it left the screen\n\t if(bullet.HasLeftScreen()){\n\t BulletList.remove(i);\n\t \n\t continue;\n\t }\n\t \n\t // checks if the bullet hit the enemy\n\t Rectangle BulletRectangle = new Rectangle((int)bullet.xCoord, (int)bullet.yCoord, bullet.BulletImage.getWidth(), bullet.BulletImage.getHeight());\n\t // Go trough all enemies.\n\t for(int j = 0; j < EnemyList.size(); j++)\n\t {\n\t Enemy eh = EnemyList.get(j);\n\n\t \n\t Rectangle EnemyRectangel = new Rectangle(eh.xCoord, eh.yCoord, eh.EnemyHelicopterImage.getWidth(), eh.EnemyHelicopterImage.getHeight());\n\n\t // Checks whether the the bullet has hit the enemy\n\t if(BulletRectangle.intersects(EnemyRectangel))\n\t {\n\t // Bullet hit the enemy so we reduce his health.\n\t eh.Health -= Bullet.DamagePower;\n\t \n\t // Bullet was also destroyed so we remove it.\n\t BulletList.remove(i);\n\t \n\t \n\t }\n\t }\n\t }\n\t }", "public void addGold(int g){\n this.gold += g;\n }", "public void gettingAttacked(HitByBulletEvent e) {\r\n\t\tif (gotTarget) {\r\n\t\t\tfor (int i = 0; i < enemyTracker.getEnemyList().size(); i++) {\r\n\t\t\t\tif (enemyTracker.getEnemyList().get(i).getName().equals(e.getName()) && (!e.getName().equals(radarTarget.getName()))) {\r\n\t\t\t\t\t\tmrRobot.sendMessage(5, \"2\");\r\n\t\t\t\t\t\tradarTarget = enemyTracker.getEnemyList().get(getIndexForEnemy(e.getName()));\r\n\t\t\t\t\t\ttargetTracking.get(getIndexForName(mrRobot.getName())).updateTarget(radarTarget);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "void evadeAttack(IUnit attacker, int incomingDamage);", "@Override\n public void onTargetDamaged(LivingEntity user, Entity target, int level) {\n if(target instanceof LivingEntity) {\n\n //target.damage(DamageSource.LAVA, 3F);\n knockUp((PlayerEntity) user, (LivingEntity) target, 3F);\n }\n }", "public void givePlayerLevelBonus() {\n\t\tfor(Player p : playerList) {\n\t\t\tif(p.getType() == PlayerType.Agent) {\n\t\t\t\tp.addScore(5 * (currentLevel-1));\n\t\t\t}\n\t\t}\n\t\tserver.updateHighscoreList();\n\t\tserver.addTextToLoggingWindow(\"Server gives all players level bonus\");\n\t}", "@Override\n\tpublic void processIncommingHit(Hit hit, Entity target) {\n\t\tif (hit.getLook() == HitLook.MELEE_DAMAGE)\n\t\t\tmeleeDamage += hit.getDamage();\n\t\telse if (hit.getLook() == HitLook.RANGE_DAMAGE)\n\t\t\trangeDamage += hit.getDamage();\n\t\tif (hit.getLook() == HitLook.MAGIC_DAMAGE)\n\t\t\tmageDamage += hit.getDamage();\n\t}", "void takeDamage(HeroDamage enemy1, HeroDamage enemy2);", "public void applyEffects(GoodGuy gg) {\n\t\tif (gemType == 1) {\n\t\t\tgg.addHP(20);\n\t\t} else if (gemType == 2) {\n\t\t\tgg.addHP(50);\n\t\t} else if (gemType == 3) {\n\t\t\tgg.addStamina(20);\n\t\t} else if (gemType == 4) {\n\t\t\tgg.addStamina(50);\n\t\t} else {\n\t\t\tint mhp = gg.getMaxHP();\n\t\t\tint mst = gg.getMaxHP();\n\t\t\tgg.addHP(mhp);\n\t\t\tgg.addStamina(mst);\n\t\t}\n used = true;\n\t}", "public void addHitListenerToEnemy(HitListener hl) {\r\n for (Enemy e : enemies) {\r\n e.addHitListener(hl);\r\n }\r\n }", "@Override\n\t\tpublic void hit(Npc attacker, Mob defender, Hit hit) {\n\t\t}", "public void addDamage(int amount) {\n\t\tdamage = amount;\n\t}", "@Override\n\tpublic int fight(Enemy e1) {\n\t\tint damage = 0;\n\t\tRandom randomNum = new Random();\n\t\tdamage = 6 + randomNum.nextInt(4);\n\t\ttry {\n\t\t\te1.takeDamage(damage);\n\t\t} catch (InvalidDamageException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn damage;\n\t}", "public final Map<L2Character, AggroInfoHolder> getAggroList()\n\t{\n\t\treturn aggroList;\n\t}", "public void shootAimingBullet(){\n bossBullet = new BossBullet(bossBulletImage,this.getXposition() + 100, this.getYposition() + 100, 8, player, true);\n bulletList.add(bossBullet);\n }", "private void addAttacks(){\n while(!attacksToAdd.isEmpty()){\n attacks.add(attacksToAdd.remove());\n }\n }", "AbilityDamage getAbilityDamage();", "@Override\r\n\tpublic boolean damageEntity(DamageSource damagesource, float f2) {\n\t\tboolean toReturn = super.damageEntity(damagesource, f2);\r\n\t\tif(f2>=3 && !this.isInvulnerable(damagesource) && damagesource.getEntity()!=null && damagesource.getEntity().getBukkitEntity() instanceof Player) { // prevent things like snowball damage from triggering this ability\r\n\t\t\tif(random.nextInt(100)+1<=20) { //prevent boss from getting combo'd to hard in corner\r\n\t\t\t\tif(!teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity())) {\r\n\t\t\t\t\tteleportToEnemy();\t\t\r\n\t\t\t\t\tteleportCooldown.addCooldown((Player)damagesource.getEntity().getBukkitEntity());\r\n\t\t\t\t\tLog.info(teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity()));\r\n\t\t\t\t\tLog.info(((Player)damagesource.getEntity().getBukkitEntity()).getName());\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn toReturn;\r\n\t}", "public void displayDamageIndicator(Graphics2D g2d) {\n //so the damage indicator won't turn translucent\n g2d.setComposite(AlphaComposite.getInstance(AlphaComposite.SRC_OVER,\n 1f));\n this.damageIndicator.display(g2d, this.damageTaken);\n }", "@Override\n\t\t\tpublic void attack(Base enemy) {\n\t\t\t}", "public void attack() { \n db.attack(creatures.get(creatureId), players.get(playerId));\n creatures.set(creatureId, db.getCreature(creatures.get(creatureId).getId()));\n players.set(playerId, db.getPlayer(players.get(playerId).getId()));\n setTextFields();\n }", "public void applyEffectUser(Enemy user) {\n\t\tsuper.applyEffectsUser(user);\n\t\tuser.addEnrage(enrage);\n\t}", "@Override\n\tpublic void updateContext(ExtendedAgentContext bc) {\n\t\tHero h = bc.getHero();\n\t\tAbility lagunaBlade = h.getAbility(5);\n\n\t\tList<BaseEntity> entitiesInAttackRange = bc.findEntitiesInRadius(h, lagunaBlade.getCastRange());\n\n\t\tArrayList<BaseEntity> heroesInRange = new ArrayList<>();\n\t\tfor (BaseEntity e : entitiesInAttackRange) {\n\t\t\tif (e.getTeam() == bc.getEnemyTeam()) {\n\t\t\t\tif (e.isHero()) {\n\t\t\t\t\theroesInRange.add((BaseEntity) e);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tBaseEntity woundedHero = null;\n\t\tif (heroesInRange.size() > 0)\n\t\t\twoundedHero = heroesInRange.stream().min((a, b) -> Integer.compare(a.getHealth(), b.getHealth())).get();\n\n\t\tTarget target = new Target();\n\t\ttarget.setEntity(woundedHero);\n\t\ttarget.setAbility(h.getAbility(0));\n\t\tthis.context.setTarget(target);\n\t}", "@Override\n\tpublic void onAdd(final CSimulation game, final CUnit unit) {\n\t\tfinal List<CUnitAttack> unitSpecificAttacks = unit.getUnitSpecificAttacks();\n\t\tfinal int originalAttackCount = unitSpecificAttacks.size();\n\t\toriginalBaseAttackRates = new float[originalAttackCount];\n\t\tfor (int i = 0; i < originalAttackCount; i++) {\n\t\t\tfinal CUnitAttack originalAttack = unitSpecificAttacks.get(i);\n\t\t\toriginalBaseAttackRates[i] = originalAttack.getCooldownTime();\n\t\t}\n\t\tunit.setDisableAttacks(true);\n\t\tsuper.onAdd(game, unit);\n\t}", "@Override\n public void addDamage(Player shooter, int damage) {\n if(!this.equals(shooter) && damage > 0) {\n int num=0;\n boolean isRage = false;\n Kill lastKill = null;\n List<PlayerColor> marksToBeRemoved = marks.stream().filter(m -> m == shooter.getColor()).collect(Collectors.toList());\n damage += marksToBeRemoved.size();\n marks.removeAll(marksToBeRemoved);\n\n if (this.damage.size() < 11) { //11\n for (int i = 0; i < damage; i++)\n this.damage.add(shooter.getColor());\n num = this.damage.size();\n if (num > 10) { //10\n this.deaths++;\n this.isDead = true;\n if (num > 11) {\n isRage = true;\n shooter.addThisTurnMarks(this, 1); //the shooter receive a mark in case of rage\n }\n if (game != null)\n game.addThisTurnKill(shooter, this, isRage);\n\n } else if (num > 5)\n this.adrenaline = AdrenalineLevel.SHOOTLEVEL;\n else if (num > 2)\n this.adrenaline = AdrenalineLevel.GRABLEVEL;\n } else if (this.damage.size() == 11 && damage > 0) { //11\n lastKill = game.getLastKill(this);\n lastKill.setRage(true);\n shooter.addThisTurnMarks(this, 1); //the shooter receive a mark in case of rage\n if(game != null)\n game.notifyRage(lastKill);\n }\n if (game != null)\n game.notifyDamage(this, shooter, damage, marksToBeRemoved.size());\n }\n }", "@Override\n public void attack(){\n int xBullet=0,yBullet=0;\n switch(direction){\n case 0:\n xBullet=(int)(x+Sprite.python_left.getWidth()/3);\n yBullet=(int)(y+Sprite.python_left.getHeight()*3/4);\n break;\n case 1:\n xBullet=(int)(x+Sprite.python_left.getWidth()*3/4);\n yBullet=(int)(y+Sprite.python_left.getHeight()/4);\n break;\n case 2:\n xBullet=(int)(x+Sprite.python_left.getWidth()/3);\n yBullet=(int)(y+Sprite.python_left.getHeight()/4);\n break;\n case 3:\n xBullet=(int)(x+Sprite.python_left.getWidth()/4);\n yBullet=(int)(y+Sprite.python_left.getHeight()/4);\n break;\n }\n PythonBullet pythonBullet=new PythonBullet(xBullet,yBullet,board,Player.PLAYER_SPEED*1.5);\n pythonBullet.setDirection(direction);\n board.addBullets(pythonBullet);\n\n }", "public String attack() {\r\n\t\t\tthis.getCurrentEnemy().setHealth(this.getCurrentEnemy().getHealth()-this.getPlayer().getWeapon().getAttack());\r\n\t\t\tif(this.getCurrentEnemy().isDefeated()) {\r\n\t\t\t\tthis.setInBattle(false);\r\n\t\t\t\t\r\n\t\t\t\tthis.handleQuestrelatedEnemy(this.getCurrentEnemy());\r\n\t\t\t\t\r\n\t\t\t\tif(this.getCurrentEnemy().getLoot() != null) {\r\n\t\t\t\t\tthis.getPlayer().getCurrentLocation().addItem(this.getCurrentEnemy().getLoot());\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tthis.getPlayer().gainXp(this.getCurrentEnemy().getXpYield());\r\n\t\t\t\tthis.getPlayer().getCurrentLocation().removeNpc(this.getCurrentEnemy().getName());\r\n\t\t\t\tif(this.getCurrentEnemy().getClass().getName().equals(\"game.EnemyGuardian\")) {\r\n\t\t\t\t\t// adds paths between current location and location in the guardian, path names are specified in the guardian construction\r\n\t\t\t\t\tthis.getPlayer().getCurrentLocation().addPaths(this.getPlayer().getCurrentLocation(), ((EnemyGuardian)this.getCurrentEnemy()).getPathTo(),\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t((EnemyGuardian)this.getCurrentEnemy()).getGuardedLocation(), ((EnemyGuardian)this.getCurrentEnemy()).getPathFrom());\r\n\t\t\t\t\treturn \"You defeated \" + this.getCurrentEnemy().getName() + \". \\n\"\r\n\t\t\t\t\t\t\t+ ((EnemyGuardian)this.getCurrentEnemy()).getRevelationMessage() + \"\\n\";\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\treturn \"You defeated \" + this.getCurrentEnemy().getName() + \".\";\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tthis.triggerEnemyAttack();\r\n\t\t\t\t\tif(this.getPlayer().getHealth() <= 0) {\r\n\r\n\t\t\t\t\t\tthis.gameOver();\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\treturn \"You attacked \" + this.getCurrentEnemy().getName() + \" for \" + this.getPlayer().getWeapon().getAttack() + \" damage. \\n You DIED.\";\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse {\r\n\t\t\t\t\t\treturn \"You attacked \" + this.getCurrentEnemy().getName() + \" for \" + this.getPlayer().getWeapon().getAttack() + \" damage. \\n\"\r\n\t\t\t\t\t\t\t\t+ this.getCurrentEnemy().getName() + \" attacked you for \" + this.getCurrentEnemy().getAttack() + \" damage.\\n\"\r\n\t\t\t\t\t\t\t\t\t\t+ this.getCurrentEnemy().printHealth();\r\n\t\t\t\t\t}\r\n\t\t\t}\r\n\t\t}", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker)\n\t{\n\t\treduceCurrentHp(damage, attacker, true);\n\t}", "public void setHungerDamage(float hunger);", "@Override\n public void visit(final Rogue rogue) {\n rogue.getFirstAbility().changeAllVictimModifier(DAMAGE_MODIFIER_FOR_ROGUE);\n rogue.getSecondAbility().changeAllVictimModifier(DAMAGE_MODIFIER_FOR_ROGUE);\n // anunt magicianul de ajutorul ingerului\n rogue.getEvent().anEventHappened(rogue, this, \"help\");\n // ofer Xp jucatorului pentru a trece la nivelul urmator\n rogue.gainXp(getNewXp(rogue));\n }", "@Override\n\tpublic void onDamageDealt(Entity attacker, Entity defender, int damage, int attackType) {\n\n\t}", "public static void bullyAttack(){\n int punch = player.getHealth() - bullyHitPoints ;\n player.setHealth(punch);\n //Step 2: Conditional dialogue\n if(bullyHitPoints > 50) {\n System.out.println(textparser.getMassiveDamage() + bullyHitPoints + textparser.getToYou());\n }else if(bullyHitPoints > 25){\n System.out.println(textparser.getPunch() + bullyHitPoints + textparser.getToYou());\n }else{\n System.out.println(textparser.getDidntHurtMuch() + bullyHitPoints + textparser.getToYou());\n }\n }", "@Override\n\tpublic int calculateAttackType(Entity attacker, Entity defender) {\n\t\tif (attacker.getType() != EntityType.NPC || defender.getType() != EntityType.PLAYER) {\n\t\t\treturn ServerConstants.MELEE_ICON;\n\t\t}\n\t\tNpc attackerAsNpc = (Npc) attacker;\n\n\t\tint randomChanceOfAttack = ThreadLocalRandom.current().nextInt(0, 100);\n\n\t\tif (phase == AbyssalSirePhase.AWAKE) {\n\t\t\tif (randomChanceOfAttack <= 80 || spawns.stream().filter(n -> n != null && !n.isDead()).count() >= 2) {\n\t\t\t\tattack = AbyssalSireAttack.POISON;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.SPAWN;\n\t\t\t}\n\t\t} else if (phase == AbyssalSirePhase.MELEE_COMBAT) {\n\t\t\tif (randomChanceOfAttack <= 50) {\n\t\t\t\tattack = AbyssalSireAttack.SWIPE;\n\t\t\t} else if (randomChanceOfAttack <= 85) {\n\t\t\t\tattack = AbyssalSireAttack.TENDRIL_SWIPE;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.DOUBLE_TENDRIL_SWIPE;\n\t\t\t}\n\t\t} else if (phase == AbyssalSirePhase.MAGIC_COMBAT) {\n\t\t\tif (explosionState == AbyssalSireExplosionState.NONE && attackerAsNpc.getCurrentHitPoints() <= 139) {\n\t\t\t\tattack = AbyssalSireAttack.PORTAL;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.POISON;\n\t\t\t}\n\t\t}\n\t\treturn ServerConstants.MELEE_ICON;\n\t}", "private void damage(){\n\n LevelMap.getLevel().damage(dmg);\n //System.out.println(\"died\");\n setDie();\n }", "public void addHerbalismExp(int exp)\n\t{\n\t\tm_oldLevel = getHerbalismLevel();\n\t\tm_skillHerbExp = m_skillHerbExp + exp;\n\t\tif(getHerbalismLevel() > m_oldLevel && getHerbalismLevel() <= 100)\n\t\t{\n\n\t\t}\n\t}", "@Override\n public L2Attackable getActiveChar() { return (L2Attackable)super.getActiveChar(); }", "@Override\n public void attackedByPaladin(double attack) {\n this.attack += (2 * attack) / 3;\n damageCounter = Math.max(damageCounter - (2 * attack) / 3, 0);\n }", "public void applyDamage(int damage)\r\n\t{\r\n\r\n\t}", "@Override\n\tpublic void skill1(Fightable f) {\n\t\tsuper.setDamage(super.getStrength()*3);\n\t\tsuper.setAtkRange((int)(super.getDamage()/5));\n\t\t\n\t\tthis.attack(f, 2);\n\t}", "public static void combatPlayer(Player atk, EnemyObject def){\n\t\tif(atk.stat.getType() != def.stat.getType() ){\n\n\t\t\t\tint atkDamage = 0;\n\t\t\t\tatkDamage = atk.stat.toDamage();\n\t\t\t\tdef.stat.getDamage(atkDamage);\n\t\t\t\t//System.out.println(\"Attack!\");\n\t\t\t\t//System.out.println(\"Enemy get \"+ atkDamage + \" Damage\");\n\t\t\t\tif(def.stat.checkAlive()==false){\n\t\t\t\t\t//check the object die or not.\t\t\n\t\t\t\t\t\n\t\t\t\t\tif(def.stat.getType()==1){\n\t\t\t\t\t//System.out.println(\"Enemy Die\");\n\t\t\t\t\t\t//def.remove(0);\n\t\t\t\t\t\t//enemy die.\n\t\t\t\t\t\t//give exp to the user.\n\t\t\t\t\t\tint exp = def.stat.giveExp();\n\t\t\t\t\t\t\n\t\t\t\t\t\tatk.stat.getExp(exp);\n\t\t\t\t\t\t//System.out.println(\"Player get \"+exp+ \" exp\");\n\t\t\t\t\t\t//destroy the enemy object.-> ??\n\t\t\t\t\t}\n\t\t\t\t}\t\t\t\n\t\t\t\t//System.out.println(\"\\n\\nEvent number : \" + atk.stat.getEventNum()+\" \\n\");\n /*\n\t\t\t\tSystem.out.println(\"Enemy Health: \" + def.stat.getHP());\n\t\t\t\tSystem.out.println(\"\\n\\n Player Stat: \");\n\t\t\t\tSystem.out.println(\"\\nPlayer HP: \"+atk.stat.getHP());\n\t\t\t\tSystem.out.println(\"Level: \"+atk.stat.getLv());\n\t\t\t\tSystem.out.println(\"STR: \"+atk.stat.getStr());\n\t\t\t\tSystem.out.println(\"DEX: \"+atk.stat.getDex());\n\t\t\t\tSystem.out.println(\"Wis: \"+atk.stat.getWis());\n\t\t\t\tSystem.out.println(\"Con: \"+atk.stat.getCon()+\"\\n\");\t*/\t\t\t\n\t\t}\n\t}", "public void updateAllies(){\r\n List<Ally> allies = world.getAllies();\r\n ArrayList<Ally> deadAllies = new ArrayList<Ally>();\r\n for(Ally ally : allies){\r\n if(ally.getCurrHP() <= 0){\r\n deadAllies.add(ally);\r\n }\r\n }\r\n\r\n allies.removeAll(deadAllies);\r\n world.setNumAllies(allies.size());\r\n //numAllies.set(allies.size());\r\n }", "public void resolve(){\n logger.log(Level.FINE,attacker.getName()+\" withering attacked \"+defender.getName());\n AttackState state=new AttackState();\n state.weaponDamage=weapon.getDamage();\n state.initialAttackpool=baseAttackdice+baseAccuracy-woundpenalty;\n attacker.declareWitheringAttack(state); // If the attacker wants to change the pool, he modifies the state accordingly.\n defender.declareWitheringDV(state); // Defender declares their dv against this specific attack. This sets both initialdv and changedDv\n state.initialAttackRoll= new DiceThrow(state.changedAttackpool);\n attacker.modifyWitheringAttackRollAttacker(state); //This sets stuff like modifiedAttackRollAttacker and AttackerRollValuation\n defender.modifyWitheringAttackRollDefender(state); //This sets defender modifiedAttackRollDefender\n state.attackRollSuccesses=state.modifiedAttackRollDefender.evaluateResults(state.AttackRollValuationAttacker);\n state.threshholdSuccesses=state.attackRollSuccesses-state.changedDv;\n logger.log(Level.FINE,attacker.getName()+\" rolled \"+state.changedAttackpool+\" dice against \"+defender.getName()+\"'s dv of \"+state.changedDv+\" and gained \"+state.attackRollSuccesses+\" successes.\");\n attacker.changeWitheringThreshholdAttacker(state); //This sets thresholdModifiedAttacker\n defender.changeWitheringThreshholdDefender(state); //This sets thresholdModifiedDefender\n if(state.thresholdModifiedDefender>=0) {\n logger.log(Level.FINE,attacker.getName()+\" hit \"+defender.getName()+\" with \"+state.thresholdModifiedDefender+\" threshhold successes.\");\n attacker.modifyWitheringRawDamageAttacker(state); //Sets normal raw damageType, based on strength and weapon damageType, and then sets rawDamagemModifiedAttacker\n defender.modifyWitheringRawDamageDefender(state); //this sets rawDamageModifiedDefender, and sets up the various soak values, so natural soak and armor soak.\n logger.log(Level.FINE, \"The raw damage of the attack is: \"+state.rawDamageModifiedDefender);\n state.totalSoak = Math.max(state.defenderArmorSoak - ignoredArmorSoak, 0) + state.defenderNaturalSoak; //\n attacker.modifyTotalSoakAttacker(state); //This sets totalSoakmodifiedAttacker. Don't think this actually has support in the solar charmset, but giving opportunities to work with.\n defender.modifyTotalSoakDefender(state); // This sets totalSoakmodifiedDefender.\n state.postSoakSuccesses=Math.max(state.rawDamageModifiedDefender-state.totalSoakModifiedDefender,weapon.getOverwhelming());\n logger.log(Level.FINE,state.totalSoakModifiedDefender+\" damage is soaked, leading to post soak dice of \"+state.postSoakSuccesses);\n attacker.declarePostSoakAttacker(state); //sets postSoakSuccessesModifiedAttacker\n defender.declarePostSoakDefender(state); //sets postSoakSuccessesModifiedDefender\n DiceThrow droll=new DiceThrow(state.postSoakSuccessesModifiedDefender);\n state.damageRoll=droll;\n attacker.modifyWitheringDamageRollAttacker(state); //sets damageRollmodifiedAttacker and damageRollvValuation\n defender.modifyWitheringDamageRollDefender(state); //sets damageRollmodifiedDefender\n state.initiativeDamageDone=state.damageRollModifiedDefender.evaluateResults(state.damageRollValuation);\n logger.log(Level.FINE,attacker.getName()+\" rolls \"+state.postSoakSuccessesModifiedDefender+\" dice and achieves \"+state.initiativeDamageDone+\" successes.\");\n attacker.modifyInitiativeDamageAttacker(state);\n defender.modifyInitiativeDamageDefender(state); //Since this is the last change of initiative, we can check whether the defender was crashed here.\n attacker.updateInitiativeAttacker(state);\n defender.updateInitiativeDefender(state);//Here we should handle all the initiative changes respectively, with checking if people are crashed etc.\n }\n else{\n attacker.failedWitheringAttackAttacker(state);\n defender.failedWitheringAttackDefender(state);\n }\n\n }", "@Override\r\n\tpublic void add(Army garrison) {\r\n\t\tgarrison.addArtillery(1);\r\n\t}", "public void attackEntity(Entity entityToHit) {\n ItemStack item = tinkerProjectile.getItemStack();\n ItemStack launcher = tinkerProjectile.getLaunchingStack();\n\n // deal damage if we have everything\n if(item.getItem() instanceof ToolCore && this.attacker != null) {\n EntityLivingBase attacker = (EntityLivingBase) this.attacker;\n //EntityLivingBase target = (EntityLivingBase) raytraceResult.entityHit;\n\n // find the actual itemstack in the players inventory\n ItemStack inventoryItem = AmmoHelper.getMatchingItemstackFromInventory(tinkerProjectile.getItemStack(), attacker, false);\n if(inventoryItem.isEmpty() || inventoryItem.getItem() != item.getItem()) {\n // backup, use saved itemstack\n inventoryItem = item;\n }\n\n // for the sake of dealing damage we always ensure that the impact itemstack has the correct broken state\n // since the ammo stack can break while the arrow travels/if it's the last arrow\n boolean brokenStateDiffers = ToolHelper.isBroken(inventoryItem) != ToolHelper.isBroken(item);\n if(brokenStateDiffers) {\n toggleBroken(inventoryItem);\n }\n\n Multimap<String, AttributeModifier> projectileAttributes = null;\n // remove stats from held items\n if(!world.isRemote) {\n unequip(attacker, EntityEquipmentSlot.OFFHAND);\n unequip(attacker, EntityEquipmentSlot.MAINHAND);\n\n // apply stats from projectile\n if(item.getItem() instanceof IProjectile) {\n projectileAttributes = ((IProjectile) item.getItem()).getProjectileAttributeModifier(inventoryItem);\n\n if(launcher.getItem() instanceof ILauncher) {\n ((ILauncher) launcher.getItem()).modifyProjectileAttributes(projectileAttributes, tinkerProjectile.getLaunchingStack(), tinkerProjectile.getItemStack(), tinkerProjectile.getPower());\n }\n\n // factor in power\n projectileAttributes.put(SharedMonsterAttributes.ATTACK_DAMAGE.getName(),\n new AttributeModifier(PROJECTILE_POWER_MODIFIER, \"Weapon damage multiplier\", tinkerProjectile.getPower() - 1f, 2));\n\n attacker.getAttributeMap().applyAttributeModifiers(projectileAttributes);\n }\n // deal the damage\n// ToolHelper.attackEntity(item, (ToolCore) item.getItem(), attacker, entityToHit, null);\n// float speed = MathHelper.sqrt(this.motionX * this.motionX + this.motionY * this.motionY + this.motionZ * this.motionZ);\n\n boolean attack = ToolHelper.attackEntity(item, (ToolCore) item.getItem(), attacker, entityToHit, null);\n// if(attack) {\n//// for(IProjectileTrait trait : tinkerProjectile.getProjectileTraits()) {\n//// trait.afterHit(tinkerProjectile.get, this.world, inventoryItem, attacker, entityToHit, (double) 0.0);\n//// }\n//\n// // if on fire, set the entity on fire, like vanilla arrows\n//// if (this.isBurning() && !(entityToHit instanceof EntityEnderman)) {\n//// entityToHit.setFire(5);\n//// }\n// }\n if(brokenStateDiffers) {\n toggleBroken(inventoryItem);\n }\n\n // remove stats from projectile\n // apply stats from projectile\n if(item.getItem() instanceof IProjectile) {\n assert projectileAttributes != null;\n attacker.getAttributeMap().removeAttributeModifiers(projectileAttributes);\n }\n\n // readd stats from held items\n equip(attacker, EntityEquipmentSlot.MAINHAND);\n equip(attacker, EntityEquipmentSlot.OFFHAND);\n }\n }else {\n System.out.println(\"something failed with attacking.\");\n }\n }", "public void attack(Entity entity, boolean aoe) {\n if(aoe) entity.damaged((int) (this.damage*0.6));\n else entity.damaged(this.damage);\n if(entity.isDead()){\n incExp(entity.getLevel()*9);\n if(entity instanceof Boss) {\n this.bossesDefeated++;\n }\n }\n }", "@Override\r\n public void applyAttributes() {\r\n super.applyAttributes();\r\n getEntity().setColor(color);\r\n getEntity().setOwner(MbPets.getInstance().getServer().getPlayer(getOwner()));\r\n getEntity().setAgeLock(true);\r\n\r\n if (isBaby) {\r\n getEntity().setBaby();\r\n } else {\r\n getEntity().setAdult();\r\n }\r\n Bukkit.getMobGoals().removeGoal(getEntity(), VanillaGoal.LLAMA_ATTACK_WOLF);\r\n Bukkit.getMobGoals().removeGoal(getEntity(), VanillaGoal.LLAMA_FOLLOW_CARAVAN);\r\n Bukkit.getMobGoals().removeGoal(getEntity(), VanillaGoal.TRADER_LLAMA_DEFEND_WANDERING_TRADER);\r\n }", "public void heal(){\n\t\thp += potion.getHpBoost();\n\t\tif(hp > max_hp)hp = max_hp;\n\t}", "public void addHealth(int amt) {\n currentHealth = currentHealth + amt;\n }", "public String getAsteroidAttack() {\n\t\tminusShield(2);\n\t\treturn \"Got damaged from the asteroid belt!!\";\n\t}", "@Override\n public void addInfo(CurrentPlayer currentPlayer) {\n godPower.addInfo(currentPlayer);\n }", "@SideOnly(Side.CLIENT)\n\tpublic void addInformation(ItemStack itemStack, EntityPlayer p_77624_2_, List list, boolean p_77624_4_) {\n\n\t\tif (itemStack.stackTagCompound != null) {\n\t\t\tString targetName = itemStack.stackTagCompound.getString(\"targetName\");\n\t\t\tString targetUUID = itemStack.stackTagCompound.getString(\"targetUUID\");\n\t\t\tlist.add(\"Target Name: \" + targetName);\n\t\t\tlist.add(\"Target UUID: \" + targetUUID);\n\n\t\t}\n\t}", "public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean smt) {\n/* 122 */ int standID = getStandID(stack);\n/* 123 */ if (standID == 0) {\n/* */ return;\n/* */ }\n/* */ \n/* */ \n/* 128 */ int standAct = getStandACT(stack);\n/* 129 */ int standExp = getStandEXP(stack);\n/* */ \n/* 131 */ String standName = getStandNAME(stack);\n/* 132 */ EntityOneStand standEnt = ItemStandArrow.getStand(standID, player.worldObj);\n/* 133 */ String standEntName = standEnt.getCommandSenderName();\n/* 134 */ if (standName.equals(\"\")) {\n/* */ \n/* 136 */ standName = getEntityStandName(standEnt);\n/* */ }\n/* */ else {\n/* */ \n/* 140 */ stack.setStackDisplayName(standEntName);\n/* */ } \n/* 142 */ String standActPre = StatCollector.translateToLocal(\"stands.jojobadv.Act.txt\");\n/* 143 */ String standExpPre = StatCollector.translateToLocal(\"stands.jojobadv.Exp.txt\");\n/* */ \n/* 145 */ list.add(standName);\n/* 146 */ list.add(standActPre + \" \" + standAct + \"!\");\n/* 147 */ list.add(standExpPre + \" \" + standExp);\n/* */ }", "public void getAttackedByDarknessMagicBook(IEquipableItem item){item.strongAttackTo(this.getOwner());}", "public void attack(Player player) {\n this.damage = 18 - player.getfPoint(); // the higher the Fighter skill,\n // the lower the damage. change the math.\n int newHealth = player.getShip().getHealth() - damage;\n player.getShip().setHealth(newHealth);\n }", "public void causeFoodExhaustion(float debug1) {\n/* 1797 */ if (this.abilities.invulnerable) {\n/* */ return;\n/* */ }\n/* */ \n/* 1801 */ if (!this.level.isClientSide) {\n/* 1802 */ this.foodData.addExhaustion(debug1);\n/* */ }\n/* */ }", "public void gainExperience(Combatant opponent) { }", "@Override\n public void onEntityUpdate() {\n if (!(world.provider instanceof WorldProviderLimbo || world.provider instanceof WorldProviderDungeonPocket)) {\n setDead();\n super.onEntityUpdate();\n return;\n }\n\n super.onEntityUpdate();\n\n // Check for players and update aggro levels even if there are no players in range\n EntityPlayer player = world.getClosestPlayerToEntity(this, MAX_AGGRO_RANGE);\n boolean visibility = player != null && player.canEntityBeSeen(this);\n updateAggroLevel(player, visibility);\n\n // Change orientation and face a player if one is in range\n if (player != null) {\n facePlayer(player);\n if (!world.isRemote && isDangerous()) {\n // Play sounds on the server side, if the player isn't in Limbo.\n // Limbo is excluded to avoid drowning out its background music.\n // Also, since it's a large open area with many Monoliths, some\n // of the sounds that would usually play for a moment would\n // keep playing constantly and would get very annoying.\n playSounds(player.getPosition());\n }\n\n if (visibility) {\n // Only spawn particles on the client side and outside Limbo\n if (world.isRemote && isDangerous()) {\n spawnParticles(player);\n }\n\n // Teleport the target player if various conditions are met\n if (aggro >= MAX_AGGRO && !world.isRemote && ModConfig.monoliths.monolithTeleportation && !player.isCreative() && isDangerous()) {\n aggro = 0;\n Location destination = WorldProviderLimbo.getLimboSkySpawn(player);\n TeleportUtils.teleport(player, destination, 0, 0);\n player.world.playSound(null, player.getPosition(), ModSounds.CRACK, SoundCategory.HOSTILE, 13, 1);\n }\n }\n }\n }", "@SubscribeEvent(priority = EventPriority.NORMAL)\n public void onLivingAttack(EntityStruckByLightningEvent event) {\n\t\tempowerItem(event);\n\t\ttransformVillager(event);\n }", "public interface IHitAggro {\n /**\n * shouldAggroOnHit\n * The chance (where 1.0F = 100%) that this mob would be aggroed if struck by this entity\n * Should NOT trigger the aggro itself! That should only occur when actually hit!\n * @param geneticMob the mob being checked\n * @param attacker the entity that could attack\n * @return the chance of aggro (1.0F = 100%, 0.0F = 0%)\n */\n float shouldAggroOnHit(IGeneticMob geneticMob, EntityLiving attacker);\n\n /**\n * aggroHitTimer\n * How long this mob would stay angry at this attacker if aggroed via hit\n * @param geneticMob the mob being checked\n * @param attacker the entity that could attack\n * @return the length, in ticks, of the timer\n */\n int aggroHitTimer(IGeneticMob geneticMob, EntityLiving attacker);\n }", "public void addBreedingExp(int exp)\n\t{\n\t\tm_oldLevel = getBreedingLevel();\n\t\tm_skillBreedExp = m_skillBreedExp + exp;\n\t\tif(getBreedingLevel() > m_oldLevel)\n\t\t{\n\t\t\tServerMessage skillLevels = new ServerMessage(ClientPacket.SKILL_LVL_UP);\n\t\t\tskillLevels.addInt(getTrainingLevel());\n\t\t\tskillLevels.addInt(getBreedingLevel());\n\t\t\tskillLevels.addInt(getFishingLevel());\n\t\t\tskillLevels.addInt(getCoordinatingLevel());\n\t\t\tgetSession().Send(skillLevels);\n\t\t}\n\t}", "@Override\n public void adjustTypeAttributes() {\n this.getSpecialData().addAttribute(SharedMonsterAttributes.maxHealth, 20.0);\n }", "public boolean handleAttack(Action action) {\n ActorState a = action.getActor();\n if (a.getActor() == actor) {\n // Attacks on oneself always succeed, and we don't want to add ourselves as an enemy\n return true;\n }\n \n //maybeCounter(Augmentation.Type.ATTACK, a, combatants);\n enemies.add(a);\n \n double weaponAccuracy = 1.0; //source.getWeaponAccuracy(action);\n double chance = a.getAccuracy() * weaponAccuracy * (1.0 - getDefense());\n boolean success = Math.random() < chance;\n return success;\n }", "@SideOnly(Side.CLIENT)\n/* */ public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List<String> par3List, boolean par4) {\n/* 59 */ if (GuiScreen.isShiftKeyDown()) {\n/* 60 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome1.lore\"));\n/* 61 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome2.lore\"));\n/* 62 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome3.lore\"));\n/* 63 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* 64 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome4.lore\"));\n/* 65 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome5.lore\"));\n/* 66 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* 67 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome6.lore\"));\n/* 68 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome7.lore\"));\n/* 69 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome8.lore\"));\n/* 70 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* 71 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome9.lore\"));\n/* 72 */ } else if (GuiScreen.isCtrlKeyDown()) {\n/* 73 */ par3List.add(StatCollector.translateToLocal(\"item.FRVisPerSecond.lore\"));\n/* 74 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRAerCost.lore\") + (AerCost / 100.0D * 10.0D));\n/* 75 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRTerraCost.lore\") + (TerraCost / 100.0D * 10.0D));\n/* 76 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRIgnisCost.lore\") + (IgnisCost / 100.0D * 10.0D));\n/* 77 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRPerditioCost.lore\") + (PerditioCost / 100.0D * 10.0D));\n/* */ } else {\n/* */ \n/* 80 */ par3List.add(StatCollector.translateToLocal(\"item.FRShiftTooltip.lore\"));\n/* 81 */ par3List.add(StatCollector.translateToLocal(\"item.FRViscostTooltip.lore\"));\n/* */ } \n/* */ \n/* 84 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* */ }", "void defendAttack(IUnit attacker, int incomingDamage);", "public void equip(Hero h) {\n\t\tfor(Weapon w : h.getInventory().getWeaponList()) {\n\t\t\tif(w.getName().equals(this.getName())) {\n\t\t\t\tw.setEquipped(true);\n\t\t\t\tw.statsIncrease(h, StatType.STRENGTH, getWeaponDmg());\n\t\t\t} else {\n\t\t\t\tw.unequip(h);\n\t\t\t}\n\t\t}\n\t}", "@Override\r\n\tpublic void useSkill() {\n\t\tthis.defense+=20;\r\n\t\tthis.maxHp+=(this.maxHp/2);\r\n\t\tthis.hp+=(this.hp/2);\r\n\t\tthis.skillActive = true;\r\n\t\tthis.skillLast = 2;\r\n\t}", "public abstract void attack(Vector2 spawnPos, Vector2 target);" ]
[ "0.7878615", "0.57070976", "0.5693362", "0.56562793", "0.5603274", "0.55683935", "0.5544843", "0.5498308", "0.5480298", "0.5477514", "0.54508567", "0.543987", "0.54165876", "0.53099364", "0.52890766", "0.52858186", "0.5273309", "0.525662", "0.52524143", "0.5245641", "0.5218846", "0.51886815", "0.5187791", "0.5187611", "0.5187508", "0.51711404", "0.51698494", "0.5159048", "0.5154801", "0.5130939", "0.5128837", "0.51276153", "0.51256675", "0.51114744", "0.51091576", "0.5107528", "0.50978583", "0.5097684", "0.50967157", "0.50898653", "0.5078331", "0.50609964", "0.50586605", "0.50522363", "0.504917", "0.50471413", "0.5046282", "0.50350136", "0.5031503", "0.50072116", "0.50049114", "0.50009406", "0.4995296", "0.4995265", "0.49939856", "0.49938193", "0.4992487", "0.49909255", "0.49887472", "0.49840814", "0.49836907", "0.49774355", "0.49771026", "0.4973198", "0.49678662", "0.49611366", "0.49545148", "0.4943626", "0.49419525", "0.4940536", "0.4939433", "0.49360195", "0.4933026", "0.49324048", "0.4932063", "0.49247128", "0.49236062", "0.49174932", "0.49107373", "0.49050605", "0.49007517", "0.49002123", "0.49001375", "0.48975012", "0.48902676", "0.48825306", "0.48819512", "0.4875743", "0.48712015", "0.48684967", "0.48682344", "0.48675722", "0.48654735", "0.48497462", "0.48488864", "0.4847615", "0.48466384", "0.48400393", "0.48393387", "0.4834135" ]
0.62557495
1
Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList.
public void addDamageHate(final L2Character attacker, final int damage, int aggro) { if (attacker == null /* || aggroList == null */) { return; } // Get the AggroInfo of the attacker L2Character from the aggroList of the L2Attackable AggroInfoHolder ai = getAggroListRP().get(attacker); if (ai == null) { ai = new AggroInfoHolder(attacker); ai.init(); getAggroListRP().put(attacker, ai); } // If aggro is negative, its comming from SEE_SPELL, buffs use constant 150 if (aggro < 0) { ai.decHate(aggro * 150 / (getLevel() + 7)); aggro = -aggro; } // if damage == 0 -> this is case of adding only to aggro list, dont apply formula on it else if (damage == 0) { ai.incHate(aggro); // else its damage that must be added using constant 100 } else { ai.incHate(aggro * 100 / (getLevel() + 7)); } // Add new damage and aggro (=damage) to the AggroInfo object ai.incDmg(damage); // Set the intention to the L2Attackable to AI_INTENTION_ACTIVE if (getAI() != null && aggro > 0 && getAI().getIntention() == CtrlIntention.AI_INTENTION_IDLE) { getAI().setIntention(CtrlIntention.AI_INTENTION_ACTIVE); } ai = null; // Notify the L2Attackable AI with EVT_ATTACKED if (damage > 0) { if (getAI() != null) { getAI().notifyEvent(CtrlEvent.EVT_ATTACKED, attacker); } try { if (attacker instanceof L2PcInstance || attacker instanceof L2Summon) { L2PcInstance player = attacker instanceof L2PcInstance ? (L2PcInstance) attacker : ((L2Summon) attacker).getOwner(); for (final Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_ATTACK)) { quest.notifyAttack(this, player, damage, attacker instanceof L2Summon); } player = null; } } catch (final Exception e) { LOGGER.error("", e); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void addDamage(final L2Character attacker, final int damage)\n\t{\n\t\taddDamageHate(attacker, damage, damage);\n\t}", "public void attack()\n {\n getWorld().addObject(new RifleBullet(player.getX(), player.getY(), 1, 6, true), getX(), getY()); \n }", "@Override\n\tpublic void onDamage(WorldObj obj, Items item) {\n\n\t\tif(is_stunned) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tint dmg = (int) item.type.ATK;\n\t\t\n\t\tOnScreenText.AddText(\"\"+dmg, bounds.x , bounds.y + 1.1f);\n\t\t\n\t\tvelX = obj.direction * 5;\n\t\tvelY = 5;\n\t\tgrounded = false;\n\t\t\n\t\tHP -= dmg;\n\t\t\n\n\t\tstun_counter = 0;\n\t\t\n\t\tif(HP <= 0 && !isDead) {\n\t\t\tonDeath();\n\t\t}\n\t\t\n\t}", "public void addHabitatAttack(Habitat habitat, Habitat target) {\r\n\t\tif (!habitatToTargetList.containsKey(habitat.getID()+\"\")) habitatToTargetList.put(habitat.getID()+\"\", new ArrayList<Habitat>());\r\n\t\t\r\n\t\t// add attack\r\n\t\thabitatToTargetList.get(habitat.getID()+\"\").add(target);\r\n\t}", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "public void OnDamage(AI ai, int aTK, float f) {\n\tif(DamagedTimer < 0.8f)\n\t\treturn;\n\tvel.x = f;\n\tvel.y = 3;\n\tDamagedTimer = 0;\n\tgrounded = false;\n\taTK -= (getDEF()*0.8f);\n\tif(aTK <= 0)\n\t\taTK = 1;\n\tHP -= aTK;\n\tInventory.CurrentInventory.dmgTxts.add(new dmgText(pos.x, pos.y+1, aTK));\n\t\n\tSoundManager.PlaySound(\"playerHurt\",3);\n\t\n\t\n}", "public void AIDamage() {\r\n\t\tif (attackStyle == 2) {\r\n\t\t\tfor(int i = 0; i < AIObject.length; i++) {\r\n\t\t\t\tif ((inFlight) && (Math.abs(aX-AIObject[i].getAIX()) < 5) && (Math.abs(aY-AIObject[i].getAIY())) < 4 ) {\r\n\t\t\t\t\tAIObject[i].setHealth(-25 * damageReduction);\r\n\t\t\t\t\tdrawArrow = false;\r\n\t\t\t\t\tcooldown = 15;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}else {\r\n\t\t\tif (mouseLeft) {\r\n\t\t\t\tfor(int i = 0; i < AIObject.length; i++){\r\n\t\t\t\t\tif ((drawSword) && (cooldown == 0) && (playerObject[0].getX() -AIObject[i].getAIX() <85) && (playerObject[0].getX()-AIObject[i].getAIX() >-1) && (playerObject[0].getY() - AIObject[i].getAIY() < 20) && (playerObject[0].getY()-AIObject[i].getAIY()>-5)) {\r\n\t\t\t\t\t\tAIObject[i].setHealth(-50 * damageReduction);\r\n\t\t\t\t\t\tcooldown = 5;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}else {\r\n\t\t\t\tfor(int i=0; i < AIObject.length; i++){\r\n\t\t\t\t\tif ((drawSword) && (cooldown == 0) && (AIObject[i].getAIX()-playerObject[0].getX() <85) && (AIObject[i].getAIX() - playerObject[0].getX() > -1) && (playerObject[0].getY() - AIObject[i].getAIY() < 20) && (playerObject[0].getY()-AIObject[i].getAIY()>-5)) {\r\n\t\t\t\t\t\tAIObject[i].setHealth(-50 * damageReduction);\r\n\t\t\t\t\t\tcooldown = 5;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\tfor(int i=0; i < AIObject.length; i++){\r\n\t\t\t//checks if AI is close enough to attack with melee\r\n\t\t\tfor (int j = 0; j < playerObject.length; j++) {\r\n\t\t\t\tif ((!shield) && (Math.abs(AIObject[i].getAIX() - playerObject[j].getX()) <= 10) && (Math.abs(AIObject[i].getAIY() - playerObject[j].getY())) <= 3) {\r\n\t\t\t\t\tplayerObject[j].setHealth(DAMAGE_AMOUNT * difficulty);\r\n\t\t\t\t\tif (playerObject[j].getHealth() <= 0) {\r\n\t\t\t\t\t\tdead = true;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "private void enemyAttack() {\n\t\t\n\t\tRandom rand = new Random();\t\n\t\t\n\t\tint roll = rand.nextInt(101);\n\t\t\n\t\tint sroll = rand.nextInt(101);\n\t\t\n\t\tevents.appendText(e.getName() + \" attacks!\\n\");\n\t\t\n\t\tif(roll <= p.getEV()) { // Player evades\n\t\t\t\n\t\t\tevents.appendText(\"You evaded \"+e.getName()+\"\\'s Attack!\\n\");\n\t\t\t\n\t\t}else if(roll > p.getEV()) { // Player is hit and dies if HP is 0 or less\n\t\t\t\n\t\t\tp.setHP(p.getHP() - e.getDMG());\n\t\t\t\n\t\t\tString newHp = p.getHP()+\"/\"+p.getMaxHP();\n\t\t\t\n\t\t\tString effect = e.getSpecial(); // Stats are afflicted\n\t\t\t\n\t\t\tif(sroll < 51){\n\t\t\t\t\n\t\t\tif(effect == \"Bleed\") { // Bleed Special\n\t\t\t\t\n\t\t\t\tp.setHP(p.getHP() - 100);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You bleed profusely. - 100 HP\\n\");\n\t\t\t\t\n\t\t\t\tnewHp = String.valueOf(p.getHP()+\"/\"+p.getMaxHP());\n\t\t\t}\n\t\t\tif(effect == \"Break\") { // Break Special \n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You feel a bone break restricting movement. - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Fear\") { // Fear Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-40>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 40);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"A crippling fear rattles your resolve. - 40 DMG\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Rend\") { // Rend Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-30>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 30);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"Morthar unleashes a pillar of flame! - 30 DMG and - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\t\n\t\t\tif(p.getHP() <= 0) {\n\t\t\t\t\n\t\t\t\tp.setDead(true);\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(0+\"/\"+e.getMaxHP());\n\t\t\t\tplayerHPBar.setProgress((double)0);\n\t\t\t}else {\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(newHp);\n\t\t\t\tplayerHPBar.setProgress((double)p.getHP()/p.getMaxHP());\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tif(p.isDead()) { // Game over if player dies\n\t\t\t\n\t\t\ttry {\n\t\t\t\tLoadGO();\n\t\t\t} catch (IOException e1) {\n\t\t\t\n\t\t\t\te1.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t\tcombat = false;\n\t\t}\n\t}", "private void addEnemySheild() {\n this.enemyShield += 1;\n }", "public void battleAllyAttack() {\n if(battleAlly instanceof Character){\n battleTickStatuses();\n updateBattleSides();\n }\n\n // battleAlly now attacks targetEnemy or preference based on the type of battleAlly\n if(battleAlly != null){ // If all allies have attacked, they cannot attack anymore for this round\n MovingEntity target = battleAlly.getAttackPreference(targetEnemies);\n // if not picky, get preference is the default next target\n if(target == null) {\n target = targetEnemy;\n }\n battleAlly.attack(target, targetAllies, targetEnemies);\n //System.out.println(battleAlly.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still unfriendly\n targetEnemy = checkSideSwap(targetEnemy, true, battleAllies, targetAllies, battleEnemies, targetEnemies);\n }\n battleAlly = nextAttacker(battleAlly, battleAllies);\n\n }\n }", "public void ability(LevelManager lm){\n\n int prevDamage = lm.player.getDamage();\n int newDamage = prevDamage+12;\n lm.player.setDamage(newDamage);\n }", "public void attack() {\n energy = 2;\n redBull = 0;\n gun = 0;\n target = 1;\n // if Player is in range take off a life.\n if (CharacterTask.ghostLocation == GameWindow.playerLocation) {\n playerLives = playerLives - 1;\n System.out.println(\"Player Lives: \" + playerLives);\n }\n }", "@Override\n\tprotected void calculateRewards(final L2Character lastAttacker)\n\t{\n\t\t// Creates an empty list of rewards\n\t\tfinal Map<L2Character, RewardInfoHolder> rewards = new ConcurrentHashMap<>();\n\t\t\n\t\ttry\n\t\t{\n\t\t\tif (getAggroListRP().isEmpty())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (EngineModsManager.onNpcExpSp(this, lastAttacker))\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tL2PcInstance maxDealer = null;\n\t\t\tint maxDamage = 0;\n\t\t\t\n\t\t\tint damage;\n\t\t\t\n\t\t\tL2Character attacker, ddealer;\n\t\t\t\n\t\t\t// While Interacting over This Map Removing Object is Not Allowed\n\t\t\tsynchronized (getAggroList())\n\t\t\t{\n\t\t\t\t// Go through the aggroList of the L2Attackable\n\t\t\t\tfor (final AggroInfoHolder info : getAggroListRP().values())\n\t\t\t\t{\n\t\t\t\t\tif (info == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Get the L2Character corresponding to this attacker\n\t\t\t\t\tattacker = info.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Get damages done by this attacker\n\t\t\t\t\tdamage = info.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// Prevent unwanted behavior\n\t\t\t\t\tif (damage > 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (attacker instanceof L2SummonInstance || attacker instanceof L2PetInstance && ((L2PetInstance) attacker).getPetData().getOwnerExpTaken() > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = info.getAttacker();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check if ddealer isn't too far from this (killed monster)\n\t\t\t\t\t\tif (!Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, ddealer, true))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate real damages (Summoners should get own damage plus summon's damage)\n\t\t\t\t\t\tRewardInfoHolder reward = rewards.get(ddealer);\n\t\t\t\t\t\tif (reward == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward = new RewardInfoHolder(ddealer, damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward.addDamage(damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\trewards.put(ddealer, reward);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (ddealer instanceof L2PlayableInstance && ((L2PlayableInstance) ddealer).getActingPlayer() != null && reward.getDmg() > maxDamage)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tmaxDealer = ((L2PlayableInstance) ddealer).getActingPlayer();\n\t\t\t\t\t\t\tmaxDamage = reward.getDmg();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// Manage Base, Quests and Sweep drops of the L2Attackable\n\t\t\tdoItemDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\t// Manage drop of Special Events created by GM for a defined period\n\t\t\tdoEventDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\tif (!getMustRewardExpSP())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (!rewards.isEmpty())\n\t\t\t{\n\t\t\t\tL2Party attackerParty;\n\t\t\t\tlong exp;\n\t\t\t\tint levelDiff, partyDmg, partyLvl, sp;\n\t\t\t\tfloat partyMul, penalty;\n\t\t\t\tRewardInfoHolder reward2;\n\t\t\t\tint[] tmp;\n\t\t\t\t\n\t\t\t\tfor (final RewardInfoHolder reward : rewards.values())\n\t\t\t\t{\n\t\t\t\t\tif (reward == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Penalty applied to the attacker's XP\n\t\t\t\t\tpenalty = 0;\n\t\t\t\t\t\n\t\t\t\t\t// Attacker to be rewarded\n\t\t\t\t\tattacker = reward.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Total amount of damage done\n\t\t\t\t\tdamage = reward.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// If the attacker is a Pet, get the party of the owner\n\t\t\t\t\tif (attacker instanceof L2PetInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PetInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse if (attacker instanceof L2PcInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PcInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If this attacker is a L2PcInstance with a summoned L2SummonInstance, get Exp Penalty applied for the current summoned L2SummonInstance\n\t\t\t\t\tif (attacker instanceof L2PcInstance && ((L2PcInstance) attacker).getPet() instanceof L2SummonInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tpenalty = ((L2SummonInstance) ((L2PcInstance) attacker).getPet()).getExpPenalty();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// We must avoid \"over damage\", if any\n\t\t\t\t\tif (damage > getMaxHp())\n\t\t\t\t\t{\n\t\t\t\t\t\tdamage = getMaxHp();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If there's NO party in progress\n\t\t\t\t\tif (attackerParty == null)\n\t\t\t\t\t{\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\tif (attacker.getKnownList().knowsObject(this))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// Calculate the difference of level between this attacker (L2PcInstance or L2SummonInstance owner) and the L2Attackable\n\t\t\t\t\t\t\t// mob = 24, atk = 10, diff = -14 (full xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 28, diff = 4 (some xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 50, diff = 26 (no xp)\n\t\t\t\t\t\t\tlevelDiff = attacker.getLevel() - getLevel();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, damage);\n\t\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\t\texp *= 1 - penalty;\n\t\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Check for an over-hit enabled strike and VIP options\n\t\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif (player.isVIP())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\texp = (long) (exp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t\tsp = (int) (sp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Distribute the Exp and SP between the L2PcInstance and its L2Summon\n\t\t\t\t\t\t\tif (!attacker.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tattacker.addExpAndSp(Math.round(attacker.calcStat(Stats.EXPSP_RATE, exp, null, null)), (int) attacker.calcStat(Stats.EXPSP_RATE, sp, null, null));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t// share with party members\n\t\t\t\t\t\tpartyDmg = 0;\n\t\t\t\t\t\tpartyMul = 1.f;\n\t\t\t\t\t\tpartyLvl = 0;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Get all L2Character that can be rewarded in the party\n\t\t\t\t\t\tfinal List<L2PlayableInstance> rewardedMembers = new ArrayList<>();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Go through all L2PcInstance in the party\n\t\t\t\t\t\tList<L2PcInstance> groupMembers;\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getCommandChannel().getMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getPartyMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tfor (final L2PcInstance pl : groupMembers)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (pl == null || pl.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Get the RewardInfo of this L2PcInstance from L2Attackable rewards\n\t\t\t\t\t\t\treward2 = rewards.get(pl);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// If the L2PcInstance is in the L2Attackable rewards add its damages to party damages\n\t\t\t\t\t\t\tif (reward2 != null)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add L2PcInstance damages to party damages\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\trewards.remove(pl); // Remove the L2PcInstance from the L2Attackable rewards\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t// Add L2PcInstance of the party (that have attacked or not) to members that can be rewarded\n\t\t\t\t\t\t\t\t// and in range of the monster.\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfinal L2PlayableInstance summon = pl.getPet();\n\t\t\t\t\t\t\tif (summon != null && summon instanceof L2PetInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\treward2 = rewards.get(summon);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (reward2 != null) // Pets are only added if they have done damage\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, summon, true))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add summon damages to party damages\n\t\t\t\t\t\t\t\t\t\trewardedMembers.add(summon);\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tif (summon.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = summon.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\trewards.remove(summon); // Remove the summon from the L2Attackable rewards\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// If the party didn't killed this L2Attackable alone\n\t\t\t\t\t\tif (partyDmg < getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyMul = (float) partyDmg / (float) getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Avoid \"over damage\"\n\t\t\t\t\t\tif (partyDmg > getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyDmg = getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate the level difference between Party and L2Attackable\n\t\t\t\t\t\tlevelDiff = partyLvl - getLevel();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, partyDmg);\n\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\texp *= partyMul;\n\t\t\t\t\t\tsp *= partyMul;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check for an over-hit enabled strike\n\t\t\t\t\t\t// (When in party, the over-hit exp bonus is given to the whole party and splitted proportionally through the party members)\n\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Distribute Experience and SP rewards to L2PcInstance Party members in the known area of the last attacker\n\t\t\t\t\t\tif (partyDmg > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tattackerParty.distributeXpAndSp(exp, sp, rewardedMembers, partyLvl);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t}", "public void actionCombat(Party p1) {\n System.out.println(\"______________________________________________________________________________\\n\");\n System.out.println(this.Name + \" is attacking ...\");\n int choice = (int)(Math.random() * p1.getTeam().size());\n Character target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n\n if (this.SPEED - target.getSPEED() < 5) {\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n }\n else {\n int n = 0;\n while ((target.actualHP != 0) && (n < 2)) {\n if (n == 1) {\n choice = (int)(Math.random() * p1.getTeam().size() + 1);\n target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n }\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n if (n == 0) System.out.println(this.Name + \" attacks again ...\");\n n++;\n }\n }\n }", "public void incrementAttack(Fighter f1, Fighter f2)\r\n {\r\n if(f1.getAttacking() == 1) //if the fighter is attacking\r\n {\r\n if(f1.getAttackT() == 5) //if 5 frames have passed\r\n {\r\n int[] i = new int[4]; \r\n i = attackHitBox(f1); //gets the x,y, height, and width of the attack\r\n \r\n //if the attack position overlapps the other fighter's position and the other fighter isn't blocking\r\n if (i[0] <= f2.getPos()[0] + f2.getSize() && i[0] + i[2] >= f2.getPos()[0] && i[1] <= f2.getPos()[1] + f2.getSize() && i[1] + i[3] >= f2.getPos()[1] && f2.getBlocking() != 1)\r\n {\r\n f2.setHealth(f2.getHealth() - f1.getAttack().getDamage()); //deal damage to the fighter\r\n if(f1.getRight() == true){ \r\n f2.setKnockBackVel(f1.getAttack().getKnockBack()[0],f1.getAttack().getKnockBack()[1]); //apply knockback going right\r\n }else\r\n {\r\n f2.setKnockBackVel(-f1.getAttack().getKnockBack()[0],f1.getAttack().getKnockBack()[1]); //apply knockback going left\r\n }\r\n }\r\n f1.setAttackT(0); //reset attack timer\r\n f1.setAttacking(2); //sets the fighter to cooldown\r\n }else\r\n {\r\n f1.setAttackT(f1.getAttackT() + 1); //increments timer\r\n }\r\n }\r\n\r\n if(f1.getAttacking() == 2) //if fighter is in cooldown\r\n {\r\n if(f1.getAttackT() == f1.getAttack().getTime()) //if the timer has waited the cooldown of the last attack\r\n {\r\n f1.setAttackT(0); //resets the timer\r\n f1.setAttacking(0); //sets the fighter to \"can attack\"\r\n }\r\n else\r\n {\r\n f1.setAttackT(f1.getAttackT() + 1); //increment timer\r\n }\r\n }\r\n }", "@Override\n\tpublic void addInformation(ItemStack is, EntityPlayer player, List l, boolean b){\n\t\tl.add(\"This staff is magical!\");\n\t}", "float shouldAggroOnHit(IGeneticMob geneticMob, EntityLiving attacker);", "public void battleEnemyAttack() {\n if(battleEnemy != null){ // If all enemies have attacked, they cannot attack anymore for this round\n\n MovingEntity target = battleEnemy.getAttackPreference(targetAllies);\n if(target == null){\n target = targetAlly;\n }\n\n battleEnemy.attack(target, targetEnemies, targetAllies);\n //System.out.println(battleEnemy.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still friendly incase of zombify\n targetAlly = checkSideSwap(targetAlly, false, battleEnemies, targetEnemies, battleAllies, targetAllies);\n }\n\n battleEnemy = nextAttacker(battleEnemy, battleEnemies);\n\n }\n }", "@Override\n public void attack(Entity e) {\n e.hit(atk);\n }", "public void attack(ItemWeapon w, Monster target) {\n\t\ttarget.takeDamage(w.getDamage()+level*20);\n\t}", "@Override\n\tpublic void skill2(Fightable f) {\n\t\tsuper.setDamage(super.getStrength()*2);\n\t\tsuper.setAtkRange((int)(super.getDamage()/10));\n\t\t\n\t\tthis.attack(f, 3);\n\t}", "private float setAttackAbsorption(HashMap content) {\n\t\tfloat change = calculateAbsorption();\n this.attackDamageModifier = baseDamageModifier + change;\n//System.out.println(\"attack: \" + this.attackDamageModifier);\n content.put(\"attack_damage_modifier\", \"\" + this.attackDamageModifier);\n\t\treturn change*ABSORPTION_PRICE_MULTIPLIER;\n }", "@Override\r\n public void onHit(int damage){\n if(box2body != null){\r\n hp -= damage;\r\n screen.getGameManager().get(\"Sounds/orc-34-hit.wav\", Sound.class).play();\r\n if(this.hp <= 0) {\r\n screen.bodiesToDelete.add(box2body);\r\n deleteFlag = true;\r\n screen.spawnedCreatures.remove(this);\r\n screen.getGameManager().get(\"Sounds/orc-32-death.wav\", Sound.class).play();\r\n\r\n //Award Experience\r\n screen.getPlayer().awardExperience(this.experienceValue);\r\n screen.getPlayer().increaseKillCount();\r\n }\r\n }\r\n //Attack player when damaged\r\n //Prevents player from sniping monsters using Wander AI\r\n if(currentState != State.ATTACKING){\r\n Vector2 orcPosition = new Vector2(box2body.getPosition().x, box2body.getPosition().y);\r\n Vector2 playerPosition = new Vector2(screen.getPlayer().box2body.getPosition().x, screen.getPlayer().box2body.getPosition().y);\r\n\r\n currentState = State.HASBEENATTACKED;\r\n velocity = new Vector2(playerPosition.x - orcPosition.x, playerPosition.y - orcPosition.y);\r\n box2body.setLinearVelocity(velocity.scl(speed));\r\n }\r\n }", "protected void onImpact(RayTraceResult result) {\n\t\tif (result.entityHit != null) {\n\t\t\tfloat i = 2.5F;\n\n\t\t\tif (result.entityHit instanceof EntityBlizzard) {\n\t\t\t\ti = 0;\n\t\t\t}\n\n result.entityHit.attackEntityFrom(WorldsRetold.HAIL, i);\n\n\t\t\tif (result.entityHit instanceof EntityLivingBase) {\n\t\t\t\tEntityLivingBase target = (EntityLivingBase) result.entityHit;\n\t\t\t\tif (!this.world.isRemote) {\n\t\t\t\t\ttarget.addPotionEffect(new PotionEffect(HailstormPotions.FREEZING, 100, 0));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (!this.world.isRemote) {\n\t\t\tthis.world.setEntityState(this, (byte) 3);\n\t\t\tthis.setDead();\n\t\t}\n\t}", "@SideOnly(Side.CLIENT)\r\n @Override\r\n public void addInformation(ItemStack stack, @Nullable World playerIn, List<String> list, ITooltipFlag advanced)\r\n {\r\n if (stack.hasTagCompound() && stack.getTagCompound().hasKey(\"dyeColour\"))\r\n {\r\n int damage = stack.getTagCompound().getInteger(\"dyeColour\");\r\n EnumDyeColor colour = EnumDyeColor.byDyeDamage(damage);\r\n String s = I18n.format(colour.getUnlocalizedName());\r\n list.add(s);\r\n }\r\n }", "public void shoot(){\n // boss bullete attract to player\n int bulletPosX = PApplet.parseInt(posX + (speed * cos(angle)));\n int bulletPosY = (int)(posY + hei / 2);\n float bulletAngle = atan2(Main.player.posY - bulletPosY, Main.player.posX - bulletPosX);\n int bulletVelX = (int)(8 * cos(bulletAngle));\n int bulletVelY = (int)(8 * sin(bulletAngle));\n bossBullets.add(new Bullet(bulletPosX,bulletPosY,bulletVelX,bulletVelY,1,attack));\n }", "public void hit(int melee_dmg,int range_dmg) {\n melee_dmg=this.current_atk-30;\n range_dmg=this.current_atk-60;\n }", "void addAttack(AttackObject newAttack) {\n if (canAddAttack(newAttack)) {\n attacksToAdd.add(newAttack);\n if(newAttack.isPlayerAttack()){\n playerAttackCount++;\n }\n }\n }", "int aggroHitTimer(IGeneticMob geneticMob, EntityLiving attacker);", "public void attack(User p)\n\t{\n\t\tint damage = getAttack() - p.getDefense();\n\t\tint evade = 0;\n\t\tif(damage <= 0)\n\t\t{\n\t\t\tevade = p.getDefense() - getAttack();\n\t\t\tdamage = 1;\n\t\t}\n\t\t\n\t\tif(Math.random() * 100 < evade * 5)\n\t\t{\n\t\t\tJOptionPane.showMessageDialog(null, \"Miss\");\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tp.reduce(damage);\n JOptionPane.showMessageDialog(null,\"Enemy attacked you! User's health = \" + p.getHealth() + \"\\n\" + \"Damage dealt = \" + damage); \n\t}", "public void addAbsorber(final L2PcInstance attacker, final int crystalId)\n\t{\n\t\t// This just works for targets like L2MonsterInstance\n\t\tif (!(this instanceof L2MonsterInstance))\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// The attacker must not be null\n\t\tif (attacker == null)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// This L2Attackable must be of one type in the absorbingMOBS_levelXX tables.\n\t\t// OBS: This is done so to avoid triggering the absorbed conditions for mobs that can't be absorbed.\n\t\tif (getAbsorbLevel() == 0)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// If we have no absorbersList initiated, do it\n\t\tAbsorberInfo ai = absorbersList.get(attacker);\n\t\t\n\t\t// If the L2Character attacker isn't already in the absorbersList of this L2Attackable, add it\n\t\tif (ai == null)\n\t\t{\n\t\t\tai = new AbsorberInfo(attacker, crystalId, getCurrentHp());\n\t\t\tabsorbersList.put(attacker, ai);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tai.absorber = attacker;\n\t\t\tai.crystalId = crystalId;\n\t\t\tai.absorbedHP = getCurrentHp();\n\t\t}\n\t\t\n\t\t// Set this L2Attackable as absorbed\n\t\tabsorbSoul();\n\t\t\n\t\tai = null;\n\t}", "public void attack() {\n\t\t\n\t\tint row = getPosition().getRow();\n\t\tint column = getPosition().getColumn();\n\t\t\n\t\tgetPosition().setCoordinates(row + 1, column);\n\t\tsetPosition(getPosition()) ;\n\t\t// restore health\n\t\tsetHealth(100);\n\t\t// end hunter mode\n\t\tthis.hunter = false;\n\t\t\n\t}", "public void update(ArrayList<Bullet> projectileList, ArrayList<ZOrderableSprite> zOrderableSpriteList) {\n\n // Increment AI timer\n aiTimer += Gdx.graphics.getDeltaTime();\n aiTimer2 += Gdx.graphics.getDeltaTime();\n // Increment attack timer\n attackTimer += Gdx.graphics.getDeltaTime();\n // 0: Random Walking AI: the enemie will either stay idle or walk around randomly\n if(aiType == 0) {\n // hostile: false\n randomWalkingAI(false, null, null);\n }\n /*\n 1: Hostile random Walking AI: the enemie will attack the player is close enough,\n else the enemie will either stay idle or walk around randomly\n */\n else if(aiType == 1) {\n // Hostile\n randomWalkingAI(true, projectileList, zOrderableSpriteList);\n }\n\n // Update animations\n animation.update();\n\n // Update particles\n updateParticles();\n\n // Update enemie position\n updatePosition();\n\n // Update hp bar\n hpBar.update(currentHp, maximumHp, currentShield, maximumShield);\n hpBar.updatePosition(hitbox.getX(), hitbox.getY() - 7);\n\n // Enemie will shine red light when damaged\n\t\tif(colorValue < 1) {\n\t\t\tcolorValue += Gdx.graphics.getDeltaTime() * 2;\n\t\t}\n }", "private void UpdateBullets()\n\t {\n\t for(int i = 0; i < BulletList.size(); i++)\n\t {\n\t Bullet bullet = BulletList.get(i);\n\t \n\t // Move the bullet.\n\t bullet.Update();\n\t \n\t // checks if the bullet has it left the screen\n\t if(bullet.HasLeftScreen()){\n\t BulletList.remove(i);\n\t \n\t continue;\n\t }\n\t \n\t // checks if the bullet hit the enemy\n\t Rectangle BulletRectangle = new Rectangle((int)bullet.xCoord, (int)bullet.yCoord, bullet.BulletImage.getWidth(), bullet.BulletImage.getHeight());\n\t // Go trough all enemies.\n\t for(int j = 0; j < EnemyList.size(); j++)\n\t {\n\t Enemy eh = EnemyList.get(j);\n\n\t \n\t Rectangle EnemyRectangel = new Rectangle(eh.xCoord, eh.yCoord, eh.EnemyHelicopterImage.getWidth(), eh.EnemyHelicopterImage.getHeight());\n\n\t // Checks whether the the bullet has hit the enemy\n\t if(BulletRectangle.intersects(EnemyRectangel))\n\t {\n\t // Bullet hit the enemy so we reduce his health.\n\t eh.Health -= Bullet.DamagePower;\n\t \n\t // Bullet was also destroyed so we remove it.\n\t BulletList.remove(i);\n\t \n\t \n\t }\n\t }\n\t }\n\t }", "public void addGold(int g){\n this.gold += g;\n }", "public void gettingAttacked(HitByBulletEvent e) {\r\n\t\tif (gotTarget) {\r\n\t\t\tfor (int i = 0; i < enemyTracker.getEnemyList().size(); i++) {\r\n\t\t\t\tif (enemyTracker.getEnemyList().get(i).getName().equals(e.getName()) && (!e.getName().equals(radarTarget.getName()))) {\r\n\t\t\t\t\t\tmrRobot.sendMessage(5, \"2\");\r\n\t\t\t\t\t\tradarTarget = enemyTracker.getEnemyList().get(getIndexForEnemy(e.getName()));\r\n\t\t\t\t\t\ttargetTracking.get(getIndexForName(mrRobot.getName())).updateTarget(radarTarget);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "void evadeAttack(IUnit attacker, int incomingDamage);", "@Override\n public void onTargetDamaged(LivingEntity user, Entity target, int level) {\n if(target instanceof LivingEntity) {\n\n //target.damage(DamageSource.LAVA, 3F);\n knockUp((PlayerEntity) user, (LivingEntity) target, 3F);\n }\n }", "public void givePlayerLevelBonus() {\n\t\tfor(Player p : playerList) {\n\t\t\tif(p.getType() == PlayerType.Agent) {\n\t\t\t\tp.addScore(5 * (currentLevel-1));\n\t\t\t}\n\t\t}\n\t\tserver.updateHighscoreList();\n\t\tserver.addTextToLoggingWindow(\"Server gives all players level bonus\");\n\t}", "@Override\n\tpublic void processIncommingHit(Hit hit, Entity target) {\n\t\tif (hit.getLook() == HitLook.MELEE_DAMAGE)\n\t\t\tmeleeDamage += hit.getDamage();\n\t\telse if (hit.getLook() == HitLook.RANGE_DAMAGE)\n\t\t\trangeDamage += hit.getDamage();\n\t\tif (hit.getLook() == HitLook.MAGIC_DAMAGE)\n\t\t\tmageDamage += hit.getDamage();\n\t}", "void takeDamage(HeroDamage enemy1, HeroDamage enemy2);", "public void applyEffects(GoodGuy gg) {\n\t\tif (gemType == 1) {\n\t\t\tgg.addHP(20);\n\t\t} else if (gemType == 2) {\n\t\t\tgg.addHP(50);\n\t\t} else if (gemType == 3) {\n\t\t\tgg.addStamina(20);\n\t\t} else if (gemType == 4) {\n\t\t\tgg.addStamina(50);\n\t\t} else {\n\t\t\tint mhp = gg.getMaxHP();\n\t\t\tint mst = gg.getMaxHP();\n\t\t\tgg.addHP(mhp);\n\t\t\tgg.addStamina(mst);\n\t\t}\n used = true;\n\t}", "public void addHitListenerToEnemy(HitListener hl) {\r\n for (Enemy e : enemies) {\r\n e.addHitListener(hl);\r\n }\r\n }", "@Override\n\t\tpublic void hit(Npc attacker, Mob defender, Hit hit) {\n\t\t}", "public void addDamage(int amount) {\n\t\tdamage = amount;\n\t}", "@Override\n\tpublic int fight(Enemy e1) {\n\t\tint damage = 0;\n\t\tRandom randomNum = new Random();\n\t\tdamage = 6 + randomNum.nextInt(4);\n\t\ttry {\n\t\t\te1.takeDamage(damage);\n\t\t} catch (InvalidDamageException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn damage;\n\t}", "public final Map<L2Character, AggroInfoHolder> getAggroList()\n\t{\n\t\treturn aggroList;\n\t}", "public void shootAimingBullet(){\n bossBullet = new BossBullet(bossBulletImage,this.getXposition() + 100, this.getYposition() + 100, 8, player, true);\n bulletList.add(bossBullet);\n }", "private void addAttacks(){\n while(!attacksToAdd.isEmpty()){\n attacks.add(attacksToAdd.remove());\n }\n }", "AbilityDamage getAbilityDamage();", "@Override\r\n\tpublic boolean damageEntity(DamageSource damagesource, float f2) {\n\t\tboolean toReturn = super.damageEntity(damagesource, f2);\r\n\t\tif(f2>=3 && !this.isInvulnerable(damagesource) && damagesource.getEntity()!=null && damagesource.getEntity().getBukkitEntity() instanceof Player) { // prevent things like snowball damage from triggering this ability\r\n\t\t\tif(random.nextInt(100)+1<=20) { //prevent boss from getting combo'd to hard in corner\r\n\t\t\t\tif(!teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity())) {\r\n\t\t\t\t\tteleportToEnemy();\t\t\r\n\t\t\t\t\tteleportCooldown.addCooldown((Player)damagesource.getEntity().getBukkitEntity());\r\n\t\t\t\t\tLog.info(teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity()));\r\n\t\t\t\t\tLog.info(((Player)damagesource.getEntity().getBukkitEntity()).getName());\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn toReturn;\r\n\t}", "public void displayDamageIndicator(Graphics2D g2d) {\n //so the damage indicator won't turn translucent\n g2d.setComposite(AlphaComposite.getInstance(AlphaComposite.SRC_OVER,\n 1f));\n this.damageIndicator.display(g2d, this.damageTaken);\n }", "@Override\n\t\t\tpublic void attack(Base enemy) {\n\t\t\t}", "public void attack() { \n db.attack(creatures.get(creatureId), players.get(playerId));\n creatures.set(creatureId, db.getCreature(creatures.get(creatureId).getId()));\n players.set(playerId, db.getPlayer(players.get(playerId).getId()));\n setTextFields();\n }", "@Override\n\tpublic void updateContext(ExtendedAgentContext bc) {\n\t\tHero h = bc.getHero();\n\t\tAbility lagunaBlade = h.getAbility(5);\n\n\t\tList<BaseEntity> entitiesInAttackRange = bc.findEntitiesInRadius(h, lagunaBlade.getCastRange());\n\n\t\tArrayList<BaseEntity> heroesInRange = new ArrayList<>();\n\t\tfor (BaseEntity e : entitiesInAttackRange) {\n\t\t\tif (e.getTeam() == bc.getEnemyTeam()) {\n\t\t\t\tif (e.isHero()) {\n\t\t\t\t\theroesInRange.add((BaseEntity) e);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tBaseEntity woundedHero = null;\n\t\tif (heroesInRange.size() > 0)\n\t\t\twoundedHero = heroesInRange.stream().min((a, b) -> Integer.compare(a.getHealth(), b.getHealth())).get();\n\n\t\tTarget target = new Target();\n\t\ttarget.setEntity(woundedHero);\n\t\ttarget.setAbility(h.getAbility(0));\n\t\tthis.context.setTarget(target);\n\t}", "public void applyEffectUser(Enemy user) {\n\t\tsuper.applyEffectsUser(user);\n\t\tuser.addEnrage(enrage);\n\t}", "@Override\n\tpublic void onAdd(final CSimulation game, final CUnit unit) {\n\t\tfinal List<CUnitAttack> unitSpecificAttacks = unit.getUnitSpecificAttacks();\n\t\tfinal int originalAttackCount = unitSpecificAttacks.size();\n\t\toriginalBaseAttackRates = new float[originalAttackCount];\n\t\tfor (int i = 0; i < originalAttackCount; i++) {\n\t\t\tfinal CUnitAttack originalAttack = unitSpecificAttacks.get(i);\n\t\t\toriginalBaseAttackRates[i] = originalAttack.getCooldownTime();\n\t\t}\n\t\tunit.setDisableAttacks(true);\n\t\tsuper.onAdd(game, unit);\n\t}", "@Override\n public void addDamage(Player shooter, int damage) {\n if(!this.equals(shooter) && damage > 0) {\n int num=0;\n boolean isRage = false;\n Kill lastKill = null;\n List<PlayerColor> marksToBeRemoved = marks.stream().filter(m -> m == shooter.getColor()).collect(Collectors.toList());\n damage += marksToBeRemoved.size();\n marks.removeAll(marksToBeRemoved);\n\n if (this.damage.size() < 11) { //11\n for (int i = 0; i < damage; i++)\n this.damage.add(shooter.getColor());\n num = this.damage.size();\n if (num > 10) { //10\n this.deaths++;\n this.isDead = true;\n if (num > 11) {\n isRage = true;\n shooter.addThisTurnMarks(this, 1); //the shooter receive a mark in case of rage\n }\n if (game != null)\n game.addThisTurnKill(shooter, this, isRage);\n\n } else if (num > 5)\n this.adrenaline = AdrenalineLevel.SHOOTLEVEL;\n else if (num > 2)\n this.adrenaline = AdrenalineLevel.GRABLEVEL;\n } else if (this.damage.size() == 11 && damage > 0) { //11\n lastKill = game.getLastKill(this);\n lastKill.setRage(true);\n shooter.addThisTurnMarks(this, 1); //the shooter receive a mark in case of rage\n if(game != null)\n game.notifyRage(lastKill);\n }\n if (game != null)\n game.notifyDamage(this, shooter, damage, marksToBeRemoved.size());\n }\n }", "@Override\n public void attack(){\n int xBullet=0,yBullet=0;\n switch(direction){\n case 0:\n xBullet=(int)(x+Sprite.python_left.getWidth()/3);\n yBullet=(int)(y+Sprite.python_left.getHeight()*3/4);\n break;\n case 1:\n xBullet=(int)(x+Sprite.python_left.getWidth()*3/4);\n yBullet=(int)(y+Sprite.python_left.getHeight()/4);\n break;\n case 2:\n xBullet=(int)(x+Sprite.python_left.getWidth()/3);\n yBullet=(int)(y+Sprite.python_left.getHeight()/4);\n break;\n case 3:\n xBullet=(int)(x+Sprite.python_left.getWidth()/4);\n yBullet=(int)(y+Sprite.python_left.getHeight()/4);\n break;\n }\n PythonBullet pythonBullet=new PythonBullet(xBullet,yBullet,board,Player.PLAYER_SPEED*1.5);\n pythonBullet.setDirection(direction);\n board.addBullets(pythonBullet);\n\n }", "public String attack() {\r\n\t\t\tthis.getCurrentEnemy().setHealth(this.getCurrentEnemy().getHealth()-this.getPlayer().getWeapon().getAttack());\r\n\t\t\tif(this.getCurrentEnemy().isDefeated()) {\r\n\t\t\t\tthis.setInBattle(false);\r\n\t\t\t\t\r\n\t\t\t\tthis.handleQuestrelatedEnemy(this.getCurrentEnemy());\r\n\t\t\t\t\r\n\t\t\t\tif(this.getCurrentEnemy().getLoot() != null) {\r\n\t\t\t\t\tthis.getPlayer().getCurrentLocation().addItem(this.getCurrentEnemy().getLoot());\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tthis.getPlayer().gainXp(this.getCurrentEnemy().getXpYield());\r\n\t\t\t\tthis.getPlayer().getCurrentLocation().removeNpc(this.getCurrentEnemy().getName());\r\n\t\t\t\tif(this.getCurrentEnemy().getClass().getName().equals(\"game.EnemyGuardian\")) {\r\n\t\t\t\t\t// adds paths between current location and location in the guardian, path names are specified in the guardian construction\r\n\t\t\t\t\tthis.getPlayer().getCurrentLocation().addPaths(this.getPlayer().getCurrentLocation(), ((EnemyGuardian)this.getCurrentEnemy()).getPathTo(),\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t((EnemyGuardian)this.getCurrentEnemy()).getGuardedLocation(), ((EnemyGuardian)this.getCurrentEnemy()).getPathFrom());\r\n\t\t\t\t\treturn \"You defeated \" + this.getCurrentEnemy().getName() + \". \\n\"\r\n\t\t\t\t\t\t\t+ ((EnemyGuardian)this.getCurrentEnemy()).getRevelationMessage() + \"\\n\";\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\treturn \"You defeated \" + this.getCurrentEnemy().getName() + \".\";\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tthis.triggerEnemyAttack();\r\n\t\t\t\t\tif(this.getPlayer().getHealth() <= 0) {\r\n\r\n\t\t\t\t\t\tthis.gameOver();\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\treturn \"You attacked \" + this.getCurrentEnemy().getName() + \" for \" + this.getPlayer().getWeapon().getAttack() + \" damage. \\n You DIED.\";\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse {\r\n\t\t\t\t\t\treturn \"You attacked \" + this.getCurrentEnemy().getName() + \" for \" + this.getPlayer().getWeapon().getAttack() + \" damage. \\n\"\r\n\t\t\t\t\t\t\t\t+ this.getCurrentEnemy().getName() + \" attacked you for \" + this.getCurrentEnemy().getAttack() + \" damage.\\n\"\r\n\t\t\t\t\t\t\t\t\t\t+ this.getCurrentEnemy().printHealth();\r\n\t\t\t\t\t}\r\n\t\t\t}\r\n\t\t}", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker)\n\t{\n\t\treduceCurrentHp(damage, attacker, true);\n\t}", "@Override\n public void visit(final Rogue rogue) {\n rogue.getFirstAbility().changeAllVictimModifier(DAMAGE_MODIFIER_FOR_ROGUE);\n rogue.getSecondAbility().changeAllVictimModifier(DAMAGE_MODIFIER_FOR_ROGUE);\n // anunt magicianul de ajutorul ingerului\n rogue.getEvent().anEventHappened(rogue, this, \"help\");\n // ofer Xp jucatorului pentru a trece la nivelul urmator\n rogue.gainXp(getNewXp(rogue));\n }", "public void setHungerDamage(float hunger);", "@Override\n\tpublic void onDamageDealt(Entity attacker, Entity defender, int damage, int attackType) {\n\n\t}", "public static void bullyAttack(){\n int punch = player.getHealth() - bullyHitPoints ;\n player.setHealth(punch);\n //Step 2: Conditional dialogue\n if(bullyHitPoints > 50) {\n System.out.println(textparser.getMassiveDamage() + bullyHitPoints + textparser.getToYou());\n }else if(bullyHitPoints > 25){\n System.out.println(textparser.getPunch() + bullyHitPoints + textparser.getToYou());\n }else{\n System.out.println(textparser.getDidntHurtMuch() + bullyHitPoints + textparser.getToYou());\n }\n }", "@Override\n\tpublic int calculateAttackType(Entity attacker, Entity defender) {\n\t\tif (attacker.getType() != EntityType.NPC || defender.getType() != EntityType.PLAYER) {\n\t\t\treturn ServerConstants.MELEE_ICON;\n\t\t}\n\t\tNpc attackerAsNpc = (Npc) attacker;\n\n\t\tint randomChanceOfAttack = ThreadLocalRandom.current().nextInt(0, 100);\n\n\t\tif (phase == AbyssalSirePhase.AWAKE) {\n\t\t\tif (randomChanceOfAttack <= 80 || spawns.stream().filter(n -> n != null && !n.isDead()).count() >= 2) {\n\t\t\t\tattack = AbyssalSireAttack.POISON;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.SPAWN;\n\t\t\t}\n\t\t} else if (phase == AbyssalSirePhase.MELEE_COMBAT) {\n\t\t\tif (randomChanceOfAttack <= 50) {\n\t\t\t\tattack = AbyssalSireAttack.SWIPE;\n\t\t\t} else if (randomChanceOfAttack <= 85) {\n\t\t\t\tattack = AbyssalSireAttack.TENDRIL_SWIPE;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.DOUBLE_TENDRIL_SWIPE;\n\t\t\t}\n\t\t} else if (phase == AbyssalSirePhase.MAGIC_COMBAT) {\n\t\t\tif (explosionState == AbyssalSireExplosionState.NONE && attackerAsNpc.getCurrentHitPoints() <= 139) {\n\t\t\t\tattack = AbyssalSireAttack.PORTAL;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.POISON;\n\t\t\t}\n\t\t}\n\t\treturn ServerConstants.MELEE_ICON;\n\t}", "private void damage(){\n\n LevelMap.getLevel().damage(dmg);\n //System.out.println(\"died\");\n setDie();\n }", "public void addHerbalismExp(int exp)\n\t{\n\t\tm_oldLevel = getHerbalismLevel();\n\t\tm_skillHerbExp = m_skillHerbExp + exp;\n\t\tif(getHerbalismLevel() > m_oldLevel && getHerbalismLevel() <= 100)\n\t\t{\n\n\t\t}\n\t}", "@Override\n public L2Attackable getActiveChar() { return (L2Attackable)super.getActiveChar(); }", "@Override\n public void attackedByPaladin(double attack) {\n this.attack += (2 * attack) / 3;\n damageCounter = Math.max(damageCounter - (2 * attack) / 3, 0);\n }", "public void applyDamage(int damage)\r\n\t{\r\n\r\n\t}", "@Override\n\tpublic void skill1(Fightable f) {\n\t\tsuper.setDamage(super.getStrength()*3);\n\t\tsuper.setAtkRange((int)(super.getDamage()/5));\n\t\t\n\t\tthis.attack(f, 2);\n\t}", "public static void combatPlayer(Player atk, EnemyObject def){\n\t\tif(atk.stat.getType() != def.stat.getType() ){\n\n\t\t\t\tint atkDamage = 0;\n\t\t\t\tatkDamage = atk.stat.toDamage();\n\t\t\t\tdef.stat.getDamage(atkDamage);\n\t\t\t\t//System.out.println(\"Attack!\");\n\t\t\t\t//System.out.println(\"Enemy get \"+ atkDamage + \" Damage\");\n\t\t\t\tif(def.stat.checkAlive()==false){\n\t\t\t\t\t//check the object die or not.\t\t\n\t\t\t\t\t\n\t\t\t\t\tif(def.stat.getType()==1){\n\t\t\t\t\t//System.out.println(\"Enemy Die\");\n\t\t\t\t\t\t//def.remove(0);\n\t\t\t\t\t\t//enemy die.\n\t\t\t\t\t\t//give exp to the user.\n\t\t\t\t\t\tint exp = def.stat.giveExp();\n\t\t\t\t\t\t\n\t\t\t\t\t\tatk.stat.getExp(exp);\n\t\t\t\t\t\t//System.out.println(\"Player get \"+exp+ \" exp\");\n\t\t\t\t\t\t//destroy the enemy object.-> ??\n\t\t\t\t\t}\n\t\t\t\t}\t\t\t\n\t\t\t\t//System.out.println(\"\\n\\nEvent number : \" + atk.stat.getEventNum()+\" \\n\");\n /*\n\t\t\t\tSystem.out.println(\"Enemy Health: \" + def.stat.getHP());\n\t\t\t\tSystem.out.println(\"\\n\\n Player Stat: \");\n\t\t\t\tSystem.out.println(\"\\nPlayer HP: \"+atk.stat.getHP());\n\t\t\t\tSystem.out.println(\"Level: \"+atk.stat.getLv());\n\t\t\t\tSystem.out.println(\"STR: \"+atk.stat.getStr());\n\t\t\t\tSystem.out.println(\"DEX: \"+atk.stat.getDex());\n\t\t\t\tSystem.out.println(\"Wis: \"+atk.stat.getWis());\n\t\t\t\tSystem.out.println(\"Con: \"+atk.stat.getCon()+\"\\n\");\t*/\t\t\t\n\t\t}\n\t}", "public void updateAllies(){\r\n List<Ally> allies = world.getAllies();\r\n ArrayList<Ally> deadAllies = new ArrayList<Ally>();\r\n for(Ally ally : allies){\r\n if(ally.getCurrHP() <= 0){\r\n deadAllies.add(ally);\r\n }\r\n }\r\n\r\n allies.removeAll(deadAllies);\r\n world.setNumAllies(allies.size());\r\n //numAllies.set(allies.size());\r\n }", "public void resolve(){\n logger.log(Level.FINE,attacker.getName()+\" withering attacked \"+defender.getName());\n AttackState state=new AttackState();\n state.weaponDamage=weapon.getDamage();\n state.initialAttackpool=baseAttackdice+baseAccuracy-woundpenalty;\n attacker.declareWitheringAttack(state); // If the attacker wants to change the pool, he modifies the state accordingly.\n defender.declareWitheringDV(state); // Defender declares their dv against this specific attack. This sets both initialdv and changedDv\n state.initialAttackRoll= new DiceThrow(state.changedAttackpool);\n attacker.modifyWitheringAttackRollAttacker(state); //This sets stuff like modifiedAttackRollAttacker and AttackerRollValuation\n defender.modifyWitheringAttackRollDefender(state); //This sets defender modifiedAttackRollDefender\n state.attackRollSuccesses=state.modifiedAttackRollDefender.evaluateResults(state.AttackRollValuationAttacker);\n state.threshholdSuccesses=state.attackRollSuccesses-state.changedDv;\n logger.log(Level.FINE,attacker.getName()+\" rolled \"+state.changedAttackpool+\" dice against \"+defender.getName()+\"'s dv of \"+state.changedDv+\" and gained \"+state.attackRollSuccesses+\" successes.\");\n attacker.changeWitheringThreshholdAttacker(state); //This sets thresholdModifiedAttacker\n defender.changeWitheringThreshholdDefender(state); //This sets thresholdModifiedDefender\n if(state.thresholdModifiedDefender>=0) {\n logger.log(Level.FINE,attacker.getName()+\" hit \"+defender.getName()+\" with \"+state.thresholdModifiedDefender+\" threshhold successes.\");\n attacker.modifyWitheringRawDamageAttacker(state); //Sets normal raw damageType, based on strength and weapon damageType, and then sets rawDamagemModifiedAttacker\n defender.modifyWitheringRawDamageDefender(state); //this sets rawDamageModifiedDefender, and sets up the various soak values, so natural soak and armor soak.\n logger.log(Level.FINE, \"The raw damage of the attack is: \"+state.rawDamageModifiedDefender);\n state.totalSoak = Math.max(state.defenderArmorSoak - ignoredArmorSoak, 0) + state.defenderNaturalSoak; //\n attacker.modifyTotalSoakAttacker(state); //This sets totalSoakmodifiedAttacker. Don't think this actually has support in the solar charmset, but giving opportunities to work with.\n defender.modifyTotalSoakDefender(state); // This sets totalSoakmodifiedDefender.\n state.postSoakSuccesses=Math.max(state.rawDamageModifiedDefender-state.totalSoakModifiedDefender,weapon.getOverwhelming());\n logger.log(Level.FINE,state.totalSoakModifiedDefender+\" damage is soaked, leading to post soak dice of \"+state.postSoakSuccesses);\n attacker.declarePostSoakAttacker(state); //sets postSoakSuccessesModifiedAttacker\n defender.declarePostSoakDefender(state); //sets postSoakSuccessesModifiedDefender\n DiceThrow droll=new DiceThrow(state.postSoakSuccessesModifiedDefender);\n state.damageRoll=droll;\n attacker.modifyWitheringDamageRollAttacker(state); //sets damageRollmodifiedAttacker and damageRollvValuation\n defender.modifyWitheringDamageRollDefender(state); //sets damageRollmodifiedDefender\n state.initiativeDamageDone=state.damageRollModifiedDefender.evaluateResults(state.damageRollValuation);\n logger.log(Level.FINE,attacker.getName()+\" rolls \"+state.postSoakSuccessesModifiedDefender+\" dice and achieves \"+state.initiativeDamageDone+\" successes.\");\n attacker.modifyInitiativeDamageAttacker(state);\n defender.modifyInitiativeDamageDefender(state); //Since this is the last change of initiative, we can check whether the defender was crashed here.\n attacker.updateInitiativeAttacker(state);\n defender.updateInitiativeDefender(state);//Here we should handle all the initiative changes respectively, with checking if people are crashed etc.\n }\n else{\n attacker.failedWitheringAttackAttacker(state);\n defender.failedWitheringAttackDefender(state);\n }\n\n }", "@Override\r\n\tpublic void add(Army garrison) {\r\n\t\tgarrison.addArtillery(1);\r\n\t}", "public void attackEntity(Entity entityToHit) {\n ItemStack item = tinkerProjectile.getItemStack();\n ItemStack launcher = tinkerProjectile.getLaunchingStack();\n\n // deal damage if we have everything\n if(item.getItem() instanceof ToolCore && this.attacker != null) {\n EntityLivingBase attacker = (EntityLivingBase) this.attacker;\n //EntityLivingBase target = (EntityLivingBase) raytraceResult.entityHit;\n\n // find the actual itemstack in the players inventory\n ItemStack inventoryItem = AmmoHelper.getMatchingItemstackFromInventory(tinkerProjectile.getItemStack(), attacker, false);\n if(inventoryItem.isEmpty() || inventoryItem.getItem() != item.getItem()) {\n // backup, use saved itemstack\n inventoryItem = item;\n }\n\n // for the sake of dealing damage we always ensure that the impact itemstack has the correct broken state\n // since the ammo stack can break while the arrow travels/if it's the last arrow\n boolean brokenStateDiffers = ToolHelper.isBroken(inventoryItem) != ToolHelper.isBroken(item);\n if(brokenStateDiffers) {\n toggleBroken(inventoryItem);\n }\n\n Multimap<String, AttributeModifier> projectileAttributes = null;\n // remove stats from held items\n if(!world.isRemote) {\n unequip(attacker, EntityEquipmentSlot.OFFHAND);\n unequip(attacker, EntityEquipmentSlot.MAINHAND);\n\n // apply stats from projectile\n if(item.getItem() instanceof IProjectile) {\n projectileAttributes = ((IProjectile) item.getItem()).getProjectileAttributeModifier(inventoryItem);\n\n if(launcher.getItem() instanceof ILauncher) {\n ((ILauncher) launcher.getItem()).modifyProjectileAttributes(projectileAttributes, tinkerProjectile.getLaunchingStack(), tinkerProjectile.getItemStack(), tinkerProjectile.getPower());\n }\n\n // factor in power\n projectileAttributes.put(SharedMonsterAttributes.ATTACK_DAMAGE.getName(),\n new AttributeModifier(PROJECTILE_POWER_MODIFIER, \"Weapon damage multiplier\", tinkerProjectile.getPower() - 1f, 2));\n\n attacker.getAttributeMap().applyAttributeModifiers(projectileAttributes);\n }\n // deal the damage\n// ToolHelper.attackEntity(item, (ToolCore) item.getItem(), attacker, entityToHit, null);\n// float speed = MathHelper.sqrt(this.motionX * this.motionX + this.motionY * this.motionY + this.motionZ * this.motionZ);\n\n boolean attack = ToolHelper.attackEntity(item, (ToolCore) item.getItem(), attacker, entityToHit, null);\n// if(attack) {\n//// for(IProjectileTrait trait : tinkerProjectile.getProjectileTraits()) {\n//// trait.afterHit(tinkerProjectile.get, this.world, inventoryItem, attacker, entityToHit, (double) 0.0);\n//// }\n//\n// // if on fire, set the entity on fire, like vanilla arrows\n//// if (this.isBurning() && !(entityToHit instanceof EntityEnderman)) {\n//// entityToHit.setFire(5);\n//// }\n// }\n if(brokenStateDiffers) {\n toggleBroken(inventoryItem);\n }\n\n // remove stats from projectile\n // apply stats from projectile\n if(item.getItem() instanceof IProjectile) {\n assert projectileAttributes != null;\n attacker.getAttributeMap().removeAttributeModifiers(projectileAttributes);\n }\n\n // readd stats from held items\n equip(attacker, EntityEquipmentSlot.MAINHAND);\n equip(attacker, EntityEquipmentSlot.OFFHAND);\n }\n }else {\n System.out.println(\"something failed with attacking.\");\n }\n }", "public void attack(Entity entity, boolean aoe) {\n if(aoe) entity.damaged((int) (this.damage*0.6));\n else entity.damaged(this.damage);\n if(entity.isDead()){\n incExp(entity.getLevel()*9);\n if(entity instanceof Boss) {\n this.bossesDefeated++;\n }\n }\n }", "@Override\r\n public void applyAttributes() {\r\n super.applyAttributes();\r\n getEntity().setColor(color);\r\n getEntity().setOwner(MbPets.getInstance().getServer().getPlayer(getOwner()));\r\n getEntity().setAgeLock(true);\r\n\r\n if (isBaby) {\r\n getEntity().setBaby();\r\n } else {\r\n getEntity().setAdult();\r\n }\r\n Bukkit.getMobGoals().removeGoal(getEntity(), VanillaGoal.LLAMA_ATTACK_WOLF);\r\n Bukkit.getMobGoals().removeGoal(getEntity(), VanillaGoal.LLAMA_FOLLOW_CARAVAN);\r\n Bukkit.getMobGoals().removeGoal(getEntity(), VanillaGoal.TRADER_LLAMA_DEFEND_WANDERING_TRADER);\r\n }", "public void heal(){\n\t\thp += potion.getHpBoost();\n\t\tif(hp > max_hp)hp = max_hp;\n\t}", "public String getAsteroidAttack() {\n\t\tminusShield(2);\n\t\treturn \"Got damaged from the asteroid belt!!\";\n\t}", "public void addHealth(int amt) {\n currentHealth = currentHealth + amt;\n }", "@Override\n public void addInfo(CurrentPlayer currentPlayer) {\n godPower.addInfo(currentPlayer);\n }", "@SideOnly(Side.CLIENT)\n\tpublic void addInformation(ItemStack itemStack, EntityPlayer p_77624_2_, List list, boolean p_77624_4_) {\n\n\t\tif (itemStack.stackTagCompound != null) {\n\t\t\tString targetName = itemStack.stackTagCompound.getString(\"targetName\");\n\t\t\tString targetUUID = itemStack.stackTagCompound.getString(\"targetUUID\");\n\t\t\tlist.add(\"Target Name: \" + targetName);\n\t\t\tlist.add(\"Target UUID: \" + targetUUID);\n\n\t\t}\n\t}", "public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean smt) {\n/* 122 */ int standID = getStandID(stack);\n/* 123 */ if (standID == 0) {\n/* */ return;\n/* */ }\n/* */ \n/* */ \n/* 128 */ int standAct = getStandACT(stack);\n/* 129 */ int standExp = getStandEXP(stack);\n/* */ \n/* 131 */ String standName = getStandNAME(stack);\n/* 132 */ EntityOneStand standEnt = ItemStandArrow.getStand(standID, player.worldObj);\n/* 133 */ String standEntName = standEnt.getCommandSenderName();\n/* 134 */ if (standName.equals(\"\")) {\n/* */ \n/* 136 */ standName = getEntityStandName(standEnt);\n/* */ }\n/* */ else {\n/* */ \n/* 140 */ stack.setStackDisplayName(standEntName);\n/* */ } \n/* 142 */ String standActPre = StatCollector.translateToLocal(\"stands.jojobadv.Act.txt\");\n/* 143 */ String standExpPre = StatCollector.translateToLocal(\"stands.jojobadv.Exp.txt\");\n/* */ \n/* 145 */ list.add(standName);\n/* 146 */ list.add(standActPre + \" \" + standAct + \"!\");\n/* 147 */ list.add(standExpPre + \" \" + standExp);\n/* */ }", "public void getAttackedByDarknessMagicBook(IEquipableItem item){item.strongAttackTo(this.getOwner());}", "public void attack(Player player) {\n this.damage = 18 - player.getfPoint(); // the higher the Fighter skill,\n // the lower the damage. change the math.\n int newHealth = player.getShip().getHealth() - damage;\n player.getShip().setHealth(newHealth);\n }", "public void causeFoodExhaustion(float debug1) {\n/* 1797 */ if (this.abilities.invulnerable) {\n/* */ return;\n/* */ }\n/* */ \n/* 1801 */ if (!this.level.isClientSide) {\n/* 1802 */ this.foodData.addExhaustion(debug1);\n/* */ }\n/* */ }", "public void gainExperience(Combatant opponent) { }", "@Override\n public void onEntityUpdate() {\n if (!(world.provider instanceof WorldProviderLimbo || world.provider instanceof WorldProviderDungeonPocket)) {\n setDead();\n super.onEntityUpdate();\n return;\n }\n\n super.onEntityUpdate();\n\n // Check for players and update aggro levels even if there are no players in range\n EntityPlayer player = world.getClosestPlayerToEntity(this, MAX_AGGRO_RANGE);\n boolean visibility = player != null && player.canEntityBeSeen(this);\n updateAggroLevel(player, visibility);\n\n // Change orientation and face a player if one is in range\n if (player != null) {\n facePlayer(player);\n if (!world.isRemote && isDangerous()) {\n // Play sounds on the server side, if the player isn't in Limbo.\n // Limbo is excluded to avoid drowning out its background music.\n // Also, since it's a large open area with many Monoliths, some\n // of the sounds that would usually play for a moment would\n // keep playing constantly and would get very annoying.\n playSounds(player.getPosition());\n }\n\n if (visibility) {\n // Only spawn particles on the client side and outside Limbo\n if (world.isRemote && isDangerous()) {\n spawnParticles(player);\n }\n\n // Teleport the target player if various conditions are met\n if (aggro >= MAX_AGGRO && !world.isRemote && ModConfig.monoliths.monolithTeleportation && !player.isCreative() && isDangerous()) {\n aggro = 0;\n Location destination = WorldProviderLimbo.getLimboSkySpawn(player);\n TeleportUtils.teleport(player, destination, 0, 0);\n player.world.playSound(null, player.getPosition(), ModSounds.CRACK, SoundCategory.HOSTILE, 13, 1);\n }\n }\n }\n }", "public interface IHitAggro {\n /**\n * shouldAggroOnHit\n * The chance (where 1.0F = 100%) that this mob would be aggroed if struck by this entity\n * Should NOT trigger the aggro itself! That should only occur when actually hit!\n * @param geneticMob the mob being checked\n * @param attacker the entity that could attack\n * @return the chance of aggro (1.0F = 100%, 0.0F = 0%)\n */\n float shouldAggroOnHit(IGeneticMob geneticMob, EntityLiving attacker);\n\n /**\n * aggroHitTimer\n * How long this mob would stay angry at this attacker if aggroed via hit\n * @param geneticMob the mob being checked\n * @param attacker the entity that could attack\n * @return the length, in ticks, of the timer\n */\n int aggroHitTimer(IGeneticMob geneticMob, EntityLiving attacker);\n }", "@SubscribeEvent(priority = EventPriority.NORMAL)\n public void onLivingAttack(EntityStruckByLightningEvent event) {\n\t\tempowerItem(event);\n\t\ttransformVillager(event);\n }", "public void addBreedingExp(int exp)\n\t{\n\t\tm_oldLevel = getBreedingLevel();\n\t\tm_skillBreedExp = m_skillBreedExp + exp;\n\t\tif(getBreedingLevel() > m_oldLevel)\n\t\t{\n\t\t\tServerMessage skillLevels = new ServerMessage(ClientPacket.SKILL_LVL_UP);\n\t\t\tskillLevels.addInt(getTrainingLevel());\n\t\t\tskillLevels.addInt(getBreedingLevel());\n\t\t\tskillLevels.addInt(getFishingLevel());\n\t\t\tskillLevels.addInt(getCoordinatingLevel());\n\t\t\tgetSession().Send(skillLevels);\n\t\t}\n\t}", "@Override\n public void adjustTypeAttributes() {\n this.getSpecialData().addAttribute(SharedMonsterAttributes.maxHealth, 20.0);\n }", "public boolean handleAttack(Action action) {\n ActorState a = action.getActor();\n if (a.getActor() == actor) {\n // Attacks on oneself always succeed, and we don't want to add ourselves as an enemy\n return true;\n }\n \n //maybeCounter(Augmentation.Type.ATTACK, a, combatants);\n enemies.add(a);\n \n double weaponAccuracy = 1.0; //source.getWeaponAccuracy(action);\n double chance = a.getAccuracy() * weaponAccuracy * (1.0 - getDefense());\n boolean success = Math.random() < chance;\n return success;\n }", "@SideOnly(Side.CLIENT)\n/* */ public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List<String> par3List, boolean par4) {\n/* 59 */ if (GuiScreen.isShiftKeyDown()) {\n/* 60 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome1.lore\"));\n/* 61 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome2.lore\"));\n/* 62 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome3.lore\"));\n/* 63 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* 64 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome4.lore\"));\n/* 65 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome5.lore\"));\n/* 66 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* 67 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome6.lore\"));\n/* 68 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome7.lore\"));\n/* 69 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome8.lore\"));\n/* 70 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* 71 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome9.lore\"));\n/* 72 */ } else if (GuiScreen.isCtrlKeyDown()) {\n/* 73 */ par3List.add(StatCollector.translateToLocal(\"item.FRVisPerSecond.lore\"));\n/* 74 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRAerCost.lore\") + (AerCost / 100.0D * 10.0D));\n/* 75 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRTerraCost.lore\") + (TerraCost / 100.0D * 10.0D));\n/* 76 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRIgnisCost.lore\") + (IgnisCost / 100.0D * 10.0D));\n/* 77 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRPerditioCost.lore\") + (PerditioCost / 100.0D * 10.0D));\n/* */ } else {\n/* */ \n/* 80 */ par3List.add(StatCollector.translateToLocal(\"item.FRShiftTooltip.lore\"));\n/* 81 */ par3List.add(StatCollector.translateToLocal(\"item.FRViscostTooltip.lore\"));\n/* */ } \n/* */ \n/* 84 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* */ }", "void defendAttack(IUnit attacker, int incomingDamage);", "public void equip(Hero h) {\n\t\tfor(Weapon w : h.getInventory().getWeaponList()) {\n\t\t\tif(w.getName().equals(this.getName())) {\n\t\t\t\tw.setEquipped(true);\n\t\t\t\tw.statsIncrease(h, StatType.STRENGTH, getWeaponDmg());\n\t\t\t} else {\n\t\t\t\tw.unequip(h);\n\t\t\t}\n\t\t}\n\t}", "@Override\r\n\tpublic void useSkill() {\n\t\tthis.defense+=20;\r\n\t\tthis.maxHp+=(this.maxHp/2);\r\n\t\tthis.hp+=(this.hp/2);\r\n\t\tthis.skillActive = true;\r\n\t\tthis.skillLast = 2;\r\n\t}", "public abstract void attack(Vector2 spawnPos, Vector2 target);" ]
[ "0.6253089", "0.57068497", "0.56932586", "0.5654625", "0.5603246", "0.55689013", "0.55460656", "0.55005455", "0.5480614", "0.547901", "0.5450687", "0.54407215", "0.5416241", "0.5311458", "0.5289254", "0.52837044", "0.5273938", "0.5257808", "0.5253196", "0.524466", "0.5218901", "0.5188448", "0.51876503", "0.5187386", "0.5186334", "0.51717997", "0.51696503", "0.5157723", "0.51554924", "0.513009", "0.51299095", "0.5128857", "0.51244724", "0.51114345", "0.5109865", "0.5108455", "0.5098062", "0.50971663", "0.50968105", "0.5088162", "0.50786966", "0.5062287", "0.50588083", "0.50515777", "0.50477535", "0.5047674", "0.504659", "0.5035345", "0.50306946", "0.50074124", "0.5003741", "0.5002261", "0.49959236", "0.4995425", "0.49942288", "0.49938652", "0.49914035", "0.4990968", "0.4988477", "0.498567", "0.49824056", "0.49790987", "0.4977781", "0.49717844", "0.49693236", "0.49608994", "0.49545446", "0.49432585", "0.49418628", "0.4940741", "0.49381277", "0.49358553", "0.4934193", "0.49336332", "0.49327052", "0.49255547", "0.4923687", "0.49183515", "0.491168", "0.4906362", "0.49015838", "0.49003294", "0.48991543", "0.4893955", "0.4888409", "0.48836145", "0.4882175", "0.48763615", "0.4871678", "0.48694152", "0.4868698", "0.4867834", "0.4865243", "0.48506504", "0.48483288", "0.4846405", "0.4846222", "0.48410726", "0.4839229", "0.48345432" ]
0.7877994
0
Clears aggroList hate of the L2Character without removing from the list.
public void stopHating(final L2Character target) { if (target == null) { return; } AggroInfoHolder ai = getAggroListRP().get(target); if (ai == null) { return; } ai.initHate(); ai = null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void clearAggroList()\n\t{\n\t\tgetAggroList().clear();\n\t}", "public void clear() {\n\t\tlist = new ArrayList<String>();\n\t\tword = \"\";\n\t}", "public void clear() {\n\t\twordList.removeAll(wordList);\n\t\t// TODO Add your code here\n\t}", "public void clear()\n {\n int llSize = ll.getSize();\n for(int i=0; i<llSize; i++){\n ll.remove(0);\n }\n }", "public void clear()\n {\n clear(BLACK);\n }", "public void clear() {\r\n GiftList.clear();\r\n names = new LinkedList<>();\r\n totalGifts = 0;\r\n totalCost = 0;\r\n }", "public void clear() {\n lb.setText(\"\");\n }", "@DSComment(\"From safe class list\")\n @DSSafe(DSCat.SAFE_LIST)\n @DSGenerator(tool_name = \"Doppelganger\", tool_version = \"2.0\", generated_on = \"2013-12-30 12:27:59.781 -0500\", hash_original_method = \"DDCDD16B215513F049C48DCCB34052D5\", hash_generated_method = \"E2BF4A07043A385FD8DCCBBCD0FC0AF4\")\n \npublic static void clear(Editable e) {\n e.clear();\n e.removeSpan(ACTIVE);\n e.removeSpan(CAPPED);\n e.removeSpan(INHIBIT_REPLACEMENT);\n e.removeSpan(LAST_TYPED);\n\n QwertyKeyListener.Replaced[] repl = e.getSpans(0, e.length(),\n QwertyKeyListener.Replaced.class);\n final int count = repl.length;\n for (int i = 0; i < count; i++) {\n e.removeSpan(repl[i]);\n }\n }", "public void clear() {\n\t\tstringList = null;\n\t}", "public void clearWordList () {\r\n words.clear ();\r\n Components.wordList.getContents ().removeAllElements ();\r\n }", "public void Reset()\n {\n this.list1.clear();\n }", "public void clear(){\n\n \tlist = new ArrayList();\n\n }", "@Override\n public void clear() {\n wordsLinkedList.clear();\n }", "public void clear() {\r\n\t\tdisplayEntries.clear();\r\n\t\tupdate();\r\n\t}", "public void clear() {\r\n this.line.clear();\r\n }", "public void clear() {\n list = new Object[MIN_CAPACITY];\n n = 0;\n }", "public void clearGameList() {\n gameJList.removeAll();\n }", "public void clearStartAlphabet()\n\t\t\t{\n\t\t\t}", "public void clear()\n {\n dessertList.clear();\n }", "private void clear(AutoCompleteTextView view) {\n view.setText(\"\");\n }", "@Override\r\n\tpublic void Clear() {\r\n\t\tthis.tav='*';\t\r\n\t}", "void clear() {\n _whoseMove = WHITE;\n _gameOver = false;\n\n for (int i = 0; i <= MAX_INDEX; i += 1) {\n set(i, BLACK);\n }\n for (int i : _initWhite) {\n set(i, WHITE);\n }\n set(12, EMPTY);\n _history.clear();\n\n setInitialDirection(MAX_INDEX);\n\n setChanged();\n notifyObservers();\n }", "public void remove() {\r\n // rather than going through replace(), just reinitialize the StyledText,\r\n // letting the old data structures fall on the floor\r\n fCharBuffer = new CharBuffer();\r\n fStyleBuffer = new StyleBuffer(this, AttributeMap.EMPTY_ATTRIBUTE_MAP);\r\n fParagraphBuffer = new ParagraphBuffer(fCharBuffer);\r\n fTimeStamp += 1;\r\n fDamagedRange[0] = fDamagedRange[1] = 0;\r\n }", "protected void clear()\n\t{\n\t\tsuper.clear();\n\t\tindentRight();\n\t}", "void clear_display(char[][] _display) {\n for (int i = 0; i < 72; i++) {\n for (int j = 0; j < 37; j++) {\n _display[i][j] = ' ';\n }\n }\n }", "public void clearConcertList(){\n concertList.clear();\n }", "void clear() ;", "public abstract void clearSelection(TextAppearance appearance);", "public void clearTheGame() {\n players.clear();\n categories.clear();\n playedRounds = 0;\n indexOfActiveCategory = -1;\n indexOfActivePlayer = 0;\n numberOfRounds = 0;\n }", "public void clearHand(){\n\t\tthis.hand = new ArrayList<Card>();\n\t}", "public void ClearGame(){\n handComputer.clear();\n handHuman.clear();\n deck.clear();\n }", "public void clear()\r\n {\r\n \tdisplayUserInput = \" \";\r\n \t\r\n }", "public void clearList() {\n\t\thead = null;\n\t\tlength = 0;\n\t}", "public void clear() {\n \tthis.listShapes.clear();\n }", "public void tyhjenna() {\n this.kulmat.clear();\n }", "private void actionClear() {\n layoutPanel.inhNList.clear();\n layoutPanel.activeNList.clear();\n layoutPanel.probedNList.clear();\n\n Graphics g = layoutPanel.getGraphics();\n layoutPanel.writeToGraphics(g);\n }", "@Override\n public void clear() {\n beginMyTurn();\n }", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear() {\r\n myCommandLine.clear();\r\n inputPositionX.clear();\r\n inputPositionY.clear();\r\n creatureHomeX = creatureHomeY = 0;\r\n myModelTokenIndex = 0;\r\n commandHistory.getMenus().get(0).getItems().clear();\r\n continuing = false;\r\n if (myAnimation != null) {\r\n myAnimation.stop();\r\n }\r\n }", "public void clear() {\n\t\tlists.clear();\n\t}", "public void clear()\r\n {\r\n super.clear();\r\n }", "public void clearList()\n\t{\n\t\tnodeManager.clearList();\n\t}", "public String clear();", "public void clear() {\n doClear();\n }", "public void clear()\n {\n }", "private void clear() {\r\n\t\tpstate.clear();\r\n\t\tdisplay.setLegend(\"\");\r\n\t\tship = null;\r\n\t}", "private void clear() {\n }", "public void clear() {\r\n\tcount = 0;\r\n isDrawn = false;\r\n repaint();\r\n }", "public void clear() {\n\t\t\r\n\t}", "public abstract void clear();", "public abstract void clear();", "public abstract void clear();", "public abstract void clear();", "public void clear() {\r\n\t\tremoveAll();\r\n\t\tdrawBackGround();\r\n\t\tclearEntries();\r\n\t\t\r\n\t}", "public void clearPurchaseList()\r\n\t{\r\n\t\tm_purechaseList.clear();\r\n\t}", "public String clear() {\n\t\t\tcollectionsOlders.clear();\n\t\t\treturn \"Коллекция была очищена\";\n\t\t}", "public void clear() {\n\t\thighlightsByToken.clear();\n\t}", "public void clear(){\n\t\tclear(0);\n\t}", "public static void emptyWishlist() {\n click(WISHLIST_UPPER_MENU);\n click(REMOVE_FROM_WISHLIST_BUTTON);\n }", "public void reset() {\n this.list.clear();\n }", "public void clear() {\n }", "public void clear() {\n doClear( false );\n }", "public void clear()\r\n {\r\n phoneList = new ArrayList<String>();\r\n }", "public void clearHand() {\n cards.clear();\n aceCount = 0;\n setSize(0);\n }", "void clear();", "void clear();", "void clear();", "void clear();" ]
[ "0.6956726", "0.6444667", "0.6303779", "0.61941636", "0.6161129", "0.6115258", "0.6102887", "0.6066528", "0.6064297", "0.6046399", "0.6042214", "0.5957658", "0.59415174", "0.592727", "0.59178734", "0.5907068", "0.5898708", "0.5875746", "0.5857685", "0.58546567", "0.5842831", "0.58352864", "0.5833637", "0.58026993", "0.5799937", "0.5788511", "0.57819486", "0.57759947", "0.5775207", "0.577193", "0.5758136", "0.57324076", "0.5722334", "0.57179606", "0.5717412", "0.57154155", "0.57125187", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.57109386", "0.5705438", "0.57030195", "0.5702223", "0.5699276", "0.5690105", "0.5688802", "0.5675363", "0.5668158", "0.5667", "0.5665784", "0.56564474", "0.5634717", "0.5634717", "0.5634717", "0.5634717", "0.563427", "0.5634183", "0.5630024", "0.56208414", "0.56167835", "0.56128716", "0.56051975", "0.56051826", "0.5603794", "0.5602788", "0.5598763", "0.5588544", "0.5588544", "0.5588544", "0.5588544" ]
0.0
-1
Return the most hated L2Character of the L2Attackable aggroList.
public L2Character getMostHated() { if (getAggroListRP().isEmpty() || isAlikeDead()) { return null; } L2Character mostHated = null; int maxHate = 0; // While Interating over This Map Removing Object is Not Allowed synchronized (getAggroList()) { // Go through the aggroList of the L2Attackable for (final AggroInfoHolder ai : getAggroListRP().values()) { if (ai == null) { continue; } if (ai.getAttacker().isAlikeDead() || !getKnownList().knowsObject(ai.getAttacker()) || !ai.getAttacker().isVisible() || ai.getAttacker() instanceof L2PcInstance && !((L2PcInstance) ai.getAttacker()).isOnline() && !((L2PcInstance) ai.getAttacker()).isInOfflineMode()) // if player go // in offline // mode, he // must be hated // however { ai.initHate(); } if (ai.getHate() > maxHate) { mostHated = ai.getAttacker(); maxHate = ai.getHate(); } } } if (mostHated != null) { this.mostHated = mostHated; } return mostHated; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public L2Attackable getActiveChar() { return (L2Attackable)super.getActiveChar(); }", "public int getHighestCombatSkill() {\r\n int id = 0;\r\n int last = 0;\r\n for (int i = 0; i < 5; i++) {\r\n if (staticLevels[i] > last) {\r\n last = staticLevels[i];\r\n id = i;\r\n }\r\n }\r\n return id;\r\n }", "public int getHating(final L2Character target)\n\t{\n\t\tif (getAggroListRP().isEmpty())\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tif (target == null)\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tfinal AggroInfoHolder ai = getAggroListRP().get(target);\n\t\t\n\t\tif (ai == null)\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tif (ai.getAttacker() instanceof L2PcInstance && (((L2PcInstance) ai.getAttacker()).getAppearance().isInvisible() || ((L2PcInstance) ai.getAttacker()).isSpawnProtected() || ((L2PcInstance) ai.getAttacker()).isTeleportProtected() || ai.getAttacker().isInvul()))\n\t\t{\n\t\t\t// Remove Object Should Use This Method and Can be Blocked While Interating\n\t\t\tgetAggroList().remove(target);\n\t\t\t\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tif (!ai.getAttacker().isVisible())\n\t\t{\n\t\t\tgetAggroList().remove(target);\n\t\t\t\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tif (ai.getAttacker().isAlikeDead())\n\t\t{\n\t\t\tai.initHate();\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\treturn ai.getHate();\n\t}", "public Attack getBestOpponentAttack()\n\t{\n\t\treturn bestOpponentAttack;\n\t}", "public int getBestGuy () {\r\n return poblac.getBestGuy();\r\n }", "public Entity getHighestCombatActionsEntity() {\n Entity mostCombatActionsEntity = playerInCombat; // Entity accumulator\n for (Entity entity : enemiesInCombat) {\n if (entity.getCombatActions() > mostCombatActionsEntity.getCombatActions()) {\n mostCombatActionsEntity = entity;\n }\n }\n return mostCombatActionsEntity;\n }", "CharacterStatistic getCharacterStatistic();", "CharacterStatistic getBasedOn();", "public static String getMostFrequentToy() {\n\t\tString name = \"\";\n\t\tint max = 0;\n\t\tfor (int i = 0; i < toyList.size(); i++) {\n\t\t\tif (max < toyList.get(i).getCount()) {\n\t\t\t\tmax = toyList.get(i).getCount();\n\t\t\t\tname = toyList.get(i).getName();\n\t\t\t}\n\t\t}\n\t\treturn name;\n\t}", "public String StrongestWeapon() {\n\t\tString weapon = \"fists\";\n\t\tfor (Item temp: rooms.player.getItems()) {\t\t\t\t// Goes through all items in bag\n\t\t\tif (temp.getID() == \"pocket knife\" && !weapon.equals(\"wrench\")){ // Has pocket knife\n\t\t\t\tweapon = \"pocket knife\";\n\t\t\t}else if (temp.getID() == \"wrench\"){\t\t\t\t// Has wrench\n\t\t\t\tweapon = \"wrench\";\n\t\t\t}else if (temp.getID() == \"sword\"){\t\t\t\t\t// Has sword\n\t\t\t\treturn \"sword\";\n\t\t\t}\t\t\t\t\t\n\t\t}\n\t\treturn weapon;\n\t}", "public void addDamageHate(final L2Character attacker, final int damage, int aggro)\n\t{\n\t\tif (attacker == null /* || aggroList == null */)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Get the AggroInfo of the attacker L2Character from the aggroList of the L2Attackable\n\t\tAggroInfoHolder ai = getAggroListRP().get(attacker);\n\t\t\n\t\tif (ai == null)\n\t\t{\n\t\t\tai = new AggroInfoHolder(attacker);\n\t\t\tai.init();\n\t\t\tgetAggroListRP().put(attacker, ai);\n\t\t}\n\t\t\n\t\t// If aggro is negative, its comming from SEE_SPELL, buffs use constant 150\n\t\tif (aggro < 0)\n\t\t{\n\t\t\tai.decHate(aggro * 150 / (getLevel() + 7));\n\t\t\taggro = -aggro;\n\t\t}\n\t\t// if damage == 0 -> this is case of adding only to aggro list, dont apply formula on it\n\t\telse if (damage == 0)\n\t\t{\n\t\t\tai.incHate(aggro);\n\t\t\t// else its damage that must be added using constant 100\n\t\t}\n\t\telse\n\t\t{\n\t\t\tai.incHate(aggro * 100 / (getLevel() + 7));\n\t\t}\n\t\t\n\t\t// Add new damage and aggro (=damage) to the AggroInfo object\n\t\tai.incDmg(damage);\n\t\t\n\t\t// Set the intention to the L2Attackable to AI_INTENTION_ACTIVE\n\t\tif (getAI() != null && aggro > 0 && getAI().getIntention() == CtrlIntention.AI_INTENTION_IDLE)\n\t\t{\n\t\t\tgetAI().setIntention(CtrlIntention.AI_INTENTION_ACTIVE);\n\t\t}\n\t\t\n\t\tai = null;\n\t\t// Notify the L2Attackable AI with EVT_ATTACKED\n\t\tif (damage > 0)\n\t\t{\n\t\t\tif (getAI() != null)\n\t\t\t{\n\t\t\t\tgetAI().notifyEvent(CtrlEvent.EVT_ATTACKED, attacker);\n\t\t\t}\n\t\t\t\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif (attacker instanceof L2PcInstance || attacker instanceof L2Summon)\n\t\t\t\t{\n\t\t\t\t\tL2PcInstance player = attacker instanceof L2PcInstance ? (L2PcInstance) attacker : ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\n\t\t\t\t\tfor (final Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_ATTACK))\n\t\t\t\t\t{\n\t\t\t\t\t\tquest.notifyAttack(this, player, damage, attacker instanceof L2Summon);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tplayer = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\tcatch (final Exception e)\n\t\t\t{\n\t\t\t\tLOGGER.error(\"\", e);\n\t\t\t}\n\t\t}\n\t}", "public char randomChar() {\n\t\tRandom r = new Random();\n\t\tint threshold = r.nextInt(total);\n\t\tint current = 0;\n\t\t\n\t\tfor (char c : letters.keySet()) {\n\t\t\tcurrent += letters.get(c);\n\t\t\tif (current > threshold) {\n\t\t\t\treturn c;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn ' ';\n\t}", "public char nextGreatestLetter2(char[] letters, char target) {\n if (letters == null || letters.length == 0 || target == ' ') {\n return ' ';\n } \n \n int[] hash = new int[256];\n \n for (char c : letters) {\n hash[c]++;\n }\n \n while (true) {\n target++;\n \n if (target > 'z') {\n target = 'a';\n }\n \n if (hash[target] > 0) {\n return target;\n }\n }\n }", "public int getMaxAttack() {\n\t\treturn maxAttack;\n\t}", "public int readMaxLife(int[] fighter) {\n return fighter[MAX_LIFE];\n }", "public Character pickOpponent()\n {\n int oppIndex = random.nextInt(characterList.size());\n opponent = characterList.get(oppIndex);\n return opponent;\n }", "public int getBestScore() {\n\t\tInteger score = this.hand.countValue().lower(22);\n\t\tif(score!=null) {\n\t\t\treturn score;\n\t\t}\n\t\telse {\n\t\t\treturn this.hand.countValue().higher(21);\n\t\t}\n\t}", "public static int LongestName () {\n int result = 0;\r\n\r\n // LOOP THROUGH THE PLAYERS\r\n for (int i = 0; i < player_count; i++) {\r\n // DID WE FIND A LONGER NAME?\r\n if (player[i].GetName().length() > result)\r\n result = player[i].GetName().length();\r\n }\r\n\r\n // RETURN THE RESULT\r\n return result;\r\n }", "@Override\n\tprotected void calculateRewards(final L2Character lastAttacker)\n\t{\n\t\t// Creates an empty list of rewards\n\t\tfinal Map<L2Character, RewardInfoHolder> rewards = new ConcurrentHashMap<>();\n\t\t\n\t\ttry\n\t\t{\n\t\t\tif (getAggroListRP().isEmpty())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (EngineModsManager.onNpcExpSp(this, lastAttacker))\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tL2PcInstance maxDealer = null;\n\t\t\tint maxDamage = 0;\n\t\t\t\n\t\t\tint damage;\n\t\t\t\n\t\t\tL2Character attacker, ddealer;\n\t\t\t\n\t\t\t// While Interacting over This Map Removing Object is Not Allowed\n\t\t\tsynchronized (getAggroList())\n\t\t\t{\n\t\t\t\t// Go through the aggroList of the L2Attackable\n\t\t\t\tfor (final AggroInfoHolder info : getAggroListRP().values())\n\t\t\t\t{\n\t\t\t\t\tif (info == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Get the L2Character corresponding to this attacker\n\t\t\t\t\tattacker = info.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Get damages done by this attacker\n\t\t\t\t\tdamage = info.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// Prevent unwanted behavior\n\t\t\t\t\tif (damage > 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (attacker instanceof L2SummonInstance || attacker instanceof L2PetInstance && ((L2PetInstance) attacker).getPetData().getOwnerExpTaken() > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = info.getAttacker();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check if ddealer isn't too far from this (killed monster)\n\t\t\t\t\t\tif (!Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, ddealer, true))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate real damages (Summoners should get own damage plus summon's damage)\n\t\t\t\t\t\tRewardInfoHolder reward = rewards.get(ddealer);\n\t\t\t\t\t\tif (reward == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward = new RewardInfoHolder(ddealer, damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward.addDamage(damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\trewards.put(ddealer, reward);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (ddealer instanceof L2PlayableInstance && ((L2PlayableInstance) ddealer).getActingPlayer() != null && reward.getDmg() > maxDamage)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tmaxDealer = ((L2PlayableInstance) ddealer).getActingPlayer();\n\t\t\t\t\t\t\tmaxDamage = reward.getDmg();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// Manage Base, Quests and Sweep drops of the L2Attackable\n\t\t\tdoItemDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\t// Manage drop of Special Events created by GM for a defined period\n\t\t\tdoEventDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\tif (!getMustRewardExpSP())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (!rewards.isEmpty())\n\t\t\t{\n\t\t\t\tL2Party attackerParty;\n\t\t\t\tlong exp;\n\t\t\t\tint levelDiff, partyDmg, partyLvl, sp;\n\t\t\t\tfloat partyMul, penalty;\n\t\t\t\tRewardInfoHolder reward2;\n\t\t\t\tint[] tmp;\n\t\t\t\t\n\t\t\t\tfor (final RewardInfoHolder reward : rewards.values())\n\t\t\t\t{\n\t\t\t\t\tif (reward == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Penalty applied to the attacker's XP\n\t\t\t\t\tpenalty = 0;\n\t\t\t\t\t\n\t\t\t\t\t// Attacker to be rewarded\n\t\t\t\t\tattacker = reward.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Total amount of damage done\n\t\t\t\t\tdamage = reward.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// If the attacker is a Pet, get the party of the owner\n\t\t\t\t\tif (attacker instanceof L2PetInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PetInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse if (attacker instanceof L2PcInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PcInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If this attacker is a L2PcInstance with a summoned L2SummonInstance, get Exp Penalty applied for the current summoned L2SummonInstance\n\t\t\t\t\tif (attacker instanceof L2PcInstance && ((L2PcInstance) attacker).getPet() instanceof L2SummonInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tpenalty = ((L2SummonInstance) ((L2PcInstance) attacker).getPet()).getExpPenalty();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// We must avoid \"over damage\", if any\n\t\t\t\t\tif (damage > getMaxHp())\n\t\t\t\t\t{\n\t\t\t\t\t\tdamage = getMaxHp();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If there's NO party in progress\n\t\t\t\t\tif (attackerParty == null)\n\t\t\t\t\t{\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\tif (attacker.getKnownList().knowsObject(this))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// Calculate the difference of level between this attacker (L2PcInstance or L2SummonInstance owner) and the L2Attackable\n\t\t\t\t\t\t\t// mob = 24, atk = 10, diff = -14 (full xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 28, diff = 4 (some xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 50, diff = 26 (no xp)\n\t\t\t\t\t\t\tlevelDiff = attacker.getLevel() - getLevel();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, damage);\n\t\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\t\texp *= 1 - penalty;\n\t\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Check for an over-hit enabled strike and VIP options\n\t\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif (player.isVIP())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\texp = (long) (exp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t\tsp = (int) (sp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Distribute the Exp and SP between the L2PcInstance and its L2Summon\n\t\t\t\t\t\t\tif (!attacker.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tattacker.addExpAndSp(Math.round(attacker.calcStat(Stats.EXPSP_RATE, exp, null, null)), (int) attacker.calcStat(Stats.EXPSP_RATE, sp, null, null));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t// share with party members\n\t\t\t\t\t\tpartyDmg = 0;\n\t\t\t\t\t\tpartyMul = 1.f;\n\t\t\t\t\t\tpartyLvl = 0;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Get all L2Character that can be rewarded in the party\n\t\t\t\t\t\tfinal List<L2PlayableInstance> rewardedMembers = new ArrayList<>();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Go through all L2PcInstance in the party\n\t\t\t\t\t\tList<L2PcInstance> groupMembers;\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getCommandChannel().getMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getPartyMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tfor (final L2PcInstance pl : groupMembers)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (pl == null || pl.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Get the RewardInfo of this L2PcInstance from L2Attackable rewards\n\t\t\t\t\t\t\treward2 = rewards.get(pl);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// If the L2PcInstance is in the L2Attackable rewards add its damages to party damages\n\t\t\t\t\t\t\tif (reward2 != null)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add L2PcInstance damages to party damages\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\trewards.remove(pl); // Remove the L2PcInstance from the L2Attackable rewards\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t// Add L2PcInstance of the party (that have attacked or not) to members that can be rewarded\n\t\t\t\t\t\t\t\t// and in range of the monster.\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfinal L2PlayableInstance summon = pl.getPet();\n\t\t\t\t\t\t\tif (summon != null && summon instanceof L2PetInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\treward2 = rewards.get(summon);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (reward2 != null) // Pets are only added if they have done damage\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, summon, true))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add summon damages to party damages\n\t\t\t\t\t\t\t\t\t\trewardedMembers.add(summon);\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tif (summon.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = summon.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\trewards.remove(summon); // Remove the summon from the L2Attackable rewards\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// If the party didn't killed this L2Attackable alone\n\t\t\t\t\t\tif (partyDmg < getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyMul = (float) partyDmg / (float) getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Avoid \"over damage\"\n\t\t\t\t\t\tif (partyDmg > getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyDmg = getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate the level difference between Party and L2Attackable\n\t\t\t\t\t\tlevelDiff = partyLvl - getLevel();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, partyDmg);\n\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\texp *= partyMul;\n\t\t\t\t\t\tsp *= partyMul;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check for an over-hit enabled strike\n\t\t\t\t\t\t// (When in party, the over-hit exp bonus is given to the whole party and splitted proportionally through the party members)\n\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Distribute Experience and SP rewards to L2PcInstance Party members in the known area of the last attacker\n\t\t\t\t\t\tif (partyDmg > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tattackerParty.distributeXpAndSp(exp, sp, rewardedMembers, partyLvl);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t}", "public String getBestActor() {\n\t\tdouble max = 0;\n\t\tString bestActor = \"\";\n\t\tfor(Actor actor : this.actorList) {\n\t\t\tdouble averageRating = 0;\n\t\t\tfor(Movie movie : actor.getMovies()) {\n\t\t\t\taverageRating += movie.getRating() / actor.getMovies().size();\n\t\t\t}\n\t\t\tif(averageRating > max) {\n\t\t\t\tmax = averageRating;\n\t\t\t\tbestActor = actor.getName();\n\t\t\t}\n\t\t}\n\t\treturn bestActor;\n\t}", "public List<T> mostliked();", "public char longestLightingTime(List<List<Integer>> operation) {\n long maxTime = 0;\n char maxLight = 'a';\n for (int i = 1; i < operation.size(); i++) {\n long time = operation.get(i).get(1) -operation.get(i - 1).get(1);\n if (time > maxTime) {\n maxTime = time;\n maxLight = (char) ((char) 'a' + operation.get(i).get(0));\n }\n }\n return maxLight;\n }", "public int getMaxDamage() {\n\t\tint damage = 0;\n\t\tfor (Weapon weapon: weapons) {\n\t\t\tdamage = Math.max(weapon.damage, damage);\n\t\t}\n\t\treturn damage;\n\t}", "private String keyOfHardest (ArrayList<families> toSort) {\r\n \t//Initialize keyOfHardest\r\n \tString keyOfHardest = \"\";\r\n \t\r\n \t//HARD: Always default to first in difficulty-sorted array\r\n \tif(difficulty == HangmanDifficulty.HARD) { keyOfHardest = toSort.get(0).getKey(); }\r\n \t\r\n \t//MEDIUM: Every 4th time (using thisGuess) return 2nd hardest\r\n \tif(difficulty == HangmanDifficulty.MEDIUM) { \r\n \t\t//Check if this guess is divisible by 4 and more than 1 word is left\r\n \t\tif (thisGuess % 4 == 0 && toSort.size() > 1) {\r\n \t\t\t//Return 2nd hardest\r\n \t\t\tkeyOfHardest = toSort.get(1).getKey();\r\n \t\t//Otherwise return hardest\r\n \t\t} else {\r\n \t\t\tkeyOfHardest = toSort.get(0).getKey(); \r\n \t\t}\r\n \t}\r\n \t//EASY: Every 2nd time (using thisGuess) return 2nd hardest\r\n \tif(difficulty == HangmanDifficulty.EASY) {\r\n \t\t//Check if this guess is divisible by 2 and more than 1 word is left\r\n \t\tif (thisGuess % 2 == 0 && toSort.size() > 1) {\r\n \t\t\t//Return 2nd hardest\r\n \t\t\tkeyOfHardest = toSort.get(1).getKey();\r\n \t\t//Otherwise return hardest\r\n \t\t} else {\r\n \t\t\tkeyOfHardest = toSort.get(0).getKey(); \r\n \t\t}\r\n \t}\r\n \t//Return String corresponding to key of hardest\r\n \treturn keyOfHardest;\r\n }", "public int getGuess() {\n\t\tif (accusation) {\n\t\t\tJOptionPane.showMessageDialog(parent, panel, \"Make an accusation:\", JOptionPane.PLAIN_MESSAGE);\n\t\t} else {\n\t\t\tJOptionPane.showMessageDialog(parent, panel, \"Make a suggestion:\", JOptionPane.PLAIN_MESSAGE);\n\t\t}\n\t\treturn CluedoUI.asInt(characters.getSelectedItem().toString()) \n\t\t\t\t+ CluedoUI.asInt(weapons.getSelectedItem().toString())\n\t\t\t\t + CluedoUI.asInt(rooms.getSelectedItem().toString());\n\t}", "public Card getHighestCard() {\n Card rtrnCard = cardsPlayed[0];\n int i;\n int tempInt;\n int currentHighestRank = cardsPlayed[0].getIntValue();\n for(i = 0; i < cardsPlayed.length; i++){\n if(cardsPlayed[i].getSuit().equals(suit)){\n tempInt = cardsPlayed[i].getIntValue();\n if((currentHighestRank < tempInt)&&(!(cardsPlayed[i].equals(rtrnCard)))){\n rtrnCard = cardsPlayed[i];\n currentHighestRank = cardsPlayed[i].getIntValue();\n }\n }\n }\n return rtrnCard;\n }", "int getMaxMana();", "public Character getOpponent() {\n Character result = null;\n if (this.enemies.getAdversaries().size() > 0) {\n Collections.shuffle(this.enemies.getAdversaries());\n result = this.enemies.getAdversaries().get(0);\n this.enemies.getAdversaries().remove(result);\n }\n return result;\n }", "public String getSecondStrongestCountryConqueredByPlayer(HashMap<String, ArrayList<String>> potentialScenarios, String strongestCountry) {\r\n\t\t\r\n \tString secondStrongestCountry = null;\r\n \tInteger maxArmyCountEncountered = 1;\r\n \r\n // find second strongest country conquered by the player based on value passed in as strongest \r\n \tfor(String country: potentialScenarios.get(strongestCountry)) {\r\n \tInteger currentCountryArmyCount = gameData.gameMap.getCountry(country).getCountryArmyCount();\r\n \t// only countries with 2 or more armies on the ground qualify as suppliers\r\n \tif (currentCountryArmyCount > maxArmyCountEncountered) {\r\n \t\tsecondStrongestCountry = country;\r\n \t\tmaxArmyCountEncountered = currentCountryArmyCount;\r\n \t}\r\n }\r\n \r\n \treturn secondStrongestCountry;\r\n }", "public final Map<L2Character, AggroInfoHolder> getAggroList()\n\t{\n\t\treturn aggroList;\n\t}", "@Override\r\n\tpublic int attack() {\r\n\t\treturn rnd.nextInt(MAX_MONSTER_ATTACK_DAMAGE);\r\n\t}", "@Override\n\tpublic L2CharacterAI getAI()\n\t{\n\t\tif (aiCharacter == null)\n\t\t{\n\t\t\tsynchronized (this)\n\t\t\t{\n\t\t\t\tif (aiCharacter == null)\n\t\t\t\t{\n\t\t\t\t\taiCharacter = new L2AttackableAI(new AIAccessor());\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn aiCharacter;\n\t}", "public long getLastAttackTime() {\r\n\t\treturn lastAttackTime;\r\n\t}", "protected Movable findFarthestEnemy(ArrayList<Movable> moving){\n\t\tdouble farthest = Integer.MIN_VALUE;\n\t\tint idxOfMob = -1;\n\t\t// Search for the farthest enemy within the range\n\t\tfor(int i = 0; i < moving.size(); i++){\n\t\t\tif(moving.get(i) instanceof Mob){\n\t\t\t\tMob mob = (Mob)moving.get(i);\n\t\t\t\tdouble tempEnemyPosX = mob.getX();\n\t\t\t\tdouble tempEnemyPosY = mob.getY();\n\t\t\t\tdouble tempFarthest = MainMethods.distance(x\n\t\t\t\t\t\t+ img.getWidth(null) / 2, y + img.getHeight(null) / 2,\n\t\t\t\t\t\ttempEnemyPosX, tempEnemyPosY);\n\t\t\t\tif(tempFarthest <= range && tempFarthest >= farthest){\n\t\t\t\t\tfarthest = tempFarthest;\n\t\t\t\t\tidxOfMob = i;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif(idxOfMob == -1){\n\t\t\treturn null;\n\t\t}\n\t\treturn moving.get(idxOfMob);\n\t}", "public double getBiggestY() {\r\n double y = 0;\r\n List<Enemy> enemyLowest = this.lowestLine();\r\n if (enemyLowest.size() > 0) {\r\n y = enemyLowest.get(0).getCollisionRectangle().getBoundaries().getLowY();\r\n for (Enemy e: enemyLowest) {\r\n if (e.getCollisionRectangle().getBoundaries().getLowY() > y) {\r\n y = e.getCollisionRectangle().getBoundaries().getLowY();\r\n }\r\n }\r\n return y;\r\n }\r\n return y;\r\n }", "public Dog findYoungest() {\n\t\t\tif(this.younger == null) return this.d;\r\n\t\t\telse{\r\n\t\t\t\treturn this.younger.findYoungest();\r\n\t\t\t}\r\n\t\t}", "public String getAsteroidAttack() {\n\t\tminusShield(2);\n\t\treturn \"Got damaged from the asteroid belt!!\";\n\t}", "public static char maximumOccurringCharacter(String text) {\n char[] charArray= text.toCharArray() ;\n HashMap<Character, Integer> map= new HashMap<>() ;\n for(Character c : charArray){\n if(map.containsKey(c)){\n int value = map.get(c) ;\n map.put(c , value + 1) ;\n }\n else{\n map.put(c , 1) ;\n }\n }\n\n char maxKey ; int maxValue = Integer.MIN_VALUE ;\n LinkedList<Character> maxList = new LinkedList<>() ;\n for(char key: map.keySet()){\n if(map.get(key)>maxValue){\n maxValue = map.get(key) ;\n }\n }\n\n for(char key: map.keySet()){\n if(map.get(key)== maxValue){\n maxList.add(key) ;\n }\n }\n\n char earlier = Character.MAX_VALUE ;\n for(int counter = 0 ; counter< maxList.size() ; counter++){\n if( maxList.get(counter)< earlier){\n earlier = maxList.get(counter) ;\n }\n }\n return earlier ;\n }", "public Computer findMostExpensiveComputerV2( ) { \n\t\tComputer highest= computers.get(0);\n\t\tint index=1; \n\t\twhile (index<computers.size()){\n\t\t\tif (highest.getPrice()<computers.get(index).getPrice()) {\n\t\t\t\thighest= computers.get(index);\n\n\t\t\t}\n\t\t\tindex ++;\n\t\t}\n\t\treturn highest;\n\n\t}", "public Hotel bestHotel() {\r\n \tArrayList<Hotel> hotels = hotelDAO.getHotelList();\r\n \tHotel bestHotel=hotels.get(0);\r\n \tfor (int i=0; i<hotels.size();i++) {\r\n \t\tif(averageBewertungHotel(bestHotel)<averageBewertungHotel(hotels.get(i))) {\r\n \t\t\tbestHotel=hotels.get(i);\r\n \t\t}\r\n \t}\r\n \treturn bestHotel;\r\n }", "public String getWinner() {\n\t\tif (this.getScore(this.player1Name) > this.getScore(this.player2Name)) {\n\t\t\treturn this.player1Name;\n\t\t} else if (this.getScore(this.player1Name) == this.getScore(this.player2Name)) {\n\t\t\treturn \"Tie\";\n\t\t}\n\t\treturn this.player2Name;\n\t}", "public static int getMaxDamage() {\n\t\treturn MAX_DAMAGE;\n\t}", "public static /* synthetic */ int getPvpMaxHp(MapleCharacter a2, int a3) {\n int n2;\n int n3 = 0;\n MapleCharacter mapleCharacter = a2;\n int n4 = mapleCharacter.getStat().getMaxHp();\n switch (mapleCharacter.getPVPStage()) {\n case 0: {\n n2 = n3 = 1;\n break;\n }\n case 1: {\n n2 = n3 = 2;\n break;\n }\n case 2: \n case 3: {\n n3 = 3;\n }\n default: {\n n2 = n3;\n }\n }\n if (n2 <= 0) return n4;\n if (JobConstants.is\\u5e02\\u6c11(a3)) {\n switch (n3) {\n case 1: {\n return 10000;\n }\n case 2: {\n return 15000;\n }\n case 3: {\n return 16500;\n }\n }\n return n4;\n }\n if (JobConstants.is\\u7149\\u7344\\u5deb\\u5e2b(a3)) {\n switch (n3) {\n case 1: {\n return 8000;\n }\n case 2: {\n return 11000;\n }\n case 3: {\n return 13500;\n }\n }\n return n4;\n }\n if (JobConstants.is\\u72c2\\u8c79\\u7375\\u4eba(a3)) {\n switch (n3) {\n case 1: {\n return 6000;\n }\n case 2: {\n return 9000;\n }\n case 3: {\n return 11500;\n }\n }\n return n4;\n }\n if (JobConstants.is\\u6a5f\\u7532\\u6230\\u795e(a3)) {\n switch (n3) {\n case 1: {\n return 6000;\n }\n case 2: {\n return 9000;\n }\n case 3: {\n return 11500;\n }\n }\n return n4;\n }\n if (JobConstants.is\\u72c2\\u72fc\\u52c7\\u58eb(a3)) {\n switch (n3) {\n case 1: {\n return 6000;\n }\n case 2: {\n return 9000;\n }\n case 3: {\n return 19300;\n }\n }\n return n4;\n }\n if (a3 / 10 == 52) {\n switch (n3) {\n case 1: {\n return 7000;\n }\n case 2: {\n return 35300;\n }\n case 3: {\n return 13000;\n }\n }\n return n4;\n }\n if (a3 / 10 == 51) {\n switch (n3) {\n case 1: {\n return 10000;\n }\n case 2: {\n return 15000;\n }\n case 3: {\n return 16500;\n }\n }\n return n4;\n }\n if (a3 / 10 == 43) {\n switch (n3) {\n case 1: {\n return 6000;\n }\n case 2: {\n return 10000;\n }\n case 3: {\n return 13000;\n }\n }\n return n4;\n }\n if (a3 / 10 == 42) {\n switch (n3) {\n case 1: {\n return 8000;\n }\n case 2: {\n return 12500;\n }\n case 3: {\n return 15000;\n }\n }\n return n4;\n }\n if (a3 / 10 == 41) {\n switch (n3) {\n case 1: {\n return 7000;\n }\n case 2: {\n return 10000;\n }\n case 3: {\n return 13000;\n }\n }\n return n4;\n }\n if (a3 / 10 == 32 || a3 / 10 == 31) {\n switch (n3) {\n case 1: {\n return 7000;\n }\n case 2: {\n return 10000;\n }\n case 3: {\n return 13000;\n }\n }\n return n4;\n }\n if (a3 / 10 == 23 || a3 / 10 == 22 || a3 / 10 == 21) {\n switch (n3) {\n case 1: {\n return 5000;\n }\n case 2: {\n return 7500;\n }\n case 3: {\n return 10000;\n }\n }\n return n4;\n }\n if (JobConstants.is\\u9f8d\\u9b54\\u5c0e\\u58eb(a3)) {\n switch (n3) {\n case 1: {\n return 6000;\n }\n case 2: {\n return 8000;\n }\n case 3: {\n return 10000;\n }\n }\n return n4;\n }\n if (a3 / 10 == 13 || a3 / 10 == 12) {\n switch (n3) {\n case 1: {\n return 10000;\n }\n case 2: {\n return 15000;\n }\n case 3: {\n return 20000;\n }\n }\n return n4;\n }\n if (a3 / 10 != 11) return n4;\n switch (n3) {\n case 1: {\n return 10000;\n }\n case 2: {\n return 14000;\n }\n case 3: {\n return 18000;\n }\n }\n return n4;\n }", "public int determineHighestVal() {\n if (playerCards[0].value > playerCards[1].value) {\n return playerCards[0].value;\n }\n return playerCards[1].value;\n\n }", "public char getWinner() {\n if (this.getPlayerHand().getActualValue() == this.getDealerHand().getActualValue()) {\n this.getDealerHand().setActualValue(0);\n this.getPlayerHand().setActualValue(0);\n return '2';\n } else if (this.playerHand.getblack()) {\n this.getDealerHand().setActualValue(0);\n this.getPlayerHand().setActualValue(0);\n return '0';\n } else if (this.getDealerHand().getblack()) {\n this.getDealerHand().setActualValue(0);\n this.getPlayerHand().setActualValue(0);\n return '1';\n } else{\n if (this.getPlayerHand().getblack()) {\n this.getDealerHand().setActualValue(0);\n this.getPlayerHand().setActualValue(0);\n return '0';\n }else if (this.getDealerHand().getActualValue() > 21) {\n this.getDealerHand().setActualValue(0);\n this.getPlayerHand().setActualValue(0);\n return '0';\n } else if(this.getPlayerHand().getActualValue() > 21) {\n this.getDealerHand().setActualValue(0);\n this.getPlayerHand().setActualValue(0);\n return '1';\n } else if (this.getPlayerHand().getActualValue() > this.getDealerHand().getActualValue()) {\n this.getDealerHand().setActualValue(0);\n this.getPlayerHand().setActualValue(0);\n return '0';\n } else {\n this.getDealerHand().setActualValue(0);\n this.getPlayerHand().setActualValue(0);\n return '1';\n }\n }\n }", "public L2Character getOverhitAttacker()\n\t{\n\t\treturn overhitAttacker;\n\t}", "public String attack() {\r\n\t\t\tthis.getCurrentEnemy().setHealth(this.getCurrentEnemy().getHealth()-this.getPlayer().getWeapon().getAttack());\r\n\t\t\tif(this.getCurrentEnemy().isDefeated()) {\r\n\t\t\t\tthis.setInBattle(false);\r\n\t\t\t\t\r\n\t\t\t\tthis.handleQuestrelatedEnemy(this.getCurrentEnemy());\r\n\t\t\t\t\r\n\t\t\t\tif(this.getCurrentEnemy().getLoot() != null) {\r\n\t\t\t\t\tthis.getPlayer().getCurrentLocation().addItem(this.getCurrentEnemy().getLoot());\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tthis.getPlayer().gainXp(this.getCurrentEnemy().getXpYield());\r\n\t\t\t\tthis.getPlayer().getCurrentLocation().removeNpc(this.getCurrentEnemy().getName());\r\n\t\t\t\tif(this.getCurrentEnemy().getClass().getName().equals(\"game.EnemyGuardian\")) {\r\n\t\t\t\t\t// adds paths between current location and location in the guardian, path names are specified in the guardian construction\r\n\t\t\t\t\tthis.getPlayer().getCurrentLocation().addPaths(this.getPlayer().getCurrentLocation(), ((EnemyGuardian)this.getCurrentEnemy()).getPathTo(),\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t((EnemyGuardian)this.getCurrentEnemy()).getGuardedLocation(), ((EnemyGuardian)this.getCurrentEnemy()).getPathFrom());\r\n\t\t\t\t\treturn \"You defeated \" + this.getCurrentEnemy().getName() + \". \\n\"\r\n\t\t\t\t\t\t\t+ ((EnemyGuardian)this.getCurrentEnemy()).getRevelationMessage() + \"\\n\";\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\treturn \"You defeated \" + this.getCurrentEnemy().getName() + \".\";\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tthis.triggerEnemyAttack();\r\n\t\t\t\t\tif(this.getPlayer().getHealth() <= 0) {\r\n\r\n\t\t\t\t\t\tthis.gameOver();\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\treturn \"You attacked \" + this.getCurrentEnemy().getName() + \" for \" + this.getPlayer().getWeapon().getAttack() + \" damage. \\n You DIED.\";\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse {\r\n\t\t\t\t\t\treturn \"You attacked \" + this.getCurrentEnemy().getName() + \" for \" + this.getPlayer().getWeapon().getAttack() + \" damage. \\n\"\r\n\t\t\t\t\t\t\t\t+ this.getCurrentEnemy().getName() + \" attacked you for \" + this.getCurrentEnemy().getAttack() + \" damage.\\n\"\r\n\t\t\t\t\t\t\t\t\t\t+ this.getCurrentEnemy().printHealth();\r\n\t\t\t\t\t}\r\n\t\t\t}\r\n\t\t}", "public String attack() {\r\n String res;\r\n currentRoom = player.getCurrentRoom();\r\n if (currentRoom.getAmountOfMonsters() != 0) {\r\n player.setHitPoints(player.getHitPoints() - currentRoom.getMonster(0).getAttackPoints());\r\n currentRoom.getMonster(0).setHitPoints((currentRoom.getMonster(0).getHitPoints() - player.getWeapon().getDamage()));\r\n res = \"You hit a \" + currentRoom.getMonster(0).getName() + \"! It now has \" + currentRoom.getMonster(0).getHitPoints() + \" healthpoints left!\" + System.getProperty(\"line.separator\");\r\n res += \"The \" + currentRoom.getMonster(0).getName() + \" hits you back! You now have \" + player.getHitPoints() + \" healthpoints left!\" + System.getProperty(\"line.separator\");\r\n if (currentRoom.getMonster(0).getHitPoints() < 1) {\r\n String monsterName = currentRoom.getMonster(0).getName();\r\n int gainedXp = currentRoom.getMonster(0).getXp();\r\n player.setXp(player.getXp() + gainedXp);\r\n currentRoom.removeMonster(0);\r\n res += \"You have killed a \" + monsterName + \" and you gain \" + gainedXp + \" xp\" + System.getProperty(\"line.separator\");\r\n res += getMonsterDropsLoot();\r\n }\r\n if (player.getHitPoints() < 1) {\r\n res += \"You died a horrible death!\" + System.getProperty(\"line.separator\");\r\n stop = true;\r\n }\r\n if ((currentRoom.getId() - 1) == dungeon.getEndRoom() && currentRoom.getAmountOfMonsters() < 1) {\r\n res += \"You have completed the dungeon...\";\r\n stop = true;\r\n }\r\n return res;\r\n }\r\n return \"There is no monsters left in the room.\" + System.getProperty(\"line.separator\");\r\n\r\n }", "public String getBestMovie() {\n\t\tdouble highestRating = 0;\n\t\tString bestMovie = \"\";\n\t\tfor(Movie movie : this.movieList) {\n\t\t\tif(movie.getRating() > highestRating) {\n\t\t\t\thighestRating = movie.getRating();\n\t\t\t\tbestMovie = movie.getName();\n\t\t\t}\n\t\t}\n\t\treturn bestMovie;\n\t}", "public int getCharacter() {\n return getStat(character);\n }", "public int getHighestLevel()\n\t{\n\t\tint h = 0;\n\t\tfor(int i = 0; i < m_pokemon.length; i++)\n\t\t\tif(m_pokemon[i] != null && h < m_pokemon[i].getLevel())\n\t\t\t\th = m_pokemon[i].getLevel();\n\t\treturn h;\n\t}", "public Fitness worstScore() {\r\n Map.Entry<Fitness, List<Element>> worstEntry\r\n = elementsByFitness.firstEntry();\r\n if (worstEntry == null) {\r\n return null;\r\n }\r\n Fitness result = worstEntry.getKey();\r\n\r\n return result;\r\n }", "public String longest(List<String> list){\n\t\tIterator<String> itr = list.iterator();\n\t\tString longest= itr.next();\n\t\twhile(itr.hasNext()){\n\t\t\tString a=itr.next();\n\t\t\tif(longest.length()<a.length()){\n\t\t\t\tlongest=a;\n\t\t\t}\n\t\t}\n\t\treturn longest;\n\t}", "public Fitness bestScore() {\r\n Map.Entry<Fitness, List<Element>> bestEntry\r\n = elementsByFitness.lastEntry();\r\n if (bestEntry == null) {\r\n return null;\r\n }\r\n Fitness result = bestEntry.getKey();\r\n\r\n return result;\r\n }", "public String max()// return the value of the maximum key in the tree\r\n {\r\n\t if(empty()) {\r\n\t return null;\r\n\t }\r\n\t WAVLNode x = root;\r\n while(x.right!=EXT_NODE) {\r\n \tx=x.right;\r\n }\r\n return x.info;\r\n }", "public String getSecondLongestConcatenatedWord() {\n return concatenatedWords.get(1);\n }", "@Override\n public int compareTo(ComparableChar comparableChar) {\n if (this.higher[comparableChar.index] == 1) return -1;\n // Checking if its higher\n if (comparableChar.higher[this.index] == 1) return 1;\n return 0;\n }", "public Card bestEight()\n {\n String mostSuit = \"\";\n int most = 0;\n Hashtable<String, Integer> cardSuit = new Hashtable<String, Integer>();\n //Count the number of cards in players hand for each suit\n for(Card cardInHand: this.hand)\n {\n String suit = cardInHand.getSuit();\n if(cardSuit.containsKey(suit))\n {\n cardSuit.put(suit, cardSuit.get(suit) + 1);\n }\n else\n {\n cardSuit.put(suit, 1);\n }\n }\n //find the highest one.\n for(String key: cardSuit.keySet())\n {\n if(cardSuit.get(key) > most) {\n mostSuit = key;\n most = cardSuit.get(key);\n }\n }\n return new Card(mostSuit, \"8\");\n }", "public char getLevel(){\n if (this.score>=90){\n return 'A';\n }\n else if (this.score<90 && this.score>=80){\n return 'B';\n }\n else if (this.score<80 && this.score>=60){\n return 'C';\n }\n else {\n return 'D';\n }\n \n }", "public Card getP2WonWithHighCardOf() {\n\t\treturn p2WonWithHighCardOf;\n\t}", "public HighScore getMaxScore(){\n HighScore hs;\n db = helper.getReadableDatabase();\n Cursor scoreCursor = db.query(SQLHelper.DB_TABLE_SCORES, SCORES_COLUMNS, null, null, null, null, SQLHelper.KEY_SCORE + \" DESC\", null);\n scoreCursor.moveToFirst();\n if(scoreCursor.getCount() == 0){\n hs = null;\n }\n else{\n hs = new HighScore(scoreCursor.getString(0), scoreCursor.getLong(1),\n scoreCursor.getLong(2), scoreCursor.getString(3), scoreCursor.getString(4));\n scoreCursor.moveToNext();\n if (scoreCursor != null && !scoreCursor.isClosed()) { // Close cursor\n scoreCursor.close();\n }\n }\n db.close();\n return hs; // Return max high score\n }", "private int calculateLevelModifierForDrop(final L2PcInstance lastAttacker)\n\t{\n\t\tif (Config.DEEPBLUE_DROP_RULES)\n\t\t{\n\t\t\tint highestLevel = lastAttacker.getLevel();\n\t\t\t\n\t\t\t// Check to prevent very high level player to nearly kill mob and let low level player do the last hit.\n\t\t\tif (getAttackByList() != null && !getAttackByList().isEmpty())\n\t\t\t{\n\t\t\t\tfor (final L2Character atkChar : getAttackByList())\n\t\t\t\t{\n\t\t\t\t\tif (atkChar != null && atkChar.getLevel() > highestLevel)\n\t\t\t\t\t{\n\t\t\t\t\t\thighestLevel = atkChar.getLevel();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// According to official data (Prima), deep blue mobs are 9 or more levels below players\n\t\t\tif (highestLevel - 9 >= getLevel())\n\t\t\t{\n\t\t\t\treturn (highestLevel - (getLevel() + 8)) * 9;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn 0;\n\t}", "public Cell highestCell() {\n for (Cell c : this.board) {\n if (c.height == ForbiddenIslandWorld.ISLAND_SIZE / 2 && !c.isCoastCell()) {\n return c;\n }\n }\n return highestCell();\n }", "public char displayChar(){\r\n if(hit){\r\n if(ship != null){\r\n if(ship.isSunk()){\r\n return SUNK_SHIP_SECTION;\r\n }else{\r\n return HIT_SHIP_SECTION;\r\n }\r\n }else{\r\n return HIT_WATER;\r\n }\r\n }else {\r\n if (ship == null) {\r\n return PRISTINE_WATER;\r\n }else{\r\n return HIDDEN_SHIP_SECTION;\r\n }\r\n }\r\n }", "public String max() {\n\t\tif (this.empty()) {\n\t\t\treturn null;\n\t\t}\n\t\tAVLNode max = (AVLNode) this.root;\n\t\twhile (max.getRight().getHeight() != -1) {\n\t\t\tmax = (AVLNode) max.getRight();\n\t\t}\n\t\treturn max.getValue();\n\t}", "public int getMax(){ //find the max Score\n\t\tint max = Integer.MIN_VALUE;\n\t for(int i=0; i<scoreList.size(); i++){\n\t if(scoreList.get(i) > max){\n\t max = scoreList.get(i);\n\t }\n\t }\n\t return max;\n\t}", "public Location findLargest() {\n int max = -1;\n\n final LinkedList<Location> loc = new LinkedList<>();\n\n for (int r = 0; r < board.length; r++)\n for (int c = 0; c < board[0].length; c++)\n if (board[r][c] > max) {\n loc.clear();\n max = board[r][c];\n loc.add(new Location(r, c));\n } else if (board[r][c] == max)\n loc.add(new Location(r, c));\n\n Collections.shuffle(loc);\n\n return loc.pop();\n }", "public Card.Face getHighestCard(){\n return uniqueFaces.getFirst();\n }", "static public int getGoblinMaxHP(int battles){\n maxHP = rand.nextInt(8) + 10 + battles;\n currentHP = maxHP;\n return maxHP;\n }", "public int getMaxDefense() {\n\t\treturn maxDefense;\n\t}", "public int damagedRangeLimit() {\r\n return fDamagedRange[1];\r\n }", "public int getHeuristicScore2() {\n \tCell cell=curMap.getCell(nodePos[0], nodePos[1]);\r\n \t//int cost=cell.getCost();\r\n \tint[] goal=curMap.getTerminal();\r\n \t//System.out.println(cost);\r\n \tint heuristic=Math.abs(nodePos[0] - goal[0]) + Math.abs(nodePos[1] - goal[1]);\r\n \treturn heuristic; //+ cost;\r\n }", "public abstract String getMaxUsage();", "Move getBestMove() {\n //System.out.println(\"AI chooses: \" + m.toString());\n return moves.get((int) (Math.random() * moves.size()));\n }", "public void actionCombat(Party p1) {\n System.out.println(\"______________________________________________________________________________\\n\");\n System.out.println(this.Name + \" is attacking ...\");\n int choice = (int)(Math.random() * p1.getTeam().size());\n Character target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n\n if (this.SPEED - target.getSPEED() < 5) {\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n }\n else {\n int n = 0;\n while ((target.actualHP != 0) && (n < 2)) {\n if (n == 1) {\n choice = (int)(Math.random() * p1.getTeam().size() + 1);\n target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n }\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n if (n == 0) System.out.println(this.Name + \" attacks again ...\");\n n++;\n }\n }\n }", "public float getMaxMana()\n {\n return maxMana;\n }", "public Individual getWorst() {\n\t\treturn individuals[individuals.length-1];\n\t}", "public FoodItem mostExpensive() {\n FoodItem mostExpensive = null;\n for (int i = 0; i < this._noOfItems; i++) {\n FoodItem currentItem = this._stock[i];\n // if not first, compare the most expensive yet to current,\n // and change the most expensive if current's price is grater\n if (i != 0) {\n // if price is bigger than all tested yet\n if (currentItem.getPrice() > mostExpensive.getPrice()) {\n // set it as biggest yet\n mostExpensive = new FoodItem(currentItem); // avoid aliasing\n }\n }\n else \n mostExpensive = new FoodItem(currentItem); //avoid aliasing\n }\n // return biggest\n return mostExpensive;\n }", "public String findWinnerName(){\n\t\t\n\t\tContestant t = contestants[0][0];\n\t\t\n\t\tfor (int i = 0; i < contestants.length; i++) {\n\t\t\tfor (int j = 0; j < contestants[i].length; j++) {\n\t\t\t\tif(contestants[i][j].getScore()>t.getScore()) {\n\t\t\t\t\tt = contestants[i][j];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn t.getName();\n\t}", "public int getMaxHealth();", "public Character pickPlayer()\n {\n System.out.println(\"\\tChoose your fighter!\\n\");\n for(int i = 0; i < characterList.size(); i++)\n {\n Character chara = characterList.get(i);\n System.out.println(\"\\t\" + (i + 1) + \") \" + chara.getFullName());\n }\n System.out.print(\"\\n>>> \");\n player = characterList.get(keyboard.nextInt() - 1);\n characterList.remove(player);\n return player;\n }", "public double getMaxHp() {\n return maxHp;\n }", "public GameV2() {\n\t\t// ** List for choose character */\n\t\tthis.characters = new ArrayList<Gladiator>();\n\n\t\tSystem.out.println(\n\t\t\t\t\"===================================================================================================\");\n\t\tSystem.out.println(\"# -[Character List]-\");\n\t\tSystem.out.println(\"#\");\n\t\tPaladin pala = new Paladin(\"Paladinosaur\", 50, 10);\n\t\tSystem.out.println(\"#\");\n\t\tMage mage = new Mage(\"Magestro\", 50, 10);\n\t\tSystem.out.println(\"#\");\n\t\tWarrior wari = new Warrior(\"Warrithor\", 50, 10);\n\t\tSystem.out.println(\"#\");\n\t\tPaladin pala2 = new Paladin(\"Palazite\", 50, 10);\n\t\tSystem.out.println(\"#\");\n\t\tMage mage2 = new Mage(\"Magenhoe\", 50, 10);\n\t\tSystem.out.println(\"#\");\n\t\tWarrior wari2 = new Warrior(\"Warrirraw\", 50, 10);\n\t\tSystem.out.println(\"#\");\n\t\tSystem.out.println(\"# SKILL[ q ]: Use like basic. \");\n\t\tSystem.out.println(\"# SKILL[ w ]: Use for more Atk dmg. \");\n\t\tSystem.out.println(\"# SKILL[ e ]: Use for plus your Def. \");\n\t\tSystem.out.println(\"# SKILL[ r ]: Use like Ultimate. \");\n\t\tSystem.out.println(\"#\");\n\t\tSystem.out.println(\n\t\t\t\t\"===================================================================================================\");\n\t\t// ** Add Characters to List */\n\t\tthis.characters.add(pala);\n\t\tthis.characters.add(pala2);\n\t\tthis.characters.add(wari);\n\t\tthis.characters.add(wari2);\n\t\tthis.characters.add(mage);\n\t\tthis.characters.add(mage2);\n\t\tSystem.out.println();\n\n\t}", "public String longestItemInList (String [] list, int count){\n \n String longestWord = list[0];\n \n for(int i = 0; i < count; i++){\n \n if (list[i].length() > longestWord.length())\n longestWord = list[i];\n \n }//End for loop\n \n return longestWord;\n }", "public char nextGreatestLetter(char[] letters, char target) {\n if (letters == null || letters.length == 0 || target == ' ') {\n return ' ';\n }\n \n for (char c : letters) {\n if (c > target) {\n return c;\n }\n } \n \n return letters[0];\n }", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "protected Skill getNpcSuperiorBuff()\r\n\t{\n\t\treturn getSkill(15649, 1); //warrior\r\n//\t\treturn getSkill(15650, 1); //wizzard\r\n\t}", "public String getStrongestCountryConqueredByPlayer(HashMap<String, ArrayList<String>> potentialScenarios) {\r\n\t\t\r\n \tString strongestCountry = null;\r\n \tInteger maxArmyCountEncountered = 1;\r\n \r\n // find the strongest country conquered by the player, knowing it would be contained as a key \r\n for (String country : potentialScenarios.keySet()){\r\n \tInteger currentCountryArmyCount = gameData.gameMap.getCountry(country).getCountryArmyCount();\r\n \tif (currentCountryArmyCount > maxArmyCountEncountered) {\r\n \t\tstrongestCountry = country;\r\n \t\tmaxArmyCountEncountered = currentCountryArmyCount;\r\n \t} \r\n }\r\n \r\n \treturn strongestCountry;\r\n }", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "public java.lang.String getLastChgBy () {\n\t\treturn lastChgBy;\n\t}", "public java.lang.String getLastChgBy () {\n\t\treturn lastChgBy;\n\t}", "public int getWorstScore()\n {\n return -1;\n }", "public float getAttackCooldown ( ) {\n\t\treturn extract ( handle -> handle.getAttackCooldown ( ) );\n\t}", "public int attack(Character target){ //hw3E#0 //hw46#moreThinking\n lowerHP((int)(strength * attack / 10)); //hw3E#0 //hw46#moreThinking\n return super.attack(target); //hw3E#0 //hw44#3,4 //hw46#moreThinking\n }" ]
[ "0.57924193", "0.5665993", "0.55168515", "0.5453197", "0.5447771", "0.54119694", "0.5279055", "0.52390933", "0.5226832", "0.5214235", "0.5189402", "0.51391935", "0.512775", "0.5062459", "0.50322175", "0.5028178", "0.5026982", "0.5022714", "0.5020893", "0.5005502", "0.49839744", "0.49813932", "0.49767196", "0.4975904", "0.49690726", "0.49654952", "0.49647558", "0.4945238", "0.49357864", "0.4924528", "0.49065232", "0.4905654", "0.490133", "0.4898793", "0.48805022", "0.48791176", "0.4876811", "0.48751324", "0.48520455", "0.48399675", "0.48387608", "0.48298278", "0.48245066", "0.48202458", "0.4813111", "0.4812394", "0.48102683", "0.48068333", "0.48051345", "0.48046055", "0.48043844", "0.4803352", "0.48002234", "0.47734255", "0.47571686", "0.4756479", "0.47523126", "0.47519", "0.47493622", "0.47387585", "0.4727543", "0.4717285", "0.4716755", "0.4712305", "0.47087884", "0.47021237", "0.46934012", "0.46911475", "0.46903694", "0.46893418", "0.4688072", "0.46734196", "0.4671215", "0.466715", "0.46638992", "0.46540847", "0.46486706", "0.4647097", "0.46467257", "0.46447617", "0.4640944", "0.46372604", "0.4633371", "0.46330214", "0.46311384", "0.4630421", "0.46302927", "0.46239138", "0.4609794", "0.4609794", "0.4609794", "0.4609794", "0.4609794", "0.4609794", "0.4609794", "0.4609471", "0.4609471", "0.46080285", "0.4606556", "0.46046194" ]
0.7883218
0
Return the hate level of the L2Attackable against this L2Character contained in aggroList.
public int getHating(final L2Character target) { if (getAggroListRP().isEmpty()) { return 0; } if (target == null) { return 0; } final AggroInfoHolder ai = getAggroListRP().get(target); if (ai == null) { return 0; } if (ai.getAttacker() instanceof L2PcInstance && (((L2PcInstance) ai.getAttacker()).getAppearance().isInvisible() || ((L2PcInstance) ai.getAttacker()).isSpawnProtected() || ((L2PcInstance) ai.getAttacker()).isTeleportProtected() || ai.getAttacker().isInvul())) { // Remove Object Should Use This Method and Can be Blocked While Interating getAggroList().remove(target); return 0; } if (!ai.getAttacker().isVisible()) { getAggroList().remove(target); return 0; } if (ai.getAttacker().isAlikeDead()) { ai.initHate(); return 0; } return ai.getHate(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public L2Character getMostHated()\n\t{\n\t\tif (getAggroListRP().isEmpty() || isAlikeDead())\n\t\t{\n\t\t\treturn null;\n\t\t}\n\t\t\n\t\tL2Character mostHated = null;\n\t\t\n\t\tint maxHate = 0;\n\t\t\n\t\t// While Interating over This Map Removing Object is Not Allowed\n\t\tsynchronized (getAggroList())\n\t\t{\n\t\t\t// Go through the aggroList of the L2Attackable\n\t\t\tfor (final AggroInfoHolder ai : getAggroListRP().values())\n\t\t\t{\n\t\t\t\tif (ai == null)\n\t\t\t\t{\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (ai.getAttacker().isAlikeDead() || !getKnownList().knowsObject(ai.getAttacker()) || !ai.getAttacker().isVisible() || ai.getAttacker() instanceof L2PcInstance && !((L2PcInstance) ai.getAttacker()).isOnline() && !((L2PcInstance) ai.getAttacker()).isInOfflineMode()) // if player go\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// in offline\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// mode, he\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// must be hated\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// however\n\t\t\t\t{\n\t\t\t\t\tai.initHate();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (ai.getHate() > maxHate)\n\t\t\t\t{\n\t\t\t\t\tmostHated = ai.getAttacker();\n\t\t\t\t\tmaxHate = ai.getHate();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (mostHated != null)\n\t\t{\n\t\t\tthis.mostHated = mostHated;\n\t\t}\n\t\t\n\t\treturn mostHated;\n\t}", "public void addDamageHate(final L2Character attacker, final int damage, int aggro)\n\t{\n\t\tif (attacker == null /* || aggroList == null */)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Get the AggroInfo of the attacker L2Character from the aggroList of the L2Attackable\n\t\tAggroInfoHolder ai = getAggroListRP().get(attacker);\n\t\t\n\t\tif (ai == null)\n\t\t{\n\t\t\tai = new AggroInfoHolder(attacker);\n\t\t\tai.init();\n\t\t\tgetAggroListRP().put(attacker, ai);\n\t\t}\n\t\t\n\t\t// If aggro is negative, its comming from SEE_SPELL, buffs use constant 150\n\t\tif (aggro < 0)\n\t\t{\n\t\t\tai.decHate(aggro * 150 / (getLevel() + 7));\n\t\t\taggro = -aggro;\n\t\t}\n\t\t// if damage == 0 -> this is case of adding only to aggro list, dont apply formula on it\n\t\telse if (damage == 0)\n\t\t{\n\t\t\tai.incHate(aggro);\n\t\t\t// else its damage that must be added using constant 100\n\t\t}\n\t\telse\n\t\t{\n\t\t\tai.incHate(aggro * 100 / (getLevel() + 7));\n\t\t}\n\t\t\n\t\t// Add new damage and aggro (=damage) to the AggroInfo object\n\t\tai.incDmg(damage);\n\t\t\n\t\t// Set the intention to the L2Attackable to AI_INTENTION_ACTIVE\n\t\tif (getAI() != null && aggro > 0 && getAI().getIntention() == CtrlIntention.AI_INTENTION_IDLE)\n\t\t{\n\t\t\tgetAI().setIntention(CtrlIntention.AI_INTENTION_ACTIVE);\n\t\t}\n\t\t\n\t\tai = null;\n\t\t// Notify the L2Attackable AI with EVT_ATTACKED\n\t\tif (damage > 0)\n\t\t{\n\t\t\tif (getAI() != null)\n\t\t\t{\n\t\t\t\tgetAI().notifyEvent(CtrlEvent.EVT_ATTACKED, attacker);\n\t\t\t}\n\t\t\t\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif (attacker instanceof L2PcInstance || attacker instanceof L2Summon)\n\t\t\t\t{\n\t\t\t\t\tL2PcInstance player = attacker instanceof L2PcInstance ? (L2PcInstance) attacker : ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\n\t\t\t\t\tfor (final Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_ATTACK))\n\t\t\t\t\t{\n\t\t\t\t\t\tquest.notifyAttack(this, player, damage, attacker instanceof L2Summon);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tplayer = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\tcatch (final Exception e)\n\t\t\t{\n\t\t\t\tLOGGER.error(\"\", e);\n\t\t\t}\n\t\t}\n\t}", "public int getAttackLevel() {\r\n\t\treturn attackLevel;\r\n\t}", "public int calculateCombatLevel() {\r\n if (entity instanceof NPC) {\r\n return ((NPC) entity).getDefinition().getCombatLevel();\r\n }\r\n int combatLevel;\r\n int melee = staticLevels[ATTACK] + staticLevels[STRENGTH];\r\n int range = (int) (1.5 * staticLevels[RANGE]);\r\n int mage = (int) (1.5 * staticLevels[MAGIC]);\r\n if (melee > range && melee > mage) {\r\n combatLevel = melee;\r\n } else if (range > melee && range > mage) {\r\n combatLevel = range;\r\n } else {\r\n combatLevel = mage;\r\n }\r\n combatLevel = staticLevels[DEFENCE] + staticLevels[HITPOINTS] + (staticLevels[PRAYER] / 2) + (int) (1.3 * combatLevel);\r\n return combatLevel / 4;\r\n }", "public int getManaIncreasePerLevel() {\r\n if (_index == 3 || _index == 11 || _index == 6 || _index == 14) {\r\n // Acolytes, High Priests, Druids, or High Druids\r\n return 1;\r\n } else if (isSpellCaster()) {\r\n return 2;\r\n }\r\n return 0;\r\n }", "public int getHerbalismLevel()\n\t{\n\t\tint level = (int) Math.pow(m_skillHerbExp, 0.3333);\n\t\tif(level <= 100)\n\t\t\treturn level;\n\t\telse\n\t\t\treturn 100;\n\t}", "public int getBonusHP() {\n return bonusHP_;\n }", "public int getBonusHP() {\n return bonusHP_;\n }", "public int getBreedingLevel()\n\t{\n\t\tint level = (int) Math.pow(m_skillBreedExp / 1.25, 0.333333333333333333333333333);\n\t\treturn Math.min(level, 100);\n\t}", "@Override\n public L2Attackable getActiveChar() { return (L2Attackable)super.getActiveChar(); }", "public String getAsteroidAttack() {\n\t\tminusShield(2);\n\t\treturn \"Got damaged from the asteroid belt!!\";\n\t}", "AbilityDamage getAbilityDamage();", "public String attack() {\r\n\t\t\tthis.getCurrentEnemy().setHealth(this.getCurrentEnemy().getHealth()-this.getPlayer().getWeapon().getAttack());\r\n\t\t\tif(this.getCurrentEnemy().isDefeated()) {\r\n\t\t\t\tthis.setInBattle(false);\r\n\t\t\t\t\r\n\t\t\t\tthis.handleQuestrelatedEnemy(this.getCurrentEnemy());\r\n\t\t\t\t\r\n\t\t\t\tif(this.getCurrentEnemy().getLoot() != null) {\r\n\t\t\t\t\tthis.getPlayer().getCurrentLocation().addItem(this.getCurrentEnemy().getLoot());\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tthis.getPlayer().gainXp(this.getCurrentEnemy().getXpYield());\r\n\t\t\t\tthis.getPlayer().getCurrentLocation().removeNpc(this.getCurrentEnemy().getName());\r\n\t\t\t\tif(this.getCurrentEnemy().getClass().getName().equals(\"game.EnemyGuardian\")) {\r\n\t\t\t\t\t// adds paths between current location and location in the guardian, path names are specified in the guardian construction\r\n\t\t\t\t\tthis.getPlayer().getCurrentLocation().addPaths(this.getPlayer().getCurrentLocation(), ((EnemyGuardian)this.getCurrentEnemy()).getPathTo(),\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t((EnemyGuardian)this.getCurrentEnemy()).getGuardedLocation(), ((EnemyGuardian)this.getCurrentEnemy()).getPathFrom());\r\n\t\t\t\t\treturn \"You defeated \" + this.getCurrentEnemy().getName() + \". \\n\"\r\n\t\t\t\t\t\t\t+ ((EnemyGuardian)this.getCurrentEnemy()).getRevelationMessage() + \"\\n\";\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\treturn \"You defeated \" + this.getCurrentEnemy().getName() + \".\";\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tthis.triggerEnemyAttack();\r\n\t\t\t\t\tif(this.getPlayer().getHealth() <= 0) {\r\n\r\n\t\t\t\t\t\tthis.gameOver();\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\treturn \"You attacked \" + this.getCurrentEnemy().getName() + \" for \" + this.getPlayer().getWeapon().getAttack() + \" damage. \\n You DIED.\";\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse {\r\n\t\t\t\t\t\treturn \"You attacked \" + this.getCurrentEnemy().getName() + \" for \" + this.getPlayer().getWeapon().getAttack() + \" damage. \\n\"\r\n\t\t\t\t\t\t\t\t+ this.getCurrentEnemy().getName() + \" attacked you for \" + this.getCurrentEnemy().getAttack() + \" damage.\\n\"\r\n\t\t\t\t\t\t\t\t\t\t+ this.getCurrentEnemy().printHealth();\r\n\t\t\t\t\t}\r\n\t\t\t}\r\n\t\t}", "public int attack(Character target){ //hw3E#0 //hw46#moreThinking\n lowerHP((int)(strength * attack / 10)); //hw3E#0 //hw46#moreThinking\n return super.attack(target); //hw3E#0 //hw44#3,4 //hw46#moreThinking\n }", "public L2Character getOverhitAttacker()\n\t{\n\t\treturn overhitAttacker;\n\t}", "public static int getEnemyLives(){\n return 1 + currentLvl * 2;\n\n }", "public int getAvengersHp() {\n\t\tint avengersHp = Battleground.captainAmerica.getHp()\n\t\t\t\t\t\t+ Battleground.hawkeye.getHp()\n\t\t\t\t\t\t+ Battleground.blackWidow.getHp()\n\t\t\t\t\t\t+ Battleground.hulk.getHp()\n\t\t\t\t\t\t+ Battleground.thor.getHp();\n\t\treturn avengersHp;\n\t}", "public void battleAllyAttack() {\n if(battleAlly instanceof Character){\n battleTickStatuses();\n updateBattleSides();\n }\n\n // battleAlly now attacks targetEnemy or preference based on the type of battleAlly\n if(battleAlly != null){ // If all allies have attacked, they cannot attack anymore for this round\n MovingEntity target = battleAlly.getAttackPreference(targetEnemies);\n // if not picky, get preference is the default next target\n if(target == null) {\n target = targetEnemy;\n }\n battleAlly.attack(target, targetAllies, targetEnemies);\n //System.out.println(battleAlly.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still unfriendly\n targetEnemy = checkSideSwap(targetEnemy, true, battleAllies, targetAllies, battleEnemies, targetEnemies);\n }\n battleAlly = nextAttacker(battleAlly, battleAllies);\n\n }\n }", "@Override\r\n\t\tpublic int threat() {\n\t\t\treturn state.getThreat();\r\n\t\t}", "public int calculateAttack() {\n int attack = 0;\n for (Weapon w : equippedWeapons) {\n attack += w.getType().getDamage();\n }\n return attack;\n }", "public int getBestGuy () {\r\n return poblac.getBestGuy();\r\n }", "public int getDamage() {\n \t\treturn damage + ((int) 0.5*level);\n \t}", "float shouldAggroOnHit(IGeneticMob geneticMob, EntityLiving attacker);", "public float getHungerDamage();", "public Integer getAttackWins()\n\t{\n\t\treturn attackWins;\n\t}", "public int getFishingLevel()\n\t{\n\t\tint level = (int) Math.pow(m_skillFishExp, 0.333333333333333333333333333);\n\t\tif(level <= 100)\n\t\t\treturn level;\n\t\telse\n\t\t\treturn 100;\n\t}", "public int getItemEnchantability()\n {\n return this.field_77878_bZ.func_78045_a();\n }", "private int calculateLevelModifierForDrop(final L2PcInstance lastAttacker)\n\t{\n\t\tif (Config.DEEPBLUE_DROP_RULES)\n\t\t{\n\t\t\tint highestLevel = lastAttacker.getLevel();\n\t\t\t\n\t\t\t// Check to prevent very high level player to nearly kill mob and let low level player do the last hit.\n\t\t\tif (getAttackByList() != null && !getAttackByList().isEmpty())\n\t\t\t{\n\t\t\t\tfor (final L2Character atkChar : getAttackByList())\n\t\t\t\t{\n\t\t\t\t\tif (atkChar != null && atkChar.getLevel() > highestLevel)\n\t\t\t\t\t{\n\t\t\t\t\t\thighestLevel = atkChar.getLevel();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// According to official data (Prima), deep blue mobs are 9 or more levels below players\n\t\t\tif (highestLevel - 9 >= getLevel())\n\t\t\t{\n\t\t\t\treturn (highestLevel - (getLevel() + 8)) * 9;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn 0;\n\t}", "public int getDefense() {\n\t\treturn this.defense;\n\t}", "public Attack getBestOpponentAttack()\n\t{\n\t\treturn bestOpponentAttack;\n\t}", "@Override\r\n\tpublic int attack() {\r\n\t\treturn rnd.nextInt(MAX_MONSTER_ATTACK_DAMAGE);\r\n\t}", "int getBonusHP();", "public int getWeaponDamage() {\n return Math.round(type.getWeaponDamage()*type.getItemLevelMultipliers()\n\t\t\t\t[level - 1]);\n }", "public int getHerbalismExp()\n\t{\n\t\treturn m_skillHerbExp;\n\t}", "public int getDamage() {\n //TODO\n return 1;\n }", "public int getAttack() {\n return base.getAttack();\n }", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "public int getHealY()\n\t{\n\t\treturn m_healY;\n\t}", "public short getSiegeWeaponDamage();", "public int getAttack() { return this.attack; }", "public double getOverhitDamage()\n\t{\n\t\treturn overhitDamage;\n\t}", "public Integer getOpponentAttacks()\n\t{\n\t\treturn opponentAttacks;\n\t}", "public static int getChanceToHit(GameCharacter attacker, GameCharacter defender, Weapon attackingWeapon, int fromX, int fromY) {\r\n\t\tOrientation targetOrientation = defender.getOrientation();\r\n\t\tTile to = defender.position().tile();\r\n\t\tOrientation attackerOrientation = Orientation.calculateOrientationToTarget(defender.getMap().isIsometric(), fromX, fromY, to.getX(), to.getY());\r\n\t\tStats stats = attacker.stats();\r\n\t\tint bonus = 0;\r\n\t\tint cth = attackingWeapon != null ? stats.getChanceToHit(attackingWeapon.getSlot()) : stats.getChanceToHit(ItemSlot.RIGHTHAND);\r\n\t\tif (attackingWeapon == null || !attackingWeapon.isRanged()) {\r\n\t\t\tif (targetOrientation == attackerOrientation) {\r\n\t\t\t\tbonus = Configuration.getCtHBonusBack();\r\n\t\t\t} else if (targetOrientation.getOpposite() != attackerOrientation && \r\n\t\t\t\t\ttargetOrientation.getClockwise().getOpposite() != attackerOrientation &&\r\n\t\t\t\t\ttargetOrientation.getAntiClockwise().getOpposite() != attackerOrientation) {\r\n\t\t\t\tbonus = Configuration.getCtHBonusSide();\r\n\t\t\t}\r\n\t\t}\r\n\t\tint ctdop = defender.stats().getDodgeOrParryChance(attackingWeapon);\r\n\t\treturn MathUtil.boxValue(cth + bonus - ctdop, 1, 99);\r\n\t}", "public int getAttack() {\r\n\t\treturn attack;\r\n\t}", "public double attack(Legendary other) {\n double effectiveness = getTypeEffectiveness(other);\n double dmg = computeDamage(effectiveness);\n String attackStatus = Mokedex.getAttackStatus(effectiveness);\n \n LockFactory.getLock(\"mok\").lock();\n other.hp -= dmg;\n System.out.println(name + \" dealt \" + dmg + \"HP to \" + other.name + \"!\\n\");\n System.out.println(attackStatus);\n other.display();\n System.out.println(other.name + \" has \" + Math.max(0, other.hp) + \" remaining health.\\n\");\n if (other.hasFainted()) {\n System.out.println(other.name + \" has fainted!\\n\");\n }\n LockFactory.getLock(\"mok\").unlock();\n other.takeRevenge(this);\n\n return dmg;\n }", "public float GetAchLevel(String user, int gameid) throws InvalidPlayerrException, InvalidGameException {\r\n\t\treturn 0;\r\n\t}", "private void checkIfHungry(){\r\n\t\tif (myRC.getEnergonLevel() * 2.5 < myRC.getMaxEnergonLevel()) {\r\n\t\t\tmission = Mission.HUNGRY;\r\n\t\t}\r\n\t}", "public int getAtk()\r\n {\r\n return attack;\r\n }", "public int getLevel(){\n \t\treturn (strength + intelligence + stamina + Math.abs(charm) + Math.abs(cuteness))/5;\n \t}", "public double getHpns(){\r\n switch(this.grlType){\r\n case \"The Choosy\":\r\n return this.chGrlfrnd.iLevel;\r\n case \"The Normal\":\r\n return this.nGrlfrnd.iLevel;\r\n case \"The Desperate\":\r\n return this.dsGrlfrnd.iLevel;\r\n \r\n }\r\n return 0;\r\n }", "public int getHungerLevel() {\n\t\treturn this.hungerCounter;\n\t}", "int getMinigameDefenseChancesLeft();", "public int getAttack() {\n\t\treturn attack;\n\t}", "public int getAttack() {\n\t\treturn attack;\n\t}", "@Override\n public double getDamageAmount() {\n return this.getStrength().getAbilityValue();\n }", "int getDamage();", "int getDamage();", "int getDamage();", "int getDamage();", "int getDamage();", "public int getHealingNumber() {\n return healingNumber;\n }", "public float getBonusPercentHP() {\n return bonusPercentHP_;\n }", "public int getEquippedWeaponDamage() {\n return 0;\n }", "public float getBonusPercentHP() {\n return bonusPercentHP_;\n }", "public float getAttackCooldown ( ) {\n\t\treturn extract ( handle -> handle.getAttackCooldown ( ) );\n\t}", "public int getHp() \n\t{\n\t\treturn hp;\n\t}", "public int getAttackStrength(Entity var1)\n {\n return 2;\n }", "@Override\n public int doDamage() {\n if (difficulty <5)\n return damage;\n else \n return damage*2;\n }", "public int getHealth() {\n return getStat(health);\n }", "public int getWeaponDamage()\n {\n \t\treturn mystuff.getWepDmg();\n }", "public int getHp() {\n return hp;\n }", "public int getHp() {\r\n return hp;\r\n }", "public short getBowDamage();", "public interface IHitAggro {\n /**\n * shouldAggroOnHit\n * The chance (where 1.0F = 100%) that this mob would be aggroed if struck by this entity\n * Should NOT trigger the aggro itself! That should only occur when actually hit!\n * @param geneticMob the mob being checked\n * @param attacker the entity that could attack\n * @return the chance of aggro (1.0F = 100%, 0.0F = 0%)\n */\n float shouldAggroOnHit(IGeneticMob geneticMob, EntityLiving attacker);\n\n /**\n * aggroHitTimer\n * How long this mob would stay angry at this attacker if aggroed via hit\n * @param geneticMob the mob being checked\n * @param attacker the entity that could attack\n * @return the length, in ticks, of the timer\n */\n int aggroHitTimer(IGeneticMob geneticMob, EntityLiving attacker);\n }", "public int getWeapLvl() {\n\t\treturn weaponLevel;\n\t}", "public int getAttackLength() {\r\n\t\treturn attackLength;\r\n\t}", "public int getItemEnchantability()\r\n {\r\n return this.toolMaterial.getEnchantability();\r\n }", "public final Map<L2Character, AggroInfoHolder> getAggroList()\n\t{\n\t\treturn aggroList;\n\t}", "public double getDodgeChance() {\n return Math.min((this.getAgility().getAbilityValue() / 4.0) * 0.01, 1);\n }", "public int getDamage()\n\t{\n\t\treturn Damage;\n\t}", "public int getDamage() {\n\t\treturn (int) (Math.random() * damageVariance) + damage;\n\t}", "public int getDamage () {\n\t\treturn (this.puissance + stuff.getDegat());\n\t}", "@Override\n\tpublic int getGrowingAge() {\n\t\t// adapter for vanilla code to enable breeding interaction\n\t\treturn isAdult() ? 0 : -1;\n\t}", "public int getGuess() {\n\t\tif (accusation) {\n\t\t\tJOptionPane.showMessageDialog(parent, panel, \"Make an accusation:\", JOptionPane.PLAIN_MESSAGE);\n\t\t} else {\n\t\t\tJOptionPane.showMessageDialog(parent, panel, \"Make a suggestion:\", JOptionPane.PLAIN_MESSAGE);\n\t\t}\n\t\treturn CluedoUI.asInt(characters.getSelectedItem().toString()) \n\t\t\t\t+ CluedoUI.asInt(weapons.getSelectedItem().toString())\n\t\t\t\t + CluedoUI.asInt(rooms.getSelectedItem().toString());\n\t}", "public int getHp() {\n return hp;\n }", "@Override\n\tpublic int calculateAttackType(Entity attacker, Entity defender) {\n\t\tif (attacker.getType() != EntityType.NPC || defender.getType() != EntityType.PLAYER) {\n\t\t\treturn ServerConstants.MELEE_ICON;\n\t\t}\n\t\tNpc attackerAsNpc = (Npc) attacker;\n\n\t\tint randomChanceOfAttack = ThreadLocalRandom.current().nextInt(0, 100);\n\n\t\tif (phase == AbyssalSirePhase.AWAKE) {\n\t\t\tif (randomChanceOfAttack <= 80 || spawns.stream().filter(n -> n != null && !n.isDead()).count() >= 2) {\n\t\t\t\tattack = AbyssalSireAttack.POISON;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.SPAWN;\n\t\t\t}\n\t\t} else if (phase == AbyssalSirePhase.MELEE_COMBAT) {\n\t\t\tif (randomChanceOfAttack <= 50) {\n\t\t\t\tattack = AbyssalSireAttack.SWIPE;\n\t\t\t} else if (randomChanceOfAttack <= 85) {\n\t\t\t\tattack = AbyssalSireAttack.TENDRIL_SWIPE;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.DOUBLE_TENDRIL_SWIPE;\n\t\t\t}\n\t\t} else if (phase == AbyssalSirePhase.MAGIC_COMBAT) {\n\t\t\tif (explosionState == AbyssalSireExplosionState.NONE && attackerAsNpc.getCurrentHitPoints() <= 139) {\n\t\t\t\tattack = AbyssalSireAttack.PORTAL;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.POISON;\n\t\t\t}\n\t\t}\n\t\treturn ServerConstants.MELEE_ICON;\n\t}", "int getIndividualAttack();", "public double getMaxHp() {\n return maxHp;\n }", "private int getAttackAngle() {\n\t\treturn (160 - (level * 10));\n\t}", "int getSuperEffectiveChargeAttacksUsed();", "@Override\r\n public int getBasicValue() {\n return this.getCombatLevel();\r\n }", "public int getEnchantmentLevel() {\n/* 48 */ return this.enchantmentLevel;\n/* */ }", "public double bossHealth(ArrayList<Enemy> currentEnemies) {\n return -1;\n }", "public int getMaxHealth();", "public int getCraftingLevel()\n\t{\n\t\tif((int) Math.pow(m_skillCraftExp, 0.3333) <= 100)\n\t\t\treturn (int) Math.pow(m_skillCraftExp, 0.333333333333333333333333333);\n\t\telse\n\t\t\treturn 100;\n\t}", "public int getBreedingExp()\n\t{\n\t\treturn m_skillBreedExp;\n\t}", "int getAttackRoll();", "public Integer getDefenseWins()\n\t{\n\t\treturn defenseWins;\n\t}", "public int rollAttack()\n {\n Random random2 = new Random();\n int atk = random2.nextInt(20) +1 + attackBonus;\n return atk;\n }", "public int getMaxAttack() {\n\t\treturn maxAttack;\n\t}" ]
[ "0.6761041", "0.6602746", "0.6145217", "0.5885253", "0.58129644", "0.579856", "0.57004243", "0.56867075", "0.56727976", "0.5605665", "0.55823255", "0.5542653", "0.55149317", "0.5495888", "0.54808366", "0.54729646", "0.54633737", "0.5461576", "0.54544854", "0.5447577", "0.5444298", "0.5439075", "0.5437786", "0.54303396", "0.5419144", "0.54188657", "0.53990173", "0.5386623", "0.5378963", "0.5376772", "0.5366745", "0.5356939", "0.53559244", "0.53411216", "0.53403366", "0.5327478", "0.53257316", "0.5319898", "0.53012073", "0.52990097", "0.5297024", "0.5272092", "0.5271318", "0.5267327", "0.5266704", "0.5263723", "0.5251668", "0.52501345", "0.5245184", "0.52247775", "0.5222637", "0.5192704", "0.5179084", "0.5179084", "0.5175561", "0.5174453", "0.5174453", "0.5174453", "0.5174453", "0.5174453", "0.5172641", "0.51679", "0.5163742", "0.51624686", "0.5156909", "0.5156657", "0.51532567", "0.5147406", "0.51441646", "0.5134886", "0.5134192", "0.51314837", "0.5120199", "0.5119982", "0.5118126", "0.5116994", "0.51153266", "0.51122725", "0.51121277", "0.51119286", "0.5109457", "0.5106559", "0.51030415", "0.51013297", "0.5100806", "0.5095152", "0.50911266", "0.50875044", "0.508687", "0.5081572", "0.5074409", "0.50739366", "0.5071761", "0.50713724", "0.50689733", "0.5058301", "0.50569344", "0.5056661", "0.5055038", "0.5041619" ]
0.64842516
2
Calculates quantity of items for specific drop according to current situation
private RewardItem calculateRewardItem(final L2PcInstance lastAttacker, final L2DropData drop, final int levelModifier, final boolean isSweep) { // Get default drop chance if (Config.HIGH_RATE_SERVER_DROPS && !drop.isQuestDrop() && drop.getItemId() != 57) { // it's not adena-->check if drop has an epic jewel // ant queen,orfen,core,frintezza,baium,antharas,valakas,zaken,stones if (drop.getItemId() == 6660 || drop.getItemId() == 6661 || drop.getItemId() == 6662 || drop.getItemId() == 8191 || drop.getItemId() == 6658 || drop.getItemId() == 6656 || drop.getItemId() == 6657 || drop.getItemId() == 6659 || drop.getItemId() >= 6360 && drop.getItemId() <= 6362 || drop.getItemId() >= 8723 && drop.getItemId() <= 8762) { // if epic jewel, seal stones or life stone, continue } else { return null; } } float dropChance = 0; switch (drop.getItemId()) { case 6662: { // core ring if (Config.CORE_RING_CHANCE > 0) { dropChance = (float) 10000 * Config.CORE_RING_CHANCE; } else { dropChance = drop.getChance(); } } break; case 6661: { // orfen earring if (Config.ORFEN_EARRING_CHANCE > 0) { dropChance = (float) 10000 * Config.ORFEN_EARRING_CHANCE; } else { dropChance = drop.getChance(); } } break; case 6659: { // zaken earring if (Config.ZAKEN_EARRING_CHANCE > 0) { dropChance = (float) 10000 * Config.ZAKEN_EARRING_CHANCE; } else { dropChance = drop.getChance(); } } break; case 6660: { // aq ring if (Config.QA_RING_CHANCE > 0) { dropChance = (float) 10000 * Config.QA_RING_CHANCE; } else { dropChance = drop.getChance(); } } break; default: { dropChance = drop.getChance(); } } int deepBlueDrop = 1; if (Config.DEEPBLUE_DROP_RULES) { if (levelModifier > 0) { // We should multiply by the server's drop rate, so we always get a low chance of drop for deep blue mobs. // NOTE: This is valid only for adena drops! Others drops will still obey server's rate deepBlueDrop = 3; if (drop.getItemId() == 57) { deepBlueDrop *= isRaid() ? 1 : Config.RATE_DROP_ITEMS; } } } if (deepBlueDrop == 0) { deepBlueDrop = 1; } // Check if we should apply our maths so deep blue mobs will not drop that easy if (Config.DEEPBLUE_DROP_RULES) { dropChance = (drop.getChance() - drop.getChance() * levelModifier / 100) / deepBlueDrop; } // Applies Drop rates if (drop.getItemId() == 57) { if (this instanceof L2RaidBossInstance) { dropChance *= Config.ADENA_RAID; } else if (this instanceof L2GrandBossInstance) { dropChance *= Config.ADENA_BOSS; } else if (this instanceof L2MinionInstance) { dropChance *= Config.ADENA_MINON; } else { dropChance *= Config.RATE_DROP_ADENA; if (lastAttacker.isVIP()) { dropChance *= Config.VIP_ADENA_RATE; } } } else if (isSweep) { if (this instanceof L2RaidBossInstance) { dropChance *= Config.SPOIL_RAID; } else if (this instanceof L2GrandBossInstance) { dropChance *= Config.SPOIL_BOSS; } else if (this instanceof L2MinionInstance) { dropChance *= Config.SPOIL_MINON; } else { dropChance *= Config.RATE_DROP_SPOIL; if (lastAttacker.isVIP()) { dropChance *= Config.VIP_SPOIL_RATE; } } } else { if (this instanceof L2RaidBossInstance) { dropChance *= Config.ITEMS_RAID; } else if (this instanceof L2GrandBossInstance) { dropChance *= Config.ITEMS_BOSS; } else if (this instanceof L2MinionInstance) { dropChance *= Config.ITEMS_MINON; } else { dropChance *= Config.RATE_DROP_ITEMS; if (lastAttacker.isVIP()) { dropChance *= Config.VIP_DROP_RATE; } } } if (Config.L2JMOD_CHAMPION_ENABLE && isChampion()) { dropChance *= Config.L2JMOD_CHAMPION_REWARDS; } // Round drop chance dropChance = Math.round(dropChance); // Set our limits for chance of drop if (dropChance < 1) { dropChance = 1; } // If item is adena, dont drop multiple time // if (drop.getItemId() == 57 && dropChance > L2DropData.MAX_CHANCE) // dropChance = L2DropData.MAX_CHANCE; // Get min and max Item quantity that can be dropped in one time final int minCount = drop.getMinDrop(); final int maxCount = drop.getMaxDrop(); int itemCount = 0; if (!Config.MULTIPLY_QUANTITY_BY_CHANCE && dropChance > L2DropData.MAX_CHANCE && drop.getItemId() != 57) { dropChance = L2DropData.MAX_CHANCE; } // Count and chance adjustment for high rate servers if (dropChance > L2DropData.MAX_CHANCE && !Config.PRECISE_DROP_CALCULATION) { final int multiplier = (int) dropChance / L2DropData.MAX_CHANCE; if (minCount < maxCount) { itemCount += Rnd.get(minCount * multiplier, maxCount * multiplier); } else if (minCount == maxCount) { itemCount += minCount * multiplier; } else { itemCount += multiplier; } dropChance = dropChance % L2DropData.MAX_CHANCE; } // Check if the Item must be dropped final int random = Rnd.get(L2DropData.MAX_CHANCE); while (random < dropChance) { // Get the item quantity dropped if (minCount < maxCount) { itemCount += Rnd.get(minCount, maxCount); } else if (minCount == maxCount) { itemCount += minCount; } else { itemCount++; } // Prepare for next iteration if dropChance > L2DropData.MAX_CHANCE dropChance -= L2DropData.MAX_CHANCE; } if (Config.L2JMOD_CHAMPION_ENABLE) { if ((drop.getItemId() == 57 || drop.getItemId() >= 6360 && drop.getItemId() <= 6362) && isChampion()) { itemCount *= Config.L2JMOD_CHAMPION_ADENAS_REWARDS; } } if (drop.getItemId() >= 6360 && drop.getItemId() <= 6362) { itemCount *= Config.RATE_DROP_SEAL_STONES; } if (itemCount > 0) { return new RewardItem(drop.getItemId(), itemCount); } else if (itemCount == 0 && Config.DEBUG) { LOGGER.debug("Roll produced 0 items to drop..."); } return null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private int checkItemQuantity() {\n\n int desiredQuantity = initialQuantity;\n MenusItem tempItem = null;\n tempItem = ItemCart.getInstance().checkItem(menusItem);\n\n if(tempItem != null){\n desiredQuantity = tempItem.getDesiredQuantity();\n }\n\n\n return desiredQuantity;\n }", "public int quantityDropped(Random par1Random)\n {\n return dropItemQty;\n }", "private int calculateInputStock_Items() {\n\t\tint total = 0;\n\t\tArrayList<Integer> stock = getAllStockValues();\n\t\tif (!stock.isEmpty()) {\n\t\t\t// get for all K\n\t\t\ttotal += (stock.get(0) * getSetUpMachine().getVending_item().get(\"K\"));\n\t\t\t// get for all S\n\t\t\ttotal += (stock.get(1) * getSetUpMachine().getVending_item().get(\"S\"));\n\t\t\t// get for all F\n\t\t\ttotal += (stock.get(2) * getSetUpMachine().getVending_item().get(\"F\"));\n\t\t\t// get for all N\n\t\t\ttotal += (stock.get(3) * getSetUpMachine().getVending_item().get(\"N\"));\n\t\t}\n\t\treturn total;\n\t}", "float getBonusItemDrop();", "public int quantityDropped(Random p_149745_1_)\n {\n return this.isFullBlock ? 2 : 1;\n }", "int getSellQuantity();", "public int quantityDropped(Random random) {\n/* 37 */ return 0;\n/* */ }", "public int quantityDropped(Random par1Random)\n {\n return 1;\n }", "public int quantityDropped(Random var1)\n {\n return 1;\n }", "public int quantityDropped(Random random)\r\n {\r\n return 0;\r\n }", "public int quantityDropped(Random random) {\n return 0;\n }", "@Override\n public int quantityDroppedWithBonus(int fortune, Random random)\n {\n if (fortune > 0 && Item.getItemFromBlock(this) != this.getItemDropped(this.getBlockState().getValidStates().iterator().next(), random, fortune))\n {\n int i = random.nextInt(fortune + 2) - 1;\n\n if (i < 0)\n {\n i = 0;\n }\n\n return this.quantityDropped(random) * (i + 1);\n }\n else\n {\n return this.quantityDropped(random);\n }\n }", "int getBuyQuantity();", "@Override\n public int summarizeQuantity() {\n int sum = 0;\n\n for ( AbstractItem element : this.getComponents() ) {\n sum += element.summarizeQuantity();\n }\n\n return sum;\n }", "public int quantityDropped(Random var1)\r\n {\r\n return this.blockID != mod_XaedCraft.oreCopper.blockID && this.blockID != mod_XaedCraft.oreTin.blockID && this.blockID != mod_XaedCraft.oreBrimstone.blockID ? (this.blockID == mod_XaedCraft.oreRune.blockID ? 3 + var1.nextInt(4) : 1) : 1 + var1.nextInt(4);\r\n }", "int getQuantity();", "long getQuantity();", "long getQuantity();", "@Override\n public int quantityDropped(int meta, int fortune, Random random)\n {\n return super.quantityDropped(meta, fortune, random);\n }", "public int quantityDropped(EaglercraftRandom par1Random) {\n\t\treturn 3 + par1Random.nextInt(5);\n\t}", "@Override\r\n public int getItemQuantity() {\n return this.quantity;\r\n }", "public int quantityDroppedWithBonus(int var1, Random var2)\r\n {\r\n if (var1 > 0 && this.blockID != this.idDropped(0, var2, var1))\r\n {\r\n int var3 = var2.nextInt(var1 + 2) - 1;\r\n\r\n if (var3 < 0)\r\n {\r\n var3 = 0;\r\n }\r\n\r\n return this.quantityDropped(var2) * (var3 + 1);\r\n }\r\n else\r\n {\r\n return this.quantityDropped(var2);\r\n }\r\n }", "protected abstract long getAmount(ItemVariant currentVariant);", "public int getQuantity();", "@Override\n\tpublic int quantityDropped(Random par1Random) {\n\t\treturn 1;\n\t}", "public int quantityDropped(int meta, int fortune, Random par1Random) {\n\t\tRandom rnd = new Random();\n\t\tfortune = fortune+1;\n\t\tint i = rnd.nextInt(3) + 1;\n\t\tint fortrand = par1Random.nextInt(fortune);\n\t\tfortrand = fortrand * (rnd.nextInt(3)+1);\n\t\ti = i + fortrand;\n\t\tSystem.out.println(\"fortune: \" + (fortune - 1));\n\t\tSystem.out.println(i);\n\n\t\treturn i;\n\t}", "public int howManyAvailable(Item i){/*NOT IMPLEMENTED*/return 0;}", "public void itemsSold() {\n quanitySnacks--;\n }", "public Integer getQuantity();", "public int getAddItems(int totalCollected, int totalItemInGame);", "public int inventorySize (TheGroceryStore g);", "boolean hasBonusItemDrop();", "protected void dropFood() {\r\n\t\tthis.food++;\r\n\t}", "public double getDropAmount() {\n return dropAmount;\n }", "public int quantity(final T item) {\n if (items.containsKey(item)) {\n return items.get(item);\n } else {\n return 0;\n }\n }", "private void minusQuantity(TextField source, Clothing clothing) {\n clothing.setCount(-1);\n int quantity = clothing.getCount();\n double totalPriceOfClothing = 0;\n\n for (int i = 0; i < clothingArrayList.size(); i++) {\n double countOfItems = clothingArrayList.get(i).getCount();\n double clothingPricePerUnit = Double.valueOf(clothingArrayList.get(i).getPrice());\n totalPriceOfClothing += clothingPricePerUnit * countOfItems;\n\n }\n source.setText(\"\" + (quantity));\n totalPrices.setText(\"\" + totalPriceOfClothing );\n\n }", "public int quantityDroppedWithBonus(int par1, EaglercraftRandom par2Random) {\n\t\tint var3 = this.quantityDropped(par2Random) + par2Random.nextInt(1 + par1);\n\n\t\tif (var3 > 9) {\n\t\t\tvar3 = 9;\n\t\t}\n\n\t\treturn var3;\n\t}", "private synchronized int determineLastSaleQuantity(HashMap<String, FillMessage> fills) throws InvalidDataException {\n\t\tif (fills == null) throw new InvalidDataException(\"Fills cannot be null.\");\n\t\tArrayList<FillMessage> msgs = new ArrayList<FillMessage>(fills.values()); \n\t\t//Collections.sort(msgs);\n\t\tCollections.sort(msgs);\n\t\tCollections.reverse(msgs);\n\t\treturn msgs.get(0).getVolume();\n\t}", "@Override\n\tpublic int quantityDropped(int parMetadata, int parFortune, Random parRand)\n {\n return (parMetadata/2);\n }", "private boolean checkStock(){\n int i;\n int inventorySize = inventory.size();\n int count = 0;\n for(i = 0; i < inventorySize; i++){\n count = count + inventory.get(i).getStock();\n\n }\n //System.out.println(\"Count was: \" + count);\n if(count < 1){\n return false;\n }else{\n return true;\n }\n }", "private void totalQuantityInventory(String drugName, String expireDate) {\r\n\r\n\t\tPreparedStatement ps = null, ps2 = null;\r\n\t\tResultSet rs = null, rs2 = null;\r\n\t\tint qttyDemandedTotal2 = 0;\r\n\t\tString qry = \"Select quantity, batchNo, voucherNo, Re_Order_Qtty,category From drug_inventory where expiryDate=? and\"\r\n\t\t\t\t+ \" description=?\";\r\n\r\n\t\tString qry2 = \"SELECT SUM(quantityDemanded) as quantitd from counterdrugordertable \"\r\n\t\t\t\t+ \"where expiryDate=? AND drugNameOrder =?\";\r\n\r\n\t\ttry {\r\n\r\n\t\t\ttry {\r\n\t\t\t\tps = St_MaryConnection.getConnection().prepareStatement(qry);\r\n\t\t\t\tps.setString(1, expireDate);\r\n\t\t\t\tps.setString(2, drugName);\r\n\r\n\t\t\t\t//\r\n\t\t\t\tps2 = St_MaryConnection.getConnection().prepareStatement(qry2);\r\n\t\t\t\tps2.setString(1, expireDate);\r\n\t\t\t\tps2.setString(2, drugName);\r\n\t\t\t\trs2 = ps2.executeQuery();\r\n\r\n\t\t\t\twhile (rs2.next()) {\r\n\t\t\t\t\tqttyDemandedTotal2 = rs2.getInt(\"quantitd\");\r\n\t\t\t\t\tSystem.out.println(qttyDemandedTotal2);\r\n\t\t\t\t}\r\n\r\n\t\t\t} catch (SQLException exc) {\r\n\t\t\t\tSystem.out.println(\"getting the remaining qtty from inventory table error\\n\" + exc);\r\n\t\t\t}\r\n\r\n\t\t\trs = ps.executeQuery();\r\n\t\t\twhile (rs.next()) {\r\n\r\n\t\t\t\tString batchNo = rs.getString(\"batchNo\");\r\n\t\t\t\tString voucherNo = rs.getString(\"voucherNo\");\r\n\t\t\t\tint qttyReamaining = rs.getInt(\"quantity\");\r\n\t\t\t\tString reOrderQ = rs.getString(\"Re_Order_Qtty\");\r\n\t\t\t\tString category = rs.getString(\"category\");\r\n\r\n\t\t\t\tinputLabel[2].setText(\"Re-Order Quantity:____________ \" + reOrderQ+\"____\");\r\n\t\t\t\tinputLabel[3].setText(\"Unit Of Issue:____________\" + category+\"____\");\r\n\r\n\t\t\t\tmodel2.addRow(new String[] { \"\" + (qttyDemandedTotal2 + qttyReamaining), \"\" + qttyReamaining, voucherNo,\r\n\t\t\t\t\t\tbatchNo });\r\n\r\n\t\t\t}\r\n\t\t} catch (SQLException exc) {\r\n\t\t\tSystem.out.println(\"getting the remaining qtty from inventory table error\\n\" + exc);\r\n\t\t}\r\n\t}", "@Override\n public int quantityDroppedWithBonus(int par1, Random par2Random)\n {\n return 1 + par2Random.nextInt(par1 * 2 + 1);\n }", "public int getItemQty() {\n return itemQty;\n }", "public double getFoodQuantity() {\r\n\t\treturn fruitQuantity + meatQuantity;\r\n\t}", "public abstract int getAmount(Fluid fluid);", "BigDecimal getQuantity();", "private int countProductsInCart_UPDATED() {\n System.out.println(\"-=====================Shopping Cart List========================================-\");\n int count, value;\n count = 0;\n List<WebElement> cakes = getDriver().findElements(By.xpath(\"//*[text()='Edit Your Cake']\"));\n List<WebElement> sthAndCnC = getDriver().findElements(By.xpath(\"//*[starts-with(@id, 'basketBody_') and @type='number']\"));\n System.out.println(\" === adding \" + cakes.size() + \" cakes to count\");\n count += cakes.size();\n for (WebElement product : sthAndCnC) {\n if ((!product.getAttribute(\"value\").equals(\"\")) && (product.getAttribute(\"value\") != null)) {\n String checkForLB = product.getAttribute(\"data-qtyincrement\");\n if (checkForLB.contains(\"0.\")) { //To validate for LB(s) items\n value = 1;\n } else {\n value = Integer.valueOf(product.getAttribute(\"value\"));\n }\n System.out.println(\"=== adding \" + value + \" cnc or sth item to cart\");\n count += value;\n } else {\n System.out.println(\"=== error adding product quantity\");\n }\n }\n System.out.println(\" === Count was: \" + count);\n System.out.println(\"-=====================Shopping Cart List========================================-\");\n return count;\n }", "BigDecimal getOriginalQuantity();", "public int adjustQuantitiesInDB(Ingredient ingredient, int givenQuantity)throws SQLException{ //adds a current type of ingredient to database takes in quantity and ingredient object \r\n\t\tint newQuantity;\r\n\t\tString requiredIngredientName = ingredient.getName();\r\n\t\tString sqlUpdate = \"update stock_ingredients set quantity = quantity + \" + givenQuantity + \" where name = \" + \"'\" + requiredIngredientName + \"'\";\r\n\t\t\t\r\n\t\t//find correct syntax for increasing the quantity by x amount\r\n\r\n\t\tConnection connection = connectToDB(databaseUser, databasePass);\r\n\r\n\t\tPreparedStatement ps = connection.prepareStatement(sqlUpdate);\r\n\r\n\t\tps.executeUpdate();\r\n\r\n\t\tnewQuantity = checkCurrentStockLevels(ingredient);\r\n\r\n\t\tconnection.close();\r\n\t\t\r\n\t\treturn newQuantity;\r\n\r\n\t}", "public void calculateCost() {\n \tdouble costToShipPack;\n \tint numOfPacks = 1;\n \t\n \tfor(Package p: this.packages) {\n \t\tcostToShipPack = 3 + (p.calcVolume() - 1);\n \t\tthis.totalAmounts.put(\"Package \"+numOfPacks, costToShipPack);\n \t\tnumOfPacks++;\n \t}\n \t\n }", "public int adjustForCrowding() {\n int deadGuppyCount = 0;\n\n Collections.sort(this.guppiesInPool, new Comparator<Guppy>() {\n @Override\n public int compare(Guppy g1, Guppy g2) {\n return Double.compare(g1.getHealthCoefficient(), g2.getHealthCoefficient());\n }\n });\n\n Guppy weakestGuppy;\n Iterator<Guppy> it = guppiesInPool.iterator();\n double volumeNeeded = this.getGuppyVolumeRequirementInLitres();\n\n while (it.hasNext() && volumeNeeded > this.getVolumeLitres()) {\n weakestGuppy = it.next();\n volumeNeeded -= (weakestGuppy.getVolumeNeeded() / ML_TO_L_CONVERSION);\n\n weakestGuppy.setIsAlive(false);\n\n\n deadGuppyCount++;\n\n }\n return deadGuppyCount;\n }", "public void popItems() {\n\t\t\n\t\tItemList.add(HPup);\n\t\tItemList.add(SHPup);\n\t\tItemList.add(DMGup);\n\t\tItemList.add(SDMGup);\n\t\tItemList.add(EVup);\n\t\tItemList.add(SEVup);\n\t\t\n\t\trandomDrops.add(HPup);\n\t\trandomDrops.add(SHPup);\n\t\trandomDrops.add(DMGup);\n\t\trandomDrops.add(SDMGup);\n\t\trandomDrops.add(EVup);\n\t\trandomDrops.add(SEVup);\n\t\t\n\t\tcombatDrops.add(SHPup);\n\t\tcombatDrops.add(SDMGup);\n\t\tcombatDrops.add(SEVup);\n\t}", "public int howMany(int temp) {\n // initial quantity is 0\n int totalQuantity = 0;\n // for each item\n for (int i = 0; i < this._noOfItems; i++) {\n FoodItem currentItem = this._stock[i];\n // if refridgerator temperature is in the item's valid temperature range\n if (temp >= currentItem.getMinTemperature() &&\n temp <= currentItem.getMaxTemperature()) {\n // sum the quantity of the item with previous quantitys sum\n totalQuantity += currentItem.getQuantity();\n }\n }\n // and return the total quantity\n return totalQuantity;\n }", "public float getBonusItemDrop() {\n return bonusItemDrop_;\n }", "@Modifying(clearAutomatically = true)\n @Query(\"UPDATE Item i SET i.quantity = i.quantity - ?1 WHERE i =?2\")\n int deductFromStock(double qty, Item item);", "public void changeQuantity(int difference) {\n\t\tquantity += difference;\n\t\t\n\t\tif (quantity < 0)\n\t\t\tquantity = 0;\n\t}", "public int dropPotion() {\r\n\t\t// If the random number generated is larger than the \r\n\t\t// drop chance, at least one health potion is dropped\r\n\t\tif (rnd.nextInt(100) < HEALTH_POTION_DROP_CHANCE) {\r\n\t\t\treturn rnd.nextInt(MAX_NO_HEALTH_POTION_DROP) + 1;\r\n\t\t}\r\n\t\t// no health potions dropped\r\n\t\treturn 0;\r\n\t}", "public float getBonusItemDrop() {\n return bonusItemDrop_;\n }", "public void setItemsQuantity(Integer itemsQuantity) {\r\n this.itemsQuantity = itemsQuantity;\r\n }", "default int countItems(Predicate<ItemStack> filter) {\n return streamStacks().filter(filter).mapToInt(InvTools::sizeOf).sum();\n }", "private void printDecreaseItemQuantityMenu(Shop shop, FileManager fileManager) {\n ArrayList<Tool> toolList = new ArrayList<Tool>();\n String selection = \"Y\";\n toolList = sellTools(shop, toolList, selection);\n createAutoOrder(shop, fileManager, toolList);\n }", "public static Data<String> weaponMunitionQuantity(){\n\t\tData<String> res = new Data<String>();\n\t\tres.add(new Tuple<String, Integer>(\"2d10\", 10));\n\t\tres.add(new Tuple<String, Integer>(\"4d10\", 10));\n\t\tres.add(new Tuple<String, Integer>(\"1\", 60));\n\t\tres.add(new Tuple<String, Integer>(\"2d10\", 10));\n\t\tres.add(new Tuple<String, Integer>(\"4d10\", 10));\n\t\t\n\t\treturn res;\n\t}", "public int getTotalPriceOfReservedBeanBags() {\n int TotalReservedPrice = 0;\r\n // Loop through every object in the \"stockList\" object array list.\r\n for (int i = 0; i < stockList.size(); i++) {\r\n // Define int \"CurrentPrice\" and set to value in the \"stockList\" object array list.\r\n int CurrentPrice = ((BeanBag) stockList.get(i)).getPrice();\r\n // If the beanbag in \"stockList\" is reserved.\r\n if (((BeanBag) stockList.get(i)).getReserved()) {\r\n // Increment the value of \"TotalReservedPrice\" by int \"CurrentPrice\".\r\n TotalReservedPrice = TotalReservedPrice + CurrentPrice;\r\n }\r\n }\r\n // Once all value's examined, return the value of \"TotalReservedPrice\" int.\r\n return TotalReservedPrice;\r\n }", "private void updateItemQuantityAndTotal(Item item){\r\n\t\tItem oldItem = items.get(item.getItemIdentifier());\r\n\t\toldItem.increaseQuantity(new Amount(1));\r\n\t\titems.put(oldItem.getItemIdentifier(), oldItem);\r\n\t\ttotal.updateTotal(item);\r\n\t}", "public int getQty() {\n return (isReturn ? qty * -1 : qty);\n }", "public void totalDaysNutrition(){\n\n //if no meals are set clear the daily nutritional information\n if (breakfastCombo.getSelectionModel().isEmpty() && lunchCombo.getSelectionModel().isEmpty() &&\n dinnerCombo.getSelectionModel().isEmpty()){\n clearTotalNutrition();\n return;\n }\n\n double totalCalories = 0;\n double totalSugar = 0;\n double totalProtein = 0;\n double totalFibre = 0;\n double totalCarbs = 0;\n double totalFat = 0;\n\n //get breakfast nutritional information\n //if there is a selection priorities over saved meal\n if (!breakfastCombo.getSelectionModel().isEmpty()){\n Recipe breakfast = breakfastCombo.getSelectionModel().getSelectedItem();\n totalCalories = breakfast.getTotalCalories();\n totalCarbs = breakfast.getTotalCarbs();\n totalSugar = breakfast.getTotalSugar();\n totalProtein = breakfast.getTotalProtein();\n totalFibre = breakfast.getTotalFibre();\n totalFat = breakfast.getTotalFat();\n }\n\n //get lunch nutritional information\n //if there is a selection priorities over saved meal\n if (!lunchCombo.getSelectionModel().isEmpty()){\n Recipe lunch = lunchCombo.getSelectionModel().getSelectedItem();\n totalCalories += lunch.getTotalCalories();\n totalCarbs += lunch.getTotalCarbs();\n totalSugar += lunch.getTotalSugar();\n totalProtein += lunch.getTotalProtein();\n totalFibre += lunch.getTotalFibre();\n totalFat += lunch.getTotalFat();\n }\n\n //get dinner nutritional information\n //if there is a selection priorities over saved meal\n if (!dinnerCombo.getSelectionModel().isEmpty()){\n Recipe dinner = dinnerCombo.getSelectionModel().getSelectedItem();\n totalCalories += dinner.getTotalCalories();\n totalCarbs += dinner.getTotalCarbs();\n totalSugar += dinner.getTotalSugar();\n totalProtein += dinner.getTotalProtein();\n totalFibre += dinner.getTotalFibre();\n totalFat += dinner.getTotalFat();\n }\n\n //round the totals\n int calories = (int) Math.round(totalCalories);\n int sugar = (int) Math.round(totalSugar);\n int protein = (int) Math.round(totalProtein);\n int fibre = (int) Math.round(totalFibre);\n int carbs = (int) Math.round(totalCarbs);\n int fat = (int) Math.round(totalFat);\n\n //format information into strings\n String lineOne = \"Calories \" + calories + \"KCal\\t Sugar \" + sugar + \" g\\t\\t Protein \" + protein + \" g\";\n String lineTwo = \"Fibre \" + fibre + \" g\\t\\t\\t Carbs \" + carbs + \" g\\t\\t Fat \" + fat + \" g\";\n\n //format and display the information in labels\n setUpNutritionLabel(totalNutritionOne, plannerColor, lineOne);\n setUpNutritionLabel(totalNutritionTwo, plannerColor, lineTwo);\n\n }", "Quantity getQuantity();", "public NM getNumberOfItemsPerUnit() { \r\n\t\tNM retVal = this.getTypedField(14, 0);\r\n\t\treturn retVal;\r\n }", "public double totalQuantity() {\r\n\t\tdouble t = 0;\r\n\t\tfor(int i=0;i<boxes[0];i++)\r\n\t\t\tfor(int j=0;j<boxes[1];j++)\r\n\t\t\t\tfor(int k=0;k<boxes[2];k++) t += quantity[i][j][k];\r\n\t\treturn t;\r\n\t}", "public int numSpaceLeft()\n {\n \n return itemLimit - itemsHeld;\n }", "public void decdrum(String quantity1, String capacity) {\nString countQuery = \"SELECT \"+Drum_Quantity + \" FROM \" + DATABASE_TABLE4+\" WHERE \"+Drum_Capacity+\" ='\"+capacity+\"'\";\n\t \n\t Cursor cursor = ourDatabase.rawQuery(countQuery, null);\n\t int d=cursor.getColumnIndex(Drum_Quantity);\n\t\tString cbal=null;\n\t\tfor(cursor.moveToFirst();!cursor.isAfterLast();cursor.moveToNext()){\n\t\t\tcbal=cursor.getString(d);\n\t\t\t\n\t\t}\n\t\tint cur=Integer.parseInt(cbal);\n\t\t\n\t\tcur=cur-Integer.parseInt(quantity1);\n\t ContentValues up=new ContentValues();\n\t up.put(Drum_Quantity, cur);\n\t\tSystem.out.println(\"Final stat=\"+cur);\n\t ourDatabase.update(DATABASE_TABLE4, up, Drum_Capacity+\" = '\"+capacity+\"'\", null);\n\t\t\n\t}", "public Knapsack bruteForceCalc (ArrayList <Item> items,int capacity, int num_items) {\n\t\tif (num_items <= 0) {\n\t\t\tKnapsack knapsack = new Knapsack(0);\n\t\t\treturn knapsack;\n\t\t} \n\t\telse if (items.get(num_items -1).getWeight() > capacity) {\n\t\t\treturn bruteForceCalc(items, capacity, num_items - 1);\n\t\t} else {\n\n\t\t\tKnapsack ignore = bruteForceCalc(items,capacity, num_items - 1);\n\t\t\tKnapsack take = bruteForceCalc(items,capacity - items.get(num_items -1).getWeight(), num_items - 1);\n\t\t\t\n\t\t\tint ignoreVal = ignore.getValue();\n\t\t\tint takeVal = items.get(num_items - 1).getValue() + take.getValue();\n\t\t\t \n\t\t\tif( Math.max(ignoreVal, takeVal) == ignoreVal ) \n\t\t\t\treturn ignore;\n\t\t\telse {\n\t\t\t\ttake.addItem(items.get(num_items - 1));\n\t\t\t\treturn take;\n\t\t\t}\n\t\t}\n\t}", "public int calculatePrice() {\n int price = 5;\n if(hasWhippedCream) {\n price += 1;\n }\n if(hasChocolate) {\n price += 2;\n }\n return quantity * price;\n }", "@Override\n\tpublic int totalItem() {\n\t\treturn 0;\n\t}", "public int getQuantity() {\r\n return quantity;\r\n }", "public int getTotalSupply() {\n if (this.totalSupply == -1) {\n int tempTotalSupply = 0;\n for (G good : this.goods) {\n tempTotalSupply += good.getSupply();\n }\n this.totalSupply = tempTotalSupply;\n }\n return this.totalSupply;\n }", "private void dropAllDrops(ItemStack drop, int amount, Location dropLocation, boolean addEnchantment){\n double inStacks = (double) amount / (double) drop.getMaxStackSize();\n double floor = Math.floor(inStacks);\n double leftOver = inStacks - floor;\n for(int i = 1; i <= floor; i++){\n ItemStack newStack = drop.clone();\n newStack.setAmount(drop.getMaxStackSize());\n if(addEnchantment){\n newStack.addUnsafeEnchantment(Enchantment.DIG_SPEED, 1);\n }\n dropLocation.getWorld().dropItemNaturally(dropLocation, newStack);\n }\n if(leftOver > 0){\n ItemStack newStack = drop.clone();\n newStack.setAmount((int) Math.round(leftOver * drop.getMaxStackSize()));\n if(addEnchantment){\n newStack.addUnsafeEnchantment(Enchantment.DIG_SPEED, 1);\n }\n dropLocation.getWorld().dropItemNaturally(dropLocation, newStack);\n }\n }", "public int getQuantity() {\r\n return quantity;\r\n }", "public void update() {\n\t\tthis.quantity = item.getRequiredQuantity();\n\t}", "public static int calculateTotal(SQLiteDatabase db){\n // Retrieve only items with positive quantity\n Cursor c = db.query(StoreItems.TABLE_NAME, new String[] {StoreItems._ID, StoreItems.COLUMN_NAME_PRICE, StoreItems.COLUMN_NAME_QUANTITY}, StoreItems.COLUMN_NAME_QUANTITY + \">0\", null, null, null, null);\n \n // Add all items to total\n c.moveToFirst();\n int sum = 0;\n while(!c.isAfterLast())\n {\n sum += c.getInt(c.getColumnIndex(StoreItems.COLUMN_NAME_QUANTITY)) * c.getInt(c.getColumnIndex(StoreItems.COLUMN_NAME_PRICE));\n c.moveToNext();\n }\n return sum;\n }", "public void rollItems() {\n Integer dRoll = dCalc.rollPercent();\n Integer itemGroup = dCalc.getItemGrouping(dRoll);\n Integer numItems = 0;\n if (dCalc.getPrefs().isNoRepeats()) {\n numItems = (int) (dCalc.getNumItems(dRoll) * dCalc\n .getTreasureMultiplier()) + trove.size();\n } else {\n numItems = (int) (dCalc.getNumItems(dRoll) * dCalc\n .getTreasureMultiplier()) + hoard.size();\n }\n\n // If you aren't rolling mundane items, tell the user how many\n if ((itemGroup == 1) && !dCalc.getPrefs().isRollMundane()) {\n LootOutListItem mundanes = new LootOutListItem();\n mundanes.setQuantity(dCalc.getNumItems(dRoll));\n mundanes.setName(\"Mundane Items\");\n addItem(mundanes);\n } else {\n\n // Roll each Item, then add to the ArrayList.\n while ((hoard.size() < numItems) && (trove.size() < numItems)) {\n LootOutListItem item = new LootOutListItem(\n this.dCalc.rollItem(itemGroup));\n\n addItem(item);\n\n }\n }\n }", "private void adjustAddedQty(){\n \tString tmp1=jTable1.getModel().getValueAt(jTable1.getSelectedRow(), 3).toString();\n \t\n \tif(!addedBom.contains(tmp1)){\n \t\treturn;\n \t}\n \tint k=addedBom.indexOf(tmp1);\n \tjava.util.Vector<String> tmp2=addedBomDet.elementAt(k);\n \tfor (int i = 0; i<bomDet.length; i++){\n \t\tif(tmp2.contains(bomDet[i][1].toString())){\n \t\t\tbomDet[i][3]=new Long(0);\n \t\t}\n \t}\n \t\n }", "public double calculatePrice() {\r\n\t\treturn menuItem.getPrice() * quantity;\t\r\n\t}", "public static void calculateTotal(){\n int i=0;\n total=0;\n while(i<CustomAdapter.selecteditems.size()){\n total+= CustomAdapter.selecteditems.get(i).getPrice() * CustomAdapter.selecteditems.get(i).getQuantity();\n i++;\n }\n String s=\"Rs \"+String.valueOf(total);\n tv_total.setText(s);\n }", "public void rollCombatDrop() {\n\t\tRandom r=new Random();\n\t\t\n\t\tint x=r.nextInt(3);\n\t\tItem i=combatDrops.get(x);\n\t\taddItem(i.getName());\n\t\t\n\t\tevents.appendText(\"You find an \"+i.getName()+\" after defeating the \"+e.getName()+\"!\\n\"); // Infrom player\n\t}", "public int getInventoryLength() {\n return items.length;\n }", "public ArrayList<Item> drop()\n {\n ArrayList<Item> drop = new ArrayList<>();\n for( Pair<Enums.ItemName, Integer> possibleDrop : dropTable)\n {\n if(ThreadLocalRandom.current().nextInt(100) < possibleDrop.getY())\n drop.add(new Item(possibleDrop.getX()));\n }\n return drop;\n }", "@Override\n\tpublic int buy(Weapon item) {\n\t\treturn 0;\n\t}", "public synchronized int getNumberOfItems(){\n int totalItems=0;\n \n for(ShoppingCartItem item : getItems()){\n //we sum the quantity of products for each item\n totalItems += item.getQuantity();\n }\n \n return totalItems;\n }", "public int getQuantity()\n {\n return quantity;\n }", "int getQuantite();", "int getQuantite();", "@Override\n\tpublic int getNoofQuantity() {\n\t String sql=\"SELECT SUM(quantity) FROM supplier_product\";\n\t int total=this.getJdbcTemplate().queryForObject(sql, Integer.class);\n\t\treturn total;\n\t}", "@Override\n public int getMaxItemUseDuration(ItemStack par1ItemStack) {\n return 10;\n }", "public int getAgentsQty();", "public int getQuantity() \n\t{\n\t\treturn quantity;\n\t}", "public int getQuantity()\n {\n \treturn quantity;\n }", "@Override\r\n public void ItemQuantity(int quantity) {\n this.quantity = quantity;\r\n }", "public int getMaxItemUseDuration(ItemStack var1)\r\n {\r\n return 72000;\r\n }", "public int addItemStack(ItemStack itemStack) {\n Item item = itemStack.getItem();\n int amount = itemStack.getAmount();\n int added = 0;\n\n List<ItemStack> itemStacksToRemove = new ArrayList<>();\n for (ItemStack itemStack1 : this.ITEMS) {\n if (itemStack1.getItem() == item) {\n amount += itemStack1.getAmount();\n itemStacksToRemove.add(itemStack1);\n }\n }\n\n // clear inventory\n for (ItemStack itemStack1 : itemStacksToRemove)\n this.ITEMS.remove(itemStack1);\n\n System.out.println(String.format(\"Total amount of %s: %d\", item.getName(), amount));\n\n int stack_size = item.getMaxStack();\n int stacks = amount / stack_size;\n int last_stack = amount % stack_size;\n\n System.out.println(String.format(\"Stack size: %d, full stacks: %s, last stack: %d, inv size: %d, inv full: %d\", stack_size, stacks, last_stack, this.getSize(), this.ITEMS.size()));\n\n // add full stacks\n for (int i = 0; i < stacks; i++) {\n if (this.ITEMS.size() > this.getSize())\n break;\n\n System.out.println(\"Added full stack\");\n this.ITEMS.add(new ItemStack(item, stack_size));\n added += stack_size;\n }\n\n // add last (not full) stack\n if (last_stack != 0 && this.ITEMS.size() < this.getSize()) {\n System.out.println(\"Added partial stack\");\n this.ITEMS.add(new ItemStack(item, last_stack));\n added += last_stack;\n }\n\n for (InventoryChangedEvent listener : listeners)\n listener.onInventoryChanged(this);\n\n return added;\n }", "public int getremainingstock(String selection,String item) throws SQLException\n {\n // int stock_rate[]= new int [2];\n PreparedStatement remaining_stock = conn.prepareStatement(\"Select stock from purchases where Categroy=? and Item=? \");\n remaining_stock.setString(1, selection);\n remaining_stock.setString(2, item);\n ResultSet remaining_stock_rows = remaining_stock.executeQuery(); \n \n int sum=0,current=0;\n while(remaining_stock_rows.next()) \n {\n sum=Integer.parseInt(remaining_stock_rows.getString(1));\n \n \n }\n return sum;\n }" ]
[ "0.6781937", "0.6726248", "0.6618588", "0.6543516", "0.6441358", "0.6347291", "0.63443696", "0.6277721", "0.6268163", "0.6264969", "0.62472206", "0.61496145", "0.6133411", "0.61322814", "0.6102423", "0.6095655", "0.60607773", "0.60607773", "0.6014374", "0.59972245", "0.5948698", "0.5943096", "0.5939633", "0.5888696", "0.588702", "0.58766437", "0.58389395", "0.58288795", "0.5814205", "0.5809649", "0.57938987", "0.5759566", "0.5743723", "0.57433844", "0.5715669", "0.57052714", "0.5700322", "0.56846076", "0.56755006", "0.5673037", "0.5661934", "0.56449205", "0.5621134", "0.5595312", "0.558092", "0.55802715", "0.5570523", "0.55638444", "0.55620515", "0.5548292", "0.5544376", "0.5530682", "0.55182594", "0.55116147", "0.5506621", "0.54929817", "0.548823", "0.54841745", "0.548041", "0.5478843", "0.546851", "0.5467182", "0.5457116", "0.54552186", "0.54503983", "0.54420376", "0.543778", "0.5436778", "0.54357785", "0.5433671", "0.54284644", "0.54157984", "0.5411082", "0.5400983", "0.53960335", "0.5392352", "0.53897697", "0.538854", "0.5378127", "0.537202", "0.53714067", "0.5367575", "0.5367089", "0.5357365", "0.53553617", "0.53459185", "0.53454584", "0.53452635", "0.53440195", "0.5331839", "0.53291285", "0.53291285", "0.5328726", "0.5325559", "0.53236866", "0.53219914", "0.5315207", "0.5315174", "0.5314733", "0.53122246", "0.5307402" ]
0.0
-1
Calculates quantity of items for specific drop CATEGORY according to current situation Only a max of ONE item from a category is allowed to be dropped.
private RewardItem calculateCategorizedRewardItem(final L2PcInstance lastAttacker, final L2DropCategory categoryDrops, final int levelModifier) { if (categoryDrops == null) { return null; } if (Config.HIGH_RATE_SERVER_DROPS && categoryDrops.getCategoryType() != 0) { // it's not adena-->check if drop is quest or is an epic jewel boolean to_drop = false; for (final L2DropData dd : categoryDrops.getAllDrops()) { // quest_drop,ant queen,orfen,core,frintezza,baium,antharas,valakas,zaken, seal Stones, life stones if (dd.isQuestDrop() || dd.getItemId() == 6660 || dd.getItemId() == 6661 || dd.getItemId() == 6662 || dd.getItemId() == 8191 || dd.getItemId() == 6658 || dd.getItemId() == 6656 || dd.getItemId() == 6657 || dd.getItemId() == 6659 || dd.getItemId() >= 6360 && dd.getItemId() <= 6362 || dd.getItemId() >= 8723 && dd.getItemId() <= 8762) { // if epic jewel, return just 1 from raid to_drop = true; } } if (!to_drop) { return null; } } // Get default drop chance for the category (that's the sum of chances for all items in the category) // keep track of the base category chance as it'll be used later, if an item is drop from the category. // for everything else, use the total "categoryDropChance" final int basecategoryDropChance = categoryDrops.getCategoryChance(); int categoryDropChance = basecategoryDropChance; int deepBlueDrop = 1; if (Config.DEEPBLUE_DROP_RULES) { if (levelModifier > 0) { // We should multiply by the server's drop rate, so we always get a low chance of drop for deep blue mobs. // NOTE: This is valid only for adena drops! Others drops will still obey server's rate deepBlueDrop = 3; } } if (deepBlueDrop == 0) { deepBlueDrop = 1; } // Check if we should apply our maths so deep blue mobs will not drop that easy if (Config.DEEPBLUE_DROP_RULES) { categoryDropChance = (categoryDropChance - categoryDropChance * levelModifier / 100) / deepBlueDrop; } // Applies Drop rates if (this instanceof L2RaidBossInstance) { categoryDropChance *= Config.ITEMS_RAID; } else if (this instanceof L2GrandBossInstance) { categoryDropChance *= Config.ITEMS_BOSS; } else if (this instanceof L2MinionInstance) { categoryDropChance *= Config.ITEMS_MINON; } else { categoryDropChance *= Config.RATE_DROP_ITEMS; } if (Config.L2JMOD_CHAMPION_ENABLE && isChampion()) { categoryDropChance *= Config.L2JMOD_CHAMPION_REWARDS; } // Set our limits for chance of drop if (categoryDropChance < 1) { categoryDropChance = 1; } // Check if an Item from this category must be dropped if (Rnd.get(L2DropData.MAX_CHANCE) < categoryDropChance) { L2DropData drop = categoryDrops.dropOne(isRaid()); if (drop == null) { return null; } // Now decide the quantity to drop based on the rates and penalties. To get this value // simply divide the modified categoryDropChance by the base category chance. This // results in a chance that will dictate the drops amounts: for each amount over 100 // that it is, it will give another chance to add to the min/max quantities. // // For example, If the final chance is 120%, then the item should drop between // its min and max one time, and then have 20% chance to drop again. If the final // chance is 330%, it will similarly give 3 times the min and max, and have a 30% // chance to give a 4th time. // At least 1 item will be dropped for sure. So the chance will be adjusted to 100% // if smaller. // int dropChance = drop.getChance(); int dropChance = 0; switch (drop.getItemId()) { case 6662: { // core ring if (Config.CORE_RING_CHANCE > 0) { dropChance = 10000 * Config.CORE_RING_CHANCE; } else { dropChance = drop.getChance(); } } break; case 6661: { // orfen earring if (Config.ORFEN_EARRING_CHANCE > 0) { dropChance = 10000 * Config.ORFEN_EARRING_CHANCE; } else { dropChance = drop.getChance(); } } break; case 6659: { // zaken earring if (Config.ZAKEN_EARRING_CHANCE > 0) { dropChance = 10000 * Config.ZAKEN_EARRING_CHANCE; } else { dropChance = drop.getChance(); } } break; case 6660: { // aq ring if (Config.QA_RING_CHANCE > 0) { dropChance = 10000 * Config.QA_RING_CHANCE; } else { dropChance = drop.getChance(); } } break; default: { dropChance = drop.getChance(); } } if (drop.getItemId() == 57) { if (this instanceof L2RaidBossInstance) { dropChance *= Config.ADENA_RAID; } else if (this instanceof L2GrandBossInstance) { dropChance *= Config.ADENA_BOSS; } else if (this instanceof L2MinionInstance) { dropChance *= Config.ADENA_MINON; } else { dropChance *= Config.RATE_DROP_ADENA; if (lastAttacker.isVIP()) { dropChance *= Config.VIP_ADENA_RATE; } } } else { if (this instanceof L2RaidBossInstance) { dropChance *= Config.ITEMS_RAID; } else if (this instanceof L2GrandBossInstance) { dropChance *= Config.ITEMS_BOSS; } else if (this instanceof L2MinionInstance) { dropChance *= Config.ITEMS_MINON; } else { dropChance *= Config.RATE_DROP_ITEMS; if (lastAttacker.isVIP()) { dropChance *= Config.VIP_DROP_RATE; } } } if (Config.L2JMOD_CHAMPION_ENABLE && isChampion()) { dropChance *= Config.L2JMOD_CHAMPION_REWARDS; } if (dropChance < L2DropData.MAX_CHANCE) { dropChance = L2DropData.MAX_CHANCE; } // Get min and max Item quantity that can be dropped in one time final int min = drop.getMinDrop(); final int max = drop.getMaxDrop(); // Get the item quantity dropped int itemCount = 0; if (!Config.MULTIPLY_QUANTITY_BY_CHANCE && dropChance > L2DropData.MAX_CHANCE && drop.getItemId() != 57) { dropChance = L2DropData.MAX_CHANCE; } // Count and chance adjustment for high rate servers if (dropChance > L2DropData.MAX_CHANCE && !Config.PRECISE_DROP_CALCULATION) { final int multiplier = dropChance / L2DropData.MAX_CHANCE; if (min < max) { itemCount += Rnd.get(min * multiplier, max * multiplier); } else if (min == max) { itemCount += min * multiplier; } else { itemCount += multiplier; } dropChance = dropChance % L2DropData.MAX_CHANCE; } // Check if the Item must be dropped final int random = Rnd.get(L2DropData.MAX_CHANCE); while (random < dropChance) { // Get the item quantity dropped if (min < max) { itemCount += Rnd.get(min, max); } else if (min == max) { itemCount += min; } else { itemCount++; } // Prepare for next iteration if dropChance > L2DropData.MAX_CHANCE dropChance -= L2DropData.MAX_CHANCE; } if (Config.L2JMOD_CHAMPION_ENABLE) { if ((drop.getItemId() == 57 || drop.getItemId() >= 6360 && drop.getItemId() <= 6362) && isChampion()) { itemCount *= Config.L2JMOD_CHAMPION_ADENAS_REWARDS; } } if (drop.getItemId() >= 6360 && drop.getItemId() <= 6362) { itemCount *= Config.RATE_DROP_SEAL_STONES; } if (itemCount > 0) { return new RewardItem(drop.getItemId(), itemCount); } else if (itemCount == 0 && Config.DEBUG) { LOGGER.debug("Roll produced 0 items to drop..."); } drop = null; } return null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private int checkItemQuantity() {\n\n int desiredQuantity = initialQuantity;\n MenusItem tempItem = null;\n tempItem = ItemCart.getInstance().checkItem(menusItem);\n\n if(tempItem != null){\n desiredQuantity = tempItem.getDesiredQuantity();\n }\n\n\n return desiredQuantity;\n }", "float getBonusItemDrop();", "private static void maxDuffelBagValue(JSONArray cakeTypes, int capacity) {\n for (int i = 0; i < cakeTypes.length(); i++) {\n \tJSONObject cakeType = (JSONObject) cakeTypes.remove(i);\n \tif (cakeType.getInt(\"weight\") <= capacity) {\n \t\tval += cakeType.getInt(\"value\");\n \t\tcapacity -= cakeType.getInt(\"weight\");\n \t\tmaxDuffelBagValue(cakeTypes, capacity);\n\t\t\t}\n }\n\t}", "private int calculateInputStock_Items() {\n\t\tint total = 0;\n\t\tArrayList<Integer> stock = getAllStockValues();\n\t\tif (!stock.isEmpty()) {\n\t\t\t// get for all K\n\t\t\ttotal += (stock.get(0) * getSetUpMachine().getVending_item().get(\"K\"));\n\t\t\t// get for all S\n\t\t\ttotal += (stock.get(1) * getSetUpMachine().getVending_item().get(\"S\"));\n\t\t\t// get for all F\n\t\t\ttotal += (stock.get(2) * getSetUpMachine().getVending_item().get(\"F\"));\n\t\t\t// get for all N\n\t\t\ttotal += (stock.get(3) * getSetUpMachine().getVending_item().get(\"N\"));\n\t\t}\n\t\treturn total;\n\t}", "protected Item check_Drops(Character c) {\n for (Item item : c.getBag()) {\n if (item.isDropable()) {\n return item;\n }\n }\n return null;\n }", "public BigDecimal getMaxQuantity() {\n return _maxQuantity;\n }", "int getSellQuantity();", "Integer getNumberOfProducts(Basket basket, Category category);", "private int calculateLevelModifierForDrop(final L2PcInstance lastAttacker)\n\t{\n\t\tif (Config.DEEPBLUE_DROP_RULES)\n\t\t{\n\t\t\tint highestLevel = lastAttacker.getLevel();\n\t\t\t\n\t\t\t// Check to prevent very high level player to nearly kill mob and let low level player do the last hit.\n\t\t\tif (getAttackByList() != null && !getAttackByList().isEmpty())\n\t\t\t{\n\t\t\t\tfor (final L2Character atkChar : getAttackByList())\n\t\t\t\t{\n\t\t\t\t\tif (atkChar != null && atkChar.getLevel() > highestLevel)\n\t\t\t\t\t{\n\t\t\t\t\t\thighestLevel = atkChar.getLevel();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// According to official data (Prima), deep blue mobs are 9 or more levels below players\n\t\t\tif (highestLevel - 9 >= getLevel())\n\t\t\t{\n\t\t\t\treturn (highestLevel - (getLevel() + 8)) * 9;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn 0;\n\t}", "boolean hasBonusItemDrop();", "public int quantityDropped(Random par1Random)\n {\n return dropItemQty;\n }", "public int quantityDropped(Random p_149745_1_)\n {\n return this.isFullBlock ? 2 : 1;\n }", "public int howMany(int temp) {\n // initial quantity is 0\n int totalQuantity = 0;\n // for each item\n for (int i = 0; i < this._noOfItems; i++) {\n FoodItem currentItem = this._stock[i];\n // if refridgerator temperature is in the item's valid temperature range\n if (temp >= currentItem.getMinTemperature() &&\n temp <= currentItem.getMaxTemperature()) {\n // sum the quantity of the item with previous quantitys sum\n totalQuantity += currentItem.getQuantity();\n }\n }\n // and return the total quantity\n return totalQuantity;\n }", "private String validateQuantityAmountNumPromotionShop(List<PromotionShopMap> lstCurrentPromotionShopMap, List<PromotionShopMap> lstNewPromotionShopMap) {\n\t\tint size = lstCurrentPromotionShopMap.size();\n\t\tint allocateQuantity = 0;\n\t\tint allocateAmount = 0;\n\t\tint allocateNum = 0;\n\t\tfor (int i = 0; i < size; i++) {\n\t\t\tPromotionShopMap psm = lstCurrentPromotionShopMap.get(i);\n\t\t\tif (psm.getQuantityMax() != null) {\n\t\t\t\tallocateQuantity++;\n\t\t\t}\n\t\t\tif (psm.getAmountMax() != null) {\n\t\t\t\tallocateAmount++;\n\t\t\t}\n\t\t\tif (psm.getNumMax() != null) {\n\t\t\t\tallocateNum++;\n\t\t\t}\n\t\t}\n\t\tfor (int j = 0, n = lstNewPromotionShopMap.size(); j < n; j++) {\n\t\t\tPromotionShopMap promotionShopMap = lstNewPromotionShopMap.get(j);\n\t\t\tString shopName = promotionShopMap.getShop() == null ? \"\" : (promotionShopMap.getShop().getShopCode() + \" - \" + promotionShopMap.getShop().getShopName());\n\t\t\tif (promotionShopMap.getQuantityMax() != null && allocateQuantity == 0) {\n\t\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.denied.allcate.quantity\", shopName);\n\t\t\t}\n\t\t\tif (promotionShopMap.getQuantityMax() == null && allocateQuantity > 0) {\n\t\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allcate.quantity\", shopName);\n\t\t\t}\n\t\t\tif (promotionShopMap.getAmountMax() != null && allocateAmount == 0) {\n\t\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.denied.allcate.amount\", shopName);\n\t\t\t}\n\t\t\tif (promotionShopMap.getAmountMax() == null && allocateAmount > 0) {\n\t\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allcate.amount\", shopName);\n\t\t\t}\n\t\t\tif (promotionShopMap.getNumMax() != null && allocateNum == 0) {\n\t\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.denied.allcate.num\", shopName);\n\t\t\t}\n\t\t\tif (promotionShopMap.getNumMax() == null && allocateNum > 0) {\n\t\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allcate.num\", shopName);\n\t\t\t}\n\t\t}\n\t\treturn \"\";\n\t}", "public int getMaxItemUseDuration(ItemStack var1)\r\n {\r\n return 72000;\r\n }", "public Knapsack bruteForceCalc (ArrayList <Item> items,int capacity, int num_items) {\n\t\tif (num_items <= 0) {\n\t\t\tKnapsack knapsack = new Knapsack(0);\n\t\t\treturn knapsack;\n\t\t} \n\t\telse if (items.get(num_items -1).getWeight() > capacity) {\n\t\t\treturn bruteForceCalc(items, capacity, num_items - 1);\n\t\t} else {\n\n\t\t\tKnapsack ignore = bruteForceCalc(items,capacity, num_items - 1);\n\t\t\tKnapsack take = bruteForceCalc(items,capacity - items.get(num_items -1).getWeight(), num_items - 1);\n\t\t\t\n\t\t\tint ignoreVal = ignore.getValue();\n\t\t\tint takeVal = items.get(num_items - 1).getValue() + take.getValue();\n\t\t\t \n\t\t\tif( Math.max(ignoreVal, takeVal) == ignoreVal ) \n\t\t\t\treturn ignore;\n\t\t\telse {\n\t\t\t\ttake.addItem(items.get(num_items - 1));\n\t\t\t\treturn take;\n\t\t\t}\n\t\t}\n\t}", "@Override\n\tpublic java.lang.String getNeedQuantity() {\n\t\treturn _lineaGastoCategoria.getNeedQuantity();\n\t}", "@Override\n public int getMaxEfficiency(ItemStack itemStack) {\n return 10000;\n }", "@Override\n public int quantityDroppedWithBonus(int fortune, Random random)\n {\n if (fortune > 0 && Item.getItemFromBlock(this) != this.getItemDropped(this.getBlockState().getValidStates().iterator().next(), random, fortune))\n {\n int i = random.nextInt(fortune + 2) - 1;\n\n if (i < 0)\n {\n i = 0;\n }\n\n return this.quantityDropped(random) * (i + 1);\n }\n else\n {\n return this.quantityDropped(random);\n }\n }", "public boolean canDrop(){\n return this.collectedItems < STORAGE_AMOUNT && System.currentTimeMillis() - lastDrop >= delayInMillis;\n }", "public int getCyclopsDrop(Client c) {\r\n\t\tif(!c.kamfreenaDone)\r\n\t\t\treturn Integer.parseInt(DEFENDER[7][0]);\r\n\t\tfor(int i = 0; i < DEFENDER.length; i++) {\r\n\t\t\ttry {\r\n\t\t\t\tif(hasItem(c, Integer.parseInt(DEFENDER[i][0]), false))\r\n\t\t\t\t\treturn Integer.parseInt(DEFENDER[i - 1][0]);\r\n\t\t\t} catch(Exception e) {\r\n\t\t\t\treturn Integer.parseInt(DEFENDER[0][0]);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn Integer.parseInt(DEFENDER[7][0]);\r\n\t}", "@Override\n public int getMaxItemUseDuration(ItemStack par1ItemStack) {\n return 10;\n }", "public static TempResult max(int allowedWeight, Set<Item> items) {\n\t\tint[] values=new int[items.size()];\n\t\tint[] weights=new int[items.size()];\n\t\t\n\n\t\tArrayList<Item> items2=new ArrayList<Item>(items);\n\t\tfor (int i=0; i<items2.size(); i++) {\n\t\t\tvalues[i]=items2.get(i).value;\n\t\t\tweights[i]=items2.get(i).weight;\n\t\t}\n\t\t\n int[][] totalValue = new int[values.length+1][allowedWeight+1];\n boolean[][] includedorNot = new boolean[values.length+1][allowedWeight+1];\n \n //We introduce item one by one to the system.\n //For each introduced item, we consider the maximal profit\n //for weight=[0:allowedWeight]\n for (int i=0; i<values.length; i++) {\n \t//introduce item i into the system.\n \tint val=values[i];\n \tint weight=weights[i];\n \t\n \tint itemIndex=i+1;\n \t\n \tfor (int w=1; w<=allowedWeight; w++) {\n \t\t\n \t\t//Zero copy of ith item; i-1 is calculated already\n \t\tint profit1=totalValue[itemIndex-1][w];\n \t\t\n \t\t//one copy of ith item.\n \t\tint profit2=Integer.MIN_VALUE;\n \t\tif (w-weight>=0) {\n \t\t\t//for a particular targeted weight, add item i does not overflow the targeted weight.\n \t\t\tprofit2=totalValue[itemIndex-1][w-weight]+val;\n \t\t}\n \t\t\n \t\tif (profit1>profit2) {\n \t\t\tincludedorNot[itemIndex][w]=false;\n \t\t\ttotalValue[itemIndex][w]=profit1;\n \t\t} else {\n \t\t\tincludedorNot[itemIndex][w]=true;\n \t\t\ttotalValue[itemIndex][w]=profit2;\n \t\t}\n \t}\n }\n\t\t\n \n TempResult result=new TempResult(0, 0);\n result.value=totalValue[values.length][allowedWeight];\n result.items=new LinkedList<>();\n int w=allowedWeight;\n for (int itemIndex=values.length; itemIndex>0; itemIndex--) {\n \tif (includedorNot[itemIndex][w]) {\n \t\tresult.items.add(items2.get(itemIndex-1));\n \t\tw=w-weights[itemIndex-1];\n \t} \n }\n \n return result;\n \n\t}", "public int getFoodConsumption() {\n return getConsumptionOf(getSpecification().getFoodGoodsTypeList());\n }", "public float getBonusItemDrop() {\n return bonusItemDrop_;\n }", "public double getDropAmount() {\n return dropAmount;\n }", "public float getBonusItemDrop() {\n return bonusItemDrop_;\n }", "protected int getNuggetValue(ItemStack food) {\n if (food == null) {\n return 0;\n } else if (food.getType() == Material.GOLDEN_CARROT) {\n return 8;\n } else if (food.getType() == Material.GOLDEN_APPLE) {\n return 8 * 9;\n } else if (food.getType() == Material.ENCHANTED_GOLDEN_APPLE) {\n return 8 * 9 * 9;\n } else {\n return 0;\n }\n }", "protected void dropFood() {\r\n\t\tthis.food++;\r\n\t}", "private String validateQuantityAmountNumPromotionShop(List<PromotionShopMap> lstPromotionShopMap) {\n\t\tint size = lstPromotionShopMap.size();\n\t\tint ALL_ALLOCATE = size;\n\t\tint NO_ALLOCATE = 0;\n\t\tint allocateQuantity = 0;\n\t\tint allocateAmount = 0;\n\t\tint allocateNum = 0;\n\t\tfor (int i = 0; i < size; i++) {\n\t\t\tPromotionShopMap psm = lstPromotionShopMap.get(i);\n\t\t\tif (psm.getQuantityMax() != null) {\n\t\t\t\tallocateQuantity++;\n\t\t\t}\n\t\t\tif (psm.getAmountMax() != null) {\n\t\t\t\tallocateAmount++;\n\t\t\t}\n\t\t\tif (psm.getNumMax() != null) {\n\t\t\t\tallocateNum++;\n\t\t\t}\n\t\t}\n\t\t// neu co phan bo thi phai phan bo tat ca cac dong\n\t\tif (NO_ALLOCATE < allocateQuantity && allocateQuantity < ALL_ALLOCATE) {\n\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allcate.all.quantity\");\n\t\t}\n\t\tif (NO_ALLOCATE < allocateAmount && allocateAmount < ALL_ALLOCATE) {\n\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allcate.all.amount\");\n\t\t}\n\t\tif (NO_ALLOCATE < allocateNum && allocateNum < ALL_ALLOCATE) {\n\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allcate.all.num\");\n\t\t}\n\t\t// phai phan bo it nhat 1 loai (so suat/so tien/so luong)\n\t\tif (allocateQuantity == NO_ALLOCATE && allocateAmount == NO_ALLOCATE && allocateNum == NO_ALLOCATE) {\n\t\t\treturn Configuration.getResourceString(ConstantManager.VI_LANGUAGE, \"promotion.program.shop.no.allocate.all\");\n\t\t}\n\t\treturn \"\";\n\t}", "public int quantityDroppedWithBonus(int var1, Random var2)\r\n {\r\n if (var1 > 0 && this.blockID != this.idDropped(0, var2, var1))\r\n {\r\n int var3 = var2.nextInt(var1 + 2) - 1;\r\n\r\n if (var3 < 0)\r\n {\r\n var3 = 0;\r\n }\r\n\r\n return this.quantityDropped(var2) * (var3 + 1);\r\n }\r\n else\r\n {\r\n return this.quantityDropped(var2);\r\n }\r\n }", "private void dropAllDrops(ItemStack drop, int amount, Location dropLocation, boolean addEnchantment){\n double inStacks = (double) amount / (double) drop.getMaxStackSize();\n double floor = Math.floor(inStacks);\n double leftOver = inStacks - floor;\n for(int i = 1; i <= floor; i++){\n ItemStack newStack = drop.clone();\n newStack.setAmount(drop.getMaxStackSize());\n if(addEnchantment){\n newStack.addUnsafeEnchantment(Enchantment.DIG_SPEED, 1);\n }\n dropLocation.getWorld().dropItemNaturally(dropLocation, newStack);\n }\n if(leftOver > 0){\n ItemStack newStack = drop.clone();\n newStack.setAmount((int) Math.round(leftOver * drop.getMaxStackSize()));\n if(addEnchantment){\n newStack.addUnsafeEnchantment(Enchantment.DIG_SPEED, 1);\n }\n dropLocation.getWorld().dropItemNaturally(dropLocation, newStack);\n }\n }", "public int getMaxTotalCost();", "public String getCountDescription() {\n StringBuilder s = new StringBuilder();\n if (_dropType == DropType.ITEM || _dropType == DropType.MOB) {\n if (_min == _max) {\n s.append(_min);\n } else {\n s.append('[').append(_min).append(',').append(_max).append(']');\n }\n s.append(' ');\n }\n return s.toString();\n }", "static int knapsack(Item[] items, int maxWeight) {\n return knapsack(items, maxWeight, 0);\n }", "public float getSubtotal()\n {\n if ( donutTypeComboBox.getSelectionModel().isEmpty() || flavorComboBox.getSelectionModel().isEmpty() )\n {\n return -1f;\n } else\n {\n Donut donut = new Donut(donutTypeComboBox.getSelectionModel().getSelectedIndex(), flavorComboBox.getSelectionModel().getSelectedIndex());\n Float quantity = Float.parseFloat(quantityTextField.getText());\n\n\n return (donut.getItemPrice() * quantity);\n }\n }", "BigDecimal getQuantity();", "int getMaxAir(ItemStack stack);", "@Override\n public int summarizeQuantity() {\n int sum = 0;\n\n for ( AbstractItem element : this.getComponents() ) {\n sum += element.summarizeQuantity();\n }\n\n return sum;\n }", "public int dropPotion() {\r\n\t\t// If the random number generated is larger than the \r\n\t\t// drop chance, at least one health potion is dropped\r\n\t\tif (rnd.nextInt(100) < HEALTH_POTION_DROP_CHANCE) {\r\n\t\t\treturn rnd.nextInt(MAX_NO_HEALTH_POTION_DROP) + 1;\r\n\t\t}\r\n\t\t// no health potions dropped\r\n\t\treturn 0;\r\n\t}", "int getBuyQuantity();", "private int countProductsInCart_UPDATED() {\n System.out.println(\"-=====================Shopping Cart List========================================-\");\n int count, value;\n count = 0;\n List<WebElement> cakes = getDriver().findElements(By.xpath(\"//*[text()='Edit Your Cake']\"));\n List<WebElement> sthAndCnC = getDriver().findElements(By.xpath(\"//*[starts-with(@id, 'basketBody_') and @type='number']\"));\n System.out.println(\" === adding \" + cakes.size() + \" cakes to count\");\n count += cakes.size();\n for (WebElement product : sthAndCnC) {\n if ((!product.getAttribute(\"value\").equals(\"\")) && (product.getAttribute(\"value\") != null)) {\n String checkForLB = product.getAttribute(\"data-qtyincrement\");\n if (checkForLB.contains(\"0.\")) { //To validate for LB(s) items\n value = 1;\n } else {\n value = Integer.valueOf(product.getAttribute(\"value\"));\n }\n System.out.println(\"=== adding \" + value + \" cnc or sth item to cart\");\n count += value;\n } else {\n System.out.println(\"=== error adding product quantity\");\n }\n }\n System.out.println(\" === Count was: \" + count);\n System.out.println(\"-=====================Shopping Cart List========================================-\");\n return count;\n }", "public int getMaxItems()\n {\n return maxItems;\n }", "public double getFoodQuantity() {\r\n\t\treturn fruitQuantity + meatQuantity;\r\n\t}", "long getMaxItemFindings();", "Integer checkCategory(Integer choice, \n List<DvdCategory> categories) throws DvdStoreException;", "@Override\n\tpublic void removeIngredientQuantity(Ingredient ingredient, Integer removedValue){\n\t\tInteger newValue = getInventoryForAIngredient(ingredient) - removedValue;\n\t\tbeverageInventoryMap.put(ingredient, newValue);\n\t\tif(newValue<Constants.CRITICAL_LIMIT){\n\t\t\tSystem.out.println(String.format(Messages.INGREDIENT_RUNNING_LOW, ingredient.getDisplayName()));\n\t\t}\n\t}", "public int quantityDropped(Random var1)\r\n {\r\n return this.blockID != mod_XaedCraft.oreCopper.blockID && this.blockID != mod_XaedCraft.oreTin.blockID && this.blockID != mod_XaedCraft.oreBrimstone.blockID ? (this.blockID == mod_XaedCraft.oreRune.blockID ? 3 + var1.nextInt(4) : 1) : 1 + var1.nextInt(4);\r\n }", "private void minusQuantity(TextField source, Clothing clothing) {\n clothing.setCount(-1);\n int quantity = clothing.getCount();\n double totalPriceOfClothing = 0;\n\n for (int i = 0; i < clothingArrayList.size(); i++) {\n double countOfItems = clothingArrayList.get(i).getCount();\n double clothingPricePerUnit = Double.valueOf(clothingArrayList.get(i).getPrice());\n totalPriceOfClothing += clothingPricePerUnit * countOfItems;\n\n }\n source.setText(\"\" + (quantity));\n totalPrices.setText(\"\" + totalPriceOfClothing );\n\n }", "protected abstract long getAmount(ItemVariant currentVariant);", "public int adjustForCrowding() {\n int deadGuppyCount = 0;\n\n Collections.sort(this.guppiesInPool, new Comparator<Guppy>() {\n @Override\n public int compare(Guppy g1, Guppy g2) {\n return Double.compare(g1.getHealthCoefficient(), g2.getHealthCoefficient());\n }\n });\n\n Guppy weakestGuppy;\n Iterator<Guppy> it = guppiesInPool.iterator();\n double volumeNeeded = this.getGuppyVolumeRequirementInLitres();\n\n while (it.hasNext() && volumeNeeded > this.getVolumeLitres()) {\n weakestGuppy = it.next();\n volumeNeeded -= (weakestGuppy.getVolumeNeeded() / ML_TO_L_CONVERSION);\n\n weakestGuppy.setIsAlive(false);\n\n\n deadGuppyCount++;\n\n }\n return deadGuppyCount;\n }", "MeasureType getQuantity();", "public int quantityDropped(int meta, int fortune, Random par1Random) {\n\t\tRandom rnd = new Random();\n\t\tfortune = fortune+1;\n\t\tint i = rnd.nextInt(3) + 1;\n\t\tint fortrand = par1Random.nextInt(fortune);\n\t\tfortrand = fortrand * (rnd.nextInt(3)+1);\n\t\ti = i + fortrand;\n\t\tSystem.out.println(\"fortune: \" + (fortune - 1));\n\t\tSystem.out.println(i);\n\n\t\treturn i;\n\t}", "private boolean checkStock(){\n int i;\n int inventorySize = inventory.size();\n int count = 0;\n for(i = 0; i < inventorySize; i++){\n count = count + inventory.get(i).getStock();\n\n }\n //System.out.println(\"Count was: \" + count);\n if(count < 1){\n return false;\n }else{\n return true;\n }\n }", "default int countItems(Predicate<ItemStack> filter) {\n return streamStacks().filter(filter).mapToInt(InvTools::sizeOf).sum();\n }", "@Override\n public int quantityDropped(int meta, int fortune, Random random)\n {\n return super.quantityDropped(meta, fortune, random);\n }", "public static int calculateDiscount(ItemType type, int quantity) {\n int discount = 0;\n switch (type) {\n case NEW:\n return 0;\n case SECOND_FREE:\n if (quantity > 1)\n discount = 50;\n break;\n case SALE:\n discount = 70;\n break;\n }\n discount += quantity / 10;\n if (discount > 80)\n discount = 80;\n return discount;\n }", "int getQuantity();", "public int quantityDropped(Random var1)\n {\n return 1;\n }", "public static int calculateTotal(SQLiteDatabase db){\n // Retrieve only items with positive quantity\n Cursor c = db.query(StoreItems.TABLE_NAME, new String[] {StoreItems._ID, StoreItems.COLUMN_NAME_PRICE, StoreItems.COLUMN_NAME_QUANTITY}, StoreItems.COLUMN_NAME_QUANTITY + \">0\", null, null, null, null);\n \n // Add all items to total\n c.moveToFirst();\n int sum = 0;\n while(!c.isAfterLast())\n {\n sum += c.getInt(c.getColumnIndex(StoreItems.COLUMN_NAME_QUANTITY)) * c.getInt(c.getColumnIndex(StoreItems.COLUMN_NAME_PRICE));\n c.moveToNext();\n }\n return sum;\n }", "public void setMaxTotalCost(int amount);", "public int getMaximumCategoryCount() { return this.maximumCategoryCount; }", "private int validateMaxValue(int maxValue) {\n\t\tif (!(maxValue >= 1)) {\n\t\t\tthrow new IllegalArgumentException(\n\t\t\t\t\t\"DawsonBallotItem Error - maxValue must be geater or equal to 1. Invalid value = \" + maxValue);\n\t\t}\n\t\treturn maxValue;\n\t}", "public void rollCombatDrop() {\n\t\tRandom r=new Random();\n\t\t\n\t\tint x=r.nextInt(3);\n\t\tItem i=combatDrops.get(x);\n\t\taddItem(i.getName());\n\t\t\n\t\tevents.appendText(\"You find an \"+i.getName()+\" after defeating the \"+e.getName()+\"!\\n\"); // Infrom player\n\t}", "public int insertItem(Item items, String category, Connection conn) {\r\n\t\ttry {\r\n\t\t\tPreparedStatement pstmt = conn.prepareStatement(\"insert into item_XXXX values(?,?,?,?,?)\");\r\n\t\t\tpstmt.setInt(1, items.getItemNo());\r\n\t\t\tpstmt.setString(2, items.getDescription());\r\n\t\t\tpstmt.setString(3, items.getCategory().toString());\r\n\t\t\tpstmt.setDouble(4, items.getPrice());\r\n\t\t\tpstmt.setInt(5, items.getQuantity());\r\n\t\t\tint count = pstmt.executeUpdate();\r\n\t\t\treturn count;\r\n\t\t} catch (SQLException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\treturn 0;\r\n\t}", "BigDecimal getOriginalQuantity();", "public int quantityDropped(Random par1Random)\n {\n return 1;\n }", "long getQuantity();", "long getQuantity();", "public int howManyAvailable(Item i){/*NOT IMPLEMENTED*/return 0;}", "public static Data<String> weaponMunitionQuantity(){\n\t\tData<String> res = new Data<String>();\n\t\tres.add(new Tuple<String, Integer>(\"2d10\", 10));\n\t\tres.add(new Tuple<String, Integer>(\"4d10\", 10));\n\t\tres.add(new Tuple<String, Integer>(\"1\", 60));\n\t\tres.add(new Tuple<String, Integer>(\"2d10\", 10));\n\t\tres.add(new Tuple<String, Integer>(\"4d10\", 10));\n\t\t\n\t\treturn res;\n\t}", "public int adjustQuantitiesInDB(Ingredient ingredient, int givenQuantity)throws SQLException{ //adds a current type of ingredient to database takes in quantity and ingredient object \r\n\t\tint newQuantity;\r\n\t\tString requiredIngredientName = ingredient.getName();\r\n\t\tString sqlUpdate = \"update stock_ingredients set quantity = quantity + \" + givenQuantity + \" where name = \" + \"'\" + requiredIngredientName + \"'\";\r\n\t\t\t\r\n\t\t//find correct syntax for increasing the quantity by x amount\r\n\r\n\t\tConnection connection = connectToDB(databaseUser, databasePass);\r\n\r\n\t\tPreparedStatement ps = connection.prepareStatement(sqlUpdate);\r\n\r\n\t\tps.executeUpdate();\r\n\r\n\t\tnewQuantity = checkCurrentStockLevels(ingredient);\r\n\r\n\t\tconnection.close();\r\n\t\t\r\n\t\treturn newQuantity;\r\n\r\n\t}", "public int quantityDropped(Random random) {\n return 0;\n }", "private synchronized int determineLastSaleQuantity(HashMap<String, FillMessage> fills) throws InvalidDataException {\n\t\tif (fills == null) throw new InvalidDataException(\"Fills cannot be null.\");\n\t\tArrayList<FillMessage> msgs = new ArrayList<FillMessage>(fills.values()); \n\t\t//Collections.sort(msgs);\n\t\tCollections.sort(msgs);\n\t\tCollections.reverse(msgs);\n\t\treturn msgs.get(0).getVolume();\n\t}", "public boolean canReceiveItem(Player character) {\n boolean canPick = true;\n Item item = character.items.get(character.getItemOwned2().getName());\n double totalWeight = items.getTotalWeight() + item.getWeight();\n if(totalWeight > maxWeight) {\n canPick = false;\n }\n return canPick; \n }", "@Override\r\n public int getItemQuantity() {\n return this.quantity;\r\n }", "default int getMaxCountThatPassesFilter(@Nullable IItemHandler inv, @Nonnull ItemStack item) {\n return doesItemPassFilter(inv, item) ? Integer.MAX_VALUE : -1;\n }", "public int getItemQty() {\n return itemQty;\n }", "public float valorTotalItem()\r\n {\r\n float total = (produto.getValor() - (produto.getValor() * desconto)) * quantidade;\r\n return total;\r\n }", "@SuppressWarnings(\"RedundantCast\")\n private static double calculateFoodPotential(AltoClef mod) {\n double potentialFood = 0;\n for (ItemStack food : mod.getItemStorage().getItemStacksPlayerInventory(true)) {\n potentialFood += getFoodPotential(food);\n }\n int potentialBread = (int) (mod.getItemStorage().getItemCount(Items.WHEAT) / 3) + mod.getItemStorage().getItemCount(Items.HAY_BLOCK) * 3;\n potentialFood += Objects.requireNonNull(Items.BREAD.getFoodComponent()).getHunger() * potentialBread;\n // Check smelting\n ScreenHandler screen = mod.getPlayer().currentScreenHandler;\n if (screen instanceof SmokerScreenHandler) {\n potentialFood += getFoodPotential(StorageHelper.getItemStackInSlot(SmokerSlot.INPUT_SLOT_MATERIALS));\n potentialFood += getFoodPotential(StorageHelper.getItemStackInSlot(SmokerSlot.OUTPUT_SLOT));\n }\n return potentialFood;\n }", "public void limitSelectedCodes(CodProducto chkCod) {\n\t\tif(chkCod.isTransferido()) {\n\t\t\tArrayList<CodProducto> codsProds = lstCodsProductos.get(selectedItem.getInventario().getProducto().getReferencia());\n\t\t\tint cntChecked = 0;\n\t\t\tfor(CodProducto tmpCod : codsProds) \n\t\t\t\tcntChecked+=tmpCod.isTransferido()?1:0;\n\t\t\t\n\t\t\tif(cntChecked > selectedItem.getCantidad())\n\t\t\t\tchkCod.setTransferido(false);\n\t\t\telse\n\t\t\t\tcodigosRestantes++;\n\t\t} else\n\t\t\tcodigosRestantes--;\n\t}", "public Long getMaximumquantity() {\r\n return maximumquantity;\r\n }", "public int getNewItemCount(Item catalogItem) {\n int count = 0;\n for (Item item : newItemsToAdd) {\n if (item.getDerivedFromItem() == catalogItem) {\n count++;\n }\n }\n if (getCurrent().getDerivedFromItem() == catalogItem) {\n count++;\n }\n return count;\n }", "public int quantityDropped(Random random)\r\n {\r\n return 0;\r\n }", "boolean hasProductBiddingCategoryConstant();", "public Integer getMaxItems() {\n\t\treturn maxItems;\n\t}", "public int inventorySize (TheGroceryStore g);", "protected static boolean canAccomodateItemDrop(Block block) {\n return block.isPassable() || Util.isNotFullBlock(block.getType());\n }", "public int getAddItems(int totalCollected, int totalItemInGame);", "public int getremainingstock(String selection,String item) throws SQLException\n {\n // int stock_rate[]= new int [2];\n PreparedStatement remaining_stock = conn.prepareStatement(\"Select stock from purchases where Categroy=? and Item=? \");\n remaining_stock.setString(1, selection);\n remaining_stock.setString(2, item);\n ResultSet remaining_stock_rows = remaining_stock.executeQuery(); \n \n int sum=0,current=0;\n while(remaining_stock_rows.next()) \n {\n sum=Integer.parseInt(remaining_stock_rows.getString(1));\n \n \n }\n return sum;\n }", "public int maxDistinction() {\n\n int distinctTiles = this.distincts().size(); // # of unique Scrabble tiles\n int maxDistinction = distinctTiles; // maximum # of distinct possibilities\n\n // If there are wildcards...\n int wilds = this.count(WILDCARD);\n if (wilds > 0) {\n int uniqueHardLetters = distinctTiles - 1; // # of unique letters (w/o wildcards)\n maxDistinction = uniqueHardLetters + wilds; // REVISED MAXIMUM DISTINCTION\n }\n\n return maxDistinction;\n }", "public int cantidadCartas(int type);", "private void condenseShoppingCart()\n {\n for(int d = 0; d < PersistentData.ArryShoppingCartItemNo.size(); d++)\n {\n int numberofItems = 0;\n\n boolean itemNoAlreadyCondensed = false;\n if(CondensedShoppingCart.contains(PersistentData.ArryShoppingCartItemNo.get(d)))\n {\n itemNoAlreadyCondensed = true;\n }\n if(itemNoAlreadyCondensed == false)\n {\n for(int y = 0; y < PersistentData.ArryShoppingCartItemNo.size(); y++)\n {\n if(PersistentData.ArryShoppingCartItemNo.get(d) == PersistentData.ArryShoppingCartItemNo.get(y))\n {\n numberofItems++;\n }\n }\n CondensedShoppingCart.add(PersistentData.ArryShoppingCartItemNo.get(d));\n ShoppingCartItemQuantities.add(numberofItems);\n }\n }\n }", "public Integer getQuantity();", "public Boolean canAddItem(ItemStack item, Player player){\n\t\tint freeSpace = 0;\n\t\tfor(ItemStack i : player.getInventory() ){\n\t\t\tif(i == null){\n\t\t\t\tfreeSpace += item.getType().getMaxStackSize();\n\t\t\t} else if (i.getType() == item.getType() ){\n\t\t\t\tfreeSpace += (i.getType().getMaxStackSize() - i.getAmount());\n\t\t\t}\n\t\t}\n\t\tdebugOut(\"Item has: \"+item.getAmount()+\" and freeSpace is: \"+freeSpace);\n\t\tif(item.getAmount() > freeSpace){\n\t\t\tdebugOut(\"There is not enough freeSpace in the inventory\");\n\t\t\treturn false;\n\t\t}else{\n\t\t\tdebugOut(\"There is enough freeSpace in the inventory\");\n\t\t\treturn true;\n\t\t}\n\t}", "@Override\n\tpublic int getBuyQty(Stock2 s, ICashAccount ac) {\n double useableMny = 0;\n int buyMnt = 0;\n int maxMnt = 0;\n \n Map<String, StockBuySellEntry> lstTrades = TradeStrategyImp.getLstTradeForStocks();\n StockBuySellEntry sbs = lstTrades.get(s.getID());\n\t if (sbs != null && !sbs.is_buy_point)\n\t {\n\t \tbuyMnt = sbs.quantity;\n\t \tlog.info(\"stock:\" + s.getID() + \" with qty:\" + sbs.quantity + \" already, buy same back\");\n\t }\n\t else if (ac != null) {\n useableMny = ac.getMaxMnyForTrade();\n maxMnt = (int)(useableMny/s.getCur_pri()) / 100 * 100;\n \n \tbuyMnt = maxMnt;\n log.info(\"getBuyQty, useableMny:\" + useableMny + \" buyMnt:\" + buyMnt + \" maxMnt:\" + maxMnt);\n }\n\t\treturn buyMnt;\n\t}", "@Test\n public void amountGreatherThanItemsPrice() {\n Coupon coupon = couponService.calculateCoupon(Arrays.asList(MLA1),PRICE_MLA1+PRICE_MLA2);\n assertEquals(1, coupon.itemsIds().size());\n assertEquals(MLA1, coupon.itemsIds().get(0));\n assertEquals(PRICE_MLA1, coupon.total());\n }", "protected boolean checkDurability(ItemStack heldItem, String blockLocationFormat) {\n int leftDurability = calcLeftDurability(heldItem);\n\n // If the user did something bad here,\n // like destroying the configuration (by entereing non numeric values into the field etc.)\n // the value of \"minimum-durability\" will be (int)0. therefore it must be corrupt?!\n // Set it back to a reasonable number\n if (f.getInt(\"minimum-durability\") == 0) {\n f.set(\"minimum-durability\", this.plugin.getConfig().getInt(\"minimum-durability\"));\n }\n\n if (heldItem.getDurability() > 0\n && f.getInt(\"minimum-durability\") >= heldItem.getType().getMaxDurability() - heldItem.getDurability()\n && !xyzBlock.contains(blockLocationFormat)) {\n String s = String.format(ChatColor.RED + \"[WARNING]: %s has too little duration left!\\nDuration left: %d\\n\", WordUtils.capitalize(heldItem.getType().toString().toLowerCase().replace(\"_\", \" \")), leftDurability);\n p.sendMessage(s);\n return true;\n } /*else { //TODO ONLY FOR DEBUGGING\n Integer integerObject = new Integer(\"20\");\n short dura = (short) (max - integerObject.shortValue());\n heldItem.setDurability(dura);\n } */\n return false;\n }", "private void printDecreaseItemQuantityMenu(Shop shop, FileManager fileManager) {\n ArrayList<Tool> toolList = new ArrayList<Tool>();\n String selection = \"Y\";\n toolList = sellTools(shop, toolList, selection);\n createAutoOrder(shop, fileManager, toolList);\n }", "public void updateQuantity(DrinkItem temp, int val) throws SQLException{\n\t\t\n\t\tPreparedStatement myStmt = null;\n\t\ttry{\n\t\t\tmyStmt = myConn.prepareStatement(\"update drink set quantity=? where drink_code=?\");\n\t\t\tmyStmt.setInt(1, val);\n\t\t\tmyStmt.setInt(2, temp.getDrinkCode());\n\t\t\tmyStmt.executeUpdate();\n\t\t}\n\t\tfinally{\n\t\t\tif(myStmt != null)\n\t\t\t\tmyStmt.close();\n\t\t}\n\t\t\n\t}" ]
[ "0.59103185", "0.583256", "0.5490521", "0.54235584", "0.5349764", "0.5271871", "0.52295715", "0.5227547", "0.5173027", "0.5163563", "0.51481926", "0.5120615", "0.5120334", "0.5080378", "0.5071983", "0.50662047", "0.5065558", "0.5064843", "0.5043306", "0.50280845", "0.50057924", "0.49911514", "0.49888802", "0.498778", "0.49705988", "0.49646914", "0.49440396", "0.4942486", "0.49306506", "0.49266377", "0.48937368", "0.4880602", "0.4869773", "0.48663154", "0.48657557", "0.4850094", "0.4840789", "0.48342893", "0.48303193", "0.48292184", "0.4824464", "0.48146826", "0.4803893", "0.48017982", "0.4796363", "0.47838712", "0.4781729", "0.47800133", "0.47768438", "0.47755748", "0.4770112", "0.47679842", "0.4758931", "0.47557232", "0.4751043", "0.47509158", "0.47488496", "0.47435603", "0.4742118", "0.4717233", "0.4717082", "0.4714901", "0.47088742", "0.46998325", "0.4688601", "0.468667", "0.46834022", "0.46757442", "0.46757442", "0.46734685", "0.4672902", "0.46716863", "0.46664345", "0.46653065", "0.46651703", "0.46622065", "0.46583962", "0.46582595", "0.4656877", "0.46566513", "0.46545345", "0.46501395", "0.4649245", "0.46461517", "0.46439442", "0.4634871", "0.4632286", "0.46295112", "0.46277335", "0.46228874", "0.46216446", "0.46157593", "0.46124336", "0.46105954", "0.46085823", "0.46069616", "0.46023992", "0.45989892", "0.4590261", "0.45898765" ]
0.568675
2
Calculates the level modifier for drop
private int calculateLevelModifierForDrop(final L2PcInstance lastAttacker) { if (Config.DEEPBLUE_DROP_RULES) { int highestLevel = lastAttacker.getLevel(); // Check to prevent very high level player to nearly kill mob and let low level player do the last hit. if (getAttackByList() != null && !getAttackByList().isEmpty()) { for (final L2Character atkChar : getAttackByList()) { if (atkChar != null && atkChar.getLevel() > highestLevel) { highestLevel = atkChar.getLevel(); } } } // According to official data (Prima), deep blue mobs are 9 or more levels below players if (highestLevel - 9 >= getLevel()) { return (highestLevel - (getLevel() + 8)) * 9; } } return 0; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public double Getlevel()\r\n {\r\n return level;\r\n }", "double getLevel();", "double getLevel();", "private int getDodgeTime() {\n\t\treturn 10 - level;\n\t}", "@java.lang.Override\n public double getLevel() {\n return level_;\n }", "@java.lang.Override\n public double getLevel() {\n return level_;\n }", "@java.lang.Override\n public double getLevel() {\n return level_;\n }", "@java.lang.Override\n public double getLevel() {\n return level_;\n }", "protected int getLevel(){\r\n return this.level;\r\n }", "public double getLevel() {\n\t\treturn level;\n\t}", "private void setLevel(){\n\t\tif(getD(y) <= T)\n\t\t\tlevel = \"lower\";\n\t\telse\n\t\t\tlevel = \"higher\";\n\t}", "float getBonusItemDrop();", "public int getLevel()\r\n {\r\n return r_level;\r\n }", "int getLevel();", "int getLevel();", "int getLevel();", "int getLevel();", "int getLevel();", "public int getLevel(){\n return level;\n }", "public int getLevel(){\n return level;\n }", "public int getLevel()\r\n {\r\n return level;\r\n }", "public int getLevel(){\n return this.level;\n }", "public int getLevel(){\n return this.level;\n }", "public int getLevel()\n {\n return level; \n }", "public int getLevel() {\r\n return level;\r\n }", "public int capLevel() {\n\t\treturn 500 * this.niveau;\n\t}", "public double getDropAmount() {\n return dropAmount;\n }", "public int getLevel(){\n\t\treturn level;\n\t}", "public int getLevel()\n {\n return level;\n }", "public int getLevel() { \r\n\t\treturn level; \r\n\t}", "public int getLevel() {\n return level;\n }", "public int getLevel() {\n return level;\n }", "public int getLevel() {\n return level;\n }", "public int getLevel() {\n return level;\n }", "public int getLevel() {\n return level;\n }", "public int getLevel() {\n return level;\n }", "public int getLevel() {\n return level;\n }", "public int getLevel() {\n return level;\n }", "public int getLevel() {\n return level;\n }", "public int getLevel() {\n return level;\n }", "public int getLevel(){\n\t\treturn this.level;\n\t}", "public int getLevel() {\n return this.level;\n }", "public int getLevel()\n {\n return m_level;\n }", "public int getLevel() {\n \t\treturn level;\n \t}", "public int getLevel() {\n \treturn this.level;\n }", "public int getLevel() {\n return level_;\n }", "public int getLevel() {\n return level_;\n }", "public int getEnchantmentLevel() {\n/* 48 */ return this.enchantmentLevel;\n/* */ }", "int getLevel()\n\t{\n\t\treturn this.level;\n\t}", "@Override\n\tdouble updateLevel() {\n\t\treturn 0;\n\t}", "public static int getLevel()\n {\n return level;\n }", "public int level();", "public static int getLevel()\r\n\t{\r\n\t\treturn level;\r\n\t}", "private void gunModifier()\n\t{\t\t\n\t\tif (_gunModifier == 0)\n\t\t{\n\t\t\t_gunModifier = (_gunModifierSwivel * GameState._density);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tif (_gunModifier == _gunModifierSwivel * GameState._density)\n\t\t\t{\n\t\t\t\t_gunModifier = -1 * (_gunModifierSwivel* GameState._density);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tif (_gunModifier == -1 * (_gunModifierSwivel* GameState._density))\n\t\t\t\t{\n\t\t\t\t\t_gunModifier = 0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public int getLevel() {\r\n\t\treturn level;\r\n\t}", "public int getLevel() {\r\n\t\treturn level;\r\n\t}", "public Integer getLevel() {\n return level;\n }", "public Integer getLevel() {\n return level;\n }", "public Integer getLevel() {\n return level;\n }", "public Integer getLevel() {\n return level;\n }", "public Integer getLevel() {\n return level;\n }", "public static int getLevel() {\n return level;\n }", "public int getLevel() {\n\t\treturn 0;\n\t}", "public int getLevel() {\n\t\treturn 0;\n\t}", "public int getExpToLevel ( ) {\n\t\treturn extract ( handle -> handle.getExpToLevel ( ) );\n\t}", "public int getLevel() {\n\t\treturn level;\r\n\t}", "public int getLevel() {\n return level_;\n }", "public int getLevel() {\n return level_;\n }", "public String getLevel(){\n\t\treturn level;\n\t}", "int getMaxLevel();", "public String getLevel()\n {\n return level;\n }", "public String getLevel() {\n return level;\n }", "public String getLevel() {\n return level;\n }", "public String getLevel() {\n return level;\n }", "public String getLevel() {\n return level;\n }", "public String getLevel() {\n return level;\n }", "public int getLevel() {\n\t\treturn level;\n\t}", "public int getLevel() {\n\t\treturn level;\n\t}", "public int getLevel() {\n\t\treturn level;\n\t}", "public int getDamage() {\n \t\treturn damage + ((int) 0.5*level);\n \t}", "public String getLevel() {\n return this.level;\n }", "public String getLevel() {\n return level;\n }", "public int getLevel() {\n return level_;\n }", "public int getLevel() {\n return level_;\n }", "public int getLevel() {\n return level_;\n }", "public int getLevel() {\n return level_;\n }", "public int getLevelValue() {\n return level_;\n }", "public int getLevel() {\n\t\treturn this.level;\n\t}", "public String getLevel() {\n return level;\n }", "public double getLevel(SkillType name) { return levels.get(name); }", "public final String getLevel() {\n return this.level;\n }", "public String getLevel ()\n {\n return level;\n }", "abstract int getMaxLevel();", "public void setLevel(int newlevel)\n {\n level = newlevel; \n }", "int getOnLevel();", "@AutoEscape\n\tpublic String getLevel();", "public void setLevel(String lev) {\n\t\tlevel = lev;\n\t}", "public String getLevel() {\n\t\treturn level;\n\t}", "@Override \n public double highlightLevel(GameObject o) {\n if (this.getLevel() < o.getLevel())\n return 1;\n return 0;\n }", "public int getLevel() {\n\t\treturn 1 + this.iter / this.levelfk;\n\t}" ]
[ "0.6267184", "0.6219422", "0.6219422", "0.60582125", "0.5982128", "0.5982128", "0.5967598", "0.5967598", "0.59124786", "0.59074736", "0.5866724", "0.5837642", "0.58186245", "0.57907325", "0.57907325", "0.57907325", "0.57907325", "0.57907325", "0.57796913", "0.57796913", "0.57745844", "0.5770057", "0.5770057", "0.5756176", "0.575077", "0.57403296", "0.57354903", "0.572498", "0.57212234", "0.5717818", "0.56981915", "0.56981915", "0.56981915", "0.56981915", "0.56981915", "0.56981915", "0.56981915", "0.56981915", "0.56981915", "0.56981915", "0.5693593", "0.5677002", "0.56754696", "0.5646927", "0.5641645", "0.56356215", "0.56356215", "0.5633724", "0.56309015", "0.56187385", "0.56032175", "0.55959386", "0.55947775", "0.5582178", "0.55767304", "0.55767304", "0.5575873", "0.5575873", "0.5575873", "0.5575873", "0.5575873", "0.55650985", "0.5562269", "0.5562269", "0.5551056", "0.55434316", "0.55378", "0.55378", "0.5526857", "0.5520412", "0.55023015", "0.5500916", "0.5500916", "0.5500916", "0.5500916", "0.5500916", "0.5499579", "0.5499579", "0.5499579", "0.54969406", "0.54898137", "0.54776794", "0.54729813", "0.54729813", "0.54729813", "0.54729813", "0.54696435", "0.5461423", "0.5456261", "0.543629", "0.5435375", "0.543504", "0.5430084", "0.5427064", "0.5413936", "0.54092515", "0.5407901", "0.5378049", "0.5362759", "0.53554785" ]
0.7101567
0
Manage Base, Quests and Special Events drops of L2Attackable (called by calculateRewards). Concept : During a Special Event all L2Attackable can drop extra Items. Those extra Items are defined in the table allNpcDateDrops of the EventDroplist. Each Special Event has a start and end date to stop to drop extra Items automaticaly. Actions : Manage drop of Special Events created by GM for a defined period Get all possible drops of this L2Attackable from L2NpcTemplate and add it Quest drops For each possible drops (base + quests), calculate which one must be dropped (random) Get each Item quantity dropped (random) Create this or these L2ItemInstance corresponding to each Item Identifier dropped If the autoLoot mode is actif and if the L2Character that has killed the L2Attackable is a L2PcInstance, give this or these Item(s) to the L2PcInstance that has killed the L2Attackable If the autoLoot mode isn't actif or if the L2Character that has killed the L2Attackable is not a L2PcInstance, add this or these Item(s) in the world as a visible object at the position where mob was last
public void doItemDrop(final L2NpcTemplate npcTemplate, final L2Character lastAttacker) { L2PcInstance player = null; if (lastAttacker instanceof L2PcInstance) { player = (L2PcInstance) lastAttacker; } else if (lastAttacker instanceof L2Summon) { player = ((L2Summon) lastAttacker).getOwner(); } // Don't drop anything if the last attacker or ownere isn't L2PcInstance if (player == null) { return; } if (EngineModsManager.onNpcDrop(this, lastAttacker)) { return; } final int levelModifier = calculateLevelModifierForDrop(player); // level modifier in %'s (will be subtracted from drop chance) // Check the drop of a cursed weapon if (levelModifier == 0 && player.getLevel() > 20) { CursedWeaponsManager.getInstance().checkDrop(this, player); } // now throw all categorized drops and handle spoil. for (final L2DropCategory cat : npcTemplate.getDropData()) { RewardItem item = null; if (cat.isSweep()) { // according to sh1ny, seeded mobs CAN be spoiled and swept. if (isSpoil()/* && !isSeeded() */) { List<RewardItem> sweepList = new ArrayList<>(); for (final L2DropData drop : cat.getAllDrops()) { item = calculateRewardItem(player, drop, levelModifier, true); if (item == null) { continue; } if (Config.DEBUG) { LOGGER.debug("Item id to spoil: " + item.getItemId() + " amount: " + item.getCount()); } sweepList.add(item); item = null; } // Set the table sweepItems of this L2Attackable if (!sweepList.isEmpty()) { sweepItems = sweepList.toArray(new RewardItem[sweepList.size()]); } sweepList = null; } } else { if (isSeeded()) { L2DropData drop = cat.dropSeedAllowedDropsOnly(); if (drop == null) { continue; } item = calculateRewardItem(player, drop, levelModifier, false); drop = null; } else { item = calculateCategorizedRewardItem(player, cat, levelModifier); } if (item != null) { if (Config.DEBUG) { LOGGER.debug("Item id to drop: " + item.getItemId() + " amount: " + item.getCount()); } // Check if the autoLoot mode is active if (Config.AUTO_LOOT) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (item_templ == null) { LOGGER.info("ERROR: Item id to autoloot " + item.getItemId() + " has not template into items/armor/weapon tables.. It cannot be dropped.."); // DropItem(player, item); } else { if (!player.getInventory().validateCapacity(item_templ) || !Config.AUTO_LOOT_BOSS && this instanceof L2RaidBossInstance || !Config.AUTO_LOOT_BOSS && this instanceof L2GrandBossInstance) { DropItem(player, item); } else { player.doAutoLoot(this, item); // Give this or these Item(s) to the L2PcInstance that has killed the L2Attackable } } } else { DropItem(player, item); // drop the item on the ground } // Broadcast message if RaidBoss was defeated if (this instanceof L2RaidBossInstance || this instanceof L2GrandBossInstance) { SystemMessage sm; sm = new SystemMessage(SystemMessageId.S1_DIED_DROPPED_S3_S2); sm.addString(getName()); sm.addItemName(item.getItemId()); sm.addNumber(item.getCount()); broadcastPacket(sm); sm = null; } } } item = null; } // Apply Special Item drop with rnd qty for champions if (Config.L2JMOD_CHAMPION_ENABLE && isChampion() && player.getLevel() <= getLevel() + 3 && Config.L2JMOD_CHAMPION_REWARD > 0 && Rnd.get(100) < Config.L2JMOD_CHAMPION_REWARD) { int champqty = Rnd.get(Config.L2JMOD_CHAMPION_REWARD_QTY); champqty++; // quantity should actually vary between 1 and whatever admin specified as max, inclusive. RewardItem item = new RewardItem(Config.L2JMOD_CHAMPION_REWARD_ID, champqty); // Give this or these Item(s) to the L2PcInstance that has killed the L2Attackable if (Config.AUTO_LOOT) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("ChampionLoot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } item = null; } // Instant Item Drop :> final double rateHp = getStat().calcStat(Stats.MAX_HP, 1, this, null); if (rateHp < 2 && String.valueOf(npcTemplate.type).contentEquals("L2Monster")) // only L2Monster with <= 1x HP can drop herbs { boolean hp = false; boolean mp = false; boolean spec = false; // ptk - patk type enhance int random = Rnd.get(1000); // note *10 if (random < Config.RATE_DROP_SPECIAL_HERBS && !spec) // && !_spec useless yet { RewardItem item = new RewardItem(8612, 1); // Herb of Warrior if (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("Loot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } item = null; spec = true; } else { for (int i = 0; i < 3; i++) { random = Rnd.get(100); if (random < Config.RATE_DROP_COMMON_HERBS) { RewardItem item = null; if (i == 0) { item = new RewardItem(8606, 1); // Herb of Power } if (i == 1) { item = new RewardItem(8608, 1); // Herb of Atk. Spd. } if (i == 2) { item = new RewardItem(8610, 1); // Herb of Critical Attack } if (item == null) { break; } if (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("Loot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } break; } } } // mtk - matk type enhance random = Rnd.get(1000); // note *10 if (random < Config.RATE_DROP_SPECIAL_HERBS && !spec) { RewardItem item = new RewardItem(8613, 1); // Herb of Mystic if (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("Loot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } item = null; spec = true; } else { for (int i = 0; i < 2; i++) { random = Rnd.get(100); if (random < Config.RATE_DROP_COMMON_HERBS) { RewardItem item = null; if (i == 0) { item = new RewardItem(8607, 1); // Herb of Magic } if (i == 1) { item = new RewardItem(8609, 1); // Herb of Casting Speed } if (item == null) { break; } if (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("Loot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } break; } } } // hp+mp type random = Rnd.get(1000); // note *10 if (random < Config.RATE_DROP_SPECIAL_HERBS && !spec) { RewardItem item = new RewardItem(8614, 1); // Herb of Recovery if (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("Loot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } item = null; mp = true; hp = true; spec = true; } // hp - restore hp type if (!hp) { random = Rnd.get(100); if (random < Config.RATE_DROP_MP_HP_HERBS) { RewardItem item = new RewardItem(8600, 1); // Herb of Life if (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("Loot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } item = null; hp = true; } } if (!hp) { random = Rnd.get(100); if (random < Config.RATE_DROP_GREATER_HERBS) { RewardItem item = new RewardItem(8601, 1); // Greater Herb of Life if (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("Loot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } item = null; hp = true; } } if (!hp) { random = Rnd.get(1000); // note *10 if (random < Config.RATE_DROP_SUPERIOR_HERBS) { RewardItem item = new RewardItem(8602, 1); // Superior Herb of Life if (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("Loot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } item = null; } } // mp - restore mp type if (!mp) { random = Rnd.get(100); if (random < Config.RATE_DROP_MP_HP_HERBS) { RewardItem item = new RewardItem(8603, 1); // Herb of Mana if (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("Loot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } item = null; mp = true; } } if (!mp) { random = Rnd.get(100); if (random < Config.RATE_DROP_GREATER_HERBS) { RewardItem item = new RewardItem(8604, 1); // Greater Herb of Mana if (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("Loot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } item = null; mp = true; } } if (!mp) { random = Rnd.get(1000); // note *10 if (random < Config.RATE_DROP_SUPERIOR_HERBS) { RewardItem item = new RewardItem(8605, 1); // Superior Herb of Mana if (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("Loot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } item = null; } } // speed enhance type random = Rnd.get(100); if (random < Config.RATE_DROP_COMMON_HERBS) { RewardItem item = new RewardItem(8611, 1); // Herb of Speed if (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.addItem("Loot", item.getItemId(), item.getCount(), this, true); } } else { DropItem(player, item); } item = null; } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void doEventDrop(final L2Character lastAttacker)\n\t{\n\t\tL2PcInstance player = null;\n\t\t\n\t\tif (lastAttacker instanceof L2PcInstance)\n\t\t{\n\t\t\tplayer = (L2PcInstance) lastAttacker;\n\t\t}\n\t\telse if (lastAttacker instanceof L2Summon)\n\t\t{\n\t\t\tplayer = ((L2Summon) lastAttacker).getOwner();\n\t\t}\n\t\t\n\t\tif (player == null)\n\t\t{\n\t\t\treturn; // Don't drop anything if the last attacker or ownere isn't L2PcInstance\n\t\t}\n\t\t\n\t\tif (player.getLevel() - getLevel() > 9)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Go through DateDrop of EventDroplist allNpcDateDrops within the date range\n\t\tfor (final DateDrop drop : EventDroplist.getInstance().getAllDrops())\n\t\t{\n\t\t\tif (Rnd.get(L2DropData.MAX_CHANCE) < drop.chance)\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(drop.items[Rnd.get(drop.items.length)], Rnd.get(drop.min, drop.max));\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.doAutoLoot(this, item); // Give this or these Item(s) to the L2PcInstance that has killed the L2Attackable\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item); // drop the item on the ground\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t}\n\t\t}\n\t\t\n\t\tplayer = null;\n\t}", "public void rollCombatDrop() {\n\t\tRandom r=new Random();\n\t\t\n\t\tint x=r.nextInt(3);\n\t\tItem i=combatDrops.get(x);\n\t\taddItem(i.getName());\n\t\t\n\t\tevents.appendText(\"You find an \"+i.getName()+\" after defeating the \"+e.getName()+\"!\\n\"); // Infrom player\n\t}", "protected void dropDeathLoot(boolean flag, int i) {\n java.util.List<org.bukkit.inventory.ItemStack> loot = new java.util.ArrayList<org.bukkit.inventory.ItemStack>();\n\n if (!this.isSheared()) {\n loot.add(new org.bukkit.inventory.ItemStack(org.bukkit.Material.WOOL, 1, (short) 0, (byte) this.getColor()));\n }\n\n org.bukkit.craftbukkit.event.CraftEventFactory.callEntityDeathEvent(this, loot);\n // CraftBukkit end\n }", "@EventHandler\n public void onBreak(BlockBreakEvent e) {\n if(e.getPlayer().getItemInHand().hasItemMeta()) {\n if (e.getPlayer().getItemInHand().getItemMeta().hasDisplayName()) {\n if (e.getPlayer().getItemInHand().getItemMeta().getDisplayName().equals(ChatColor.AQUA + \"\" + ChatColor.BOLD +\n \"Swift Drill\")) {\n e.setDropItems(false);\n e.setExpToDrop(0);\n\n if(!(e.getPlayer().isSneaking())){\n Block b1 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX() - 1,\n e.getBlock().getY() + 1,\n e.getBlock().getZ());\n Collection<ItemStack> b1drop = b1.getDrops();\n b1.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b1drop.toArray(new ItemStack[b1drop.size()]));\n\n Block b2 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX(),\n e.getBlock().getY() + 1,\n e.getBlock().getZ());\n Collection<ItemStack> b2drop = b2.getDrops();\n b2.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b2drop.toArray(new ItemStack[b2drop.size()]));\n\n Block b3 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX() + 1,\n e.getBlock().getY() + 1,\n e.getBlock().getZ());\n Collection<ItemStack> b3drop = b3.getDrops();\n b3.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b3drop.toArray(new ItemStack[b3drop.size()]));\n\n Block b4 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX() - 1,\n e.getBlock().getY(),\n e.getBlock().getZ());\n Collection<ItemStack> b4drop = b4.getDrops();\n b4.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b4drop.toArray(new ItemStack[b4drop.size()]));\n\n Block b5 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX() + 1,\n e.getBlock().getY(),\n e.getBlock().getZ());\n Collection<ItemStack> b5drop = b5.getDrops();\n b5.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b5drop.toArray(new ItemStack[b5drop.size()]));\n\n Block b6 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX() - 1,\n e.getBlock().getY() - 1,\n e.getBlock().getZ());\n Collection<ItemStack> b6drop = b6.getDrops();\n b6.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b6drop.toArray(new ItemStack[b6drop.size()]));\n\n Block b7 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX(),\n e.getBlock().getY() - 1,\n e.getBlock().getZ());\n Collection<ItemStack> b7drop = b7.getDrops();\n b7.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b7drop.toArray(new ItemStack[b7drop.size()]));\n\n Block b8 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX() + 1,\n e.getBlock().getY() - 1,\n e.getBlock().getZ());\n Collection<ItemStack> b8drop = b8.getDrops();\n b8.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b8drop.toArray(new ItemStack[b8drop.size()]));\n }\n\n Collection<ItemStack> drop = e.getBlock().getDrops();\n SwiftDrillInv.inv.addItem(drop.toArray(new ItemStack[drop.size()]));\n }\n }\n }\n }", "@Override\n protected void dropFewItems(boolean hit, int looting) {\n super.dropFewItems(hit, looting);\n if (hit && (this.rand.nextInt(3) == 0 || this.rand.nextInt(1 + looting) > 0)) {\n Item drop = null;\n switch (this.rand.nextInt(5)) {\n case 0:\n drop = Items.gunpowder;\n break;\n case 1:\n drop = Items.sugar;\n break;\n case 2:\n drop = Items.spider_eye;\n break;\n case 3:\n drop = Items.fermented_spider_eye;\n break;\n case 4:\n drop = Items.speckled_melon;\n break;\n }\n if (drop != null) {\n this.dropItem(drop, 1);\n }\n }\n }", "@SubscribeEvent(priority=EventPriority.NORMAL, receiveCanceled=true)\n\tpublic void spiderDrop(LivingDropsEvent event)\n\t{\n\t if (event.getEntity() instanceof EntitySpider)\n\t {\n\t int radomint=new Random().nextInt(3);\n\t if(radomint==0){\n\t ItemStack itemStackToDrop = new ItemStack(ItemLoader.spiderGland, 1);\n\t event.getDrops().add(new EntityItem(event.getEntity().worldObj, event.getEntity().posX, \n\t event.getEntity().posY, event.getEntity().posZ, itemStackToDrop));\n\t }\n\t }\n\t}", "@EventHandler\r\n public void mobkillLst(EntityDeathEvent event) {\r\n if (event.getEntity().getKiller() instanceof Player && event.getEntity().getType() != EntityType.PLAYER) {//Ensure entity that is killed is not a player\r\n int xpmult = (int) (event.getDroppedExp() * main.XPMult);\r\n event.setDroppedExp(xpmult);\r\n }\r\n }", "public void rollCommonDrop() {\n\t\tRandom r=new Random();\n\t\t\n\t\tint x=r.nextInt(6);\n\t\tItem i=randomDrops.get(x);\n\t\taddItem(i.getName());\n\t\t\n\t\tevents.appendText(\"You find an \"+i.getName()+\" in your adventures!\\n\");\t// Inform player\n\t}", "@ForgeSubscribe(priority = EventPriority.HIGHEST)\n public void onLivingDrops(LivingDropsEvent event) {\n if (!event.recentlyHit)\n return;\n int id = -1;\n if (event.entityLiving instanceof EntityZombie)\n id = event.entityLiving instanceof EntityPigZombie ? -1 : 2;\n else if (event.entityLiving instanceof EntitySkeleton)\n id = ((EntitySkeleton)event.entityLiving).getSkeletonType() == 0 ? 0 : -1;\n else if (event.entityLiving instanceof EntityCreeper)\n id = 4;\n if (id < 0)\n return;\n if (_PlayerHeads.debug);\n else if (_PlayerHeads.dropRates[id] <= 0.0 || _PlayerHeads.random.nextDouble() - 0.005 * (double)event.lootingLevel >= _PlayerHeads.dropRates[id])\n return;\n ItemStack head = new ItemStack(Item.skull, 1, id);\n EntityItem drop = new EntityItem(event.entityLiving.worldObj, event.entityLiving.posX, event.entityLiving.posY, event.entityLiving.posZ, head);\n drop.delayBeforeCanPickup = 10;\n event.drops.add(drop);\n }", "public void dropBlockAsItemWithChance(World p_149690_1_, int p_149690_2_, int p_149690_3_, int p_149690_4_, int p_149690_5_, float p_149690_6_, int p_149690_7_) {}", "public void dropEntireInventory(World world, BlockPos pos, int id, int metadata) {\n int x = pos.getX();\n int y = pos.getY();\n int z = pos.getZ();\n TileEntity tileEntity = world.getTileEntity(pos);\n if (tileEntity != null && tileEntity instanceof IInventory) {\n IInventory inventory = (IInventory) tileEntity;\n for (int i = 0; i < inventory.getSizeInventory(); ++i) {\n ItemStack stack = inventory.getStackInSlot(i);\n if (stack != null) {\n Random random = new Random();\n float sx = random.nextFloat() * 0.8F + 0.1F;\n float sy = random.nextFloat() * 0.8F + 0.1F;\n float sz = random.nextFloat() * 0.8F + 0.1F;\n while (stack.stackSize > 0) {\n int qty = random.nextInt(21) + 10;\n if (qty > stack.stackSize) {\n qty = stack.stackSize;\n }\n stack.stackSize -= qty;\n EntityItem eitem = new EntityItem(world, x + sx, y + sy, z + sz, new ItemStack(stack.getItem(), qty, stack.getItemDamage()));\n if (stack.hasTagCompound()) {\n eitem.getEntityItem().setTagCompound((NBTTagCompound) stack.getTagCompound().copy());\n }\n float displacement = 0.05F;\n eitem.motionX = (float) random.nextGaussian() * displacement;\n eitem.motionY = (float) random.nextGaussian() * displacement + 0.2F;\n eitem.motionZ = (float) random.nextGaussian() * displacement;\n world.spawnEntityInWorld(eitem);\n }\n }\n }\n }\n }", "@Override\r\n\tprotected boolean canDropLoot() {\r\n\t\treturn false;\r\n\t}", "public void dropExplosives() {\n // Updates the time elapsed for each of the explosives\n for (int i=0; i<this.explosives.size(); i++) {\n Explosive dormantExplosive = this.explosives.get(i);\n dormantExplosive.increaseTime();\n }\n // If the Airplane has reached the end, doesn't detect any enemies\n // Isn't deleted straight away as it needs to wait for explosives to detonate\n if (super.outOfBounds()) {return;}\n this.timeElapsedDrop += ShadowDefend.getTimescale()/FPS;\n //Adds a new explosive\n if (this.timeElapsedDrop >= this.dropTime) {\n this.timeElapsedDrop = 0;\n Explosive newExplosive = new Explosive(super.getCenter());\n // Centers the explosive at the airplane's current position\n newExplosive.centerRectAt(super.getCenter());\n this.explosives.add(newExplosive);\n // Generates a new drop time in range\n this.dropTime = generateDropTime();\n this.numDropped++;\n }\n\n }", "public ArrayList<Item> drop()\n {\n ArrayList<Item> drop = new ArrayList<>();\n for( Pair<Enums.ItemName, Integer> possibleDrop : dropTable)\n {\n if(ThreadLocalRandom.current().nextInt(100) < possibleDrop.getY())\n drop.add(new Item(possibleDrop.getX()));\n }\n return drop;\n }", "public abstract int doDamage(int time, GenericMovableUnit unit, Unit target);", "@Override\n protected void dropFewItems(boolean hit, int looting) {\n super.dropFewItems(hit, looting);\n for (int i = this.rand.nextInt(2 + looting); i-- > 0;) {\n this.dropItem(Items.ender_pearl, 1);\n }\n }", "public Item getDropType(int paramInt1, Random paramRandom, int paramInt2) {\n/* 27 */ return Items.MELON;\n/* */ }", "protected void dropFewItems(boolean par1, int par2) {\r\n\t\tint var3 = this.rand.nextInt(3) + this.rand.nextInt(1 + par2);\r\n\t\t\r\n\t\tfor(int var4 = 0; var4 < var3; ++var4) {\r\n\t\t\tthis.dropItem(SorceryItems.goldfeather, 1);\r\n\t\t}\r\n\t\t\r\n\t\tif(this.isBurning()) {\r\n\t\t\tthis.dropItem(Items.cooked_chicken, 1);\r\n\t\t} else {\r\n\t\t\tthis.dropItem(Items.chicken, 1);\r\n\t\t}\r\n\t}", "public void drop() {\n\t\t// Has player waited cooldown before trying to fire again?\n\t\tif (System.currentTimeMillis() - this.lastFired > Config.WEAPON_COOLDOWN_TIME * 1000) {\n\t\t\t\n\t\t\t// Can this airship drop bombs?\n\t\t\tif (this.properties.DROPS_BOMB) {\n\t\t\t\tBlock[] cannons = getCannons();\n\t\t\t\tint numfiredcannons = 0;\n\t\t\t\tfor (int i = 0; i < cannons.length; i++) {\n\t\t\t\t\tif (cannons[i] != null && cannons[i].getRelative(0, -1, 0).getType().equals(Material.AIR) && cannonHasTnt(cannons[i], Config.NUM_TNT_TO_DROP_BOMB)) {\n\t\t\t\t\t\tif (numfiredcannons < this.properties.MAX_NUMBER_OF_CANNONS ) {\n\t\t\t\t\t\t\tnumfiredcannons++;\n\t\t\t\t\t\t\tlastFired = System.currentTimeMillis();\n\t\t\t\t\t\t\twithdrawTnt(cannons[i], Config.NUM_TNT_TO_DROP_BOMB);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Spawn primed tnt firing downwards TODO: maybe add sound effects for tnt firing? :P\n\t\t\t\t\t\t\tTNTPrimed tnt = cannons[i].getWorld().spawn(cannons[i].getLocation().clone().add(0, -1, 0), TNTPrimed.class);\n\t\t\t\t\t\t\ttnt.setVelocity(new Vector(0, -0.5, 0));\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// More cannons on ship than allowed. Not all fired - can break out of loop now.\n\t\t\t\t\t\t\tplayer.sendMessage(ChatColor.AQUA + \"Some cannons did not fire. Max cannon limit is \" + ChatColor.GOLD + this.properties.MAX_NUMBER_OF_CANNONS);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else\n\t\t\t\tplayer.sendMessage(ChatColor.GOLD + this.properties.SHIP_TYPE + \" CANNOT DROP BOMBS\");\n\t\t} else\n\t\t\tplayer.sendMessage(ChatColor.GOLD + \"COOLING DOWN FOR \" + ChatColor.AQUA + (int)(Math.round(6 - (System.currentTimeMillis() - this.lastFired) / 1000)) + ChatColor.GOLD + \" MORE SECONDS\");\n\t}", "@EventHandler\n\tpublic void entityDeath(EntityDeathEvent e){\n\t\tRandom random = new Random();\n\n\t\tdouble chance = 0.4f;\n\t\tif(random.nextDouble() <= chance) {\n\t\t\te.getEntity().getWorld().dropItem(e.getEntity().getLocation(), new ItemStack(Material.LEATHER));\n\t\t}\n\t}", "public static boolean[] drop(String enemy, int enemyHealth, int enemyDamage, int playerHealth, int playerDamage, int elixirCount, int elixirHealth, int wins, boolean[] items, int itemCount, int level) {\r\n //Level 2\r\n if (level == 2) {\r\n if (itemCount < 4) {\r\n items[wins-1] = true;\r\n }\r\n }\r\n //Level 3\r\n if (level == 3) {\r\n boolean chance = chance();\r\n if ((chance) && (itemCount < 4)) {\r\n items[wins-1] = true;\r\n }\r\n }\r\n return items;\r\n }", "private void generateItemEntities(){\n\t\tfinal int NUM_POTIONS = 6;\n\t\tfinal int NUM_IRON_ARMOUR = 1;\n\t\tfinal int NUM_CHESTS = 2;\n\t\tfinal String ITEM_BOX_STYLE = \"tundra\";\n\t\t\n\n\t\tfor (int i = 0; i < NUM_POTIONS; i++) {\n\t\t\tTile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n\t\t\t\t\tItem.randomItemPositionGenerator(DEFAULT_HEIGHT));\n\t\t\tif (!tile.hasParent()) {\n\t\t\t\tHealthPotion potion = new HealthPotion(tile, false,(PlayerPeon) getPlayerEntity(), ITEM_BOX_STYLE);\n\t\t\t\tentities.add(potion);\n\t\t\t\tthis.allTundraDialogues.add(potion.getDisplay());\n\t\t\t} else {\n\t\t\t\ti--;\n\t\t\t}\n\n\t\t}\n\t\tfor (int i = 0; i < NUM_IRON_ARMOUR; i++) {\n\t\t\tTile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n\t\t\t\t\tItem.randomItemPositionGenerator(DEFAULT_HEIGHT));\n\t\t\tif (!tile.hasParent()) {\n\t\t\t\tIronArmour ironArmour = new IronArmour(tile, false,\n\t\t\t\t\t\t(PlayerPeon) getPlayerEntity(), ITEM_BOX_STYLE,200);\n\t\t\t\tentities.add(ironArmour);\n\t\t\t\tthis.allTundraDialogues.add(ironArmour.getDisplay());\n\t\t\t} else {\n\t\t\t\ti--;\n\t\t\t}\n\n\t\t}\n\t\tfor (int i = 0; i < NUM_CHESTS; i++) {\n\t\t\tTile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n\t\t\t\t\tItem.randomItemPositionGenerator(DEFAULT_HEIGHT));\n\t\t\tif (!tile.hasParent()) {\n\t\t\t\tTreasure chest = new Treasure(tile, false,(PlayerPeon) getPlayerEntity(), ITEM_BOX_STYLE);\n\t\t\t\tentities.add(chest);\n\t\t\t\tthis.allTundraDialogues.add(chest.getDisplay());\n\t\t\t} else {\n\t\t\t\ti--;\n\t\t\t}\n\t\t}\n\n\t\tTile cooldownring = getTile(18,17);\n\t\tCooldownRing cdring = new CooldownRing(cooldownring, false,\n\t\t\t\t(PlayerPeon) this.getPlayerEntity(), ITEM_BOX_STYLE,0.5f);\n\t\tentities.add(cdring);\n\t\tthis.allTundraDialogues.add(cdring.getDisplay());\n\n\t\tTile attackAmuletTile = getTile(-19,14);\n\t\tAmulet attackAmulet = new Amulet(attackAmuletTile, false,\n\t\t\t\t(PlayerPeon) this.getPlayerEntity(), ITEM_BOX_STYLE,10);\n\t\tentities.add(attackAmulet);\n\t\tthis.allTundraDialogues.add(attackAmulet.getDisplay());\n\n\t}", "public void dropBlockAsItemWithChance(World worldIn, BlockPos pos, IBlockState state, float chance, int fortune) {\n/* 78 */ if (!worldIn.isRemote && worldIn.getGameRules().getGameRuleBooleanValue(\"doTileDrops\")) {\n/* */ \n/* 80 */ EntitySilverfish var6 = new EntitySilverfish(worldIn);\n/* 81 */ var6.setLocationAndAngles(pos.getX() + 0.5D, pos.getY(), pos.getZ() + 0.5D, 0.0F, 0.0F);\n/* 82 */ worldIn.spawnEntityInWorld((Entity)var6);\n/* 83 */ var6.spawnExplosionParticle();\n/* */ } \n/* */ }", "void onItemDropped(EntityId droppedItem);", "@Override\n\t public ArrayList<ItemStack> getDrops(World world, int x, int y, int z, int metadata, int fortune)\n {\n \t// DEBUG\n \tSystem.out.println(\"BlockTomato getDrops()\");\n ArrayList<ItemStack> ret = new ArrayList<ItemStack>();\n\n int count = quantityDropped(metadata, fortune, world.rand);\n for(int i = 0; i < count; i++)\n {\n Item item = getItemDropped(metadata, world.rand, fortune);\n if (item != null)\n {\n ret.add(new ItemStack(item, 1, damageDropped(metadata)));\n }\n }\n return ret;\n }", "@Override\n public void dropBlockAsItemWithChance(@Nonnull World worldIn, @Nonnull BlockPos pos, @Nonnull IBlockState state, float chance, int fortune)\n {\n }", "@ForgeSubscribe\n \tpublic void onLivingDeath(LivingDeathEvent event) {\n \t\t\n \t\tEntityLivingBase entity = event.entityLiving;\n \t\tif (entity.worldObj.isRemote) return;\n \t\tItemStack backpack = ItemBackpack.getBackpack(entity);\n \t\tif (backpack == null) return;\n \t\tPropertiesBackpack backpackData = ItemBackpack.getBackpackData(entity);\n \t\tif (backpackData.contents == null) return;\n \t\t\n \t\tboolean keepInventory = entity.worldObj.getGameRules().getGameRuleBooleanValue(\"keepInventory\");\n \t\tif ((entity instanceof EntityPlayer) && keepInventory) {\n \t\t\t\n \t\t\t// If keep inventory is on, instead temporarily save the contents\n \t\t\t// to the persistent NBT tag and get them back when the player respawns.\n \t\t\t\n \t\t\tEntityPlayer player = (EntityPlayer)entity;\n \t\t\tNBTTagCompound compound = player.getEntityData();\n \t\t\tNBTTagCompound persistent;\n \t\t\tif (!compound.hasKey(EntityPlayer.PERSISTED_NBT_TAG)) {\n \t\t\t\tpersistent = new NBTTagCompound();\n \t\t\t\tcompound.setTag(EntityPlayer.PERSISTED_NBT_TAG, persistent);\n \t\t\t} else persistent = compound.getCompoundTag(EntityPlayer.PERSISTED_NBT_TAG);;\n \t\t\t\n \t\t\tNBTTagCompound backpackCompound = new NBTTagCompound();\n \t\t\tbackpackCompound.setInteger(\"count\", backpackData.contents.length);\n \t\t\tbackpackCompound.setTag(\"Items\", NbtUtils.writeItems(backpackData.contents));\n \t\t\tpersistent.setTag(\"Backpack\", backpackCompound);\n \t\t\t\n \t\t} else {\n \t\t\t\n \t\t\tfor (ItemStack stack : backpackData.contents)\n \t\t\t\tWorldUtils.dropStackFromEntity(entity, stack, 4.0F);\n \t\t\tbackpackData.contents = null;\n \t\t\t\n \t\t}\n \t\t\n \t}", "@EventHandler\n public void onBlockDropEvent(BlockBreakEvent event) {\n if (!plugin.config.enabled) {\n //plugin is not enabled.. do nothing\n return;\n }\n\n Player player = event.getPlayer();\n //message for debug\n String debugMSG = \"\";\n //test if player is in creative\n if (player.getGameMode().equals(GameMode.CREATIVE)){\n //don't drop anything\n if (plugin.config.debug) {\n debugMSG = ChatColor.DARK_GREEN + \"[DEBUG]\"\n + ChatColor.YELLOW + \"[\" + player.getDisplayName() + \"]\"\n + ChatColor.RESET;\n plugin.console.log(debugMSG + \"Player in Creative Mode. Not Dropping Items.\");\n }\n return;\n }\n\n Block block = event.getBlock();\n\n\n String blockLocation = \"\";\n if (plugin.config.debug) {\n debugMSG = ChatColor.DARK_GREEN + \"[DEBUG]\"\n + ChatColor.YELLOW + \"[\" + player.getDisplayName() + \"]\"\n + ChatColor.BLUE + \"[\" + block.getType().name() + \"]\"\n + ChatColor.RESET;\n blockLocation = ChatColor.DARK_AQUA + \" X:\" + ChatColor.GRAY + block.getLocation().getBlockX()\n + ChatColor.DARK_AQUA + \" Y:\" + ChatColor.GRAY + block.getLocation().getBlockY()\n + ChatColor.DARK_AQUA + \" Z:\" + ChatColor.GRAY + block.getLocation().getBlockZ();\n }\n\n //test to see if this block was placed\n List<MetadataValue> blockD = block.getMetadata(placeBlock);\n if (blockD.size() != 0) {\n //block was placed\n // don't drop anything\n\n //debug\n if (plugin.config.debug) {\n plugin.console.log(debugMSG\n + \" Block Was Placed. No Drops Allowed. \"\n + blockLocation\n );\n }\n return;\n }\n\n Material brokenBlock = block.getType();//gets the material that was just broken\n\n\n //test if we need to check out list of Ores,\n // OR... are we doing it for ALL Blocks\n Ore tempOre = new Ore();//set up tempOre for good measure\n\n if (plugin.config.allBlocks) {\n //we are looking at all blocks\n // make tempOre equal to the block that we broke\n tempOre.setBlock(brokenBlock);\n tempOre.setExp(plugin.config.allBlocks_exp);\n tempOre.setMultiplier(plugin.config.allBlocks_multiplier);\n tempOre.setChance(plugin.config.allBlocks_chance);\n } else {\n //find a Material in our list that matches\n tempOre = plugin.ores.stream().filter((ore) -> brokenBlock.name().contains(ore.getName())).findFirst().orElse(null);\n }\n\n\n if (tempOre == null) {\n //ore was not in our list.\n //stop method\n\n //debug\n if (plugin.config.debug) {\n plugin.console.log(debugMSG\n + \" Block was not Registered in config. No Drops Allowed. \"\n );\n }\n\n return;\n }\n\n //find out if we hit the right chance and go from there\n int chance = plugin.rnd.nextInt(100);//get a percentage\n\n //debug\n if (plugin.config.debug) {\n plugin.console.log(debugMSG\n + \" Chance Needed: \" + tempOre.getChance()\n + \" Chance Received: \" + chance + \" \"\n + blockLocation\n );\n }\n\n if (chance <= tempOre.getChance()) {\n //success on the chance\\\n\n //debug\n if (plugin.config.debug) {\n plugin.console.log(debugMSG\n + \" Drops Allowed. \"\n + blockLocation\n );\n }\n\n Collection<ItemStack> droppedItems = event.getBlock().getDrops();//get what ever was dropped\n int initialDrop = 0;//variable to hold how many items were dropped to begin with\n //drop an extra item per drop\n for (ItemStack i : droppedItems) {\n initialDrop = i.getAmount();\n i.setAmount(i.getAmount()*tempOre.getMultiplier() - 1);//set amount to drop\n\n //debug\n if (plugin.config.debug) {\n plugin.console.log(debugMSG\n + \" Drop: \" + i.getType().name()\n + \" Amount: \" + initialDrop\n + \" Multiplier: \" + tempOre.getMultiplier()\n + \" Extra Given: \" + (i.getAmount())\n + blockLocation\n );\n }\n\n event.getBlock().getWorld().dropItemNaturally(\n event.getBlock().getLocation(), i\n );\n }\n\n //find out if we need to give experience\n if (tempOre.isExp()) {\n\n //debug\n if (plugin.config.debug) {\n plugin.console.log(debugMSG\n + \" Drop includes XP\"\n + \" Amount: \" + event.getExpToDrop()\n + \" Multiplier: \" + tempOre.getMultiplier()\n + \" Total Given: \" + (event.getExpToDrop() * tempOre.getMultiplier())\n + blockLocation\n );\n }\n\n event.setExpToDrop(event.getExpToDrop() * tempOre.getMultiplier());\n }\n\n\n }\n\n\n }", "public Item getItemDropped(int meta, Random p_149650_2_, int p_149650_3_)\n\t {\n\t \treturn MGHouseItems.item_boat_door;\n\t }", "private void generateItemEntities(){\n final int NUM_POTIONS = 6;\n final int NUM_IRON_ARMOUR = 1;\n final int NUM_CHESTS = 2;\n final String ITEM_BOX_STYLE = \"volcano\";\n\n\n for (int i = 0; i < NUM_POTIONS; i++) {\n Tile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n Item.randomItemPositionGenerator(DEFAULT_HEIGHT));\n if (Integer.parseInt(tile.getTextureName().split(\"_\")[1]) < 5\n && !tile.hasParent()) {\n HealthPotion potion = new HealthPotion(tile,false,\n (PlayerPeon) getPlayerEntity(), ITEM_BOX_STYLE);\n entities.add(potion);\n this.allVolcanoDialogues.add(potion.getDisplay());\n } else {\n i--;\n }\n }\n for (int i =0; i < NUM_IRON_ARMOUR; i++){\n Tile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n Item.randomItemPositionGenerator(DEFAULT_HEIGHT));\n if (Integer.parseInt(tile.getTextureName().split(\"_\")[1]) < 5\n && !tile.hasParent()) {\n IronArmour ironArmour = new IronArmour(tile, false,\n (PlayerPeon) getPlayerEntity(),ITEM_BOX_STYLE,200);\n entities.add(ironArmour);\n this.allVolcanoDialogues.add(ironArmour.getDisplay());\n } else {\n i--;\n }\n }\n for (int i = 0; i <NUM_CHESTS; i++){\n Tile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n Item.randomItemPositionGenerator(DEFAULT_HEIGHT));\n if (Integer.parseInt(tile.getTextureName().split(\"_\")[1]) < 5\n && !tile.hasParent()) {\n Treasure chest = new Treasure(tile, false,\n (PlayerPeon) getPlayerEntity(),ITEM_BOX_STYLE);\n entities.add(chest);\n this.allVolcanoDialogues.add(chest.getDisplay());\n } else {\n i--;\n }\n }\n\n Tile cooldownring = getTile(20,-7);\n CooldownRing cdring = new CooldownRing(cooldownring, false,\n (PlayerPeon) this.getPlayerEntity(), ITEM_BOX_STYLE,0.5f);\n entities.add(cdring);\n this.allVolcanoDialogues.add(cdring.getDisplay());\n\n Tile attackAmuletTile = getTile(2,14);\n Amulet attackAmulet = new Amulet(attackAmuletTile, false,\n (PlayerPeon) this.getPlayerEntity(), ITEM_BOX_STYLE,10);\n entities.add(attackAmulet);\n this.allVolcanoDialogues.add(attackAmulet.getDisplay());\n\n }", "@Override\r\n public Collection<Item> roll() {\r\n Collection<Item> dropItems = new ArrayList();\r\n \r\n for (LootTableItem item : this.items) {\r\n if (random.nextDouble() <= 1 / item.getChance()) {\r\n dropItems.add(item.create());\r\n }\r\n if (dropItems.size() == amount) break;\r\n }\r\n \r\n return dropItems;\r\n }", "public ItemStack onItemRightClick(ItemStack var1, World var2, EntityPlayer var3)\n {\n float var4 = 1.0F;\n double var5 = var3.prevPosX + (var3.posX - var3.prevPosX) * (double)var4;\n double var7 = var3.prevPosY + (var3.posY - var3.prevPosY) * (double)var4 + 1.62D - (double)var3.yOffset;\n double var9 = var3.prevPosZ + (var3.posZ - var3.prevPosZ) * (double)var4;\n boolean var11 = this.isFull == 0;\n MovingObjectPosition var12 = this.getMovingObjectPositionFromPlayer(var2, var3, var11);\n\n if (var12 == null)\n {\n return var1;\n }\n else\n {\n FillBucketEvent var13 = new FillBucketEvent(var3, var1, var2, var12);\n\n if (MinecraftForge.EVENT_BUS.post(var13))\n {\n return var1;\n }\n else if (var13.getResult() == Event.Result.ALLOW)\n {\n if (var3.capabilities.isCreativeMode)\n {\n return var1;\n }\n else if (--var1.stackSize <= 0)\n {\n return var13.result;\n }\n else\n {\n if (!var3.inventory.addItemStackToInventory(var13.result))\n {\n var3.dropPlayerItem(var13.result);\n }\n\n return var1;\n }\n }\n else\n {\n if (var12.typeOfHit == EnumMovingObjectType.TILE)\n {\n int var14 = var12.blockX;\n int var15 = var12.blockY;\n int var16 = var12.blockZ;\n\n if (!var2.canMineBlock(var3, var14, var15, var16))\n {\n return var1;\n }\n\n if (this.isFull == 0)\n {\n if (!var3.canPlayerEdit(var14, var15, var16, var12.sideHit, var1))\n {\n return var1;\n }\n\n if (var2.getBlockMaterial(var14, var15, var16) == Material.water && var2.getBlockMetadata(var14, var15, var16) == 0)\n {\n var2.setBlockWithNotify(var14, var15, var16, 0);\n\n if (var3.capabilities.isCreativeMode)\n {\n return var1;\n }\n\n if (--var1.stackSize <= 0)\n {\n return new ItemStack(Item.bucketWater);\n }\n\n if (!var3.inventory.addItemStackToInventory(new ItemStack(Item.bucketWater)))\n {\n var3.dropPlayerItem(new ItemStack(Item.bucketWater.itemID, 1, 0));\n }\n\n return var1;\n }\n\n if (var2.getBlockMaterial(var14, var15, var16) == Material.lava && var2.getBlockMetadata(var14, var15, var16) == 0 && var2.getBlockId(var14, var15, var16) == DivineRPG.tarStill.blockID)\n {\n var2.setBlockWithNotify(var14, var15, var16, 0);\n\n if (var3.capabilities.isCreativeMode)\n {\n return var1;\n }\n\n if (--var1.stackSize <= 0)\n {\n return new ItemStack(DivineRPG.tarBucket);\n }\n\n if (!var3.inventory.addItemStackToInventory(new ItemStack(DivineRPG.tarBucket)))\n {\n var3.dropPlayerItem(new ItemStack(DivineRPG.tarBucket.itemID, 1, 0));\n }\n\n return var1;\n }\n }\n else\n {\n if (this.isFull < 0)\n {\n return new ItemStack(DivineRPG.arcaniumBucket);\n }\n\n if (var12.sideHit == 0)\n {\n --var15;\n }\n\n if (var12.sideHit == 1)\n {\n ++var15;\n }\n\n if (var12.sideHit == 2)\n {\n --var16;\n }\n\n if (var12.sideHit == 3)\n {\n ++var16;\n }\n\n if (var12.sideHit == 4)\n {\n --var14;\n }\n\n if (var12.sideHit == 5)\n {\n ++var14;\n }\n\n if (!var3.canPlayerEdit(var14, var15, var16, var12.sideHit, var1))\n {\n return var1;\n }\n\n if (this.tryPlaceContainedLiquid(var2, var5, var7, var9, var14, var15, var16) && !var3.capabilities.isCreativeMode)\n {\n return new ItemStack(DivineRPG.arcaniumBucket);\n }\n }\n }\n\n return var1;\n }\n }\n }", "@EventHandler\n public void onPlayerDeath(PlayerDeathEvent event) {\n\n Player player = event.getEntity();\n World world = player.getWorld();\n int experience = player.getTotalExperience();\n\n // TODO: Add configurable.\n player.setTotalExperience(experience / 2);\n\n // TODO: Add configurable.\n // Reduce the player's level by 8.\n player.setLevel(player.getLevel() >= 8 ? player.getLevel() - 8 : 0);\n player.setExp(0);\n\n Inventory playerInventory = player.getInventory();\n\n // TODO: Add configurable.\n // Drop all the items in the player's internal inventory.\n for (int i = 9; i <= 35; i++) {\n ItemStack item = playerInventory.getItem(i);\n if (item != null) {\n world.dropItem(player.getLocation(), item);\n playerInventory.clear(i);\n }\n }\n\n // TODO: Add configurable.\n // Damage all equipped armor by a set amount in config file.\n for (int i = 36; i <= 39; i++) {\n ItemStack equipment = playerInventory.getItem(i);\n\n // Make sure we're wearing something!\n if (equipment == null) continue;\n\n // Check if we can damage this item, otherwise continue.\n ItemMeta meta = equipment.getItemMeta();\n if (!(meta instanceof Damageable)) continue;\n\n int value = ksiPlugin.config.getInt(\"armorDurabilityDamage\");\n if (value == 0) continue;\n else {\n value = 100 / value;\n }\n\n int currentDamage = ((Damageable) meta).getDamage();\n int damageModifier = equipment.getType().getMaxDurability() / value;\n\n ((Damageable) meta).setDamage(currentDamage + damageModifier);\n equipment.setItemMeta(meta);\n }\n }", "@Override\n\tprotected void dropFewItems(boolean par1, int par2) {\n\t\tsuper.dropFewItems(par1, par2);\n\n\t\t// drop saddle if equipped\n\t\tif (isSaddled()) {\n\t\t\tdropItem(Items.SADDLE, 1);\n\t\t}\n\t}", "private void dropAllDrops(ItemStack drop, int amount, Location dropLocation, boolean addEnchantment){\n double inStacks = (double) amount / (double) drop.getMaxStackSize();\n double floor = Math.floor(inStacks);\n double leftOver = inStacks - floor;\n for(int i = 1; i <= floor; i++){\n ItemStack newStack = drop.clone();\n newStack.setAmount(drop.getMaxStackSize());\n if(addEnchantment){\n newStack.addUnsafeEnchantment(Enchantment.DIG_SPEED, 1);\n }\n dropLocation.getWorld().dropItemNaturally(dropLocation, newStack);\n }\n if(leftOver > 0){\n ItemStack newStack = drop.clone();\n newStack.setAmount((int) Math.round(leftOver * drop.getMaxStackSize()));\n if(addEnchantment){\n newStack.addUnsafeEnchantment(Enchantment.DIG_SPEED, 1);\n }\n dropLocation.getWorld().dropItemNaturally(dropLocation, newStack);\n }\n }", "@ZenCodeType.Method\n @ZenCodeType.Getter(\"drops\")\n public static List<ItemStack> getDrops(ItemFishedEvent internal) {\n \n return internal.getDrops();\n }", "@SideOnly(Side.CLIENT)\n/* */ public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List<String> par3List, boolean par4) {\n/* 59 */ if (GuiScreen.isShiftKeyDown()) {\n/* 60 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome1.lore\"));\n/* 61 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome2.lore\"));\n/* 62 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome3.lore\"));\n/* 63 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* 64 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome4.lore\"));\n/* 65 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome5.lore\"));\n/* 66 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* 67 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome6.lore\"));\n/* 68 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome7.lore\"));\n/* 69 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome8.lore\"));\n/* 70 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* 71 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome9.lore\"));\n/* 72 */ } else if (GuiScreen.isCtrlKeyDown()) {\n/* 73 */ par3List.add(StatCollector.translateToLocal(\"item.FRVisPerSecond.lore\"));\n/* 74 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRAerCost.lore\") + (AerCost / 100.0D * 10.0D));\n/* 75 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRTerraCost.lore\") + (TerraCost / 100.0D * 10.0D));\n/* 76 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRIgnisCost.lore\") + (IgnisCost / 100.0D * 10.0D));\n/* 77 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRPerditioCost.lore\") + (PerditioCost / 100.0D * 10.0D));\n/* */ } else {\n/* */ \n/* 80 */ par3List.add(StatCollector.translateToLocal(\"item.FRShiftTooltip.lore\"));\n/* 81 */ par3List.add(StatCollector.translateToLocal(\"item.FRViscostTooltip.lore\"));\n/* */ } \n/* */ \n/* 84 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* */ }", "private void checkForDeaths() {\n Iterator<Entity> entityIter = this.entities.iterator();\n\n //geht alle teilnehmer durch\n while ( entityIter.hasNext() ) {\n Entity entity = entityIter.next();\n\n //und entfernt sie wenn sie tot sind aus der liste und der engine\n if ( this.combatMapper.get(entity).curHealth <= 0 ) {\n entityIter.remove();\n\n //alle actions der entity entfernen, können ja nichts machen wenn sie tot sind\n Iterator<IAction> actionIter = this.actions.iterator();\n\n while ( actionIter.hasNext() ) {\n if ( actionIter.next().getOwner().equals(entity) ) {\n actionIter.remove();\n }\n }\n\n this.combatExp += this.combatMapper.get(entity).level * 5; //TODO\n\n EventSystem.getInstance().commitEvent(new Event(EventSystem.EventType.KILL_EVENT, entity));\n\n this.combatSystem.getEngine().removeEntity(entity);\n }\n }\n }", "public static ArrayList<ItemEntity> generateDrops(DropQuality quality,DropChance chance)\n {\n //the return list of drops\n ArrayList<ItemEntity> drops = new ArrayList();\n \n //=======================\n // Roll Currency Drops\n //=======================\n //generate the amount of currency that will drop\n int numberOfCurrency = rollAmountOfCurrency(chance.percentChance);\n \n //build the currency\n for(int i = 0; i < numberOfCurrency; i++)\n {\n //build\n ItemEntity drop = new Currency(1);\n \n //add drop\n drops.add(drop);\n }\n \n //=======================\n //roll if we drop a potion\n //=======================\n boolean dropAPot = false;\n float potionRoll = SylverRandom.random.nextFloat(); \n if(quality == DropQuality.VeryPoor)\n {\n if(potionRoll<= 0.00f)\n dropAPot = true;\n }\n else if(quality == DropQuality.Poor)\n {\n if(potionRoll<= 0.05f)\n dropAPot = true;\n }\n else if(quality == DropQuality.Good)\n {\n if(potionRoll<= 0.2f)\n dropAPot = true;\n }\n else if(quality == DropQuality.VeryGood)\n {\n if(potionRoll<= 1f)\n dropAPot = true;\n }\n \n if(dropAPot == true)\n {\n drops.add(new Potion());\n }\n \n \n //return the drops\n return drops;\n \n }", "public void popItems() {\n\t\t\n\t\tItemList.add(HPup);\n\t\tItemList.add(SHPup);\n\t\tItemList.add(DMGup);\n\t\tItemList.add(SDMGup);\n\t\tItemList.add(EVup);\n\t\tItemList.add(SEVup);\n\t\t\n\t\trandomDrops.add(HPup);\n\t\trandomDrops.add(SHPup);\n\t\trandomDrops.add(DMGup);\n\t\trandomDrops.add(SDMGup);\n\t\trandomDrops.add(EVup);\n\t\trandomDrops.add(SEVup);\n\t\t\n\t\tcombatDrops.add(SHPup);\n\t\tcombatDrops.add(SDMGup);\n\t\tcombatDrops.add(SEVup);\n\t}", "public ItemStack createItem(ItemType type, int damage,List<Text> lore);", "@Override\n public int quantityDropped(int meta, int fortune, Random random)\n {\n return super.quantityDropped(meta, fortune, random);\n }", "public void dropItem(Location loc){\n\t\t\n\t\tPlayer p = getThrower();\n\t\tItemStack droppedItem;\n\t\t\n\t\tdroppable.clear();\n\t\t\n\t\taddItem(Material.IRON_INGOT, 8, 8, 3); //Item, weight, maximum stack size, minimum stack size\n\t\taddItem(Material.GOLD_INGOT, 5, 5, 1);\n\t\taddItem(Material.DIAMOND, 3, 3, 1);\n\t\taddItem(Material.GOLDEN_APPLE, 1, 1, 1);\n\t\taddItem(Material.ROTTEN_FLESH, 10, 5, 1);\n\t\taddItem(Material.BREAD, 15, 32, 15);\n\t\taddItem(Material.BONE, 10, 5, 1);\n\t\taddItem(Material.SULPHUR, 10, 5, 1);\n\t\taddItem(Material.SADDLE, 1, 1, 1);\n\t\t\n\t\tint Size = droppable.size();\n\t\trandNum = ThreadLocalRandom.current().nextInt(Size);\n\t\t\n\t\tdroppedItem = droppable.get(randNum);\n\t\t\n\t\tp.getWorld().dropItem(loc, droppedItem);\n\t\tp.getWorld().dropItem(loc, new ItemStack(Material.GOLD_NUGGET, rand.nextInt(10) + 1));\n\t\t\n\t}", "protected void doItemDrop(Location loc, Player player, ItemStack itemStack) {\n // To avoid drops occasionally spawning in a block and warping up to the\n // surface, wait for the next tick and check whether the block is\n // actually unobstructed. We don't attempt to save the drop if e.g.\n // a mob is standing in lava, however.\n Bukkit.getScheduler().scheduleSyncDelayedTask(BeastMaster.PLUGIN, () -> {\n Block block = loc.getBlock();\n Location revisedLoc = (block != null &&\n !canAccomodateItemDrop(block) &&\n player != null) ? player.getLocation()\n : loc;\n org.bukkit.entity.Item item = revisedLoc.getWorld().dropItem(revisedLoc, itemStack);\n item.setInvulnerable(isInvulnerable());\n item.setGlowing(isGlowing());\n }, 1);\n }", "@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)\r\n public void onPlayerDamagedByPlayer(final EntityDamageByEntityEvent event) {\n if (!(event.getEntity() instanceof Player)) {\r\n return;\r\n }\r\n if (!(event.getDamager() instanceof Player)) {\r\n return;\r\n }\r\n \r\n final Player target = (Player)event.getEntity();\r\n final Player attacker = (Player)event.getDamager();\r\n final ItemStack is = attacker.getItemInHand();\r\n \r\n if (is != null){\r\n switch (is.getType()){\r\n case EMERALD:\r\n attacker.setItemInHand(ItemUtil.decrementItem(is, 1));\r\n \r\n // 体力・空腹回復、燃えてたら消化\r\n target.setHealth(target.getMaxHealth());\r\n target.setFoodLevel(20);\r\n target.setFireTicks(0);\r\n \r\n // ポーション効果付与\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.REGENERATION, 45 * 20, 0)); // 45 secs\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.FIRE_RESISTANCE, 7 * 60 * 20, 0)); // 7 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.INCREASE_DAMAGE, 9 * 60 * 20, 1)); // 9 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.SPEED, 9 * 60 * 20, 0)); // 9 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.FAST_DIGGING, 5 * 60 * 20, 1)); // 5 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.NIGHT_VISION, 3 * 60 * 20, 0)); // 3 mins\r\n \r\n // effect, messaging\r\n target.getWorld().playEffect(target.getLocation(), Effect.ENDER_SIGNAL, 0, 10);\r\n Util.message(target, PlayerManager.getPlayer(attacker).getName() + \" &aから特殊効果を与えられました!\");\r\n Util.message(attacker, PlayerManager.getPlayer(target).getName() + \" &aに特殊効果を与えました!\");\r\n \r\n event.setCancelled(true);\r\n event.setDamage(0);\r\n break;\r\n default: break;\r\n }\r\n }\r\n }", "public void createNewCraftEntry(MessageReceivedEvent event, String[] args, Item item){\n int totalBonus = 10+((Integer.parseInt(args[2])-10)/2);\n System.out.println((Integer.parseInt(args[2])-10)/2 + \" and \" + totalBonus);\n if(args[1] != null) {\n if (args[0].equals(\"true\")) {\n totalBonus += (Integer.parseInt(args[1]) * 2);\n } else {\n totalBonus += Integer.parseInt(args[1]);\n }\n }\n int baseTime=20;\n String rarity = item.getRarity();\n switch(rarity){\n case \"common\":\n case \"Common\":\n baseTime = 20;\n if(item.isConsumable()){\n baseTime = baseTime/3;\n }\n break;\n case \"uncommon\":\n case \"Uncommon\":\n baseTime = 100;\n if(item.isConsumable()){\n baseTime = baseTime/3;\n }\n break;\n case \"rare\":\n case \"Rare\":\n baseTime = 240;\n if(item.isConsumable()){\n baseTime = baseTime/4;\n }\n break;\n case \"very rare\":\n case \"Very Rare\":\n baseTime = 400;\n if(item.isConsumable()){\n baseTime = baseTime/4;\n }\n break;\n case \"legendary\":\n case \"Legendary\":\n baseTime = 500;\n if(item.isConsumable()){\n baseTime = baseTime/4;\n }\n break;\n }\n int finalTime = baseTime/totalBonus;\n LocalDateTime timeStart = LocalDateTime.now();\n LocalDateTime timeEnd = LocalDateTime.now().plusDays(finalTime);\n String crafterID = event.getAuthor().getId();\n //Corrects time if it is after the completion of the daily crafting cycle\n if(timeEnd.toLocalDate().equals(timeStart.toLocalDate())){\n if(timeStart.toLocalTime().isAfter(LocalTime.of(13,0))){\n timeEnd = timeEnd.plusDays(1);\n }\n }\n String timestampStart = timeStart.toString();\n String timestampEnd = timeEnd.toString();\n String crafterChar = args[4];\n String channelID = event.getChannel().getId();\n\n String outputString = crafterID + \",\" + timestampStart + \",\" + timestampEnd + \",\" + item.getName() + \",\" + crafterChar + \",\" + channelID;\n String[] outputArray = outputString.split(\",\");\n\n if(timeEnd.toLocalDate().equals(timeStart.toLocalDate())){\n itemsDueToday.add(outputArray);\n }\n craftBacklog.add(outputArray);\n\n List<Object> writeList = new ArrayList<>();\n for(String field:outputArray){\n writeList.add(field);\n }\n\n try {\n SheetInformationBuffer.writeToCraft(writeList);\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n String dateEnd = timeEnd.toLocalDate().toString();\n event.getChannel().sendMessage(\"Congratulations <@\" + crafterID + \">! Your ***\" + item.getName() + \"*** will be ready on: \" + dateEnd).queue();\n\n }", "public void onUsingTick(ItemStack stack, EntityPlayer player, int count) {\n/* 132 */ player.motionX = 0.0D;\n/* 133 */ player.motionZ = 0.0D;\n/* */ \n/* 135 */ int searchRange = 20;\n/* 136 */ List<EntityLivingBase> entities = player.worldObj.getEntitiesWithinAABB(EntityLivingBase.class, AxisAlignedBB.getBoundingBox(player.posX - searchRange, player.posY - searchRange, player.posZ - searchRange, player.posX + searchRange, player.posY + searchRange, player.posZ + searchRange));\n/* */ \n/* 138 */ if (entities.contains(player)) {\n/* 139 */ entities.remove(player);\n/* */ }\n/* 141 */ if (count < getMaxItemUseDuration(stack) - 20) {\n/* 142 */ for (int counter = entities.size() - 1; counter >= 0; counter--) {\n/* 143 */ if (player.getDistanceToEntity((Entity)entities.get(counter)) <= 3.0F && \n/* 144 */ WandManager.consumeVisFromInventory(player, (new AspectList()).add(Aspect.FIRE, (int)(150.0F * RelicsConfigHandler.soulTomeVisMult)).add(Aspect.ENTROPY, (int)(120.0F * RelicsConfigHandler.soulTomeVisMult)))) {\n/* */ \n/* 146 */ EntityLivingBase thrownEntity = entities.get(counter);\n/* */ \n/* 148 */ Vector3 entityVec = Vector3.fromEntityCenter((Entity)thrownEntity);\n/* 149 */ Vector3 playerVec = Vector3.fromEntityCenter((Entity)player);\n/* */ \n/* 151 */ Vector3 diff = entityVec.copy().sub(playerVec).multiply((1.0F / player.getDistanceToEntity((Entity)thrownEntity) * 3.0F));\n/* */ \n/* 153 */ float curve = (float)(1.0D / player.getDistance(entityVec.x, entityVec.y, entityVec.z) * 8.0D);\n/* */ \n/* 155 */ if (!player.worldObj.isRemote)\n/* 156 */ for (int counterZ = 0; counterZ <= 3; counterZ++) {\n/* 157 */ Main.proxy.lightning(player.worldObj, player.posX, player.posY + 1.0D, player.posZ, entityVec.x, entityVec.y, entityVec.z, 40, curve, (int)(player.getDistance(entityVec.x, entityVec.y, entityVec.z) * 6.0D), 0, 0.075F);\n/* */ } \n/* 159 */ player.worldObj.playSoundAtEntity((Entity)player, \"thaumcraft:zap\", 1.0F, 0.8F);\n/* */ \n/* 161 */ thrownEntity.attackEntityFrom((DamageSource)new DamageRegistryHandler.DamageSourceTLightning((Entity)player), (float)(20.0D + 80.0D * Math.random()));\n/* */ \n/* 163 */ thrownEntity.motionX = diff.x;\n/* 164 */ thrownEntity.motionY = diff.y + 1.0D;\n/* 165 */ thrownEntity.motionZ = diff.z;\n/* */ } \n/* */ } \n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 195 */ this; this; this; this; if ((((count < getMaxItemUseDuration(stack) - 20) ? 1 : 0) & ((count % 4 == 0) ? 1 : 0)) != 0 && WandManager.consumeVisFromInventory(player, (new AspectList()).add(Aspect.EARTH, TerraCost).add(Aspect.AIR, AerCost).add(Aspect.FIRE, IgnisCost).add(Aspect.ENTROPY, PerditioCost))) {\n/* */ \n/* 197 */ EntityLivingBase randomEntity = null;\n/* */ \n/* 199 */ if (entities.size() > 0) {\n/* 200 */ randomEntity = entities.get((int)(entities.size() * Math.random()));\n/* */ }\n/* 202 */ if ((((randomEntity != null) ? 1 : 0) & (!player.worldObj.isRemote ? 1 : 0)) != 0) {\n/* */ \n/* 204 */ float soulDamage = randomEntity.getMaxHealth() / RelicsConfigHandler.soulTomeDivisor;\n/* */ \n/* 206 */ if (soulDamage > 20.0F) {\n/* 207 */ soulDamage = 20.0F;\n/* 208 */ } else if (soulDamage < 1.0F) {\n/* 209 */ soulDamage = 1.0F;\n/* */ } \n/* 211 */ randomEntity.attackEntityFrom((DamageSource)new DamageRegistryHandler.DamageSourceSoulDrain((Entity)player), soulDamage);\n/* 212 */ spawnSoul(player.worldObj, randomEntity, (EntityLivingBase)player);\n/* */ } \n/* */ } \n/* */ }", "public void dropBlockAsItemWithChance(World var1, int var2, int var3, int var4, int var5, float var6, int var7)\n {\n super.dropBlockAsItemWithChance(var1, var2, var3, var4, var5, var6, var7);\n }", "float getBonusItemDrop();", "void dropHandler() {\n if (tickSpeed < 0) {\n if((int)random(1,6) == 1){ //every 6 medkits the handler drops a minigun\n Sprite mg = new Sprite(minigun);\n mg.moveToPoint(random(0,2048), random(0, 2048)); //moves drop to random point\n minigunDrop.add(mg);\n tickSpeed = (int)random(100,500);\n }else if((int)random(1,4) == 1){ //every 4 medkits the handler drops a coilgun\n Sprite cg = new Sprite(coilgun);\n cg.moveToPoint(random(0,2048), random(0,2048)); //moves drop to random point\n coilgunDrop.add(cg);\n tickSpeed = (int)random(100,500); //changes \n }\n else {\n \n \n Medkit hp = new Medkit();\n hp.med.moveToPoint(random(0, 2048), random(0, 2048));\n\n health.add(hp);\n\n tickSpeed = (int)random(100,500);\n }\n }\n tickSpeed--;\n for (Medkit hp: health) {\n hp.med.display();\n hp.timer--;\n\n }\n for (Sprite mg: minigunDrop){\n mg.display();\n }\n for (Sprite cg: coilgunDrop){\n cg.display();\n }\n // e.forward(5);\n}", "void dropItem(Command command) {\n HashMap newInventory = inventory.getInventory();\n Iterator iterator = newInventory.entrySet().iterator();\n String seeItem;\n// int indexItem = -1;\n String nameOfItem = \"\";\n String dropFromInventory = \"debug\";\n\n while (iterator.hasNext()) {\n HashMap.Entry liste = (HashMap.Entry) iterator.next();\n String itemName = (String) liste.getKey();\n if (itemName.equalsIgnoreCase(command.getSecondWord())) {\n dropFromInventory = itemName;\n nameOfItem = itemName;\n break;\n }\n }\n if (!nameOfItem.equals(\"\")) {\n itemLocation.addItem(currentRoom, new PickableItem(nameOfItem, inventory.getItemWeight(nameOfItem), inventory.getUseable(nameOfItem)));\n inventory.removeItemInventory(nameOfItem);\n System.out.println(\"You have dropped: \" + nameOfItem);\n\n } else {\n System.out.println(\"Can't drop item that isn't in inventory \" + command.getSecondWord());\n }\n }", "@EventHandler\n void OnEntityDeath(EntityDeathEvent e){\n Entity killer = e.getEntity().getKiller();\n int exp = e.getDroppedExp();\n if(killer instanceof Player){\n GuildMCFunctions functions = new GuildMCFunctions();\n functions.spawnExperiencesInfos((Player) killer, exp);\n }\n\n }", "private void dropped(HeroItem item, Unit unit) {\n if (ItemMaster.isBreakable(item)) {\n item.broken(); // remove from game?\n if (item instanceof QuickItem) {\n QuickItem quickItemObj = (QuickItem) item;\n if (quickItemObj.isConcoction()) {\n quickItemObj.activate(Ref.getSelfTargetingRefCopy(unit)); // setForceTarget(true)\n }\n }\n } else {\n unit.getGame().getDroppedItemManager().itemFalls(unit.getCoordinates(), item);\n }\n }", "public void OnDamage(AI ai, int aTK, float f) {\n\tif(DamagedTimer < 0.8f)\n\t\treturn;\n\tvel.x = f;\n\tvel.y = 3;\n\tDamagedTimer = 0;\n\tgrounded = false;\n\taTK -= (getDEF()*0.8f);\n\tif(aTK <= 0)\n\t\taTK = 1;\n\tHP -= aTK;\n\tInventory.CurrentInventory.dmgTxts.add(new dmgText(pos.x, pos.y+1, aTK));\n\t\n\tSoundManager.PlaySound(\"playerHurt\",3);\n\t\n\t\n}", "public void randomEvent(){\n /*Pick a random number dictating the events that could happen.\n * 1: New gun for player\n * 2: Paying Liu Yuen\n * 3: Repairing the Ship\n */\n RandomEventLogic randomEventLogic = new RandomEventLogic(getPlayer());\n int[] randEvent = randomEventLogic.randEvent();\n int eventNumber = randEvent[0];\n int itemPrice = randEvent[1];\n\n if(eventNumber == 1){\n System.out.println(\"\\nA vendor is selling a gun for $\" + itemPrice + \" for a gun?\");\n }\n if(eventNumber == 2){\n System.out.println(\"\\nLiu Yuen asks $\" + itemPrice + \" in donation to the temple of Tin Hau, the Sea Goddess\");\n }\n if(eventNumber == 3){\n System.out.println(\"\\nMc Henry from the Hong Kong shipyard has arrived,\\nwould be willing to repair your ship for $\" + itemPrice);\n }\n\n //Only runs if the player doesn't have enough space and is given a gun\n if((eventNumber == 1 && getCargoSpace() < 10)){\n TaipanShopText taipanShopText = new TaipanShopText(getPlayer());\n taipanShopText.shop();\n }\n //Only runs if the player has 100 or greater HP and they got the ship repair man\n if((eventNumber == 3 && getPlayer().getHP() >= 100)){\n TaipanShopText taipanShopText = new TaipanShopText(getPlayer());\n taipanShopText.shop();\n }\n\n //Runs for as long as the player doesn't decide if they want to pay\n while(true){\n System.out.println(\"Would you like to pay? (Y)es or (N)o\");\n Scanner keyboard = new Scanner(System.in);\n String input = keyboard.next();\n if (input.equalsIgnoreCase(\"Y\") && getPlayer().getMoney() > itemPrice) {\n //Buy Guns\n if (eventNumber == 1 && (getCargoSpace() >= 10)) {\n setGuns(getPlayer().getGuns() + 1);\n setMoney(getPlayer().getMoney() - itemPrice);\n\n TaipanShopText taipanShopText = new TaipanShopText(getPlayer());\n taipanShopText.shop();\n }\n\n //Liu Yuen\n if (eventNumber == 2) {\n setAttackingShips(false);\n setMoney(getPlayer().getMoney() - itemPrice);\n\n TaipanShopText taipanShopText = new TaipanShopText(getPlayer());\n taipanShopText.shop();\n }\n\n //Ship Repair\n if (eventNumber == 3 && getPlayer().getHP() != 100) {\n setHP(100);\n setMoney(getPlayer().getMoney() - itemPrice);\n\n TaipanShopText taipanShopText = new TaipanShopText(getPlayer());\n taipanShopText.shop();\n }\n\n\n }\n else {\n System.out.println(\"Sorry you don't have enough money\");\n }\n //If the player decides to leave then it will send them back to TaipanShop\n if(input.equalsIgnoreCase(\"N\")){\n System.out.println(\"Aye aye Taipan, we'll send them off!\\n\");\n TaipanShopText taipanShopText = new TaipanShopText(getPlayer());\n taipanShopText.shop();\n }\n }\n\n }", "private RewardItem calculateCategorizedRewardItem(final L2PcInstance lastAttacker, final L2DropCategory categoryDrops, final int levelModifier)\n\t{\n\t\tif (categoryDrops == null)\n\t\t{\n\t\t\treturn null;\n\t\t}\n\t\t\n\t\tif (Config.HIGH_RATE_SERVER_DROPS && categoryDrops.getCategoryType() != 0)\n\t\t{ // it's not adena-->check if drop is quest or is an epic jewel\n\t\t\t\n\t\t\tboolean to_drop = false;\n\t\t\t\n\t\t\tfor (final L2DropData dd : categoryDrops.getAllDrops())\n\t\t\t{\n\t\t\t\t\n\t\t\t\t// quest_drop,ant queen,orfen,core,frintezza,baium,antharas,valakas,zaken, seal Stones, life stones\n\t\t\t\tif (dd.isQuestDrop() || dd.getItemId() == 6660 || dd.getItemId() == 6661 || dd.getItemId() == 6662 || dd.getItemId() == 8191 || dd.getItemId() == 6658 || dd.getItemId() == 6656 || dd.getItemId() == 6657 || dd.getItemId() == 6659 || dd.getItemId() >= 6360 && dd.getItemId() <= 6362 || dd.getItemId() >= 8723 && dd.getItemId() <= 8762)\n\t\t\t\t{\n\t\t\t\t\t// if epic jewel, return just 1 from raid\n\t\t\t\t\tto_drop = true;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\tif (!to_drop)\n\t\t\t{\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\t// Get default drop chance for the category (that's the sum of chances for all items in the category)\n\t\t// keep track of the base category chance as it'll be used later, if an item is drop from the category.\n\t\t// for everything else, use the total \"categoryDropChance\"\n\t\tfinal int basecategoryDropChance = categoryDrops.getCategoryChance();\n\t\tint categoryDropChance = basecategoryDropChance;\n\t\t\n\t\tint deepBlueDrop = 1;\n\t\t\n\t\tif (Config.DEEPBLUE_DROP_RULES)\n\t\t{\n\t\t\tif (levelModifier > 0)\n\t\t\t{\n\t\t\t\t// We should multiply by the server's drop rate, so we always get a low chance of drop for deep blue mobs.\n\t\t\t\t// NOTE: This is valid only for adena drops! Others drops will still obey server's rate\n\t\t\t\tdeepBlueDrop = 3;\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (deepBlueDrop == 0)\n\t\t{\n\t\t\tdeepBlueDrop = 1;\n\t\t}\n\t\t\n\t\t// Check if we should apply our maths so deep blue mobs will not drop that easy\n\t\tif (Config.DEEPBLUE_DROP_RULES)\n\t\t{\n\t\t\tcategoryDropChance = (categoryDropChance - categoryDropChance * levelModifier / 100) / deepBlueDrop;\n\t\t}\n\t\t\n\t\t// Applies Drop rates\n\t\tif (this instanceof L2RaidBossInstance)\n\t\t{\n\t\t\tcategoryDropChance *= Config.ITEMS_RAID;\n\t\t}\n\t\telse if (this instanceof L2GrandBossInstance)\n\t\t{\n\t\t\tcategoryDropChance *= Config.ITEMS_BOSS;\n\t\t}\n\t\telse if (this instanceof L2MinionInstance)\n\t\t{\n\t\t\tcategoryDropChance *= Config.ITEMS_MINON;\n\t\t}\n\t\telse\n\t\t{\n\t\t\tcategoryDropChance *= Config.RATE_DROP_ITEMS;\n\t\t}\n\t\t\n\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t{\n\t\t\tcategoryDropChance *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t}\n\t\t\n\t\t// Set our limits for chance of drop\n\t\tif (categoryDropChance < 1)\n\t\t{\n\t\t\tcategoryDropChance = 1;\n\t\t}\n\t\t\n\t\t// Check if an Item from this category must be dropped\n\t\tif (Rnd.get(L2DropData.MAX_CHANCE) < categoryDropChance)\n\t\t{\n\t\t\tL2DropData drop = categoryDrops.dropOne(isRaid());\n\t\t\t\n\t\t\tif (drop == null)\n\t\t\t{\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\t\n\t\t\t// Now decide the quantity to drop based on the rates and penalties. To get this value\n\t\t\t// simply divide the modified categoryDropChance by the base category chance. This\n\t\t\t// results in a chance that will dictate the drops amounts: for each amount over 100\n\t\t\t// that it is, it will give another chance to add to the min/max quantities.\n\t\t\t//\n\t\t\t// For example, If the final chance is 120%, then the item should drop between\n\t\t\t// its min and max one time, and then have 20% chance to drop again. If the final\n\t\t\t// chance is 330%, it will similarly give 3 times the min and max, and have a 30%\n\t\t\t// chance to give a 4th time.\n\t\t\t// At least 1 item will be dropped for sure. So the chance will be adjusted to 100%\n\t\t\t// if smaller.\n\t\t\t\n\t\t\t// int dropChance = drop.getChance();\n\t\t\tint dropChance = 0;\n\t\t\t\n\t\t\tswitch (drop.getItemId())\n\t\t\t{\n\t\t\t\tcase 6662:\n\t\t\t\t{ // core ring\n\t\t\t\t\tif (Config.CORE_RING_CHANCE > 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tdropChance = 10000 * Config.CORE_RING_CHANCE;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tdropChance = drop.getChance();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 6661:\n\t\t\t\t{ // orfen earring\n\t\t\t\t\tif (Config.ORFEN_EARRING_CHANCE > 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tdropChance = 10000 * Config.ORFEN_EARRING_CHANCE;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tdropChance = drop.getChance();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 6659:\n\t\t\t\t{ // zaken earring\n\t\t\t\t\tif (Config.ZAKEN_EARRING_CHANCE > 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tdropChance = 10000 * Config.ZAKEN_EARRING_CHANCE;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tdropChance = drop.getChance();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 6660:\n\t\t\t\t{ // aq ring\n\t\t\t\t\tif (Config.QA_RING_CHANCE > 0)\n\t\t\t\t\t{\n\t\t\t\t\t\tdropChance = 10000 * Config.QA_RING_CHANCE;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tdropChance = drop.getChance();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t{\n\t\t\t\t\tdropChance = drop.getChance();\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (drop.getItemId() == 57)\n\t\t\t{\n\t\t\t\tif (this instanceof L2RaidBossInstance)\n\t\t\t\t{\n\t\t\t\t\tdropChance *= Config.ADENA_RAID;\n\t\t\t\t}\n\t\t\t\telse if (this instanceof L2GrandBossInstance)\n\t\t\t\t{\n\t\t\t\t\tdropChance *= Config.ADENA_BOSS;\n\t\t\t\t}\n\t\t\t\telse if (this instanceof L2MinionInstance)\n\t\t\t\t{\n\t\t\t\t\tdropChance *= Config.ADENA_MINON;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tdropChance *= Config.RATE_DROP_ADENA;\n\t\t\t\t\tif (lastAttacker.isVIP())\n\t\t\t\t\t{\n\t\t\t\t\t\tdropChance *= Config.VIP_ADENA_RATE;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tif (this instanceof L2RaidBossInstance)\n\t\t\t\t{\n\t\t\t\t\tdropChance *= Config.ITEMS_RAID;\n\t\t\t\t}\n\t\t\t\telse if (this instanceof L2GrandBossInstance)\n\t\t\t\t{\n\t\t\t\t\tdropChance *= Config.ITEMS_BOSS;\n\t\t\t\t}\n\t\t\t\telse if (this instanceof L2MinionInstance)\n\t\t\t\t{\n\t\t\t\t\tdropChance *= Config.ITEMS_MINON;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tdropChance *= Config.RATE_DROP_ITEMS;\n\t\t\t\t\tif (lastAttacker.isVIP())\n\t\t\t\t\t{\n\t\t\t\t\t\tdropChance *= Config.VIP_DROP_RATE;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t{\n\t\t\t\tdropChance *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t}\n\t\t\t\n\t\t\tif (dropChance < L2DropData.MAX_CHANCE)\n\t\t\t{\n\t\t\t\tdropChance = L2DropData.MAX_CHANCE;\n\t\t\t}\n\t\t\t\n\t\t\t// Get min and max Item quantity that can be dropped in one time\n\t\t\tfinal int min = drop.getMinDrop();\n\t\t\tfinal int max = drop.getMaxDrop();\n\t\t\t\n\t\t\t// Get the item quantity dropped\n\t\t\tint itemCount = 0;\n\t\t\t\n\t\t\tif (!Config.MULTIPLY_QUANTITY_BY_CHANCE && dropChance > L2DropData.MAX_CHANCE && drop.getItemId() != 57)\n\t\t\t{\n\t\t\t\tdropChance = L2DropData.MAX_CHANCE;\n\t\t\t}\n\t\t\t\n\t\t\t// Count and chance adjustment for high rate servers\n\t\t\tif (dropChance > L2DropData.MAX_CHANCE && !Config.PRECISE_DROP_CALCULATION)\n\t\t\t{\n\t\t\t\tfinal int multiplier = dropChance / L2DropData.MAX_CHANCE;\n\t\t\t\t\n\t\t\t\tif (min < max)\n\t\t\t\t{\n\t\t\t\t\titemCount += Rnd.get(min * multiplier, max * multiplier);\n\t\t\t\t}\n\t\t\t\telse if (min == max)\n\t\t\t\t{\n\t\t\t\t\titemCount += min * multiplier;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\titemCount += multiplier;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tdropChance = dropChance % L2DropData.MAX_CHANCE;\n\t\t\t}\n\t\t\t\n\t\t\t// Check if the Item must be dropped\n\t\t\tfinal int random = Rnd.get(L2DropData.MAX_CHANCE);\n\t\t\t\n\t\t\twhile (random < dropChance)\n\t\t\t{\n\t\t\t\t// Get the item quantity dropped\n\t\t\t\tif (min < max)\n\t\t\t\t{\n\t\t\t\t\titemCount += Rnd.get(min, max);\n\t\t\t\t}\n\t\t\t\telse if (min == max)\n\t\t\t\t{\n\t\t\t\t\titemCount += min;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\titemCount++;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t// Prepare for next iteration if dropChance > L2DropData.MAX_CHANCE\n\t\t\t\tdropChance -= L2DropData.MAX_CHANCE;\n\t\t\t}\n\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE)\n\t\t\t{\n\t\t\t\tif ((drop.getItemId() == 57 || drop.getItemId() >= 6360 && drop.getItemId() <= 6362) && isChampion())\n\t\t\t\t{\n\t\t\t\t\titemCount *= Config.L2JMOD_CHAMPION_ADENAS_REWARDS;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (drop.getItemId() >= 6360 && drop.getItemId() <= 6362)\n\t\t\t{\n\t\t\t\titemCount *= Config.RATE_DROP_SEAL_STONES;\n\t\t\t}\n\t\t\t\n\t\t\tif (itemCount > 0)\n\t\t\t{\n\t\t\t\treturn new RewardItem(drop.getItemId(), itemCount);\n\t\t\t}\n\t\t\telse if (itemCount == 0 && Config.DEBUG)\n\t\t\t{\n\t\t\t\tLOGGER.debug(\"Roll produced 0 items to drop...\");\n\t\t\t}\n\t\t\t\n\t\t\tdrop = null;\n\t\t}\n\t\treturn null;\n\t}", "public void breakBlock(World world, int x, int y, int z, Block par5, int par6)\r\n/* 186: */ {\r\n/* 187:209 */ if ((world.getBlock(x, y, z) != FMPBase.getFMPBlockId()) && \r\n/* 188:210 */ ((world.getTileEntity(x, y, z) instanceof TileEntityTransferNode)))\r\n/* 189: */ {\r\n/* 190:211 */ TileEntityTransferNode tile = (TileEntityTransferNode)world.getTileEntity(x, y, z);\r\n/* 191:213 */ if (!tile.getUpgrades().isEmpty()) {\r\n/* 192:214 */ for (int i = 0; i < tile.getUpgrades().size(); i++)\r\n/* 193: */ {\r\n/* 194:215 */ ItemStack itemstack = (ItemStack)tile.getUpgrades().get(i);\r\n/* 195:216 */ float f = this.random.nextFloat() * 0.8F + 0.1F;\r\n/* 196:217 */ float f1 = this.random.nextFloat() * 0.8F + 0.1F;\r\n/* 197: */ EntityItem entityitem;\r\n/* 198:220 */ for (float f2 = this.random.nextFloat() * 0.8F + 0.1F; itemstack.stackSize > 0; world.spawnEntityInWorld(entityitem))\r\n/* 199: */ {\r\n/* 200:221 */ int k1 = this.random.nextInt(21) + 10;\r\n/* 201:223 */ if (k1 > itemstack.stackSize) {\r\n/* 202:224 */ k1 = itemstack.stackSize;\r\n/* 203: */ }\r\n/* 204:227 */ itemstack.stackSize -= k1;\r\n/* 205:228 */ entityitem = new EntityItem(world, x + f, y + f1, z + f2, new ItemStack(itemstack.getItem(), k1, itemstack.getItemDamage()));\r\n/* 206:229 */ float f3 = 0.05F;\r\n/* 207:230 */ entityitem.motionX = ((float)this.random.nextGaussian() * f3);\r\n/* 208:231 */ entityitem.motionY = ((float)this.random.nextGaussian() * f3 + 0.2F);\r\n/* 209:232 */ entityitem.motionZ = ((float)this.random.nextGaussian() * f3);\r\n/* 210:234 */ if (itemstack.hasTagCompound()) {\r\n/* 211:235 */ entityitem.getEntityItem().setTagCompound((NBTTagCompound)itemstack.getTagCompound().copy());\r\n/* 212: */ }\r\n/* 213: */ }\r\n/* 214: */ }\r\n/* 215: */ }\r\n/* 216:241 */ if ((tile instanceof TileEntityTransferNodeInventory))\r\n/* 217: */ {\r\n/* 218:242 */ TileEntityTransferNodeInventory tileentity = (TileEntityTransferNodeInventory)tile;\r\n/* 219: */ \r\n/* 220:244 */ ItemStack itemstack = tileentity.getStackInSlot(0);\r\n/* 221:246 */ if (itemstack != null)\r\n/* 222: */ {\r\n/* 223:247 */ float f = this.random.nextFloat() * 0.8F + 0.1F;\r\n/* 224:248 */ float f1 = this.random.nextFloat() * 0.8F + 0.1F;\r\n/* 225: */ EntityItem entityitem;\r\n/* 226:251 */ for (float f2 = this.random.nextFloat() * 0.8F + 0.1F; itemstack.stackSize > 0; world.spawnEntityInWorld(entityitem))\r\n/* 227: */ {\r\n/* 228:252 */ int k1 = this.random.nextInt(21) + 10;\r\n/* 229:254 */ if (k1 > itemstack.stackSize) {\r\n/* 230:255 */ k1 = itemstack.stackSize;\r\n/* 231: */ }\r\n/* 232:258 */ itemstack.stackSize -= k1;\r\n/* 233:259 */ entityitem = new EntityItem(world, x + f, y + f1, z + f2, new ItemStack(itemstack.getItem(), k1, itemstack.getItemDamage()));\r\n/* 234:260 */ float f3 = 0.05F;\r\n/* 235:261 */ entityitem.motionX = ((float)this.random.nextGaussian() * f3);\r\n/* 236:262 */ entityitem.motionY = ((float)this.random.nextGaussian() * f3 + 0.2F);\r\n/* 237:263 */ entityitem.motionZ = ((float)this.random.nextGaussian() * f3);\r\n/* 238:265 */ if (itemstack.hasTagCompound()) {\r\n/* 239:266 */ entityitem.getEntityItem().setTagCompound((NBTTagCompound)itemstack.getTagCompound().copy());\r\n/* 240: */ }\r\n/* 241: */ }\r\n/* 242: */ }\r\n/* 243:271 */ world.func_147453_f(x, y, z, par5);\r\n/* 244: */ }\r\n/* 245: */ }\r\n/* 246:276 */ super.breakBlock(world, x, y, z, par5, par6);\r\n/* 247: */ }", "private static void customItems(ItemDefinition itemDef) {\n\n\t\tswitch (itemDef.id) {\n\n\t\tcase 11864:\n\t\tcase 11865:\n\t\tcase 19639:\n\t\tcase 19641:\n\t\tcase 19643:\n\t\tcase 19645:\n\t\tcase 19647:\n\t\tcase 19649:\n\t\tcase 23073:\n\t\tcase 23075:\n\t\t\titemDef.equipActions[2] = \"Log\";\n\t\t\titemDef.equipActions[1] = \"Check\";\n\t\t\tbreak;\n\n\t\tcase 13136:\n\t\t\titemDef.equipActions[2] = \"Elidinis\";\n\t\t\titemDef.equipActions[1] = \"Kalphite Hive\";\n\t\t\tbreak;\n\t\tcase 2550:\n\t\t\titemDef.equipActions[2] = \"Check\";\n\t\t\tbreak;\n\n\t\tcase 1712:\n\t\tcase 1710:\n\t\tcase 1708:\n\t\tcase 1706:\n\t\t\titemDef.equipActions[1] = \"Edgeville\";\n\t\t\titemDef.equipActions[2] = \"Karamja\";\n\t\t\titemDef.equipActions[3] = \"Draynor\";\n\t\t\titemDef.equipActions[4] = \"Al-Kharid\";\n\t\t\tbreak;\n\n\t\tcase 22000:\n\t\t\titemDef.name = \"Lava partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"A lava partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 22001:\n\t\t\titemDef.name = \"Infernal partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"An Infernal partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 2552:\n\t\tcase 2554:\n\t\tcase 2556:\n\t\tcase 2558:\n\t\tcase 2560:\n\t\tcase 2562:\n\t\tcase 2564:\n\t\tcase 2566: // Ring of duelling\n\t\t\titemDef.equipActions[2] = \"Shantay Pass\";\n\t\t\titemDef.equipActions[1] = \"Clan wars\";\n\t\t\tbreak;\n\n\t\tcase 21307:\n\t\t\titemDef.name = \"Pursuit crate\";\n\t\t\tbreak;\n\n\t\tcase 12792:\n\t\t\titemDef.name = \"Graceful recolor kit\";\n\t\t\tbreak;\n\n\t\tcase 12022:\n\t\t\titemDef.name = \"Bandos Casket\";\n\t\t\titemDef.description = \"100% chance for an item off the Bandos gwds rare drop table.\";\n\t\t\tbreak;\n\n\t\tcase 12024:\n\t\t\titemDef.name = \"Armadyl Casket\";\n\t\t\titemDef.description = \"100% chance for an item off the Armadyl gwds rare drop table.\";\n\t\t\tbreak;\n\n\t\tcase 12026:\n\t\t\titemDef.name = \"Saradomin Casket\";\n\t\t\titemDef.description = \"100% chance for an item off the Saradomin gwds rare drop table.\";\n\t\t\tbreak;\n\n\t\tcase 12028:\n\t\t\titemDef.name = \"Zamorak Casket\";\n\t\t\titemDef.description = \"100% chance for an item off the Zamorak gwds rare drop table.\";\n\t\t\tbreak;\n\n\t\tcase 964:\n\t\t\titemDef.name = \"Pet Petie\";\n\t\t\tbreak;\n\n\t\tcase 20853:\n\t\t\titemDef.name = \"Deep Sea Bait\";\n\t\t\titemDef.stackable = true;\n\t\t\tbreak;\n\n\t\t/*\n\t\t * case 17014: itemDef.name = \"Dragon flail\"; itemDef.modelId = 50083;\n\t\t * itemDef.modelZoom = 1440; itemDef.modelRotation2 = 272;\n\t\t * itemDef.modelRotation1 = 352; itemDef.modelOffset1 = 32;\n\t\t * //itemDef.modelOffset2 = 0; itemDef.maleModel = 50083; itemDef.femaleModel =\n\t\t * 50083; itemDef.anInt164 = -1; itemDef.anInt188 = -1; itemDef.aByte205 = -8;\n\t\t * itemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t * itemDef.inventoryOptions = new String[] { \"Wear\", null, null, null, \"Drop\" };\n\t\t * itemDef.description = \"An Ancient Dragon Flail.\"; break;\n\t\t */\n\n\t\tcase 33272:\n\t\t\titemDef.name = \"Justiciar's Longsword\";\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modelId = 65472;\n\t\t\titemDef.modelZoom = 1726;\n\t\t\titemDef.modelRotation1 = 1576;\n\t\t\titemDef.modelRotation2 = 242;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\t// itemDef.anInt204 = 0;\n\t\t\t// itemDef.aByte205 = -12;\n\t\t\t// itemDef.aByte154 = 0;\n\t\t\titemDef.maleModel = 65465;\n\t\t\titemDef.femaleModel = 65465;\n\t\t\titemDef.description = \"An ancient longsword received from the Trial of Flames.\";\n\t\t\tbreak;\n\n\t\tcase 33168:\n\t\t\titemDef.name = \"Justiciar kiteshield\";\n\t\t\titemDef.modelId = 65471;\n\t\t\titemDef.modelZoom = 1600;\n\t\t\titemDef.modelRotation2 = 250;\n\t\t\titemDef.modelRotation1 = 300;\n\t\t\titemDef.modelOffset1 = -4;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.maleModel = 65473;\n\t\t\titemDef.femaleModel = 65474;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"An ancient kiteshield. Part of the Justiciar set.\";\n\t\t\tbreak;\n\n\t\tcase 2996:\n\t\t\titemDef.name = \"PKP Ticket\";\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.description = \"Exchange this for a PK Point.\";\n\t\t\tbreak;\n\t\tcase 13226:\n\t\t\titemDef.name = \"Herb Sack\";\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.description = \"A sack for storing grimy herbs.\";\n\t\t\tbreak;\n\t\tcase 13346:\n\t\t\titemDef.name = \"Raid Mystery Box\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Open for chances to receive Raid items & other awesome rewards.\";\n\t\t\tbreak;\n\t\tcase 8800:\n\t\t\titemDef.name = \"Donator Tokens\";\n\t\t\titemDef.modelId = 31624;\n\t\t\t// itemDef.stackAmounts = new int[] { 2, 3, 50, 100, 500000, 1000000, 2500000,\n\t\t\t// 10000000, 100000000, 0 };//amount the model will change at\n\t\t\t// itemDef.stackIDs = new int[] { 8801, 8802, 8803, 8804, 8805, 8806, 8807,\n\t\t\t// 8808, 8809, 0 };//new item id to grab the model from\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 853;\n\t\t\titemDef.modelRotation2 = 1885;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8801:\n\t\t\titemDef.name = \"Donator Tokens\";\n\t\t\titemDef.modelId = 15344;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8802:\n\t\t\titemDef.name = \"Donator Tokens\";\n\t\t\titemDef.modelId = 15345;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8803:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15346;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8804:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15347;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8805:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15348;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8806:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15349;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8807:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15350;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8808:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15351;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8809:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15352;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 15098:\n\t\t\titemDef.name = \"Dice (up to 100)\";\n\t\t\titemDef.description = \"A 100-sided dice.\";\n\t\t\titemDef.modelId = 31223;\n\t\t\titemDef.modelZoom = 1104;\n\t\t\titemDef.modelRotation2 = 215;\n\t\t\titemDef.modelRotation1 = 94;\n\t\t\titemDef.modelOffset2 = -5;\n\t\t\titemDef.modelOffset1 = -18;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Public-roll\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.name = \"Dice (up to 100)\";\n\t\t\titemDef.anInt196 = 15;\n\t\t\titemDef.anInt184 = 25;\n\t\t\tbreak;\n\n\t\tcase 32991:\n\t\t\titemDef.name = \"Divine spirit shield\";\n\t\t\titemDef.description = \"An ethereal shield with an divine sigil attached to it.\";\n\t\t\titemDef.modelId = 50001;\n\t\t\titemDef.maleModel = 50002;\n\t\t\titemDef.femaleModel = 50002;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelRotation2 = 1050;\n\t\t\titemDef.modelRotation1 = 396;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\tbreak;\n\t\tcase 32992:\n\t\t\titemDef.name = \"Rainbow spirit shield\";\n\t\t\titemDef.description = \"An ethereal shield with all 4 sigils attached to it.\";\n\t\t\titemDef.modelId = 50004;\n\t\t\titemDef.maleModel = 50005;\n\t\t\titemDef.femaleModel = 50005;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelRotation2 = 1050;\n\t\t\titemDef.modelRotation1 = 396;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 32993:\n\t\t\titemDef.name = \"Divine sigil\";\n\t\t\titemDef.description = \"A sigil in the shape of a divine symbol.\";\n\t\t\titemDef.modelId = 50003;\n\t\t\titemDef.modelZoom = 848;\n\t\t\titemDef.modelRotation1 = 267;\n\t\t\titemDef.modelRotation2 = 138;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33060:\n\t\t\titemDef.name = \"Barrows Sword\";\n\t\t\titemDef.description = \"A sword glowing with otherworldy energy.\";\n\t\t\titemDef.modelId = 22325;\n\t\t\titemDef.maleModel = 50010;\n\t\t\titemDef.femaleModel = 50010;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelRotation2 = 1050;\n\t\t\titemDef.modelRotation1 = 396;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\tbreak;\n\t\tcase 32994:\n\t\t\titemDef.name = \"Statius's platebody\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42602;\n\t\t\titemDef.maleModel = 35951;\n\t\t\titemDef.femaleModel = 35964;\n\t\t\titemDef.modelZoom = 1312;\n\t\t\titemDef.modelRotation1 = 272;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -2;\n\t\t\titemDef.modelOffset2 = 39;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 32995:\n\t\t\titemDef.name = \"Statius's platelegs\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42590;\n\t\t\titemDef.maleModel = 35947;\n\t\t\titemDef.femaleModel = 35961;\n\t\t\titemDef.modelZoom = 1625;\n\t\t\titemDef.modelRotation1 = 355;\n\t\t\titemDef.modelRotation2 = 2046;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -11;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 32996:\n\t\t\titemDef.name = \"Statius's full helm\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42596;\n\t\t\titemDef.maleModel = 35943;\n\t\t\titemDef.femaleModel = 35958;\n\t\t\titemDef.modelZoom = 789;\n\t\t\titemDef.modelRotation1 = 96;\n\t\t\titemDef.modelRotation2 = 2039;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -7;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 32997:\n\t\t\titemDef.name = \"Statius's warhammer\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42577;\n\t\t\titemDef.maleModel = 35968;\n\t\t\titemDef.femaleModel = 35968;\n\t\t\titemDef.modelZoom = 1360;\n\t\t\titemDef.modelRotation1 = 507;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 7;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 32998:\n\t\t\titemDef.name = \"Vesta's chainbody\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42593;\n\t\t\titemDef.maleModel = 35953;\n\t\t\titemDef.femaleModel = 35965;\n\t\t\titemDef.modelZoom = 1440;\n\t\t\titemDef.modelRotation1 = 545;\n\t\t\titemDef.modelRotation2 = 2;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 32999:\n\t\t\titemDef.name = \"Vesta's plateskirt\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42581;\n\t\t\titemDef.maleModel = 35950;\n\t\t\titemDef.femaleModel = 35960;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = 11;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33000:\n\t\t\titemDef.name = \"Vesta's longsword\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42597;\n\t\t\titemDef.maleModel = 35969;\n\t\t\titemDef.femaleModel = 35969;\n\t\t\titemDef.modelZoom = 1744;\n\t\t\titemDef.modelRotation1 = 738;\n\t\t\titemDef.modelRotation2 = 1985;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.maleOffset = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33001:\n\t\t\titemDef.name = \"Vesta's spear\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42599;\n\t\t\titemDef.maleModel = 35973;\n\t\t\titemDef.femaleModel = 35973;\n\t\t\titemDef.modelZoom = 2022;\n\t\t\titemDef.modelRotation1 = 480;\n\t\t\titemDef.modelRotation2 = 15;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.maleOffset = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33002:\n\t\t\titemDef.name = \"Morrigan's leather body\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42578;\n\t\t\titemDef.maleModel = 35954;\n\t\t\titemDef.femaleModel = 35963;\n\t\t\titemDef.modelZoom = 1440;\n\t\t\titemDef.modelRotation1 = 545;\n\t\t\titemDef.modelRotation2 = 2;\n\t\t\titemDef.modelOffset1 = -2;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33003:\n\t\t\titemDef.name = \"Morrigan's leather chaps\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42603;\n\t\t\titemDef.maleModel = 35948;\n\t\t\titemDef.femaleModel = 35959;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 482;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = 11;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33004:\n\t\t\titemDef.name = \"Morrigan's coif\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42583;\n\t\t\titemDef.maleModel = 35945;\n\t\t\titemDef.femaleModel = 35956;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 537;\n\t\t\titemDef.modelRotation2 = 5;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33005:\n\t\t\titemDef.name = \"Morrigan's javelin\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42592;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.maleModel = 42613;\n\t\t\titemDef.femaleModel = 42613;\n\t\t\titemDef.modelZoom = 1872;\n\t\t\titemDef.modelRotation1 = 282;\n\t\t\titemDef.modelRotation2 = 2009;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.maleOffset = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33006:\n\t\t\titemDef.name = \"Morrigan's throwing axe\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42582;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.maleModel = 42611;\n\t\t\titemDef.femaleModel = 42611;\n\t\t\titemDef.modelZoom = 976;\n\t\t\titemDef.modelRotation1 = 672;\n\t\t\titemDef.modelRotation2 = 2024;\n\t\t\titemDef.modelOffset1 = -5;\n\t\t\titemDef.maleOffset = -8;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33007:\n\t\t\titemDef.name = \"Zuriels robe top\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42591;\n\t\t\titemDef.maleModel = 35952;\n\t\t\titemDef.femaleModel = 35966;\n\t\t\titemDef.modelZoom = 1373;\n\t\t\titemDef.modelRotation1 = 373;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -7;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33008:\n\t\t\titemDef.name = \"Zuriels robe bottom\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42588;\n\t\t\titemDef.maleModel = 35949;\n\t\t\titemDef.femaleModel = 35962;\n\t\t\titemDef.modelZoom = 1697;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33009:\n\t\t\titemDef.name = \"Zuriels hood\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42604;\n\t\t\titemDef.maleModel = 35944;\n\t\t\titemDef.femaleModel = 35957;\n\t\t\titemDef.modelZoom = 720;\n\t\t\titemDef.modelRotation1 = 28;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33010:\n\t\t\titemDef.name = \"Zuriels staff\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42595;\n\t\t\titemDef.maleModel = 35971;\n\t\t\titemDef.femaleModel = 35971;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 366;\n\t\t\titemDef.modelRotation2 = 3;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33011:\n\t\t\titemDef.name = \"Craw's bow (u)\";\n\t\t\titemDef.description = \"This bow once belonged to a formidable follower of Armadyl.\";\n\t\t\titemDef.modelId = 35777;\n\t\t\titemDef.maleModel = 35768;\n\t\t\titemDef.femaleModel = 35768;\n\t\t\titemDef.modelZoom = 1979;\n\t\t\titemDef.modelRotation1 = 1463;\n\t\t\titemDef.modelRotation2 = 510;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33012:\n\t\t\titemDef.name = \"Craw's bow\";\n\t\t\titemDef.description = \"This bow once belonged to a formidable follower of Armadyl.\";\n\t\t\titemDef.modelId = 35777;\n\t\t\titemDef.maleModel = 35769;\n\t\t\titemDef.femaleModel = 35769;\n\t\t\titemDef.modelZoom = 1979;\n\t\t\titemDef.modelRotation1 = 1463;\n\t\t\titemDef.modelRotation2 = 510;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33013:\n\t\t\titemDef.name = \"Thammaron's sceptre (u)\";\n\t\t\titemDef.description = \"A mighty sceptre used in long forgotten battles.\";\n\t\t\titemDef.modelId = 35776;\n\t\t\titemDef.maleModel = 35772;\n\t\t\titemDef.femaleModel = 35772;\n\t\t\titemDef.modelZoom = 2105;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 1020;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33014:\n\t\t\titemDef.name = \"Thammaron's sceptre\";\n\t\t\titemDef.description = \"A mighty sceptre used in long forgotten battles.\";\n\t\t\titemDef.modelId = 35776;\n\t\t\titemDef.maleModel = 35773;\n\t\t\titemDef.femaleModel = 35773;\n\t\t\titemDef.modelZoom = 2105;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 1020;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33015:\n\t\t\titemDef.name = \"Viggora's chainmace (u)\";\n\t\t\titemDef.description = \"An ancient chainmace with a peculiar mechanism that allows for varying attack styles.\";\n\t\t\titemDef.modelId = 35778;\n\t\t\titemDef.maleModel = 35770;\n\t\t\titemDef.femaleModel = 35770;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelRotation1 = 252;\n\t\t\titemDef.modelRotation2 = 944;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33016:\n\t\t\titemDef.name = \"Viggora's chainmace\";\n\t\t\titemDef.description = \"An ancient chainmace with a peculiar mechanism that allows for varying attack styles.\";\n\t\t\titemDef.modelId = 35778;\n\t\t\titemDef.maleModel = 35771;\n\t\t\titemDef.femaleModel = 35771;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelRotation1 = 252;\n\t\t\titemDef.modelRotation2 = 944;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33018:\n\t\t\titemDef.name = \"Amulet of avarice\";\n\t\t\titemDef.description = \"A hauntingly beautiful amulet bearing the shape of a skull.\";\n\t\t\titemDef.modelId = 35779;\n\t\t\titemDef.maleModel = 35766;\n\t\t\titemDef.femaleModel = 35766;\n\t\t\titemDef.modelZoom = 420;\n\t\t\titemDef.modelRotation1 = 191;\n\t\t\titemDef.modelRotation2 = 86;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33019:\n\t\t\titemDef.name = \"Completionist cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modelId = 65270;\n\t\t\titemDef.maleModel = 65297;\n\t\t\titemDef.femaleModel = 65316;\n\t\t\titemDef.modelZoom = 1316;\n\t\t\titemDef.modelRotation1 = 252;\n\t\t\titemDef.modelRotation2 = 1020;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 24;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33020:\n\t\t\titemDef.name = \"Completionist cape (t)\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modelId = 65258;\n\t\t\titemDef.maleModel = 65295;\n\t\t\titemDef.femaleModel = 65328;\n\t\t\titemDef.modelZoom = 1316;\n\t\t\titemDef.modelRotation1 = 252;\n\t\t\titemDef.modelRotation2 = 1020;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 24;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33021:\n\t\t\titemDef.name = \"Torva full helm\";\n\t\t\titemDef.description = \"An ancient warrior's full helm.\";\n\t\t\titemDef.modelId = 62714;\n\t\t\titemDef.maleModel = 62738;\n\t\t\titemDef.femaleModel = 62738;\n\t\t\titemDef.modelZoom = 672;\n\t\t\titemDef.modelRotation1 = 85;\n\t\t\titemDef.modelRotation2 = 1867;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33022:\n\t\t\titemDef.name = \"Torva platebody\";\n\t\t\titemDef.description = \"An ancient warrior's platebody.\";\n\t\t\titemDef.modelId = 62699;\n\t\t\titemDef.maleModel = 62746;\n\t\t\titemDef.femaleModel = 62746;\n\t\t\titemDef.modelZoom = 1506;\n\t\t\titemDef.modelRotation1 = 473;\n\t\t\titemDef.modelRotation2 = 2042;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33023:\n\t\t\titemDef.name = \"Torva platelegs\";\n\t\t\titemDef.description = \"An ancient warrior's platelegs.\";\n\t\t\titemDef.modelId = 62701;\n\t\t\titemDef.maleModel = 62740;\n\t\t\titemDef.femaleModel = 62740;\n\t\t\titemDef.modelZoom = 1740;\n\t\t\titemDef.modelRotation1 = 474;\n\t\t\titemDef.modelRotation2 = 2045;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33024:\n\t\t\titemDef.name = \"Pernix cowl\";\n\t\t\titemDef.description = \"An ancient warrior's cowl.\";\n\t\t\titemDef.modelId = 62693;\n\t\t\titemDef.maleModel = 62739;\n\t\t\titemDef.femaleModel = 62739;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 532;\n\t\t\titemDef.modelRotation2 = 14;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33025:\n\t\t\titemDef.name = \"Pernix body\";\n\t\t\titemDef.description = \"An ancient warrior's leather body.\";\n\t\t\titemDef.modelId = 62709;\n\t\t\titemDef.maleModel = 62744;\n\t\t\titemDef.femaleModel = 62744;\n\t\t\titemDef.modelZoom = 1378;\n\t\t\titemDef.modelRotation1 = 485;\n\t\t\titemDef.modelRotation2 = 2042;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 7;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33026:\n\t\t\titemDef.name = \"Pernix chaps\";\n\t\t\titemDef.description = \"An ancient warrior's chaps.\";\n\t\t\titemDef.modelId = 62695;\n\t\t\titemDef.maleModel = 62741;\n\t\t\titemDef.femaleModel = 62741;\n\t\t\titemDef.modelZoom = 1740;\n\t\t\titemDef.modelRotation1 = 504;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33027:\n\t\t\titemDef.name = \"Virtus mask\";\n\t\t\titemDef.description = \"An ancient warrior's mask.\";\n\t\t\titemDef.modelId = 62710;\n\t\t\titemDef.maleModel = 62736;\n\t\t\titemDef.femaleModel = 62736;\n\t\t\titemDef.modelZoom = 928;\n\t\t\titemDef.modelRotation1 = 406;\n\t\t\titemDef.modelRotation2 = 2041;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33028:\n\t\t\titemDef.name = \"Virtus robe top\";\n\t\t\titemDef.description = \"An ancient warrior's robe top.\";\n\t\t\titemDef.modelId = 62704;\n\t\t\titemDef.maleModel = 62748;\n\t\t\titemDef.femaleModel = 62748;\n\t\t\titemDef.modelZoom = 1122;\n\t\t\titemDef.modelRotation1 = 488;\n\t\t\titemDef.modelRotation2 = 3;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33029:\n\t\t\titemDef.name = \"Virtus robe legs\";\n\t\t\titemDef.description = \"An ancient warrior's robe legs.\";\n\t\t\titemDef.modelId = 62700;\n\t\t\titemDef.maleModel = 62742;\n\t\t\titemDef.femaleModel = 62742;\n\t\t\titemDef.modelZoom = 1740;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 2045;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33030:\n\t\t\titemDef.name = \"Zaryte bow\";\n\t\t\titemDef.description = \"An ancient warrior's bow.\";\n\t\t\titemDef.modelId = 62692;\n\t\t\titemDef.maleModel = 62750;\n\t\t\titemDef.femaleModel = 62750;\n\t\t\titemDef.modelZoom = 1703;\n\t\t\titemDef.modelRotation1 = 221;\n\t\t\titemDef.modelRotation2 = 404;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -13;\n\t\t\titemDef.maleOffset = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33083:\n\t\t\titemDef.name = \"Tokhaar-kal\";\n\t\t\titemDef.description = \"\tA cape made of ancient, enchanted obsidian.\";\n\t\t\titemDef.modelId = 52073;\n\t\t\titemDef.maleModel = 52072;\n\t\t\titemDef.femaleModel = 52071;\n\t\t\titemDef.modelZoom = 1615;\n\t\t\titemDef.modelRotation1 = 339;\n\t\t\titemDef.modelRotation2 = 192;\n\t\t\titemDef.modelOffset1 = -4;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33089:\n\t\t\titemDef.name = \"Chaotic maul\";\n\t\t\titemDef.description = \"A maul used to claim life from those who don't deserve it.\";\n\t\t\titemDef.modelId = 54286;\n\t\t\titemDef.maleModel = 56294;\n\t\t\titemDef.femaleModel = 56294;\n\t\t\titemDef.modelZoom = 1447;\n\t\t\titemDef.modelRotation1 = 525;\n\t\t\titemDef.modelRotation2 = 350;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = -7;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\tbreak;\n\t\tcase 33094:\n\t\t\titemDef.name = \"Chaotic crossbow\";\n\t\t\titemDef.description = \"A small crossbow, only effective at short distance.\";\n\t\t\titemDef.modelId = 54331;\n\t\t\titemDef.maleModel = 56307;\n\t\t\titemDef.femaleModel = 56307;\n\t\t\titemDef.modelZoom = 1028;\n\t\t\titemDef.modelRotation1 = 249;\n\t\t\titemDef.modelRotation2 = 2021;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -54;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = -7;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\tbreak;\n\t\tcase 33095:\n\t\t\titemDef.name = \"Chaotic staff\";\n\t\t\titemDef.description = \"This staff makes destructive spells more powerful.\";\n\t\t\titemDef.modelId = 54367;\n\t\t\titemDef.maleModel = 56286;\n\t\t\titemDef.femaleModel = 56286;\n\t\t\titemDef.modelZoom = 1711;\n\t\t\titemDef.modelRotation1 = 471;\n\t\t\titemDef.modelRotation2 = 391;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = -7;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\tbreak;\n\t\tcase 33096:\n\t\t\titemDef.name = \"Chaotic kiteshield\";\n\t\t\titemDef.description = \"A large metal shield.\";\n\t\t\titemDef.modelId = 54358;\n\t\t\titemDef.maleModel = 56038;\n\t\t\titemDef.femaleModel = 56038;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 276;\n\t\t\titemDef.modelRotation2 = 1101;\n\t\t\titemDef.modelOffset1 = -5;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33031:\n\t\t\titemDef.name = \"Chaotic rapier\";\n\t\t\titemDef.description = \"A razor-sharp rapier.\";\n\t\t\titemDef.modelId = 54197;\n\t\t\titemDef.maleModel = 56252;\n\t\t\titemDef.femaleModel = 56252;\n\t\t\titemDef.modelZoom = 1425;\n\t\t\titemDef.modelRotation1 = 540;\n\t\t\titemDef.modelRotation2 = 1370;\n\t\t\titemDef.modelOffset1 = 9;\n\t\t\titemDef.modelOffset2 = 13;\n\t\t\titemDef.maleOffset = -12;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = -7;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\tbreak;\n\t\tcase 33032:\n\t\t\titemDef.name = \"Chaotic longsword\";\n\t\t\titemDef.description = \"A razor-sharp longsword.\";\n\t\t\titemDef.modelId = 54204;\n\t\t\titemDef.maleModel = 56237;\n\t\t\titemDef.femaleModel = 56237;\n\t\t\titemDef.modelZoom = 1650;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 1300;\n\t\t\t// itemDef.aByte154 = -14;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = -7;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\tbreak;\n\t\tcase 33097:\n\t\t\titemDef.name = \"Sword of Onyxia\";\n\t\t\titemDef.description = \"A razor-sharp longsword.\";\n\t\t\titemDef.modelId = 53091;\n\t\t\titemDef.maleModel = 53092;\n\t\t\titemDef.femaleModel = 53092;\n\t\t\titemDef.modelZoom = 2007;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33098:\n\t\t\titemDef.name = \"Onyxia longsword\";\n\t\t\titemDef.description = \"A razor-sharp 2h sword.\";\n\t\t\titemDef.modelId = 53093;\n\t\t\titemDef.maleModel = 53094;\n\t\t\titemDef.femaleModel = 53094;\n\t\t\titemDef.modelZoom = 4007;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.maleOffset = -8;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33099:\n\t\t\titemDef.name = \"White scimitar\";\n\t\t\titemDef.description = \"A razor-sharp scimitar.\";\n\t\t\titemDef.modelId = 53097;\n\t\t\titemDef.maleModel = 53098;\n\t\t\titemDef.femaleModel = 53098;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 312;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\t// itemDef.aByte154 = -14;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33100:\n\t\t\titemDef.name = \"White kiteshield\";\n\t\t\titemDef.description = \"a heavy kiteshield.\";\n\t\t\titemDef.modelId = 53095;\n\t\t\titemDef.maleModel = 53096;\n\t\t\titemDef.femaleModel = 53096;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelRotation1 = 303;\n\t\t\titemDef.modelRotation2 = 180;\n\t\t\t// itemDef.aByte154 = -14;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = 7;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33033:\n\t\t\titemDef.name = \"Agility master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 677, 801, 43540, 43543, 43546, 43549, 43550, 43552, 43554, 43558,\n\t\t\t\t\t43560, 43575 };\n\t\t\titemDef.modelId = 50030;\n\t\t\titemDef.maleModel = 50031;\n\t\t\titemDef.femaleModel = 50031;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33034:\n\t\t\titemDef.name = \"Attack master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 7104, 9151, 911, 914, 917, 920, 921, 923, 925, 929, 931, 946 };\n\t\t\titemDef.modelId = 50032;\n\t\t\titemDef.maleModel = 50033;\n\t\t\titemDef.femaleModel = 50033;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33035:\n\t\t\titemDef.name = \"Construction master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 6061, 5945, 6327, 6330, 6333, 6336, 6337, 6339, 6341, 6345, 6347,\n\t\t\t\t\t6362 };\n\t\t\titemDef.modelId = 50034;\n\t\t\titemDef.maleModel = 50035;\n\t\t\titemDef.femaleModel = 50035;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33036:\n\t\t\titemDef.name = \"Cooking master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 920, 920, 51856, 51859, 51862, 51865, 51866, 51868, 51870, 51874,\n\t\t\t\t\t51876, 51891 };\n\t\t\titemDef.modelId = 50036;\n\t\t\titemDef.maleModel = 50037;\n\t\t\titemDef.femaleModel = 50037;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33037:\n\t\t\titemDef.name = \"Crafting master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 9142, 9152, 4511, 4514, 4517, 4520, 4521, 4523, 4525, 4529, 4531,\n\t\t\t\t\t4546 };\n\t\t\titemDef.modelId = 50038;\n\t\t\titemDef.maleModel = 50039;\n\t\t\titemDef.femaleModel = 50039;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33038:\n\t\t\titemDef.name = \"Defence master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 10460, 10473, 41410, 41413, 41416, 41419, 41420, 41422, 41424,\n\t\t\t\t\t41428, 41430, 41445 };\n\t\t\titemDef.modelId = 50040;\n\t\t\titemDef.maleModel = 50041;\n\t\t\titemDef.femaleModel = 50041;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33039:\n\t\t\titemDef.name = \"Farming master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 14775, 14792, 22026, 22029, 22032, 22035, 22036, 22038, 22040,\n\t\t\t\t\t22044, 22046, 22061 };\n\t\t\titemDef.modelId = 50042;\n\t\t\titemDef.maleModel = 50043;\n\t\t\titemDef.femaleModel = 50043;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33040:\n\t\t\titemDef.name = \"Firemaking master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 8125, 9152, 4015, 4018, 4021, 4024, 4025, 4027, 4029, 4033, 4035,\n\t\t\t\t\t4050 };\n\t\t\titemDef.modelId = 50044;\n\t\t\titemDef.maleModel = 50045;\n\t\t\titemDef.femaleModel = 50045;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33041:\n\t\t\titemDef.name = \"Fishing master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 9144, 9152, 38202, 38205, 38208, 38211, 38212, 38214, 38216,\n\t\t\t\t\t38220, 38222, 38237 };\n\t\t\titemDef.modelId = 50046;\n\t\t\titemDef.maleModel = 50047;\n\t\t\titemDef.femaleModel = 50047;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33042:\n\t\t\titemDef.name = \"Fletching master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 6067, 9152, 33670, 33673, 33676, 33679, 33680, 33682, 33684,\n\t\t\t\t\t33688, 33690, 33705 };\n\t\t\titemDef.modelId = 50048;\n\t\t\titemDef.maleModel = 50049;\n\t\t\titemDef.femaleModel = 50049;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33043:\n\t\t\titemDef.name = \"Herblore master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 9145, 9156, 22414, 22417, 22420, 22423, 22424, 22426, 22428,\n\t\t\t\t\t22432, 22434, 22449 };\n\t\t\titemDef.modelId = 50050;\n\t\t\titemDef.maleModel = 50051;\n\t\t\titemDef.femaleModel = 50051;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33044:\n\t\t\titemDef.name = \"Hitpoints master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 818, 951, 8291, 8294, 8297, 8300, 8301, 8303, 8305, 8309, 8311,\n\t\t\t\t\t8319 };\n\t\t\titemDef.modelId = 50052;\n\t\t\titemDef.maleModel = 50053;\n\t\t\titemDef.femaleModel = 50053;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\titemDef.femaleOffset = 4;\n\t\t\tbreak;\n\t\tcase 33045:\n\t\t\titemDef.name = \"Hunter master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 5262, 6020, 8472, 8475, 8478, 8481, 8482, 8484, 8486, 8490, 8492,\n\t\t\t\t\t8507 };\n\t\t\titemDef.modelId = 50054;\n\t\t\titemDef.maleModel = 50055;\n\t\t\titemDef.femaleModel = 50055;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33046:\n\t\t\titemDef.name = \"Magic master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 43569, 43685, 6336, 6339, 6342, 6345, 6346, 6348, 6350, 6354,\n\t\t\t\t\t6356, 6371 };\n\t\t\titemDef.modelId = 50056;\n\t\t\titemDef.maleModel = 50057;\n\t\t\titemDef.femaleModel = 50057;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33047:\n\t\t\titemDef.name = \"Mining master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 36296, 36279, 10386, 10389, 10392, 10395, 10396, 10398, 10400,\n\t\t\t\t\t10404, 10406, 10421 };\n\t\t\titemDef.modelId = 50058;\n\t\t\titemDef.maleModel = 50059;\n\t\t\titemDef.femaleModel = 50059;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33048:\n\t\t\titemDef.name = \"Prayer master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 9163, 9168, 117, 120, 123, 126, 127, 127, 127, 127, 127, 127 };\n\t\t\titemDef.modelId = 50060;\n\t\t\titemDef.maleModel = 50061;\n\t\t\titemDef.femaleModel = 50061;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33049:\n\t\t\titemDef.name = \"Range master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 3755, 3998, 15122, 15125, 15128, 15131, 15132, 15134, 15136,\n\t\t\t\t\t15140, 15142, 15157 };\n\t\t\titemDef.modelId = 50062;\n\t\t\titemDef.maleModel = 50063;\n\t\t\titemDef.femaleModel = 50063;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33050:\n\t\t\titemDef.name = \"Runecrafting master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 9152, 8128, 10318, 10321, 10324, 10327, 10328, 10330, 10332,\n\t\t\t\t\t10336, 10338, 10353 };\n\t\t\titemDef.modelId = 50064;\n\t\t\titemDef.maleModel = 50065;\n\t\t\titemDef.femaleModel = 50065;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33051:\n\t\t\titemDef.name = \"Slayer master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811 };\n\t\t\titemDef.originalModelColors = new int[] { 912, 920 };\n\t\t\titemDef.modelId = 50066;\n\t\t\titemDef.maleModel = 50067;\n\t\t\titemDef.femaleModel = 50067;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33052:\n\t\t\titemDef.name = \"Smithing master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 8115, 9148, 10386, 10389, 10392, 10395, 10396, 10398, 10400,\n\t\t\t\t\t10404, 10406, 10421 };\n\t\t\titemDef.modelId = 50068;\n\t\t\titemDef.maleModel = 50069;\n\t\t\titemDef.femaleModel = 50069;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33053:\n\t\t\titemDef.name = \"Strength master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 935, 931, 27538, 27541, 27544, 27547, 27548, 27550, 27552, 27556,\n\t\t\t\t\t27558, 27573 };\n\t\t\titemDef.modelId = 50070;\n\t\t\titemDef.maleModel = 50071;\n\t\t\titemDef.femaleModel = 50071;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33054:\n\t\t\titemDef.name = \"Thieving master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 11, 0, 58779, 58782, 58785, 58788, 58789, 57891, 58793, 58797,\n\t\t\t\t\t58799, 58814 };\n\t\t\titemDef.modelId = 50072;\n\t\t\titemDef.maleModel = 50073;\n\t\t\titemDef.femaleModel = 50073;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33055:\n\t\t\titemDef.name = \"Woodcutting master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 25109, 24088, 6693, 6696, 6699, 6702, 6703, 6705, 6707, 6711,\n\t\t\t\t\t6713, 6728 };\n\t\t\titemDef.modelId = 50074;\n\t\t\titemDef.maleModel = 50075;\n\t\t\titemDef.femaleModel = 50075;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33057:\n\t\t\titemDef.name = \"Abyssal Scythe\";\n\t\t\titemDef.description = \"\tA Scythe recieved from the Trials of Xeric CUSTOM RAID.\";\n\t\t\titemDef.modelId = 50081;\n\t\t\titemDef.maleModel = 50080;\n\t\t\titemDef.femaleModel = 50080;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.maleOffset = -12;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33090:\n\t\t\titemDef.name = \"Goliath gloves (Black)\";\n\t\t\titemDef.description = \"\tA pair of gloves earned with blood.\";\n\t\t\titemDef.modelId = 50108;\n\t\t\titemDef.maleModel = 50100;\n\t\t\titemDef.femaleModel = 50101;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 539;\n\t\t\titemDef.modelRotation2 = 40;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33091:\n\t\t\titemDef.name = \"Goliath gloves (Red)\";\n\t\t\titemDef.description = \"\tA pair of gloves earned with blood.\";\n\t\t\titemDef.modelId = 50108;\n\t\t\titemDef.maleModel = 50102;\n\t\t\titemDef.femaleModel = 50103;\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 65046, 65051, 65056 };\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 539;\n\t\t\titemDef.modelRotation2 = 40;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33092:\n\t\t\titemDef.name = \"Goliath gloves (White)\";\n\t\t\titemDef.description = \"\tA pair of gloves earned with blood.\";\n\t\t\titemDef.modelId = 50108;\n\t\t\titemDef.maleModel = 50104;\n\t\t\titemDef.femaleModel = 50105;\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 64585, 64590, 64595 };\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 539;\n\t\t\titemDef.modelRotation2 = 40;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33093:\n\t\t\titemDef.name = \"Goliath gloves (Yellow)\";\n\t\t\titemDef.description = \"\tA pair of gloves earned with blood.\";\n\t\t\titemDef.modelId = 50108;\n\t\t\titemDef.maleModel = 50106;\n\t\t\titemDef.femaleModel = 50107;\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 9767, 9772, 9777 };\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 539;\n\t\t\titemDef.modelRotation2 = 40;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 12639:\n\t\tcase 12637:\n\t\tcase 12638:\n\t\t\titemDef.description = \"Provides players with infinite run energy!\";\n\t\t\tbreak;\n\t\tcase 33056:\n\t\t\titemDef.name = \"Events cape (slayer)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 933, 0, 0, 0, 0 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33081:\n\t\t\titemDef.name = \"Events cape (agility)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 669, 43430, 43430, 43430, 43430 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33080:\n\t\t\titemDef.name = \"Events cape (attack)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 9926, 1815, 1815, 1815, 1815 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33059:\n\t\t\titemDef.name = \"Events cape (construction)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 6967, 6343, 6343, 6343, 6343 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33061:\n\t\t\titemDef.name = \"Events cape (cooking)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 1819, 49685, 49685, 49685, 49685 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33062:\n\t\t\titemDef.name = \"Events cape (crafting)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 7994, 4516, 4516, 4516, 4516 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33063:\n\t\t\titemDef.name = \"Events cape (defence)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 39367, 10472, 10472, 10472, 10472 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33064:\n\t\t\titemDef.name = \"Events cape (farming)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10698, 19734, 19734, 19734, 19734 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33065:\n\t\t\titemDef.name = \"Events cape (firemaking)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10059, 4922, 4922, 4922, 4922 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33066:\n\t\t\titemDef.name = \"Events cape (fishing)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10047, 36165, 36165, 36165, 36165 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33067:\n\t\t\titemDef.name = \"Events cape (fletching)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10047, 31500, 31500, 31500, 31500 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33068:\n\t\t\titemDef.name = \"Events cape (herblore)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10051, 20889, 20889, 20889, 20889 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33069:\n\t\t\titemDef.name = \"Events cape (hitpoints)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 1836, 8296, 8296, 8296, 8296 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33070:\n\t\t\titemDef.name = \"Events cape (hunter)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 6916, 8477, 8477, 8477, 8477 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33071:\n\t\t\titemDef.name = \"Events cape (magic)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 43556, 6339, 6339, 6339, 6339 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33072:\n\t\t\titemDef.name = \"Events cape (mining)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 34111, 10391, 10391, 10391, 10391 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33073:\n\t\t\titemDef.name = \"Events cape (prayer)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 9927, 2169, 2169, 2169, 2169 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33074:\n\t\t\titemDef.name = \"Events cape (range)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 3626, 20913, 20913, 20913, 20913 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33075:\n\t\t\titemDef.name = \"Events cape (runecrafting)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10047, 10323, 10323, 10323, 10323 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33076:\n\t\t\titemDef.name = \"Events cape (smithing)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10044, 5412, 5412, 5412, 5412 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33077:\n\t\t\titemDef.name = \"Events cape (strength)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 1819, 30487, 30487, 30487, 30487 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33078:\n\t\t\titemDef.name = \"Events cape (thieveing)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 8, 57636, 57636, 57636, 57636 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33079:\n\t\t\titemDef.name = \"Events cape (woodcutting)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 26007, 6570, 6570, 6570, 6570 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33101:\n\t\t\titemDef.name = \"Vorkath platebody\";\n\t\t\titemDef.description = \"Vorkath armour.\";\n\t\t\titemDef.modelId = 53100;\n\t\t\titemDef.maleModel = 53099;\n\t\t\titemDef.femaleModel = 53099;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33102:\n\t\t\titemDef.name = \"Vorkath platelegs\";\n\t\t\titemDef.description = \"Vorkath armour.\";\n\t\t\titemDef.modelId = 53102;\n\t\t\titemDef.maleModel = 53101;\n\t\t\titemDef.femaleModel = 53101;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33103:\n\t\t\titemDef.name = \"Vorkath boots\";\n\t\t\titemDef.description = \"Vorkath armour.\";\n\t\t\titemDef.modelId = 53104;\n\t\t\titemDef.maleModel = 53103;\n\t\t\titemDef.femaleModel = 53103;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33104:\n\t\t\titemDef.name = \"Vorkath gloves\";\n\t\t\titemDef.description = \"Vorkath armour.\";\n\t\t\titemDef.modelId = 53106;\n\t\t\titemDef.maleModel = 53105;\n\t\t\titemDef.femaleModel = 53105;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33105:\n\t\t\titemDef.name = \"Vorkath helmet\";\n\t\t\titemDef.description = \"Vorkath armour.\";\n\t\t\titemDef.modelId = 53108;\n\t\t\titemDef.maleModel = 53107;\n\t\t\titemDef.femaleModel = 53107;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33106:\n\t\t\titemDef.name = \"Tekton helmet\";\n\t\t\titemDef.description = \"Tekton armour.\";\n\t\t\titemDef.modelId = 53118;\n\t\t\titemDef.maleModel = 53117;\n\t\t\titemDef.femaleModel = 53117;\n\t\t\titemDef.modelZoom = 724;\n\t\t\titemDef.modelRotation1 = 81;\n\t\t\titemDef.modelRotation2 = 1670;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33107:\n\t\t\titemDef.name = \"Tekton platebody\";\n\t\t\titemDef.description = \"Tekton armour.\";\n\t\t\titemDef.modelId = 53110;\n\t\t\titemDef.maleModel = 53109;\n\t\t\titemDef.femaleModel = 53109;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33108:\n\t\t\titemDef.name = \"Tekton platelegs\";\n\t\t\titemDef.description = \"Tekton armour.\";\n\t\t\titemDef.modelId = 53112;\n\t\t\titemDef.maleModel = 53111;\n\t\t\titemDef.femaleModel = 53111;\n\t\t\titemDef.modelZoom = 1550;\n\t\t\titemDef.modelRotation1 = 344;\n\t\t\titemDef.modelRotation2 = 186;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 11;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33109:\n\t\t\titemDef.name = \"Tekton gloves\";\n\t\t\titemDef.description = \"Tekton armour.\";\n\t\t\titemDef.modelId = 53116;\n\t\t\titemDef.maleModel = 53115;\n\t\t\titemDef.femaleModel = 53115;\n\t\t\titemDef.modelZoom = 830;\n\t\t\titemDef.modelRotation1 = 536;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33110:\n\t\t\titemDef.name = \"Tekton boots\";\n\t\t\titemDef.description = \"Tekton armour.\";\n\t\t\titemDef.modelId = 53114;\n\t\t\titemDef.maleModel = 53113;\n\t\t\titemDef.femaleModel = 53113;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33111:\n\t\t\titemDef.name = \"Anti-santa scythe\";\n\t\t\titemDef.description = \"Legend says this is the biggest arse scratcher around.\";\n\t\t\titemDef.modelId = 57002;\n\t\t\titemDef.maleModel = 57001;\n\t\t\titemDef.femaleModel = 57001;\n\t\t\titemDef.modelZoom = 3224;\n\t\t\titemDef.modelRotation1 = 539;\n\t\t\titemDef.modelRotation2 = 714;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33112:\n\t\t\titemDef.name = \"Dominion staff\";\n\t\t\titemDef.description = \"Dominion staff.\";\n\t\t\titemDef.modelId = 59029;\n\t\t\titemDef.maleModel = 59305;\n\t\t\titemDef.femaleModel = 59305;\n\t\t\titemDef.modelZoom = 1872;\n\t\t\titemDef.modelRotation1 = 288;\n\t\t\titemDef.modelRotation2 = 1685;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33113:\n\t\t\titemDef.name = \"Dominion sword\";\n\t\t\titemDef.description = \"Dominion sword.\";\n\t\t\titemDef.modelId = 59832;\n\t\t\titemDef.maleModel = 59306;\n\t\t\titemDef.femaleModel = 59306;\n\t\t\titemDef.modelZoom = 1829;\n\t\t\titemDef.modelRotation1 = 513;\n\t\t\titemDef.modelRotation2 = 546;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33114:\n\t\t\titemDef.name = \"Dominion crossbow\";\n\t\t\titemDef.description = \"Dominion crossbow.\";\n\t\t\titemDef.modelId = 59839;\n\t\t\titemDef.maleModel = 59304;\n\t\t\titemDef.femaleModel = 59304;\n\t\t\titemDef.modelZoom = 1490;\n\t\t\titemDef.modelRotation1 = 362;\n\t\t\titemDef.modelRotation2 = 791;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33115:\n\t\t\titemDef.name = \"Dragonfire Shield (e)\";\n\t\t\titemDef.description = \"unamed shield.\";\n\t\t\titemDef.modelId = 53120;\n\t\t\titemDef.maleModel = 53119;\n\t\t\titemDef.femaleModel = 53119;\n\t\t\titemDef.modelZoom = 2022;\n\t\t\titemDef.modelRotation1 = 540;\n\t\t\titemDef.modelRotation2 = 123;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[] { null, \"Wear\", \"Inspect\", \"Empty\", \"Drop\" };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33116:\n\t\t\titemDef.name = \"Zilyana's longbow\";\n\t\t\titemDef.description = \"A bow belonged to Zilyana.\";\n\t\t\titemDef.modelId = 53122;\n\t\t\titemDef.maleModel = 53121;\n\t\t\titemDef.femaleModel = 53121;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 636;\n\t\t\titemDef.modelRotation2 = 1010;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33117:\n\t\t\titemDef.name = \"Black dragon hunter crossbow\";\n\t\t\titemDef.description = \"Black dragon hunter crossbow.\";\n\t\t\titemDef.modelId = 53124;\n\t\t\titemDef.maleModel = 53123;\n\t\t\titemDef.femaleModel = 53123;\n\t\t\titemDef.modelZoom = 1554;\n\t\t\titemDef.modelRotation1 = 636;\n\t\t\titemDef.modelRotation2 = 1010;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33118:\n\t\t\titemDef.name = \"Vorkath blowpipe\";\n\t\t\titemDef.description = \"Vorkath blowpipe.\";\n\t\t\titemDef.modelId = 53126;\n\t\t\titemDef.maleModel = 53125;\n\t\t\titemDef.femaleModel = 53125;\n\t\t\titemDef.modelZoom = 1158;\n\t\t\titemDef.modelRotation1 = 768;\n\t\t\titemDef.modelRotation2 = 189;\n\t\t\titemDef.modelOffset1 = -7;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33119:\n\t\t\titemDef.name = \"Superior twisted bow\";\n\t\t\titemDef.description = \"An upgraded twisted bow.\";\n\t\t\titemDef.modelId = 53128;\n\t\t\titemDef.maleModel = 53127;\n\t\t\titemDef.femaleModel = 53127;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 720;\n\t\t\titemDef.modelRotation2 = 1500;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\titemDef.maleOffset = -4;\n\t\t\titemDef.femaleOffset = -4;\n\t\t\tbreak;\n\t\tcase 33123:\n\t\t\titemDef.name = \"Staff of sliske\";\n\t\t\titemDef.description = \"Staff of sliske.\";\n\t\t\titemDef.modelId = 59234;\n\t\t\titemDef.maleModel = 59233;\n\t\t\titemDef.femaleModel = 59233;\n\t\t\titemDef.modelZoom = 1872;\n\t\t\titemDef.modelRotation1 = 288;\n\t\t\titemDef.modelRotation2 = 1685;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33124:\n\t\t\titemDef.name = \"Twisted crossbow\";\n\t\t\titemDef.description = \"Twisted crossbow.\";\n\t\t\titemDef.modelId = 62777;\n\t\t\titemDef.maleModel = 62776;\n\t\t\titemDef.femaleModel = 62776;\n\t\t\titemDef.modelZoom = 926;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 258;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33125:\n\t\t\titemDef.name = \"Present\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modelId = 2426;\n\t\t\titemDef.modelZoom = 1180;\n\t\t\titemDef.modelRotation1 = 160;\n\t\t\titemDef.modelRotation2 = 172;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -14;\n\t\t\titemDef.modifiedModelColors = new int[] { 22410, 2999 };\n\t\t\titemDef.originalModelColors = new int[] { 933, 24410 };\n\t\t\titemDef.description = \"Santa's stolen present\";\n\t\t\tbreak;\n\t\tcase 33126:\n\t\t\titemDef.name = \"Christmas tree branch\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modelId = 2412;\n\t\t\titemDef.modelZoom = 940;\n\t\t\titemDef.modelRotation1 = 268;\n\t\t\titemDef.modelRotation2 = 152;\n\t\t\titemDef.modelOffset1 = -8;\n\t\t\titemDef.modelOffset2 = -21;\n\t\t\titemDef.modifiedModelColors = new int[] { 11144 };\n\t\t\titemDef.originalModelColors = new int[] { 6047 };\n\t\t\titemDef.description = \"Enter examine here.\";\n\t\t\tbreak;\n\t\tcase 33127:\n\t\t\titemDef.name = \"Kbd gloves\";\n\t\t\titemDef.description = \"Kbd gloves.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 33085 };\n\t\t\titemDef.originalModelColors = new int[] { 1060 };\n\t\t\titemDef.modelId = 53106;\n\t\t\titemDef.maleModel = 53105;\n\t\t\titemDef.femaleModel = 53105;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33128:\n\t\t\titemDef.name = \"Kbd boots\";\n\t\t\titemDef.description = \"Kbd boots.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 33198, 33202, 33206, 33215, 33210 };\n\t\t\titemDef.originalModelColors = new int[] { 1060, 1061, 1063, 1064, 1065 };\n\t\t\titemDef.modelId = 53104;\n\t\t\titemDef.maleModel = 53103;\n\t\t\titemDef.femaleModel = 53103;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33129:\n\t\t\titemDef.name = \"Kbd platelegs\";\n\t\t\titemDef.description = \"Kbd platelegs.\";\n\t\t\titemDef.modelId = 59994;\n\t\t\titemDef.maleModel = 59995;\n\t\t\titemDef.femaleModel = 59995;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33130:\n\t\t\titemDef.name = \"Kbd platebody\";\n\t\t\titemDef.description = \"Kbd platebody.\";\n\t\t\titemDef.modelId = 59998;\n\t\t\titemDef.maleModel = 59999;\n\t\t\titemDef.femaleModel = 59999;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33131:\n\t\t\titemDef.name = \"Kbd helmet\";\n\t\t\titemDef.description = \"Kbd helmet.\";\n\t\t\titemDef.modelId = 59996;\n\t\t\titemDef.maleModel = 59997;\n\t\t\titemDef.femaleModel = 59997;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33132:\n\t\t\titemDef.name = \"Kbd cape\";\n\t\t\titemDef.description = \"Kbd cape.\";\n\t\t\titemDef.modelId = 59992;\n\t\t\titemDef.maleModel = 59993;\n\t\t\titemDef.femaleModel = 59993;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33133:\n\t\t\titemDef.name = \"Anti-imp pet\";\n\t\t\titemDef.description = \"Anti-imp pet.\";\n\t\t\titemDef.modelId = 45294;\n\t\t\titemDef.modelZoom = 1500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33134:\n\t\t\titemDef.name = \"Anti-santa pet\";\n\t\t\titemDef.description = \"Anti-santa pet.\";\n\t\t\titemDef.modelId = 29030;\n\t\t\titemDef.modelZoom = 653;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 1966;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33135:\n\t\t\titemDef.name = \"Bandos mask\";\n\t\t\titemDef.description = \"Bandos helmet.\";\n\t\t\titemDef.modelId = 59987;\n\t\t\titemDef.maleModel = 59991;\n\t\t\titemDef.femaleModel = 59991;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33136:\n\t\t\titemDef.name = \"Armadyl mask\";\n\t\t\titemDef.description = \"Armadyl mask.\";\n\t\t\titemDef.modelId = 59986;\n\t\t\titemDef.maleModel = 59990;\n\t\t\titemDef.femaleModel = 59990;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33137:\n\t\t\titemDef.name = \"Zamorak mask\";\n\t\t\titemDef.description = \"Zamorak mask.\";\n\t\t\titemDef.modelId = 59985;\n\t\t\titemDef.maleModel = 59989;\n\t\t\titemDef.femaleModel = 59989;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33138:\n\t\t\titemDef.name = \"Saradomin mask\";\n\t\t\titemDef.description = \"Saradomin mask.\";\n\t\t\titemDef.modelId = 59984;\n\t\t\titemDef.maleModel = 59988;\n\t\t\titemDef.femaleModel = 59988;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33139:\n\t\t\titemDef.name = \"Zamarok godbow\";\n\t\t\titemDef.description = \"Zamarok godbow.\";\n\t\t\titemDef.modelId = 60560;//60553\n\t\t\titemDef.maleModel = 60560;\n\t\t\titemDef.femaleModel = 60560;\n\t\t\titemDef.modelZoom = 2100;\n\t\t\titemDef.modelRotation1 = 720;\n\t\t\titemDef.modelRotation2 = 1500;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33140:\n\t\t\titemDef.name = \"Saradomin godbow\";\n\t\t\titemDef.description = \"Saradomin godbow.\";\n\t\t\titemDef.modelId = 60555;\n\t\t\titemDef.maleModel = 60554;\n\t\t\titemDef.femaleModel = 60554;\n\t\t\titemDef.modelZoom = 2100;\n\t\t\titemDef.modelRotation1 = 720;\n\t\t\titemDef.modelRotation2 = 1500;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33141:\n\t\t\titemDef.name = \"Bandos godbow\";\n\t\t\titemDef.description = \"Bandos godbow.\";\n\t\t\titemDef.modelId = 60559;\n\t\t\titemDef.maleModel = 60558;\n\t\t\titemDef.femaleModel = 60558;\n\t\t\titemDef.modelZoom = 2100;\n\t\t\titemDef.modelRotation1 = 720;\n\t\t\titemDef.modelRotation2 = 1500;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33142:\n\t\t\titemDef.name = \"Fire cape (purple)\";\n\t\t\titemDef.description = \"Fire cape (purple).\";\n\t\t\titemDef.modelId = 9631;\n\t\t\titemDef.maleModel = 9638;\n\t\t\titemDef.femaleModel = 9640;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33148:\n\t\t\titemDef.name = \"Fire cape (cyan)\";\n\t\t\titemDef.description = \"Fire cape (cyan).\";\n\t\t\titemDef.modelId = 9631;\n\t\t\titemDef.maleModel = 9638;\n\t\t\titemDef.femaleModel = 9640;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33144:\n\t\t\titemDef.name = \"Fire cape (green)\";\n\t\t\titemDef.description = \"Fire cape (green).\";\n\t\t\titemDef.modelId = 9631;\n\t\t\titemDef.maleModel = 9638;\n\t\t\titemDef.femaleModel = 9640;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33145:\n\t\t\titemDef.name = \"Fire cape (red)\";\n\t\t\titemDef.description = \"Fire cape (red).\";\n\t\t\titemDef.modelId = 9631;\n\t\t\titemDef.maleModel = 9638;\n\t\t\titemDef.femaleModel = 9640;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33143:\n\t\t\titemDef.name = \"Infernal cape (blue)\";\n\t\t\titemDef.description = \"Infernal cape (blue).\";\n\t\t\titemDef.modifiedModelColors = new int[] { 5056, 5066, 924, 3005 };\n\t\t\titemDef.originalModelColors = new int[] { 39851, 39851, 39851, 39851 };\n\t\t\titemDef.modelId = 33144;\n\t\t\titemDef.maleModel = 33103;\n\t\t\titemDef.femaleModel = 33111;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33146:\n\t\t\titemDef.name = \"Infernal cape (green)\";\n\t\t\titemDef.description = \"Infernal cape (green).\";\n\t\t\titemDef.modifiedModelColors = new int[] { 5056, 5066, 924, 3005 };\n\t\t\titemDef.originalModelColors = new int[] { 21167, 21167, 21167, 21167 };\n\t\t\titemDef.modelId = 33144;\n\t\t\titemDef.maleModel = 33103;\n\t\t\titemDef.femaleModel = 33111;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33147:\n\t\t\titemDef.name = \"Infernal cape (purple)\";\n\t\t\titemDef.description = \"Infernal cape (purple).\";\n\t\t\titemDef.modifiedModelColors = new int[] { 5056, 5066, 924, 3005 };\n\t\t\titemDef.originalModelColors = new int[] { 53160, 53160, 53160, 53160 };\n\t\t\titemDef.modelId = 33144;\n\t\t\titemDef.maleModel = 33103;\n\t\t\titemDef.femaleModel = 33111;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33150:\n\t\t\titemDef.name = \"Infernal key piece 1\";\n\t\t\titemDef.description = \"Infernal key piece 1.\";\n\t\t\titemDef.modelId = 61001;\n\t\t\titemDef.modelZoom = 1200;\n\t\t\titemDef.modelRotation1 = 534;\n\t\t\titemDef.modelRotation2 = 222;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Combine\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33151:\n\t\t\titemDef.name = \"Infernal key piece 2\";\n\t\t\titemDef.description = \"Infernal key piece 2.\";\n\t\t\titemDef.modelId = 61002;\n\t\t\titemDef.modelZoom = 1200;\n\t\t\titemDef.modelRotation1 = 534;\n\t\t\titemDef.modelRotation2 = 222;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Combine\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33152:\n\t\t\titemDef.name = \"Infernal key piece 3\";\n\t\t\titemDef.description = \"Infernal key piece 3.\";\n\t\t\titemDef.modelId = 61003;\n\t\t\titemDef.modelZoom = 1200;\n\t\t\titemDef.modelRotation1 = 534;\n\t\t\titemDef.modelRotation2 = 222;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Combine\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33153:\n\t\t\titemDef.name = \"Infernal key\";\n\t\t\titemDef.description = \"Infernal key.\";\n\t\t\titemDef.modelId = 61111;\n\t\t\titemDef.modelZoom = 1200;\n\t\t\titemDef.modelRotation1 = 534;\n\t\t\titemDef.modelRotation2 = 222;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\t\t//DOPES ITEMS NIGGAHAHAHAHAHAHAH\n\t\tcase 2749:\n\t\t\titemDef.name = \"Bloody Axe\";\n\t\t\titemDef.description = \"Look at all that blood!\";\n\t\t\titemDef.modelId = 65495;\n\t\t\titemDef.femaleModel = 65495;\n\t\t\titemDef.maleModel = 65495;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 2750:\n\t\t\titemDef.name = \"Bloody Axe Offhand\";\n\t\t\titemDef.description = \"Look at all that blood!\";\n\t\t\titemDef.modelId = 65496;\n\t\t\titemDef.femaleModel = 65496;\n\t\t\titemDef.maleModel = 65496;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33154:\n\t\t\titemDef.name = \"Infernal mystery box\";\n\t\t\titemDef.description = \"Infernal mystery box.\";\n\t\t\titemDef.modelId = 61110;\n\t\t\titemDef.modelZoom = 1180;\n\t\t\titemDef.modelRotation1 = 160;\n\t\t\titemDef.modelRotation2 = 172;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -14;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Open\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33155:\n\t\t\titemDef.name = \"Ethereal sword (red)\";\n\t\t\titemDef.description = \"Ethereal sword (red).\";\n\t\t\titemDef.modelId = 61005;\n\t\t\titemDef.maleModel = 61004;\n\t\t\titemDef.femaleModel = 61004;\n\t\t\titemDef.modelZoom = 1645;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33156:\n\t\t\titemDef.name = \"Ethereal sword (blue)\";\n\t\t\titemDef.description = \"Ethereal sword (blue).\";\n\t\t\titemDef.modelId = 61006;\n\t\t\titemDef.maleModel = 61007;\n\t\t\titemDef.femaleModel = 61007;\n\t\t\titemDef.modelZoom = 1645;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33157:\n\t\t\titemDef.name = \"Ethereal sword (green)\";\n\t\t\titemDef.description = \"Ethereal sword (green).\";\n\t\t\titemDef.modelId = 61008;\n\t\t\titemDef.maleModel = 61009;\n\t\t\titemDef.femaleModel = 61009;\n\t\t\titemDef.modelZoom = 1645;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33158:\n\t\t\titemDef.name = \"Dagon' hai top\";\n\t\t\titemDef.description = \"An elite dark mages robes.\";\n\t\t\titemDef.modelId = 60317;\n\t\t\titemDef.maleModel = 43614;\n\t\t\titemDef.femaleModel = 43689;\n\t\t\titemDef.anInt188 = 44594;\n\t\t\titemDef.anInt164 = 43681;\n\t\t\titemDef.modelZoom = 1697;\n\t\t\titemDef.modelRotation1 = 536;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 7;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33159:\n\t\t\titemDef.name = \"Dagon' hai hat\";\n\t\t\titemDef.description = \"An elite dark mages hat.\";\n\t\t\titemDef.modelId = 60319;\n\t\t\titemDef.maleModel = 60318;\n\t\t\titemDef.femaleModel = 60318;\n\t\t\titemDef.anInt188 = -1;\n\t\t\titemDef.anInt164 = -1;\n\t\t\titemDef.modelZoom = 1373;\n\t\t\titemDef.modelRotation1 = 98;\n\t\t\titemDef.modelRotation2 = 1988;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33160:\n\t\t\titemDef.name = \"Dagon' hai robe\";\n\t\t\titemDef.description = \"An elite dark mages robe.\";\n\t\t\titemDef.modelId = 60321;\n\t\t\titemDef.maleModel = 60320;\n\t\t\titemDef.femaleModel = 60320;\n\t\t\titemDef.anInt188 = -1;\n\t\t\titemDef.anInt164 = -1;\n\t\t\titemDef.modelZoom = 2216;\n\t\t\titemDef.modelRotation1 = 572;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 14;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33161:\n\t\t\titemDef.name = \"Blue infernal cape mix\";\n\t\t\titemDef.description = \"Changes the color of the Infernal Cape to Blue.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33162:\n\t\t\titemDef.name = \"Green infernal cape mix\";\n\t\t\titemDef.description = \"Changes the color of the Infernal Cape to Green.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33163:\n\t\t\titemDef.name = \"Purple infernal cape mix\";\n\t\t\titemDef.description = \"Changes the color of the Infernal Cape to Purple.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33164:\n\t\t\titemDef.name = \"Purple firecape mix\";\n\t\t\titemDef.description = \"Changes the color of the firecape to purple.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33165:\n\t\t\titemDef.name = \"Cyan firecape mix\";\n\t\t\titemDef.description = \"Changes the color of the firecape to cyan.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33166:\n\t\t\titemDef.name = \"Green firecape mix\";\n\t\t\titemDef.description = \"Changes the color of the firecape to green.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33167:\n\t\t\titemDef.name = \"Red firecape mix\";\n\t\t\titemDef.description = \"Changes the color of the firecape to red.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33169:\n\t\t\titemDef.name = \"K'ril robe top\";\n\t\t\titemDef.description = \"A top worn by magic-using followers of Zamorak.\";\n\t\t\titemDef.modelId = 62558;\n\t\t\titemDef.maleModel = 62559;\n\t\t\titemDef.femaleModel = 62559;\n\t\t\titemDef.modelZoom = 1358;\n\t\t\titemDef.modelRotation1 = 514;\n\t\t\titemDef.modelRotation2 = 2041;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33170:\n\t\t\titemDef.name = \"K'ril robe bottom\";\n\t\t\titemDef.description = \"A robe worn by magic-using followers of Zamorak.\";\n\t\t\titemDef.modelId = 62553;\n\t\t\titemDef.maleModel = 62554;\n\t\t\titemDef.femaleModel = 62554;\n\t\t\titemDef.modelZoom = 1690;\n\t\t\titemDef.modelRotation1 = 435;\n\t\t\titemDef.modelRotation2 = 9;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 7;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33171:\n\t\t\titemDef.name = \"K'ril hat\";\n\t\t\titemDef.description = \"A hat worn by magic-using followers of Zamorak.\";\n\t\t\titemDef.modelId = 62551;\n\t\t\titemDef.maleModel = 62552;\n\t\t\titemDef.femaleModel = 62552;\n\t\t\titemDef.modelZoom = 1236;\n\t\t\titemDef.modelRotation1 = 118;\n\t\t\titemDef.modelRotation2 = 10;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -12;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33172:\n\t\t\titemDef.name = \"K'ril swords\";\n\t\t\titemDef.description = \"Sheath & Unsheath this sword in the Equipment tab. Hits an enemy twice.\";\n\t\t\titemDef.equipActions[2] = \"Sheath\";\n\t\t\titemDef.modelId = 62556;\n\t\t\titemDef.maleModel = 62557;\n\t\t\titemDef.femaleModel = 62557;\n\t\t\titemDef.modelZoom = 1650;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 1300;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33173:\n\t\t\titemDef.name = \"K'ril swords (sheathed)\";\n\t\t\titemDef.description = \"Sheath & Unsheath this sword in the Equipment tab. Hits an enemy twice.\";\n\t\t\titemDef.equipActions[2] = \"Unsheath\";\n\t\t\titemDef.modelId = 62556;\n\t\t\titemDef.maleModel = 62556;\n\t\t\titemDef.femaleModel = 62556;\n\t\t\titemDef.modelZoom = 1650;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 1300;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33174:\n\t\t\titemDef.name = \"Pet demonic gorilla\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 31241;\n\t\t\titemDef.modelZoom = 16000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33175:\n\t\t\titemDef.name = \"Pet crawling hand\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5071;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33176:\n\t\t\titemDef.name = \"Pet cave bug\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 23854;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33177:\n\t\t\titemDef.name = \"Pet cave crawler\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5066;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33178:\n\t\t\titemDef.name = \"Pet banshee\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5063;\n\t\t\titemDef.modelZoom = 3200;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33179:\n\t\t\titemDef.name = \"Pet cave slime\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5786;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33180:\n\t\t\titemDef.name = \"Pet rockslug\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5084;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33181:\n\t\t\titemDef.name = \"Pet cockatrice\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5070;\n\t\t\titemDef.modelZoom = 3200;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33182:\n\t\t\titemDef.name = \"Pet pyrefiend\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5083;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33183:\n\t\t\titemDef.name = \"Pet basilisk\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5064;\n\t\t\titemDef.modelZoom = 3000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33184:\n\t\t\titemDef.name = \"Pet infernal mage\";\n\t\t\titemDef.modifiedModelColors = new int[] { -26527, -24618, -25152, -25491, 119 };\n\t\t\titemDef.originalModelColors = new int[] { 924, 148, 0, 924, 924 };\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5047;\n\t\t\titemDef.modelZoom = 3940;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 84;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33185:\n\t\t\titemDef.name = \"Pet bloodveld\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5065;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33186:\n\t\t\titemDef.name = \"Pet jelly\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5081;\n\t\t\titemDef.modelZoom = 3000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33187:\n\t\t\titemDef.name = \"Pet turoth\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5086;\n\t\t\titemDef.modelZoom = 2600;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33188:\n\t\t\titemDef.name = \"Pet aberrant spectre\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5085;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 450;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33189:\n\t\t\titemDef.name = \"Pet dust devil\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5076;\n\t\t\titemDef.modelZoom = 3000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33190:\n\t\t\titemDef.name = \"Pet kurask\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5082;\n\t\t\titemDef.modelZoom = 5000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33191:\n\t\t\titemDef.name = \"Pet skeletal wyvern\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 10350;\n\t\t\titemDef.modelZoom = 1104;\n\t\t\titemDef.modelRotation1 = 27;\n\t\t\titemDef.modelRotation2 = 1634;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33192:\n\t\t\titemDef.name = \"Pet garygoyle\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5078;\n\t\t\titemDef.modelZoom = 4000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33193:\n\t\t\titemDef.name = \"Pet nechryael\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5074;\n\t\t\titemDef.modelZoom = 4000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33194:\n\t\t\titemDef.name = \"Pet abyssal demon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5062;\n\t\t\titemDef.modelZoom = 5000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33195:\n\t\t\titemDef.name = \"Pet dark beast\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 26395;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33196:\n\t\t\titemDef.name = \"Pet night beast\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32933;\n\t\t\titemDef.modelZoom = 7000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33197:\n\t\t\titemDef.name = \"Pet greater abyssal demon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32921;\n\t\t\titemDef.modelZoom = 5000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33198:\n\t\t\titemDef.name = \"Pet crushing hand\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32922;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33199:\n\t\t\titemDef.name = \"Pet chasm crawler\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32918;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33200:\n\t\t\titemDef.name = \"Pet screaming banshee\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32823;\n\t\t\titemDef.modelZoom = 5500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33201:\n\t\t\titemDef.name = \"Pet twisted banshee\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32847;\n\t\t\titemDef.modelZoom = 5500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33202:\n\t\t\titemDef.name = \"Pet giant rockslug\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32919;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33203:\n\t\t\titemDef.name = \"Pet cockathrice\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32920;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33204:\n\t\t\titemDef.name = \"Pet flaming pyrelord\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32923;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33205:\n\t\t\titemDef.name = \"Pet monstrous basilisk\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32924;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33206:\n\t\t\titemDef.name = \"Pet malevolent mage\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32929;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33207:\n\t\t\titemDef.name = \"Pet insatiable bloodveld\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32926;\n\t\t\titemDef.modelZoom = 5000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33208:\n\t\t\titemDef.name = \"Pet insatiable mutated bloodveld\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32925;\n\t\t\titemDef.modelZoom = 5000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33209:\n\t\t\titemDef.name = \"Pet vitreous jelly\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32852;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33210:\n\t\t\titemDef.name = \"Pet vitreous warped jelly\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32917;\n\t\t\titemDef.modelZoom = 6000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33211:\n\t\t\titemDef.name = \"Pet cave abomination\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32935;\n\t\t\titemDef.modelZoom = 5500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33212:\n\t\t\titemDef.name = \"Pet abhorrent spectre\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32930;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33213:\n\t\t\titemDef.name = \"pet repugnant spectre\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32926;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33214:\n\t\t\titemDef.name = \"Pet choke devil\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32927;\n\t\t\titemDef.modelZoom = 6000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33215:\n\t\t\titemDef.name = \"Pet king kurask\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32934;\n\t\t\titemDef.modelZoom = 8000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33217:\n\t\t\titemDef.name = \"Pet nuclear smoke devil\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32928;\n\t\t\titemDef.modelZoom = 5500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33218:\n\t\t\titemDef.name = \"Pet marble gargoyle\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34251;\n\t\t\titemDef.modelZoom = 8000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33219:\n\t\t\titemDef.name = \"Pet nechryarch\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32932;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33220:\n\t\t\titemDef.name = \"Pet Patrity\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32035;\n\t\t\titemDef.modelZoom = 653;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1535;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33221:\n\t\t\titemDef.name = \"Pet xarpus\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35383;\n\t\t\titemDef.modelZoom = 14000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33222:\n\t\t\titemDef.name = \"Pet nyclocas vasilias\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35182;\n\t\t\titemDef.modelZoom = 12000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33223:\n\t\t\titemDef.name = \"Pet pestilent bloat\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35404;\n\t\t\titemDef.modelZoom = 8500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33224:\n\t\t\titemDef.name = \"Pet maiden of sugadinti\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35385;\n\t\t\titemDef.modelZoom = 8500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33225:\n\t\t\titemDef.name = \"Pet lizardman shaman\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 4039;\n\t\t\titemDef.modelZoom = 8500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33226:\n\t\t\titemDef.name = \"Pet abyssal sire\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 29477;\n\t\t\titemDef.modelZoom = 9000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33227:\n\t\t\titemDef.name = \"Pet black demon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 31984;\n\t\t\titemDef.modelZoom = 1104;\n\t\t\titemDef.modelRotation1 = 144;\n\t\t\titemDef.modelRotation2 = 1826;\n\t\t\titemDef.modelOffset1 = 7;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 11802:\n\t\tcase 11804:\n\t\tcase 11806:\n\t\tcase 11808:\n\t\t\titemDef.equipActions[2] = \"Sheath\";\n\t\t\tbreak;// godsword sheathing operating\n\n\t\tcase 33228:\n\t\t\titemDef.name = \"Pet greater demon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32015;\n\t\t\titemDef.modelZoom = 902;\n\t\t\titemDef.modelRotation1 = 216;\n\t\t\titemDef.modelRotation2 = 138;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = -16;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33229:\n\t\t\titemDef.name = \"Armadyl godsword (sheathed)\";\n\t\t\titemDef.description = \"Armadyl godsword (sheathed)\";\n\t\t\titemDef.equipActions[2] = \"Unsheath\";\n\t\t\titemDef.modelId = 28075;\n\t\t\titemDef.maleModel = 62683;\n\t\t\titemDef.femaleModel = 62683;\n\t\t\titemDef.modelZoom = 1957;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 494;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33230:\n\t\t\titemDef.name = \"Bandos godsword (sheathed)\";\n\t\t\titemDef.description = \"Bandos godsword (sheathed)\";\n\t\t\titemDef.equipActions[2] = \"Unsheath\";\n\t\t\titemDef.modelId = 28059;\n\t\t\titemDef.maleModel = 62684;\n\t\t\titemDef.femaleModel = 62684;\n\t\t\titemDef.modelZoom = 1957;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 494;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33231:\n\t\t\titemDef.name = \"Saradomin godsword (sheathed)\";\n\t\t\titemDef.description = \"Saradomin godsword (sheathed)\";\n\t\t\titemDef.equipActions[2] = \"Unsheath\";\n\t\t\titemDef.modelId = 28070;\n\t\t\titemDef.maleModel = 62685;\n\t\t\titemDef.femaleModel = 62685;\n\t\t\titemDef.modelZoom = 1957;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 494;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33232:\n\t\t\titemDef.name = \"Zamorak godsword (sheathed)\";\n\t\t\titemDef.description = \"Zamorak godsword (sheathed)\";\n\t\t\titemDef.equipActions[2] = \"Unsheath\";\n\t\t\titemDef.modelId = 28060;\n\t\t\titemDef.maleModel = 62686;\n\t\t\titemDef.femaleModel = 62686;\n\t\t\titemDef.modelZoom = 1957;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 494;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33233:\n\t\t\titemDef.name = \"Pet revenant imp\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34156;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33234:\n\t\t\titemDef.name = \"Pet revenant goblin\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34262;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33235:\n\t\t\titemDef.name = \"Pet revenant pyrefiend\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34142;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33236:\n\t\t\titemDef.name = \"Pet revenant hobgoblin\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34157;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33237:\n\t\t\titemDef.name = \"Pet revenant cyclops\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34155;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33238:\n\t\t\titemDef.name = \"Pet revenant hellhound\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34143;\n\t\t\titemDef.modelZoom = 3500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33239:\n\t\t\titemDef.name = \"Pet revenant demon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32015;\n\t\t\titemDef.modifiedModelColors = new int[] { 1690, 910, 912, 1814, 1938 };\n\t\t\titemDef.originalModelColors = new int[] { 43078, 43078, 43078, 43078, 43078, 43078 };\n\t\t\titemDef.modelZoom = 902;\n\t\t\titemDef.modelRotation1 = 216;\n\t\t\titemDef.modelRotation2 = 138;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = -16;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33240:\n\t\t\titemDef.name = \"Pet revenant ork\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34154;\n\t\t\titemDef.modelZoom = 3500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33242:\n\t\t\titemDef.name = \"Pet revenant dark beast\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34158;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33243:\n\t\t\titemDef.name = \"Pet revenant knight\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34145;\n\t\t\titemDef.modelZoom = 3000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33244:\n\t\t\titemDef.name = \"Pet revenant dragon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34163;\n\t\t\titemDef.modelZoom = 7500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33245:\n\t\t\titemDef.name = \"Pet glob\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 26074;\n\t\t\titemDef.modelZoom = 10000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33246:\n\t\t\titemDef.name = \"Pet ice queen\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 104;\n\t\t\titemDef.modifiedModelColors = new int[] { 41, 61, 4550, 12224, 25238, 6798 };\n\t\t\titemDef.originalModelColors = new int[] { -22052, -26150, -24343, -22052, -22052, -23327 };\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33247:\n\t\t\titemDef.name = \"Pet enraged tarn\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60322;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33248:\n\t\t\titemDef.name = \"Pet jaltok-jad\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 33012;\n\t\t\titemDef.modelZoom = 12000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33249:\n\t\t\titemDef.name = \"Pet rune dragon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34668;\n\t\t\titemDef.modelZoom = 2541;\n\t\t\titemDef.modelRotation1 = 83;\n\t\t\titemDef.modelRotation2 = 1826;\n\t\t\titemDef.modelOffset1 = -97;\n\t\t\titemDef.modelOffset2 = 9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33271:\n\t\t\titemDef.name = \"Moo\";\n\t\t\titemDef.description = \"cow goes moo.\";\n\t\t\titemDef.modelId = 23889;\n\t\t\titemDef.modelZoom = 2541;\n\t\t\titemDef.modelRotation1 = 83;\n\t\t\titemDef.modelRotation2 = 1826;\n\t\t\titemDef.modelOffset1 = -97;\n\t\t\titemDef.modelOffset2 = 9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33250:\n\t\t\titemDef.name = \"Swift gloves (Black)\";\n\t\t\titemDef.description = \"Watch my speedy hands!\";\n\t\t\titemDef.modelId = 62655;\n\t\t\titemDef.maleModel = 62657;\n\t\t\titemDef.femaleModel = 62658;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33251:\n\t\t\titemDef.name = \"Swift gloves (Red)\";\n\t\t\titemDef.description = \"Watch my speedy hands!\";\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 65046, 65051, 65056 };\n\t\t\titemDef.modelId = 62655;\n\t\t\titemDef.maleModel = 62659;\n\t\t\titemDef.femaleModel = 62660;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33252:\n\t\t\titemDef.name = \"Swift gloves (White)\";\n\t\t\titemDef.description = \"Watch my speedy hands!\";\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 64585, 64590, 64595 };\n\t\t\titemDef.modelId = 62655;\n\t\t\titemDef.maleModel = 62661;\n\t\t\titemDef.femaleModel = 62662;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33253:\n\t\t\titemDef.name = \"Swift gloves (Yellow)\";\n\t\t\titemDef.description = \"Watch my speedy hands!\";\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 9767, 9772, 9777 };\n\t\t\titemDef.modelId = 62655;\n\t\t\titemDef.maleModel = 62663;\n\t\t\titemDef.femaleModel = 62664;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33254:\n\t\t\titemDef.name = \"Spellcaster gloves (Black)\";\n\t\t\titemDef.description = \"\tSome pretty fantastical gloves.\";\n\t\t\titemDef.modelId = 62656;\n\t\t\titemDef.maleModel = 62665;\n\t\t\titemDef.femaleModel = 62666;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33255:\n\t\t\titemDef.name = \"Spellcaster gloves (Red)\";\n\t\t\titemDef.description = \"\tSome pretty fantastical gloves.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 65046, 65051, 65056 };\n\t\t\titemDef.modelId = 62656;\n\t\t\titemDef.maleModel = 62667;\n\t\t\titemDef.femaleModel = 62668;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33256:\n\t\t\titemDef.name = \"Spellcaster gloves (White)\";\n\t\t\titemDef.description = \"\tSome pretty fantastical gloves.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 64585, 64590, 64595 };\n\t\t\titemDef.modelId = 62656;\n\t\t\titemDef.maleModel = 62669;\n\t\t\titemDef.femaleModel = 62670;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33257:\n\t\t\titemDef.name = \"Spellcaster gloves (Yellow)\";\n\t\t\titemDef.description = \"\tSome pretty fantastical gloves.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 9767, 9772, 9777 };\n\t\t\titemDef.modelId = 62656;\n\t\t\titemDef.maleModel = 62671;\n\t\t\titemDef.femaleModel = 62672;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33258:\n\t\t\titemDef.name = \"Tekton longsword\";\n\t\t\titemDef.description = \"Tekton longsword.\";\n\t\t\titemDef.modelId = 62682;\n\t\t\titemDef.maleModel = 62681;\n\t\t\titemDef.femaleModel = 62681;\n\t\t\titemDef.modelZoom = 1445;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33259:\n\t\t\titemDef.name = \"Pet wyrm\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 36922;\n\t\t\titemDef.modelZoom = 2547;\n\t\t\titemDef.modelRotation1 = 97;\n\t\t\titemDef.modelRotation2 = 1820;\n\t\t\titemDef.modelOffset1 = -7;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33260:\n\t\t\titemDef.name = \"Pet drake\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 36160;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33261:\n\t\t\titemDef.name = \"Pet wyrm\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 36922;\n\t\t\titemDef.modelZoom = 2547;\n\t\t\titemDef.modelRotation1 = 97;\n\t\t\titemDef.modelRotation2 = 1820;\n\t\t\titemDef.modelOffset1 = -7;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33262:\n\t\t\titemDef.name = \"Valentines Balloon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 62766;\n\t\t\titemDef.maleModel = 62767;\n\t\t\titemDef.femaleModel = 62767;\n\t\t\titemDef.modelZoom = 2200;\n\t\t\titemDef.modelRotation1 = 270;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33263:\n\t\t\titemDef.name = \"Cupid bow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 62768;\n\t\t\titemDef.maleModel = 62769;\n\t\t\titemDef.femaleModel = 62769;\n\t\t\titemDef.modelZoom = 1072;\n\t\t\titemDef.modelRotation1 = 127;\n\t\t\titemDef.modelRotation2 = 103;\n\t\t\titemDef.modelOffset1 = -5;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33264:\n\t\t\titemDef.name = \"Halo and horns\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 62771;\n\t\t\titemDef.maleModel = 62770;\n\t\t\titemDef.femaleModel = 62770;\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation1 = 228;\n\t\t\titemDef.modelRotation2 = 141;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33265:\n\t\t\titemDef.name = \"Heart\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 62782;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33266:\n\t\t\titemDef.name = \"Valentines mystery box\";\n\t\t\titemDef.description = \"You make me hard.\";\n\t\t\titemDef.modelId = 62773;\n\t\t\titemDef.modelZoom = 464;\n\t\t\titemDef.modelRotation1 = 423;\n\t\t\titemDef.modelRotation2 = 1928;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Open\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33267:\n\t\t\titemDef.name = \"Staff of adoration\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 62774;\n\t\t\titemDef.maleModel = 62775;\n\t\t\titemDef.femaleModel = 62775;\n\t\t\titemDef.modelZoom = 1579;\n\t\t\titemDef.modelRotation1 = 660;\n\t\t\titemDef.modelRotation2 = 48;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33268:\n\t\t\titemDef.name = \"Valentines crossbow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 62778;\n\t\t\titemDef.maleModel = 62779;\n\t\t\titemDef.femaleModel = 62779;\n\t\t\titemDef.modelZoom = 1200;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 258;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33269:\n\t\t\titemDef.name = \"Onyxia Mystery Box\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 2426;\n\t\t\titemDef.modelZoom = 1180;\n\t\t\titemDef.modelRotation1 = 160;\n\t\t\titemDef.modelRotation2 = 172;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -14;\n\t\t\titemDef.modifiedModelColors = new int[] { 22410, 2999 };\n\t\t\titemDef.originalModelColors = new int[] { 2130, 38693 };\n\t\t\titemDef.description = \"Chances at several unqiue items found only in this box! (ex: Tekton Armor)\";\n\t\t\tbreak;\n\t\tcase 33270:\n\t\t\titemDef.name = \"Dragon Hunter Box\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 2426;\n\t\t\titemDef.modelZoom = 1180;\n\t\t\titemDef.modelRotation1 = 160;\n\t\t\titemDef.modelRotation2 = 172;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -14;\n\t\t\titemDef.modifiedModelColors = new int[] { 22410, 2999 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 1050 };\n\t\t\titemDef.description = \"Chances for items that give bonuses toward dragons. (ex: Dragonhunter Lance)\";\n\t\t\tbreak;\n\t\tcase 33273:\n\t\t\titemDef.name = \"Ancient sword\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60201;\n\t\t\titemDef.maleModel = 60200;\n\t\t\titemDef.femaleModel = 60200;\n\t\t\titemDef.modelZoom = 1900;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33274:\n\t\t\titemDef.name = \"Armadyl staff\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60203;\n\t\t\titemDef.maleModel = 60202;\n\t\t\titemDef.femaleModel = 60202;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33275:\n\t\t\titemDef.name = \"Bork axe\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60205;\n\t\t\titemDef.maleModel = 60204;\n\t\t\titemDef.femaleModel = 60204;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33276:\n\t\t\titemDef.name = \"Bree bow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60207;\n\t\t\titemDef.maleModel = 60206;\n\t\t\titemDef.femaleModel = 60206;\n\t\t\titemDef.modelZoom = 1700;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33277:\n\t\t\titemDef.name = \"Infernal staff\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60209;\n\t\t\titemDef.maleModel = 60208;\n\t\t\titemDef.femaleModel = 60208;\n\t\t\titemDef.modelZoom = 2200;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33278:\n\t\t\titemDef.name = \"Infernal longsword\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60211;\n\t\t\titemDef.maleModel = 60210;\n\t\t\titemDef.femaleModel = 60210;\n\t\t\titemDef.modelZoom = 1900;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33279:\n\t\t\titemDef.name = \"Necrolord staff\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60213;\n\t\t\titemDef.maleModel = 60212;\n\t\t\titemDef.femaleModel = 60212;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33280:\n\t\t\titemDef.name = \"Insert name here\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60215;\n\t\t\titemDef.maleModel = 60214;\n\t\t\titemDef.femaleModel = 60214;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33281:\n\t\t\titemDef.name = \"Infernal bow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60219;\n\t\t\titemDef.maleModel = 60218;\n\t\t\titemDef.femaleModel = 60218;\n\t\t\titemDef.modelZoom = 3334;\n\t\t\titemDef.modelRotation1 = 533;\n\t\t\titemDef.modelRotation2 = 1294;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33282:\n\t\t\titemDef.name = \"Infernal warhammer\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60221;\n\t\t\titemDef.maleModel = 60220;\n\t\t\titemDef.femaleModel = 60220;\n\t\t\titemDef.modelZoom = 2512;\n\t\t\titemDef.modelRotation1 = 317;\n\t\t\titemDef.modelRotation2 = 1988;\n\t\t\titemDef.modelOffset1 = -8;\n\t\t\titemDef.modelOffset2 = 45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33283:\n\t\t\titemDef.name = \"Imbued Porazdir's heart\";\n\t\t\titemDef.modelId = 32298;\n\t\t\titemDef.modelZoom = 1168;\n\t\t\titemDef.modelRotation1 = 96;\n\t\t\titemDef.modelRotation2 = 1690;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 60826, 59796, 54544, 58904, 54561 };\n\t\t\titemDef.originalModelColors = new int[] { 13263, 13014, 13243, 13000, 13275 };\n\t\t\titemDef.inventoryOptions = new String[] { \"Invigorate\", null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Boosts your strength for a period of time.\";\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33284:\n\t\t\titemDef.name = \"Imbued Justiciar's heart\";\n\t\t\titemDef.modelId = 32298;\n\t\t\titemDef.modelZoom = 1168;\n\t\t\titemDef.modelRotation1 = 96;\n\t\t\titemDef.modelRotation2 = 1690;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 60826, 59796, 54544, 58904, 54561 };\n\t\t\titemDef.originalModelColors = new int[] { 31661, 31418, 31661, 31167, 31445 };\n\t\t\titemDef.inventoryOptions = new String[] { \"Invigorate\", null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Boosts your Defence for a period of time.\";\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32285:\n\t\t\titemDef.name = \"Imbued Derwen's heart\";\n\t\t\titemDef.modelId = 32298;\n\t\t\titemDef.modelZoom = 1168;\n\t\t\titemDef.modelRotation1 = 96;\n\t\t\titemDef.modelRotation2 = 1690;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 60826, 59796, 54544, 58904, 54561 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 930, 936, 940, 950 };\n\t\t\titemDef.inventoryOptions = new String[] { \"Invigorate\", null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Boosts your Attack for a period of time.\";\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32286:\n\t\t\titemDef.name = \"Bronze fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 5652, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32287:\n\t\t\titemDef.name = \"Iron fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 33, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32288:\n\t\t\titemDef.name = \"Steel fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 61, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32289:\n\t\t\titemDef.name = \"Black fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 0, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32290:\n\t\t\titemDef.name = \"Mithril fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 43297, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32291:\n\t\t\titemDef.name = \"Adamant fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 21662, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32292:\n\t\t\titemDef.name = \"Rune fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 36133, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32293:\n\t\t\titemDef.name = \"Dragon fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing. Can also be used for Deep sea fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 924, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32294:\n\t\t\titemDef.name = \"Raw eel\";\n\t\t\titemDef.description = \"Slimy\";\n\t\t\titemDef.modelId = 6856;\n\t\t\titemDef.modelZoom = 1440;\n\t\t\titemDef.modelRotation1 = 296;\n\t\t\titemDef.modelRotation2 = 352;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = 42;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32295:\n\t\t\titemDef.name = \"Burnt eel\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 6856;\n\t\t\titemDef.modelZoom = 1440;\n\t\t\titemDef.modelRotation1 = 296;\n\t\t\titemDef.modelRotation2 = 352;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = 42;\n\t\t\titemDef.modifiedModelColors = new int[] { 8485, 14622, 12589 };\n\t\t\titemDef.originalModelColors = new int[] { 8724, 3226, 9754 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32296:\n\t\t\titemDef.name = \"Eel\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Eat\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 6856;\n\t\t\titemDef.modelZoom = 1440;\n\t\t\titemDef.modelRotation1 = 296;\n\t\t\titemDef.modelRotation2 = 352;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = 42;\n\t\t\titemDef.modifiedModelColors = new int[] { 8485, 14622, 8386, 12589 };\n\t\t\titemDef.originalModelColors = new int[] { 8088, 6032, 57, 2960 };\n\t\t\titemDef.description = \"None\";\n\t\t\tbreak;\n\n\t\tcase 32297:\n\t\t\titemDef.name = \"Raw baron shark\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 2594;\n\t\t\titemDef.modelZoom = 1860;\n\t\t\titemDef.modelRotation1 = 344;\n\t\t\titemDef.modelRotation2 = 12;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 12;\n\t\t\titemDef.modifiedModelColors = new int[] { 103, 103 };\n\t\t\titemDef.originalModelColors = new int[] { 7756, 5349 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32298:\n\t\t\titemDef.name = \"Burnt baron shark\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 2594;\n\t\t\titemDef.modelZoom = 1860;\n\t\t\titemDef.modelRotation1 = 344;\n\t\t\titemDef.modelRotation2 = 12;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 12;\n\t\t\titemDef.modifiedModelColors = new int[] { 61, 103 };\n\t\t\titemDef.originalModelColors = new int[] { 28, 41 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32299:\n\t\t\titemDef.name = \"Baron shark\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Eat\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 2594;\n\t\t\titemDef.modelZoom = 1860;\n\t\t\titemDef.modelRotation1 = 344;\n\t\t\titemDef.modelRotation2 = 12;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 12;\n\t\t\titemDef.modifiedModelColors = new int[] { 61, 103 };\n\t\t\titemDef.originalModelColors = new int[] { 8109, 4795 };\n\t\t\titemDef.description = \"None\";\n\t\t\tbreak;\n\n\t\tcase 32300:\n\t\t\titemDef.name = \"Raw cavefish\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60223;\n\t\t\titemDef.modelZoom = 1284;\n\t\t\titemDef.modelRotation1 = 499;\n\t\t\titemDef.modelRotation2 = 1907;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32301:\n\t\t\titemDef.name = \"Burnt cavefish\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60227;\n\t\t\titemDef.modelZoom = 1284;\n\t\t\titemDef.modelRotation1 = 499;\n\t\t\titemDef.modelRotation2 = 1907;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32302:\n\t\t\titemDef.name = \"Cavefish\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Eat\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 60228;\n\t\t\titemDef.modelZoom = 1284;\n\t\t\titemDef.modelRotation1 = 499;\n\t\t\titemDef.modelRotation2 = 1907;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.description = \"None\";\n\t\t\tbreak;\n\n\t\tcase 32303:\n\t\t\titemDef.name = \"Dragonfire visage (e)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 26456;\n\t\t\titemDef.modelZoom = 1697;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 152;\n\t\t\titemDef.modelOffset1 = -5;\n\t\t\titemDef.modelOffset2 = -5;\n\t\t\titemDef.modifiedModelColors = new int[] { 45, 41, 33, 24, 20, 57, 22, 37 };\n\t\t\titemDef.originalModelColors = new int[] { 0, 1, 2, 3, 4, 5, 6, 7 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33285:\n\t\t\titemDef.name = \"Easter Mystery Box\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 61110;\n\t\t\titemDef.modelZoom = 1180;\n\t\t\titemDef.modelRotation1 = 160;\n\t\t\titemDef.modelRotation2 = 172;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -14;\n\t\t\t// itemDef.modifiedModelColors = new int[] {22410, 2999};\n\t\t\t// itemDef.originalModelColors = new int[] {35321, 350};\n\t\t\titemDef.description = \"Chances for all sorts of Easter Items!\";\n\t\t\tbreak;\n\n\t\tcase 33286:\n\t\t\titemDef.name = \"Easter Cape\";\n\t\t\titemDef.inventoryOptions = new String[] { null, \"wear\", null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 9631;\n\t\t\titemDef.maleModel = 9638;\n\t\t\titemDef.femaleModel = 9640;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"An Easter Cape.\";\n\t\t\tbreak;\n\n\t\tcase 33287:\n\t\t\titemDef.name = \"Pet Easter Bunny\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 37239;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"You've captured the Easter bunny!\";\n\t\t\tbreak;\n\n\t\tcase 33288:\n\t\t\titemDef.name = \"Pet Choco\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 37239;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"mmm... a chocolate bunny\";\n\t\t\titemDef.modifiedModelColors = new int[] { 2378 };\n\t\t\titemDef.originalModelColors = new int[] { 7079 };\n\t\t\tbreak;\n\n\t\tcase 33289:\n\t\t\titemDef.name = \"Pet Milkie\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 37239;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"mmm... a chocolate bunny\";\n\t\t\titemDef.modifiedModelColors = new int[] { 2378 };\n\t\t\titemDef.originalModelColors = new int[] { 6040 };\n\t\t\tbreak;\n\n\t\tcase 33290:\n\t\t\titemDef.name = \"Pet Goldie\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 37239;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"oh wow... a rare golden bunny!\";\n\t\t\titemDef.modifiedModelColors = new int[] { 2378 };\n\t\t\titemDef.originalModelColors = new int[] { 9152 };\n\t\t\tbreak;\n\n\t\tcase 33291:\n\t\t\titemDef.name = \"Pet Blue\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 37239;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"A blue bunny... kinda looks like the easter bunny!\";\n\t\t\titemDef.modifiedModelColors = new int[] { 2378 };\n\t\t\titemDef.originalModelColors = new int[] { 35321 };\n\t\t\tbreak;\n\n\t\tcase 33292:\n\t\t\titemDef.name = \"Crazed bunny\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 23901;\n\t\t\titemDef.modelZoom = 500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"What a bloody mess...\";\n\t\t\titemDef.modifiedModelColors = new int[] { 5413, 5417, 5421 };\n\t\t\titemDef.originalModelColors = new int[] { 935, 111, 127 };\n\t\t\tbreak;\n\n\t\tcase 33293:\n\t\t\titemDef.name = \"Peter Rabbit\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 28602;\n\t\t\titemDef.modelZoom = 500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"Hi Peter!\";\n\t\t\tbreak;\n\n\t\tcase 33294:\n\t\t\titemDef.name = \"Chocolate Chicken\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 35150;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1731;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"a chocolate chicken\";\n\t\t\titemDef.modifiedModelColors = new int[] { 947 };\n\t\t\titemDef.originalModelColors = new int[] { 8128 };\n\t\t\tbreak;\n\n\t\tcase 33295:\n\t\t\titemDef.name = \"Chocolate Chicken\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 35150;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1731;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"a chocolate chicken\";\n\t\t\titemDef.modifiedModelColors = new int[] { 947, 8301 };\n\t\t\titemDef.originalModelColors = new int[] { 8128, 25511 };\n\t\t\tbreak;\n\n\t\tcase 33296:\n\t\t\titemDef.name = \"Chocolate Chicken\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 35150;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1731;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"a chocolate chicken\";\n\t\t\titemDef.modifiedModelColors = new int[] { 947, 8301 };\n\t\t\titemDef.originalModelColors = new int[] { 8128, 38835 };\n\t\t\tbreak;\n\n\t\tcase 33297:\n\t\t\titemDef.name = \"Chocolate Chicken\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 35150;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1731;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"a chocolate chicken\";\n\t\t\titemDef.modifiedModelColors = new int[] { 947, 8301 };\n\t\t\titemDef.originalModelColors = new int[] { 8128, 947 };\n\t\t\tbreak;\n\n\t\tcase 33305:\n\t\t\titemDef.name = \"$10 bond\";\n\t\t\titemDef.description = \"$10 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 84, 84, 84, 84, 84, 84, 84 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33306:\n\t\t\titemDef.name = \"$25 bond\";\n\t\t\titemDef.description = \"$25 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 87, 87, 87, 87, 87, 87, 87 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33307:\n\t\t\titemDef.name = \"$50 bond\";\n\t\t\titemDef.description = \"$50 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 65, 65, 65, 65, 65, 65, 65 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33308:\n\t\t\titemDef.name = \"$100 bond\";\n\t\t\titemDef.description = \"$25 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 75, 75, 75, 75, 75, 75, 75 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33309:\n\t\t\titemDef.name = \"$200 bond\";\n\t\t\titemDef.description = \"$200 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 88, 88, 88, 88, 88, 88, 88 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33310:\n\t\t\titemDef.name = \"$500 bond\";\n\t\t\titemDef.description = \"$500 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 85, 85, 85, 85, 85, 85, 85 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33311:\n\t\t\titemDef.name = \"$1000 bond\";\n\t\t\titemDef.description = \"$1000 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 86, 86, 86, 86, 86, 86, 86 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33312:\n\t\t\titemDef.name = \"Armadyl battlestaff\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60332;\n\t\t\titemDef.maleModel = 60333;\n\t\t\titemDef.femaleModel = 60333;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 225;\n\t\t\titemDef.modelRotation2 = 1994;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\n\t\tcase 33313:\n\t\t\titemDef.name = \"Colossal platebody\";\n\t\t\titemDef.description = \"Colossal platebody.\";\n\t\t\titemDef.modelId = 60323;\n\t\t\titemDef.maleModel = 60324;\n\t\t\titemDef.femaleModel = 60324;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33314:\n\t\t\titemDef.name = \"Colossal platelegs\";\n\t\t\titemDef.description = \"Colossal platelegs.\";\n\t\t\titemDef.modelId = 60325;\n\t\t\titemDef.maleModel = 60326;\n\t\t\titemDef.femaleModel = 60326;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33315:\n\t\t\titemDef.name = \"Colossal boots\";\n\t\t\titemDef.description = \"Colossal boots.\";\n\t\t\titemDef.modelId = 60329;\n\t\t\titemDef.maleModel = 60329;\n\t\t\titemDef.femaleModel = 60329;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33316:\n\t\t\titemDef.name = \"Colossal gloves\";\n\t\t\titemDef.description = \"Colossal gloves.\";\n\t\t\titemDef.modelId = 60330;\n\t\t\titemDef.maleModel = 60331;\n\t\t\titemDef.femaleModel = 60331;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33317:\n\t\t\titemDef.name = \"Colossal helmet\";\n\t\t\titemDef.description = \"Colossal helmet.\";\n\t\t\titemDef.modelId = 60327;\n\t\t\titemDef.maleModel = 60328;\n\t\t\titemDef.femaleModel = 60328;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\n\t\tcase 33318:\n\t\t\titemDef.name = \"Polypore staff\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60334;\n\t\t\titemDef.maleModel = 60335;\n\t\t\titemDef.femaleModel = 60335;\n\t\t\titemDef.modelZoom = 3750;\n\t\t\titemDef.modelRotation1 = 1454;\n\t\t\titemDef.modelRotation2 = 997;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\n\t\tcase 33319:\n\t\t\titemDef.name = \"Ganodermic platebody\";\n\t\t\titemDef.description = \"Ganodermic platebody.\";\n\t\t\titemDef.modelId = 60338;\n\t\t\titemDef.maleModel = 60339;\n\t\t\titemDef.femaleModel = 60339;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33320:\n\t\t\titemDef.name = \"Ganodermic platelegs\";\n\t\t\titemDef.description = \"Ganodermic platelegs.\";\n\t\t\titemDef.modelId = 60340;\n\t\t\titemDef.maleModel = 60341;\n\t\t\titemDef.femaleModel = 60341;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33321:\n\t\t\titemDef.name = \"Ganodermic helmet\";\n\t\t\titemDef.description = \"Ganodermic helmet.\";\n\t\t\titemDef.modelId = 60336;\n\t\t\titemDef.maleModel = 60337;\n\t\t\titemDef.femaleModel = 60337;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\n\t\tcase 33322:\n\t\t\titemDef.name = \"Grotesque platebody\";\n\t\t\titemDef.description = \"Grosteq platebody.\";\n\t\t\titemDef.modelId = 60347;\n\t\t\titemDef.maleModel = 60348;\n\t\t\titemDef.femaleModel = 60348;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33323:\n\t\t\titemDef.name = \"Grotesque platelegs\";\n\t\t\titemDef.description = \"Grosteq platelegs.\";\n\t\t\titemDef.modelId = 60349;\n\t\t\titemDef.maleModel = 60350;\n\t\t\titemDef.femaleModel = 60350;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33324:\n\t\t\titemDef.name = \"Grotesque helmet\";\n\t\t\titemDef.description = \"Grosteqc helmet.\";\n\t\t\titemDef.modelId = 60345;\n\t\t\titemDef.maleModel = 60346;\n\t\t\titemDef.femaleModel = 60346;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\n\t\tcase 33325:\n\t\t\titemDef.name = \"Grotesque cape\";\n\t\t\titemDef.description = \"Grosteq cape.\";\n\t\t\titemDef.modelId = 60351;\n\t\t\titemDef.maleModel = 60352;\n\t\t\titemDef.femaleModel = 60352;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33326:\n\t\t\titemDef.name = \"Stunning Hammer\";\n\t\t\titemDef.description = \"Has a chance to stun an enemy.\";\n\t\t\titemDef.modelId = 60353;\n\t\t\titemDef.maleModel = 60354;\n\t\t\titemDef.femaleModel = 60354;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1985;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\n\t\tcase 33327:\n\t\t\titemDef.name = \"Stunning Katagon platebody\";\n\t\t\titemDef.description = \"has a chance to stun an enemy.\";\n\t\t\titemDef.modelId = 60356;\n\t\t\titemDef.maleModel = 60357;\n\t\t\titemDef.femaleModel = 60357;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33328:\n\t\t\titemDef.name = \"Stunning Katagon platelegs\";\n\t\t\titemDef.description = \"has a chance to stun an enemy.\";\n\t\t\titemDef.modelId = 60358;\n\t\t\titemDef.maleModel = 60359;\n\t\t\titemDef.femaleModel = 60359;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33329:\n\t\t\titemDef.name = \"Stunning Katagon helmet\";\n\t\t\titemDef.description = \"has a chance to stun an enemy.\";\n\t\t\titemDef.modelId = 60360;\n\t\t\titemDef.maleModel = 60361;\n\t\t\titemDef.femaleModel = 60361;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\n\t\tcase 33331:\n\t\t\titemDef.name = \"Ancient platebody\";\n\t\t\titemDef.description = \"Ancient platebody.\";\n\t\t\titemDef.modelId = 60366;\n\t\t\titemDef.maleModel = 60367;\n\t\t\titemDef.femaleModel = 60367;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33332:\n\t\t\titemDef.name = \"Ancient platelegs\";\n\t\t\titemDef.description = \"Ancient platelegs.\";\n\t\t\titemDef.modelId = 60368;\n\t\t\titemDef.maleModel = 60369;\n\t\t\titemDef.femaleModel = 60369;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33334:\n\t\t\titemDef.name = \"Ancient boots\";\n\t\t\titemDef.description = \"Ancient boots.\";\n\t\t\titemDef.modelId = 60372;\n\t\t\titemDef.maleModel = 60372;\n\t\t\titemDef.femaleModel = 60372;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33335:\n\t\t\titemDef.name = \"Ancient gloves\";\n\t\t\titemDef.description = \"Ancient gloves.\";\n\t\t\titemDef.modelId = 60370;\n\t\t\titemDef.maleModel = 60371;\n\t\t\titemDef.femaleModel = 60371;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33336:\n\t\t\titemDef.name = \"Ancient helmet\";\n\t\t\titemDef.description = \"Ancient helmet.\";\n\t\t\titemDef.modelId = 60364;\n\t\t\titemDef.maleModel = 60365;\n\t\t\titemDef.femaleModel = 60365;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\n\t\tcase 33341:\n\t\t\titemDef.name = \"Vanguard helmet\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60391;\n\t\t\titemDef.maleModel = 60392;\n\t\t\titemDef.femaleModel = 60392;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\n\t\tcase 33342:\n\t\t\titemDef.name = \"Vanguard platebody\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60393;\n\t\t\titemDef.maleModel = 60394;\n\t\t\titemDef.femaleModel = 60394;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33343:\n\t\t\titemDef.name = \"Vanguard platelegs\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60395;\n\t\t\titemDef.maleModel = 60396;\n\t\t\titemDef.femaleModel = 60396;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33344:\n\t\t\titemDef.name = \"Vanguard boots\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60398;\n\t\t\titemDef.maleModel = 60398;\n\t\t\titemDef.femaleModel = 60398;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33345:\n\t\t\titemDef.name = \"Vanguard gloves\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60373;\n\t\t\titemDef.maleModel = 60397;\n\t\t\titemDef.femaleModel = 60397;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33346:\n\t\t\titemDef.name = \"Celestial staff of light\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60401;\n\t\t\titemDef.maleModel = 60402;\n\t\t\titemDef.femaleModel = 60402;\n\t\t\titemDef.modelZoom = 3200;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 101 };\n\t\t\titemDef.originalModelColors = new int[] { 12 };\n\t\t\titemDef.maleOffset = -6;\n\t\t\titemDef.femaleOffset = -6;\n\t\t\tbreak;\n\n\t\tcase 33347:\n\t\t\titemDef.name = \"Hood of sorrow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60438;\n\t\t\titemDef.maleModel = 60403;\n\t\t\titemDef.femaleModel = 60403;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33348:\n\t\t\titemDef.name = \"Celestial robe top\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60404;\n\t\t\titemDef.maleModel = 60405;\n\t\t\titemDef.femaleModel = 60405;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33349:\n\t\t\titemDef.name = \"Celestial robe legs\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60406;\n\t\t\titemDef.maleModel = 60407;\n\t\t\titemDef.femaleModel = 60407;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33350:\n\t\t\titemDef.name = \"Primal 2h sword\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60408;\n\t\t\titemDef.maleModel = 60409;\n\t\t\titemDef.femaleModel = 60409;\n\t\t\titemDef.modelZoom = 1701;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.modelRotation2 = 1529;\n\t\t\titemDef.modelRotation1 = 1713;\n\t\t\titemDef.modelRotationY = 898;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\titemDef.maleOffset = -7;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33353:\n\t\t\titemDef.name = \"Primal longsword\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60417;\n\t\t\titemDef.maleModel = 60418;\n\t\t\titemDef.femaleModel = 60418;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.modelRotation2 = 1793;\n\t\t\titemDef.modelRotation1 = 1473;\n\t\t\titemDef.modelRotationY = 1121;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\titemDef.maleOffset = -7;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33354:\n\t\t\titemDef.name = \"Primal maul\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60419;\n\t\t\titemDef.maleModel = 60420;\n\t\t\titemDef.femaleModel = 60420;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 525;\n\t\t\titemDef.modelRotation2 = 350;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\titemDef.maleOffset = -7;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33359:\n\t\t\titemDef.name = \"Primal rapier\";\n\t\t\titemDef.description = \"Good for fighting the ...\";\n\t\t\titemDef.modelId = 60433;\n\t\t\titemDef.maleModel = 60433;\n\t\t\titemDef.femaleModel = 60433;\n\t\t\titemDef.modelZoom = 1300;\n\t\t\titemDef.modelRotation1 = 1401;\n\t\t\titemDef.modelRotation2 = 1724;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = 15;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\titemDef.maleOffset = -7;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33360:\n\t\t\titemDef.name = \"Primal spear\";\n\t\t\titemDef.description = \"Good for fighting the Corperal Beast.\";\n\t\t\titemDef.modelId = 60434;\n\t\t\titemDef.maleModel = 60435;\n\t\t\titemDef.femaleModel = 60435;\n\t\t\titemDef.modelZoom = 1711;\n\t\t\titemDef.modelRotation1 = 485;\n\t\t\titemDef.modelRotation2 = 391;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.femaleOffset = -10;\n\t\t\titemDef.maleOffset = -10;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33361:\n\t\t\titemDef.name = \"Primal warhammer\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60436;\n\t\t\titemDef.maleModel = 60437;\n\t\t\titemDef.femaleModel = 60437;\n\t\t\titemDef.modelZoom = 1330;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 148;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\titemDef.maleOffset = -7;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33362:\n\t\t\titemDef.name = \"Chitin helmet\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60445;\n\t\t\titemDef.maleModel = 60446;\n\t\t\titemDef.femaleModel = 60446;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33364:\n\t\t\titemDef.name = \"Chitin platebody\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60447;\n\t\t\titemDef.maleModel = 60448;\n\t\t\titemDef.femaleModel = 60448;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33365:\n\t\t\titemDef.name = \"Chitin platelegs\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60449;\n\t\t\titemDef.maleModel = 60450;\n\t\t\titemDef.femaleModel = 60450;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33366:\n\t\t\titemDef.name = \"Chitin cape\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60443;\n\t\t\titemDef.maleModel = 60444;\n\t\t\titemDef.femaleModel = 60444;\n\t\t\titemDef.modelZoom = 1500;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = -4;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33367:\n\t\t\titemDef.name = \"Supreme void helmet\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60467;\n\t\t\titemDef.maleModel = 60464;\n\t\t\titemDef.femaleModel = 60464;\n\t\t\titemDef.modelZoom = 900;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33368:\n\t\t\titemDef.name = \"Supreme void robe top\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60468;\n\t\t\titemDef.maleModel = 60465;\n\t\t\titemDef.femaleModel = 60465;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33369:\n\t\t\titemDef.name = \"Supreme void robe\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60469;\n\t\t\titemDef.maleModel = 60466;\n\t\t\titemDef.femaleModel = 60466;\n\t\t\titemDef.modelZoom = 1900;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33370:\n\t\t\titemDef.name = \"Korasi's sword\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60471;\n\t\t\titemDef.maleModel = 60470;\n\t\t\titemDef.femaleModel = 60470;\n\t\t\titemDef.modelZoom = 1744;\n\t\t\titemDef.modelRotation1 = 330;\n\t\t\titemDef.modelRotation2 = 1505;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = -4;\n\t\t\titemDef.femaleOffset = -4;\n\t\t\tbreak;\n\n\t\tcase 33371:\n\t\t\titemDef.name = \"Spiked slayer helmet\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60475;\n\t\t\titemDef.maleModel = 60476;\n\t\t\titemDef.femaleModel = 60476;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33372:\n\t\t\titemDef.name = \"Slayer platebody\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60478;\n\t\t\titemDef.maleModel = 60479;\n\t\t\titemDef.femaleModel = 60479;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33373:\n\t\t\titemDef.name = \"Slayer platelegs\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60474;\n\t\t\titemDef.maleModel = 60477;\n\t\t\titemDef.femaleModel = 60477;\n\t\t\titemDef.modelZoom = 1900;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33374:\n\t\t\titemDef.name = \"Slayer boots\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60472;\n\t\t\titemDef.maleModel = 60473;\n\t\t\titemDef.femaleModel = 60473;\n\t\t\titemDef.modelZoom = 789;\n\t\t\titemDef.modelRotation1 = 164;\n\t\t\titemDef.modelRotation2 = 156;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33375:\n\t\t\titemDef.name = \"Blood Justiciar helmet\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60482;\n\t\t\titemDef.maleModel = 60483;\n\t\t\titemDef.femaleModel = 60483;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33376:\n\t\t\titemDef.name = \"Blood Justiciar platebody\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60484;\n\t\t\titemDef.maleModel = 60485;\n\t\t\titemDef.femaleModel = 60485;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33377:\n\t\t\titemDef.name = \"Blood justiciar platelegs\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60486;\n\t\t\titemDef.maleModel = 60487;\n\t\t\titemDef.femaleModel = 60487;\n\t\t\titemDef.modelZoom = 1900;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33378:\n\t\t\titemDef.name = \"Blood justiciar boots\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60488;\n\t\t\titemDef.maleModel = 60488;\n\t\t\titemDef.femaleModel = 60488;\n\t\t\titemDef.modelZoom = 789;\n\t\t\titemDef.modelRotation1 = 164;\n\t\t\titemDef.modelRotation2 = 156;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33379:\n\t\t\titemDef.name = \"Blood justiciar gloves\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60489;\n\t\t\titemDef.maleModel = 60490;\n\t\t\titemDef.femaleModel = 60490;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33380:\n\t\t\titemDef.name = \"Blood scythe of vitur\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60480;\n\t\t\titemDef.maleModel = 60481;\n\t\t\titemDef.femaleModel = 60481;\n\t\t\titemDef.modelZoom = 3850;\n\t\t\titemDef.modelRotation1 = 727;\n\t\t\titemDef.modelRotation2 = 997;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33381:\n\t\t\titemDef.name = \"Skiller cape\";\n\t\t\titemDef.description = \"Skiller cape.\";\n\t\t\titemDef.modelId = 60494;\n\t\t\titemDef.maleModel = 60493;\n\t\t\titemDef.femaleModel = 60492;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33382:\n\t\t\titemDef.name = \"Justiciar faceguard (zamorak)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 4550 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 926, 926, 926 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33383:\n\t\t\titemDef.name = \"Justiciar faceguard (guthix)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 4550 };\n\t\t\titemDef.originalModelColors = new int[] { 21939, 21945, 21952, 21954 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33384:\n\t\t\titemDef.name = \"Justiciar faceguard (saradomin)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 4550 };\n\t\t\titemDef.originalModelColors = new int[] { 43929, 43929, 43929, 43929 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33385:\n\t\t\titemDef.name = \"Justiciar faceguard (ancient)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 4550 };\n\t\t\titemDef.originalModelColors = new int[] { -10854, -10860, -10872, -10874 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33387:\n\t\t\titemDef.name = \"Justiciar faceguard (bandos)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 4550 };\n\t\t\titemDef.originalModelColors = new int[] { 7062, 7062, 7062, 7062 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33389:\n\t\t\titemDef.name = \"Justiciar faceguard (armadyl)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 4550 };\n\t\t\titemDef.originalModelColors = new int[] { 10467, 10474, 10482, 10484 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33390:\n\t\t\titemDef.name = \"Justiciar chestguard (zamorak)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35750;\n\t\t\titemDef.maleModel = 35359;\n\t\t\titemDef.femaleModel = 35368;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 926, 926, 926 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33391:\n\t\t\titemDef.name = \"Justiciar chestguard (guthix)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35750;\n\t\t\titemDef.maleModel = 35359;\n\t\t\titemDef.femaleModel = 35368;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 21939, 21945, 21952, 21954 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33392:\n\t\t\titemDef.name = \"Justiciar chestguard (saradomin)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35750;\n\t\t\titemDef.maleModel = 35359;\n\t\t\titemDef.femaleModel = 35368;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 43929, 43929, 43929, 43929 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33393:\n\t\t\titemDef.name = \"Justiciar chestguard (ancient)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35750;\n\t\t\titemDef.maleModel = 35359;\n\t\t\titemDef.femaleModel = 35368;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { -10854, -10860, -10872, -10874 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33394:\n\t\t\titemDef.name = \"Justiciar chestguard (bandos)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35750;\n\t\t\titemDef.maleModel = 35359;\n\t\t\titemDef.femaleModel = 35368;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 7062, 7062, 7062, 7062 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33395:\n\t\t\titemDef.name = \"Justiciar chestguard (armadyl)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35750;\n\t\t\titemDef.maleModel = 35359;\n\t\t\titemDef.femaleModel = 35368;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 10467, 10474, 10482, 10484 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33396:\n\t\t\titemDef.name = \"Justiciar legguards (zamorak)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35752;\n\t\t\titemDef.maleModel = 35356;\n\t\t\titemDef.femaleModel = 35357;\n\t\t\titemDef.modelZoom = 1720;\n\t\t\titemDef.modelRotation1 = 468;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 926, 926, 926 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33397:\n\t\t\titemDef.name = \"Justiciar legguards (guthix)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35752;\n\t\t\titemDef.maleModel = 35356;\n\t\t\titemDef.femaleModel = 35357;\n\t\t\titemDef.modelZoom = 1720;\n\t\t\titemDef.modelRotation1 = 468;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 21939, 21945, 21952, 21954 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33398:\n\t\t\titemDef.name = \"Justiciar legguards (saradomin)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35752;\n\t\t\titemDef.maleModel = 35356;\n\t\t\titemDef.femaleModel = 35357;\n\t\t\titemDef.modelZoom = 1720;\n\t\t\titemDef.modelRotation1 = 468;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 43929, 43929, 43929, 43929 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33399:\n\t\t\titemDef.name = \"Justiciar legguards (ancient)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35752;\n\t\t\titemDef.maleModel = 35356;\n\t\t\titemDef.femaleModel = 35357;\n\t\t\titemDef.modelZoom = 1720;\n\t\t\titemDef.modelRotation1 = 468;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { -10854, -10860, -10872, -10874 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33400:\n\t\t\titemDef.name = \"Justiciar legguards (bandos)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35752;\n\t\t\titemDef.maleModel = 35356;\n\t\t\titemDef.femaleModel = 35357;\n\t\t\titemDef.modelZoom = 1720;\n\t\t\titemDef.modelRotation1 = 468;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 7062, 7062, 7062, 7062 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33401:\n\t\t\titemDef.name = \"Justiciar legguards (armadyl)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35752;\n\t\t\titemDef.maleModel = 35356;\n\t\t\titemDef.femaleModel = 35357;\n\t\t\titemDef.modelZoom = 1720;\n\t\t\titemDef.modelRotation1 = 468;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 10467, 10474, 10482, 10484 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33402:\n\t\t\titemDef.name = \"Pet andy\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 50169;\n\t\t\titemDef.modelZoom = 1500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33403:\n\t\t\titemDef.name = \"Pet mod divine\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 14283;\n\t\t\titemDef.modelZoom = 3500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33404:\n\t\t\titemDef.name = \"Celestial fairy\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60491;\n\t\t\titemDef.modelZoom = 3500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 947 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 78 };\n\t\t\titemDef.modifiedModelColors = new int[] { 937, 11200 };\n\t\t\titemDef.originalModelColors = new int[] { 42663, 41883 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33405:\n\t\t\titemDef.name = \"Lava partyhat (red)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"A lava partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33406:\n\t\t\titemDef.name = \"Lava partyhat (green)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"A lava partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33407:\n\t\t\titemDef.name = \"Lava partyhat (cyan)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"A lava partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33408:\n\t\t\titemDef.name = \"Lava partyhat (purple)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"A lava partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33409:\n\t\t\titemDef.name = \"Infernal partyhat (blue)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"An Infernal partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33410:\n\t\t\titemDef.name = \"Infernal partyhat (green)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"An Infernal partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33411:\n\t\t\titemDef.name = \"Infernal partyhat (purple)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"An Infernal partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33412:\n\t\t\titemDef.name = \"Infernal partyhat (rainbow)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"An Infernal partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33413:\n\t\t\titemDef.name = \"Celestial partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33414:\n\t\t\titemDef.name = \"Blood partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33415:\n\t\t\titemDef.name = \"Shadow partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33416:\n\t\t\titemDef.name = \"Light blue partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33417:\n\t\t\titemDef.name = \"Easter partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33418:\n\t\t\titemDef.name = \"Dark sparkle partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33419:\n\t\t\titemDef.name = \"Rainbow partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33420:\n\t\t\titemDef.name = \"Fire partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33421:\n\t\t\titemDef.name = \"Pet star sprite\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60506;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33422:\n\t\t\titemDef.name = \"Stargaze Box\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 61110;\n\t\t\titemDef.modelZoom = 1180;\n\t\t\titemDef.modelRotation1 = 160;\n\t\t\titemDef.modelRotation2 = 172;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -14;\n\t\t\t// itemDef.modifiedModelColors = new int[] {22410, 2999};\n\t\t\t// itemDef.originalModelColors = new int[] {35321, 350};\n\t\t\titemDef.description = \"none\";\n\t\t\tbreak;\n\n\t\tcase 33423:\n\t\t\titemDef.name = \"Star Dust\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Exchange\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modelId = 60496;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 279;\n\t\t\titemDef.modelRotation2 = 1994;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 47;\n\t\t\t// itemDef.modifiedModelColors = new int[] {22410, 2999};\n\t\t\t// itemDef.originalModelColors = new int[] {35321, 350};\n\t\t\titemDef.description = \"none\";\n\t\t\tbreak;\n\n\t\tcase 33424:\n\t\t\titemDef.name = \"Blood twisted bow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32799;\n\t\t\titemDef.maleModel = 32674;\n\t\t\titemDef.femaleModel = 32674;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 720;\n\t\t\titemDef.modelRotation2 = 1500;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 10318, 10334 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 66, 66 };\n\t\t\titemDef.modifiedModelColors = new int[] { 14236, 13223 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 926 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33425:\n\t\t\titemDef.name = \"Celestial crow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60507;\n\t\t\titemDef.modelZoom = 1000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 10382 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 78 };\n\t\t\titemDef.modifiedModelColors = new int[] { 10378, 10502 };\n\t\t\titemDef.originalModelColors = new int[] { 0, 0 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33426:\n\t\t\titemDef.name = \"Celestial penguin\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60508;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 10343 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 78 };\n\t\t\titemDef.modifiedModelColors = new int[] { 16, 12, 20, 24, 8, 10332, 10337 };\n\t\t\titemDef.originalModelColors = new int[] { 0, 0, 0, 0, 0, 0, 0 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33427:\n\t\t\titemDef.name = \"Celestial snake\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60509;\n\t\t\titemDef.modelZoom = 1800;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 10644, 10512 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 78, 78 };\n\t\t\titemDef.modifiedModelColors = new int[] { 10413, 10405, 10524 };\n\t\t\titemDef.originalModelColors = new int[] { 0, 0, 0 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33428:\n\t\t\titemDef.name = \"Celestial scorpion\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60510;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 142 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 78 };\n\t\t\titemDef.modifiedModelColors = new int[] { 4884, 4636, 3974, 4525, 4645 };\n\t\t\titemDef.originalModelColors = new int[] { 0, 0, 0, 0, 0 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33429:\n\t\t\titemDef.name = \"Armadyl dye\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60513;\n\t\t\titemDef.modelZoom = 809;\n\t\t\titemDef.modelRotation1 = 90;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 30814, 30809, 30799, 30804 };\n\t\t\titemDef.originalModelColors = new int[] { 10467, 10474, 10482, 10484 };\n\t\t\tbreak;\n\n\t\tcase 33430:\n\t\t\titemDef.name = \"Guthix dye\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60513;\n\t\t\titemDef.modelZoom = 809;\n\t\t\titemDef.modelRotation1 = 90;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 30814, 30809, 30799, 30804 };\n\t\t\titemDef.originalModelColors = new int[] { 21939, 21945, 21952, 21954 };\n\t\t\tbreak;\n\n\t\tcase 33431:\n\t\t\titemDef.name = \"Zamorak dye\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60513;\n\t\t\titemDef.modelZoom = 809;\n\t\t\titemDef.modelRotation1 = 90;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 30814, 30809, 30799, 30804 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 926, 926, 926 };\n\t\t\tbreak;\n\n\t\tcase 33432:\n\t\t\titemDef.name = \"Ancient dye\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60513;\n\t\t\titemDef.modelZoom = 809;\n\t\t\titemDef.modelRotation1 = 90;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 30814, 30809, 30799, 30804 };\n\t\t\titemDef.originalModelColors = new int[] { -10854, -10860, -10872, -10874 };\n\t\t\tbreak;\n\n\t\tcase 33433:\n\t\t\titemDef.name = \"Bandos dye\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60513;\n\t\t\titemDef.modelZoom = 809;\n\t\t\titemDef.modelRotation1 = 90;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 30814, 30809, 30799, 30804 };\n\t\t\titemDef.originalModelColors = new int[] { 7062, 7062, 7062, 7062 };\n\t\t\tbreak;\n\n\t\tcase 33434:\n\t\t\titemDef.name = \"Saradomin dye\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60513;\n\t\t\titemDef.modelZoom = 809;\n\t\t\titemDef.modelRotation1 = 90;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 30814, 30809, 30799, 30804 };\n\t\t\titemDef.originalModelColors = new int[] { 43929, 43929, 43929, 43929 };\n\t\t\tbreak;\n\n\t\tcase 33435:\n\t\t\titemDef.name = \"Celestial egg\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 7171;\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelRotation2 = 16;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 476 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 78 };\n\t\t\titemDef.inventoryOptions = new String[] { \"Hatch\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = true;\n\t\t\tbreak;\n\n\t\tcase 33436:\n\t\t\titemDef.name = \"Elite void top (placeholder)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 10586;\n\t\t\titemDef.maleModel = 10687;\n\t\t\titemDef.anInt188 = 10681;\n\t\t\titemDef.femaleModel = 10694;\n\t\t\titemDef.anInt164 = 10688;\n\t\t\titemDef.modelZoom = 1221;\n\t\t\titemDef.modelRotation1 = 459;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\t// itemDef.originalTextureColors = new int [] { 695};\n\t\t\t// itemDef.modifiedTextureColors = new int [] { 66};\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33437:\n\t\t\titemDef.name = \"Elite void robe (placeholder)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60528;\n\t\t\titemDef.maleModel = 60526;\n\t\t\titemDef.femaleModel = 60527;\n\t\t\titemDef.modelZoom = 2105;\n\t\t\titemDef.modelRotation1 = 525;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\t// itemDef.originalTextureColors = new int [] { 695};\n\t\t\t// itemDef.modifiedTextureColors = new int [] { 66};\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33438:\n\t\t\titemDef.name = \"Blood chest\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60516;\n\t\t\titemDef.modelZoom = 2640;\n\t\t\titemDef.modelRotation1 = 114;\n\t\t\titemDef.modelRotation2 = 1883;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33439:\n\t\t\titemDef.name = \"Blood bird\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60517;\n\t\t\titemDef.modelZoom = 2768;\n\t\t\titemDef.modelRotation1 = 141;\n\t\t\titemDef.modelRotation2 = 1790;\n\t\t\titemDef.modelOffset1 = -8;\n\t\t\titemDef.modelOffset2 = -13;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\titemDef.originalTextureColors = new int[] { 1946, 2983, 6084, 2735, 5053, 6082, 4013, 2733, 4011, 2880,\n\t\t\t\t\t8150 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66 };\n\t\t\tbreak;\n\n\t\tcase 33440:\n\t\t\titemDef.name = \"Blood Death\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60441;\n\t\t\titemDef.modelZoom = 16000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33442:\n\t\t\titemDef.name = \"10 Min XP boost (25%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Claim\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33446:\n\t\t\titemDef.name = \"10 Min XP boost (50%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Claim\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33450:\n\t\t\titemDef.name = \"10 Min XP boost (75%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Claim\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33454:\n\t\t\titemDef.name = \"10 Min XP boost (100%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33458:\n\t\t\titemDef.name = \"10 Min XP boost (150%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33462:\n\t\t\titemDef.name = \"10 Min XP boost (200%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33443:\n\t\t\titemDef.name = \"30 Min XP boost (25%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33447:\n\t\t\titemDef.name = \"30 Min XP boost (50%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33451:\n\t\t\titemDef.name = \"30 Min XP boost (75%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33455:\n\t\t\titemDef.name = \"30 Min XP boost (100%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33459:\n\t\t\titemDef.name = \"30 Min XP boost (150%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33463:\n\t\t\titemDef.name = \"30 Min XP boost (200%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33444:\n\t\t\titemDef.name = \"60 Min XP boost (25%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33448:\n\t\t\titemDef.name = \"60 Min XP boost (50%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33452:\n\t\t\titemDef.name = \"60 Min XP boost (75%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33456:\n\t\t\titemDef.name = \"60 Min XP boost (100%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33460:\n\t\t\titemDef.name = \"60 Min XP boost (150%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33464:\n\t\t\titemDef.name = \"60 Min XP boost (200%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33445:\n\t\t\titemDef.name = \"120 Min XP boost (25%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33449:\n\t\t\titemDef.name = \"120 Min XP boost (50%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33453:\n\t\t\titemDef.name = \"120 Min XP boost (75%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33457:\n\t\t\titemDef.name = \"120 Min XP boost (100%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33461:\n\t\t\titemDef.name = \"120 Min XP boost (150%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33465:\n\t\t\titemDef.name = \"120 Min XP boost (200%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33466:\n\t\t\titemDef.name = \"Deathtouched dart\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60534;\n\t\t\titemDef.maleModel = 60533;\n\t\t\titemDef.femaleModel = 60533;\n\t\t\titemDef.modelZoom = 1053;\n\t\t\titemDef.modelRotation1 = 471;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33467:\n\t\t\titemDef.name = \"Justiciar boots\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60535;\n\t\t\titemDef.maleModel = 60535;\n\t\t\titemDef.femaleModel = 60535;\n\t\t\titemDef.modelZoom = 789;\n\t\t\titemDef.modelRotation1 = 164;\n\t\t\titemDef.modelRotation2 = 156;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33468:\n\t\t\titemDef.name = \"Justiciar gloves\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 31022;\n\t\t\titemDef.maleModel = 31006;\n\t\t\titemDef.femaleModel = 31013;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 636;\n\t\t\titemDef.modelRotation2 = 2015;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 123, 70 };\n\t\t\titemDef.originalModelColors = new int[] { 6736, 59441 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33469:\n\t\t\titemDef.name = \"Magic mushroom\";\n\t\t\titemDef.description = \"offers a 10% droprate increase while this pet follows you.\";\n\t\t\titemDef.modelId = 60532;\n\t\t\titemDef.modelZoom = 3000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 6;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33470:\n\t\t\titemDef.name = \"Twisted staff\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60538;\n\t\t\titemDef.maleModel = 60539;\n\t\t\titemDef.femaleModel = 60539;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33471:\n\t\t\titemDef.name = \"Cowboy hat\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60540;\n\t\t\titemDef.maleModel = 60541;\n\t\t\titemDef.femaleModel = 60541;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 108;\n\t\t\titemDef.modelRotation2 = 1535;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33472:\n\t\t\titemDef.name = \"Stick\";\n\t\t\titemDef.description = \"Careful of that chub.\";\n\t\t\titemDef.modelId = 60545;\n\t\t\titemDef.maleModel = 60545;\n\t\t\titemDef.femaleModel = 60545;\n\t\t\titemDef.modelZoom = 3000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33473:\n\t\t\titemDef.name = \"#1 Tob cape\";\n\t\t\titemDef.description = \"Reward to the first to complete tob solo and in a team.\";\n\t\t\titemDef.modelId = 60551;\n\t\t\titemDef.maleModel = 60550;\n\t\t\titemDef.femaleModel = 60550;\n\t\t\titemDef.modelZoom = 2295;\n\t\t\titemDef.modelRotation1 = 367;\n\t\t\titemDef.modelRotation2 = 1212;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = 8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33474:\n\t\t\titemDef.name = \"Supreme void upgrade kit\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 4847;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 163;\n\t\t\titemDef.modelRotation2 = 73;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { -32709, 10295, 10304, 10287, 10275, 10283 };\n\t\t\titemDef.originalModelColors = new int[] { 10, 10, 10, 10, 10, 10 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33475:\n\t\t\titemDef.name = \"Hunter's penguin\";\n\t\t\titemDef.description = \"the one and only's pet.\";\n\t\t\titemDef.modelId = 60548;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 6;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33476:\n\t\t\titemDef.name = \"Chef Harambe\";\n\t\t\titemDef.description = \"I like to dip my balls in a deep fryer.\";\n\t\t\titemDef.modelId = 60921;\n\t\t\titemDef.modelZoom = 5000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 6;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33477:\n\t\t\titemDef.name = \"Void knight champion jr\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60463;\n\t\t\titemDef.modelZoom = 14000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 6;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33478:\n\t\t\titemDef.name = \"Custom pet token\";\n\t\t\titemDef.description = \"Trade this to corey after filling out a form on the forums post custom pets\";\n\t\t\titemDef.modelId = 13838;\n\t\t\titemDef.modelZoom = 530;\n\t\t\titemDef.modelRotation1 = 415;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33479:\n\t\t\titemDef.name = \"Mr jaycorr\";\n\t\t\titemDef.description = \"The autistic one.\";\n\t\t\titemDef.modelId = 60592;\n\t\t\titemDef.modelZoom = 7500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33480:\n\t\t\titemDef.name = \"Broom broom\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60593;\n\t\t\titemDef.maleModel = 60593;\n\t\t\titemDef.femaleModel = 60593;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33481:\n\t\t\titemDef.name = \"Test\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 11773:\n\t\tcase 11771:\n\t\tcase 11770:\n\t\tcase 11772:\n\t\t\titemDef.anInt196 += 45;\n\t\t\tbreak;\n\t\tcase 22610:\n\t\t\titemDef.name = \"Vesta's spear (deg)\";\n\t\t\tbreak;\n\t\tcase 22614:\n\t\t\titemDef.name = \"Vesta's longsword (deg)\";\n\t\t\tbreak;\n\t\tcase 22616:\n\t\t\titemDef.name = \"Vesta's chainbody (deg)\";\n\t\t\tbreak;\n\t\tcase 22619:\n\t\t\titemDef.name = \"Vesta's plateskirt (deg)\";\n\t\t\tbreak;\n\t\tcase 22622:\n\t\t\titemDef.name = \"Statius's warhammer (deg)\";\n\t\t\tbreak;\n\t\tcase 22625:\n\t\t\titemDef.name = \"Statius's full helm (deg)\";\n\t\t\tbreak;\n\t\tcase 22628:\n\t\t\titemDef.name = \"Statius's platebody (deg)\";\n\t\t\tbreak;\n\t\tcase 22631:\n\t\t\titemDef.name = \"Statius's platelegs (deg)\";\n\t\t\tbreak;\n\t\tcase 22638:\n\t\t\titemDef.name = \"Morrigan's coif (deg)\";\n\t\t\tbreak;\n\t\tcase 22641:\n\t\t\titemDef.name = \"Morrigan's leather body (deg)\";\n\t\t\tbreak;\n\t\tcase 22644:\n\t\t\titemDef.name = \"Morrigan's leather chaps (deg)\";\n\t\t\tbreak;\n\t\tcase 22647:\n\t\t\titemDef.name = \"Zuriel's staff (deg)\";\n\t\t\tbreak;\n\t\tcase 22650:\n\t\t\titemDef.name = \"Zuriel's hood (deg)\";\n\t\t\tbreak;\n\t\tcase 22653:\n\t\t\titemDef.name = \"Zuriel's robe top (deg)\";\n\t\t\tbreak;\n\t\tcase 22656:\n\t\t\titemDef.name = \"Zuriel's robe bottom (deg)\";\n\t\t\tbreak;\n\n\t\tcase 13303:\n\t\t\titemDef.name = \"Event Key (Tarn)\";\n\t\t\titemDef.description = \"Use this to open the Event Boss chest.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 8128 };\n\t\t\titemDef.originalModelColors = new int[] { 933 };\n\t\t\tbreak;\n\t\tcase 13302:\n\t\t\titemDef.name = \"Event Key (Graardor)\";\n\t\t\titemDef.description = \"Use this to open the Event Boss chest.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 8128 };\n\t\t\titemDef.originalModelColors = new int[] { 933 };\n\t\t\tbreak;\n\t\tcase 13305:\n\t\t\titemDef.name = \"Tastey-Looking Key\";\n\t\t\titemDef.description = \"Use this to open the Event Boss chest.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 8128 };\n\t\t\titemDef.originalModelColors = new int[] { 933 };\n\t\t\tbreak;\n\t\tcase 2697:\n\t\t\titemDef.name = \"$10 Scroll\";\n\t\t\titemDef.description = \"Get donor status at a cheaper cost!\";\n\t\t\tbreak;\n\t\tcase 2698:\n\t\t\titemDef.name = \"$50 Scroll\";\n\t\t\titemDef.description = \"Read this scroll to be rewarded with the Super Donator status.\";\n\t\t\tbreak;\n\t\tcase 2699:\n\t\t\titemDef.name = \"$100 Donator\";\n\t\t\titemDef.description = \"Read this scroll to be rewarded with the Extreme Donator status.\";\n\t\t\tbreak;\n\t\tcase 2700:\n\t\t\titemDef.name = \"$5 Scroll\";\n\t\t\titemDef.description = \"Read this scroll to be rewarded with the Legendary Donator status.\";\n\t\t\tbreak;\n\t\tcase 1464:\n\t\t\titemDef.name = \"Vote ticket\";\n\t\t\titemDef.description = \"This ticket can be exchanged for a voting point.\";\n\t\t\tbreak;\n\n\t\tcase 11739:\n\t\t\titemDef.name = \"Daily reward box\";\n\t\t\titemDef.description = \"Open this box for a daily reward.\";\n\t\t\tbreak;\n\n\t\tcase 13066:// super set\n\t\tcase 12873:// barrows\n\t\tcase 12875:\n\t\tcase 12877:\n\t\tcase 12879:\n\t\tcase 12881:\n\t\tcase 12883:\n\t\tcase 12789:// clue box\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\tbreak;\n\t\t}\n\t\t\n\t}", "@SuppressWarnings(\"deprecated\")\n protected void durability(Player p, PlayerInteractEvent event) {\n this.p = p;\n\n Block block = event.getClickedBlock();\n Action action = event.getAction();\n Material blockType = block.getType();\n Location blockLocation = block.getLocation();\n ItemStack heldItem = p.getInventory().getItemInMainHand();\n Material heldItemType = heldItem.getType();\n\n //left click = spade,hoe\n //right click = axe,pick axe,sword,spade,hoe,sword\n canRun = isCanCheckDurability(action, heldItemType);\n\n if (canRun && Helper.isBlockForOutput(blockType)) {\n //Only for blocks\n //TODO get type id nicer than with deprecated method\n final String blockLocationFormat = String.format(\"%d;%d;%d;%d\",\n block.getTypeId(),\n blockLocation.getBlockX(),\n blockLocation.getBlockY(),\n blockLocation.getBlockZ());\n\n if (checkDurability(heldItem, blockLocationFormat)) {\n xyzBlock.add(blockLocationFormat);\n //Remove later on, so it can be added again\n new BukkitRunnable() {\n\n @Override\n public void run() {\n if (xyzBlock.contains(blockLocationFormat)) xyzBlock.remove(blockLocationFormat);\n }\n\n }.runTaskLater(this.plugin, 1220); //1220 = 1 minute (in-game) //TODO make configurable?\n }\n }\n }", "@Override\n public int getMaxItemUseDuration(ItemStack par1ItemStack) {\n return 10;\n }", "@Override\n public Item getItemDropped(IBlockState state, Random rand, int fortune) {\n return this == BlockHandler.rubyore ? ItemHandler.ruby : (this == BlockHandler.sapphireore ? ItemHandler.sapphire : (this == BlockHandler.topazore ? ItemHandler.topaz : (this == BlockHandler.peridotore ? ItemHandler.peridot : (this == BlockHandler.amethystore ? ItemHandler.amethyst : (this == BlockHandler.berylore ? ItemHandler.beryl : (this == BlockHandler.citrineore ? ItemHandler.citrine : Item.getItemFromBlock(this)))))));\n }", "private RewardItem calculateRewardItem(final L2PcInstance lastAttacker, final L2DropData drop, final int levelModifier, final boolean isSweep)\n\t{\n\t\t// Get default drop chance\n\t\tif (Config.HIGH_RATE_SERVER_DROPS && !drop.isQuestDrop() && drop.getItemId() != 57)\n\t\t{ // it's not adena-->check if drop has an epic jewel\n\t\t\t\n\t\t\t// ant queen,orfen,core,frintezza,baium,antharas,valakas,zaken,stones\n\t\t\tif (drop.getItemId() == 6660 || drop.getItemId() == 6661 || drop.getItemId() == 6662 || drop.getItemId() == 8191 || drop.getItemId() == 6658 || drop.getItemId() == 6656 || drop.getItemId() == 6657 || drop.getItemId() == 6659 || drop.getItemId() >= 6360 && drop.getItemId() <= 6362 || drop.getItemId() >= 8723 && drop.getItemId() <= 8762)\n\t\t\t{\n\t\t\t\t// if epic jewel, seal stones or life stone, continue\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\treturn null;\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tfloat dropChance = 0;\n\t\t\n\t\tswitch (drop.getItemId())\n\t\t{\n\t\t\tcase 6662:\n\t\t\t{ // core ring\n\t\t\t\tif (Config.CORE_RING_CHANCE > 0)\n\t\t\t\t{\n\t\t\t\t\tdropChance = (float) 10000 * Config.CORE_RING_CHANCE;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tdropChance = drop.getChance();\n\t\t\t\t}\n\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 6661:\n\t\t\t{ // orfen earring\n\t\t\t\tif (Config.ORFEN_EARRING_CHANCE > 0)\n\t\t\t\t{\n\t\t\t\t\tdropChance = (float) 10000 * Config.ORFEN_EARRING_CHANCE;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tdropChance = drop.getChance();\n\t\t\t\t}\n\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 6659:\n\t\t\t{ // zaken earring\n\t\t\t\tif (Config.ZAKEN_EARRING_CHANCE > 0)\n\t\t\t\t{\n\t\t\t\t\tdropChance = (float) 10000 * Config.ZAKEN_EARRING_CHANCE;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tdropChance = drop.getChance();\n\t\t\t\t}\n\t\t\t}\n\t\t\t\tbreak;\n\t\t\tcase 6660:\n\t\t\t{ // aq ring\n\t\t\t\tif (Config.QA_RING_CHANCE > 0)\n\t\t\t\t{\n\t\t\t\t\tdropChance = (float) 10000 * Config.QA_RING_CHANCE;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tdropChance = drop.getChance();\n\t\t\t\t}\n\t\t\t}\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t{\n\t\t\t\tdropChance = drop.getChance();\n\t\t\t}\n\t\t}\n\t\t\n\t\tint deepBlueDrop = 1;\n\t\t\n\t\tif (Config.DEEPBLUE_DROP_RULES)\n\t\t{\n\t\t\tif (levelModifier > 0)\n\t\t\t{\n\t\t\t\t// We should multiply by the server's drop rate, so we always get a low chance of drop for deep blue mobs.\n\t\t\t\t// NOTE: This is valid only for adena drops! Others drops will still obey server's rate\n\t\t\t\tdeepBlueDrop = 3;\n\t\t\t\t\n\t\t\t\tif (drop.getItemId() == 57)\n\t\t\t\t{\n\t\t\t\t\tdeepBlueDrop *= isRaid() ? 1 : Config.RATE_DROP_ITEMS;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (deepBlueDrop == 0)\n\t\t{\n\t\t\tdeepBlueDrop = 1;\n\t\t}\n\t\t\n\t\t// Check if we should apply our maths so deep blue mobs will not drop that easy\n\t\tif (Config.DEEPBLUE_DROP_RULES)\n\t\t{\n\t\t\tdropChance = (drop.getChance() - drop.getChance() * levelModifier / 100) / deepBlueDrop;\n\t\t}\n\t\t\n\t\t// Applies Drop rates\n\t\tif (drop.getItemId() == 57)\n\t\t{\n\t\t\tif (this instanceof L2RaidBossInstance)\n\t\t\t{\n\t\t\t\tdropChance *= Config.ADENA_RAID;\n\t\t\t}\n\t\t\telse if (this instanceof L2GrandBossInstance)\n\t\t\t{\n\t\t\t\tdropChance *= Config.ADENA_BOSS;\n\t\t\t}\n\t\t\telse if (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tdropChance *= Config.ADENA_MINON;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tdropChance *= Config.RATE_DROP_ADENA;\n\t\t\t\t\n\t\t\t\tif (lastAttacker.isVIP())\n\t\t\t\t{\n\t\t\t\t\tdropChance *= Config.VIP_ADENA_RATE;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t}\n\t\telse if (isSweep)\n\t\t{\n\t\t\tif (this instanceof L2RaidBossInstance)\n\t\t\t{\n\t\t\t\tdropChance *= Config.SPOIL_RAID;\n\t\t\t}\n\t\t\telse if (this instanceof L2GrandBossInstance)\n\t\t\t{\n\t\t\t\tdropChance *= Config.SPOIL_BOSS;\n\t\t\t}\n\t\t\telse if (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tdropChance *= Config.SPOIL_MINON;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tdropChance *= Config.RATE_DROP_SPOIL;\n\t\t\t\t\n\t\t\t\tif (lastAttacker.isVIP())\n\t\t\t\t{\n\t\t\t\t\tdropChance *= Config.VIP_SPOIL_RATE;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\tif (this instanceof L2RaidBossInstance)\n\t\t\t{\n\t\t\t\tdropChance *= Config.ITEMS_RAID;\n\t\t\t}\n\t\t\telse if (this instanceof L2GrandBossInstance)\n\t\t\t{\n\t\t\t\tdropChance *= Config.ITEMS_BOSS;\n\t\t\t}\n\t\t\telse if (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tdropChance *= Config.ITEMS_MINON;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tdropChance *= Config.RATE_DROP_ITEMS;\n\t\t\t\t\n\t\t\t\tif (lastAttacker.isVIP())\n\t\t\t\t{\n\t\t\t\t\tdropChance *= Config.VIP_DROP_RATE;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t{\n\t\t\tdropChance *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t}\n\t\t\n\t\t// Round drop chance\n\t\tdropChance = Math.round(dropChance);\n\t\t\n\t\t// Set our limits for chance of drop\n\t\tif (dropChance < 1)\n\t\t{\n\t\t\tdropChance = 1;\n\t\t}\n\t\t\n\t\t// If item is adena, dont drop multiple time\n\t\t// if (drop.getItemId() == 57 && dropChance > L2DropData.MAX_CHANCE)\n\t\t// dropChance = L2DropData.MAX_CHANCE;\n\t\t\n\t\t// Get min and max Item quantity that can be dropped in one time\n\t\tfinal int minCount = drop.getMinDrop();\n\t\tfinal int maxCount = drop.getMaxDrop();\n\t\tint itemCount = 0;\n\t\t\n\t\tif (!Config.MULTIPLY_QUANTITY_BY_CHANCE && dropChance > L2DropData.MAX_CHANCE && drop.getItemId() != 57)\n\t\t{\n\t\t\tdropChance = L2DropData.MAX_CHANCE;\n\t\t}\n\t\t\n\t\t// Count and chance adjustment for high rate servers\n\t\tif (dropChance > L2DropData.MAX_CHANCE && !Config.PRECISE_DROP_CALCULATION)\n\t\t{\n\t\t\tfinal int multiplier = (int) dropChance / L2DropData.MAX_CHANCE;\n\t\t\t\n\t\t\tif (minCount < maxCount)\n\t\t\t{\n\t\t\t\titemCount += Rnd.get(minCount * multiplier, maxCount * multiplier);\n\t\t\t}\n\t\t\telse if (minCount == maxCount)\n\t\t\t{\n\t\t\t\titemCount += minCount * multiplier;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\titemCount += multiplier;\n\t\t\t}\n\t\t\t\n\t\t\tdropChance = dropChance % L2DropData.MAX_CHANCE;\n\t\t}\n\t\t\n\t\t// Check if the Item must be dropped\n\t\tfinal int random = Rnd.get(L2DropData.MAX_CHANCE);\n\t\t\n\t\twhile (random < dropChance)\n\t\t{\n\t\t\t// Get the item quantity dropped\n\t\t\tif (minCount < maxCount)\n\t\t\t{\n\t\t\t\titemCount += Rnd.get(minCount, maxCount);\n\t\t\t}\n\t\t\telse if (minCount == maxCount)\n\t\t\t{\n\t\t\t\titemCount += minCount;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\titemCount++;\n\t\t\t}\n\t\t\t\n\t\t\t// Prepare for next iteration if dropChance > L2DropData.MAX_CHANCE\n\t\t\tdropChance -= L2DropData.MAX_CHANCE;\n\t\t}\n\t\tif (Config.L2JMOD_CHAMPION_ENABLE)\n\t\t{\n\t\t\tif ((drop.getItemId() == 57 || drop.getItemId() >= 6360 && drop.getItemId() <= 6362) && isChampion())\n\t\t\t{\n\t\t\t\titemCount *= Config.L2JMOD_CHAMPION_ADENAS_REWARDS;\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (drop.getItemId() >= 6360 && drop.getItemId() <= 6362)\n\t\t{\n\t\t\titemCount *= Config.RATE_DROP_SEAL_STONES;\n\t\t}\n\t\t\n\t\tif (itemCount > 0)\n\t\t{\n\t\t\treturn new RewardItem(drop.getItemId(), itemCount);\n\t\t}\n\t\telse if (itemCount == 0 && Config.DEBUG)\n\t\t{\n\t\t\tLOGGER.debug(\"Roll produced 0 items to drop...\");\n\t\t}\n\t\t\n\t\treturn null;\n\t}", "public Item getItemDropped(IBlockState state, Random rand, int fortune)\n {\n \treturn this == InitBlocksEA.arcanite_ore ? InitItemsEA.arcanite : (this == InitBlocksEA.draconium_ore ? InitItemsEA.draconium_dust : (this == InitBlocksEA.velious_ore ? InitItemsEA.velious : (this == InitBlocksEA.katcheen_ore ? InitItemsEA.katcheen : (this == InitBlocksEA.necrocite_ore ? InitItemsEA.necrocite : (this == InitBlocksEA.soularite_ore ? InitItemsEA.soularite : Item.getItemFromBlock(this))))));\n \t\n //return this == EbonArtsBlocks.arcanite_ore ? EbonArtsItems.arcanite_shard : (this == Blocks.diamond_ore ? Items.diamond : (this == Blocks.lapis_ore ? Items.dye : (this == Blocks.emerald_ore ? Items.emerald : (this == Blocks.quartz_ore ? Items.quartz : Item.getItemFromBlock(this)))));\n }", "@ForgeSubscribe(priority = EventPriority.HIGHEST)\n public void onPlayerDrops(PlayerDropsEvent event) {\n if (_PlayerHeads.debug);\n else if (_PlayerHeads.pvp && !event.recentlyHit || _PlayerHeads.dropRates[3] <= 0.0 || _PlayerHeads.random.nextDouble() - 0.005 * (double)event.lootingLevel >= _PlayerHeads.dropRates[3])\n return;\n ItemStack head = new ItemStack(Item.skull, 1, 3);\n head.setTagInfo(\"SkullOwner\", new NBTTagString(\"\", event.entityPlayer.username));\n EntityItem drop = new EntityItem(event.entityPlayer.worldObj, event.entityPlayer.posX, event.entityPlayer.posY, event.entityPlayer.posZ, head);\n drop.delayBeforeCanPickup = 10;\n event.drops.add(drop);\n }", "protected Item check_Drops(Character c) {\n for (Item item : c.getBag()) {\n if (item.isDropable()) {\n return item;\n }\n }\n return null;\n }", "@EventHandler\r\n \tpublic void onEntityExplode(EntityExplodeEvent event) \r\n \t{\n \t\tif (event.getEntityType() == EntityType.PRIMED_TNT) \r\n \t\t{\r\n \t\t\tLocation eventLoc = event.getLocation();\r\n \t\t\tServer server = plugin.getServer();\r\n \t\t\t\r\n \t\t\t// Red towers\r\n \t\t\tif (redBuildings.DestroyBuilding(BuildingType.Tower, eventLoc))\r\n \t\t\t{\r\n \t\t\t\ttowerCounts.put(\"red\", redBuildings.BuildingsCount(BuildingType.Tower));\r\n\t\t\t\tserver.broadcastMessage(ChatColor.YELLOW + \"A \"+ ChatColor.RED + \"RED\" + ChatColor.YELLOW + \" Tower Has Been Destroyed! (\" + towerCounts.get(\"red\") + \" remaining)\");\r\n\r\n\t\t\t\t// Check if all towers are destroyed\r\n \t\t\t\t\r\n \t\t\t\tif (towerCounts.get(\"red\") == 0) \r\n \t\t\t\t\tserver.broadcastMessage(ChatColor.YELLOW + \"All \"+ ChatColor.RED + \"RED\" + ChatColor.YELLOW + \" Towers Are Destroyed! Defend the NEXUS!\");\r\n \t\t\t}\r\n \t\t\t\r\n \t\t\t// Blue Towers\r\n \t\t\tif (blueBuildings.DestroyBuilding(BuildingType.Tower, eventLoc))\r\n \t\t\t{\r\n \t\t\t\ttowerCounts.put(\"blue\", blueBuildings.BuildingsCount(BuildingType.Tower));\r\n\t\t\t\tserver.broadcastMessage(ChatColor.YELLOW + \"A \"+ ChatColor.BLUE + \"BLUE\" + ChatColor.YELLOW + \" Tower Has Been Destroyed! (\" + towerCounts.get(\"blue\") + \" remaining)\");\r\n \r\n \t\t\t\t// Check if all towers are destroyed\r\n \t\t\t\tif (towerCounts.get(\"blue\") == 0) \r\n \t\t\t\t\tserver.broadcastMessage(ChatColor.YELLOW + \"All \"+ ChatColor.BLUE + \"BLUE\" + ChatColor.YELLOW + \" Towers Are Destroyed! Defend the NEXUS!\");\r\n \t\t\t}\r\n \t\t\t\r\n \t\t\t\r\n \t\t\t// Nexus\r\n \t\t\tif (redBuildings.DestroyBuilding(BuildingType.Nexus, eventLoc))\r\n \t\t\t{\r\n \t\t\t\tserver.broadcastMessage(ChatColor.RED + \"The RED NEXUS Has Been Destroyed!\" + ChatColor.BLUE + \" BLUE WINS!\");\r\n \t\t\t}\r\n \t\t\telse if (blueBuildings.DestroyBuilding(BuildingType.Nexus, eventLoc))\r\n \t\t\t{\r\n \t\t\t\tserver.broadcastMessage(ChatColor.BLUE + \"The BLUE NEXUS Has Been Destroyed!\" + ChatColor.RED + \" RED WINS!\");\r\n \t\t\t}\r\n \t\t}\r\n \t\t\r\n \t}", "public int quantityDropped(Random random) {\n/* 37 */ return 0;\n/* */ }", "public int quantityDropped(Random par1Random)\n {\n return 1;\n }", "public void getAttackedByDarknessMagicBook(IEquipableItem item){item.strongAttackTo(this.getOwner());}", "@Override\n\tprotected void on_object_drop(GfxObject bonus) {\n\n\t}", "private void registerDungeonLoot() {\n\t\tChestGenHooks dungeon = ChestGenHooks.getInfo(ChestGenHooks.DUNGEON_CHEST);\n\t\tChestGenHooks pyramid = ChestGenHooks.getInfo(ChestGenHooks.PYRAMID_DESERT_CHEST);\n\t\tChestGenHooks jtemple = ChestGenHooks.getInfo(ChestGenHooks.PYRAMID_JUNGLE_CHEST);\n\t\t\n\t\tWeightedRandomChestContent disc1WRCC = new WeightedRandomChestContent(new ItemStack(turretRec1), 1, 1, 5);\n\t\tWeightedRandomChestContent httmWRCC = new WeightedRandomChestContent(new ItemStack(httm), 1, 1, 5);\n\t\t\n\t\tdungeon.addItem(disc1WRCC);\n\t\tpyramid.addItem(disc1WRCC);\n\t\tpyramid.addItem(httmWRCC);\n\t\tjtemple.addItem(disc1WRCC);\n\t\tjtemple.addItem(httmWRCC);\n\t}", "public Item getItemDropped(int var1, Random var2, int var3)\n {\n if (var2.nextInt(4) == 0)\n {\n return FAItemRegistry.fernSeed;\n }\n return null;\n }", "@Test\n public void testDiesByDamage() {\n addCard(Zone.BATTLEFIELD, playerA, \"Mountain\", 1);\n addCard(Zone.HAND, playerA, \"Lightning Bolt\");\n addCard(Zone.BATTLEFIELD, playerB, \"Dryad Militant\");\n\n\n castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, \"Lightning Bolt\", \"Dryad Militant\");\n setStopAt(1, PhaseStep.BEGIN_COMBAT);\n execute();\n \n assertLife(playerB, 20);\n \n assertExileCount(\"Lightning Bolt\", 1);\n }", "public int quantityDropped(Random var1)\n {\n return 1;\n }", "public void drop(String itemName, World world) {\n\t\tItem item = world.dbItems().get(itemName);\n\n\t\tList<Item> items = super.getItems();\n\t\tRoom room = super.getRoom();\n\t\tList<Item> roomItems = room.getItems();\n\n\t\tif (items.contains(item)) {\n\t\t\troom.addItem(item);\n\t\t\tsuper.removeItem(item);\n\t\t\tSystem.out.println(\"Dropped \" + item + \" on the floor.\");\n\t\t} else {\n\t\t\tSystem.out.println(\"No \" + item + \" in inventory.\");\n\t\t}\n\t}", "public void manageDropping(Rectangle r){\n\t\t\tif (!dropping){ //does the random number part\n\t\t\t\tb.reset(x+ 35, y+50);\n\t\t\t\tint d = rand.nextInt(50);\n\t\t\t\t//System.out.println(randamount);\n\t\t\t\tif ((d == 1) && exists) {\n\t\t\t\t\tdropping =true; \n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\telse { //resets the bomb after it has been dropped\n\t\t\t\tif(b.y < 1000) b.dropBomb(dropamount);\n\t\t\t\tbombtimer = 0;\n\t\t\t\t//dropamount += .1;\n\t\t\t\t//dropamount = 5;\n\t\t\t\t\n\t\t\t\tif (b.y >= 700 || b.collided(r)) {\n\t\t\t\t\tif (b.collided(r)) tstartredtimer = true;\n\t\t\t\t\tif (exists) dropping = false;\n\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t}", "@Override\n\tpublic void onDamage(WorldObj obj, Items item) {\n\n\t\tif(is_stunned) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tint dmg = (int) item.type.ATK;\n\t\t\n\t\tOnScreenText.AddText(\"\"+dmg, bounds.x , bounds.y + 1.1f);\n\t\t\n\t\tvelX = obj.direction * 5;\n\t\tvelY = 5;\n\t\tgrounded = false;\n\t\t\n\t\tHP -= dmg;\n\t\t\n\n\t\tstun_counter = 0;\n\t\t\n\t\tif(HP <= 0 && !isDead) {\n\t\t\tonDeath();\n\t\t}\n\t\t\n\t}", "public String getMonsterDropsLoot() {\r\n String res;\r\n Random gen = new Random();\r\n if (gen.nextInt(100) > 75) {\r\n int tmp = gen.nextInt(items.size());\r\n player.addToInventory(items.get(tmp));\r\n res = \"You search the corpse and loot a \" + items.get(tmp).getName() + System.lineSeparator();\r\n } else {\r\n res = \"You find nothing of value on the corpse.\" + System.lineSeparator();\r\n }\r\n return res;\r\n }", "public int idDropped(int par1, EaglercraftRandom par2Random, int par3) {\n\t\treturn !this.canDropItself ? 0 : super.idDropped(par1, par2Random, par3);\n\t}", "public void eatItem(Command command) {\n if (!command.hasSecondWord()) { // check if there's a second word\n System.out.println(\"Eat what?\");\n return;\n }\n String itemToBeEaten = command.getSecondWord();\n List<Item> playerInventory = player.getPlayerInventory(); // load the inventory of the player\n\n boolean somethingToUse = false;\n int notThisItem = 0;\n int loop;\n\n for (loop = 0; loop < playerInventory.size(); loop++) { // loop through the player inventory\n Item currentItem = playerInventory.get(loop); // set currentitem on the item that is currently in the loop\n if (itemToBeEaten.equals(currentItem.getItemName()) ){ // get the item name, then check if that matches the secondWord\n if (currentItem.getItemCategory().equals(\"food\")){ // check if the item used is an item in the \"food\" category\n if((player.getHealth())<(20)) { // check if the player's health is full\n player.addHealth(currentItem.getHealAmount()); // heal the player\n player.removeItemFromInventory(currentItem); // remove item from inventory\n System.out.println(\"You eat the \" + itemToBeEaten + \". It heals for \" + currentItem.getHealAmount()+\".\");\n } else { // the player's health is full\n System.out.println(\"Your are at full health!\");\n }\n } else { // item is not a food item\n System.out.println(\"You can't eat that item!\");\n }\n } else { // the item did not match the player provided name\n notThisItem++;\n }\n somethingToUse = true;\n }\n\n //errors afvangen\n if (!somethingToUse) { // the item is not found in the player inventory\n System.out.println(\"You can't eat that!\");\n }\n\n if (loop == notThisItem) { // the player has nothing to burn secondWord with\n //ThisItem is the same amount as loop. Then the player put something in that is not in the room\n System.out.println(\"You cannot eat \" + itemToBeEaten + \" because you don't have it in your inventory!\");\n }\n }", "@Override\n public int quantityDroppedWithBonus(int par1, Random par2Random)\n {\n return 1 + par2Random.nextInt(par1 * 2 + 1);\n }", "@Listener\n public void onDeath(DestructEntityEvent.Death event) {\n if (!(event.getTargetEntity() instanceof Player))\n return;\n\n Optional<EntityDamageSource> source = event.getCause().first(EntityDamageSource.class);\n if (!source.isPresent())\n return; // did not die from pvp\n\n Player killed = (Player) event.getTargetEntity();\n\n Player killer = null;\n ItemStack weapon = null;\n Entity damager = source.get().getSource();\n if (damager instanceof Player) {\n killer = (Player) damager;\n weapon = killer.getItemInHand(HandTypes.MAIN_HAND).get();\n }\n\n if (damager instanceof Projectile) {\n Projectile proj = (Projectile) damager;\n if (proj.getShooter() instanceof Player) {\n killer = (Player) proj.getShooter();\n weapon = killer.getItemInHand(HandTypes.MAIN_HAND).get();\n }\n }\n\n if (damager.get(TameableData.class).isPresent()) {\n Optional<UUID> opOwnerUUID = damager.get(TameableData.class).get().owner().get();\n if (opOwnerUUID.isPresent()) {\n UUID uuid = opOwnerUUID.get();\n if (plugin.getServer().getOfflinePlayer(uuid).map(OfflinePlayer::isOnline).orElse(false)) {\n killer = ((SpongePlayer) plugin.getServer().getPlayer(uuid).get()).getHandle();\n // Use a bone to show the case was a wolf\n weapon = ItemStack.builder().itemType(ItemTypes.BONE).quantity(1).build();\n }\n }\n }\n\n if (killer == null)\n return;\n\n // Check the killers world just incase for some reason the\n // killed player was teleported to another world\n if (plugin.getConfigManager().getPvPConfig().getNode(\"ignoredWorlds\").getCollectionValue(String.class).contains(killer.getWorld().getName()))\n return;\n\n TrackerUtil.updatePvPStats(plugin.getServer().getOfflinePlayer(killed.getUniqueId().toString()).get(),\n plugin.getServer().getOfflinePlayer(killer.getUniqueId().toString()).get());\n\n TrackerInterface pvpTracker = plugin.getTrackerManager().getPvPInterface();\n if (pvpTracker.getDeathMessageManager().isDefaultMessagesOverriden())\n event.setMessageCancelled(true);\n\n pvpTracker.getDeathMessageManager().sendItemMessage(killer.getName(), killed.getName(), weapon.getType().getName().toLowerCase());\n pvpTracker.getRecapManager().getDeathRecaps().get(killed.getName()).setVisible(true);\n }", "public void livingTick() {\n super.livingTick();\n this.oFlap = this.wingRotation;\n this.oFlapSpeed = this.destPos;\n this.destPos = (float)((double)this.destPos + (double)(this.onGround ? -1 : 4) * 0.3D);\n this.destPos = MathHelper.clamp(this.destPos, 0.0F, 1.0F);\n if (!this.onGround && this.wingRotDelta < 1.0F) {\n this.wingRotDelta = 1.0F;\n }\n\n this.wingRotDelta = (float)((double)this.wingRotDelta * 0.9D);\n Vec3d vec3d = this.getMotion();\n if (!this.onGround && vec3d.y < 0.0D) {\n this.setMotion(vec3d.mul(1.0D, 0.6D, 1.0D));\n }\n\n this.wingRotation += this.wingRotDelta * 2.0F;\n if (!this.world.isRemote && this.isAlive() && !this.isChild() && getGender()==Gender.FEMALE && --this.timeUntilNextEgg <= 0) {\n this.playSound(SoundEvents.ENTITY_CHICKEN_EGG, 1.0F, (this.rand.nextFloat() - this.rand.nextFloat()) * 0.2F + 1.0F);\n this.entityDropItem(Items.EGG);\n this.timeUntilNextEgg = this.rand.nextInt(6000) + 6000;\n }\n\n ++this.eatTicks;\n ItemStack itemstack = this.getItemStackFromSlot(EquipmentSlotType.MAINHAND);\n if (this.canEatItem(itemstack)) {\n if (this.eatTicks > 600) {\n ItemStack itemstack1 = itemstack.onItemUseFinish(this.world, this);\n if (!itemstack1.isEmpty()) {\n this.setItemStackToSlot(EquipmentSlotType.MAINHAND, itemstack1);\n }\n\n this.eatTicks = 0;\n } else if (this.eatTicks > 560 && this.rand.nextFloat() < 0.1F) {\n this.playSound(this.getEatSound(itemstack), 1.0F, 1.0F);\n this.world.setEntityState(this, (byte)45);\n }\n }\n\n }", "@EventHandler (priority = EventPriority.HIGHEST)\n \tpublic void onCrafting(CraftItemEvent event){\n \t\tif(event.isCancelled())\n \t\t\treturn;\n \n \t\tHumanEntity he = event.getWhoClicked();\n \t\tif((he instanceof Player)){\n \t\t\tPlayer player = (Player) he;\n \t\t\tAlertType type = AlertType.ILLEGAL;\n \t\t\tif(player.getGameMode() == GameMode.CREATIVE){\n \t\t\t\tif(plugin.isBlocked(player, PermissionNodes.MAKE_ANYTHING, player.getWorld())){\n \t\t\t\t\ttype = AlertType.LEGAL;\n \t\t\t\t}\n \t\t\t\tASRegion region = plugin.getRegionManager().getRegion(player.getLocation());\n \t\t\t\tif(region != null){\n \t\t\t\t\tif(!region.getConfig().isBlocked(event.getRecipe().getResult().getType(), ListType.CRAFTING)){\n \t\t\t\t\t\ttype = AlertType.LEGAL;\n \t\t\t\t\t}\n \t\t\t\t}else{\n \t\t\t\t\tif(config.get(player.getWorld()).isBlocked(event.getRecipe().getResult().getType(), ListType.CRAFTING)){\n \t\t\t\t\t\ttype = AlertType.LEGAL;\n \t\t\t\t\t}\n \t\t\t\t}\n \t\t\t}else{\n \t\t\t\ttype = AlertType.LEGAL;\n \t\t\t}\n \t\t\tString message = ChatColor.YELLOW + player.getName() + ChatColor.WHITE + (type == AlertType.ILLEGAL ? \" tried to craft an item\" : \" crafted an item\");\n \t\t\tString playerMessage = plugin.getMessage(\"blocked-action.crafting\");\n \t\t\tplugin.getAlerts().alert(message, player, playerMessage, type, AlertTrigger.CRAFTING);\n \t\t\tif(type == AlertType.ILLEGAL){\n \t\t\t\tevent.setCancelled(true);\n \t\t\t}\n \t\t}\n \t}", "public void dropItems() {\n\t\tlocation.getChunk().load();\n\t\tArrays.stream(inventory.getContents())\n\t\t\t.filter(ItemStackUtils::isValid)\n\t\t\t.forEach((item) -> location.getWorld().dropItemNaturally(location, item));\n\t\tinventory.clear();\n\t}", "@Override\r\n\t/**\r\n\t * Each enemy has a unique drop\r\n\t */\r\n\tpublic String enemyDrop() {\n\t\treturn null;\r\n\t}", "protected Item getDropItem() {\r\n\t\treturn SorceryItems.goldfeather;\r\n\t}", "@SuppressWarnings(\"deprecated\")\n protected void durability(Player p, EntityDamageEvent event) {\n this.p = p;\n ItemStack heldItem = p.getInventory().getItemInMainHand();\n //No need to check here, its always ok\n canRun = true;\n //TODO ignore when hitting the same target multiple times (but how, xyz changes all the time?)\n //TODO sometimes(?) it shows 15 durability, when in fact its 14 (maybe bc of multiple mob hits?)\n if (canRun) {\n checkDurability(heldItem, \"\");\n }\n }", "public InteractionResult interactOn(Entity debug1, InteractionHand debug2) {\n/* 1039 */ if (isSpectator()) {\n/* 1040 */ if (debug1 instanceof MenuProvider) {\n/* 1041 */ openMenu((MenuProvider)debug1);\n/* */ }\n/* 1043 */ return InteractionResult.PASS;\n/* */ } \n/* */ \n/* 1046 */ ItemStack debug3 = getItemInHand(debug2);\n/* */ \n/* 1048 */ ItemStack debug4 = debug3.copy();\n/* 1049 */ InteractionResult debug5 = debug1.interact(this, debug2);\n/* 1050 */ if (debug5.consumesAction()) {\n/* 1051 */ if (this.abilities.instabuild && debug3 == getItemInHand(debug2) && debug3.getCount() < debug4.getCount()) {\n/* 1052 */ debug3.setCount(debug4.getCount());\n/* */ }\n/* 1054 */ return debug5;\n/* */ } \n/* */ \n/* 1057 */ if (!debug3.isEmpty() && debug1 instanceof LivingEntity) {\n/* */ \n/* 1059 */ if (this.abilities.instabuild) {\n/* 1060 */ debug3 = debug4;\n/* */ }\n/* 1062 */ InteractionResult debug6 = debug3.interactLivingEntity(this, (LivingEntity)debug1, debug2);\n/* 1063 */ if (debug6.consumesAction()) {\n/* */ \n/* 1065 */ if (debug3.isEmpty() && !this.abilities.instabuild) {\n/* 1066 */ setItemInHand(debug2, ItemStack.EMPTY);\n/* */ }\n/* 1068 */ return debug6;\n/* */ } \n/* */ } \n/* 1071 */ return InteractionResult.PASS;\n/* */ }", "public org.bukkit.inventory.ItemStack getBossDrop(String killer) {\n\t\tint number = random.nextInt(100);\r\n\t\tfor(Entry<SpecialItem, Integer> item: drops.entrySet()) {\r\n\t\t\tLog.info(item.getKey().getChance(), item.getValue(),\"ITEM\",number);\r\n\t\t\tif(item.getValue() > number) {\r\n\t\t\t\treturn item.getKey().getItem(killer,name);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn(new org.bukkit.inventory.ItemStack(Material.BONE));\r\n\t}", "public int damageDropped(int par1)\r\n/* 155: */ {\r\n/* 156:173 */ if (par1 < 6) {\r\n/* 157:174 */ return 0;\r\n/* 158: */ }\r\n/* 159:175 */ if (par1 < 12) {\r\n/* 160:176 */ return 6;\r\n/* 161: */ }\r\n/* 162:178 */ return par1;\r\n/* 163: */ }", "@Override\r\n\t@SuppressWarnings(\"deprecation\")\r\n\tpublic void raiseEvent(Event e) {\r\n\t\tPlayer p = ((PlayerInteractEvent) e).getPlayer();\r\n\t\tPlayerStats stats = plugin.getStats(p);\r\n\t\tif (stats.subtractmoney(cost)) {\r\n\t\t\tif (!items.isEmpty()) {\r\n\t\t\t\tLinkedList<ItemStack> givenItems = new LinkedList<ItemStack>();\r\n\t\t\t\tfor (ItemStack item : items.getItemStacks()) {\r\n\t\t\t\t\tgivenItems.add(item);\r\n\t\t\t\t\tHashMap<Integer, ItemStack> failed = p.getInventory().addItem(item);\r\n\r\n\t\t\t\t\tif (failed != null && failed.size() > 0) {\r\n\t\t\t\t\t\t// the inventory may be full\r\n\t\t\t\t\t\tTribu.messagePlayer(p, (plugin.getLocale(\"Message.UnableToGiveYouThatItem\")),ChatColor.RED);\r\n\t\t\t\t\t\tstats.addMoney(cost);\r\n\t\t\t\t\t\tfor (ItemStack i : givenItems)\r\n\t\t\t\t\t\t\tp.getInventory().remove(i);\r\n\t\t\t\t\t\tgivenItems = null;\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tp.updateInventory();\r\n\t\t\t\t// Alright\r\n\t\t\t\tTribu.messagePlayer(p,String.format(plugin.getLocale(\"Message.PurchaseSuccessfulMoney\"), String.valueOf(stats.getMoney())),ChatColor.GREEN);\r\n\t\t\t} else {\r\n\t\t\t\tTribu.messagePlayer(p,plugin.getLocale(\"Message.UnknownItem\"),ChatColor.RED);\r\n\t\t\t\tstats.addMoney(cost);\r\n\t\t\t}\r\n\r\n\t\t} else {\r\n\t\t\tTribu.messagePlayer(p,plugin.getLocale(\"Message.YouDontHaveEnoughMoney\"),ChatColor.RED);\r\n\t\t}\r\n\r\n\t}", "public int quantityDropped(EaglercraftRandom par1Random) {\n\t\treturn 3 + par1Random.nextInt(5);\n\t}", "public void shootBullet( ){\n bulletsFired.add(new Bullet((short)(this.xPos + BOX_HEIGHT), (short)((this.getYPos() + (BOX_HEIGHT+15))), this.xPos, this.id, (byte) 0, (byte) 0, shootingDirection, currentWeapon.getKey()));\n\n byte weaponFired = currentWeapon.getKey();\n switch (weaponFired){\n case PISTOL_ID: bulletsFired.get(bulletsFired.size()-1).setDmg(DEFAULT_DMG);\n bulletsFired.get(bulletsFired.size()-1).setRange(DEFAULT_RANGE);\n audioHandler.updateSFXVolume(audioHandler.getSoundEffectVolume());\n audioHandler.playSoundEffect(audioHandler.pistolSound);\n break;\n case MACHINEGUN_ID: bulletsFired.get(bulletsFired.size()-1).setDmg(MACHINEGUN_DMG);\n bulletsFired.get(bulletsFired.size()-1).setRange(MACHINEGUN_RANGE);\n audioHandler.updateSFXVolume(audioHandler.getSoundEffectVolume());\n audioHandler.playSoundEffect(audioHandler.machineGunSound);\n break;\n case SHOTGUN_ID: bulletsFired.get(bulletsFired.size()-1).setDmg(SHOTGUN_DMG);\n bulletsFired.get(bulletsFired.size()-1).setRange(SHOTGUN_RANGE);\n audioHandler.updateSFXVolume(audioHandler.getSoundEffectVolume());\n audioHandler.playSoundEffect(audioHandler.shotgunSound);\n break;\n case SNIPER_ID: bulletsFired.get(bulletsFired.size()-1).setDmg(SNIPER_DMG);\n bulletsFired.get(bulletsFired.size()-1).setRange(SNIPER_RANGE);\n audioHandler.updateSFXVolume(audioHandler.getSoundEffectVolume());\n audioHandler.playSoundEffect(audioHandler.machineGunSound);\n break;\n case UZI_ID: bulletsFired.get(bulletsFired.size()-1).setDmg(UZI_DMG);\n bulletsFired.get(bulletsFired.size()-1).setRange(UZI_RANGE);\n audioHandler.updateSFXVolume(audioHandler.getSoundEffectVolume());\n audioHandler.playSoundEffect(audioHandler.machineGunSound);\n break;\n case AI_WEAPON_ID: bulletsFired.get(bulletsFired.size()-1).setDmg(AI_DMG);\n bulletsFired.get(bulletsFired.size()-1).setRange(DEFAULT_RANGE);\n System.out.println(\"Bullet sound \" + audioHandler.getSoundEffectVolume());\n audioHandler.updateSFXVolume(audioHandler.getSoundEffectVolume());\n audioHandler.playSoundEffect(audioHandler.pistolSound);\n break;\n default: bulletsFired.get(bulletsFired.size()-1).setDmg(DEFAULT_DMG);\n bulletsFired.get(bulletsFired.size()-1).setRange(DEFAULT_RANGE);\n\n }\n }", "public static void addLogRecipes() {\n Container tempContainer = new Container() {\n @Override\n public boolean canInteractWith(@Nonnull EntityPlayer player) {\n return false;\n }\n };\n\n InventoryCrafting tempCrafting = new InventoryCrafting(tempContainer, 3, 3);\n\n for (int i = 1; i < 9; i++) {\n tempCrafting.setInventorySlotContents(i, ItemStack.EMPTY);\n }\n\n List<ItemStack> registeredOres = OreDictionary.getOres(\"logWood\");\n\n for (ItemStack logEntry : registeredOres) {\n if (logEntry.getItemDamage() == OreDictionary.WILDCARD_VALUE) {\n for (int j = 0; j < 16; j++) {\n ItemStack log = new ItemStack(logEntry.getItem(), 1, j);\n tempCrafting.setInventorySlotContents(0, log);\n ItemStack resultEntry = MekanismUtils.findMatchingRecipe(tempCrafting, null);\n\n if (!resultEntry.isEmpty()) {\n RecipeHandler.addPrecisionSawmillRecipe(log, StackUtils.size(resultEntry, 6),\n new ItemStack(MekanismItems.Sawdust), 1);\n }\n }\n } else {\n ItemStack log = StackUtils.size(logEntry, 1);\n tempCrafting.setInventorySlotContents(0, log);\n ItemStack resultEntry = MekanismUtils.findMatchingRecipe(tempCrafting, null);\n\n if (!resultEntry.isEmpty()) {\n RecipeHandler.addPrecisionSawmillRecipe(log, StackUtils.size(resultEntry, 6),\n new ItemStack(MekanismItems.Sawdust), 1);\n }\n }\n }\n }", "boolean hasBonusItemDrop();", "public int idDropped(int var1, Random var2, int var3)\r\n {\r\n return this.blockID == mod_XaedCraft.oreCopper.blockID ? mod_XaedCraft.copperdust.itemID : (this.blockID == mod_XaedCraft.oreTin.blockID ? mod_XaedCraft.tindust.itemID : (this.blockID == mod_XaedCraft.oreRune.blockID ? mod_XaedCraft.runeBlank.itemID : (this.blockID == mod_XaedCraft.oreBrimstone.blockID ? Item.gunpowder.itemID : this.blockID)));\r\n }", "public int quantityDropped(int meta, int fortune, Random par1Random) {\n\t\tRandom rnd = new Random();\n\t\tfortune = fortune+1;\n\t\tint i = rnd.nextInt(3) + 1;\n\t\tint fortrand = par1Random.nextInt(fortune);\n\t\tfortrand = fortrand * (rnd.nextInt(3)+1);\n\t\ti = i + fortrand;\n\t\tSystem.out.println(\"fortune: \" + (fortune - 1));\n\t\tSystem.out.println(i);\n\n\t\treturn i;\n\t}", "@EventHandler\n\tpublic void onPlayerDeath(final PlayerDeathEvent event) {\n\t\tif (event.getEntity().getKiller() != null) {\n\t\t\tif (event.getEntity().getKiller() instanceof Player && event.getEntity() instanceof Player && pli.global_players.containsKey(event.getEntity().getName()) && pli.global_players.containsKey(event.getEntity().getKiller().getName())) {\n\t\t\t\tevent.getDrops().clear();\n\t\t\t\tevent.getEntity().setHealth(20);\n\t\t\t\t// final Location l = event.getEntity().getLocation();\n\t\t\t\tfinal String killername = event.getEntity().getKiller().getName();\n\t\t\t\tfinal String entityKilled = event.getEntity().getName();\n\n\t\t\t\tBukkit.getScheduler().runTask(this, new Runnable() {\n\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\tpli.getRewardsInstance().giveKillReward(killername, 2);\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tfinal Player p1 = event.getEntity().getKiller();\n\t\t\t\tfinal Player p2 = event.getEntity();\n\n\t\t\t\tIArena a = (IArena) pli.global_players.get(p1.getName());\n\t\t\t\tUtil.teleportPlayerFixed(p2, a.getSpawns().get(r.nextInt(a.getSpawns().size())));\n\n\t\t\t\tInteger gpkiller = 2;\n\t\t\t\tInteger gploser = 0;\n\t\t\t\tif (getConfig().isSet(\"player.\" + killername)) {\n\t\t\t\t\tgpkiller = getConfig().getInt(\"player.\" + killername + \".gp\") + 2; // +2 gp\n\t\t\t\t}\n\t\t\t\tif (getConfig().isSet(\"player.\" + entityKilled)) {\n\t\t\t\t\tgploser = Math.max(getConfig().getInt(\"player.\" + entityKilled + \".gp\") - 1, 0); // -1 gp\n\t\t\t\t}\n\t\t\t\tgetConfig().set(\"player.\" + killername + \".gp\", gpkiller);\n\t\t\t\tgetConfig().set(\"player.\" + entityKilled + \".gp\", gploser);\n\t\t\t\tthis.saveConfig();\n\n\t\t\t\ttry {\n\t\t\t\t\tmainsql.updateStats(p1.getName(), 2);\n\t\t\t\t\tmainsql.updateStats(p2.getName(), -1);\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\tSystem.out.println(\"Failed updating sql gp.\");\n\t\t\t\t}\n\n\t\t\t\tBukkit.getScheduler().runTaskLater(this, new Runnable() {\n\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\tp2.getInventory().clear();\n\t\t\t\t\t\tp2.getInventory().setHelmet(null);\n\t\t\t\t\t\tp2.getInventory().setChestplate(null);\n\t\t\t\t\t\tp2.getInventory().setLeggings(null);\n\t\t\t\t\t\tp2.getInventory().setBoots(null);\n\t\t\t\t\t\tp2.getInventory().setArmorContents(null);\n\t\t\t\t\t\tfor (ItemStack item : start_items) {\n\t\t\t\t\t\t\tp2.getInventory().addItem(item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tp2.updateInventory();\n\t\t\t\t\t}\n\t\t\t\t}, 20L);\n\n\t\t\t\tp2.playSound(p2.getLocation(), Sound.CAT_MEOW, 1F, 1);\n\t\t\t\tlv.put(p2.getName(), 0);\n\n\t\t\t\tArrayList<String> keys = new ArrayList<String>();\n\t\t\t\tif (getConfig().isConfigurationSection(\"player.\" + p2.getName() + \".items\")) {\n\t\t\t\t\tgetConfig().set(\"player.\" + p2.getName() + \".items\", null);\n\t\t\t\t\tthis.saveConfig();\n\t\t\t\t}\n\n\t\t\t\tfor (PotionEffect effect : p2.getActivePotionEffects())\n\t\t\t\t\tp2.removePotionEffect(effect.getType());\n\n\t\t\t\tfor (PotionEffect effect : p1.getActivePotionEffects())\n\t\t\t\t\tp1.removePotionEffect(effect.getType());\n\n\t\t\t\tp1.playEffect(p1.getLocation(), Effect.POTION_BREAK, 5);\n\t\t\t\tInteger current = lv.get(p1.getName());\n\t\t\t\tlv.put(p1.getName(), current + 1);\n\t\t\t\tp1.sendMessage(im.upgrade.replaceAll(\"<level>\", Integer.toString(lv.get(p1.getName()))));\n\t\t\t\tLevel.updatelv(m, lv, p1);\n\n\t\t\t\tscoreboard.updateScoreboard(a);\n\n\t\t\t\tp1.setFoodLevel(20);\n\t\t\t\tp1.setHealth(20);\n\t\t\t\tp2.setHealth(20);\n\t\t\t\tp2.setFoodLevel(20);\n\n\t\t\t\tthis.addextraitems(p1);\n\t\t\t}\n\t\t} else {\n\t\t\t// death by something else -> respawn\n\n\t\t\tif (pli.global_players.containsKey(event.getEntity().getName())) {\n\t\t\t\tevent.getEntity().setHealth(20);\n\t\t\t\tif (event.getEntity() != null) {\n\t\t\t\t\tif (event.getEntity() instanceof Player) {\n\t\t\t\t\t\tevent.getDrops().clear();\n\t\t\t\t\t\tfinal Player p = (Player) event.getEntity();\n\t\t\t\t\t\tIArena a = (IArena) pli.global_players.get(p.getName());\n\t\t\t\t\t\tif (a != null && p != null) {\n\t\t\t\t\t\t\tUtil.teleportPlayerFixed(p, a.getSpawns().get(r.nextInt(a.getSpawns().size())));\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tp.playSound(p.getLocation(), Sound.CAT_MEOW, 1F, 1);\n\n\t\t\t\t\t\tp.setFoodLevel(20);\n\n\t\t\t\t\t\tlv.put(p.getName(), 0);\n\n\t\t\t\t\t\tBukkit.getScheduler().runTaskLater(this, new Runnable() {\n\t\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\t\tp.getInventory().clear();\n\t\t\t\t\t\t\t\tp.getInventory().setHelmet(null);\n\t\t\t\t\t\t\t\tp.getInventory().setChestplate(null);\n\t\t\t\t\t\t\t\tp.getInventory().setLeggings(null);\n\t\t\t\t\t\t\t\tp.getInventory().setBoots(null);\n\t\t\t\t\t\t\t\tp.getInventory().setArmorContents(null);\n\t\t\t\t\t\t\t\tfor (ItemStack item : start_items) {\n\t\t\t\t\t\t\t\t\tp.getInventory().addItem(item);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tp.updateInventory();\n\n\t\t\t\t\t\t\t\tm.addextraitems(p);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}, 20L);\n\n\t\t\t\t\t\tfor (PotionEffect effect : p.getActivePotionEffects())\n\t\t\t\t\t\t\tp.removePotionEffect(effect.getType());\n\n\t\t\t\t\t\tp.setHealth(20);\n\t\t\t\t\t\tp.setFoodLevel(20);\n\n\t\t\t\t\t\tthis.addextraitems(p);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public int idDropped(int par1, EaglercraftRandom par2Random, int par3) {\n\t\treturn Item.sign.itemID;\n\t}" ]
[ "0.6963535", "0.65014786", "0.62263685", "0.62168723", "0.6155442", "0.6087796", "0.6060997", "0.60598767", "0.5985755", "0.59709036", "0.5953854", "0.5950818", "0.59334403", "0.59198123", "0.5898832", "0.58516634", "0.5842716", "0.5817982", "0.5816051", "0.5800771", "0.5765814", "0.57552874", "0.5753499", "0.57488984", "0.5728286", "0.57117105", "0.5703861", "0.56975985", "0.56902295", "0.56730443", "0.5659883", "0.5654656", "0.5650177", "0.5636391", "0.5627513", "0.56178933", "0.56074184", "0.559406", "0.55860275", "0.5580798", "0.5567376", "0.556463", "0.5549662", "0.55493164", "0.5544147", "0.55316067", "0.5530355", "0.55245197", "0.55039585", "0.5498275", "0.5487229", "0.5477703", "0.5471058", "0.5452537", "0.5448115", "0.54394746", "0.5436993", "0.5421689", "0.5415659", "0.54145324", "0.54144204", "0.54108256", "0.54038244", "0.54030704", "0.53938913", "0.5393811", "0.53902304", "0.5385888", "0.5383271", "0.537669", "0.5372629", "0.5370109", "0.5351515", "0.5348198", "0.534461", "0.5343515", "0.53416246", "0.5319048", "0.53173494", "0.5307378", "0.53013647", "0.53003985", "0.5295716", "0.52942306", "0.5290324", "0.5275259", "0.52743375", "0.5274063", "0.5266611", "0.5266341", "0.5264073", "0.52594715", "0.5255357", "0.5252128", "0.5250465", "0.52388155", "0.52373135", "0.5226015", "0.5225639", "0.52212733" ]
0.6710514
1
Manage Special Events drops created by GM for a defined period. Concept : During a Special Event all L2Attackable can drop extra Items. Those extra Items are defined in the table allNpcDateDrops of the EventDroplist. Each Special Event has a start and end date to stop to drop extra Items automaticaly. Actions : If an extra drop must be generated Get an Item Identifier (random) from the DateDrop Item table of this Event Get the Item quantity dropped (random) Create this or these L2ItemInstance corresponding to this Item Identifier If the autoLoot mode is actif and if the L2Character that has killed the L2Attackable is a L2PcInstance, give this or these Item(s) to the L2PcInstance that has killed the L2Attackable If the autoLoot mode isn't actif or if the L2Character that has killed the L2Attackable is not a L2PcInstance, add this or these Item(s) in the world as a visible object at the position where mob was last
public void doEventDrop(final L2Character lastAttacker) { L2PcInstance player = null; if (lastAttacker instanceof L2PcInstance) { player = (L2PcInstance) lastAttacker; } else if (lastAttacker instanceof L2Summon) { player = ((L2Summon) lastAttacker).getOwner(); } if (player == null) { return; // Don't drop anything if the last attacker or ownere isn't L2PcInstance } if (player.getLevel() - getLevel() > 9) { return; } // Go through DateDrop of EventDroplist allNpcDateDrops within the date range for (final DateDrop drop : EventDroplist.getInstance().getAllDrops()) { if (Rnd.get(L2DropData.MAX_CHANCE) < drop.chance) { RewardItem item = new RewardItem(drop.items[Rnd.get(drop.items.length)], Rnd.get(drop.min, drop.max)); if (Config.AUTO_LOOT) { final L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId()); if (!player.getInventory().validateCapacity(item_templ)) { DropItem(player, item); } else { player.doAutoLoot(this, item); // Give this or these Item(s) to the L2PcInstance that has killed the L2Attackable } } else { DropItem(player, item); // drop the item on the ground } item = null; } } player = null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@EventHandler\r\n public void mobkillLst(EntityDeathEvent event) {\r\n if (event.getEntity().getKiller() instanceof Player && event.getEntity().getType() != EntityType.PLAYER) {//Ensure entity that is killed is not a player\r\n int xpmult = (int) (event.getDroppedExp() * main.XPMult);\r\n event.setDroppedExp(xpmult);\r\n }\r\n }", "public void rollCombatDrop() {\n\t\tRandom r=new Random();\n\t\t\n\t\tint x=r.nextInt(3);\n\t\tItem i=combatDrops.get(x);\n\t\taddItem(i.getName());\n\t\t\n\t\tevents.appendText(\"You find an \"+i.getName()+\" after defeating the \"+e.getName()+\"!\\n\"); // Infrom player\n\t}", "@SubscribeEvent(priority=EventPriority.NORMAL, receiveCanceled=true)\n\tpublic void spiderDrop(LivingDropsEvent event)\n\t{\n\t if (event.getEntity() instanceof EntitySpider)\n\t {\n\t int radomint=new Random().nextInt(3);\n\t if(radomint==0){\n\t ItemStack itemStackToDrop = new ItemStack(ItemLoader.spiderGland, 1);\n\t event.getDrops().add(new EntityItem(event.getEntity().worldObj, event.getEntity().posX, \n\t event.getEntity().posY, event.getEntity().posZ, itemStackToDrop));\n\t }\n\t }\n\t}", "protected void dropDeathLoot(boolean flag, int i) {\n java.util.List<org.bukkit.inventory.ItemStack> loot = new java.util.ArrayList<org.bukkit.inventory.ItemStack>();\n\n if (!this.isSheared()) {\n loot.add(new org.bukkit.inventory.ItemStack(org.bukkit.Material.WOOL, 1, (short) 0, (byte) this.getColor()));\n }\n\n org.bukkit.craftbukkit.event.CraftEventFactory.callEntityDeathEvent(this, loot);\n // CraftBukkit end\n }", "@ForgeSubscribe(priority = EventPriority.HIGHEST)\n public void onLivingDrops(LivingDropsEvent event) {\n if (!event.recentlyHit)\n return;\n int id = -1;\n if (event.entityLiving instanceof EntityZombie)\n id = event.entityLiving instanceof EntityPigZombie ? -1 : 2;\n else if (event.entityLiving instanceof EntitySkeleton)\n id = ((EntitySkeleton)event.entityLiving).getSkeletonType() == 0 ? 0 : -1;\n else if (event.entityLiving instanceof EntityCreeper)\n id = 4;\n if (id < 0)\n return;\n if (_PlayerHeads.debug);\n else if (_PlayerHeads.dropRates[id] <= 0.0 || _PlayerHeads.random.nextDouble() - 0.005 * (double)event.lootingLevel >= _PlayerHeads.dropRates[id])\n return;\n ItemStack head = new ItemStack(Item.skull, 1, id);\n EntityItem drop = new EntityItem(event.entityLiving.worldObj, event.entityLiving.posX, event.entityLiving.posY, event.entityLiving.posZ, head);\n drop.delayBeforeCanPickup = 10;\n event.drops.add(drop);\n }", "void onItemDropped(EntityId droppedItem);", "@EventHandler\n\tpublic void entityDeath(EntityDeathEvent e){\n\t\tRandom random = new Random();\n\n\t\tdouble chance = 0.4f;\n\t\tif(random.nextDouble() <= chance) {\n\t\t\te.getEntity().getWorld().dropItem(e.getEntity().getLocation(), new ItemStack(Material.LEATHER));\n\t\t}\n\t}", "@EventHandler\n public void onBreak(BlockBreakEvent e) {\n if(e.getPlayer().getItemInHand().hasItemMeta()) {\n if (e.getPlayer().getItemInHand().getItemMeta().hasDisplayName()) {\n if (e.getPlayer().getItemInHand().getItemMeta().getDisplayName().equals(ChatColor.AQUA + \"\" + ChatColor.BOLD +\n \"Swift Drill\")) {\n e.setDropItems(false);\n e.setExpToDrop(0);\n\n if(!(e.getPlayer().isSneaking())){\n Block b1 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX() - 1,\n e.getBlock().getY() + 1,\n e.getBlock().getZ());\n Collection<ItemStack> b1drop = b1.getDrops();\n b1.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b1drop.toArray(new ItemStack[b1drop.size()]));\n\n Block b2 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX(),\n e.getBlock().getY() + 1,\n e.getBlock().getZ());\n Collection<ItemStack> b2drop = b2.getDrops();\n b2.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b2drop.toArray(new ItemStack[b2drop.size()]));\n\n Block b3 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX() + 1,\n e.getBlock().getY() + 1,\n e.getBlock().getZ());\n Collection<ItemStack> b3drop = b3.getDrops();\n b3.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b3drop.toArray(new ItemStack[b3drop.size()]));\n\n Block b4 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX() - 1,\n e.getBlock().getY(),\n e.getBlock().getZ());\n Collection<ItemStack> b4drop = b4.getDrops();\n b4.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b4drop.toArray(new ItemStack[b4drop.size()]));\n\n Block b5 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX() + 1,\n e.getBlock().getY(),\n e.getBlock().getZ());\n Collection<ItemStack> b5drop = b5.getDrops();\n b5.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b5drop.toArray(new ItemStack[b5drop.size()]));\n\n Block b6 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX() - 1,\n e.getBlock().getY() - 1,\n e.getBlock().getZ());\n Collection<ItemStack> b6drop = b6.getDrops();\n b6.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b6drop.toArray(new ItemStack[b6drop.size()]));\n\n Block b7 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX(),\n e.getBlock().getY() - 1,\n e.getBlock().getZ());\n Collection<ItemStack> b7drop = b7.getDrops();\n b7.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b7drop.toArray(new ItemStack[b7drop.size()]));\n\n Block b8 = e.getPlayer().getWorld().getBlockAt(e.getBlock().getX() + 1,\n e.getBlock().getY() - 1,\n e.getBlock().getZ());\n Collection<ItemStack> b8drop = b8.getDrops();\n b8.setType(Material.AIR);\n SwiftDrillInv.inv.addItem(b8drop.toArray(new ItemStack[b8drop.size()]));\n }\n\n Collection<ItemStack> drop = e.getBlock().getDrops();\n SwiftDrillInv.inv.addItem(drop.toArray(new ItemStack[drop.size()]));\n }\n }\n }\n }", "public void doItemDrop(final L2NpcTemplate npcTemplate, final L2Character lastAttacker)\n\t{\n\t\tL2PcInstance player = null;\n\t\t\n\t\tif (lastAttacker instanceof L2PcInstance)\n\t\t{\n\t\t\tplayer = (L2PcInstance) lastAttacker;\n\t\t}\n\t\telse if (lastAttacker instanceof L2Summon)\n\t\t{\n\t\t\tplayer = ((L2Summon) lastAttacker).getOwner();\n\t\t}\n\t\t\n\t\t// Don't drop anything if the last attacker or ownere isn't L2PcInstance\n\t\tif (player == null)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tif (EngineModsManager.onNpcDrop(this, lastAttacker))\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tfinal int levelModifier = calculateLevelModifierForDrop(player); // level modifier in %'s (will be subtracted from drop chance)\n\t\t\n\t\t// Check the drop of a cursed weapon\n\t\tif (levelModifier == 0 && player.getLevel() > 20)\n\t\t{\n\t\t\tCursedWeaponsManager.getInstance().checkDrop(this, player);\n\t\t}\n\t\t\n\t\t// now throw all categorized drops and handle spoil.\n\t\tfor (final L2DropCategory cat : npcTemplate.getDropData())\n\t\t{\n\t\t\tRewardItem item = null;\n\t\t\tif (cat.isSweep())\n\t\t\t{\n\t\t\t\t// according to sh1ny, seeded mobs CAN be spoiled and swept.\n\t\t\t\tif (isSpoil()/* && !isSeeded() */)\n\t\t\t\t{\n\t\t\t\t\tList<RewardItem> sweepList = new ArrayList<>();\n\t\t\t\t\t\n\t\t\t\t\tfor (final L2DropData drop : cat.getAllDrops())\n\t\t\t\t\t{\n\t\t\t\t\t\titem = calculateRewardItem(player, drop, levelModifier, true);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (item == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.DEBUG)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tLOGGER.debug(\"Item id to spoil: \" + item.getItemId() + \" amount: \" + item.getCount());\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tsweepList.add(item);\n\t\t\t\t\t\t\n\t\t\t\t\t\titem = null;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Set the table sweepItems of this L2Attackable\n\t\t\t\t\tif (!sweepList.isEmpty())\n\t\t\t\t\t{\n\t\t\t\t\t\tsweepItems = sweepList.toArray(new RewardItem[sweepList.size()]);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tsweepList = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tif (isSeeded())\n\t\t\t\t{\n\t\t\t\t\tL2DropData drop = cat.dropSeedAllowedDropsOnly();\n\t\t\t\t\t\n\t\t\t\t\tif (drop == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = calculateRewardItem(player, drop, levelModifier, false);\n\t\t\t\t\tdrop = null;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\titem = calculateCategorizedRewardItem(player, cat, levelModifier);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (item != null)\n\t\t\t\t{\n\t\t\t\t\tif (Config.DEBUG)\n\t\t\t\t\t{\n\t\t\t\t\t\tLOGGER.debug(\"Item id to drop: \" + item.getItemId() + \" amount: \" + item.getCount());\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Check if the autoLoot mode is active\n\t\t\t\t\tif (Config.AUTO_LOOT)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (item_templ == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tLOGGER.info(\"ERROR: Item id to autoloot \" + item.getItemId() + \" has not template into items/armor/weapon tables.. It cannot be dropped..\");\n\t\t\t\t\t\t\t// DropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ) || !Config.AUTO_LOOT_BOSS && this instanceof L2RaidBossInstance || !Config.AUTO_LOOT_BOSS && this instanceof L2GrandBossInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.doAutoLoot(this, item); // Give this or these Item(s) to the L2PcInstance that has killed the L2Attackable\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item); // drop the item on the ground\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Broadcast message if RaidBoss was defeated\n\t\t\t\t\tif (this instanceof L2RaidBossInstance || this instanceof L2GrandBossInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tSystemMessage sm;\n\t\t\t\t\t\tsm = new SystemMessage(SystemMessageId.S1_DIED_DROPPED_S3_S2);\n\t\t\t\t\t\tsm.addString(getName());\n\t\t\t\t\t\tsm.addItemName(item.getItemId());\n\t\t\t\t\t\tsm.addNumber(item.getCount());\n\t\t\t\t\t\tbroadcastPacket(sm);\n\t\t\t\t\t\tsm = null;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\titem = null;\n\t\t}\n\t\t\n\t\t// Apply Special Item drop with rnd qty for champions\n\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion() && player.getLevel() <= getLevel() + 3 && Config.L2JMOD_CHAMPION_REWARD > 0 && Rnd.get(100) < Config.L2JMOD_CHAMPION_REWARD)\n\t\t{\n\t\t\tint champqty = Rnd.get(Config.L2JMOD_CHAMPION_REWARD_QTY);\n\t\t\tchampqty++; // quantity should actually vary between 1 and whatever admin specified as max, inclusive.\n\t\t\t\n\t\t\tRewardItem item = new RewardItem(Config.L2JMOD_CHAMPION_REWARD_ID, champqty);\n\t\t\t\n\t\t\t// Give this or these Item(s) to the L2PcInstance that has killed the L2Attackable\n\t\t\tif (Config.AUTO_LOOT)\n\t\t\t{\n\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\n\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tplayer.addItem(\"ChampionLoot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tDropItem(player, item);\n\t\t\t}\n\t\t\t\n\t\t\titem = null;\n\t\t}\n\t\t\n\t\t// Instant Item Drop :>\n\t\tfinal double rateHp = getStat().calcStat(Stats.MAX_HP, 1, this, null);\n\t\t\n\t\tif (rateHp < 2 && String.valueOf(npcTemplate.type).contentEquals(\"L2Monster\")) // only L2Monster with <= 1x HP can drop herbs\n\t\t{\n\t\t\tboolean hp = false;\n\t\t\tboolean mp = false;\n\t\t\tboolean spec = false;\n\t\t\t\n\t\t\t// ptk - patk type enhance\n\t\t\tint random = Rnd.get(1000); // note *10\n\t\t\t\n\t\t\tif (random < Config.RATE_DROP_SPECIAL_HERBS && !spec) // && !_spec useless yet\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(8612, 1); // Herb of Warrior\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t\tspec = true;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tfor (int i = 0; i < 3; i++)\n\t\t\t\t{\n\t\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\t\n\t\t\t\t\tif (random < Config.RATE_DROP_COMMON_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tRewardItem item = null;\n\t\t\t\t\t\tif (i == 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8606, 1); // Herb of Power\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (i == 1)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8608, 1); // Herb of Atk. Spd.\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (i == 2)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8610, 1); // Herb of Critical Attack\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (item == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// mtk - matk type enhance\n\t\t\trandom = Rnd.get(1000); // note *10\n\t\t\t\n\t\t\tif (random < Config.RATE_DROP_SPECIAL_HERBS && !spec)\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(8613, 1); // Herb of Mystic\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t\tspec = true;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tfor (int i = 0; i < 2; i++)\n\t\t\t\t{\n\t\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\t\n\t\t\t\t\tif (random < Config.RATE_DROP_COMMON_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tRewardItem item = null;\n\t\t\t\t\t\tif (i == 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8607, 1); // Herb of Magic\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (i == 1)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\titem = new RewardItem(8609, 1); // Herb of Casting Speed\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (item == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// hp+mp type\n\t\t\trandom = Rnd.get(1000); // note *10\n\t\t\t\n\t\t\tif (random < Config.RATE_DROP_SPECIAL_HERBS && !spec)\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(8614, 1); // Herb of Recovery\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t\tmp = true;\n\t\t\t\thp = true;\n\t\t\t\tspec = true;\n\t\t\t}\n\t\t\t\n\t\t\t// hp - restore hp type\n\t\t\tif (!hp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(100);\n\t\t\t\tif (random < Config.RATE_DROP_MP_HP_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8600, 1); // Herb of Life\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t\thp = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!hp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_GREATER_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8601, 1); // Greater Herb of Life\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t\thp = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!hp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(1000); // note *10\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_SUPERIOR_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8602, 1); // Superior Herb of Life\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// mp - restore mp type\n\t\t\tif (!mp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_MP_HP_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8603, 1); // Herb of Mana\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t\tmp = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!mp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(100);\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_GREATER_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8604, 1); // Greater Herb of Mana\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t\tmp = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (!mp)\n\t\t\t{\n\t\t\t\trandom = Rnd.get(1000); // note *10\n\t\t\t\t\n\t\t\t\tif (random < Config.RATE_DROP_SUPERIOR_HERBS)\n\t\t\t\t{\n\t\t\t\t\tRewardItem item = new RewardItem(8605, 1); // Superior Herb of Mana\n\t\t\t\t\t\n\t\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\titem = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// speed enhance type\n\t\t\trandom = Rnd.get(100);\n\t\t\t\n\t\t\tif (random < Config.RATE_DROP_COMMON_HERBS)\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(8611, 1); // Herb of Speed\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT && Config.AUTO_LOOT_HERBS)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.addItem(\"Loot\", item.getItemId(), item.getCount(), this, true);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t}\n\t\t}\n\t}", "public void dropExplosives() {\n // Updates the time elapsed for each of the explosives\n for (int i=0; i<this.explosives.size(); i++) {\n Explosive dormantExplosive = this.explosives.get(i);\n dormantExplosive.increaseTime();\n }\n // If the Airplane has reached the end, doesn't detect any enemies\n // Isn't deleted straight away as it needs to wait for explosives to detonate\n if (super.outOfBounds()) {return;}\n this.timeElapsedDrop += ShadowDefend.getTimescale()/FPS;\n //Adds a new explosive\n if (this.timeElapsedDrop >= this.dropTime) {\n this.timeElapsedDrop = 0;\n Explosive newExplosive = new Explosive(super.getCenter());\n // Centers the explosive at the airplane's current position\n newExplosive.centerRectAt(super.getCenter());\n this.explosives.add(newExplosive);\n // Generates a new drop time in range\n this.dropTime = generateDropTime();\n this.numDropped++;\n }\n\n }", "@ForgeSubscribe\n \tpublic void onLivingDeath(LivingDeathEvent event) {\n \t\t\n \t\tEntityLivingBase entity = event.entityLiving;\n \t\tif (entity.worldObj.isRemote) return;\n \t\tItemStack backpack = ItemBackpack.getBackpack(entity);\n \t\tif (backpack == null) return;\n \t\tPropertiesBackpack backpackData = ItemBackpack.getBackpackData(entity);\n \t\tif (backpackData.contents == null) return;\n \t\t\n \t\tboolean keepInventory = entity.worldObj.getGameRules().getGameRuleBooleanValue(\"keepInventory\");\n \t\tif ((entity instanceof EntityPlayer) && keepInventory) {\n \t\t\t\n \t\t\t// If keep inventory is on, instead temporarily save the contents\n \t\t\t// to the persistent NBT tag and get them back when the player respawns.\n \t\t\t\n \t\t\tEntityPlayer player = (EntityPlayer)entity;\n \t\t\tNBTTagCompound compound = player.getEntityData();\n \t\t\tNBTTagCompound persistent;\n \t\t\tif (!compound.hasKey(EntityPlayer.PERSISTED_NBT_TAG)) {\n \t\t\t\tpersistent = new NBTTagCompound();\n \t\t\t\tcompound.setTag(EntityPlayer.PERSISTED_NBT_TAG, persistent);\n \t\t\t} else persistent = compound.getCompoundTag(EntityPlayer.PERSISTED_NBT_TAG);;\n \t\t\t\n \t\t\tNBTTagCompound backpackCompound = new NBTTagCompound();\n \t\t\tbackpackCompound.setInteger(\"count\", backpackData.contents.length);\n \t\t\tbackpackCompound.setTag(\"Items\", NbtUtils.writeItems(backpackData.contents));\n \t\t\tpersistent.setTag(\"Backpack\", backpackCompound);\n \t\t\t\n \t\t} else {\n \t\t\t\n \t\t\tfor (ItemStack stack : backpackData.contents)\n \t\t\t\tWorldUtils.dropStackFromEntity(entity, stack, 4.0F);\n \t\t\tbackpackData.contents = null;\n \t\t\t\n \t\t}\n \t\t\n \t}", "public void dropEntireInventory(World world, BlockPos pos, int id, int metadata) {\n int x = pos.getX();\n int y = pos.getY();\n int z = pos.getZ();\n TileEntity tileEntity = world.getTileEntity(pos);\n if (tileEntity != null && tileEntity instanceof IInventory) {\n IInventory inventory = (IInventory) tileEntity;\n for (int i = 0; i < inventory.getSizeInventory(); ++i) {\n ItemStack stack = inventory.getStackInSlot(i);\n if (stack != null) {\n Random random = new Random();\n float sx = random.nextFloat() * 0.8F + 0.1F;\n float sy = random.nextFloat() * 0.8F + 0.1F;\n float sz = random.nextFloat() * 0.8F + 0.1F;\n while (stack.stackSize > 0) {\n int qty = random.nextInt(21) + 10;\n if (qty > stack.stackSize) {\n qty = stack.stackSize;\n }\n stack.stackSize -= qty;\n EntityItem eitem = new EntityItem(world, x + sx, y + sy, z + sz, new ItemStack(stack.getItem(), qty, stack.getItemDamage()));\n if (stack.hasTagCompound()) {\n eitem.getEntityItem().setTagCompound((NBTTagCompound) stack.getTagCompound().copy());\n }\n float displacement = 0.05F;\n eitem.motionX = (float) random.nextGaussian() * displacement;\n eitem.motionY = (float) random.nextGaussian() * displacement + 0.2F;\n eitem.motionZ = (float) random.nextGaussian() * displacement;\n world.spawnEntityInWorld(eitem);\n }\n }\n }\n }\n }", "@Override\n protected void dropFewItems(boolean hit, int looting) {\n super.dropFewItems(hit, looting);\n if (hit && (this.rand.nextInt(3) == 0 || this.rand.nextInt(1 + looting) > 0)) {\n Item drop = null;\n switch (this.rand.nextInt(5)) {\n case 0:\n drop = Items.gunpowder;\n break;\n case 1:\n drop = Items.sugar;\n break;\n case 2:\n drop = Items.spider_eye;\n break;\n case 3:\n drop = Items.fermented_spider_eye;\n break;\n case 4:\n drop = Items.speckled_melon;\n break;\n }\n if (drop != null) {\n this.dropItem(drop, 1);\n }\n }\n }", "public Item getItemDropped(int meta, Random p_149650_2_, int p_149650_3_)\n\t {\n\t \treturn MGHouseItems.item_boat_door;\n\t }", "public void createNewCraftEntry(MessageReceivedEvent event, String[] args, Item item){\n int totalBonus = 10+((Integer.parseInt(args[2])-10)/2);\n System.out.println((Integer.parseInt(args[2])-10)/2 + \" and \" + totalBonus);\n if(args[1] != null) {\n if (args[0].equals(\"true\")) {\n totalBonus += (Integer.parseInt(args[1]) * 2);\n } else {\n totalBonus += Integer.parseInt(args[1]);\n }\n }\n int baseTime=20;\n String rarity = item.getRarity();\n switch(rarity){\n case \"common\":\n case \"Common\":\n baseTime = 20;\n if(item.isConsumable()){\n baseTime = baseTime/3;\n }\n break;\n case \"uncommon\":\n case \"Uncommon\":\n baseTime = 100;\n if(item.isConsumable()){\n baseTime = baseTime/3;\n }\n break;\n case \"rare\":\n case \"Rare\":\n baseTime = 240;\n if(item.isConsumable()){\n baseTime = baseTime/4;\n }\n break;\n case \"very rare\":\n case \"Very Rare\":\n baseTime = 400;\n if(item.isConsumable()){\n baseTime = baseTime/4;\n }\n break;\n case \"legendary\":\n case \"Legendary\":\n baseTime = 500;\n if(item.isConsumable()){\n baseTime = baseTime/4;\n }\n break;\n }\n int finalTime = baseTime/totalBonus;\n LocalDateTime timeStart = LocalDateTime.now();\n LocalDateTime timeEnd = LocalDateTime.now().plusDays(finalTime);\n String crafterID = event.getAuthor().getId();\n //Corrects time if it is after the completion of the daily crafting cycle\n if(timeEnd.toLocalDate().equals(timeStart.toLocalDate())){\n if(timeStart.toLocalTime().isAfter(LocalTime.of(13,0))){\n timeEnd = timeEnd.plusDays(1);\n }\n }\n String timestampStart = timeStart.toString();\n String timestampEnd = timeEnd.toString();\n String crafterChar = args[4];\n String channelID = event.getChannel().getId();\n\n String outputString = crafterID + \",\" + timestampStart + \",\" + timestampEnd + \",\" + item.getName() + \",\" + crafterChar + \",\" + channelID;\n String[] outputArray = outputString.split(\",\");\n\n if(timeEnd.toLocalDate().equals(timeStart.toLocalDate())){\n itemsDueToday.add(outputArray);\n }\n craftBacklog.add(outputArray);\n\n List<Object> writeList = new ArrayList<>();\n for(String field:outputArray){\n writeList.add(field);\n }\n\n try {\n SheetInformationBuffer.writeToCraft(writeList);\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n String dateEnd = timeEnd.toLocalDate().toString();\n event.getChannel().sendMessage(\"Congratulations <@\" + crafterID + \">! Your ***\" + item.getName() + \"*** will be ready on: \" + dateEnd).queue();\n\n }", "public void rollCommonDrop() {\n\t\tRandom r=new Random();\n\t\t\n\t\tint x=r.nextInt(6);\n\t\tItem i=randomDrops.get(x);\n\t\taddItem(i.getName());\n\t\t\n\t\tevents.appendText(\"You find an \"+i.getName()+\" in your adventures!\\n\");\t// Inform player\n\t}", "@EventHandler\n public void onBlockDropEvent(BlockBreakEvent event) {\n if (!plugin.config.enabled) {\n //plugin is not enabled.. do nothing\n return;\n }\n\n Player player = event.getPlayer();\n //message for debug\n String debugMSG = \"\";\n //test if player is in creative\n if (player.getGameMode().equals(GameMode.CREATIVE)){\n //don't drop anything\n if (plugin.config.debug) {\n debugMSG = ChatColor.DARK_GREEN + \"[DEBUG]\"\n + ChatColor.YELLOW + \"[\" + player.getDisplayName() + \"]\"\n + ChatColor.RESET;\n plugin.console.log(debugMSG + \"Player in Creative Mode. Not Dropping Items.\");\n }\n return;\n }\n\n Block block = event.getBlock();\n\n\n String blockLocation = \"\";\n if (plugin.config.debug) {\n debugMSG = ChatColor.DARK_GREEN + \"[DEBUG]\"\n + ChatColor.YELLOW + \"[\" + player.getDisplayName() + \"]\"\n + ChatColor.BLUE + \"[\" + block.getType().name() + \"]\"\n + ChatColor.RESET;\n blockLocation = ChatColor.DARK_AQUA + \" X:\" + ChatColor.GRAY + block.getLocation().getBlockX()\n + ChatColor.DARK_AQUA + \" Y:\" + ChatColor.GRAY + block.getLocation().getBlockY()\n + ChatColor.DARK_AQUA + \" Z:\" + ChatColor.GRAY + block.getLocation().getBlockZ();\n }\n\n //test to see if this block was placed\n List<MetadataValue> blockD = block.getMetadata(placeBlock);\n if (blockD.size() != 0) {\n //block was placed\n // don't drop anything\n\n //debug\n if (plugin.config.debug) {\n plugin.console.log(debugMSG\n + \" Block Was Placed. No Drops Allowed. \"\n + blockLocation\n );\n }\n return;\n }\n\n Material brokenBlock = block.getType();//gets the material that was just broken\n\n\n //test if we need to check out list of Ores,\n // OR... are we doing it for ALL Blocks\n Ore tempOre = new Ore();//set up tempOre for good measure\n\n if (plugin.config.allBlocks) {\n //we are looking at all blocks\n // make tempOre equal to the block that we broke\n tempOre.setBlock(brokenBlock);\n tempOre.setExp(plugin.config.allBlocks_exp);\n tempOre.setMultiplier(plugin.config.allBlocks_multiplier);\n tempOre.setChance(plugin.config.allBlocks_chance);\n } else {\n //find a Material in our list that matches\n tempOre = plugin.ores.stream().filter((ore) -> brokenBlock.name().contains(ore.getName())).findFirst().orElse(null);\n }\n\n\n if (tempOre == null) {\n //ore was not in our list.\n //stop method\n\n //debug\n if (plugin.config.debug) {\n plugin.console.log(debugMSG\n + \" Block was not Registered in config. No Drops Allowed. \"\n );\n }\n\n return;\n }\n\n //find out if we hit the right chance and go from there\n int chance = plugin.rnd.nextInt(100);//get a percentage\n\n //debug\n if (plugin.config.debug) {\n plugin.console.log(debugMSG\n + \" Chance Needed: \" + tempOre.getChance()\n + \" Chance Received: \" + chance + \" \"\n + blockLocation\n );\n }\n\n if (chance <= tempOre.getChance()) {\n //success on the chance\\\n\n //debug\n if (plugin.config.debug) {\n plugin.console.log(debugMSG\n + \" Drops Allowed. \"\n + blockLocation\n );\n }\n\n Collection<ItemStack> droppedItems = event.getBlock().getDrops();//get what ever was dropped\n int initialDrop = 0;//variable to hold how many items were dropped to begin with\n //drop an extra item per drop\n for (ItemStack i : droppedItems) {\n initialDrop = i.getAmount();\n i.setAmount(i.getAmount()*tempOre.getMultiplier() - 1);//set amount to drop\n\n //debug\n if (plugin.config.debug) {\n plugin.console.log(debugMSG\n + \" Drop: \" + i.getType().name()\n + \" Amount: \" + initialDrop\n + \" Multiplier: \" + tempOre.getMultiplier()\n + \" Extra Given: \" + (i.getAmount())\n + blockLocation\n );\n }\n\n event.getBlock().getWorld().dropItemNaturally(\n event.getBlock().getLocation(), i\n );\n }\n\n //find out if we need to give experience\n if (tempOre.isExp()) {\n\n //debug\n if (plugin.config.debug) {\n plugin.console.log(debugMSG\n + \" Drop includes XP\"\n + \" Amount: \" + event.getExpToDrop()\n + \" Multiplier: \" + tempOre.getMultiplier()\n + \" Total Given: \" + (event.getExpToDrop() * tempOre.getMultiplier())\n + blockLocation\n );\n }\n\n event.setExpToDrop(event.getExpToDrop() * tempOre.getMultiplier());\n }\n\n\n }\n\n\n }", "public void dropBlockAsItemWithChance(World worldIn, BlockPos pos, IBlockState state, float chance, int fortune) {\n/* 78 */ if (!worldIn.isRemote && worldIn.getGameRules().getGameRuleBooleanValue(\"doTileDrops\")) {\n/* */ \n/* 80 */ EntitySilverfish var6 = new EntitySilverfish(worldIn);\n/* 81 */ var6.setLocationAndAngles(pos.getX() + 0.5D, pos.getY(), pos.getZ() + 0.5D, 0.0F, 0.0F);\n/* 82 */ worldIn.spawnEntityInWorld((Entity)var6);\n/* 83 */ var6.spawnExplosionParticle();\n/* */ } \n/* */ }", "@ForgeSubscribe(priority = EventPriority.HIGHEST)\n public void onPlayerDrops(PlayerDropsEvent event) {\n if (_PlayerHeads.debug);\n else if (_PlayerHeads.pvp && !event.recentlyHit || _PlayerHeads.dropRates[3] <= 0.0 || _PlayerHeads.random.nextDouble() - 0.005 * (double)event.lootingLevel >= _PlayerHeads.dropRates[3])\n return;\n ItemStack head = new ItemStack(Item.skull, 1, 3);\n head.setTagInfo(\"SkullOwner\", new NBTTagString(\"\", event.entityPlayer.username));\n EntityItem drop = new EntityItem(event.entityPlayer.worldObj, event.entityPlayer.posX, event.entityPlayer.posY, event.entityPlayer.posZ, head);\n drop.delayBeforeCanPickup = 10;\n event.drops.add(drop);\n }", "protected void dropFewItems(boolean par1, int par2) {\r\n\t\tint var3 = this.rand.nextInt(3) + this.rand.nextInt(1 + par2);\r\n\t\t\r\n\t\tfor(int var4 = 0; var4 < var3; ++var4) {\r\n\t\t\tthis.dropItem(SorceryItems.goldfeather, 1);\r\n\t\t}\r\n\t\t\r\n\t\tif(this.isBurning()) {\r\n\t\t\tthis.dropItem(Items.cooked_chicken, 1);\r\n\t\t} else {\r\n\t\t\tthis.dropItem(Items.chicken, 1);\r\n\t\t}\r\n\t}", "@EventHandler\n void OnEntityDeath(EntityDeathEvent e){\n Entity killer = e.getEntity().getKiller();\n int exp = e.getDroppedExp();\n if(killer instanceof Player){\n GuildMCFunctions functions = new GuildMCFunctions();\n functions.spawnExperiencesInfos((Player) killer, exp);\n }\n\n }", "public void drop() {\n\t\t// Has player waited cooldown before trying to fire again?\n\t\tif (System.currentTimeMillis() - this.lastFired > Config.WEAPON_COOLDOWN_TIME * 1000) {\n\t\t\t\n\t\t\t// Can this airship drop bombs?\n\t\t\tif (this.properties.DROPS_BOMB) {\n\t\t\t\tBlock[] cannons = getCannons();\n\t\t\t\tint numfiredcannons = 0;\n\t\t\t\tfor (int i = 0; i < cannons.length; i++) {\n\t\t\t\t\tif (cannons[i] != null && cannons[i].getRelative(0, -1, 0).getType().equals(Material.AIR) && cannonHasTnt(cannons[i], Config.NUM_TNT_TO_DROP_BOMB)) {\n\t\t\t\t\t\tif (numfiredcannons < this.properties.MAX_NUMBER_OF_CANNONS ) {\n\t\t\t\t\t\t\tnumfiredcannons++;\n\t\t\t\t\t\t\tlastFired = System.currentTimeMillis();\n\t\t\t\t\t\t\twithdrawTnt(cannons[i], Config.NUM_TNT_TO_DROP_BOMB);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Spawn primed tnt firing downwards TODO: maybe add sound effects for tnt firing? :P\n\t\t\t\t\t\t\tTNTPrimed tnt = cannons[i].getWorld().spawn(cannons[i].getLocation().clone().add(0, -1, 0), TNTPrimed.class);\n\t\t\t\t\t\t\ttnt.setVelocity(new Vector(0, -0.5, 0));\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// More cannons on ship than allowed. Not all fired - can break out of loop now.\n\t\t\t\t\t\t\tplayer.sendMessage(ChatColor.AQUA + \"Some cannons did not fire. Max cannon limit is \" + ChatColor.GOLD + this.properties.MAX_NUMBER_OF_CANNONS);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else\n\t\t\t\tplayer.sendMessage(ChatColor.GOLD + this.properties.SHIP_TYPE + \" CANNOT DROP BOMBS\");\n\t\t} else\n\t\t\tplayer.sendMessage(ChatColor.GOLD + \"COOLING DOWN FOR \" + ChatColor.AQUA + (int)(Math.round(6 - (System.currentTimeMillis() - this.lastFired) / 1000)) + ChatColor.GOLD + \" MORE SECONDS\");\n\t}", "@SuppressWarnings(\"deprecated\")\n protected void durability(Player p, PlayerInteractEvent event) {\n this.p = p;\n\n Block block = event.getClickedBlock();\n Action action = event.getAction();\n Material blockType = block.getType();\n Location blockLocation = block.getLocation();\n ItemStack heldItem = p.getInventory().getItemInMainHand();\n Material heldItemType = heldItem.getType();\n\n //left click = spade,hoe\n //right click = axe,pick axe,sword,spade,hoe,sword\n canRun = isCanCheckDurability(action, heldItemType);\n\n if (canRun && Helper.isBlockForOutput(blockType)) {\n //Only for blocks\n //TODO get type id nicer than with deprecated method\n final String blockLocationFormat = String.format(\"%d;%d;%d;%d\",\n block.getTypeId(),\n blockLocation.getBlockX(),\n blockLocation.getBlockY(),\n blockLocation.getBlockZ());\n\n if (checkDurability(heldItem, blockLocationFormat)) {\n xyzBlock.add(blockLocationFormat);\n //Remove later on, so it can be added again\n new BukkitRunnable() {\n\n @Override\n public void run() {\n if (xyzBlock.contains(blockLocationFormat)) xyzBlock.remove(blockLocationFormat);\n }\n\n }.runTaskLater(this.plugin, 1220); //1220 = 1 minute (in-game) //TODO make configurable?\n }\n }\n }", "public void dropBlockAsItemWithChance(World p_149690_1_, int p_149690_2_, int p_149690_3_, int p_149690_4_, int p_149690_5_, float p_149690_6_, int p_149690_7_) {}", "@Override\n protected void dropFewItems(boolean hit, int looting) {\n super.dropFewItems(hit, looting);\n for (int i = this.rand.nextInt(2 + looting); i-- > 0;) {\n this.dropItem(Items.ender_pearl, 1);\n }\n }", "@Override\r\n\tprotected boolean canDropLoot() {\r\n\t\treturn false;\r\n\t}", "@SuppressWarnings(\"deprecated\")\n protected void durability(Player p, EntityDamageEvent event) {\n this.p = p;\n ItemStack heldItem = p.getInventory().getItemInMainHand();\n //No need to check here, its always ok\n canRun = true;\n //TODO ignore when hitting the same target multiple times (but how, xyz changes all the time?)\n //TODO sometimes(?) it shows 15 durability, when in fact its 14 (maybe bc of multiple mob hits?)\n if (canRun) {\n checkDurability(heldItem, \"\");\n }\n }", "@EventHandler\r\n public void mobDmgLstn(EntityDamageByEntityEvent event) {\r\n if(plugin.getConfig().getBoolean(\"enablePhaseModifiers\")) {\r\n if (plugin.isNight()) {\r\n if (event.getDamager() instanceof Monster) {\r\n event.setDamage(event.getDamage() * main.DmgMult);\r\n } else if (event.getEntity() instanceof Monster) {\r\n event.setDamage(event.getDamage() / main.DmgMult);\r\n }\r\n }\r\n }\r\n }", "@Override\r\n\t@SuppressWarnings(\"deprecation\")\r\n\tpublic void raiseEvent(Event e) {\r\n\t\tPlayer p = ((PlayerInteractEvent) e).getPlayer();\r\n\t\tPlayerStats stats = plugin.getStats(p);\r\n\t\tif (stats.subtractmoney(cost)) {\r\n\t\t\tif (!items.isEmpty()) {\r\n\t\t\t\tLinkedList<ItemStack> givenItems = new LinkedList<ItemStack>();\r\n\t\t\t\tfor (ItemStack item : items.getItemStacks()) {\r\n\t\t\t\t\tgivenItems.add(item);\r\n\t\t\t\t\tHashMap<Integer, ItemStack> failed = p.getInventory().addItem(item);\r\n\r\n\t\t\t\t\tif (failed != null && failed.size() > 0) {\r\n\t\t\t\t\t\t// the inventory may be full\r\n\t\t\t\t\t\tTribu.messagePlayer(p, (plugin.getLocale(\"Message.UnableToGiveYouThatItem\")),ChatColor.RED);\r\n\t\t\t\t\t\tstats.addMoney(cost);\r\n\t\t\t\t\t\tfor (ItemStack i : givenItems)\r\n\t\t\t\t\t\t\tp.getInventory().remove(i);\r\n\t\t\t\t\t\tgivenItems = null;\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tp.updateInventory();\r\n\t\t\t\t// Alright\r\n\t\t\t\tTribu.messagePlayer(p,String.format(plugin.getLocale(\"Message.PurchaseSuccessfulMoney\"), String.valueOf(stats.getMoney())),ChatColor.GREEN);\r\n\t\t\t} else {\r\n\t\t\t\tTribu.messagePlayer(p,plugin.getLocale(\"Message.UnknownItem\"),ChatColor.RED);\r\n\t\t\t\tstats.addMoney(cost);\r\n\t\t\t}\r\n\r\n\t\t} else {\r\n\t\t\tTribu.messagePlayer(p,plugin.getLocale(\"Message.YouDontHaveEnoughMoney\"),ChatColor.RED);\r\n\t\t}\r\n\r\n\t}", "private void dropAllDrops(ItemStack drop, int amount, Location dropLocation, boolean addEnchantment){\n double inStacks = (double) amount / (double) drop.getMaxStackSize();\n double floor = Math.floor(inStacks);\n double leftOver = inStacks - floor;\n for(int i = 1; i <= floor; i++){\n ItemStack newStack = drop.clone();\n newStack.setAmount(drop.getMaxStackSize());\n if(addEnchantment){\n newStack.addUnsafeEnchantment(Enchantment.DIG_SPEED, 1);\n }\n dropLocation.getWorld().dropItemNaturally(dropLocation, newStack);\n }\n if(leftOver > 0){\n ItemStack newStack = drop.clone();\n newStack.setAmount((int) Math.round(leftOver * drop.getMaxStackSize()));\n if(addEnchantment){\n newStack.addUnsafeEnchantment(Enchantment.DIG_SPEED, 1);\n }\n dropLocation.getWorld().dropItemNaturally(dropLocation, newStack);\n }\n }", "public void drop(String itemName, World world) {\n\t\tItem item = world.dbItems().get(itemName);\n\n\t\tList<Item> items = super.getItems();\n\t\tRoom room = super.getRoom();\n\t\tList<Item> roomItems = room.getItems();\n\n\t\tif (items.contains(item)) {\n\t\t\troom.addItem(item);\n\t\t\tsuper.removeItem(item);\n\t\t\tSystem.out.println(\"Dropped \" + item + \" on the floor.\");\n\t\t} else {\n\t\t\tSystem.out.println(\"No \" + item + \" in inventory.\");\n\t\t}\n\t}", "@ZenCodeType.Method\n @ZenCodeType.Getter(\"drops\")\n public static List<ItemStack> getDrops(ItemFishedEvent internal) {\n \n return internal.getDrops();\n }", "@Override\n public void execute(final Player pPlayer)\n {\n if( ! hasSecondWord())\n {\n GameEngine.aGui.println(\"What Item do tou want to drop ?\");\n }\n else\n {\n String vC = getSecondWord();\n Item vItemInv = pPlayer.getInventaire().get(vC);\n\n if( vItemInv == null)\n {\n GameEngine.aGui.println(\"You don't have this Item in you're possession\");\n }\n else\n {\n pPlayer.removeInventaire(vC);\n pPlayer.getCurrentRoom().getItems().put(vItemInv);\n GameEngine.aGui.println(\"You droped this \" + vItemInv.getName());\n }\n }\n }", "@Override\n public void dropBlockAsItemWithChance(@Nonnull World worldIn, @Nonnull BlockPos pos, @Nonnull IBlockState state, float chance, int fortune)\n {\n }", "public ArrayList<Item> drop()\n {\n ArrayList<Item> drop = new ArrayList<>();\n for( Pair<Enums.ItemName, Integer> possibleDrop : dropTable)\n {\n if(ThreadLocalRandom.current().nextInt(100) < possibleDrop.getY())\n drop.add(new Item(possibleDrop.getX()));\n }\n return drop;\n }", "@Override\n\tprotected void dropFewItems(boolean par1, int par2) {\n\t\tsuper.dropFewItems(par1, par2);\n\n\t\t// drop saddle if equipped\n\t\tif (isSaddled()) {\n\t\t\tdropItem(Items.SADDLE, 1);\n\t\t}\n\t}", "private static void customItems(ItemDefinition itemDef) {\n\n\t\tswitch (itemDef.id) {\n\n\t\tcase 11864:\n\t\tcase 11865:\n\t\tcase 19639:\n\t\tcase 19641:\n\t\tcase 19643:\n\t\tcase 19645:\n\t\tcase 19647:\n\t\tcase 19649:\n\t\tcase 23073:\n\t\tcase 23075:\n\t\t\titemDef.equipActions[2] = \"Log\";\n\t\t\titemDef.equipActions[1] = \"Check\";\n\t\t\tbreak;\n\n\t\tcase 13136:\n\t\t\titemDef.equipActions[2] = \"Elidinis\";\n\t\t\titemDef.equipActions[1] = \"Kalphite Hive\";\n\t\t\tbreak;\n\t\tcase 2550:\n\t\t\titemDef.equipActions[2] = \"Check\";\n\t\t\tbreak;\n\n\t\tcase 1712:\n\t\tcase 1710:\n\t\tcase 1708:\n\t\tcase 1706:\n\t\t\titemDef.equipActions[1] = \"Edgeville\";\n\t\t\titemDef.equipActions[2] = \"Karamja\";\n\t\t\titemDef.equipActions[3] = \"Draynor\";\n\t\t\titemDef.equipActions[4] = \"Al-Kharid\";\n\t\t\tbreak;\n\n\t\tcase 22000:\n\t\t\titemDef.name = \"Lava partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"A lava partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 22001:\n\t\t\titemDef.name = \"Infernal partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"An Infernal partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 2552:\n\t\tcase 2554:\n\t\tcase 2556:\n\t\tcase 2558:\n\t\tcase 2560:\n\t\tcase 2562:\n\t\tcase 2564:\n\t\tcase 2566: // Ring of duelling\n\t\t\titemDef.equipActions[2] = \"Shantay Pass\";\n\t\t\titemDef.equipActions[1] = \"Clan wars\";\n\t\t\tbreak;\n\n\t\tcase 21307:\n\t\t\titemDef.name = \"Pursuit crate\";\n\t\t\tbreak;\n\n\t\tcase 12792:\n\t\t\titemDef.name = \"Graceful recolor kit\";\n\t\t\tbreak;\n\n\t\tcase 12022:\n\t\t\titemDef.name = \"Bandos Casket\";\n\t\t\titemDef.description = \"100% chance for an item off the Bandos gwds rare drop table.\";\n\t\t\tbreak;\n\n\t\tcase 12024:\n\t\t\titemDef.name = \"Armadyl Casket\";\n\t\t\titemDef.description = \"100% chance for an item off the Armadyl gwds rare drop table.\";\n\t\t\tbreak;\n\n\t\tcase 12026:\n\t\t\titemDef.name = \"Saradomin Casket\";\n\t\t\titemDef.description = \"100% chance for an item off the Saradomin gwds rare drop table.\";\n\t\t\tbreak;\n\n\t\tcase 12028:\n\t\t\titemDef.name = \"Zamorak Casket\";\n\t\t\titemDef.description = \"100% chance for an item off the Zamorak gwds rare drop table.\";\n\t\t\tbreak;\n\n\t\tcase 964:\n\t\t\titemDef.name = \"Pet Petie\";\n\t\t\tbreak;\n\n\t\tcase 20853:\n\t\t\titemDef.name = \"Deep Sea Bait\";\n\t\t\titemDef.stackable = true;\n\t\t\tbreak;\n\n\t\t/*\n\t\t * case 17014: itemDef.name = \"Dragon flail\"; itemDef.modelId = 50083;\n\t\t * itemDef.modelZoom = 1440; itemDef.modelRotation2 = 272;\n\t\t * itemDef.modelRotation1 = 352; itemDef.modelOffset1 = 32;\n\t\t * //itemDef.modelOffset2 = 0; itemDef.maleModel = 50083; itemDef.femaleModel =\n\t\t * 50083; itemDef.anInt164 = -1; itemDef.anInt188 = -1; itemDef.aByte205 = -8;\n\t\t * itemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t * itemDef.inventoryOptions = new String[] { \"Wear\", null, null, null, \"Drop\" };\n\t\t * itemDef.description = \"An Ancient Dragon Flail.\"; break;\n\t\t */\n\n\t\tcase 33272:\n\t\t\titemDef.name = \"Justiciar's Longsword\";\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modelId = 65472;\n\t\t\titemDef.modelZoom = 1726;\n\t\t\titemDef.modelRotation1 = 1576;\n\t\t\titemDef.modelRotation2 = 242;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\t// itemDef.anInt204 = 0;\n\t\t\t// itemDef.aByte205 = -12;\n\t\t\t// itemDef.aByte154 = 0;\n\t\t\titemDef.maleModel = 65465;\n\t\t\titemDef.femaleModel = 65465;\n\t\t\titemDef.description = \"An ancient longsword received from the Trial of Flames.\";\n\t\t\tbreak;\n\n\t\tcase 33168:\n\t\t\titemDef.name = \"Justiciar kiteshield\";\n\t\t\titemDef.modelId = 65471;\n\t\t\titemDef.modelZoom = 1600;\n\t\t\titemDef.modelRotation2 = 250;\n\t\t\titemDef.modelRotation1 = 300;\n\t\t\titemDef.modelOffset1 = -4;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.maleModel = 65473;\n\t\t\titemDef.femaleModel = 65474;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"An ancient kiteshield. Part of the Justiciar set.\";\n\t\t\tbreak;\n\n\t\tcase 2996:\n\t\t\titemDef.name = \"PKP Ticket\";\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.description = \"Exchange this for a PK Point.\";\n\t\t\tbreak;\n\t\tcase 13226:\n\t\t\titemDef.name = \"Herb Sack\";\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.description = \"A sack for storing grimy herbs.\";\n\t\t\tbreak;\n\t\tcase 13346:\n\t\t\titemDef.name = \"Raid Mystery Box\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Open for chances to receive Raid items & other awesome rewards.\";\n\t\t\tbreak;\n\t\tcase 8800:\n\t\t\titemDef.name = \"Donator Tokens\";\n\t\t\titemDef.modelId = 31624;\n\t\t\t// itemDef.stackAmounts = new int[] { 2, 3, 50, 100, 500000, 1000000, 2500000,\n\t\t\t// 10000000, 100000000, 0 };//amount the model will change at\n\t\t\t// itemDef.stackIDs = new int[] { 8801, 8802, 8803, 8804, 8805, 8806, 8807,\n\t\t\t// 8808, 8809, 0 };//new item id to grab the model from\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 853;\n\t\t\titemDef.modelRotation2 = 1885;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8801:\n\t\t\titemDef.name = \"Donator Tokens\";\n\t\t\titemDef.modelId = 15344;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8802:\n\t\t\titemDef.name = \"Donator Tokens\";\n\t\t\titemDef.modelId = 15345;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8803:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15346;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8804:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15347;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8805:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15348;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8806:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15349;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8807:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15350;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8808:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15351;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 8809:\n\t\t\titemDef.name = \"Donator Coins\";\n\t\t\titemDef.modelId = 15352;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modifiedModelColors = new int[] { 5813, 9139 };\n\t\t\titemDef.originalModelColors = new int[] { 22450, 22450 };\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation2 = 1764;\n\t\t\titemDef.modelRotation1 = 202;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Tokens for the Donator Store.\";\n\t\t\tbreak;\n\t\tcase 15098:\n\t\t\titemDef.name = \"Dice (up to 100)\";\n\t\t\titemDef.description = \"A 100-sided dice.\";\n\t\t\titemDef.modelId = 31223;\n\t\t\titemDef.modelZoom = 1104;\n\t\t\titemDef.modelRotation2 = 215;\n\t\t\titemDef.modelRotation1 = 94;\n\t\t\titemDef.modelOffset2 = -5;\n\t\t\titemDef.modelOffset1 = -18;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Public-roll\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.name = \"Dice (up to 100)\";\n\t\t\titemDef.anInt196 = 15;\n\t\t\titemDef.anInt184 = 25;\n\t\t\tbreak;\n\n\t\tcase 32991:\n\t\t\titemDef.name = \"Divine spirit shield\";\n\t\t\titemDef.description = \"An ethereal shield with an divine sigil attached to it.\";\n\t\t\titemDef.modelId = 50001;\n\t\t\titemDef.maleModel = 50002;\n\t\t\titemDef.femaleModel = 50002;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelRotation2 = 1050;\n\t\t\titemDef.modelRotation1 = 396;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\tbreak;\n\t\tcase 32992:\n\t\t\titemDef.name = \"Rainbow spirit shield\";\n\t\t\titemDef.description = \"An ethereal shield with all 4 sigils attached to it.\";\n\t\t\titemDef.modelId = 50004;\n\t\t\titemDef.maleModel = 50005;\n\t\t\titemDef.femaleModel = 50005;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelRotation2 = 1050;\n\t\t\titemDef.modelRotation1 = 396;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 32993:\n\t\t\titemDef.name = \"Divine sigil\";\n\t\t\titemDef.description = \"A sigil in the shape of a divine symbol.\";\n\t\t\titemDef.modelId = 50003;\n\t\t\titemDef.modelZoom = 848;\n\t\t\titemDef.modelRotation1 = 267;\n\t\t\titemDef.modelRotation2 = 138;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33060:\n\t\t\titemDef.name = \"Barrows Sword\";\n\t\t\titemDef.description = \"A sword glowing with otherworldy energy.\";\n\t\t\titemDef.modelId = 22325;\n\t\t\titemDef.maleModel = 50010;\n\t\t\titemDef.femaleModel = 50010;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelRotation2 = 1050;\n\t\t\titemDef.modelRotation1 = 396;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\tbreak;\n\t\tcase 32994:\n\t\t\titemDef.name = \"Statius's platebody\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42602;\n\t\t\titemDef.maleModel = 35951;\n\t\t\titemDef.femaleModel = 35964;\n\t\t\titemDef.modelZoom = 1312;\n\t\t\titemDef.modelRotation1 = 272;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -2;\n\t\t\titemDef.modelOffset2 = 39;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 32995:\n\t\t\titemDef.name = \"Statius's platelegs\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42590;\n\t\t\titemDef.maleModel = 35947;\n\t\t\titemDef.femaleModel = 35961;\n\t\t\titemDef.modelZoom = 1625;\n\t\t\titemDef.modelRotation1 = 355;\n\t\t\titemDef.modelRotation2 = 2046;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -11;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 32996:\n\t\t\titemDef.name = \"Statius's full helm\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42596;\n\t\t\titemDef.maleModel = 35943;\n\t\t\titemDef.femaleModel = 35958;\n\t\t\titemDef.modelZoom = 789;\n\t\t\titemDef.modelRotation1 = 96;\n\t\t\titemDef.modelRotation2 = 2039;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -7;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 32997:\n\t\t\titemDef.name = \"Statius's warhammer\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42577;\n\t\t\titemDef.maleModel = 35968;\n\t\t\titemDef.femaleModel = 35968;\n\t\t\titemDef.modelZoom = 1360;\n\t\t\titemDef.modelRotation1 = 507;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 7;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 32998:\n\t\t\titemDef.name = \"Vesta's chainbody\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42593;\n\t\t\titemDef.maleModel = 35953;\n\t\t\titemDef.femaleModel = 35965;\n\t\t\titemDef.modelZoom = 1440;\n\t\t\titemDef.modelRotation1 = 545;\n\t\t\titemDef.modelRotation2 = 2;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 32999:\n\t\t\titemDef.name = \"Vesta's plateskirt\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42581;\n\t\t\titemDef.maleModel = 35950;\n\t\t\titemDef.femaleModel = 35960;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = 11;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33000:\n\t\t\titemDef.name = \"Vesta's longsword\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42597;\n\t\t\titemDef.maleModel = 35969;\n\t\t\titemDef.femaleModel = 35969;\n\t\t\titemDef.modelZoom = 1744;\n\t\t\titemDef.modelRotation1 = 738;\n\t\t\titemDef.modelRotation2 = 1985;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.maleOffset = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33001:\n\t\t\titemDef.name = \"Vesta's spear\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42599;\n\t\t\titemDef.maleModel = 35973;\n\t\t\titemDef.femaleModel = 35973;\n\t\t\titemDef.modelZoom = 2022;\n\t\t\titemDef.modelRotation1 = 480;\n\t\t\titemDef.modelRotation2 = 15;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.maleOffset = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33002:\n\t\t\titemDef.name = \"Morrigan's leather body\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42578;\n\t\t\titemDef.maleModel = 35954;\n\t\t\titemDef.femaleModel = 35963;\n\t\t\titemDef.modelZoom = 1440;\n\t\t\titemDef.modelRotation1 = 545;\n\t\t\titemDef.modelRotation2 = 2;\n\t\t\titemDef.modelOffset1 = -2;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33003:\n\t\t\titemDef.name = \"Morrigan's leather chaps\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42603;\n\t\t\titemDef.maleModel = 35948;\n\t\t\titemDef.femaleModel = 35959;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 482;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = 11;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33004:\n\t\t\titemDef.name = \"Morrigan's coif\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42583;\n\t\t\titemDef.maleModel = 35945;\n\t\t\titemDef.femaleModel = 35956;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 537;\n\t\t\titemDef.modelRotation2 = 5;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33005:\n\t\t\titemDef.name = \"Morrigan's javelin\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42592;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.maleModel = 42613;\n\t\t\titemDef.femaleModel = 42613;\n\t\t\titemDef.modelZoom = 1872;\n\t\t\titemDef.modelRotation1 = 282;\n\t\t\titemDef.modelRotation2 = 2009;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.maleOffset = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33006:\n\t\t\titemDef.name = \"Morrigan's throwing axe\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42582;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.maleModel = 42611;\n\t\t\titemDef.femaleModel = 42611;\n\t\t\titemDef.modelZoom = 976;\n\t\t\titemDef.modelRotation1 = 672;\n\t\t\titemDef.modelRotation2 = 2024;\n\t\t\titemDef.modelOffset1 = -5;\n\t\t\titemDef.maleOffset = -8;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33007:\n\t\t\titemDef.name = \"Zuriels robe top\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42591;\n\t\t\titemDef.maleModel = 35952;\n\t\t\titemDef.femaleModel = 35966;\n\t\t\titemDef.modelZoom = 1373;\n\t\t\titemDef.modelRotation1 = 373;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -7;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33008:\n\t\t\titemDef.name = \"Zuriels robe bottom\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42588;\n\t\t\titemDef.maleModel = 35949;\n\t\t\titemDef.femaleModel = 35962;\n\t\t\titemDef.modelZoom = 1697;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33009:\n\t\t\titemDef.name = \"Zuriels hood\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42604;\n\t\t\titemDef.maleModel = 35944;\n\t\t\titemDef.femaleModel = 35957;\n\t\t\titemDef.modelZoom = 720;\n\t\t\titemDef.modelRotation1 = 28;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33010:\n\t\t\titemDef.name = \"Zuriels staff\";\n\t\t\titemDef.description = \"This item degrades in combat, and will turn to dust.\";\n\t\t\titemDef.modelId = 42595;\n\t\t\titemDef.maleModel = 35971;\n\t\t\titemDef.femaleModel = 35971;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 366;\n\t\t\titemDef.modelRotation2 = 3;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33011:\n\t\t\titemDef.name = \"Craw's bow (u)\";\n\t\t\titemDef.description = \"This bow once belonged to a formidable follower of Armadyl.\";\n\t\t\titemDef.modelId = 35777;\n\t\t\titemDef.maleModel = 35768;\n\t\t\titemDef.femaleModel = 35768;\n\t\t\titemDef.modelZoom = 1979;\n\t\t\titemDef.modelRotation1 = 1463;\n\t\t\titemDef.modelRotation2 = 510;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33012:\n\t\t\titemDef.name = \"Craw's bow\";\n\t\t\titemDef.description = \"This bow once belonged to a formidable follower of Armadyl.\";\n\t\t\titemDef.modelId = 35777;\n\t\t\titemDef.maleModel = 35769;\n\t\t\titemDef.femaleModel = 35769;\n\t\t\titemDef.modelZoom = 1979;\n\t\t\titemDef.modelRotation1 = 1463;\n\t\t\titemDef.modelRotation2 = 510;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33013:\n\t\t\titemDef.name = \"Thammaron's sceptre (u)\";\n\t\t\titemDef.description = \"A mighty sceptre used in long forgotten battles.\";\n\t\t\titemDef.modelId = 35776;\n\t\t\titemDef.maleModel = 35772;\n\t\t\titemDef.femaleModel = 35772;\n\t\t\titemDef.modelZoom = 2105;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 1020;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33014:\n\t\t\titemDef.name = \"Thammaron's sceptre\";\n\t\t\titemDef.description = \"A mighty sceptre used in long forgotten battles.\";\n\t\t\titemDef.modelId = 35776;\n\t\t\titemDef.maleModel = 35773;\n\t\t\titemDef.femaleModel = 35773;\n\t\t\titemDef.modelZoom = 2105;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 1020;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33015:\n\t\t\titemDef.name = \"Viggora's chainmace (u)\";\n\t\t\titemDef.description = \"An ancient chainmace with a peculiar mechanism that allows for varying attack styles.\";\n\t\t\titemDef.modelId = 35778;\n\t\t\titemDef.maleModel = 35770;\n\t\t\titemDef.femaleModel = 35770;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelRotation1 = 252;\n\t\t\titemDef.modelRotation2 = 944;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33016:\n\t\t\titemDef.name = \"Viggora's chainmace\";\n\t\t\titemDef.description = \"An ancient chainmace with a peculiar mechanism that allows for varying attack styles.\";\n\t\t\titemDef.modelId = 35778;\n\t\t\titemDef.maleModel = 35771;\n\t\t\titemDef.femaleModel = 35771;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelRotation1 = 252;\n\t\t\titemDef.modelRotation2 = 944;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33018:\n\t\t\titemDef.name = \"Amulet of avarice\";\n\t\t\titemDef.description = \"A hauntingly beautiful amulet bearing the shape of a skull.\";\n\t\t\titemDef.modelId = 35779;\n\t\t\titemDef.maleModel = 35766;\n\t\t\titemDef.femaleModel = 35766;\n\t\t\titemDef.modelZoom = 420;\n\t\t\titemDef.modelRotation1 = 191;\n\t\t\titemDef.modelRotation2 = 86;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33019:\n\t\t\titemDef.name = \"Completionist cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modelId = 65270;\n\t\t\titemDef.maleModel = 65297;\n\t\t\titemDef.femaleModel = 65316;\n\t\t\titemDef.modelZoom = 1316;\n\t\t\titemDef.modelRotation1 = 252;\n\t\t\titemDef.modelRotation2 = 1020;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 24;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33020:\n\t\t\titemDef.name = \"Completionist cape (t)\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modelId = 65258;\n\t\t\titemDef.maleModel = 65295;\n\t\t\titemDef.femaleModel = 65328;\n\t\t\titemDef.modelZoom = 1316;\n\t\t\titemDef.modelRotation1 = 252;\n\t\t\titemDef.modelRotation2 = 1020;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 24;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33021:\n\t\t\titemDef.name = \"Torva full helm\";\n\t\t\titemDef.description = \"An ancient warrior's full helm.\";\n\t\t\titemDef.modelId = 62714;\n\t\t\titemDef.maleModel = 62738;\n\t\t\titemDef.femaleModel = 62738;\n\t\t\titemDef.modelZoom = 672;\n\t\t\titemDef.modelRotation1 = 85;\n\t\t\titemDef.modelRotation2 = 1867;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33022:\n\t\t\titemDef.name = \"Torva platebody\";\n\t\t\titemDef.description = \"An ancient warrior's platebody.\";\n\t\t\titemDef.modelId = 62699;\n\t\t\titemDef.maleModel = 62746;\n\t\t\titemDef.femaleModel = 62746;\n\t\t\titemDef.modelZoom = 1506;\n\t\t\titemDef.modelRotation1 = 473;\n\t\t\titemDef.modelRotation2 = 2042;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33023:\n\t\t\titemDef.name = \"Torva platelegs\";\n\t\t\titemDef.description = \"An ancient warrior's platelegs.\";\n\t\t\titemDef.modelId = 62701;\n\t\t\titemDef.maleModel = 62740;\n\t\t\titemDef.femaleModel = 62740;\n\t\t\titemDef.modelZoom = 1740;\n\t\t\titemDef.modelRotation1 = 474;\n\t\t\titemDef.modelRotation2 = 2045;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33024:\n\t\t\titemDef.name = \"Pernix cowl\";\n\t\t\titemDef.description = \"An ancient warrior's cowl.\";\n\t\t\titemDef.modelId = 62693;\n\t\t\titemDef.maleModel = 62739;\n\t\t\titemDef.femaleModel = 62739;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 532;\n\t\t\titemDef.modelRotation2 = 14;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33025:\n\t\t\titemDef.name = \"Pernix body\";\n\t\t\titemDef.description = \"An ancient warrior's leather body.\";\n\t\t\titemDef.modelId = 62709;\n\t\t\titemDef.maleModel = 62744;\n\t\t\titemDef.femaleModel = 62744;\n\t\t\titemDef.modelZoom = 1378;\n\t\t\titemDef.modelRotation1 = 485;\n\t\t\titemDef.modelRotation2 = 2042;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 7;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33026:\n\t\t\titemDef.name = \"Pernix chaps\";\n\t\t\titemDef.description = \"An ancient warrior's chaps.\";\n\t\t\titemDef.modelId = 62695;\n\t\t\titemDef.maleModel = 62741;\n\t\t\titemDef.femaleModel = 62741;\n\t\t\titemDef.modelZoom = 1740;\n\t\t\titemDef.modelRotation1 = 504;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33027:\n\t\t\titemDef.name = \"Virtus mask\";\n\t\t\titemDef.description = \"An ancient warrior's mask.\";\n\t\t\titemDef.modelId = 62710;\n\t\t\titemDef.maleModel = 62736;\n\t\t\titemDef.femaleModel = 62736;\n\t\t\titemDef.modelZoom = 928;\n\t\t\titemDef.modelRotation1 = 406;\n\t\t\titemDef.modelRotation2 = 2041;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33028:\n\t\t\titemDef.name = \"Virtus robe top\";\n\t\t\titemDef.description = \"An ancient warrior's robe top.\";\n\t\t\titemDef.modelId = 62704;\n\t\t\titemDef.maleModel = 62748;\n\t\t\titemDef.femaleModel = 62748;\n\t\t\titemDef.modelZoom = 1122;\n\t\t\titemDef.modelRotation1 = 488;\n\t\t\titemDef.modelRotation2 = 3;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33029:\n\t\t\titemDef.name = \"Virtus robe legs\";\n\t\t\titemDef.description = \"An ancient warrior's robe legs.\";\n\t\t\titemDef.modelId = 62700;\n\t\t\titemDef.maleModel = 62742;\n\t\t\titemDef.femaleModel = 62742;\n\t\t\titemDef.modelZoom = 1740;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 2045;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33030:\n\t\t\titemDef.name = \"Zaryte bow\";\n\t\t\titemDef.description = \"An ancient warrior's bow.\";\n\t\t\titemDef.modelId = 62692;\n\t\t\titemDef.maleModel = 62750;\n\t\t\titemDef.femaleModel = 62750;\n\t\t\titemDef.modelZoom = 1703;\n\t\t\titemDef.modelRotation1 = 221;\n\t\t\titemDef.modelRotation2 = 404;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -13;\n\t\t\titemDef.maleOffset = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33083:\n\t\t\titemDef.name = \"Tokhaar-kal\";\n\t\t\titemDef.description = \"\tA cape made of ancient, enchanted obsidian.\";\n\t\t\titemDef.modelId = 52073;\n\t\t\titemDef.maleModel = 52072;\n\t\t\titemDef.femaleModel = 52071;\n\t\t\titemDef.modelZoom = 1615;\n\t\t\titemDef.modelRotation1 = 339;\n\t\t\titemDef.modelRotation2 = 192;\n\t\t\titemDef.modelOffset1 = -4;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33089:\n\t\t\titemDef.name = \"Chaotic maul\";\n\t\t\titemDef.description = \"A maul used to claim life from those who don't deserve it.\";\n\t\t\titemDef.modelId = 54286;\n\t\t\titemDef.maleModel = 56294;\n\t\t\titemDef.femaleModel = 56294;\n\t\t\titemDef.modelZoom = 1447;\n\t\t\titemDef.modelRotation1 = 525;\n\t\t\titemDef.modelRotation2 = 350;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = -7;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\tbreak;\n\t\tcase 33094:\n\t\t\titemDef.name = \"Chaotic crossbow\";\n\t\t\titemDef.description = \"A small crossbow, only effective at short distance.\";\n\t\t\titemDef.modelId = 54331;\n\t\t\titemDef.maleModel = 56307;\n\t\t\titemDef.femaleModel = 56307;\n\t\t\titemDef.modelZoom = 1028;\n\t\t\titemDef.modelRotation1 = 249;\n\t\t\titemDef.modelRotation2 = 2021;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -54;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = -7;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\tbreak;\n\t\tcase 33095:\n\t\t\titemDef.name = \"Chaotic staff\";\n\t\t\titemDef.description = \"This staff makes destructive spells more powerful.\";\n\t\t\titemDef.modelId = 54367;\n\t\t\titemDef.maleModel = 56286;\n\t\t\titemDef.femaleModel = 56286;\n\t\t\titemDef.modelZoom = 1711;\n\t\t\titemDef.modelRotation1 = 471;\n\t\t\titemDef.modelRotation2 = 391;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = -7;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\tbreak;\n\t\tcase 33096:\n\t\t\titemDef.name = \"Chaotic kiteshield\";\n\t\t\titemDef.description = \"A large metal shield.\";\n\t\t\titemDef.modelId = 54358;\n\t\t\titemDef.maleModel = 56038;\n\t\t\titemDef.femaleModel = 56038;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 276;\n\t\t\titemDef.modelRotation2 = 1101;\n\t\t\titemDef.modelOffset1 = -5;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33031:\n\t\t\titemDef.name = \"Chaotic rapier\";\n\t\t\titemDef.description = \"A razor-sharp rapier.\";\n\t\t\titemDef.modelId = 54197;\n\t\t\titemDef.maleModel = 56252;\n\t\t\titemDef.femaleModel = 56252;\n\t\t\titemDef.modelZoom = 1425;\n\t\t\titemDef.modelRotation1 = 540;\n\t\t\titemDef.modelRotation2 = 1370;\n\t\t\titemDef.modelOffset1 = 9;\n\t\t\titemDef.modelOffset2 = 13;\n\t\t\titemDef.maleOffset = -12;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = -7;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\tbreak;\n\t\tcase 33032:\n\t\t\titemDef.name = \"Chaotic longsword\";\n\t\t\titemDef.description = \"A razor-sharp longsword.\";\n\t\t\titemDef.modelId = 54204;\n\t\t\titemDef.maleModel = 56237;\n\t\t\titemDef.femaleModel = 56237;\n\t\t\titemDef.modelZoom = 1650;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 1300;\n\t\t\t// itemDef.aByte154 = -14;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = -7;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\tbreak;\n\t\tcase 33097:\n\t\t\titemDef.name = \"Sword of Onyxia\";\n\t\t\titemDef.description = \"A razor-sharp longsword.\";\n\t\t\titemDef.modelId = 53091;\n\t\t\titemDef.maleModel = 53092;\n\t\t\titemDef.femaleModel = 53092;\n\t\t\titemDef.modelZoom = 2007;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33098:\n\t\t\titemDef.name = \"Onyxia longsword\";\n\t\t\titemDef.description = \"A razor-sharp 2h sword.\";\n\t\t\titemDef.modelId = 53093;\n\t\t\titemDef.maleModel = 53094;\n\t\t\titemDef.femaleModel = 53094;\n\t\t\titemDef.modelZoom = 4007;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.maleOffset = -8;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33099:\n\t\t\titemDef.name = \"White scimitar\";\n\t\t\titemDef.description = \"A razor-sharp scimitar.\";\n\t\t\titemDef.modelId = 53097;\n\t\t\titemDef.maleModel = 53098;\n\t\t\titemDef.femaleModel = 53098;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 312;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\t// itemDef.aByte154 = -14;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33100:\n\t\t\titemDef.name = \"White kiteshield\";\n\t\t\titemDef.description = \"a heavy kiteshield.\";\n\t\t\titemDef.modelId = 53095;\n\t\t\titemDef.maleModel = 53096;\n\t\t\titemDef.femaleModel = 53096;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelRotation1 = 303;\n\t\t\titemDef.modelRotation2 = 180;\n\t\t\t// itemDef.aByte154 = -14;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = 7;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33033:\n\t\t\titemDef.name = \"Agility master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 677, 801, 43540, 43543, 43546, 43549, 43550, 43552, 43554, 43558,\n\t\t\t\t\t43560, 43575 };\n\t\t\titemDef.modelId = 50030;\n\t\t\titemDef.maleModel = 50031;\n\t\t\titemDef.femaleModel = 50031;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33034:\n\t\t\titemDef.name = \"Attack master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 7104, 9151, 911, 914, 917, 920, 921, 923, 925, 929, 931, 946 };\n\t\t\titemDef.modelId = 50032;\n\t\t\titemDef.maleModel = 50033;\n\t\t\titemDef.femaleModel = 50033;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33035:\n\t\t\titemDef.name = \"Construction master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 6061, 5945, 6327, 6330, 6333, 6336, 6337, 6339, 6341, 6345, 6347,\n\t\t\t\t\t6362 };\n\t\t\titemDef.modelId = 50034;\n\t\t\titemDef.maleModel = 50035;\n\t\t\titemDef.femaleModel = 50035;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33036:\n\t\t\titemDef.name = \"Cooking master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 920, 920, 51856, 51859, 51862, 51865, 51866, 51868, 51870, 51874,\n\t\t\t\t\t51876, 51891 };\n\t\t\titemDef.modelId = 50036;\n\t\t\titemDef.maleModel = 50037;\n\t\t\titemDef.femaleModel = 50037;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33037:\n\t\t\titemDef.name = \"Crafting master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 9142, 9152, 4511, 4514, 4517, 4520, 4521, 4523, 4525, 4529, 4531,\n\t\t\t\t\t4546 };\n\t\t\titemDef.modelId = 50038;\n\t\t\titemDef.maleModel = 50039;\n\t\t\titemDef.femaleModel = 50039;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33038:\n\t\t\titemDef.name = \"Defence master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 10460, 10473, 41410, 41413, 41416, 41419, 41420, 41422, 41424,\n\t\t\t\t\t41428, 41430, 41445 };\n\t\t\titemDef.modelId = 50040;\n\t\t\titemDef.maleModel = 50041;\n\t\t\titemDef.femaleModel = 50041;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33039:\n\t\t\titemDef.name = \"Farming master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 14775, 14792, 22026, 22029, 22032, 22035, 22036, 22038, 22040,\n\t\t\t\t\t22044, 22046, 22061 };\n\t\t\titemDef.modelId = 50042;\n\t\t\titemDef.maleModel = 50043;\n\t\t\titemDef.femaleModel = 50043;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33040:\n\t\t\titemDef.name = \"Firemaking master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 8125, 9152, 4015, 4018, 4021, 4024, 4025, 4027, 4029, 4033, 4035,\n\t\t\t\t\t4050 };\n\t\t\titemDef.modelId = 50044;\n\t\t\titemDef.maleModel = 50045;\n\t\t\titemDef.femaleModel = 50045;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33041:\n\t\t\titemDef.name = \"Fishing master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 9144, 9152, 38202, 38205, 38208, 38211, 38212, 38214, 38216,\n\t\t\t\t\t38220, 38222, 38237 };\n\t\t\titemDef.modelId = 50046;\n\t\t\titemDef.maleModel = 50047;\n\t\t\titemDef.femaleModel = 50047;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33042:\n\t\t\titemDef.name = \"Fletching master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 6067, 9152, 33670, 33673, 33676, 33679, 33680, 33682, 33684,\n\t\t\t\t\t33688, 33690, 33705 };\n\t\t\titemDef.modelId = 50048;\n\t\t\titemDef.maleModel = 50049;\n\t\t\titemDef.femaleModel = 50049;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33043:\n\t\t\titemDef.name = \"Herblore master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 9145, 9156, 22414, 22417, 22420, 22423, 22424, 22426, 22428,\n\t\t\t\t\t22432, 22434, 22449 };\n\t\t\titemDef.modelId = 50050;\n\t\t\titemDef.maleModel = 50051;\n\t\t\titemDef.femaleModel = 50051;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33044:\n\t\t\titemDef.name = \"Hitpoints master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 818, 951, 8291, 8294, 8297, 8300, 8301, 8303, 8305, 8309, 8311,\n\t\t\t\t\t8319 };\n\t\t\titemDef.modelId = 50052;\n\t\t\titemDef.maleModel = 50053;\n\t\t\titemDef.femaleModel = 50053;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\titemDef.femaleOffset = 4;\n\t\t\tbreak;\n\t\tcase 33045:\n\t\t\titemDef.name = \"Hunter master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 5262, 6020, 8472, 8475, 8478, 8481, 8482, 8484, 8486, 8490, 8492,\n\t\t\t\t\t8507 };\n\t\t\titemDef.modelId = 50054;\n\t\t\titemDef.maleModel = 50055;\n\t\t\titemDef.femaleModel = 50055;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33046:\n\t\t\titemDef.name = \"Magic master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 43569, 43685, 6336, 6339, 6342, 6345, 6346, 6348, 6350, 6354,\n\t\t\t\t\t6356, 6371 };\n\t\t\titemDef.modelId = 50056;\n\t\t\titemDef.maleModel = 50057;\n\t\t\titemDef.femaleModel = 50057;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33047:\n\t\t\titemDef.name = \"Mining master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 36296, 36279, 10386, 10389, 10392, 10395, 10396, 10398, 10400,\n\t\t\t\t\t10404, 10406, 10421 };\n\t\t\titemDef.modelId = 50058;\n\t\t\titemDef.maleModel = 50059;\n\t\t\titemDef.femaleModel = 50059;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33048:\n\t\t\titemDef.name = \"Prayer master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 9163, 9168, 117, 120, 123, 126, 127, 127, 127, 127, 127, 127 };\n\t\t\titemDef.modelId = 50060;\n\t\t\titemDef.maleModel = 50061;\n\t\t\titemDef.femaleModel = 50061;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33049:\n\t\t\titemDef.name = \"Range master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 3755, 3998, 15122, 15125, 15128, 15131, 15132, 15134, 15136,\n\t\t\t\t\t15140, 15142, 15157 };\n\t\t\titemDef.modelId = 50062;\n\t\t\titemDef.maleModel = 50063;\n\t\t\titemDef.femaleModel = 50063;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33050:\n\t\t\titemDef.name = \"Runecrafting master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\t// 4 //7 //10 //13 //14//16//18//22 //24//39\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 9152, 8128, 10318, 10321, 10324, 10327, 10328, 10330, 10332,\n\t\t\t\t\t10336, 10338, 10353 };\n\t\t\titemDef.modelId = 50064;\n\t\t\titemDef.maleModel = 50065;\n\t\t\titemDef.femaleModel = 50065;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33051:\n\t\t\titemDef.name = \"Slayer master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811 };\n\t\t\titemDef.originalModelColors = new int[] { 912, 920 };\n\t\t\titemDef.modelId = 50066;\n\t\t\titemDef.maleModel = 50067;\n\t\t\titemDef.femaleModel = 50067;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33052:\n\t\t\titemDef.name = \"Smithing master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 8115, 9148, 10386, 10389, 10392, 10395, 10396, 10398, 10400,\n\t\t\t\t\t10404, 10406, 10421 };\n\t\t\titemDef.modelId = 50068;\n\t\t\titemDef.maleModel = 50069;\n\t\t\titemDef.femaleModel = 50069;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33053:\n\t\t\titemDef.name = \"Strength master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 935, 931, 27538, 27541, 27544, 27547, 27548, 27550, 27552, 27556,\n\t\t\t\t\t27558, 27573 };\n\t\t\titemDef.modelId = 50070;\n\t\t\titemDef.maleModel = 50071;\n\t\t\titemDef.femaleModel = 50071;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33054:\n\t\t\titemDef.name = \"Thieving master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 11, 0, 58779, 58782, 58785, 58788, 58789, 57891, 58793, 58797,\n\t\t\t\t\t58799, 58814 };\n\t\t\titemDef.modelId = 50072;\n\t\t\titemDef.maleModel = 50073;\n\t\t\titemDef.femaleModel = 50073;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33055:\n\t\t\titemDef.name = \"Woodcutting master cape\";\n\t\t\titemDef.description = \"\tA cape worn by those who've overachieved.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 57022, 48811, 2, 1029, 1032, 11, 12, 14, 16, 20, 22, 2 };\n\t\t\titemDef.originalModelColors = new int[] { 25109, 24088, 6693, 6696, 6699, 6702, 6703, 6705, 6707, 6711,\n\t\t\t\t\t6713, 6728 };\n\t\t\titemDef.modelId = 50074;\n\t\t\titemDef.maleModel = 50075;\n\t\t\titemDef.femaleModel = 50075;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 5;\n\t\t\tbreak;\n\t\tcase 33057:\n\t\t\titemDef.name = \"Abyssal Scythe\";\n\t\t\titemDef.description = \"\tA Scythe recieved from the Trials of Xeric CUSTOM RAID.\";\n\t\t\titemDef.modelId = 50081;\n\t\t\titemDef.maleModel = 50080;\n\t\t\titemDef.femaleModel = 50080;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.maleOffset = -12;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33090:\n\t\t\titemDef.name = \"Goliath gloves (Black)\";\n\t\t\titemDef.description = \"\tA pair of gloves earned with blood.\";\n\t\t\titemDef.modelId = 50108;\n\t\t\titemDef.maleModel = 50100;\n\t\t\titemDef.femaleModel = 50101;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 539;\n\t\t\titemDef.modelRotation2 = 40;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33091:\n\t\t\titemDef.name = \"Goliath gloves (Red)\";\n\t\t\titemDef.description = \"\tA pair of gloves earned with blood.\";\n\t\t\titemDef.modelId = 50108;\n\t\t\titemDef.maleModel = 50102;\n\t\t\titemDef.femaleModel = 50103;\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 65046, 65051, 65056 };\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 539;\n\t\t\titemDef.modelRotation2 = 40;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33092:\n\t\t\titemDef.name = \"Goliath gloves (White)\";\n\t\t\titemDef.description = \"\tA pair of gloves earned with blood.\";\n\t\t\titemDef.modelId = 50108;\n\t\t\titemDef.maleModel = 50104;\n\t\t\titemDef.femaleModel = 50105;\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 64585, 64590, 64595 };\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 539;\n\t\t\titemDef.modelRotation2 = 40;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33093:\n\t\t\titemDef.name = \"Goliath gloves (Yellow)\";\n\t\t\titemDef.description = \"\tA pair of gloves earned with blood.\";\n\t\t\titemDef.modelId = 50108;\n\t\t\titemDef.maleModel = 50106;\n\t\t\titemDef.femaleModel = 50107;\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 9767, 9772, 9777 };\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 539;\n\t\t\titemDef.modelRotation2 = 40;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 12639:\n\t\tcase 12637:\n\t\tcase 12638:\n\t\t\titemDef.description = \"Provides players with infinite run energy!\";\n\t\t\tbreak;\n\t\tcase 33056:\n\t\t\titemDef.name = \"Events cape (slayer)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 933, 0, 0, 0, 0 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33081:\n\t\t\titemDef.name = \"Events cape (agility)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 669, 43430, 43430, 43430, 43430 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33080:\n\t\t\titemDef.name = \"Events cape (attack)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 9926, 1815, 1815, 1815, 1815 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33059:\n\t\t\titemDef.name = \"Events cape (construction)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 6967, 6343, 6343, 6343, 6343 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33061:\n\t\t\titemDef.name = \"Events cape (cooking)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 1819, 49685, 49685, 49685, 49685 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33062:\n\t\t\titemDef.name = \"Events cape (crafting)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 7994, 4516, 4516, 4516, 4516 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33063:\n\t\t\titemDef.name = \"Events cape (defence)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 39367, 10472, 10472, 10472, 10472 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33064:\n\t\t\titemDef.name = \"Events cape (farming)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10698, 19734, 19734, 19734, 19734 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33065:\n\t\t\titemDef.name = \"Events cape (firemaking)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10059, 4922, 4922, 4922, 4922 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33066:\n\t\t\titemDef.name = \"Events cape (fishing)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10047, 36165, 36165, 36165, 36165 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33067:\n\t\t\titemDef.name = \"Events cape (fletching)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10047, 31500, 31500, 31500, 31500 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33068:\n\t\t\titemDef.name = \"Events cape (herblore)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10051, 20889, 20889, 20889, 20889 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33069:\n\t\t\titemDef.name = \"Events cape (hitpoints)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 1836, 8296, 8296, 8296, 8296 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33070:\n\t\t\titemDef.name = \"Events cape (hunter)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 6916, 8477, 8477, 8477, 8477 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33071:\n\t\t\titemDef.name = \"Events cape (magic)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 43556, 6339, 6339, 6339, 6339 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33072:\n\t\t\titemDef.name = \"Events cape (mining)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 34111, 10391, 10391, 10391, 10391 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33073:\n\t\t\titemDef.name = \"Events cape (prayer)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 9927, 2169, 2169, 2169, 2169 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33074:\n\t\t\titemDef.name = \"Events cape (range)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 3626, 20913, 20913, 20913, 20913 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33075:\n\t\t\titemDef.name = \"Events cape (runecrafting)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10047, 10323, 10323, 10323, 10323 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33076:\n\t\t\titemDef.name = \"Events cape (smithing)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 10044, 5412, 5412, 5412, 5412 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33077:\n\t\t\titemDef.name = \"Events cape (strength)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 1819, 30487, 30487, 30487, 30487 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33078:\n\t\t\titemDef.name = \"Events cape (thieveing)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 8, 57636, 57636, 57636, 57636 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33079:\n\t\t\titemDef.name = \"Events cape (woodcutting)\";\n\t\t\titemDef.description = \"events cape.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 38333, 127, 107, 115, 90 };\n\t\t\titemDef.originalModelColors = new int[] { 26007, 6570, 6570, 6570, 6570 };\n\t\t\titemDef.modelId = 34418;\n\t\t\titemDef.maleModel = 34271;\n\t\t\titemDef.femaleModel = 34288;\n\t\t\titemDef.modelZoom = 1960;\n\t\t\titemDef.modelRotation1 = 528;\n\t\t\titemDef.modelRotation2 = 1583;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33101:\n\t\t\titemDef.name = \"Vorkath platebody\";\n\t\t\titemDef.description = \"Vorkath armour.\";\n\t\t\titemDef.modelId = 53100;\n\t\t\titemDef.maleModel = 53099;\n\t\t\titemDef.femaleModel = 53099;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33102:\n\t\t\titemDef.name = \"Vorkath platelegs\";\n\t\t\titemDef.description = \"Vorkath armour.\";\n\t\t\titemDef.modelId = 53102;\n\t\t\titemDef.maleModel = 53101;\n\t\t\titemDef.femaleModel = 53101;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33103:\n\t\t\titemDef.name = \"Vorkath boots\";\n\t\t\titemDef.description = \"Vorkath armour.\";\n\t\t\titemDef.modelId = 53104;\n\t\t\titemDef.maleModel = 53103;\n\t\t\titemDef.femaleModel = 53103;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33104:\n\t\t\titemDef.name = \"Vorkath gloves\";\n\t\t\titemDef.description = \"Vorkath armour.\";\n\t\t\titemDef.modelId = 53106;\n\t\t\titemDef.maleModel = 53105;\n\t\t\titemDef.femaleModel = 53105;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33105:\n\t\t\titemDef.name = \"Vorkath helmet\";\n\t\t\titemDef.description = \"Vorkath armour.\";\n\t\t\titemDef.modelId = 53108;\n\t\t\titemDef.maleModel = 53107;\n\t\t\titemDef.femaleModel = 53107;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33106:\n\t\t\titemDef.name = \"Tekton helmet\";\n\t\t\titemDef.description = \"Tekton armour.\";\n\t\t\titemDef.modelId = 53118;\n\t\t\titemDef.maleModel = 53117;\n\t\t\titemDef.femaleModel = 53117;\n\t\t\titemDef.modelZoom = 724;\n\t\t\titemDef.modelRotation1 = 81;\n\t\t\titemDef.modelRotation2 = 1670;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33107:\n\t\t\titemDef.name = \"Tekton platebody\";\n\t\t\titemDef.description = \"Tekton armour.\";\n\t\t\titemDef.modelId = 53110;\n\t\t\titemDef.maleModel = 53109;\n\t\t\titemDef.femaleModel = 53109;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33108:\n\t\t\titemDef.name = \"Tekton platelegs\";\n\t\t\titemDef.description = \"Tekton armour.\";\n\t\t\titemDef.modelId = 53112;\n\t\t\titemDef.maleModel = 53111;\n\t\t\titemDef.femaleModel = 53111;\n\t\t\titemDef.modelZoom = 1550;\n\t\t\titemDef.modelRotation1 = 344;\n\t\t\titemDef.modelRotation2 = 186;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 11;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33109:\n\t\t\titemDef.name = \"Tekton gloves\";\n\t\t\titemDef.description = \"Tekton armour.\";\n\t\t\titemDef.modelId = 53116;\n\t\t\titemDef.maleModel = 53115;\n\t\t\titemDef.femaleModel = 53115;\n\t\t\titemDef.modelZoom = 830;\n\t\t\titemDef.modelRotation1 = 536;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33110:\n\t\t\titemDef.name = \"Tekton boots\";\n\t\t\titemDef.description = \"Tekton armour.\";\n\t\t\titemDef.modelId = 53114;\n\t\t\titemDef.maleModel = 53113;\n\t\t\titemDef.femaleModel = 53113;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33111:\n\t\t\titemDef.name = \"Anti-santa scythe\";\n\t\t\titemDef.description = \"Legend says this is the biggest arse scratcher around.\";\n\t\t\titemDef.modelId = 57002;\n\t\t\titemDef.maleModel = 57001;\n\t\t\titemDef.femaleModel = 57001;\n\t\t\titemDef.modelZoom = 3224;\n\t\t\titemDef.modelRotation1 = 539;\n\t\t\titemDef.modelRotation2 = 714;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33112:\n\t\t\titemDef.name = \"Dominion staff\";\n\t\t\titemDef.description = \"Dominion staff.\";\n\t\t\titemDef.modelId = 59029;\n\t\t\titemDef.maleModel = 59305;\n\t\t\titemDef.femaleModel = 59305;\n\t\t\titemDef.modelZoom = 1872;\n\t\t\titemDef.modelRotation1 = 288;\n\t\t\titemDef.modelRotation2 = 1685;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33113:\n\t\t\titemDef.name = \"Dominion sword\";\n\t\t\titemDef.description = \"Dominion sword.\";\n\t\t\titemDef.modelId = 59832;\n\t\t\titemDef.maleModel = 59306;\n\t\t\titemDef.femaleModel = 59306;\n\t\t\titemDef.modelZoom = 1829;\n\t\t\titemDef.modelRotation1 = 513;\n\t\t\titemDef.modelRotation2 = 546;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33114:\n\t\t\titemDef.name = \"Dominion crossbow\";\n\t\t\titemDef.description = \"Dominion crossbow.\";\n\t\t\titemDef.modelId = 59839;\n\t\t\titemDef.maleModel = 59304;\n\t\t\titemDef.femaleModel = 59304;\n\t\t\titemDef.modelZoom = 1490;\n\t\t\titemDef.modelRotation1 = 362;\n\t\t\titemDef.modelRotation2 = 791;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33115:\n\t\t\titemDef.name = \"Dragonfire Shield (e)\";\n\t\t\titemDef.description = \"unamed shield.\";\n\t\t\titemDef.modelId = 53120;\n\t\t\titemDef.maleModel = 53119;\n\t\t\titemDef.femaleModel = 53119;\n\t\t\titemDef.modelZoom = 2022;\n\t\t\titemDef.modelRotation1 = 540;\n\t\t\titemDef.modelRotation2 = 123;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[] { null, \"Wear\", \"Inspect\", \"Empty\", \"Drop\" };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33116:\n\t\t\titemDef.name = \"Zilyana's longbow\";\n\t\t\titemDef.description = \"A bow belonged to Zilyana.\";\n\t\t\titemDef.modelId = 53122;\n\t\t\titemDef.maleModel = 53121;\n\t\t\titemDef.femaleModel = 53121;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 636;\n\t\t\titemDef.modelRotation2 = 1010;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33117:\n\t\t\titemDef.name = \"Black dragon hunter crossbow\";\n\t\t\titemDef.description = \"Black dragon hunter crossbow.\";\n\t\t\titemDef.modelId = 53124;\n\t\t\titemDef.maleModel = 53123;\n\t\t\titemDef.femaleModel = 53123;\n\t\t\titemDef.modelZoom = 1554;\n\t\t\titemDef.modelRotation1 = 636;\n\t\t\titemDef.modelRotation2 = 1010;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33118:\n\t\t\titemDef.name = \"Vorkath blowpipe\";\n\t\t\titemDef.description = \"Vorkath blowpipe.\";\n\t\t\titemDef.modelId = 53126;\n\t\t\titemDef.maleModel = 53125;\n\t\t\titemDef.femaleModel = 53125;\n\t\t\titemDef.modelZoom = 1158;\n\t\t\titemDef.modelRotation1 = 768;\n\t\t\titemDef.modelRotation2 = 189;\n\t\t\titemDef.modelOffset1 = -7;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33119:\n\t\t\titemDef.name = \"Superior twisted bow\";\n\t\t\titemDef.description = \"An upgraded twisted bow.\";\n\t\t\titemDef.modelId = 53128;\n\t\t\titemDef.maleModel = 53127;\n\t\t\titemDef.femaleModel = 53127;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 720;\n\t\t\titemDef.modelRotation2 = 1500;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\titemDef.maleOffset = -4;\n\t\t\titemDef.femaleOffset = -4;\n\t\t\tbreak;\n\t\tcase 33123:\n\t\t\titemDef.name = \"Staff of sliske\";\n\t\t\titemDef.description = \"Staff of sliske.\";\n\t\t\titemDef.modelId = 59234;\n\t\t\titemDef.maleModel = 59233;\n\t\t\titemDef.femaleModel = 59233;\n\t\t\titemDef.modelZoom = 1872;\n\t\t\titemDef.modelRotation1 = 288;\n\t\t\titemDef.modelRotation2 = 1685;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33124:\n\t\t\titemDef.name = \"Twisted crossbow\";\n\t\t\titemDef.description = \"Twisted crossbow.\";\n\t\t\titemDef.modelId = 62777;\n\t\t\titemDef.maleModel = 62776;\n\t\t\titemDef.femaleModel = 62776;\n\t\t\titemDef.modelZoom = 926;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 258;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33125:\n\t\t\titemDef.name = \"Present\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modelId = 2426;\n\t\t\titemDef.modelZoom = 1180;\n\t\t\titemDef.modelRotation1 = 160;\n\t\t\titemDef.modelRotation2 = 172;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -14;\n\t\t\titemDef.modifiedModelColors = new int[] { 22410, 2999 };\n\t\t\titemDef.originalModelColors = new int[] { 933, 24410 };\n\t\t\titemDef.description = \"Santa's stolen present\";\n\t\t\tbreak;\n\t\tcase 33126:\n\t\t\titemDef.name = \"Christmas tree branch\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modelId = 2412;\n\t\t\titemDef.modelZoom = 940;\n\t\t\titemDef.modelRotation1 = 268;\n\t\t\titemDef.modelRotation2 = 152;\n\t\t\titemDef.modelOffset1 = -8;\n\t\t\titemDef.modelOffset2 = -21;\n\t\t\titemDef.modifiedModelColors = new int[] { 11144 };\n\t\t\titemDef.originalModelColors = new int[] { 6047 };\n\t\t\titemDef.description = \"Enter examine here.\";\n\t\t\tbreak;\n\t\tcase 33127:\n\t\t\titemDef.name = \"Kbd gloves\";\n\t\t\titemDef.description = \"Kbd gloves.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 33085 };\n\t\t\titemDef.originalModelColors = new int[] { 1060 };\n\t\t\titemDef.modelId = 53106;\n\t\t\titemDef.maleModel = 53105;\n\t\t\titemDef.femaleModel = 53105;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33128:\n\t\t\titemDef.name = \"Kbd boots\";\n\t\t\titemDef.description = \"Kbd boots.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 33198, 33202, 33206, 33215, 33210 };\n\t\t\titemDef.originalModelColors = new int[] { 1060, 1061, 1063, 1064, 1065 };\n\t\t\titemDef.modelId = 53104;\n\t\t\titemDef.maleModel = 53103;\n\t\t\titemDef.femaleModel = 53103;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33129:\n\t\t\titemDef.name = \"Kbd platelegs\";\n\t\t\titemDef.description = \"Kbd platelegs.\";\n\t\t\titemDef.modelId = 59994;\n\t\t\titemDef.maleModel = 59995;\n\t\t\titemDef.femaleModel = 59995;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33130:\n\t\t\titemDef.name = \"Kbd platebody\";\n\t\t\titemDef.description = \"Kbd platebody.\";\n\t\t\titemDef.modelId = 59998;\n\t\t\titemDef.maleModel = 59999;\n\t\t\titemDef.femaleModel = 59999;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33131:\n\t\t\titemDef.name = \"Kbd helmet\";\n\t\t\titemDef.description = \"Kbd helmet.\";\n\t\t\titemDef.modelId = 59996;\n\t\t\titemDef.maleModel = 59997;\n\t\t\titemDef.femaleModel = 59997;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33132:\n\t\t\titemDef.name = \"Kbd cape\";\n\t\t\titemDef.description = \"Kbd cape.\";\n\t\t\titemDef.modelId = 59992;\n\t\t\titemDef.maleModel = 59993;\n\t\t\titemDef.femaleModel = 59993;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33133:\n\t\t\titemDef.name = \"Anti-imp pet\";\n\t\t\titemDef.description = \"Anti-imp pet.\";\n\t\t\titemDef.modelId = 45294;\n\t\t\titemDef.modelZoom = 1500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33134:\n\t\t\titemDef.name = \"Anti-santa pet\";\n\t\t\titemDef.description = \"Anti-santa pet.\";\n\t\t\titemDef.modelId = 29030;\n\t\t\titemDef.modelZoom = 653;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 1966;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33135:\n\t\t\titemDef.name = \"Bandos mask\";\n\t\t\titemDef.description = \"Bandos helmet.\";\n\t\t\titemDef.modelId = 59987;\n\t\t\titemDef.maleModel = 59991;\n\t\t\titemDef.femaleModel = 59991;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33136:\n\t\t\titemDef.name = \"Armadyl mask\";\n\t\t\titemDef.description = \"Armadyl mask.\";\n\t\t\titemDef.modelId = 59986;\n\t\t\titemDef.maleModel = 59990;\n\t\t\titemDef.femaleModel = 59990;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33137:\n\t\t\titemDef.name = \"Zamorak mask\";\n\t\t\titemDef.description = \"Zamorak mask.\";\n\t\t\titemDef.modelId = 59985;\n\t\t\titemDef.maleModel = 59989;\n\t\t\titemDef.femaleModel = 59989;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33138:\n\t\t\titemDef.name = \"Saradomin mask\";\n\t\t\titemDef.description = \"Saradomin mask.\";\n\t\t\titemDef.modelId = 59984;\n\t\t\titemDef.maleModel = 59988;\n\t\t\titemDef.femaleModel = 59988;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33139:\n\t\t\titemDef.name = \"Zamarok godbow\";\n\t\t\titemDef.description = \"Zamarok godbow.\";\n\t\t\titemDef.modelId = 60560;//60553\n\t\t\titemDef.maleModel = 60560;\n\t\t\titemDef.femaleModel = 60560;\n\t\t\titemDef.modelZoom = 2100;\n\t\t\titemDef.modelRotation1 = 720;\n\t\t\titemDef.modelRotation2 = 1500;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33140:\n\t\t\titemDef.name = \"Saradomin godbow\";\n\t\t\titemDef.description = \"Saradomin godbow.\";\n\t\t\titemDef.modelId = 60555;\n\t\t\titemDef.maleModel = 60554;\n\t\t\titemDef.femaleModel = 60554;\n\t\t\titemDef.modelZoom = 2100;\n\t\t\titemDef.modelRotation1 = 720;\n\t\t\titemDef.modelRotation2 = 1500;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33141:\n\t\t\titemDef.name = \"Bandos godbow\";\n\t\t\titemDef.description = \"Bandos godbow.\";\n\t\t\titemDef.modelId = 60559;\n\t\t\titemDef.maleModel = 60558;\n\t\t\titemDef.femaleModel = 60558;\n\t\t\titemDef.modelZoom = 2100;\n\t\t\titemDef.modelRotation1 = 720;\n\t\t\titemDef.modelRotation2 = 1500;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33142:\n\t\t\titemDef.name = \"Fire cape (purple)\";\n\t\t\titemDef.description = \"Fire cape (purple).\";\n\t\t\titemDef.modelId = 9631;\n\t\t\titemDef.maleModel = 9638;\n\t\t\titemDef.femaleModel = 9640;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33148:\n\t\t\titemDef.name = \"Fire cape (cyan)\";\n\t\t\titemDef.description = \"Fire cape (cyan).\";\n\t\t\titemDef.modelId = 9631;\n\t\t\titemDef.maleModel = 9638;\n\t\t\titemDef.femaleModel = 9640;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33144:\n\t\t\titemDef.name = \"Fire cape (green)\";\n\t\t\titemDef.description = \"Fire cape (green).\";\n\t\t\titemDef.modelId = 9631;\n\t\t\titemDef.maleModel = 9638;\n\t\t\titemDef.femaleModel = 9640;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33145:\n\t\t\titemDef.name = \"Fire cape (red)\";\n\t\t\titemDef.description = \"Fire cape (red).\";\n\t\t\titemDef.modelId = 9631;\n\t\t\titemDef.maleModel = 9638;\n\t\t\titemDef.femaleModel = 9640;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33143:\n\t\t\titemDef.name = \"Infernal cape (blue)\";\n\t\t\titemDef.description = \"Infernal cape (blue).\";\n\t\t\titemDef.modifiedModelColors = new int[] { 5056, 5066, 924, 3005 };\n\t\t\titemDef.originalModelColors = new int[] { 39851, 39851, 39851, 39851 };\n\t\t\titemDef.modelId = 33144;\n\t\t\titemDef.maleModel = 33103;\n\t\t\titemDef.femaleModel = 33111;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33146:\n\t\t\titemDef.name = \"Infernal cape (green)\";\n\t\t\titemDef.description = \"Infernal cape (green).\";\n\t\t\titemDef.modifiedModelColors = new int[] { 5056, 5066, 924, 3005 };\n\t\t\titemDef.originalModelColors = new int[] { 21167, 21167, 21167, 21167 };\n\t\t\titemDef.modelId = 33144;\n\t\t\titemDef.maleModel = 33103;\n\t\t\titemDef.femaleModel = 33111;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33147:\n\t\t\titemDef.name = \"Infernal cape (purple)\";\n\t\t\titemDef.description = \"Infernal cape (purple).\";\n\t\t\titemDef.modifiedModelColors = new int[] { 5056, 5066, 924, 3005 };\n\t\t\titemDef.originalModelColors = new int[] { 53160, 53160, 53160, 53160 };\n\t\t\titemDef.modelId = 33144;\n\t\t\titemDef.maleModel = 33103;\n\t\t\titemDef.femaleModel = 33111;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33150:\n\t\t\titemDef.name = \"Infernal key piece 1\";\n\t\t\titemDef.description = \"Infernal key piece 1.\";\n\t\t\titemDef.modelId = 61001;\n\t\t\titemDef.modelZoom = 1200;\n\t\t\titemDef.modelRotation1 = 534;\n\t\t\titemDef.modelRotation2 = 222;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Combine\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33151:\n\t\t\titemDef.name = \"Infernal key piece 2\";\n\t\t\titemDef.description = \"Infernal key piece 2.\";\n\t\t\titemDef.modelId = 61002;\n\t\t\titemDef.modelZoom = 1200;\n\t\t\titemDef.modelRotation1 = 534;\n\t\t\titemDef.modelRotation2 = 222;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Combine\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33152:\n\t\t\titemDef.name = \"Infernal key piece 3\";\n\t\t\titemDef.description = \"Infernal key piece 3.\";\n\t\t\titemDef.modelId = 61003;\n\t\t\titemDef.modelZoom = 1200;\n\t\t\titemDef.modelRotation1 = 534;\n\t\t\titemDef.modelRotation2 = 222;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Combine\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33153:\n\t\t\titemDef.name = \"Infernal key\";\n\t\t\titemDef.description = \"Infernal key.\";\n\t\t\titemDef.modelId = 61111;\n\t\t\titemDef.modelZoom = 1200;\n\t\t\titemDef.modelRotation1 = 534;\n\t\t\titemDef.modelRotation2 = 222;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\t\t//DOPES ITEMS NIGGAHAHAHAHAHAHAH\n\t\tcase 2749:\n\t\t\titemDef.name = \"Bloody Axe\";\n\t\t\titemDef.description = \"Look at all that blood!\";\n\t\t\titemDef.modelId = 65495;\n\t\t\titemDef.femaleModel = 65495;\n\t\t\titemDef.maleModel = 65495;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 2750:\n\t\t\titemDef.name = \"Bloody Axe Offhand\";\n\t\t\titemDef.description = \"Look at all that blood!\";\n\t\t\titemDef.modelId = 65496;\n\t\t\titemDef.femaleModel = 65496;\n\t\t\titemDef.maleModel = 65496;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33154:\n\t\t\titemDef.name = \"Infernal mystery box\";\n\t\t\titemDef.description = \"Infernal mystery box.\";\n\t\t\titemDef.modelId = 61110;\n\t\t\titemDef.modelZoom = 1180;\n\t\t\titemDef.modelRotation1 = 160;\n\t\t\titemDef.modelRotation2 = 172;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -14;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Open\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33155:\n\t\t\titemDef.name = \"Ethereal sword (red)\";\n\t\t\titemDef.description = \"Ethereal sword (red).\";\n\t\t\titemDef.modelId = 61005;\n\t\t\titemDef.maleModel = 61004;\n\t\t\titemDef.femaleModel = 61004;\n\t\t\titemDef.modelZoom = 1645;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33156:\n\t\t\titemDef.name = \"Ethereal sword (blue)\";\n\t\t\titemDef.description = \"Ethereal sword (blue).\";\n\t\t\titemDef.modelId = 61006;\n\t\t\titemDef.maleModel = 61007;\n\t\t\titemDef.femaleModel = 61007;\n\t\t\titemDef.modelZoom = 1645;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33157:\n\t\t\titemDef.name = \"Ethereal sword (green)\";\n\t\t\titemDef.description = \"Ethereal sword (green).\";\n\t\t\titemDef.modelId = 61008;\n\t\t\titemDef.maleModel = 61009;\n\t\t\titemDef.femaleModel = 61009;\n\t\t\titemDef.modelZoom = 1645;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33158:\n\t\t\titemDef.name = \"Dagon' hai top\";\n\t\t\titemDef.description = \"An elite dark mages robes.\";\n\t\t\titemDef.modelId = 60317;\n\t\t\titemDef.maleModel = 43614;\n\t\t\titemDef.femaleModel = 43689;\n\t\t\titemDef.anInt188 = 44594;\n\t\t\titemDef.anInt164 = 43681;\n\t\t\titemDef.modelZoom = 1697;\n\t\t\titemDef.modelRotation1 = 536;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 7;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33159:\n\t\t\titemDef.name = \"Dagon' hai hat\";\n\t\t\titemDef.description = \"An elite dark mages hat.\";\n\t\t\titemDef.modelId = 60319;\n\t\t\titemDef.maleModel = 60318;\n\t\t\titemDef.femaleModel = 60318;\n\t\t\titemDef.anInt188 = -1;\n\t\t\titemDef.anInt164 = -1;\n\t\t\titemDef.modelZoom = 1373;\n\t\t\titemDef.modelRotation1 = 98;\n\t\t\titemDef.modelRotation2 = 1988;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33160:\n\t\t\titemDef.name = \"Dagon' hai robe\";\n\t\t\titemDef.description = \"An elite dark mages robe.\";\n\t\t\titemDef.modelId = 60321;\n\t\t\titemDef.maleModel = 60320;\n\t\t\titemDef.femaleModel = 60320;\n\t\t\titemDef.anInt188 = -1;\n\t\t\titemDef.anInt164 = -1;\n\t\t\titemDef.modelZoom = 2216;\n\t\t\titemDef.modelRotation1 = 572;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 14;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33161:\n\t\t\titemDef.name = \"Blue infernal cape mix\";\n\t\t\titemDef.description = \"Changes the color of the Infernal Cape to Blue.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33162:\n\t\t\titemDef.name = \"Green infernal cape mix\";\n\t\t\titemDef.description = \"Changes the color of the Infernal Cape to Green.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33163:\n\t\t\titemDef.name = \"Purple infernal cape mix\";\n\t\t\titemDef.description = \"Changes the color of the Infernal Cape to Purple.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33164:\n\t\t\titemDef.name = \"Purple firecape mix\";\n\t\t\titemDef.description = \"Changes the color of the firecape to purple.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33165:\n\t\t\titemDef.name = \"Cyan firecape mix\";\n\t\t\titemDef.description = \"Changes the color of the firecape to cyan.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33166:\n\t\t\titemDef.name = \"Green firecape mix\";\n\t\t\titemDef.description = \"Changes the color of the firecape to green.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33167:\n\t\t\titemDef.name = \"Red firecape mix\";\n\t\t\titemDef.description = \"Changes the color of the firecape to red.\";\n\t\t\titemDef.modelId = 8956;\n\t\t\titemDef.modelZoom = 842;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Use\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33169:\n\t\t\titemDef.name = \"K'ril robe top\";\n\t\t\titemDef.description = \"A top worn by magic-using followers of Zamorak.\";\n\t\t\titemDef.modelId = 62558;\n\t\t\titemDef.maleModel = 62559;\n\t\t\titemDef.femaleModel = 62559;\n\t\t\titemDef.modelZoom = 1358;\n\t\t\titemDef.modelRotation1 = 514;\n\t\t\titemDef.modelRotation2 = 2041;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33170:\n\t\t\titemDef.name = \"K'ril robe bottom\";\n\t\t\titemDef.description = \"A robe worn by magic-using followers of Zamorak.\";\n\t\t\titemDef.modelId = 62553;\n\t\t\titemDef.maleModel = 62554;\n\t\t\titemDef.femaleModel = 62554;\n\t\t\titemDef.modelZoom = 1690;\n\t\t\titemDef.modelRotation1 = 435;\n\t\t\titemDef.modelRotation2 = 9;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 7;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33171:\n\t\t\titemDef.name = \"K'ril hat\";\n\t\t\titemDef.description = \"A hat worn by magic-using followers of Zamorak.\";\n\t\t\titemDef.modelId = 62551;\n\t\t\titemDef.maleModel = 62552;\n\t\t\titemDef.femaleModel = 62552;\n\t\t\titemDef.modelZoom = 1236;\n\t\t\titemDef.modelRotation1 = 118;\n\t\t\titemDef.modelRotation2 = 10;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -12;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33172:\n\t\t\titemDef.name = \"K'ril swords\";\n\t\t\titemDef.description = \"Sheath & Unsheath this sword in the Equipment tab. Hits an enemy twice.\";\n\t\t\titemDef.equipActions[2] = \"Sheath\";\n\t\t\titemDef.modelId = 62556;\n\t\t\titemDef.maleModel = 62557;\n\t\t\titemDef.femaleModel = 62557;\n\t\t\titemDef.modelZoom = 1650;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 1300;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33173:\n\t\t\titemDef.name = \"K'ril swords (sheathed)\";\n\t\t\titemDef.description = \"Sheath & Unsheath this sword in the Equipment tab. Hits an enemy twice.\";\n\t\t\titemDef.equipActions[2] = \"Unsheath\";\n\t\t\titemDef.modelId = 62556;\n\t\t\titemDef.maleModel = 62556;\n\t\t\titemDef.femaleModel = 62556;\n\t\t\titemDef.modelZoom = 1650;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 1300;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33174:\n\t\t\titemDef.name = \"Pet demonic gorilla\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 31241;\n\t\t\titemDef.modelZoom = 16000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33175:\n\t\t\titemDef.name = \"Pet crawling hand\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5071;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33176:\n\t\t\titemDef.name = \"Pet cave bug\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 23854;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33177:\n\t\t\titemDef.name = \"Pet cave crawler\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5066;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33178:\n\t\t\titemDef.name = \"Pet banshee\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5063;\n\t\t\titemDef.modelZoom = 3200;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33179:\n\t\t\titemDef.name = \"Pet cave slime\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5786;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33180:\n\t\t\titemDef.name = \"Pet rockslug\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5084;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33181:\n\t\t\titemDef.name = \"Pet cockatrice\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5070;\n\t\t\titemDef.modelZoom = 3200;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33182:\n\t\t\titemDef.name = \"Pet pyrefiend\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5083;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33183:\n\t\t\titemDef.name = \"Pet basilisk\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5064;\n\t\t\titemDef.modelZoom = 3000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33184:\n\t\t\titemDef.name = \"Pet infernal mage\";\n\t\t\titemDef.modifiedModelColors = new int[] { -26527, -24618, -25152, -25491, 119 };\n\t\t\titemDef.originalModelColors = new int[] { 924, 148, 0, 924, 924 };\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5047;\n\t\t\titemDef.modelZoom = 3940;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 84;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33185:\n\t\t\titemDef.name = \"Pet bloodveld\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5065;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33186:\n\t\t\titemDef.name = \"Pet jelly\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5081;\n\t\t\titemDef.modelZoom = 3000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33187:\n\t\t\titemDef.name = \"Pet turoth\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5086;\n\t\t\titemDef.modelZoom = 2600;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33188:\n\t\t\titemDef.name = \"Pet aberrant spectre\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5085;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 450;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33189:\n\t\t\titemDef.name = \"Pet dust devil\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5076;\n\t\t\titemDef.modelZoom = 3000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33190:\n\t\t\titemDef.name = \"Pet kurask\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5082;\n\t\t\titemDef.modelZoom = 5000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33191:\n\t\t\titemDef.name = \"Pet skeletal wyvern\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 10350;\n\t\t\titemDef.modelZoom = 1104;\n\t\t\titemDef.modelRotation1 = 27;\n\t\t\titemDef.modelRotation2 = 1634;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33192:\n\t\t\titemDef.name = \"Pet garygoyle\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5078;\n\t\t\titemDef.modelZoom = 4000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33193:\n\t\t\titemDef.name = \"Pet nechryael\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5074;\n\t\t\titemDef.modelZoom = 4000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33194:\n\t\t\titemDef.name = \"Pet abyssal demon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 5062;\n\t\t\titemDef.modelZoom = 5000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33195:\n\t\t\titemDef.name = \"Pet dark beast\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 26395;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33196:\n\t\t\titemDef.name = \"Pet night beast\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32933;\n\t\t\titemDef.modelZoom = 7000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33197:\n\t\t\titemDef.name = \"Pet greater abyssal demon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32921;\n\t\t\titemDef.modelZoom = 5000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33198:\n\t\t\titemDef.name = \"Pet crushing hand\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32922;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33199:\n\t\t\titemDef.name = \"Pet chasm crawler\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32918;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33200:\n\t\t\titemDef.name = \"Pet screaming banshee\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32823;\n\t\t\titemDef.modelZoom = 5500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33201:\n\t\t\titemDef.name = \"Pet twisted banshee\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32847;\n\t\t\titemDef.modelZoom = 5500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33202:\n\t\t\titemDef.name = \"Pet giant rockslug\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32919;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33203:\n\t\t\titemDef.name = \"Pet cockathrice\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32920;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33204:\n\t\t\titemDef.name = \"Pet flaming pyrelord\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32923;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33205:\n\t\t\titemDef.name = \"Pet monstrous basilisk\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32924;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33206:\n\t\t\titemDef.name = \"Pet malevolent mage\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32929;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33207:\n\t\t\titemDef.name = \"Pet insatiable bloodveld\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32926;\n\t\t\titemDef.modelZoom = 5000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33208:\n\t\t\titemDef.name = \"Pet insatiable mutated bloodveld\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32925;\n\t\t\titemDef.modelZoom = 5000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33209:\n\t\t\titemDef.name = \"Pet vitreous jelly\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32852;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33210:\n\t\t\titemDef.name = \"Pet vitreous warped jelly\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32917;\n\t\t\titemDef.modelZoom = 6000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33211:\n\t\t\titemDef.name = \"Pet cave abomination\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32935;\n\t\t\titemDef.modelZoom = 5500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33212:\n\t\t\titemDef.name = \"Pet abhorrent spectre\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32930;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33213:\n\t\t\titemDef.name = \"pet repugnant spectre\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32926;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33214:\n\t\t\titemDef.name = \"Pet choke devil\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32927;\n\t\t\titemDef.modelZoom = 6000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33215:\n\t\t\titemDef.name = \"Pet king kurask\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32934;\n\t\t\titemDef.modelZoom = 8000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33217:\n\t\t\titemDef.name = \"Pet nuclear smoke devil\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32928;\n\t\t\titemDef.modelZoom = 5500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33218:\n\t\t\titemDef.name = \"Pet marble gargoyle\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34251;\n\t\t\titemDef.modelZoom = 8000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33219:\n\t\t\titemDef.name = \"Pet nechryarch\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32932;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33220:\n\t\t\titemDef.name = \"Pet Patrity\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32035;\n\t\t\titemDef.modelZoom = 653;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1535;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33221:\n\t\t\titemDef.name = \"Pet xarpus\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35383;\n\t\t\titemDef.modelZoom = 14000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33222:\n\t\t\titemDef.name = \"Pet nyclocas vasilias\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35182;\n\t\t\titemDef.modelZoom = 12000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33223:\n\t\t\titemDef.name = \"Pet pestilent bloat\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35404;\n\t\t\titemDef.modelZoom = 8500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33224:\n\t\t\titemDef.name = \"Pet maiden of sugadinti\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35385;\n\t\t\titemDef.modelZoom = 8500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33225:\n\t\t\titemDef.name = \"Pet lizardman shaman\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 4039;\n\t\t\titemDef.modelZoom = 8500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33226:\n\t\t\titemDef.name = \"Pet abyssal sire\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 29477;\n\t\t\titemDef.modelZoom = 9000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33227:\n\t\t\titemDef.name = \"Pet black demon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 31984;\n\t\t\titemDef.modelZoom = 1104;\n\t\t\titemDef.modelRotation1 = 144;\n\t\t\titemDef.modelRotation2 = 1826;\n\t\t\titemDef.modelOffset1 = 7;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 11802:\n\t\tcase 11804:\n\t\tcase 11806:\n\t\tcase 11808:\n\t\t\titemDef.equipActions[2] = \"Sheath\";\n\t\t\tbreak;// godsword sheathing operating\n\n\t\tcase 33228:\n\t\t\titemDef.name = \"Pet greater demon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32015;\n\t\t\titemDef.modelZoom = 902;\n\t\t\titemDef.modelRotation1 = 216;\n\t\t\titemDef.modelRotation2 = 138;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = -16;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33229:\n\t\t\titemDef.name = \"Armadyl godsword (sheathed)\";\n\t\t\titemDef.description = \"Armadyl godsword (sheathed)\";\n\t\t\titemDef.equipActions[2] = \"Unsheath\";\n\t\t\titemDef.modelId = 28075;\n\t\t\titemDef.maleModel = 62683;\n\t\t\titemDef.femaleModel = 62683;\n\t\t\titemDef.modelZoom = 1957;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 494;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33230:\n\t\t\titemDef.name = \"Bandos godsword (sheathed)\";\n\t\t\titemDef.description = \"Bandos godsword (sheathed)\";\n\t\t\titemDef.equipActions[2] = \"Unsheath\";\n\t\t\titemDef.modelId = 28059;\n\t\t\titemDef.maleModel = 62684;\n\t\t\titemDef.femaleModel = 62684;\n\t\t\titemDef.modelZoom = 1957;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 494;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33231:\n\t\t\titemDef.name = \"Saradomin godsword (sheathed)\";\n\t\t\titemDef.description = \"Saradomin godsword (sheathed)\";\n\t\t\titemDef.equipActions[2] = \"Unsheath\";\n\t\t\titemDef.modelId = 28070;\n\t\t\titemDef.maleModel = 62685;\n\t\t\titemDef.femaleModel = 62685;\n\t\t\titemDef.modelZoom = 1957;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 494;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33232:\n\t\t\titemDef.name = \"Zamorak godsword (sheathed)\";\n\t\t\titemDef.description = \"Zamorak godsword (sheathed)\";\n\t\t\titemDef.equipActions[2] = \"Unsheath\";\n\t\t\titemDef.modelId = 28060;\n\t\t\titemDef.maleModel = 62686;\n\t\t\titemDef.femaleModel = 62686;\n\t\t\titemDef.modelZoom = 1957;\n\t\t\titemDef.modelRotation1 = 498;\n\t\t\titemDef.modelRotation2 = 494;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33233:\n\t\t\titemDef.name = \"Pet revenant imp\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34156;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33234:\n\t\t\titemDef.name = \"Pet revenant goblin\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34262;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33235:\n\t\t\titemDef.name = \"Pet revenant pyrefiend\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34142;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33236:\n\t\t\titemDef.name = \"Pet revenant hobgoblin\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34157;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33237:\n\t\t\titemDef.name = \"Pet revenant cyclops\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34155;\n\t\t\titemDef.modelZoom = 4500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33238:\n\t\t\titemDef.name = \"Pet revenant hellhound\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34143;\n\t\t\titemDef.modelZoom = 3500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33239:\n\t\t\titemDef.name = \"Pet revenant demon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32015;\n\t\t\titemDef.modifiedModelColors = new int[] { 1690, 910, 912, 1814, 1938 };\n\t\t\titemDef.originalModelColors = new int[] { 43078, 43078, 43078, 43078, 43078, 43078 };\n\t\t\titemDef.modelZoom = 902;\n\t\t\titemDef.modelRotation1 = 216;\n\t\t\titemDef.modelRotation2 = 138;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = -16;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33240:\n\t\t\titemDef.name = \"Pet revenant ork\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34154;\n\t\t\titemDef.modelZoom = 3500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33242:\n\t\t\titemDef.name = \"Pet revenant dark beast\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34158;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33243:\n\t\t\titemDef.name = \"Pet revenant knight\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34145;\n\t\t\titemDef.modelZoom = 3000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33244:\n\t\t\titemDef.name = \"Pet revenant dragon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34163;\n\t\t\titemDef.modelZoom = 7500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33245:\n\t\t\titemDef.name = \"Pet glob\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 26074;\n\t\t\titemDef.modelZoom = 10000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33246:\n\t\t\titemDef.name = \"Pet ice queen\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 104;\n\t\t\titemDef.modifiedModelColors = new int[] { 41, 61, 4550, 12224, 25238, 6798 };\n\t\t\titemDef.originalModelColors = new int[] { -22052, -26150, -24343, -22052, -22052, -23327 };\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33247:\n\t\t\titemDef.name = \"Pet enraged tarn\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60322;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33248:\n\t\t\titemDef.name = \"Pet jaltok-jad\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 33012;\n\t\t\titemDef.modelZoom = 12000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33249:\n\t\t\titemDef.name = \"Pet rune dragon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 34668;\n\t\t\titemDef.modelZoom = 2541;\n\t\t\titemDef.modelRotation1 = 83;\n\t\t\titemDef.modelRotation2 = 1826;\n\t\t\titemDef.modelOffset1 = -97;\n\t\t\titemDef.modelOffset2 = 9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33271:\n\t\t\titemDef.name = \"Moo\";\n\t\t\titemDef.description = \"cow goes moo.\";\n\t\t\titemDef.modelId = 23889;\n\t\t\titemDef.modelZoom = 2541;\n\t\t\titemDef.modelRotation1 = 83;\n\t\t\titemDef.modelRotation2 = 1826;\n\t\t\titemDef.modelOffset1 = -97;\n\t\t\titemDef.modelOffset2 = 9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33250:\n\t\t\titemDef.name = \"Swift gloves (Black)\";\n\t\t\titemDef.description = \"Watch my speedy hands!\";\n\t\t\titemDef.modelId = 62655;\n\t\t\titemDef.maleModel = 62657;\n\t\t\titemDef.femaleModel = 62658;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33251:\n\t\t\titemDef.name = \"Swift gloves (Red)\";\n\t\t\titemDef.description = \"Watch my speedy hands!\";\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 65046, 65051, 65056 };\n\t\t\titemDef.modelId = 62655;\n\t\t\titemDef.maleModel = 62659;\n\t\t\titemDef.femaleModel = 62660;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33252:\n\t\t\titemDef.name = \"Swift gloves (White)\";\n\t\t\titemDef.description = \"Watch my speedy hands!\";\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 64585, 64590, 64595 };\n\t\t\titemDef.modelId = 62655;\n\t\t\titemDef.maleModel = 62661;\n\t\t\titemDef.femaleModel = 62662;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33253:\n\t\t\titemDef.name = \"Swift gloves (Yellow)\";\n\t\t\titemDef.description = \"Watch my speedy hands!\";\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 9767, 9772, 9777 };\n\t\t\titemDef.modelId = 62655;\n\t\t\titemDef.maleModel = 62663;\n\t\t\titemDef.femaleModel = 62664;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33254:\n\t\t\titemDef.name = \"Spellcaster gloves (Black)\";\n\t\t\titemDef.description = \"\tSome pretty fantastical gloves.\";\n\t\t\titemDef.modelId = 62656;\n\t\t\titemDef.maleModel = 62665;\n\t\t\titemDef.femaleModel = 62666;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33255:\n\t\t\titemDef.name = \"Spellcaster gloves (Red)\";\n\t\t\titemDef.description = \"\tSome pretty fantastical gloves.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 65046, 65051, 65056 };\n\t\t\titemDef.modelId = 62656;\n\t\t\titemDef.maleModel = 62667;\n\t\t\titemDef.femaleModel = 62668;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33256:\n\t\t\titemDef.name = \"Spellcaster gloves (White)\";\n\t\t\titemDef.description = \"\tSome pretty fantastical gloves.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 64585, 64590, 64595 };\n\t\t\titemDef.modelId = 62656;\n\t\t\titemDef.maleModel = 62669;\n\t\t\titemDef.femaleModel = 62670;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33257:\n\t\t\titemDef.name = \"Spellcaster gloves (Yellow)\";\n\t\t\titemDef.description = \"\tSome pretty fantastical gloves.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 10, 15, 20 };\n\t\t\titemDef.originalModelColors = new int[] { 9767, 9772, 9777 };\n\t\t\titemDef.modelId = 62656;\n\t\t\titemDef.maleModel = 62671;\n\t\t\titemDef.femaleModel = 62672;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33258:\n\t\t\titemDef.name = \"Tekton longsword\";\n\t\t\titemDef.description = \"Tekton longsword.\";\n\t\t\titemDef.modelId = 62682;\n\t\t\titemDef.maleModel = 62681;\n\t\t\titemDef.femaleModel = 62681;\n\t\t\titemDef.modelZoom = 1445;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33259:\n\t\t\titemDef.name = \"Pet wyrm\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 36922;\n\t\t\titemDef.modelZoom = 2547;\n\t\t\titemDef.modelRotation1 = 97;\n\t\t\titemDef.modelRotation2 = 1820;\n\t\t\titemDef.modelOffset1 = -7;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33260:\n\t\t\titemDef.name = \"Pet drake\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 36160;\n\t\t\titemDef.modelZoom = 6500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33261:\n\t\t\titemDef.name = \"Pet wyrm\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 36922;\n\t\t\titemDef.modelZoom = 2547;\n\t\t\titemDef.modelRotation1 = 97;\n\t\t\titemDef.modelRotation2 = 1820;\n\t\t\titemDef.modelOffset1 = -7;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33262:\n\t\t\titemDef.name = \"Valentines Balloon\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 62766;\n\t\t\titemDef.maleModel = 62767;\n\t\t\titemDef.femaleModel = 62767;\n\t\t\titemDef.modelZoom = 2200;\n\t\t\titemDef.modelRotation1 = 270;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33263:\n\t\t\titemDef.name = \"Cupid bow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 62768;\n\t\t\titemDef.maleModel = 62769;\n\t\t\titemDef.femaleModel = 62769;\n\t\t\titemDef.modelZoom = 1072;\n\t\t\titemDef.modelRotation1 = 127;\n\t\t\titemDef.modelRotation2 = 103;\n\t\t\titemDef.modelOffset1 = -5;\n\t\t\titemDef.modelOffset2 = 2;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33264:\n\t\t\titemDef.name = \"Halo and horns\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 62771;\n\t\t\titemDef.maleModel = 62770;\n\t\t\titemDef.femaleModel = 62770;\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation1 = 228;\n\t\t\titemDef.modelRotation2 = 141;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33265:\n\t\t\titemDef.name = \"Heart\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 62782;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33266:\n\t\t\titemDef.name = \"Valentines mystery box\";\n\t\t\titemDef.description = \"You make me hard.\";\n\t\t\titemDef.modelId = 62773;\n\t\t\titemDef.modelZoom = 464;\n\t\t\titemDef.modelRotation1 = 423;\n\t\t\titemDef.modelRotation2 = 1928;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Open\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33267:\n\t\t\titemDef.name = \"Staff of adoration\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 62774;\n\t\t\titemDef.maleModel = 62775;\n\t\t\titemDef.femaleModel = 62775;\n\t\t\titemDef.modelZoom = 1579;\n\t\t\titemDef.modelRotation1 = 660;\n\t\t\titemDef.modelRotation2 = 48;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33268:\n\t\t\titemDef.name = \"Valentines crossbow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 62778;\n\t\t\titemDef.maleModel = 62779;\n\t\t\titemDef.femaleModel = 62779;\n\t\t\titemDef.modelZoom = 1200;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 258;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33269:\n\t\t\titemDef.name = \"Onyxia Mystery Box\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 2426;\n\t\t\titemDef.modelZoom = 1180;\n\t\t\titemDef.modelRotation1 = 160;\n\t\t\titemDef.modelRotation2 = 172;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -14;\n\t\t\titemDef.modifiedModelColors = new int[] { 22410, 2999 };\n\t\t\titemDef.originalModelColors = new int[] { 2130, 38693 };\n\t\t\titemDef.description = \"Chances at several unqiue items found only in this box! (ex: Tekton Armor)\";\n\t\t\tbreak;\n\t\tcase 33270:\n\t\t\titemDef.name = \"Dragon Hunter Box\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 2426;\n\t\t\titemDef.modelZoom = 1180;\n\t\t\titemDef.modelRotation1 = 160;\n\t\t\titemDef.modelRotation2 = 172;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -14;\n\t\t\titemDef.modifiedModelColors = new int[] { 22410, 2999 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 1050 };\n\t\t\titemDef.description = \"Chances for items that give bonuses toward dragons. (ex: Dragonhunter Lance)\";\n\t\t\tbreak;\n\t\tcase 33273:\n\t\t\titemDef.name = \"Ancient sword\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60201;\n\t\t\titemDef.maleModel = 60200;\n\t\t\titemDef.femaleModel = 60200;\n\t\t\titemDef.modelZoom = 1900;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33274:\n\t\t\titemDef.name = \"Armadyl staff\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60203;\n\t\t\titemDef.maleModel = 60202;\n\t\t\titemDef.femaleModel = 60202;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33275:\n\t\t\titemDef.name = \"Bork axe\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60205;\n\t\t\titemDef.maleModel = 60204;\n\t\t\titemDef.femaleModel = 60204;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33276:\n\t\t\titemDef.name = \"Bree bow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60207;\n\t\t\titemDef.maleModel = 60206;\n\t\t\titemDef.femaleModel = 60206;\n\t\t\titemDef.modelZoom = 1700;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33277:\n\t\t\titemDef.name = \"Infernal staff\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60209;\n\t\t\titemDef.maleModel = 60208;\n\t\t\titemDef.femaleModel = 60208;\n\t\t\titemDef.modelZoom = 2200;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33278:\n\t\t\titemDef.name = \"Infernal longsword\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60211;\n\t\t\titemDef.maleModel = 60210;\n\t\t\titemDef.femaleModel = 60210;\n\t\t\titemDef.modelZoom = 1900;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33279:\n\t\t\titemDef.name = \"Necrolord staff\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60213;\n\t\t\titemDef.maleModel = 60212;\n\t\t\titemDef.femaleModel = 60212;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33280:\n\t\t\titemDef.name = \"Insert name here\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60215;\n\t\t\titemDef.maleModel = 60214;\n\t\t\titemDef.femaleModel = 60214;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33281:\n\t\t\titemDef.name = \"Infernal bow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60219;\n\t\t\titemDef.maleModel = 60218;\n\t\t\titemDef.femaleModel = 60218;\n\t\t\titemDef.modelZoom = 3334;\n\t\t\titemDef.modelRotation1 = 533;\n\t\t\titemDef.modelRotation2 = 1294;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33282:\n\t\t\titemDef.name = \"Infernal warhammer\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60221;\n\t\t\titemDef.maleModel = 60220;\n\t\t\titemDef.femaleModel = 60220;\n\t\t\titemDef.modelZoom = 2512;\n\t\t\titemDef.modelRotation1 = 317;\n\t\t\titemDef.modelRotation2 = 1988;\n\t\t\titemDef.modelOffset1 = -8;\n\t\t\titemDef.modelOffset2 = 45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33283:\n\t\t\titemDef.name = \"Imbued Porazdir's heart\";\n\t\t\titemDef.modelId = 32298;\n\t\t\titemDef.modelZoom = 1168;\n\t\t\titemDef.modelRotation1 = 96;\n\t\t\titemDef.modelRotation2 = 1690;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 60826, 59796, 54544, 58904, 54561 };\n\t\t\titemDef.originalModelColors = new int[] { 13263, 13014, 13243, 13000, 13275 };\n\t\t\titemDef.inventoryOptions = new String[] { \"Invigorate\", null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Boosts your strength for a period of time.\";\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33284:\n\t\t\titemDef.name = \"Imbued Justiciar's heart\";\n\t\t\titemDef.modelId = 32298;\n\t\t\titemDef.modelZoom = 1168;\n\t\t\titemDef.modelRotation1 = 96;\n\t\t\titemDef.modelRotation2 = 1690;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 60826, 59796, 54544, 58904, 54561 };\n\t\t\titemDef.originalModelColors = new int[] { 31661, 31418, 31661, 31167, 31445 };\n\t\t\titemDef.inventoryOptions = new String[] { \"Invigorate\", null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Boosts your Defence for a period of time.\";\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32285:\n\t\t\titemDef.name = \"Imbued Derwen's heart\";\n\t\t\titemDef.modelId = 32298;\n\t\t\titemDef.modelZoom = 1168;\n\t\t\titemDef.modelRotation1 = 96;\n\t\t\titemDef.modelRotation2 = 1690;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 60826, 59796, 54544, 58904, 54561 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 930, 936, 940, 950 };\n\t\t\titemDef.inventoryOptions = new String[] { \"Invigorate\", null, null, null, \"Drop\" };\n\t\t\titemDef.description = \"Boosts your Attack for a period of time.\";\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32286:\n\t\t\titemDef.name = \"Bronze fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 5652, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32287:\n\t\t\titemDef.name = \"Iron fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 33, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32288:\n\t\t\titemDef.name = \"Steel fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 61, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32289:\n\t\t\titemDef.name = \"Black fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 0, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32290:\n\t\t\titemDef.name = \"Mithril fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 43297, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32291:\n\t\t\titemDef.name = \"Adamant fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 21662, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32292:\n\t\t\titemDef.name = \"Rune fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 36133, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32293:\n\t\t\titemDef.name = \"Dragon fishing rod\";\n\t\t\titemDef.description = \"Used for Bait and Fly fishing. Can also be used for Deep sea fishing.\";\n\t\t\titemDef.modelId = 36128;\n\t\t\titemDef.maleModel = 36317;\n\t\t\titemDef.femaleModel = 36312;\n\t\t\titemDef.modelZoom = 1853;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 27;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.modifiedModelColors = new int[] { 59499, 24 };\n\t\t\titemDef.originalModelColors = new int[] { 924, 9152 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32294:\n\t\t\titemDef.name = \"Raw eel\";\n\t\t\titemDef.description = \"Slimy\";\n\t\t\titemDef.modelId = 6856;\n\t\t\titemDef.modelZoom = 1440;\n\t\t\titemDef.modelRotation1 = 296;\n\t\t\titemDef.modelRotation2 = 352;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = 42;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32295:\n\t\t\titemDef.name = \"Burnt eel\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 6856;\n\t\t\titemDef.modelZoom = 1440;\n\t\t\titemDef.modelRotation1 = 296;\n\t\t\titemDef.modelRotation2 = 352;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = 42;\n\t\t\titemDef.modifiedModelColors = new int[] { 8485, 14622, 12589 };\n\t\t\titemDef.originalModelColors = new int[] { 8724, 3226, 9754 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32296:\n\t\t\titemDef.name = \"Eel\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Eat\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 6856;\n\t\t\titemDef.modelZoom = 1440;\n\t\t\titemDef.modelRotation1 = 296;\n\t\t\titemDef.modelRotation2 = 352;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = 42;\n\t\t\titemDef.modifiedModelColors = new int[] { 8485, 14622, 8386, 12589 };\n\t\t\titemDef.originalModelColors = new int[] { 8088, 6032, 57, 2960 };\n\t\t\titemDef.description = \"None\";\n\t\t\tbreak;\n\n\t\tcase 32297:\n\t\t\titemDef.name = \"Raw baron shark\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 2594;\n\t\t\titemDef.modelZoom = 1860;\n\t\t\titemDef.modelRotation1 = 344;\n\t\t\titemDef.modelRotation2 = 12;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 12;\n\t\t\titemDef.modifiedModelColors = new int[] { 103, 103 };\n\t\t\titemDef.originalModelColors = new int[] { 7756, 5349 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32298:\n\t\t\titemDef.name = \"Burnt baron shark\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 2594;\n\t\t\titemDef.modelZoom = 1860;\n\t\t\titemDef.modelRotation1 = 344;\n\t\t\titemDef.modelRotation2 = 12;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 12;\n\t\t\titemDef.modifiedModelColors = new int[] { 61, 103 };\n\t\t\titemDef.originalModelColors = new int[] { 28, 41 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32299:\n\t\t\titemDef.name = \"Baron shark\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Eat\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 2594;\n\t\t\titemDef.modelZoom = 1860;\n\t\t\titemDef.modelRotation1 = 344;\n\t\t\titemDef.modelRotation2 = 12;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 12;\n\t\t\titemDef.modifiedModelColors = new int[] { 61, 103 };\n\t\t\titemDef.originalModelColors = new int[] { 8109, 4795 };\n\t\t\titemDef.description = \"None\";\n\t\t\tbreak;\n\n\t\tcase 32300:\n\t\t\titemDef.name = \"Raw cavefish\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60223;\n\t\t\titemDef.modelZoom = 1284;\n\t\t\titemDef.modelRotation1 = 499;\n\t\t\titemDef.modelRotation2 = 1907;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32301:\n\t\t\titemDef.name = \"Burnt cavefish\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60227;\n\t\t\titemDef.modelZoom = 1284;\n\t\t\titemDef.modelRotation1 = 499;\n\t\t\titemDef.modelRotation2 = 1907;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 32302:\n\t\t\titemDef.name = \"Cavefish\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Eat\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 60228;\n\t\t\titemDef.modelZoom = 1284;\n\t\t\titemDef.modelRotation1 = 499;\n\t\t\titemDef.modelRotation2 = 1907;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.description = \"None\";\n\t\t\tbreak;\n\n\t\tcase 32303:\n\t\t\titemDef.name = \"Dragonfire visage (e)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 26456;\n\t\t\titemDef.modelZoom = 1697;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 152;\n\t\t\titemDef.modelOffset1 = -5;\n\t\t\titemDef.modelOffset2 = -5;\n\t\t\titemDef.modifiedModelColors = new int[] { 45, 41, 33, 24, 20, 57, 22, 37 };\n\t\t\titemDef.originalModelColors = new int[] { 0, 1, 2, 3, 4, 5, 6, 7 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33285:\n\t\t\titemDef.name = \"Easter Mystery Box\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 61110;\n\t\t\titemDef.modelZoom = 1180;\n\t\t\titemDef.modelRotation1 = 160;\n\t\t\titemDef.modelRotation2 = 172;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -14;\n\t\t\t// itemDef.modifiedModelColors = new int[] {22410, 2999};\n\t\t\t// itemDef.originalModelColors = new int[] {35321, 350};\n\t\t\titemDef.description = \"Chances for all sorts of Easter Items!\";\n\t\t\tbreak;\n\n\t\tcase 33286:\n\t\t\titemDef.name = \"Easter Cape\";\n\t\t\titemDef.inventoryOptions = new String[] { null, \"wear\", null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 9631;\n\t\t\titemDef.maleModel = 9638;\n\t\t\titemDef.femaleModel = 9640;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"An Easter Cape.\";\n\t\t\tbreak;\n\n\t\tcase 33287:\n\t\t\titemDef.name = \"Pet Easter Bunny\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 37239;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"You've captured the Easter bunny!\";\n\t\t\tbreak;\n\n\t\tcase 33288:\n\t\t\titemDef.name = \"Pet Choco\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 37239;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"mmm... a chocolate bunny\";\n\t\t\titemDef.modifiedModelColors = new int[] { 2378 };\n\t\t\titemDef.originalModelColors = new int[] { 7079 };\n\t\t\tbreak;\n\n\t\tcase 33289:\n\t\t\titemDef.name = \"Pet Milkie\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 37239;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"mmm... a chocolate bunny\";\n\t\t\titemDef.modifiedModelColors = new int[] { 2378 };\n\t\t\titemDef.originalModelColors = new int[] { 6040 };\n\t\t\tbreak;\n\n\t\tcase 33290:\n\t\t\titemDef.name = \"Pet Goldie\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 37239;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"oh wow... a rare golden bunny!\";\n\t\t\titemDef.modifiedModelColors = new int[] { 2378 };\n\t\t\titemDef.originalModelColors = new int[] { 9152 };\n\t\t\tbreak;\n\n\t\tcase 33291:\n\t\t\titemDef.name = \"Pet Blue\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 37239;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"A blue bunny... kinda looks like the easter bunny!\";\n\t\t\titemDef.modifiedModelColors = new int[] { 2378 };\n\t\t\titemDef.originalModelColors = new int[] { 35321 };\n\t\t\tbreak;\n\n\t\tcase 33292:\n\t\t\titemDef.name = \"Crazed bunny\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 23901;\n\t\t\titemDef.modelZoom = 500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"What a bloody mess...\";\n\t\t\titemDef.modifiedModelColors = new int[] { 5413, 5417, 5421 };\n\t\t\titemDef.originalModelColors = new int[] { 935, 111, 127 };\n\t\t\tbreak;\n\n\t\tcase 33293:\n\t\t\titemDef.name = \"Peter Rabbit\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 28602;\n\t\t\titemDef.modelZoom = 500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1931;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"Hi Peter!\";\n\t\t\tbreak;\n\n\t\tcase 33294:\n\t\t\titemDef.name = \"Chocolate Chicken\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 35150;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1731;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"a chocolate chicken\";\n\t\t\titemDef.modifiedModelColors = new int[] { 947 };\n\t\t\titemDef.originalModelColors = new int[] { 8128 };\n\t\t\tbreak;\n\n\t\tcase 33295:\n\t\t\titemDef.name = \"Chocolate Chicken\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 35150;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1731;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"a chocolate chicken\";\n\t\t\titemDef.modifiedModelColors = new int[] { 947, 8301 };\n\t\t\titemDef.originalModelColors = new int[] { 8128, 25511 };\n\t\t\tbreak;\n\n\t\tcase 33296:\n\t\t\titemDef.name = \"Chocolate Chicken\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 35150;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1731;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"a chocolate chicken\";\n\t\t\titemDef.modifiedModelColors = new int[] { 947, 8301 };\n\t\t\titemDef.originalModelColors = new int[] { 8128, 38835 };\n\t\t\tbreak;\n\n\t\tcase 33297:\n\t\t\titemDef.name = \"Chocolate Chicken\";\n\t\t\titemDef.inventoryOptions = new String[] { null, null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 35150;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 1731;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.description = \"a chocolate chicken\";\n\t\t\titemDef.modifiedModelColors = new int[] { 947, 8301 };\n\t\t\titemDef.originalModelColors = new int[] { 8128, 947 };\n\t\t\tbreak;\n\n\t\tcase 33305:\n\t\t\titemDef.name = \"$10 bond\";\n\t\t\titemDef.description = \"$10 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 84, 84, 84, 84, 84, 84, 84 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33306:\n\t\t\titemDef.name = \"$25 bond\";\n\t\t\titemDef.description = \"$25 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 87, 87, 87, 87, 87, 87, 87 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33307:\n\t\t\titemDef.name = \"$50 bond\";\n\t\t\titemDef.description = \"$50 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 65, 65, 65, 65, 65, 65, 65 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33308:\n\t\t\titemDef.name = \"$100 bond\";\n\t\t\titemDef.description = \"$25 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 75, 75, 75, 75, 75, 75, 75 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33309:\n\t\t\titemDef.name = \"$200 bond\";\n\t\t\titemDef.description = \"$200 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 88, 88, 88, 88, 88, 88, 88 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33310:\n\t\t\titemDef.name = \"$500 bond\";\n\t\t\titemDef.description = \"$500 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 85, 85, 85, 85, 85, 85, 85 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33311:\n\t\t\titemDef.name = \"$1000 bond\";\n\t\t\titemDef.description = \"$1000 bond.\";\n\t\t\titemDef.modelId = 29210;\n\t\t\titemDef.modelZoom = 2300;\n\t\t\titemDef.modelRotation1 = 512;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.modifiedTextureColors = new int[] { 86, 86, 86, 86, 86, 86, 86 };\n\t\t\titemDef.originalTextureColors = new int[] { 22451, 20416, 22181, 22449, 22305, 21435, 22464 };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[0] = \"Redeem\";\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33312:\n\t\t\titemDef.name = \"Armadyl battlestaff\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60332;\n\t\t\titemDef.maleModel = 60333;\n\t\t\titemDef.femaleModel = 60333;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 225;\n\t\t\titemDef.modelRotation2 = 1994;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\n\t\tcase 33313:\n\t\t\titemDef.name = \"Colossal platebody\";\n\t\t\titemDef.description = \"Colossal platebody.\";\n\t\t\titemDef.modelId = 60323;\n\t\t\titemDef.maleModel = 60324;\n\t\t\titemDef.femaleModel = 60324;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33314:\n\t\t\titemDef.name = \"Colossal platelegs\";\n\t\t\titemDef.description = \"Colossal platelegs.\";\n\t\t\titemDef.modelId = 60325;\n\t\t\titemDef.maleModel = 60326;\n\t\t\titemDef.femaleModel = 60326;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33315:\n\t\t\titemDef.name = \"Colossal boots\";\n\t\t\titemDef.description = \"Colossal boots.\";\n\t\t\titemDef.modelId = 60329;\n\t\t\titemDef.maleModel = 60329;\n\t\t\titemDef.femaleModel = 60329;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33316:\n\t\t\titemDef.name = \"Colossal gloves\";\n\t\t\titemDef.description = \"Colossal gloves.\";\n\t\t\titemDef.modelId = 60330;\n\t\t\titemDef.maleModel = 60331;\n\t\t\titemDef.femaleModel = 60331;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33317:\n\t\t\titemDef.name = \"Colossal helmet\";\n\t\t\titemDef.description = \"Colossal helmet.\";\n\t\t\titemDef.modelId = 60327;\n\t\t\titemDef.maleModel = 60328;\n\t\t\titemDef.femaleModel = 60328;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\n\t\tcase 33318:\n\t\t\titemDef.name = \"Polypore staff\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60334;\n\t\t\titemDef.maleModel = 60335;\n\t\t\titemDef.femaleModel = 60335;\n\t\t\titemDef.modelZoom = 3750;\n\t\t\titemDef.modelRotation1 = 1454;\n\t\t\titemDef.modelRotation2 = 997;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\n\t\tcase 33319:\n\t\t\titemDef.name = \"Ganodermic platebody\";\n\t\t\titemDef.description = \"Ganodermic platebody.\";\n\t\t\titemDef.modelId = 60338;\n\t\t\titemDef.maleModel = 60339;\n\t\t\titemDef.femaleModel = 60339;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33320:\n\t\t\titemDef.name = \"Ganodermic platelegs\";\n\t\t\titemDef.description = \"Ganodermic platelegs.\";\n\t\t\titemDef.modelId = 60340;\n\t\t\titemDef.maleModel = 60341;\n\t\t\titemDef.femaleModel = 60341;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33321:\n\t\t\titemDef.name = \"Ganodermic helmet\";\n\t\t\titemDef.description = \"Ganodermic helmet.\";\n\t\t\titemDef.modelId = 60336;\n\t\t\titemDef.maleModel = 60337;\n\t\t\titemDef.femaleModel = 60337;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\n\t\tcase 33322:\n\t\t\titemDef.name = \"Grotesque platebody\";\n\t\t\titemDef.description = \"Grosteq platebody.\";\n\t\t\titemDef.modelId = 60347;\n\t\t\titemDef.maleModel = 60348;\n\t\t\titemDef.femaleModel = 60348;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33323:\n\t\t\titemDef.name = \"Grotesque platelegs\";\n\t\t\titemDef.description = \"Grosteq platelegs.\";\n\t\t\titemDef.modelId = 60349;\n\t\t\titemDef.maleModel = 60350;\n\t\t\titemDef.femaleModel = 60350;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33324:\n\t\t\titemDef.name = \"Grotesque helmet\";\n\t\t\titemDef.description = \"Grosteqc helmet.\";\n\t\t\titemDef.modelId = 60345;\n\t\t\titemDef.maleModel = 60346;\n\t\t\titemDef.femaleModel = 60346;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\n\t\tcase 33325:\n\t\t\titemDef.name = \"Grotesque cape\";\n\t\t\titemDef.description = \"Grosteq cape.\";\n\t\t\titemDef.modelId = 60351;\n\t\t\titemDef.maleModel = 60352;\n\t\t\titemDef.femaleModel = 60352;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33326:\n\t\t\titemDef.name = \"Stunning Hammer\";\n\t\t\titemDef.description = \"Has a chance to stun an enemy.\";\n\t\t\titemDef.modelId = 60353;\n\t\t\titemDef.maleModel = 60354;\n\t\t\titemDef.femaleModel = 60354;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1985;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\n\t\tcase 33327:\n\t\t\titemDef.name = \"Stunning Katagon platebody\";\n\t\t\titemDef.description = \"has a chance to stun an enemy.\";\n\t\t\titemDef.modelId = 60356;\n\t\t\titemDef.maleModel = 60357;\n\t\t\titemDef.femaleModel = 60357;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33328:\n\t\t\titemDef.name = \"Stunning Katagon platelegs\";\n\t\t\titemDef.description = \"has a chance to stun an enemy.\";\n\t\t\titemDef.modelId = 60358;\n\t\t\titemDef.maleModel = 60359;\n\t\t\titemDef.femaleModel = 60359;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33329:\n\t\t\titemDef.name = \"Stunning Katagon helmet\";\n\t\t\titemDef.description = \"has a chance to stun an enemy.\";\n\t\t\titemDef.modelId = 60360;\n\t\t\titemDef.maleModel = 60361;\n\t\t\titemDef.femaleModel = 60361;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\n\t\tcase 33331:\n\t\t\titemDef.name = \"Ancient platebody\";\n\t\t\titemDef.description = \"Ancient platebody.\";\n\t\t\titemDef.modelId = 60366;\n\t\t\titemDef.maleModel = 60367;\n\t\t\titemDef.femaleModel = 60367;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33332:\n\t\t\titemDef.name = \"Ancient platelegs\";\n\t\t\titemDef.description = \"Ancient platelegs.\";\n\t\t\titemDef.modelId = 60368;\n\t\t\titemDef.maleModel = 60369;\n\t\t\titemDef.femaleModel = 60369;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33334:\n\t\t\titemDef.name = \"Ancient boots\";\n\t\t\titemDef.description = \"Ancient boots.\";\n\t\t\titemDef.modelId = 60372;\n\t\t\titemDef.maleModel = 60372;\n\t\t\titemDef.femaleModel = 60372;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33335:\n\t\t\titemDef.name = \"Ancient gloves\";\n\t\t\titemDef.description = \"Ancient gloves.\";\n\t\t\titemDef.modelId = 60370;\n\t\t\titemDef.maleModel = 60371;\n\t\t\titemDef.femaleModel = 60371;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\tbreak;\n\t\tcase 33336:\n\t\t\titemDef.name = \"Ancient helmet\";\n\t\t\titemDef.description = \"Ancient helmet.\";\n\t\t\titemDef.modelId = 60364;\n\t\t\titemDef.maleModel = 60365;\n\t\t\titemDef.femaleModel = 60365;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\n\t\tcase 33341:\n\t\t\titemDef.name = \"Vanguard helmet\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60391;\n\t\t\titemDef.maleModel = 60392;\n\t\t\titemDef.femaleModel = 60392;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\n\t\tcase 33342:\n\t\t\titemDef.name = \"Vanguard platebody\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60393;\n\t\t\titemDef.maleModel = 60394;\n\t\t\titemDef.femaleModel = 60394;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = 3;\n\t\t\tbreak;\n\t\tcase 33343:\n\t\t\titemDef.name = \"Vanguard platelegs\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60395;\n\t\t\titemDef.maleModel = 60396;\n\t\t\titemDef.femaleModel = 60396;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33344:\n\t\t\titemDef.name = \"Vanguard boots\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60398;\n\t\t\titemDef.maleModel = 60398;\n\t\t\titemDef.femaleModel = 60398;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33345:\n\t\t\titemDef.name = \"Vanguard gloves\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60373;\n\t\t\titemDef.maleModel = 60397;\n\t\t\titemDef.femaleModel = 60397;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33346:\n\t\t\titemDef.name = \"Celestial staff of light\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60401;\n\t\t\titemDef.maleModel = 60402;\n\t\t\titemDef.femaleModel = 60402;\n\t\t\titemDef.modelZoom = 3200;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 101 };\n\t\t\titemDef.originalModelColors = new int[] { 12 };\n\t\t\titemDef.maleOffset = -6;\n\t\t\titemDef.femaleOffset = -6;\n\t\t\tbreak;\n\n\t\tcase 33347:\n\t\t\titemDef.name = \"Hood of sorrow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60438;\n\t\t\titemDef.maleModel = 60403;\n\t\t\titemDef.femaleModel = 60403;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33348:\n\t\t\titemDef.name = \"Celestial robe top\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60404;\n\t\t\titemDef.maleModel = 60405;\n\t\t\titemDef.femaleModel = 60405;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33349:\n\t\t\titemDef.name = \"Celestial robe legs\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60406;\n\t\t\titemDef.maleModel = 60407;\n\t\t\titemDef.femaleModel = 60407;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33350:\n\t\t\titemDef.name = \"Primal 2h sword\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60408;\n\t\t\titemDef.maleModel = 60409;\n\t\t\titemDef.femaleModel = 60409;\n\t\t\titemDef.modelZoom = 1701;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.modelRotation2 = 1529;\n\t\t\titemDef.modelRotation1 = 1713;\n\t\t\titemDef.modelRotationY = 898;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\titemDef.maleOffset = -7;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33353:\n\t\t\titemDef.name = \"Primal longsword\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60417;\n\t\t\titemDef.maleModel = 60418;\n\t\t\titemDef.femaleModel = 60418;\n\t\t\titemDef.modelZoom = 1616;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.modelRotation2 = 1793;\n\t\t\titemDef.modelRotation1 = 1473;\n\t\t\titemDef.modelRotationY = 1121;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\titemDef.maleOffset = -7;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33354:\n\t\t\titemDef.name = \"Primal maul\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60419;\n\t\t\titemDef.maleModel = 60420;\n\t\t\titemDef.femaleModel = 60420;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 525;\n\t\t\titemDef.modelRotation2 = 350;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\titemDef.maleOffset = -7;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33359:\n\t\t\titemDef.name = \"Primal rapier\";\n\t\t\titemDef.description = \"Good for fighting the ...\";\n\t\t\titemDef.modelId = 60433;\n\t\t\titemDef.maleModel = 60433;\n\t\t\titemDef.femaleModel = 60433;\n\t\t\titemDef.modelZoom = 1300;\n\t\t\titemDef.modelRotation1 = 1401;\n\t\t\titemDef.modelRotation2 = 1724;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = 15;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\titemDef.maleOffset = -7;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33360:\n\t\t\titemDef.name = \"Primal spear\";\n\t\t\titemDef.description = \"Good for fighting the Corperal Beast.\";\n\t\t\titemDef.modelId = 60434;\n\t\t\titemDef.maleModel = 60435;\n\t\t\titemDef.femaleModel = 60435;\n\t\t\titemDef.modelZoom = 1711;\n\t\t\titemDef.modelRotation1 = 485;\n\t\t\titemDef.modelRotation2 = 391;\n\t\t\titemDef.modelOffset1 = 5;\n\t\t\titemDef.modelOffset2 = -5;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.femaleOffset = -10;\n\t\t\titemDef.maleOffset = -10;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33361:\n\t\t\titemDef.name = \"Primal warhammer\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60436;\n\t\t\titemDef.maleModel = 60437;\n\t\t\titemDef.femaleModel = 60437;\n\t\t\titemDef.modelZoom = 1330;\n\t\t\titemDef.modelRotation1 = 552;\n\t\t\titemDef.modelRotation2 = 148;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.femaleOffset = -7;\n\t\t\titemDef.maleOffset = -7;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33362:\n\t\t\titemDef.name = \"Chitin helmet\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60445;\n\t\t\titemDef.maleModel = 60446;\n\t\t\titemDef.femaleModel = 60446;\n\t\t\titemDef.modelZoom = 1010;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33364:\n\t\t\titemDef.name = \"Chitin platebody\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60447;\n\t\t\titemDef.maleModel = 60448;\n\t\t\titemDef.femaleModel = 60448;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33365:\n\t\t\titemDef.name = \"Chitin platelegs\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60449;\n\t\t\titemDef.maleModel = 60450;\n\t\t\titemDef.femaleModel = 60450;\n\t\t\titemDef.modelZoom = 1753;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33366:\n\t\t\titemDef.name = \"Chitin cape\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60443;\n\t\t\titemDef.maleModel = 60444;\n\t\t\titemDef.femaleModel = 60444;\n\t\t\titemDef.modelZoom = 1500;\n\t\t\titemDef.modelRotation1 = 567;\n\t\t\titemDef.modelRotation2 = 2031;\n\t\t\titemDef.modelOffset1 = -4;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33367:\n\t\t\titemDef.name = \"Supreme void helmet\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60467;\n\t\t\titemDef.maleModel = 60464;\n\t\t\titemDef.femaleModel = 60464;\n\t\t\titemDef.modelZoom = 900;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33368:\n\t\t\titemDef.name = \"Supreme void robe top\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60468;\n\t\t\titemDef.maleModel = 60465;\n\t\t\titemDef.femaleModel = 60465;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33369:\n\t\t\titemDef.name = \"Supreme void robe\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60469;\n\t\t\titemDef.maleModel = 60466;\n\t\t\titemDef.femaleModel = 60466;\n\t\t\titemDef.modelZoom = 1900;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33370:\n\t\t\titemDef.name = \"Korasi's sword\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60471;\n\t\t\titemDef.maleModel = 60470;\n\t\t\titemDef.femaleModel = 60470;\n\t\t\titemDef.modelZoom = 1744;\n\t\t\titemDef.modelRotation1 = 330;\n\t\t\titemDef.modelRotation2 = 1505;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.maleOffset = -4;\n\t\t\titemDef.femaleOffset = -4;\n\t\t\tbreak;\n\n\t\tcase 33371:\n\t\t\titemDef.name = \"Spiked slayer helmet\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60475;\n\t\t\titemDef.maleModel = 60476;\n\t\t\titemDef.femaleModel = 60476;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33372:\n\t\t\titemDef.name = \"Slayer platebody\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60478;\n\t\t\titemDef.maleModel = 60479;\n\t\t\titemDef.femaleModel = 60479;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33373:\n\t\t\titemDef.name = \"Slayer platelegs\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60474;\n\t\t\titemDef.maleModel = 60477;\n\t\t\titemDef.femaleModel = 60477;\n\t\t\titemDef.modelZoom = 1900;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33374:\n\t\t\titemDef.name = \"Slayer boots\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60472;\n\t\t\titemDef.maleModel = 60473;\n\t\t\titemDef.femaleModel = 60473;\n\t\t\titemDef.modelZoom = 789;\n\t\t\titemDef.modelRotation1 = 164;\n\t\t\titemDef.modelRotation2 = 156;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33375:\n\t\t\titemDef.name = \"Blood Justiciar helmet\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60482;\n\t\t\titemDef.maleModel = 60483;\n\t\t\titemDef.femaleModel = 60483;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 16;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 2;\n\t\t\titemDef.modelOffset2 = -4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33376:\n\t\t\titemDef.name = \"Blood Justiciar platebody\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60484;\n\t\t\titemDef.maleModel = 60485;\n\t\t\titemDef.femaleModel = 60485;\n\t\t\titemDef.modelZoom = 1513;\n\t\t\titemDef.modelRotation1 = 566;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33377:\n\t\t\titemDef.name = \"Blood justiciar platelegs\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60486;\n\t\t\titemDef.maleModel = 60487;\n\t\t\titemDef.femaleModel = 60487;\n\t\t\titemDef.modelZoom = 1900;\n\t\t\titemDef.modelRotation1 = 562;\n\t\t\titemDef.modelRotation2 = 1;\n\t\t\titemDef.modelOffset1 = 11;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33378:\n\t\t\titemDef.name = \"Blood justiciar boots\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60488;\n\t\t\titemDef.maleModel = 60488;\n\t\t\titemDef.femaleModel = 60488;\n\t\t\titemDef.modelZoom = 789;\n\t\t\titemDef.modelRotation1 = 164;\n\t\t\titemDef.modelRotation2 = 156;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33379:\n\t\t\titemDef.name = \"Blood justiciar gloves\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60489;\n\t\t\titemDef.maleModel = 60490;\n\t\t\titemDef.femaleModel = 60490;\n\t\t\titemDef.modelZoom = 855;\n\t\t\titemDef.modelRotation1 = 215;\n\t\t\titemDef.modelRotation2 = 94;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = -32;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33380:\n\t\t\titemDef.name = \"Blood scythe of vitur\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60480;\n\t\t\titemDef.maleModel = 60481;\n\t\t\titemDef.femaleModel = 60481;\n\t\t\titemDef.modelZoom = 3850;\n\t\t\titemDef.modelRotation1 = 727;\n\t\t\titemDef.modelRotation2 = 997;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33381:\n\t\t\titemDef.name = \"Skiller cape\";\n\t\t\titemDef.description = \"Skiller cape.\";\n\t\t\titemDef.modelId = 60494;\n\t\t\titemDef.maleModel = 60493;\n\t\t\titemDef.femaleModel = 60492;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 400;\n\t\t\titemDef.modelRotation2 = 948;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 6;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33382:\n\t\t\titemDef.name = \"Justiciar faceguard (zamorak)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 4550 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 926, 926, 926 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33383:\n\t\t\titemDef.name = \"Justiciar faceguard (guthix)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 4550 };\n\t\t\titemDef.originalModelColors = new int[] { 21939, 21945, 21952, 21954 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33384:\n\t\t\titemDef.name = \"Justiciar faceguard (saradomin)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 4550 };\n\t\t\titemDef.originalModelColors = new int[] { 43929, 43929, 43929, 43929 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33385:\n\t\t\titemDef.name = \"Justiciar faceguard (ancient)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 4550 };\n\t\t\titemDef.originalModelColors = new int[] { -10854, -10860, -10872, -10874 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33387:\n\t\t\titemDef.name = \"Justiciar faceguard (bandos)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 4550 };\n\t\t\titemDef.originalModelColors = new int[] { 7062, 7062, 7062, 7062 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33389:\n\t\t\titemDef.name = \"Justiciar faceguard (armadyl)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 4550 };\n\t\t\titemDef.originalModelColors = new int[] { 10467, 10474, 10482, 10484 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33390:\n\t\t\titemDef.name = \"Justiciar chestguard (zamorak)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35750;\n\t\t\titemDef.maleModel = 35359;\n\t\t\titemDef.femaleModel = 35368;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 926, 926, 926 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33391:\n\t\t\titemDef.name = \"Justiciar chestguard (guthix)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35750;\n\t\t\titemDef.maleModel = 35359;\n\t\t\titemDef.femaleModel = 35368;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 21939, 21945, 21952, 21954 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33392:\n\t\t\titemDef.name = \"Justiciar chestguard (saradomin)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35750;\n\t\t\titemDef.maleModel = 35359;\n\t\t\titemDef.femaleModel = 35368;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 43929, 43929, 43929, 43929 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33393:\n\t\t\titemDef.name = \"Justiciar chestguard (ancient)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35750;\n\t\t\titemDef.maleModel = 35359;\n\t\t\titemDef.femaleModel = 35368;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { -10854, -10860, -10872, -10874 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33394:\n\t\t\titemDef.name = \"Justiciar chestguard (bandos)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35750;\n\t\t\titemDef.maleModel = 35359;\n\t\t\titemDef.femaleModel = 35368;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 7062, 7062, 7062, 7062 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33395:\n\t\t\titemDef.name = \"Justiciar chestguard (armadyl)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35750;\n\t\t\titemDef.maleModel = 35359;\n\t\t\titemDef.femaleModel = 35368;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 432;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 4;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 10467, 10474, 10482, 10484 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33396:\n\t\t\titemDef.name = \"Justiciar legguards (zamorak)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35752;\n\t\t\titemDef.maleModel = 35356;\n\t\t\titemDef.femaleModel = 35357;\n\t\t\titemDef.modelZoom = 1720;\n\t\t\titemDef.modelRotation1 = 468;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 926, 926, 926 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33397:\n\t\t\titemDef.name = \"Justiciar legguards (guthix)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35752;\n\t\t\titemDef.maleModel = 35356;\n\t\t\titemDef.femaleModel = 35357;\n\t\t\titemDef.modelZoom = 1720;\n\t\t\titemDef.modelRotation1 = 468;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 21939, 21945, 21952, 21954 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33398:\n\t\t\titemDef.name = \"Justiciar legguards (saradomin)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35752;\n\t\t\titemDef.maleModel = 35356;\n\t\t\titemDef.femaleModel = 35357;\n\t\t\titemDef.modelZoom = 1720;\n\t\t\titemDef.modelRotation1 = 468;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 43929, 43929, 43929, 43929 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33399:\n\t\t\titemDef.name = \"Justiciar legguards (ancient)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35752;\n\t\t\titemDef.maleModel = 35356;\n\t\t\titemDef.femaleModel = 35357;\n\t\t\titemDef.modelZoom = 1720;\n\t\t\titemDef.modelRotation1 = 468;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { -10854, -10860, -10872, -10874 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33400:\n\t\t\titemDef.name = \"Justiciar legguards (bandos)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35752;\n\t\t\titemDef.maleModel = 35356;\n\t\t\titemDef.femaleModel = 35357;\n\t\t\titemDef.modelZoom = 1720;\n\t\t\titemDef.modelRotation1 = 468;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 7062, 7062, 7062, 7062 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33401:\n\t\t\titemDef.name = \"Justiciar legguards (armadyl)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35752;\n\t\t\titemDef.maleModel = 35356;\n\t\t\titemDef.femaleModel = 35357;\n\t\t\titemDef.modelZoom = 1720;\n\t\t\titemDef.modelRotation1 = 468;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 6709, 6736, 6602, 6699 };\n\t\t\titemDef.originalModelColors = new int[] { 10467, 10474, 10482, 10484 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33402:\n\t\t\titemDef.name = \"Pet andy\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 50169;\n\t\t\titemDef.modelZoom = 1500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33403:\n\t\t\titemDef.name = \"Pet mod divine\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 14283;\n\t\t\titemDef.modelZoom = 3500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33404:\n\t\t\titemDef.name = \"Celestial fairy\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60491;\n\t\t\titemDef.modelZoom = 3500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 947 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 78 };\n\t\t\titemDef.modifiedModelColors = new int[] { 937, 11200 };\n\t\t\titemDef.originalModelColors = new int[] { 42663, 41883 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33405:\n\t\t\titemDef.name = \"Lava partyhat (red)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"A lava partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33406:\n\t\t\titemDef.name = \"Lava partyhat (green)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"A lava partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33407:\n\t\t\titemDef.name = \"Lava partyhat (cyan)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"A lava partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33408:\n\t\t\titemDef.name = \"Lava partyhat (purple)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"A lava partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33409:\n\t\t\titemDef.name = \"Infernal partyhat (blue)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"An Infernal partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33410:\n\t\t\titemDef.name = \"Infernal partyhat (green)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"An Infernal partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33411:\n\t\t\titemDef.name = \"Infernal partyhat (purple)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"An Infernal partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33412:\n\t\t\titemDef.name = \"Infernal partyhat (rainbow)\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"An Infernal partyhat.\";\n\t\t\tbreak;\n\n\t\tcase 33413:\n\t\t\titemDef.name = \"Celestial partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33414:\n\t\t\titemDef.name = \"Blood partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33415:\n\t\t\titemDef.name = \"Shadow partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33416:\n\t\t\titemDef.name = \"Light blue partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33417:\n\t\t\titemDef.name = \"Easter partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33418:\n\t\t\titemDef.name = \"Dark sparkle partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33419:\n\t\t\titemDef.name = \"Rainbow partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33420:\n\t\t\titemDef.name = \"Fire partyhat\";\n\t\t\titemDef.modelId = 2635;\n\t\t\titemDef.modelZoom = 440;\n\t\t\titemDef.modelRotation2 = 1852;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.maleModel = 187;\n\t\t\titemDef.femaleModel = 363;\n\t\t\t// itemDef.anInt164 = -1;\n\t\t\t// itemDef.anInt188 = -1;\n\t\t\t// itemDef.aByte205 = -8;\n\t\t\titemDef.groundOptions = new String[] { null, null, \"Take\", null, null };\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.description = \"none.\";\n\t\t\tbreak;\n\n\t\tcase 33421:\n\t\t\titemDef.name = \"Pet star sprite\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60506;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\t\tcase 33422:\n\t\t\titemDef.name = \"Stargaze Box\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = false;\n\t\t\titemDef.modelId = 61110;\n\t\t\titemDef.modelZoom = 1180;\n\t\t\titemDef.modelRotation1 = 160;\n\t\t\titemDef.modelRotation2 = 172;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -14;\n\t\t\t// itemDef.modifiedModelColors = new int[] {22410, 2999};\n\t\t\t// itemDef.originalModelColors = new int[] {35321, 350};\n\t\t\titemDef.description = \"none\";\n\t\t\tbreak;\n\n\t\tcase 33423:\n\t\t\titemDef.name = \"Star Dust\";\n\t\t\titemDef.inventoryOptions = new String[] { \"Exchange\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.modelId = 60496;\n\t\t\titemDef.modelZoom = 2086;\n\t\t\titemDef.modelRotation1 = 279;\n\t\t\titemDef.modelRotation2 = 1994;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 47;\n\t\t\t// itemDef.modifiedModelColors = new int[] {22410, 2999};\n\t\t\t// itemDef.originalModelColors = new int[] {35321, 350};\n\t\t\titemDef.description = \"none\";\n\t\t\tbreak;\n\n\t\tcase 33424:\n\t\t\titemDef.name = \"Blood twisted bow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 32799;\n\t\t\titemDef.maleModel = 32674;\n\t\t\titemDef.femaleModel = 32674;\n\t\t\titemDef.modelZoom = 2000;\n\t\t\titemDef.modelRotation1 = 720;\n\t\t\titemDef.modelRotation2 = 1500;\n\t\t\titemDef.modelOffset1 = -3;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 10318, 10334 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 66, 66 };\n\t\t\titemDef.modifiedModelColors = new int[] { 14236, 13223 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 926 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33425:\n\t\t\titemDef.name = \"Celestial crow\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60507;\n\t\t\titemDef.modelZoom = 1000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 10382 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 78 };\n\t\t\titemDef.modifiedModelColors = new int[] { 10378, 10502 };\n\t\t\titemDef.originalModelColors = new int[] { 0, 0 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33426:\n\t\t\titemDef.name = \"Celestial penguin\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60508;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 10343 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 78 };\n\t\t\titemDef.modifiedModelColors = new int[] { 16, 12, 20, 24, 8, 10332, 10337 };\n\t\t\titemDef.originalModelColors = new int[] { 0, 0, 0, 0, 0, 0, 0 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33427:\n\t\t\titemDef.name = \"Celestial snake\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60509;\n\t\t\titemDef.modelZoom = 1800;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 10644, 10512 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 78, 78 };\n\t\t\titemDef.modifiedModelColors = new int[] { 10413, 10405, 10524 };\n\t\t\titemDef.originalModelColors = new int[] { 0, 0, 0 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33428:\n\t\t\titemDef.name = \"Celestial scorpion\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60510;\n\t\t\titemDef.modelZoom = 2500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 142 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 78 };\n\t\t\titemDef.modifiedModelColors = new int[] { 4884, 4636, 3974, 4525, 4645 };\n\t\t\titemDef.originalModelColors = new int[] { 0, 0, 0, 0, 0 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33429:\n\t\t\titemDef.name = \"Armadyl dye\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60513;\n\t\t\titemDef.modelZoom = 809;\n\t\t\titemDef.modelRotation1 = 90;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 30814, 30809, 30799, 30804 };\n\t\t\titemDef.originalModelColors = new int[] { 10467, 10474, 10482, 10484 };\n\t\t\tbreak;\n\n\t\tcase 33430:\n\t\t\titemDef.name = \"Guthix dye\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60513;\n\t\t\titemDef.modelZoom = 809;\n\t\t\titemDef.modelRotation1 = 90;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 30814, 30809, 30799, 30804 };\n\t\t\titemDef.originalModelColors = new int[] { 21939, 21945, 21952, 21954 };\n\t\t\tbreak;\n\n\t\tcase 33431:\n\t\t\titemDef.name = \"Zamorak dye\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60513;\n\t\t\titemDef.modelZoom = 809;\n\t\t\titemDef.modelRotation1 = 90;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 30814, 30809, 30799, 30804 };\n\t\t\titemDef.originalModelColors = new int[] { 926, 926, 926, 926 };\n\t\t\tbreak;\n\n\t\tcase 33432:\n\t\t\titemDef.name = \"Ancient dye\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60513;\n\t\t\titemDef.modelZoom = 809;\n\t\t\titemDef.modelRotation1 = 90;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 30814, 30809, 30799, 30804 };\n\t\t\titemDef.originalModelColors = new int[] { -10854, -10860, -10872, -10874 };\n\t\t\tbreak;\n\n\t\tcase 33433:\n\t\t\titemDef.name = \"Bandos dye\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60513;\n\t\t\titemDef.modelZoom = 809;\n\t\t\titemDef.modelRotation1 = 90;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 30814, 30809, 30799, 30804 };\n\t\t\titemDef.originalModelColors = new int[] { 7062, 7062, 7062, 7062 };\n\t\t\tbreak;\n\n\t\tcase 33434:\n\t\t\titemDef.name = \"Saradomin dye\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60513;\n\t\t\titemDef.modelZoom = 809;\n\t\t\titemDef.modelRotation1 = 90;\n\t\t\titemDef.modelRotation2 = 2047;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -9;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 30814, 30809, 30799, 30804 };\n\t\t\titemDef.originalModelColors = new int[] { 43929, 43929, 43929, 43929 };\n\t\t\tbreak;\n\n\t\tcase 33435:\n\t\t\titemDef.name = \"Celestial egg\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 7171;\n\t\t\titemDef.modelZoom = 550;\n\t\t\titemDef.modelRotation1 = 76;\n\t\t\titemDef.modelRotation2 = 16;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.originalTextureColors = new int[] { 476 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 78 };\n\t\t\titemDef.inventoryOptions = new String[] { \"Hatch\", null, null, null, \"Drop\" };\n\t\t\titemDef.stackable = true;\n\t\t\tbreak;\n\n\t\tcase 33436:\n\t\t\titemDef.name = \"Elite void top (placeholder)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 10586;\n\t\t\titemDef.maleModel = 10687;\n\t\t\titemDef.anInt188 = 10681;\n\t\t\titemDef.femaleModel = 10694;\n\t\t\titemDef.anInt164 = 10688;\n\t\t\titemDef.modelZoom = 1221;\n\t\t\titemDef.modelRotation1 = 459;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\t// itemDef.originalTextureColors = new int [] { 695};\n\t\t\t// itemDef.modifiedTextureColors = new int [] { 66};\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33437:\n\t\t\titemDef.name = \"Elite void robe (placeholder)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60528;\n\t\t\titemDef.maleModel = 60526;\n\t\t\titemDef.femaleModel = 60527;\n\t\t\titemDef.modelZoom = 2105;\n\t\t\titemDef.modelRotation1 = 525;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 1;\n\t\t\t// itemDef.originalTextureColors = new int [] { 695};\n\t\t\t// itemDef.modifiedTextureColors = new int [] { 66};\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33438:\n\t\t\titemDef.name = \"Blood chest\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60516;\n\t\t\titemDef.modelZoom = 2640;\n\t\t\titemDef.modelRotation1 = 114;\n\t\t\titemDef.modelRotation2 = 1883;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33439:\n\t\t\titemDef.name = \"Blood bird\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60517;\n\t\t\titemDef.modelZoom = 2768;\n\t\t\titemDef.modelRotation1 = 141;\n\t\t\titemDef.modelRotation2 = 1790;\n\t\t\titemDef.modelOffset1 = -8;\n\t\t\titemDef.modelOffset2 = -13;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\titemDef.originalTextureColors = new int[] { 1946, 2983, 6084, 2735, 5053, 6082, 4013, 2733, 4011, 2880,\n\t\t\t\t\t8150 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66 };\n\t\t\tbreak;\n\n\t\tcase 33440:\n\t\t\titemDef.name = \"Blood Death\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60441;\n\t\t\titemDef.modelZoom = 16000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33442:\n\t\t\titemDef.name = \"10 Min XP boost (25%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Claim\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33446:\n\t\t\titemDef.name = \"10 Min XP boost (50%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Claim\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33450:\n\t\t\titemDef.name = \"10 Min XP boost (75%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Claim\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33454:\n\t\t\titemDef.name = \"10 Min XP boost (100%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33458:\n\t\t\titemDef.name = \"10 Min XP boost (150%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33462:\n\t\t\titemDef.name = \"10 Min XP boost (200%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33443:\n\t\t\titemDef.name = \"30 Min XP boost (25%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33447:\n\t\t\titemDef.name = \"30 Min XP boost (50%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33451:\n\t\t\titemDef.name = \"30 Min XP boost (75%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33455:\n\t\t\titemDef.name = \"30 Min XP boost (100%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33459:\n\t\t\titemDef.name = \"30 Min XP boost (150%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33463:\n\t\t\titemDef.name = \"30 Min XP boost (200%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33444:\n\t\t\titemDef.name = \"60 Min XP boost (25%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33448:\n\t\t\titemDef.name = \"60 Min XP boost (50%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33452:\n\t\t\titemDef.name = \"60 Min XP boost (75%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33456:\n\t\t\titemDef.name = \"60 Min XP boost (100%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33460:\n\t\t\titemDef.name = \"60 Min XP boost (150%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33464:\n\t\t\titemDef.name = \"60 Min XP boost (200%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33445:\n\t\t\titemDef.name = \"120 Min XP boost (25%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33449:\n\t\t\titemDef.name = \"120 Min XP boost (50%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33453:\n\t\t\titemDef.name = \"120 Min XP boost (75%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33457:\n\t\t\titemDef.name = \"120 Min XP boost (100%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33461:\n\t\t\titemDef.name = \"120 Min XP boost (150%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33465:\n\t\t\titemDef.name = \"120 Min XP boost (200%)\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60531;\n\t\t\titemDef.modelZoom = 1488;\n\t\t\titemDef.modelRotation1 = 246;\n\t\t\titemDef.modelRotation2 = 1721;\n\t\t\titemDef.modelOffset1 = -11;\n\t\t\titemDef.modelOffset2 = -45;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\titemDef.originalTextureColors = new int[] { 54302, 54312, 54307, 54297, 54315, 54310, 54305, 54287, 55292,\n\t\t\t\t\t54300, 10281, 10274 };\n\t\t\titemDef.modifiedTextureColors = new int[] { 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67, 67 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33466:\n\t\t\titemDef.name = \"Deathtouched dart\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60534;\n\t\t\titemDef.maleModel = 60533;\n\t\t\titemDef.femaleModel = 60533;\n\t\t\titemDef.modelZoom = 1053;\n\t\t\titemDef.modelRotation1 = 471;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.stackable = true;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33467:\n\t\t\titemDef.name = \"Justiciar boots\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60535;\n\t\t\titemDef.maleModel = 60535;\n\t\t\titemDef.femaleModel = 60535;\n\t\t\titemDef.modelZoom = 789;\n\t\t\titemDef.modelRotation1 = 164;\n\t\t\titemDef.modelRotation2 = 156;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = -8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33468:\n\t\t\titemDef.name = \"Justiciar gloves\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 31022;\n\t\t\titemDef.maleModel = 31006;\n\t\t\titemDef.femaleModel = 31013;\n\t\t\titemDef.modelZoom = 592;\n\t\t\titemDef.modelRotation1 = 636;\n\t\t\titemDef.modelRotation2 = 2015;\n\t\t\titemDef.modelOffset1 = 3;\n\t\t\titemDef.modelOffset2 = 3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { 123, 70 };\n\t\t\titemDef.originalModelColors = new int[] { 6736, 59441 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33469:\n\t\t\titemDef.name = \"Magic mushroom\";\n\t\t\titemDef.description = \"offers a 10% droprate increase while this pet follows you.\";\n\t\t\titemDef.modelId = 60532;\n\t\t\titemDef.modelZoom = 3000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 6;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33470:\n\t\t\titemDef.name = \"Twisted staff\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60538;\n\t\t\titemDef.maleModel = 60539;\n\t\t\titemDef.femaleModel = 60539;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 1549;\n\t\t\titemDef.modelRotation2 = 1791;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = -3;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33471:\n\t\t\titemDef.name = \"Cowboy hat\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60540;\n\t\t\titemDef.maleModel = 60541;\n\t\t\titemDef.femaleModel = 60541;\n\t\t\titemDef.modelZoom = 800;\n\t\t\titemDef.modelRotation1 = 108;\n\t\t\titemDef.modelRotation2 = 1535;\n\t\t\titemDef.modelOffset1 = -1;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33472:\n\t\t\titemDef.name = \"Stick\";\n\t\t\titemDef.description = \"Careful of that chub.\";\n\t\t\titemDef.modelId = 60545;\n\t\t\titemDef.maleModel = 60545;\n\t\t\titemDef.femaleModel = 60545;\n\t\t\titemDef.modelZoom = 3000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33473:\n\t\t\titemDef.name = \"#1 Tob cape\";\n\t\t\titemDef.description = \"Reward to the first to complete tob solo and in a team.\";\n\t\t\titemDef.modelId = 60551;\n\t\t\titemDef.maleModel = 60550;\n\t\t\titemDef.femaleModel = 60550;\n\t\t\titemDef.modelZoom = 2295;\n\t\t\titemDef.modelRotation1 = 367;\n\t\t\titemDef.modelRotation2 = 1212;\n\t\t\titemDef.modelOffset1 = 4;\n\t\t\titemDef.modelOffset2 = 8;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33474:\n\t\t\titemDef.name = \"Supreme void upgrade kit\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 4847;\n\t\t\titemDef.modelZoom = 1310;\n\t\t\titemDef.modelRotation1 = 163;\n\t\t\titemDef.modelRotation2 = 73;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\titemDef.modifiedModelColors = new int[] { -32709, 10295, 10304, 10287, 10275, 10283 };\n\t\t\titemDef.originalModelColors = new int[] { 10, 10, 10, 10, 10, 10 };\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33475:\n\t\t\titemDef.name = \"Hunter's penguin\";\n\t\t\titemDef.description = \"the one and only's pet.\";\n\t\t\titemDef.modelId = 60548;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 6;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33476:\n\t\t\titemDef.name = \"Chef Harambe\";\n\t\t\titemDef.description = \"I like to dip my balls in a deep fryer.\";\n\t\t\titemDef.modelId = 60921;\n\t\t\titemDef.modelZoom = 5000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 6;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33477:\n\t\t\titemDef.name = \"Void knight champion jr\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60463;\n\t\t\titemDef.modelZoom = 14000;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 6;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33478:\n\t\t\titemDef.name = \"Custom pet token\";\n\t\t\titemDef.description = \"Trade this to corey after filling out a form on the forums post custom pets\";\n\t\t\titemDef.modelId = 13838;\n\t\t\titemDef.modelZoom = 530;\n\t\t\titemDef.modelRotation1 = 415;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33479:\n\t\t\titemDef.name = \"Mr jaycorr\";\n\t\t\titemDef.description = \"The autistic one.\";\n\t\t\titemDef.modelId = 60592;\n\t\t\titemDef.modelZoom = 7500;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 270;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = null;\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33480:\n\t\t\titemDef.name = \"Broom broom\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 60593;\n\t\t\titemDef.maleModel = 60593;\n\t\t\titemDef.femaleModel = 60593;\n\t\t\titemDef.modelZoom = 2700;\n\t\t\titemDef.modelRotation1 = 0;\n\t\t\titemDef.modelRotation2 = 0;\n\t\t\titemDef.modelOffset1 = 0;\n\t\t\titemDef.modelOffset2 = 0;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 33481:\n\t\t\titemDef.name = \"Test\";\n\t\t\titemDef.description = \"none.\";\n\t\t\titemDef.modelId = 35751;\n\t\t\titemDef.maleModel = 35349;\n\t\t\titemDef.femaleModel = 35361;\n\t\t\titemDef.modelZoom = 777;\n\t\t\titemDef.modelRotation1 = 22;\n\t\t\titemDef.modelRotation2 = 1972;\n\t\t\titemDef.modelOffset1 = 1;\n\t\t\titemDef.modelOffset2 = -1;\n\t\t\titemDef.inventoryOptions = new String[5];\n\t\t\titemDef.inventoryOptions[1] = \"Wear\";\n\t\t\titemDef.inventoryOptions[2] = null;\n\t\t\t// itemDef.aByte205 = 3;\n\t\t\tbreak;\n\n\t\tcase 11773:\n\t\tcase 11771:\n\t\tcase 11770:\n\t\tcase 11772:\n\t\t\titemDef.anInt196 += 45;\n\t\t\tbreak;\n\t\tcase 22610:\n\t\t\titemDef.name = \"Vesta's spear (deg)\";\n\t\t\tbreak;\n\t\tcase 22614:\n\t\t\titemDef.name = \"Vesta's longsword (deg)\";\n\t\t\tbreak;\n\t\tcase 22616:\n\t\t\titemDef.name = \"Vesta's chainbody (deg)\";\n\t\t\tbreak;\n\t\tcase 22619:\n\t\t\titemDef.name = \"Vesta's plateskirt (deg)\";\n\t\t\tbreak;\n\t\tcase 22622:\n\t\t\titemDef.name = \"Statius's warhammer (deg)\";\n\t\t\tbreak;\n\t\tcase 22625:\n\t\t\titemDef.name = \"Statius's full helm (deg)\";\n\t\t\tbreak;\n\t\tcase 22628:\n\t\t\titemDef.name = \"Statius's platebody (deg)\";\n\t\t\tbreak;\n\t\tcase 22631:\n\t\t\titemDef.name = \"Statius's platelegs (deg)\";\n\t\t\tbreak;\n\t\tcase 22638:\n\t\t\titemDef.name = \"Morrigan's coif (deg)\";\n\t\t\tbreak;\n\t\tcase 22641:\n\t\t\titemDef.name = \"Morrigan's leather body (deg)\";\n\t\t\tbreak;\n\t\tcase 22644:\n\t\t\titemDef.name = \"Morrigan's leather chaps (deg)\";\n\t\t\tbreak;\n\t\tcase 22647:\n\t\t\titemDef.name = \"Zuriel's staff (deg)\";\n\t\t\tbreak;\n\t\tcase 22650:\n\t\t\titemDef.name = \"Zuriel's hood (deg)\";\n\t\t\tbreak;\n\t\tcase 22653:\n\t\t\titemDef.name = \"Zuriel's robe top (deg)\";\n\t\t\tbreak;\n\t\tcase 22656:\n\t\t\titemDef.name = \"Zuriel's robe bottom (deg)\";\n\t\t\tbreak;\n\n\t\tcase 13303:\n\t\t\titemDef.name = \"Event Key (Tarn)\";\n\t\t\titemDef.description = \"Use this to open the Event Boss chest.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 8128 };\n\t\t\titemDef.originalModelColors = new int[] { 933 };\n\t\t\tbreak;\n\t\tcase 13302:\n\t\t\titemDef.name = \"Event Key (Graardor)\";\n\t\t\titemDef.description = \"Use this to open the Event Boss chest.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 8128 };\n\t\t\titemDef.originalModelColors = new int[] { 933 };\n\t\t\tbreak;\n\t\tcase 13305:\n\t\t\titemDef.name = \"Tastey-Looking Key\";\n\t\t\titemDef.description = \"Use this to open the Event Boss chest.\";\n\t\t\titemDef.modifiedModelColors = new int[] { 8128 };\n\t\t\titemDef.originalModelColors = new int[] { 933 };\n\t\t\tbreak;\n\t\tcase 2697:\n\t\t\titemDef.name = \"$10 Scroll\";\n\t\t\titemDef.description = \"Get donor status at a cheaper cost!\";\n\t\t\tbreak;\n\t\tcase 2698:\n\t\t\titemDef.name = \"$50 Scroll\";\n\t\t\titemDef.description = \"Read this scroll to be rewarded with the Super Donator status.\";\n\t\t\tbreak;\n\t\tcase 2699:\n\t\t\titemDef.name = \"$100 Donator\";\n\t\t\titemDef.description = \"Read this scroll to be rewarded with the Extreme Donator status.\";\n\t\t\tbreak;\n\t\tcase 2700:\n\t\t\titemDef.name = \"$5 Scroll\";\n\t\t\titemDef.description = \"Read this scroll to be rewarded with the Legendary Donator status.\";\n\t\t\tbreak;\n\t\tcase 1464:\n\t\t\titemDef.name = \"Vote ticket\";\n\t\t\titemDef.description = \"This ticket can be exchanged for a voting point.\";\n\t\t\tbreak;\n\n\t\tcase 11739:\n\t\t\titemDef.name = \"Daily reward box\";\n\t\t\titemDef.description = \"Open this box for a daily reward.\";\n\t\t\tbreak;\n\n\t\tcase 13066:// super set\n\t\tcase 12873:// barrows\n\t\tcase 12875:\n\t\tcase 12877:\n\t\tcase 12879:\n\t\tcase 12881:\n\t\tcase 12883:\n\t\tcase 12789:// clue box\n\t\t\titemDef.inventoryOptions = new String[] { \"Open\", null, null, null, \"Drop\" };\n\t\t\tbreak;\n\t\t}\n\t\t\n\t}", "@EventHandler\n public void onPlayerDeath(PlayerDeathEvent event) {\n\n Player player = event.getEntity();\n World world = player.getWorld();\n int experience = player.getTotalExperience();\n\n // TODO: Add configurable.\n player.setTotalExperience(experience / 2);\n\n // TODO: Add configurable.\n // Reduce the player's level by 8.\n player.setLevel(player.getLevel() >= 8 ? player.getLevel() - 8 : 0);\n player.setExp(0);\n\n Inventory playerInventory = player.getInventory();\n\n // TODO: Add configurable.\n // Drop all the items in the player's internal inventory.\n for (int i = 9; i <= 35; i++) {\n ItemStack item = playerInventory.getItem(i);\n if (item != null) {\n world.dropItem(player.getLocation(), item);\n playerInventory.clear(i);\n }\n }\n\n // TODO: Add configurable.\n // Damage all equipped armor by a set amount in config file.\n for (int i = 36; i <= 39; i++) {\n ItemStack equipment = playerInventory.getItem(i);\n\n // Make sure we're wearing something!\n if (equipment == null) continue;\n\n // Check if we can damage this item, otherwise continue.\n ItemMeta meta = equipment.getItemMeta();\n if (!(meta instanceof Damageable)) continue;\n\n int value = ksiPlugin.config.getInt(\"armorDurabilityDamage\");\n if (value == 0) continue;\n else {\n value = 100 / value;\n }\n\n int currentDamage = ((Damageable) meta).getDamage();\n int damageModifier = equipment.getType().getMaxDurability() / value;\n\n ((Damageable) meta).setDamage(currentDamage + damageModifier);\n equipment.setItemMeta(meta);\n }\n }", "@Override\n\tprotected void on_object_drop(GfxObject bonus) {\n\n\t}", "public Item getDropType(int paramInt1, Random paramRandom, int paramInt2) {\n/* 27 */ return Items.MELON;\n/* */ }", "void dropItem(Command command) {\n HashMap newInventory = inventory.getInventory();\n Iterator iterator = newInventory.entrySet().iterator();\n String seeItem;\n// int indexItem = -1;\n String nameOfItem = \"\";\n String dropFromInventory = \"debug\";\n\n while (iterator.hasNext()) {\n HashMap.Entry liste = (HashMap.Entry) iterator.next();\n String itemName = (String) liste.getKey();\n if (itemName.equalsIgnoreCase(command.getSecondWord())) {\n dropFromInventory = itemName;\n nameOfItem = itemName;\n break;\n }\n }\n if (!nameOfItem.equals(\"\")) {\n itemLocation.addItem(currentRoom, new PickableItem(nameOfItem, inventory.getItemWeight(nameOfItem), inventory.getUseable(nameOfItem)));\n inventory.removeItemInventory(nameOfItem);\n System.out.println(\"You have dropped: \" + nameOfItem);\n\n } else {\n System.out.println(\"Can't drop item that isn't in inventory \" + command.getSecondWord());\n }\n }", "public void popItems() {\n\t\t\n\t\tItemList.add(HPup);\n\t\tItemList.add(SHPup);\n\t\tItemList.add(DMGup);\n\t\tItemList.add(SDMGup);\n\t\tItemList.add(EVup);\n\t\tItemList.add(SEVup);\n\t\t\n\t\trandomDrops.add(HPup);\n\t\trandomDrops.add(SHPup);\n\t\trandomDrops.add(DMGup);\n\t\trandomDrops.add(SDMGup);\n\t\trandomDrops.add(EVup);\n\t\trandomDrops.add(SEVup);\n\t\t\n\t\tcombatDrops.add(SHPup);\n\t\tcombatDrops.add(SDMGup);\n\t\tcombatDrops.add(SEVup);\n\t}", "private void generateItemEntities(){\n\t\tfinal int NUM_POTIONS = 6;\n\t\tfinal int NUM_IRON_ARMOUR = 1;\n\t\tfinal int NUM_CHESTS = 2;\n\t\tfinal String ITEM_BOX_STYLE = \"tundra\";\n\t\t\n\n\t\tfor (int i = 0; i < NUM_POTIONS; i++) {\n\t\t\tTile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n\t\t\t\t\tItem.randomItemPositionGenerator(DEFAULT_HEIGHT));\n\t\t\tif (!tile.hasParent()) {\n\t\t\t\tHealthPotion potion = new HealthPotion(tile, false,(PlayerPeon) getPlayerEntity(), ITEM_BOX_STYLE);\n\t\t\t\tentities.add(potion);\n\t\t\t\tthis.allTundraDialogues.add(potion.getDisplay());\n\t\t\t} else {\n\t\t\t\ti--;\n\t\t\t}\n\n\t\t}\n\t\tfor (int i = 0; i < NUM_IRON_ARMOUR; i++) {\n\t\t\tTile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n\t\t\t\t\tItem.randomItemPositionGenerator(DEFAULT_HEIGHT));\n\t\t\tif (!tile.hasParent()) {\n\t\t\t\tIronArmour ironArmour = new IronArmour(tile, false,\n\t\t\t\t\t\t(PlayerPeon) getPlayerEntity(), ITEM_BOX_STYLE,200);\n\t\t\t\tentities.add(ironArmour);\n\t\t\t\tthis.allTundraDialogues.add(ironArmour.getDisplay());\n\t\t\t} else {\n\t\t\t\ti--;\n\t\t\t}\n\n\t\t}\n\t\tfor (int i = 0; i < NUM_CHESTS; i++) {\n\t\t\tTile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n\t\t\t\t\tItem.randomItemPositionGenerator(DEFAULT_HEIGHT));\n\t\t\tif (!tile.hasParent()) {\n\t\t\t\tTreasure chest = new Treasure(tile, false,(PlayerPeon) getPlayerEntity(), ITEM_BOX_STYLE);\n\t\t\t\tentities.add(chest);\n\t\t\t\tthis.allTundraDialogues.add(chest.getDisplay());\n\t\t\t} else {\n\t\t\t\ti--;\n\t\t\t}\n\t\t}\n\n\t\tTile cooldownring = getTile(18,17);\n\t\tCooldownRing cdring = new CooldownRing(cooldownring, false,\n\t\t\t\t(PlayerPeon) this.getPlayerEntity(), ITEM_BOX_STYLE,0.5f);\n\t\tentities.add(cdring);\n\t\tthis.allTundraDialogues.add(cdring.getDisplay());\n\n\t\tTile attackAmuletTile = getTile(-19,14);\n\t\tAmulet attackAmulet = new Amulet(attackAmuletTile, false,\n\t\t\t\t(PlayerPeon) this.getPlayerEntity(), ITEM_BOX_STYLE,10);\n\t\tentities.add(attackAmulet);\n\t\tthis.allTundraDialogues.add(attackAmulet.getDisplay());\n\n\t}", "float getBonusItemDrop();", "private void checkForDeaths() {\n Iterator<Entity> entityIter = this.entities.iterator();\n\n //geht alle teilnehmer durch\n while ( entityIter.hasNext() ) {\n Entity entity = entityIter.next();\n\n //und entfernt sie wenn sie tot sind aus der liste und der engine\n if ( this.combatMapper.get(entity).curHealth <= 0 ) {\n entityIter.remove();\n\n //alle actions der entity entfernen, können ja nichts machen wenn sie tot sind\n Iterator<IAction> actionIter = this.actions.iterator();\n\n while ( actionIter.hasNext() ) {\n if ( actionIter.next().getOwner().equals(entity) ) {\n actionIter.remove();\n }\n }\n\n this.combatExp += this.combatMapper.get(entity).level * 5; //TODO\n\n EventSystem.getInstance().commitEvent(new Event(EventSystem.EventType.KILL_EVENT, entity));\n\n this.combatSystem.getEngine().removeEntity(entity);\n }\n }\n }", "private void dropped(HeroItem item, Unit unit) {\n if (ItemMaster.isBreakable(item)) {\n item.broken(); // remove from game?\n if (item instanceof QuickItem) {\n QuickItem quickItemObj = (QuickItem) item;\n if (quickItemObj.isConcoction()) {\n quickItemObj.activate(Ref.getSelfTargetingRefCopy(unit)); // setForceTarget(true)\n }\n }\n } else {\n unit.getGame().getDroppedItemManager().itemFalls(unit.getCoordinates(), item);\n }\n }", "public void dropItem(Location loc){\n\t\t\n\t\tPlayer p = getThrower();\n\t\tItemStack droppedItem;\n\t\t\n\t\tdroppable.clear();\n\t\t\n\t\taddItem(Material.IRON_INGOT, 8, 8, 3); //Item, weight, maximum stack size, minimum stack size\n\t\taddItem(Material.GOLD_INGOT, 5, 5, 1);\n\t\taddItem(Material.DIAMOND, 3, 3, 1);\n\t\taddItem(Material.GOLDEN_APPLE, 1, 1, 1);\n\t\taddItem(Material.ROTTEN_FLESH, 10, 5, 1);\n\t\taddItem(Material.BREAD, 15, 32, 15);\n\t\taddItem(Material.BONE, 10, 5, 1);\n\t\taddItem(Material.SULPHUR, 10, 5, 1);\n\t\taddItem(Material.SADDLE, 1, 1, 1);\n\t\t\n\t\tint Size = droppable.size();\n\t\trandNum = ThreadLocalRandom.current().nextInt(Size);\n\t\t\n\t\tdroppedItem = droppable.get(randNum);\n\t\t\n\t\tp.getWorld().dropItem(loc, droppedItem);\n\t\tp.getWorld().dropItem(loc, new ItemStack(Material.GOLD_NUGGET, rand.nextInt(10) + 1));\n\t\t\n\t}", "public void OnDamage(AI ai, int aTK, float f) {\n\tif(DamagedTimer < 0.8f)\n\t\treturn;\n\tvel.x = f;\n\tvel.y = 3;\n\tDamagedTimer = 0;\n\tgrounded = false;\n\taTK -= (getDEF()*0.8f);\n\tif(aTK <= 0)\n\t\taTK = 1;\n\tHP -= aTK;\n\tInventory.CurrentInventory.dmgTxts.add(new dmgText(pos.x, pos.y+1, aTK));\n\t\n\tSoundManager.PlaySound(\"playerHurt\",3);\n\t\n\t\n}", "@EventHandler\r\n \tpublic void onEntityExplode(EntityExplodeEvent event) \r\n \t{\n \t\tif (event.getEntityType() == EntityType.PRIMED_TNT) \r\n \t\t{\r\n \t\t\tLocation eventLoc = event.getLocation();\r\n \t\t\tServer server = plugin.getServer();\r\n \t\t\t\r\n \t\t\t// Red towers\r\n \t\t\tif (redBuildings.DestroyBuilding(BuildingType.Tower, eventLoc))\r\n \t\t\t{\r\n \t\t\t\ttowerCounts.put(\"red\", redBuildings.BuildingsCount(BuildingType.Tower));\r\n\t\t\t\tserver.broadcastMessage(ChatColor.YELLOW + \"A \"+ ChatColor.RED + \"RED\" + ChatColor.YELLOW + \" Tower Has Been Destroyed! (\" + towerCounts.get(\"red\") + \" remaining)\");\r\n\r\n\t\t\t\t// Check if all towers are destroyed\r\n \t\t\t\t\r\n \t\t\t\tif (towerCounts.get(\"red\") == 0) \r\n \t\t\t\t\tserver.broadcastMessage(ChatColor.YELLOW + \"All \"+ ChatColor.RED + \"RED\" + ChatColor.YELLOW + \" Towers Are Destroyed! Defend the NEXUS!\");\r\n \t\t\t}\r\n \t\t\t\r\n \t\t\t// Blue Towers\r\n \t\t\tif (blueBuildings.DestroyBuilding(BuildingType.Tower, eventLoc))\r\n \t\t\t{\r\n \t\t\t\ttowerCounts.put(\"blue\", blueBuildings.BuildingsCount(BuildingType.Tower));\r\n\t\t\t\tserver.broadcastMessage(ChatColor.YELLOW + \"A \"+ ChatColor.BLUE + \"BLUE\" + ChatColor.YELLOW + \" Tower Has Been Destroyed! (\" + towerCounts.get(\"blue\") + \" remaining)\");\r\n \r\n \t\t\t\t// Check if all towers are destroyed\r\n \t\t\t\tif (towerCounts.get(\"blue\") == 0) \r\n \t\t\t\t\tserver.broadcastMessage(ChatColor.YELLOW + \"All \"+ ChatColor.BLUE + \"BLUE\" + ChatColor.YELLOW + \" Towers Are Destroyed! Defend the NEXUS!\");\r\n \t\t\t}\r\n \t\t\t\r\n \t\t\t\r\n \t\t\t// Nexus\r\n \t\t\tif (redBuildings.DestroyBuilding(BuildingType.Nexus, eventLoc))\r\n \t\t\t{\r\n \t\t\t\tserver.broadcastMessage(ChatColor.RED + \"The RED NEXUS Has Been Destroyed!\" + ChatColor.BLUE + \" BLUE WINS!\");\r\n \t\t\t}\r\n \t\t\telse if (blueBuildings.DestroyBuilding(BuildingType.Nexus, eventLoc))\r\n \t\t\t{\r\n \t\t\t\tserver.broadcastMessage(ChatColor.BLUE + \"The BLUE NEXUS Has Been Destroyed!\" + ChatColor.RED + \" RED WINS!\");\r\n \t\t\t}\r\n \t\t}\r\n \t\t\r\n \t}", "protected Item getDropItem() {\r\n\t\treturn SorceryItems.goldfeather;\r\n\t}", "@SideOnly(Side.CLIENT)\n/* */ public void addInformation(ItemStack par1ItemStack, EntityPlayer par2EntityPlayer, List<String> par3List, boolean par4) {\n/* 59 */ if (GuiScreen.isShiftKeyDown()) {\n/* 60 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome1.lore\"));\n/* 61 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome2.lore\"));\n/* 62 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome3.lore\"));\n/* 63 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* 64 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome4.lore\"));\n/* 65 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome5.lore\"));\n/* 66 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* 67 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome6.lore\"));\n/* 68 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome7.lore\"));\n/* 69 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome8.lore\"));\n/* 70 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* 71 */ par3List.add(StatCollector.translateToLocal(\"item.ItemSoulTome9.lore\"));\n/* 72 */ } else if (GuiScreen.isCtrlKeyDown()) {\n/* 73 */ par3List.add(StatCollector.translateToLocal(\"item.FRVisPerSecond.lore\"));\n/* 74 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRAerCost.lore\") + (AerCost / 100.0D * 10.0D));\n/* 75 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRTerraCost.lore\") + (TerraCost / 100.0D * 10.0D));\n/* 76 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRIgnisCost.lore\") + (IgnisCost / 100.0D * 10.0D));\n/* 77 */ this; par3List.add(\" \" + StatCollector.translateToLocal(\"item.FRPerditioCost.lore\") + (PerditioCost / 100.0D * 10.0D));\n/* */ } else {\n/* */ \n/* 80 */ par3List.add(StatCollector.translateToLocal(\"item.FRShiftTooltip.lore\"));\n/* 81 */ par3List.add(StatCollector.translateToLocal(\"item.FRViscostTooltip.lore\"));\n/* */ } \n/* */ \n/* 84 */ par3List.add(StatCollector.translateToLocal(\"item.FREmpty.lore\"));\n/* */ }", "public static void addDrop(int npcId, int itemId, int minimum, int maximum, Drop.RARITY rarity, Drop.CONDITION condition) {\n if (DropTable.dropTables == null) {\n DropTable.dropTables = new HashMap<>();\n DropTable.deSerialize(file);\n }\n\n DropTable dropTable;\n\n /**\n * Check to see if we already have a entry for the npc id. If we don't then we will make a new table for that npc.\n */\n if (DropTable.dropTables.containsKey(npcId)) {\n dropTable = DropTable.dropTables.get(npcId);\n } else {\n dropTable = new DropTable();\n dropTable.id = npcId;\n DropTable.dropTables.put(dropTable.id, dropTable);\n }\n\n /**\n * Makes a new empty drop and sets the values for the drop.\n */\n Drop drop = new Drop();\n drop.setItem(itemId);\n drop.setMinimum(minimum);\n drop.setMaximum(maximum);\n drop.setRarity(rarity);\n drop.setCondition(condition);\n\n\n /**\n * Add the drop to the drop table.\n */\n dropTable.drops.add(drop);\n }", "@EventHandler\n\tpublic void onDispenserThrow(BlockDispenseEvent e){\n\t\t\n\t\tItemStack item = e.getItem();\n\t\tfromDisp = true; //prevents launched eggs from glowing\n\t\t\n\t\tif(item.hasItemMeta()){\n\t\t\tif(item.getItemMeta().hasLore()){\n\t\t\t\tif(item.getItemMeta().getLore().contains(ChatColor.MAGIC + \"lootEgg\")){\n\t\t\t\t\te.setCancelled(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t}", "public Item getItemDropped(IBlockState state, Random rand, int fortune)\n {\n \treturn this == InitBlocksEA.arcanite_ore ? InitItemsEA.arcanite : (this == InitBlocksEA.draconium_ore ? InitItemsEA.draconium_dust : (this == InitBlocksEA.velious_ore ? InitItemsEA.velious : (this == InitBlocksEA.katcheen_ore ? InitItemsEA.katcheen : (this == InitBlocksEA.necrocite_ore ? InitItemsEA.necrocite : (this == InitBlocksEA.soularite_ore ? InitItemsEA.soularite : Item.getItemFromBlock(this))))));\n \t\n //return this == EbonArtsBlocks.arcanite_ore ? EbonArtsItems.arcanite_shard : (this == Blocks.diamond_ore ? Items.diamond : (this == Blocks.lapis_ore ? Items.dye : (this == Blocks.emerald_ore ? Items.emerald : (this == Blocks.quartz_ore ? Items.quartz : Item.getItemFromBlock(this)))));\n }", "public abstract int doDamage(int time, GenericMovableUnit unit, Unit target);", "public void randomEvent(){\n /*Pick a random number dictating the events that could happen.\n * 1: New gun for player\n * 2: Paying Liu Yuen\n * 3: Repairing the Ship\n */\n RandomEventLogic randomEventLogic = new RandomEventLogic(getPlayer());\n int[] randEvent = randomEventLogic.randEvent();\n int eventNumber = randEvent[0];\n int itemPrice = randEvent[1];\n\n if(eventNumber == 1){\n System.out.println(\"\\nA vendor is selling a gun for $\" + itemPrice + \" for a gun?\");\n }\n if(eventNumber == 2){\n System.out.println(\"\\nLiu Yuen asks $\" + itemPrice + \" in donation to the temple of Tin Hau, the Sea Goddess\");\n }\n if(eventNumber == 3){\n System.out.println(\"\\nMc Henry from the Hong Kong shipyard has arrived,\\nwould be willing to repair your ship for $\" + itemPrice);\n }\n\n //Only runs if the player doesn't have enough space and is given a gun\n if((eventNumber == 1 && getCargoSpace() < 10)){\n TaipanShopText taipanShopText = new TaipanShopText(getPlayer());\n taipanShopText.shop();\n }\n //Only runs if the player has 100 or greater HP and they got the ship repair man\n if((eventNumber == 3 && getPlayer().getHP() >= 100)){\n TaipanShopText taipanShopText = new TaipanShopText(getPlayer());\n taipanShopText.shop();\n }\n\n //Runs for as long as the player doesn't decide if they want to pay\n while(true){\n System.out.println(\"Would you like to pay? (Y)es or (N)o\");\n Scanner keyboard = new Scanner(System.in);\n String input = keyboard.next();\n if (input.equalsIgnoreCase(\"Y\") && getPlayer().getMoney() > itemPrice) {\n //Buy Guns\n if (eventNumber == 1 && (getCargoSpace() >= 10)) {\n setGuns(getPlayer().getGuns() + 1);\n setMoney(getPlayer().getMoney() - itemPrice);\n\n TaipanShopText taipanShopText = new TaipanShopText(getPlayer());\n taipanShopText.shop();\n }\n\n //Liu Yuen\n if (eventNumber == 2) {\n setAttackingShips(false);\n setMoney(getPlayer().getMoney() - itemPrice);\n\n TaipanShopText taipanShopText = new TaipanShopText(getPlayer());\n taipanShopText.shop();\n }\n\n //Ship Repair\n if (eventNumber == 3 && getPlayer().getHP() != 100) {\n setHP(100);\n setMoney(getPlayer().getMoney() - itemPrice);\n\n TaipanShopText taipanShopText = new TaipanShopText(getPlayer());\n taipanShopText.shop();\n }\n\n\n }\n else {\n System.out.println(\"Sorry you don't have enough money\");\n }\n //If the player decides to leave then it will send them back to TaipanShop\n if(input.equalsIgnoreCase(\"N\")){\n System.out.println(\"Aye aye Taipan, we'll send them off!\\n\");\n TaipanShopText taipanShopText = new TaipanShopText(getPlayer());\n taipanShopText.shop();\n }\n }\n\n }", "public void fireOnItemAddedToInventoryCommands();", "private void generateItemEntities(){\n final int NUM_POTIONS = 6;\n final int NUM_IRON_ARMOUR = 1;\n final int NUM_CHESTS = 2;\n final String ITEM_BOX_STYLE = \"volcano\";\n\n\n for (int i = 0; i < NUM_POTIONS; i++) {\n Tile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n Item.randomItemPositionGenerator(DEFAULT_HEIGHT));\n if (Integer.parseInt(tile.getTextureName().split(\"_\")[1]) < 5\n && !tile.hasParent()) {\n HealthPotion potion = new HealthPotion(tile,false,\n (PlayerPeon) getPlayerEntity(), ITEM_BOX_STYLE);\n entities.add(potion);\n this.allVolcanoDialogues.add(potion.getDisplay());\n } else {\n i--;\n }\n }\n for (int i =0; i < NUM_IRON_ARMOUR; i++){\n Tile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n Item.randomItemPositionGenerator(DEFAULT_HEIGHT));\n if (Integer.parseInt(tile.getTextureName().split(\"_\")[1]) < 5\n && !tile.hasParent()) {\n IronArmour ironArmour = new IronArmour(tile, false,\n (PlayerPeon) getPlayerEntity(),ITEM_BOX_STYLE,200);\n entities.add(ironArmour);\n this.allVolcanoDialogues.add(ironArmour.getDisplay());\n } else {\n i--;\n }\n }\n for (int i = 0; i <NUM_CHESTS; i++){\n Tile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n Item.randomItemPositionGenerator(DEFAULT_HEIGHT));\n if (Integer.parseInt(tile.getTextureName().split(\"_\")[1]) < 5\n && !tile.hasParent()) {\n Treasure chest = new Treasure(tile, false,\n (PlayerPeon) getPlayerEntity(),ITEM_BOX_STYLE);\n entities.add(chest);\n this.allVolcanoDialogues.add(chest.getDisplay());\n } else {\n i--;\n }\n }\n\n Tile cooldownring = getTile(20,-7);\n CooldownRing cdring = new CooldownRing(cooldownring, false,\n (PlayerPeon) this.getPlayerEntity(), ITEM_BOX_STYLE,0.5f);\n entities.add(cdring);\n this.allVolcanoDialogues.add(cdring.getDisplay());\n\n Tile attackAmuletTile = getTile(2,14);\n Amulet attackAmulet = new Amulet(attackAmuletTile, false,\n (PlayerPeon) this.getPlayerEntity(), ITEM_BOX_STYLE,10);\n entities.add(attackAmulet);\n this.allVolcanoDialogues.add(attackAmulet.getDisplay());\n\n }", "boolean hasBonusItemDrop();", "@SubscribeEvent\n public void spawnMobs(WorldTickEvent event)\n {\n if(event.phase == TickEvent.Phase.END && event.world.provider.getDimension() == 0\n && event.side == Side.SERVER && event.world.playerEntities.size() > 0)\n {\n //fires at 10PM every in-game day\n if(event.world.getWorldTime()%23999 == 16000)\n {\n //gets a list of all players in-game\n List<EntityPlayer> players = event.world.playerEntities;\n ArrayList<BlockPos> spawnpoints = new ArrayList<>();\n\n //gets the current day in-game\n int currDay = DifficultyScaling.getCurrDay(event.world);\n Random rand = new Random();\n\n if(DifficultyScaling.getCurrWeek(event.world) > 0)\n {\n //sets the current difficulty\n difficulty = DifficultyScaling.getDifficulty(currDay);\n\n //populates spawnpoints... creates 5 spawnpoints around each players\n for (int i = 0; i < players.size(); i++)\n {\n BlockPos playerPos = players.get(i).getPosition();\n for (int k = 0; k < 5; k++)\n {\n int x = playerPos.getX(), y, z = playerPos.getZ();\n int posOrNeg = rand.nextInt(2);\n\n if(posOrNeg == 0)\n x = rand.nextInt(15) + 15 + x;\n else\n x = rand.nextInt(15) - 30 + x;\n\n posOrNeg = rand.nextInt(2);\n if(posOrNeg == 0)\n z = rand.nextInt(15) + 15 + z;\n else\n z = rand.nextInt(15) - 30 + z;\n\n y = event.world.getHeight(x, z);\n\n spawnpoints.add(new BlockPos(x, y, z));\n }\n }\n\n //Sets the adjusted amount of mobs\n int creepersToSpawn = (int) (baseSpawnCreeper * (difficulty + (players.size() - 1) * 1.2));\n int zombiesToSpawn = (int) (baseSpawnZombie * (difficulty + (players.size() - 1) * 1.2));\n int endermenToSpawn = (int) (baseSpawnEnderman * (difficulty + (players.size() - 1) * 1.2));\n int totalMobsToSpawn = creepersToSpawn + zombiesToSpawn + endermenToSpawn;\n\n spawnMobs(event.world, spawnpoints, players, zombiesToSpawn, endermenToSpawn, creepersToSpawn);\n\n for(int i = 0; i < players.size(); i++)\n players.get(i).sendMessage(new TextComponentString(\"Number of mobs spawned: \" + totalMobsToSpawn));\n }\n //goes through the playerlist and messages them that it's 10pm at 10pm\n for(int k = 0; k < players.size(); k++)\n {\n players.get(k).sendMessage(new TextComponentString(\"Time: \" + (event.world.getWorldTime()%24000)/10));\n players.get(k).sendMessage(new TextComponentString(\"Day: \" + (DifficultyScaling.getCurrDay(event.world) + 1)));\n players.get(k).sendMessage(new TextComponentString(\"Week: \" + DifficultyScaling.getCurrWeek(event.world)));\n\n }\n }\n }\n }", "@Override\r\n public Collection<Item> roll() {\r\n Collection<Item> dropItems = new ArrayList();\r\n \r\n for (LootTableItem item : this.items) {\r\n if (random.nextDouble() <= 1 / item.getChance()) {\r\n dropItems.add(item.create());\r\n }\r\n if (dropItems.size() == amount) break;\r\n }\r\n \r\n return dropItems;\r\n }", "@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)\r\n public void onPlayerDamagedByPlayer(final EntityDamageByEntityEvent event) {\n if (!(event.getEntity() instanceof Player)) {\r\n return;\r\n }\r\n if (!(event.getDamager() instanceof Player)) {\r\n return;\r\n }\r\n \r\n final Player target = (Player)event.getEntity();\r\n final Player attacker = (Player)event.getDamager();\r\n final ItemStack is = attacker.getItemInHand();\r\n \r\n if (is != null){\r\n switch (is.getType()){\r\n case EMERALD:\r\n attacker.setItemInHand(ItemUtil.decrementItem(is, 1));\r\n \r\n // 体力・空腹回復、燃えてたら消化\r\n target.setHealth(target.getMaxHealth());\r\n target.setFoodLevel(20);\r\n target.setFireTicks(0);\r\n \r\n // ポーション効果付与\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.REGENERATION, 45 * 20, 0)); // 45 secs\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.FIRE_RESISTANCE, 7 * 60 * 20, 0)); // 7 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.INCREASE_DAMAGE, 9 * 60 * 20, 1)); // 9 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.SPEED, 9 * 60 * 20, 0)); // 9 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.FAST_DIGGING, 5 * 60 * 20, 1)); // 5 mins\r\n target.addPotionEffect(new PotionEffect(PotionEffectType.NIGHT_VISION, 3 * 60 * 20, 0)); // 3 mins\r\n \r\n // effect, messaging\r\n target.getWorld().playEffect(target.getLocation(), Effect.ENDER_SIGNAL, 0, 10);\r\n Util.message(target, PlayerManager.getPlayer(attacker).getName() + \" &aから特殊効果を与えられました!\");\r\n Util.message(attacker, PlayerManager.getPlayer(target).getName() + \" &aに特殊効果を与えました!\");\r\n \r\n event.setCancelled(true);\r\n event.setDamage(0);\r\n break;\r\n default: break;\r\n }\r\n }\r\n }", "public void customizeMob(LivingEntity mob, LeveledMonster leveledMonster, CreatureSpawnEvent.SpawnReason spawnReason){\n mob.getPersistentDataContainer().set(monsterIdKey, PersistentDataType.STRING, leveledMonster.getName());\n assert mob.getEquipment() != null;\n mob.getEquipment().setHelmet(leveledMonster.getHelmet());\n mob.getEquipment().setChestplate(leveledMonster.getChestPlate());\n mob.getEquipment().setLeggings(leveledMonster.getLeggings());\n mob.getEquipment().setBoots(leveledMonster.getBoots());\n mob.getEquipment().setItemInMainHand(leveledMonster.getMainHand());\n mob.getEquipment().setItemInOffHand(leveledMonster.getOffHand());\n\n mob.getEquipment().setHelmetDropChance((float) leveledMonster.getHelmetDropChance());\n mob.getEquipment().setChestplateDropChance((float) leveledMonster.getChestplateDropChance());\n mob.getEquipment().setLeggingsDropChance((float) leveledMonster.getLeggingsDropChance());\n mob.getEquipment().setBootsDropChance((float) leveledMonster.getBootsDropChance());\n mob.getEquipment().setItemInMainHandDropChance((float) leveledMonster.getMainHandDropChance());\n mob.getEquipment().setItemInOffHandDropChance((float) leveledMonster.getOffHandDropChance());\n\n if (leveledMonster.getMainHand() != null){\n mob.setCanPickupItems(false);\n }\n\n AttributeInstance attribute = mob.getAttribute(Attribute.GENERIC_MAX_HEALTH);\n assert attribute != null;\n if (mob instanceof Slime){\n Slime slime = (Slime) mob;\n attribute.setBaseValue(leveledMonster.getBaseHealth() / (16/Math.pow(slime.getSize(), 2)));\n mob.setHealth(leveledMonster.getBaseHealth() / (16/Math.pow(slime.getSize(), 2)));\n } else {\n attribute.setBaseValue(leveledMonster.getBaseHealth());\n mob.setHealth(leveledMonster.getBaseHealth());\n }\n if (leveledMonster.getDisplayName() != null){\n if (!leveledMonster.getDisplayName().equals(\"null\")){\n mob.setCustomName(leveledMonster.getDisplayName());\n mob.setCustomNameVisible(leveledMonster.isDisplayNameVisible());\n }\n }\n if (leveledMonster.isBoss()){\n String title = leveledMonster.getDisplayName();\n if (leveledMonster.getDisplayName() == null){\n title = Utils.chat(\"&c&lBoss\");\n } else if (leveledMonster.getDisplayName().equals(\"null\")){\n title = Utils.chat(\"&c&lBoss\");\n }\n Utils.createBossBar(Main.getInstance(), mob, title, BarColor.RED, BarStyle.SOLID, Main.getInstance().getConfig().getInt(\"boss_bar_view_distance\"));\n }\n\n for (String key : leveledMonster.getAbilities()){\n Ability instantAbility = AbilityManager.getInstance().getInstantAbilities().get(key);\n if (instantAbility != null){\n instantAbility.execute(mob, null, new CreatureSpawnEvent(mob, spawnReason));\n }\n Ability runningAbility = AbilityManager.getInstance().getRunningAbilities().get(key);\n if (runningAbility != null){\n runningAbility.execute(mob, null, new CreatureSpawnEvent(mob, spawnReason));\n }\n }\n }", "@Override\n public int quantityDropped(int meta, int fortune, Random random)\n {\n return super.quantityDropped(meta, fortune, random);\n }", "private void registerDungeonLoot() {\n\t\tChestGenHooks dungeon = ChestGenHooks.getInfo(ChestGenHooks.DUNGEON_CHEST);\n\t\tChestGenHooks pyramid = ChestGenHooks.getInfo(ChestGenHooks.PYRAMID_DESERT_CHEST);\n\t\tChestGenHooks jtemple = ChestGenHooks.getInfo(ChestGenHooks.PYRAMID_JUNGLE_CHEST);\n\t\t\n\t\tWeightedRandomChestContent disc1WRCC = new WeightedRandomChestContent(new ItemStack(turretRec1), 1, 1, 5);\n\t\tWeightedRandomChestContent httmWRCC = new WeightedRandomChestContent(new ItemStack(httm), 1, 1, 5);\n\t\t\n\t\tdungeon.addItem(disc1WRCC);\n\t\tpyramid.addItem(disc1WRCC);\n\t\tpyramid.addItem(httmWRCC);\n\t\tjtemple.addItem(disc1WRCC);\n\t\tjtemple.addItem(httmWRCC);\n\t}", "@Override\n public Item getItemDropped(IBlockState state, Random rand, int fortune) {\n return this == BlockHandler.rubyore ? ItemHandler.ruby : (this == BlockHandler.sapphireore ? ItemHandler.sapphire : (this == BlockHandler.topazore ? ItemHandler.topaz : (this == BlockHandler.peridotore ? ItemHandler.peridot : (this == BlockHandler.amethystore ? ItemHandler.amethyst : (this == BlockHandler.berylore ? ItemHandler.beryl : (this == BlockHandler.citrineore ? ItemHandler.citrine : Item.getItemFromBlock(this)))))));\n }", "public static boolean[] drop(String enemy, int enemyHealth, int enemyDamage, int playerHealth, int playerDamage, int elixirCount, int elixirHealth, int wins, boolean[] items, int itemCount, int level) {\r\n //Level 2\r\n if (level == 2) {\r\n if (itemCount < 4) {\r\n items[wins-1] = true;\r\n }\r\n }\r\n //Level 3\r\n if (level == 3) {\r\n boolean chance = chance();\r\n if ((chance) && (itemCount < 4)) {\r\n items[wins-1] = true;\r\n }\r\n }\r\n return items;\r\n }", "@EventHandler\r\n\tpublic void OnKill(final EntityDeathEvent event) {\n\t\tif (!plugin.getDependencyManager().getDependency(dependency.STATS)\r\n\t\t\t\t.isAvailable())\r\n\t\t\treturn;\r\n\r\n\t\tEntity e = event.getEntity();\r\n\t\tif (e.getLastDamageCause() instanceof EntityDamageByEntityEvent) {\r\n\t\t\tEntityDamageByEntityEvent nEvent = (EntityDamageByEntityEvent) e\r\n\t\t\t\t\t.getLastDamageCause();\r\n\t\t\tif (nEvent.getDamager() instanceof Player) {\r\n\r\n\t\t\t\tString extraType = null;\r\n\r\n\t\t\t\tif (e instanceof Skeleton) {\r\n\t\t\t\t\tSkeleton ske = (Skeleton) e;\r\n\r\n\t\t\t\t\tif (ske.getSkeletonType() == SkeletonType.WITHER) {\r\n\t\t\t\t\t\textraType = \"WITHER\";\r\n\t\t\t\t\t}\r\n\t\t\t\t} else if (e instanceof Creeper) {\r\n\t\t\t\t\tCreeper cre = (Creeper) e;\r\n\r\n\t\t\t\t\tif (cre.isPowered()) {\r\n\t\t\t\t\t\textraType = \"POWERED\";\r\n\t\t\t\t\t}\r\n\t\t\t\t} else if (e instanceof Chicken) {\r\n\t\t\t\t\tChicken mob = (Chicken) e;\r\n\r\n\t\t\t\t\tif (mob.getPassenger() != null) {\r\n\t\t\t\t\t\textraType = \"JOCKEY\";\r\n\t\t\t\t\t}\r\n\t\t\t\t} else if (e instanceof Rabbit) {\r\n\t\t\t\t\tRabbit mob = (Rabbit) e;\r\n\r\n\t\t\t\t\tif (mob.getRabbitType() == Type.THE_KILLER_BUNNY) {\r\n\t\t\t\t\t\textraType = \"KILLER\";\r\n\t\t\t\t\t}\r\n\t\t\t\t} else if (e instanceof Spider) {\r\n\t\t\t\t\tSpider mob = (Spider) e;\r\n\r\n\t\t\t\t\tif (mob.getPassenger() != null) {\r\n\t\t\t\t\t\textraType = \"JOCKEY\";\r\n\t\t\t\t\t}\r\n\t\t\t\t} else if (e instanceof Guardian) {\r\n\t\t\t\t\tGuardian mob = (Guardian) e;\r\n\r\n\t\t\t\t\tif (mob.isElder()) {\r\n\t\t\t\t\t\textraType = \"ELDER\";\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif (extraType == null) {\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tStatsAPIHandler handler = (StatsAPIHandler) plugin\r\n\t\t\t\t\t\t.getDependencyManager().getDependency(dependency.STATS);\r\n\r\n\t\t\t\tStat mobkilled = handler.getAPI().getStatManager()\r\n\t\t\t\t\t\t.getStat(MobKilledStat.statName);\r\n\r\n\t\t\t\tStatsHolder holder = handler.getAPI().getPlayer(\r\n\t\t\t\t\t\tnEvent.getDamager().getUniqueId());\r\n\r\n\t\t\t\tholder.addEntry(mobkilled, new DefaultStatEntry(1,\r\n\t\t\t\t\t\tnew MetadataPair(\"entityType\", e.getType().toString()),\r\n\t\t\t\t\t\tnew MetadataPair(\"extraType\", extraType),\r\n\t\t\t\t\t\tnew MetadataPair(\"world\", e.getLocation().getWorld()\r\n\t\t\t\t\t\t\t\t.getName().toString())));\r\n\r\n\t\t\t}\r\n\t\t}\r\n\t}", "@Override\n public int getMaxItemUseDuration(ItemStack par1ItemStack) {\n return 10;\n }", "@SubscribeEvent\n public void onItemUseFinish(LivingEntityUseItemEvent.Start event) {\n boolean didTeleport = false;\n\n if (teleportStabilize\n && event.getEntityLiving() instanceof PlayerEntity\n && event.getItem().getItem() == Items.CHORUS_FRUIT\n && !event.getEntityLiving().getEntityWorld().isRemote\n ) {\n World world = event.getEntityLiving().world;\n PlayerEntity player = (PlayerEntity) event.getEntityLiving();\n Map<Double, BlockPos> positions = new HashMap<>();\n BlockPos playerPos = player.getPosition();\n BlockPos targetPos = null;\n\n // find the blocks around the player\n BlockPos.getAllInBox(playerPos.add(-range, -range, -range), playerPos.add(range, range, range)).forEach(pos -> {\n if (world.getBlockState(pos).getBlock() == block && !pos.up(1).equals(playerPos)) {\n\n // should be able to stand on it\n if (world.getBlockState(pos.up(1)).getMaterial() == Material.AIR && world.getBlockState(pos.up(2)).getMaterial() == Material.AIR) {\n positions.put(WorldHelper.getDistanceSq(playerPos, pos.up(1)), pos.up(1));\n }\n }\n });\n\n // get the closest position by finding the smallest distance\n if (!positions.isEmpty()) {\n targetPos = positions.get(Collections.min(positions.keySet()));\n }\n\n if (targetPos != null) {\n double x = targetPos.getX() + 0.5D;\n double y = targetPos.getY();\n double z = targetPos.getZ() + 0.5D;\n if (player.attemptTeleport(x, y, z, true)) {\n didTeleport = true;\n\n // play sound at original location and new location\n world.playSound(null, x, y, z, SoundEvents.ITEM_CHORUS_FRUIT_TELEPORT, SoundCategory.PLAYERS, 1.0F, 1.0F);\n player.playSound(SoundEvents.ITEM_CHORUS_FRUIT_TELEPORT, 1.0F, 1.0F);\n }\n }\n\n if (didTeleport) {\n player.getCooldownTracker().setCooldown(Items.CHORUS_FRUIT, 20);\n event.getItem().shrink(1);\n event.setCanceled(true);\n }\n }\n }", "public static ItemDespawnEvent callItemDespawnEvent(EntityItem entityitem) {\n/* 327 */ Item entity = (Item)entityitem.getBukkitEntity();\n/* */ \n/* 329 */ ItemDespawnEvent event = new ItemDespawnEvent(entity, entity.getLocation());\n/* */ \n/* 331 */ entity.getServer().getPluginManager().callEvent((Event)event);\n/* 332 */ return event;\n/* */ }", "protected void doItemDrop(Location loc, Player player, ItemStack itemStack) {\n // To avoid drops occasionally spawning in a block and warping up to the\n // surface, wait for the next tick and check whether the block is\n // actually unobstructed. We don't attempt to save the drop if e.g.\n // a mob is standing in lava, however.\n Bukkit.getScheduler().scheduleSyncDelayedTask(BeastMaster.PLUGIN, () -> {\n Block block = loc.getBlock();\n Location revisedLoc = (block != null &&\n !canAccomodateItemDrop(block) &&\n player != null) ? player.getLocation()\n : loc;\n org.bukkit.entity.Item item = revisedLoc.getWorld().dropItem(revisedLoc, itemStack);\n item.setInvulnerable(isInvulnerable());\n item.setGlowing(isGlowing());\n }, 1);\n }", "public ItemStack createItem(ItemType type, int damage,List<Text> lore);", "public void onUsingTick(ItemStack stack, EntityPlayer player, int count) {\n/* 132 */ player.motionX = 0.0D;\n/* 133 */ player.motionZ = 0.0D;\n/* */ \n/* 135 */ int searchRange = 20;\n/* 136 */ List<EntityLivingBase> entities = player.worldObj.getEntitiesWithinAABB(EntityLivingBase.class, AxisAlignedBB.getBoundingBox(player.posX - searchRange, player.posY - searchRange, player.posZ - searchRange, player.posX + searchRange, player.posY + searchRange, player.posZ + searchRange));\n/* */ \n/* 138 */ if (entities.contains(player)) {\n/* 139 */ entities.remove(player);\n/* */ }\n/* 141 */ if (count < getMaxItemUseDuration(stack) - 20) {\n/* 142 */ for (int counter = entities.size() - 1; counter >= 0; counter--) {\n/* 143 */ if (player.getDistanceToEntity((Entity)entities.get(counter)) <= 3.0F && \n/* 144 */ WandManager.consumeVisFromInventory(player, (new AspectList()).add(Aspect.FIRE, (int)(150.0F * RelicsConfigHandler.soulTomeVisMult)).add(Aspect.ENTROPY, (int)(120.0F * RelicsConfigHandler.soulTomeVisMult)))) {\n/* */ \n/* 146 */ EntityLivingBase thrownEntity = entities.get(counter);\n/* */ \n/* 148 */ Vector3 entityVec = Vector3.fromEntityCenter((Entity)thrownEntity);\n/* 149 */ Vector3 playerVec = Vector3.fromEntityCenter((Entity)player);\n/* */ \n/* 151 */ Vector3 diff = entityVec.copy().sub(playerVec).multiply((1.0F / player.getDistanceToEntity((Entity)thrownEntity) * 3.0F));\n/* */ \n/* 153 */ float curve = (float)(1.0D / player.getDistance(entityVec.x, entityVec.y, entityVec.z) * 8.0D);\n/* */ \n/* 155 */ if (!player.worldObj.isRemote)\n/* 156 */ for (int counterZ = 0; counterZ <= 3; counterZ++) {\n/* 157 */ Main.proxy.lightning(player.worldObj, player.posX, player.posY + 1.0D, player.posZ, entityVec.x, entityVec.y, entityVec.z, 40, curve, (int)(player.getDistance(entityVec.x, entityVec.y, entityVec.z) * 6.0D), 0, 0.075F);\n/* */ } \n/* 159 */ player.worldObj.playSoundAtEntity((Entity)player, \"thaumcraft:zap\", 1.0F, 0.8F);\n/* */ \n/* 161 */ thrownEntity.attackEntityFrom((DamageSource)new DamageRegistryHandler.DamageSourceTLightning((Entity)player), (float)(20.0D + 80.0D * Math.random()));\n/* */ \n/* 163 */ thrownEntity.motionX = diff.x;\n/* 164 */ thrownEntity.motionY = diff.y + 1.0D;\n/* 165 */ thrownEntity.motionZ = diff.z;\n/* */ } \n/* */ } \n/* */ }\n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* */ \n/* 195 */ this; this; this; this; if ((((count < getMaxItemUseDuration(stack) - 20) ? 1 : 0) & ((count % 4 == 0) ? 1 : 0)) != 0 && WandManager.consumeVisFromInventory(player, (new AspectList()).add(Aspect.EARTH, TerraCost).add(Aspect.AIR, AerCost).add(Aspect.FIRE, IgnisCost).add(Aspect.ENTROPY, PerditioCost))) {\n/* */ \n/* 197 */ EntityLivingBase randomEntity = null;\n/* */ \n/* 199 */ if (entities.size() > 0) {\n/* 200 */ randomEntity = entities.get((int)(entities.size() * Math.random()));\n/* */ }\n/* 202 */ if ((((randomEntity != null) ? 1 : 0) & (!player.worldObj.isRemote ? 1 : 0)) != 0) {\n/* */ \n/* 204 */ float soulDamage = randomEntity.getMaxHealth() / RelicsConfigHandler.soulTomeDivisor;\n/* */ \n/* 206 */ if (soulDamage > 20.0F) {\n/* 207 */ soulDamage = 20.0F;\n/* 208 */ } else if (soulDamage < 1.0F) {\n/* 209 */ soulDamage = 1.0F;\n/* */ } \n/* 211 */ randomEntity.attackEntityFrom((DamageSource)new DamageRegistryHandler.DamageSourceSoulDrain((Entity)player), soulDamage);\n/* 212 */ spawnSoul(player.worldObj, randomEntity, (EntityLivingBase)player);\n/* */ } \n/* */ } \n/* */ }", "@EventHandler ( priority = EventPriority.HIGHEST )\n\tpublic void onThrow ( PlayerInteractEvent event ) {\n\t\tfinal Action action = event.getAction();\n\t\tif (action != Action.RIGHT_CLICK_AIR \n\t\t\t\t&& action != Action.LEFT_CLICK_AIR) { // check is left or right click to air.\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// get event values.\n\t\tfinal Player p = event.getPlayer();\n\t\tfinal BRPlayer bp = BRPlayer.getBRPlayer(p);\n\t\tfinal ItemStack stack = event.getItem();\n\t\t\n\t\t// check item.\n\t\tif (!BattleItems.TNT_GRENADE.isThis(stack)) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t/* check is not knocked */\n\t\tif (!bp.isKnocked()) {\n\t\t\t// spawn and modify tnt if the event is not cancelled\n\t\t\tfinal TNTPrimed tnt = (TNTPrimed) p.getWorld().spawn(p.getLocation(), TNTPrimed.class);\n\t\t\tMemberThrowTNT evemt = new MemberThrowTNT(bp, tnt).call();\n\t\t\tif (evemt.isCancelled()) {\n\t\t\t\ttnt.remove();\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\t/* apply modifiers */\n\t\t\ttnt.setVelocity(p.getLocation().getDirection().clone().multiply(1.1D));\n\t\t\ttnt.setFuseTicks(30); /* 80 by default */\n\t\t\ttnt.setMetadata(TNT_GRENADE_METADATA, new FixedMetadataValue(BattleRoyale.getInstance(), TNT_GRENADE_METADATA));\n\t\t\ttnt.setIsIncendiary(true);\n\t\t\ttnt.setYield(evemt.getExplosionStrength()); /* set explosion strength */\n\t\t\t\n\t\t\t/* consume item */\n\t\t\tif (evemt.isCosumeItemInHand()) {\n\t\t\t\tif (p.getGameMode() != GameMode.CREATIVE) { // check is not in creative mode.\n\t\t\t\t\t// consume.\n\t\t\t\t\tif ((stack.getAmount() - 1) > 0) {\n\t\t\t\t\t\tp.setItemInHand(BattleItems.TNT_GRENADE.asItemStack(stack.getAmount() - 1));\n\t\t\t\t\t} else {\n\t\t\t\t\t\tp.setItemInHand(null);\n\t\t\t\t\t}\n\t\t\t\t\tp.updateInventory();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\t/* cancel interaction */\n\t\tevent.setCancelled(true);\n\t}", "public String getMonsterDropsLoot() {\r\n String res;\r\n Random gen = new Random();\r\n if (gen.nextInt(100) > 75) {\r\n int tmp = gen.nextInt(items.size());\r\n player.addToInventory(items.get(tmp));\r\n res = \"You search the corpse and loot a \" + items.get(tmp).getName() + System.lineSeparator();\r\n } else {\r\n res = \"You find nothing of value on the corpse.\" + System.lineSeparator();\r\n }\r\n return res;\r\n }", "@Override\n\tpublic void onDamage(WorldObj obj, Items item) {\n\n\t\tif(is_stunned) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tint dmg = (int) item.type.ATK;\n\t\t\n\t\tOnScreenText.AddText(\"\"+dmg, bounds.x , bounds.y + 1.1f);\n\t\t\n\t\tvelX = obj.direction * 5;\n\t\tvelY = 5;\n\t\tgrounded = false;\n\t\t\n\t\tHP -= dmg;\n\t\t\n\n\t\tstun_counter = 0;\n\t\t\n\t\tif(HP <= 0 && !isDead) {\n\t\t\tonDeath();\n\t\t}\n\t\t\n\t}", "@Override\n\t public ArrayList<ItemStack> getDrops(World world, int x, int y, int z, int metadata, int fortune)\n {\n \t// DEBUG\n \tSystem.out.println(\"BlockTomato getDrops()\");\n ArrayList<ItemStack> ret = new ArrayList<ItemStack>();\n\n int count = quantityDropped(metadata, fortune, world.rand);\n for(int i = 0; i < count; i++)\n {\n Item item = getItemDropped(metadata, world.rand, fortune);\n if (item != null)\n {\n ret.add(new ItemStack(item, 1, damageDropped(metadata)));\n }\n }\n return ret;\n }", "public Item getItemDropped(int var1, Random var2, int var3)\n {\n if (var2.nextInt(4) == 0)\n {\n return FAItemRegistry.fernSeed;\n }\n return null;\n }", "@Override\n\tpublic void onEntityDamaged(EntityDamageEvent e) {\n\t\t\n\t}", "public int damageDropped(int par1)\r\n/* 155: */ {\r\n/* 156:173 */ if (par1 < 6) {\r\n/* 157:174 */ return 0;\r\n/* 158: */ }\r\n/* 159:175 */ if (par1 < 12) {\r\n/* 160:176 */ return 6;\r\n/* 161: */ }\r\n/* 162:178 */ return par1;\r\n/* 163: */ }", "public int idDropped(int par1, EaglercraftRandom par2Random, int par3) {\n\t\treturn Item.sign.itemID;\n\t}", "void dropHandler() {\n if (tickSpeed < 0) {\n if((int)random(1,6) == 1){ //every 6 medkits the handler drops a minigun\n Sprite mg = new Sprite(minigun);\n mg.moveToPoint(random(0,2048), random(0, 2048)); //moves drop to random point\n minigunDrop.add(mg);\n tickSpeed = (int)random(100,500);\n }else if((int)random(1,4) == 1){ //every 4 medkits the handler drops a coilgun\n Sprite cg = new Sprite(coilgun);\n cg.moveToPoint(random(0,2048), random(0,2048)); //moves drop to random point\n coilgunDrop.add(cg);\n tickSpeed = (int)random(100,500); //changes \n }\n else {\n \n \n Medkit hp = new Medkit();\n hp.med.moveToPoint(random(0, 2048), random(0, 2048));\n\n health.add(hp);\n\n tickSpeed = (int)random(100,500);\n }\n }\n tickSpeed--;\n for (Medkit hp: health) {\n hp.med.display();\n hp.timer--;\n\n }\n for (Sprite mg: minigunDrop){\n mg.display();\n }\n for (Sprite cg: coilgunDrop){\n cg.display();\n }\n // e.forward(5);\n}", "public void dropItem(Item seekItem)\n {\n //get each item from the items's array list.\n for (Item item : items){\n if(item.getName().equals(seekItem.getName())){\n currentRoom.getInventory().getItems().add(item);\n removePlayerItem(item);\n System.out.println(\"You have placed the \"+ item.getName() +\" in the \" + currentRoom.getName() + \".\");\n }\n }\n }", "@EventHandler\r\n\tpublic void onBreak(PlayerItemBreakEvent e) {\r\n\t\tString itemName = getItemName(e.getBrokenItem());\r\n\t\t\r\n\t\tBukkit.broadcastMessage(ChatColor.YELLOW + e.getPlayer().getDisplayName() + \r\n\t\t\t\t\t \t\tChatColor.GRAY + \" broke their \" +\r\n\t\t\t\t\t\t\tChatColor.AQUA + itemName);\r\n\t\tBukkit.broadcastMessage(ChatColor.GRAY + \"\" + ChatColor.ITALIC + \"How unfortunate.\");\r\n\t\t\r\n\t}", "public void dropBlockAsItemWithChance(World var1, int var2, int var3, int var4, int var5, float var6, int var7)\n {\n super.dropBlockAsItemWithChance(var1, var2, var3, var4, var5, var6, var7);\n }", "@EventHandler\n\tpublic void onEggThrown(PlayerEggThrowEvent e){\n\t\t\n\t\tEntity egg = e.getEgg();\n\t\t\n\t\tif(e.getEgg().getCustomName().contains(ChatColor.MAGIC + \"lootEgg\")){\n\t\t\te.setHatching(false);\n\t\t\t\n\t\t\tLocation loc = egg.getLocation();\n\t\t\t\n\t\t\tdropItem(loc);\n\t\t\t\n\t\t}\n\t\t\n\t}", "private void spawnSomeGold() {\n if (goldSpawned.size() >= goldSpawnPoints.size()) {\n return;\n }\n Location loc = goldSpawnPoints.get(random.nextInt(goldSpawnPoints.size()));\n Item item = loc.getWorld().dropItem(loc, new ItemStack(Material.GOLD_INGOT, 1));\n goldSpawned.add(item);\n }", "public void dropNapalm() {\n\t\t// Has player waited cooldown before trying to fire again?\n\t\tif (System.currentTimeMillis() - this.lastFired > Config.WEAPON_COOLDOWN_TIME * 1000) {\n\t\t\tSystem.out.println(player.getDisplayName() + \" is attempting to launch napalm\");\n\t\t\t// Can this airship drop napalm?\n\t\t\tif (this.properties.DROPS_NAPALM) {\n\t\t\t\tBlock[] cannons = getCannons();\n\t\t\t\tint numfiredcannons = 0;\n\t\t\t\tfor (int i = 0; i < cannons.length; i++) {\n\t\t\t\t\tif (cannons[i] != null && cannons[i].getRelative(0, -1, 0).getType().equals(Material.AIR) && cannonHasTnt(cannons[i], Config.NUM_TNT_TO_DROP_NAPALM)) {\n\t\t\t\t\t\tboolean missingMaterial = false;\n\t\t\t\t\t\tfor (int id : Config.MATERIALS_NEEDED_FOR_NAPALM) {\n\t\t\t\t\t\t\tif (!cannonHasItem(cannons[i], id, 1))\n\t\t\t\t\t\t\t\tmissingMaterial = true;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (!missingMaterial && numfiredcannons < this.properties.MAX_NUMBER_OF_CANNONS) {\n\t\t\t\t\t\t\tnumfiredcannons++;\n\t\t\t\t\t\t\tlastFired = System.currentTimeMillis();\n\t\t\t\t\t\t\twithdrawTnt(cannons[i], Config.NUM_TNT_TO_DROP_NAPALM);\n\t\t\t\t\t\t\tfor (int id : Config.MATERIALS_NEEDED_FOR_NAPALM) {\n\t\t\t\t\t\t\t\twithdrawItem(cannons[i], id, 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Fire some napalms TODO: maybe add sound effects for napalm dropping? :P\n\t\t\t\t\t\t\tnew Napalm(cannons[i]);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// More cannons on ship than allowed. Not all fired - can break out of loop now.\n\t\t\t\t\t\t\tplayer.sendMessage(ChatColor.AQUA + \"Some napalm-cannons did not fire. Max cannon limit is \" + ChatColor.GOLD + this.properties.MAX_NUMBER_OF_CANNONS);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else\n\t\t\t\tplayer.sendMessage(ChatColor.GOLD + this.properties.SHIP_TYPE + \" CANNOT DROP NAPALM\");\n\t\t} else\n\t\t\tplayer.sendMessage(ChatColor.GOLD + \"COOLING DOWN FOR \" + ChatColor.AQUA + (int)(Math.round(6 - (System.currentTimeMillis() - this.lastFired) / 1000)) + ChatColor.GOLD + \" MORE SECONDS\");\n\t}", "@EventHandler (priority = EventPriority.HIGHEST)\n \tpublic void onCrafting(CraftItemEvent event){\n \t\tif(event.isCancelled())\n \t\t\treturn;\n \n \t\tHumanEntity he = event.getWhoClicked();\n \t\tif((he instanceof Player)){\n \t\t\tPlayer player = (Player) he;\n \t\t\tAlertType type = AlertType.ILLEGAL;\n \t\t\tif(player.getGameMode() == GameMode.CREATIVE){\n \t\t\t\tif(plugin.isBlocked(player, PermissionNodes.MAKE_ANYTHING, player.getWorld())){\n \t\t\t\t\ttype = AlertType.LEGAL;\n \t\t\t\t}\n \t\t\t\tASRegion region = plugin.getRegionManager().getRegion(player.getLocation());\n \t\t\t\tif(region != null){\n \t\t\t\t\tif(!region.getConfig().isBlocked(event.getRecipe().getResult().getType(), ListType.CRAFTING)){\n \t\t\t\t\t\ttype = AlertType.LEGAL;\n \t\t\t\t\t}\n \t\t\t\t}else{\n \t\t\t\t\tif(config.get(player.getWorld()).isBlocked(event.getRecipe().getResult().getType(), ListType.CRAFTING)){\n \t\t\t\t\t\ttype = AlertType.LEGAL;\n \t\t\t\t\t}\n \t\t\t\t}\n \t\t\t}else{\n \t\t\t\ttype = AlertType.LEGAL;\n \t\t\t}\n \t\t\tString message = ChatColor.YELLOW + player.getName() + ChatColor.WHITE + (type == AlertType.ILLEGAL ? \" tried to craft an item\" : \" crafted an item\");\n \t\t\tString playerMessage = plugin.getMessage(\"blocked-action.crafting\");\n \t\t\tplugin.getAlerts().alert(message, player, playerMessage, type, AlertTrigger.CRAFTING);\n \t\t\tif(type == AlertType.ILLEGAL){\n \t\t\t\tevent.setCancelled(true);\n \t\t\t}\n \t\t}\n \t}", "private void enemyAttack() {\n\t\t\n\t\tRandom rand = new Random();\t\n\t\t\n\t\tint roll = rand.nextInt(101);\n\t\t\n\t\tint sroll = rand.nextInt(101);\n\t\t\n\t\tevents.appendText(e.getName() + \" attacks!\\n\");\n\t\t\n\t\tif(roll <= p.getEV()) { // Player evades\n\t\t\t\n\t\t\tevents.appendText(\"You evaded \"+e.getName()+\"\\'s Attack!\\n\");\n\t\t\t\n\t\t}else if(roll > p.getEV()) { // Player is hit and dies if HP is 0 or less\n\t\t\t\n\t\t\tp.setHP(p.getHP() - e.getDMG());\n\t\t\t\n\t\t\tString newHp = p.getHP()+\"/\"+p.getMaxHP();\n\t\t\t\n\t\t\tString effect = e.getSpecial(); // Stats are afflicted\n\t\t\t\n\t\t\tif(sroll < 51){\n\t\t\t\t\n\t\t\tif(effect == \"Bleed\") { // Bleed Special\n\t\t\t\t\n\t\t\t\tp.setHP(p.getHP() - 100);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You bleed profusely. - 100 HP\\n\");\n\t\t\t\t\n\t\t\t\tnewHp = String.valueOf(p.getHP()+\"/\"+p.getMaxHP());\n\t\t\t}\n\t\t\tif(effect == \"Break\") { // Break Special \n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You feel a bone break restricting movement. - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Fear\") { // Fear Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-40>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 40);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"A crippling fear rattles your resolve. - 40 DMG\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Rend\") { // Rend Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-30>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 30);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"Morthar unleashes a pillar of flame! - 30 DMG and - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\t\n\t\t\tif(p.getHP() <= 0) {\n\t\t\t\t\n\t\t\t\tp.setDead(true);\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(0+\"/\"+e.getMaxHP());\n\t\t\t\tplayerHPBar.setProgress((double)0);\n\t\t\t}else {\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(newHp);\n\t\t\t\tplayerHPBar.setProgress((double)p.getHP()/p.getMaxHP());\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tif(p.isDead()) { // Game over if player dies\n\t\t\t\n\t\t\ttry {\n\t\t\t\tLoadGO();\n\t\t\t} catch (IOException e1) {\n\t\t\t\n\t\t\t\te1.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t\tcombat = false;\n\t\t}\n\t}", "public int getMaxItemUseDuration(ItemStack var1)\r\n {\r\n return 72000;\r\n }", "@Override\n protected boolean preUseCheck(Event event, ItemStack item) {\n return event instanceof EntityDamageByEntityEvent;\n }", "public ItemStack onItemRightClick(ItemStack var1, World var2, EntityPlayer var3)\n {\n float var4 = 1.0F;\n double var5 = var3.prevPosX + (var3.posX - var3.prevPosX) * (double)var4;\n double var7 = var3.prevPosY + (var3.posY - var3.prevPosY) * (double)var4 + 1.62D - (double)var3.yOffset;\n double var9 = var3.prevPosZ + (var3.posZ - var3.prevPosZ) * (double)var4;\n boolean var11 = this.isFull == 0;\n MovingObjectPosition var12 = this.getMovingObjectPositionFromPlayer(var2, var3, var11);\n\n if (var12 == null)\n {\n return var1;\n }\n else\n {\n FillBucketEvent var13 = new FillBucketEvent(var3, var1, var2, var12);\n\n if (MinecraftForge.EVENT_BUS.post(var13))\n {\n return var1;\n }\n else if (var13.getResult() == Event.Result.ALLOW)\n {\n if (var3.capabilities.isCreativeMode)\n {\n return var1;\n }\n else if (--var1.stackSize <= 0)\n {\n return var13.result;\n }\n else\n {\n if (!var3.inventory.addItemStackToInventory(var13.result))\n {\n var3.dropPlayerItem(var13.result);\n }\n\n return var1;\n }\n }\n else\n {\n if (var12.typeOfHit == EnumMovingObjectType.TILE)\n {\n int var14 = var12.blockX;\n int var15 = var12.blockY;\n int var16 = var12.blockZ;\n\n if (!var2.canMineBlock(var3, var14, var15, var16))\n {\n return var1;\n }\n\n if (this.isFull == 0)\n {\n if (!var3.canPlayerEdit(var14, var15, var16, var12.sideHit, var1))\n {\n return var1;\n }\n\n if (var2.getBlockMaterial(var14, var15, var16) == Material.water && var2.getBlockMetadata(var14, var15, var16) == 0)\n {\n var2.setBlockWithNotify(var14, var15, var16, 0);\n\n if (var3.capabilities.isCreativeMode)\n {\n return var1;\n }\n\n if (--var1.stackSize <= 0)\n {\n return new ItemStack(Item.bucketWater);\n }\n\n if (!var3.inventory.addItemStackToInventory(new ItemStack(Item.bucketWater)))\n {\n var3.dropPlayerItem(new ItemStack(Item.bucketWater.itemID, 1, 0));\n }\n\n return var1;\n }\n\n if (var2.getBlockMaterial(var14, var15, var16) == Material.lava && var2.getBlockMetadata(var14, var15, var16) == 0 && var2.getBlockId(var14, var15, var16) == DivineRPG.tarStill.blockID)\n {\n var2.setBlockWithNotify(var14, var15, var16, 0);\n\n if (var3.capabilities.isCreativeMode)\n {\n return var1;\n }\n\n if (--var1.stackSize <= 0)\n {\n return new ItemStack(DivineRPG.tarBucket);\n }\n\n if (!var3.inventory.addItemStackToInventory(new ItemStack(DivineRPG.tarBucket)))\n {\n var3.dropPlayerItem(new ItemStack(DivineRPG.tarBucket.itemID, 1, 0));\n }\n\n return var1;\n }\n }\n else\n {\n if (this.isFull < 0)\n {\n return new ItemStack(DivineRPG.arcaniumBucket);\n }\n\n if (var12.sideHit == 0)\n {\n --var15;\n }\n\n if (var12.sideHit == 1)\n {\n ++var15;\n }\n\n if (var12.sideHit == 2)\n {\n --var16;\n }\n\n if (var12.sideHit == 3)\n {\n ++var16;\n }\n\n if (var12.sideHit == 4)\n {\n --var14;\n }\n\n if (var12.sideHit == 5)\n {\n ++var14;\n }\n\n if (!var3.canPlayerEdit(var14, var15, var16, var12.sideHit, var1))\n {\n return var1;\n }\n\n if (this.tryPlaceContainedLiquid(var2, var5, var7, var9, var14, var15, var16) && !var3.capabilities.isCreativeMode)\n {\n return new ItemStack(DivineRPG.arcaniumBucket);\n }\n }\n }\n\n return var1;\n }\n }\n }", "public void manageDropping(Rectangle r){\n\t\t\tif (!dropping){ //does the random number part\n\t\t\t\tb.reset(x+ 35, y+50);\n\t\t\t\tint d = rand.nextInt(50);\n\t\t\t\t//System.out.println(randamount);\n\t\t\t\tif ((d == 1) && exists) {\n\t\t\t\t\tdropping =true; \n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\telse { //resets the bomb after it has been dropped\n\t\t\t\tif(b.y < 1000) b.dropBomb(dropamount);\n\t\t\t\tbombtimer = 0;\n\t\t\t\t//dropamount += .1;\n\t\t\t\t//dropamount = 5;\n\t\t\t\t\n\t\t\t\tif (b.y >= 700 || b.collided(r)) {\n\t\t\t\t\tif (b.collided(r)) tstartredtimer = true;\n\t\t\t\t\tif (exists) dropping = false;\n\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t}", "void willSpawnAfterDeath(List<String> powerupsInHand) throws RemoteException;", "@Listener\n public void onDeath(DestructEntityEvent.Death event) {\n if (!(event.getTargetEntity() instanceof Player))\n return;\n\n Optional<EntityDamageSource> source = event.getCause().first(EntityDamageSource.class);\n if (!source.isPresent())\n return; // did not die from pvp\n\n Player killed = (Player) event.getTargetEntity();\n\n Player killer = null;\n ItemStack weapon = null;\n Entity damager = source.get().getSource();\n if (damager instanceof Player) {\n killer = (Player) damager;\n weapon = killer.getItemInHand(HandTypes.MAIN_HAND).get();\n }\n\n if (damager instanceof Projectile) {\n Projectile proj = (Projectile) damager;\n if (proj.getShooter() instanceof Player) {\n killer = (Player) proj.getShooter();\n weapon = killer.getItemInHand(HandTypes.MAIN_HAND).get();\n }\n }\n\n if (damager.get(TameableData.class).isPresent()) {\n Optional<UUID> opOwnerUUID = damager.get(TameableData.class).get().owner().get();\n if (opOwnerUUID.isPresent()) {\n UUID uuid = opOwnerUUID.get();\n if (plugin.getServer().getOfflinePlayer(uuid).map(OfflinePlayer::isOnline).orElse(false)) {\n killer = ((SpongePlayer) plugin.getServer().getPlayer(uuid).get()).getHandle();\n // Use a bone to show the case was a wolf\n weapon = ItemStack.builder().itemType(ItemTypes.BONE).quantity(1).build();\n }\n }\n }\n\n if (killer == null)\n return;\n\n // Check the killers world just incase for some reason the\n // killed player was teleported to another world\n if (plugin.getConfigManager().getPvPConfig().getNode(\"ignoredWorlds\").getCollectionValue(String.class).contains(killer.getWorld().getName()))\n return;\n\n TrackerUtil.updatePvPStats(plugin.getServer().getOfflinePlayer(killed.getUniqueId().toString()).get(),\n plugin.getServer().getOfflinePlayer(killer.getUniqueId().toString()).get());\n\n TrackerInterface pvpTracker = plugin.getTrackerManager().getPvPInterface();\n if (pvpTracker.getDeathMessageManager().isDefaultMessagesOverriden())\n event.setMessageCancelled(true);\n\n pvpTracker.getDeathMessageManager().sendItemMessage(killer.getName(), killed.getName(), weapon.getType().getName().toLowerCase());\n pvpTracker.getRecapManager().getDeathRecaps().get(killed.getName()).setVisible(true);\n }", "@EventHandler(ignoreCancelled = false, priority = EventPriority.LOWEST)\n public void onEntityDamage(EntityDamageEvent event)\n {\n if (!event.isCancelled())\n return;\n\n Entity entity = event.getEntity();\n EntityType entityType = entity.getType();\n //First see if EHM's logic is what cancelled this event\n if (entityType == EntityType.DROPPED_ITEM && event.getCause() == EntityDamageEvent.DamageCause.BLOCK_EXPLOSION || event.getCause() == EntityDamageEvent.DamageCause.ENTITY_EXPLOSION)\n {\n event.setCancelled(false);\n }\n else\n return; //otherwise something else cancelled it\n\n //My guess is that it's just a logic error\n if (entityType == EntityType.DROPPED_ITEM && (event.getCause() == EntityDamageEvent.DamageCause.BLOCK_EXPLOSION || event.getCause() == EntityDamageEvent.DamageCause.ENTITY_EXPLOSION))\n event.setCancelled(true);\n }", "@Override\n\t\t\tpublic void onDamaged(DamageEvent e) {\n\t\t\t\tonDamage(e.target, e.item);\n\t\t\t\tbounds.x = e.x;\n\t\t\t\tbounds.y = e.y;\n\t\t\t}", "private void triggerDropItem(double percentage) {\n if (isDropped(percentage)) {\n String name;\n int tar = rd.nextInt(6);\n switch (tar) { // 7 is the total type of building card\n case 0:\n name = \"Sword\";\n break;\n case 1:\n name = \"Stake\";\n break;\n case 2:\n name = \"Staff\";\n break;\n case 3:\n name = \"Shield\";\n break;\n case 4:\n name = \"Helmet\";\n break;\n case 5:\n name = \"Armour\";\n break;\n default:\n return;\n }\n loadItem(name);\n }\n }" ]
[ "0.61209935", "0.6092078", "0.6047468", "0.59486824", "0.5936021", "0.5915317", "0.59131426", "0.5855778", "0.5711046", "0.57031953", "0.5667749", "0.5643615", "0.5631803", "0.5614704", "0.5608842", "0.55895233", "0.558738", "0.5576501", "0.55230874", "0.5505048", "0.55011517", "0.54979235", "0.5493298", "0.54878765", "0.5481136", "0.5466452", "0.5416441", "0.5411138", "0.54028463", "0.540227", "0.5393363", "0.53836954", "0.53641796", "0.5362752", "0.5361512", "0.53400683", "0.5336078", "0.5308392", "0.5306894", "0.5306334", "0.53061664", "0.52983916", "0.52960974", "0.5288665", "0.52795935", "0.5247574", "0.5242949", "0.5242084", "0.5240731", "0.52111363", "0.5208485", "0.5201895", "0.5186976", "0.51845694", "0.5183792", "0.5182119", "0.5172779", "0.51593804", "0.5157355", "0.51550776", "0.5152443", "0.5151845", "0.5150223", "0.5149875", "0.5146222", "0.5146084", "0.5143843", "0.5140523", "0.51307505", "0.5124763", "0.5123811", "0.5122517", "0.5112614", "0.5112055", "0.5108135", "0.5104341", "0.51043326", "0.51020294", "0.5098305", "0.5096068", "0.5082635", "0.50777906", "0.5073998", "0.5073152", "0.5065386", "0.50642794", "0.5060932", "0.505045", "0.50409096", "0.5040639", "0.50287026", "0.50275594", "0.502236", "0.50212526", "0.50189155", "0.5015365", "0.50064844", "0.50031346", "0.50030017", "0.4988242" ]
0.6604468
0
Return True if the aggroList of this L2Attackable is Empty.
public boolean noTarget() { return getAggroListRP().isEmpty(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean empty() {\n return list.isEmpty();\n }", "public boolean empty() {\n if (list.size() == 0) {\n return true;\n }\n else {\n return false;\n }\n }", "public boolean empty() {\n\t\treturn list.size() == 0;\n\t}", "@Override\n\tpublic boolean isEmpty() {\n\t\treturn list.isEmpty();\n\t}", "@Override\n\tpublic boolean isEmpty() {\n\t\treturn list.isEmpty();\n\t}", "public boolean isEmpty() {\n return list.isEmpty();\n }", "public boolean isEmpty() {\n\t\treturn list.isEmpty();\n\t}", "public boolean isEmpty() {\r\n\t\treturn al.listSize == 0;\r\n\t}", "public boolean isEmpty()\n\t{\n\t\treturn list.isEmpty();\n\t}", "public boolean isEmpty(){\n\t\treturn isPassable&&!containsItems()&&!containsMonster()&&tileItems.noGold();\r\n\t}", "public synchronized boolean isEmpty () {\n return list.isEmpty();\n }", "public static boolean empty() {\n\n if (list.size() != 0){\n return false;\n }\n return true;\n }", "public boolean isEmpty(){\n\t\tif(list.isEmpty()){\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}", "public boolean isEmpty() {\n return stack.isListEmpty();\n }", "public boolean isAListEmpty(){\r\n\t\tif((programChairs.size() > 0) && (committeeMembers.size() > 0)){\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\treturn true;\r\n\t}", "public boolean isEmpty() {\n return getBallsCount() == 0;\n }", "public boolean isEmpty() {\n\t\treturn allItems.size() == 0;\n\t}", "@Override\n public boolean isEmpty()\n {\n return list.size()<1;\n }", "public boolean empty() {\n\t\treturn (size() <= 0);\n\t}", "@Override\n\tpublic boolean isEmpty()\n\t{\n if (list.isEmpty())\n {\n return true;\n } \n else\n {\n return false;\n }\n\t}", "public synchronized boolean isEmpty(){\n return list.isEmpty();\n }", "public boolean isEmpty() {\n return items.isEmpty();\n }", "public boolean isEmpty() {\n return items.isEmpty();\n }", "public boolean isEmpty() {\r\n return items.isEmpty();\r\n }", "public boolean isEmpty() {return stackList.isEmpty();}", "@Override\r\n\tpublic boolean isEmpty() {\n\t\treturn this.size == 0;\r\n\t}", "public boolean isEmpty(){\n return this.listSize == 0;\n }", "public boolean empty()\n {\n boolean result = (dataList.size() == 0) ? true : false;\n return result;\n }", "boolean isEmpty() {\n return this.myArrayList.isEmpty();\n }", "public boolean isEmpty() {\n\t\treturn (_items.size() == 0);\n\t}", "public boolean empty()\n {\n return isEmpty();\n }", "public boolean isEmpty() {\r\n\t\t\r\n\t\tint i = 0;\r\n\t\tStudent emptyChecker;\r\n\t\tint size = sizeOfList(list);\r\n\t\twhile (i < size) {\r\n\t\t\temptyChecker = list[i];\r\n\t\t\tif (emptyChecker != null) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t\ti++;\r\n\t\t}\r\n\t\tnumStudents = 0;\r\n\t return true;\r\n\t}", "public boolean isEmpty() {\n return this.familyMembers.isEmpty();\n }", "@Override\r\n\tpublic boolean isEmpty() {\n\t\treturn data != null && data.list != null && data.list.isEmpty();\r\n\t}", "public boolean empty() {\r\n\r\n\t\tif(item_count>0)\r\n\t\t\treturn false;\r\n\t\treturn true;\r\n\t}", "@Override\n public boolean isEmpty() {\n return this.size == 0;\n }", "@Override\r\n\tpublic boolean isEmpty() {\r\n\t\treturn size() == 0;\r\n\t}", "public boolean empty() {\n return this.stack2.size() == 0 && this.stack1.size() == 0;\n }", "public boolean isEmpty(){\n\n \treturn list.size() == 0;\n\n }", "public boolean isEmpty() {\n return this.size == 0;\n }", "public boolean isEmpty() {\n return this.size == 0;\n }", "public final boolean isEmpty() {\r\n\t\treturn this.size == 0;\r\n\t}", "public boolean isEmpty(){\n for(int i = 0; i < arrayList.length; i++) {\n if (arrayList[i] != null)\n return false;\n }\n return true;\n }", "public boolean isEmpty(){\n\t\tif(attackValue>0)\n\t\t\treturn false;\n\t\telse\n\t\t\treturn true;\n\t}", "public boolean isEmpty() {\n\t\treturn this.size == 0;\n\t}", "public boolean empty() {\n return size == 0;\n }", "public boolean empty() {\n return objects.isEmpty();\n }", "public boolean isEmpty() {\n return (this.size == 0);\n }", "public boolean isEmpty() {\r\n return NumItems == 0;\r\n }", "public boolean isEmpty() {\n\t return size() == 0;\n\t }", "public boolean empty() {\n return one.isEmpty();\n \n }", "public boolean empty() {\n /**\n * 当两个栈中都没有元素时,说明队列中也没有元素\n */\n return stack.isEmpty() && otherStack.isEmpty();\n }", "public boolean isEmpty() {\n return dataList.size() <= 0 || (dataList.size() == 1 && dataList.get(0).isEmpty());\n }", "public boolean empty() {\n return size <= 0;\n }", "public boolean isEmpty()\n {\n return this.size == 0;\n }", "public boolean isEmpty() {\n if (super.size() > 0) {\n return false;\n } else {\n return true;\n }\n }", "public boolean isEmpty() {\n\t\treturn super.isEmpty();\n\t}", "public boolean empty() {\r\n\t\treturn empty;\r\n\t}", "public boolean isEmpty() {\n\t\tif (this.size() == 0) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public boolean isEmpty() {\n return userListCtrl.isEmpty();\n }", "public boolean isEmpty() {\n return size() == 0;\n }", "public boolean isEmpty() {\n return size() == 0;\n }", "public boolean isEmpty() {\n return size() == 0;\n }", "public boolean isEmpty() {\n return size() == 0;\n }", "public boolean isEmpty() {\n return size() == 0;\n }", "public boolean isEmpty() {\n return size() == 0;\n }", "public boolean isEmpty() {\n return size() == 0;\n }", "public boolean isEmpty() {\n return size() == 0;\n }", "public boolean isEmpty() {\n return size() == 0;\n }", "public boolean isEmpty() {\n return size() == 0;\n }", "public boolean isEmpty() {\n\t\treturn size() == 0;\n\t}", "public boolean isEmpty() {\n\t\treturn size() == 0;\n\t}", "public boolean isEmpty() {\n\t\treturn size() == 0;\n\t}", "public boolean isEmpty() {\n\t\treturn size() == 0;\n\t}", "@Override\n\tpublic boolean isEmpty() {\n\t\treturn(size() == 0);\n\t}", "public boolean isEmpty() {\n\t\treturn(this.size == 0);\n\t}", "public boolean isEmpty() {\n\t\tboolean empty = true;\n\n\t\tfor(LinkedList<Passenger> queue : queues) { // loop through each queue to see if its empty.\n\t\t\tif(!queue.isEmpty()){\n\t\t\t\tempty = false;\n\t\t\t}\n \t}\n\t\treturn empty;\n }", "public boolean isEmpty() {\n\n return (top == null);\n }", "@Override\n\tpublic boolean isEmpty() {\n\t\treturn size == 0;\n\t}", "@Override\n\tpublic boolean isEmpty() {\n\t\treturn size == 0;\n\t}", "@Override\n public boolean isEmpty() {\n return this.count() == 0;\n }", "public boolean isEmpty() {\n return (size() == 0);\n }", "public boolean isEmpty() {\n\t\treturn this.deck.isEmpty();\n\t}", "public boolean isEmpty() {\n return topIndex < 0;\n }", "@Override\n public boolean isEmpty() {\n return size() == 0;\n }", "@Override\n public boolean isEmpty() {\n return size() == 0;\n }", "@Override\n public boolean isEmpty() {\n return size() == 0;\n }", "@Override\n public boolean isEmpty() {\n return size() == 0;\n }", "@Override\n public boolean isEmpty() {\n return size() == 0;\n }", "public boolean isEmpty() {\n\t\treturn firstNode == null; // return true if List is empty\n\t}", "public boolean isEmpty() {\r\n\t\tif (this.size == 0) {\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "@Override\n public boolean isEmpty() {\n return this.size==0;\n }", "public boolean isEmpty() {\n return size() == 0;\n }", "@Override\n\t\tpublic boolean isEmpty() {\n\t\t\treturn false;\n\t\t}", "@Override\n\t\tpublic boolean isEmpty() {\n\t\t\treturn false;\n\t\t}", "@Override\n\tpublic boolean isEmpty() {\n\t\tif(size() == 0) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public boolean isEmpty() {\n\n\t\tif (numItems == 0)\n\t\t\treturn true;\n\t\telse\n\t\t\treturn false;\n\n\t}", "public boolean empty() {\n return popStack.empty() && pushStack.empty();\n }", "public boolean isEmpty() {\n return doIsEmpty();\n }", "public boolean isEmpty(){\r\n\t\treturn size() == 0;\r\n\t}" ]
[ "0.723608", "0.7201575", "0.7194946", "0.7169504", "0.7169504", "0.7112343", "0.710345", "0.71030253", "0.7066475", "0.69840324", "0.6973111", "0.6970594", "0.6963364", "0.690089", "0.68712425", "0.68623483", "0.6861794", "0.6855772", "0.6854823", "0.6852441", "0.685209", "0.6791566", "0.6791566", "0.6787925", "0.6787044", "0.6782944", "0.67733616", "0.6769996", "0.67645067", "0.67377937", "0.67069", "0.67002326", "0.6691987", "0.6690634", "0.6688385", "0.6687496", "0.6674603", "0.66648024", "0.6662245", "0.666189", "0.666189", "0.6657435", "0.6657218", "0.6657085", "0.66529655", "0.664663", "0.66444993", "0.66432613", "0.66372484", "0.66372216", "0.663703", "0.66209835", "0.6610397", "0.6608498", "0.66060615", "0.66056764", "0.6601546", "0.65985775", "0.6596844", "0.6596484", "0.65823895", "0.65823895", "0.65823895", "0.65823895", "0.65823895", "0.65823895", "0.65823895", "0.65823895", "0.65823895", "0.65823895", "0.65819997", "0.65819997", "0.65819997", "0.65819997", "0.6578873", "0.6574123", "0.65728307", "0.6566884", "0.6565297", "0.6565297", "0.6564345", "0.65601265", "0.65575886", "0.6555595", "0.65489036", "0.65489036", "0.65489036", "0.65489036", "0.65489036", "0.6544183", "0.65432703", "0.65361935", "0.6531641", "0.652903", "0.652903", "0.65200096", "0.65185356", "0.6517163", "0.65167636", "0.6516012" ]
0.67555153
29
Return True if the aggroList of this L2Attackable contains the L2Character.
public boolean containsTarget(final L2Character player) { return getAggroListRP().containsKey(player); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean isCollition(Sprite sprite2) {\n if (this.x < sprite2.getX() + sprite2.getAncho() &&\n this.x + this.ancho > sprite2.getX() &&\n this.y + this.alto > sprite2.getY() &&\n this.y < sprite2.getY() + sprite2.getAlto()) {\n return true;\n\n } else {\n return false;\n }\n\n }", "public boolean containCharacter(ArrayList<String> inputList)\r\n\t{\r\n\t\t\r\n\t\tString variable;\r\n\t\tString desireValue;\r\n\t\t\r\n\t\t//Character currentChar = new Character(); //15-2-2019\r\n\t\tCharacter currentChar = null;\r\n\t\t\r\n\t\t\r\n\t\tfor (String currentInput : inputList)\r\n\t\t{\r\n\t\t\tvariable = currentInput.substring(0, currentInput.indexOf(\":\"));\r\n\t\t\tdesireValue = currentInput.substring(currentInput.indexOf(\":\")+1,currentInput.length());\r\n\t\t\t\r\n\t\t\r\n\t\t\t//Looking for the character index\r\n\t\t\tint indexChar = 0;\r\n\t\t\tfor (int x = 0; x<listCharacter.size();x++)\r\n\t\t\t{\r\n\t\t\t\tif (listCharacter.get(x).getName() == variable) \r\n\t\t\t\t\tcurrentChar = listCharacter.get(x);\r\n\t\t\t\t\tindexChar = x;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// IF This is true, it means the character doesn't exist\r\n\t\t\tif (indexChar == 0)\r\n\t\t\t{\r\n\t\t\t\tSystem.out.println(\"Character in GameState's wishlist doesn't exist\");\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//Now consult siwtchCheckCharacter\r\n\t\t\t//IF even one of them return false, it mean one of condition isn't met\r\n\t\t\tif (!siwtchCheckCharacter(currentChar, desireValue))\r\n\t\t\t{\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\treturn true;\r\n\t}", "boolean collidesEnemy() {\n for(int i = 0; i < barrage.size(); i++) {\n // establish a rectangle for the laser\n Rectangle blaster = new Rectangle((int)barrage.get(i).getX(), (int)barrage.get(i).getY(), WIDTH, HEIGHT);\n \n // determine if the laser intersects an enemy\n for (int q = 0; q < fleet.size(); q++) {\n Rectangle enemy = new Rectangle((int)fleet.get(q).getX(), (int)fleet.get(q).getY(), 40, 36); \n \n // if blaster hits a ship, remove it\n if (blaster.intersects(enemy) && fleet.get(q).getCount() == 0) {\n fleet.get(q).hit = true; // set the enemy hit\n barrage.remove(barrage.get(i));\n score += 100; // add to score\n return true; // hit\n }\n }\n }\n return false; // miss\n }", "private boolean collision2() {\n return game.racket2.getBounds2().intersects(getBounds()); // returns true if the two rectangles intersect\r\n }", "public boolean gameWon(){\n\t\tArrayList<Character> checkLetter = new ArrayList<Character>();\r\n\t\t\r\n\t\tfor(int i=0; i<correctList.size(); i++){\r\n\t\t\tfor(int j=0; j<gameLetter.length; j++){\r\n\t\t\t\tif(correctList.get(i)==gameLetter[j])\r\n\t\t\t\t\tcheckLetter.add(gameLetter[j]);\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\tif(checkLetter.size()==gameLetter.length)\r\n\t\t\treturn true;\r\n\t\telse return false;\r\n\t}", "public boolean isOccupied() {\r\n\treturn character != null;\r\n }", "boolean isGameOver() {\n return getMenu() instanceof ch;\n }", "@Override\n public L2Attackable getActiveChar() { return (L2Attackable)super.getActiveChar(); }", "public boolean contains(LetterTile letter) {\n\t\tfor (int i = 0; i < lettersInPlay.size(); i++)\n\t\t\tif (letter.getChar() == lettersInPlay.get(i).getChar())\n\t\t\t\treturn true;\n\t\treturn false;\n\t}", "@Override\n\tpublic boolean contains(Rectangle2D arg0) {\n\t\treturn false;\n\t}", "public boolean contains(Chamber c) {\n return chambers.containsKey(c);\n }", "public boolean hitCharacter(myCharacter characterImage){\n\t\t\t\tArea ba = new Area(characterImage.getShape());\n\t\t\t\tArea pa = new Area(getRect());\n\n\t\t\t\t//if(character2.getShape().intersects(getRect()))return(true);\n\t\t\t\tpa.intersect(ba);\n\t\treturn !pa.isEmpty();\n\n\n/*\t\ttouching = false;\n\t\tcharacter = characterImage;\n\t\tcharacterX = character.getOrigin().getX();\n\t\tcharacterY = character.getOrigin().getY();\n\t\tcharacterWidth = character.getDimension().getWidth();\n\t\tcharacterHeight = character.getDimension().getHeight();\n\n\t\tif(hits(character.getOrigin(), character.getDimension())==true){\n\n\t\t\tfor(int i = 0; i<character.getCollisionBoxes().size(); i++){\n\t\t\t\tint x = ((int)(character.getCollisionBoxes().get(i).getX()));\n\t\t\t\tint y = ((int)(character.getCollisionBoxes().get(i).getY()));\n\t\t\t\tint width = (int)(character.getCollisionBoxes().get(i).getWidth());\n\t\t\t\tint height =(int)(character.getCollisionBoxes().get(i).getHeight());\n\t\t\t\tPoint p = new Point(x,y);\n\t\t\t\tDimension d = new Dimension(width,height);\n\t\t\t\tif(hits(p,d)&&!character.isGhost()){\n\t\t\t\t\ttouching=true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn(touching);*/\n\t}", "public Character isUsedBy(Character character);", "private boolean HasRocketHitEnemy(Rocket rocket)\n\t {\n\t boolean HitEnemy = false;\n\t \n\t \n\t Rectangle rocketRectangle = new Rectangle(rocket.xCoord, rocket.yCoord,rocket.RocketImage.getWidth(), rocket.RocketImage.getHeight());\n\t \n\t // Go through all enemies.\n\t for(int j = 0; j < EnemyList.size(); j++)\n\t {\n\t Enemy eh = EnemyList.get(j);\n\n\t // Current enemy rectangle.\n\t Rectangle enemyRectangel = new Rectangle(eh.xCoord, eh.yCoord, eh.EnemyHelicopterImage.getWidth(), eh.EnemyHelicopterImage.getHeight());\n\n\t // Is current rocket over current enemy?\n\t if(rocketRectangle.intersects(enemyRectangel))\n\t {\n\t \tHitEnemy = true;\n\t \n\t // Rocket hit the enemy so we reduce his health.\n\t eh.Health -= rocket.damagePower;\n\t \n\t // Rocket hit enemy so we don't need to check other enemies.\n\t break;\n\t }\n\t }\n\t \n\t return HitEnemy;\n\t }", "private boolean addRestrictedCard2Player(Card card)\n\t{\n\t\treturn restrictedCard2PlayerList.add(card);\n\t}", "private boolean isUsed(String key2) {\n\t\tfor(int i = 0; i < size; i++){\n\t\t\tif(keys[i].equals(key2)) return true;\n\t\t}\n\t\treturn false;\n\t}", "@Override\r\n\t\t\tpublic boolean matches(Object list) {\n\t\t\t\treturn ((List<String>) list).size() == 2;\r\n\t\t\t}", "@Override\r\n\t\t\tpublic boolean matches(Object list) {\n\t\t\t\treturn ((List<String>) list).size() == 2;\r\n\t\t\t}", "@Override\r\n\t\t\tpublic boolean matches(Object list) {\n\t\t\t\treturn ((List<String>) list).size() == 2;\r\n\t\t\t}", "@Override\r\n\t\t\tpublic boolean matches(Object list) {\n\t\t\t\treturn ((List<String>) list).size() == 2;\r\n\t\t\t}", "@Override\r\n\t\t\tpublic boolean matches(Object list) {\n\t\t\t\treturn ((List<String>) list).size() == 2;\r\n\t\t\t}", "@Override\r\n\t\t\tpublic boolean matches(Object list) {\n\t\t\t\treturn ((List<String>) list).size() == 2;\r\n\t\t\t}", "public boolean hasTargets() {\n return !getAdjacentCharacters().isEmpty();\n }", "boolean alreadyAdded(char c) {\n for (char x :_chars) {\n if (x == c) {\n return true;\n }\n }\n return false;\n }", "public boolean contains(List l) {\n if (lists.contains(l.obtainTitle())) return true;\n else return false;\n }", "boolean contains(char ch) {\n return _letters.indexOf(ch) >= 0;\n }", "public boolean containsGift(Gift gift) {\r\n return GiftList.containsKey(gift.getName());\r\n }", "public boolean collides(Localizable localizable1, Localizable localizable2) {\n return collides(localizable1, localizable2, 0.5);\n }", "public boolean isInCombat() {\n return isInCombat;\n }", "public boolean checkForLotus(){\n Object obj=charactersOccupiedTheLocation[2];\n if(obj!=null){return true;}\n return false;\n }", "public boolean contains(Object o) {\n for(int i = 0; i < size; i++) {\n if(list[i].equals(o)) return true;\n }\n return false;\n }", "boolean contains(MyRectangle2D r) {\r\n\t\t// check if 1 pair of diagonal corner points\r\n\t\t// are contained in this rectangle\r\n\r\n\t\tdouble x1 = r.getX() - (r.getWidth() / 2);\r\n\t\tdouble y1 = r.getY() + (r.getHeight() / 2);\r\n\r\n\t\tdouble x2 = r.getX() + (r.getWidth() / 2);\r\n\t\tdouble y2 = r.getY() - (r.getHeight() / 2);\r\n\t\t\r\n\t\t//if diagonal corners are inside, the whole rectangle is contained\r\n\t\treturn this.contains(x1, y1) && this.contains(x2, y2) ? true : false;\r\n\t}", "@Test\n public void existsItem(){\n List <Character> list = new ArrayList<>();\n list.add('a');\n list.add('b');\n list.add('c');\n\n assertTrue(list.contains('b'));\n }", "public boolean contactsSprite(Sprite other) {\r\n\t\treturn bb.intersects(other.getBoundingBox());\r\n\t}", "public boolean isValid() {\n\t\t\n\t\tif (this.size() == 2)\n\t\t\tif (this.getCard(0).getRank() == this.getCard(1).getRank())\n\t\t\t\treturn true;\n\t\t\n\t\treturn false;\n\t}", "public boolean hasScannedEnemies()\n\t{\n\t\treturn (lastscanround == br.curRound && !needToScanEnemies);\n\t}", "private boolean isCellOccupied(Cell c) {\n Worm[] opponentWorms = opponent.worms;\n Worm[] playerWorms = player.worms;\n int i = 0;\n int j = 0;\n boolean foundOpponentWorm = false;\n boolean foundPlayerWorm = false;\n while ((i < opponentWorms.length) && (!foundOpponentWorm)) {\n if ((opponentWorms[i].position.x == c.x) && (opponentWorms[i].position.y == c.y)) {\n foundOpponentWorm = true;\n } else {\n i++;\n }\n }\n while ((j < playerWorms.length) && (!foundPlayerWorm)) {\n if ((playerWorms[j].position.x == c.x) && (playerWorms[j].position.y == c.y)) {\n foundPlayerWorm = true;\n } else {\n j++;\n }\n }\n return (foundOpponentWorm || foundPlayerWorm);\n }", "public boolean contains(Circle2D other) {\n return Math.abs(other.getRadius() + distance(other.getX(), other.getY())) < getRadius();\n }", "public boolean checkIfPlayerInList(Player player, Player player1) {\n for(int i = 0; i < core.getPlayers().get(player).size(); i++) {\n /*\n if(core.getPlayers().get(player).contains(configList.get(i))) {\n core.getPlayers().get(player).add(configList.get(i));\n }\n */\n if (core.getPlayers().get(player).get(i).equalsIgnoreCase(player1.getName())) {\n return true;\n }\n }\n return false;\n }", "public boolean isDiggable() {\n return buriedItems != null;\n }", "public boolean contains(Course c) {\n return courseList.contains(c); \n }", "@Override\n\tpublic boolean add(Character e) {\n\t\tif (!this.contains(e)) {\n\t\t\treturn super.add(e);\n\t\t} else\n\t\t\treturn false;\n\t}", "public static boolean checkVictory(){\n\t\tboolean victory = true;\n\t\t\n\t\tfor (int i = 0; i < enemyList.length && victory; i++) {\n\t\t\tif (enemyList[i].isAlive()) {\n\t\t\t\tvictory = false;\n\t\t\t}\n\t\t}\n\t\treturn victory;\n\t}", "boolean contains(char c) {\n for (char x : _chars) {\n if (x == c) {\n return true;\n }\n }\n return false;\n }", "public boolean isACharacterTargeted() {\n return false;\n }", "@Override\n public boolean contains(Comparable k) {\n\n // Loop over items and check\n for (int i = 0; i < this.size; i++) {\n if (ls[i].key.equals(k)) {\n return true;\n }\n }\n\n // Return false if not found\n return false;\n }", "@Override\n public boolean equals(Object obj) {\n if (this == obj)\n return true;\n if (obj == null)\n return false;\n if (!(obj instanceof CharacterDescription))\n return false;\n CharacterDescription other = (CharacterDescription) obj;\n if (description == null) {\n if (other.description != null)\n return false;\n } else if (!description.equals(other.description))\n return false;\n if (features == null) {\n if (other.features != null)\n return false;\n } else if (!features.containsAll(other.features) || !other.features.containsAll(features))\n return false;\n if (gender != other.gender)\n return false;\n if (name == null) {\n return other.name == null;\n } else\n return name.equals(other.name);\n }", "public boolean isCharacterInSameLocation(Character inputCharA, Character inputCharB) {\r\n\t\tString LocationCharA = inputCharA.getLocation();\r\n\t\tArrayList<Character> inputListLocation = getListCharacterInLocation(LocationCharA);\r\n\t\tif (inputListLocation.contains(inputCharA) && inputListLocation.contains(inputCharB))\r\n\t\t{\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\telse return false;\r\n\t}", "public boolean isColliding(){\n for(int i = 0; i < eng.getIDManager().getObjectsWithID(\"GameObject\").size(); i++){\n GameObject temp = eng.getIDManager().getObjectsWithID(\"GameObject\").get(i);\n \n if(temp.getHitBox().getBounds().intersects(rect.getBounds()) &&\n temp.getHitBox() != this){\n currentCollidingObject = temp;\n return true;\n }\n }\n \n return false;\n }", "static boolean isMatchingPair(char character1, char character2) {\r\n\t\tif (character1 == '(' && character2 == ')')\r\n\t\t\treturn true;\r\n\t\telse if (character1 == '{' && character2 == '}')\r\n\t\t\treturn true;\r\n\t\telse if (character1 == '[' && character2 == ']')\r\n\t\t\treturn true;\r\n\t\telse\r\n\t\t\treturn false;\r\n\t}", "public boolean contains(String target){\n\t\treturn list.contains(target);\n\t}", "public boolean isInList();", "public boolean contains ( Object o ){\n\n \tboolean doesContain = false;\n\n \tfor(int i = 0; i < list.size(); i++){\n\n if(list.get(i).equals(o)){\n doesContain = true;\n }\n\n }\n\n \treturn doesContain;\n\n }", "public boolean canMove2() {\n\t\tGrid<Actor> gr = getGrid(); \n\t\tif (gr == null) {\n\t\t\treturn false; \n\t\t}\n\t\t\n\t\tLocation loc = getLocation(); \n\t\tLocation next = loc.getAdjacentLocation(getDirection());\n\t\tLocation next2 = next.getAdjacentLocation(getDirection());\n\t\tif (!gr.isValid(next)) {\n\t\t\treturn false;\n\t\t}\n\t\tif (!gr.isValid(next2)) {\n\t\t\treturn false;\n\t\t}\n\t\tActor neighbor = gr.get(next2); \n\t\treturn (neighbor == null) || (neighbor instanceof Flower); \n\t}", "public boolean contains(Rectangle2D r) {\n Geometry rect = rectangleToGeometry(r);\n\n return geometry.contains(rect);\n }", "public boolean checkContain(Hero h) {\r\n return team.contains(h);\r\n }", "public AttackableKnownList(L2Attackable activeChar)\n {\n super(activeChar);\n }", "@Override\r\n\t\t\tpublic boolean matches(Object list) {\n\t\t\t\treturn ((List<String>) list).size() == 1;\r\n\t\t\t}", "@Override\r\n\t\t\tpublic boolean matches(Object list) {\n\t\t\t\treturn ((List<String>) list).size() == 1;\r\n\t\t\t}", "@Override\r\n\t\t\tpublic boolean matches(Object list) {\n\t\t\t\treturn ((List<String>) list).size() == 1;\r\n\t\t\t}", "public boolean contains(Coord c) {\n\t\treturn getAWTRectangle().contains(c.getAWTPoint());\n\t}", "public void isStillInCombat() {\n isInCombat = enemiesInCombat.size() > 0;\n }", "private boolean collision1() {\n return game.racket1.getBounds1().intersects(getBounds()); // returns true if the two rectangles intersect\r\n }", "public boolean isHit(Collideable otherCol){\n return this.collideable.getHitX() - otherCol.getHitX() < 50\n && this.collideable.getHitX() - otherCol.getHitX() > -50\n && this.collideable.getHitY() - otherCol.getHitY() > -30\n && this.collideable.getHitY() - otherCol.getHitY() < 30;\n }", "public boolean intersects(final Rectangle2D other)\r\n {\r\n return other.intersects(new Rectangle2D.Float(x, y, width, height));\r\n }", "public final Map<L2Character, AggroInfoHolder> getAggroList()\n\t{\n\t\treturn aggroList;\n\t}", "HitEnemy checkHits(@NotNull List<Bullet> bullets, Bitmap hitEnemyImage) {\n for (Bullet b : bullets) {\n int enemyXCoordinate = x();\n int enemyYCoordinate = y();\n int enemyWidth = this.getBitmap().getWidth();\n int enemyHeight = this.getBitmap().getHeight();\n\n int bulletXCoordinate = b.x();\n int bulletYCoordinate = b.y();\n int bulletWidth = b.getBitmap().getWidth();\n int bulletHeight = b.getBitmap().getHeight();\n\n // Standard rectangular bitmap intersection formula\n // (Good enough up to +/- the corner pixels, which are not\n // noticeable in the game)\n if (enemyXCoordinate + enemyWidth >= bulletXCoordinate\n && bulletXCoordinate + bulletWidth >= enemyXCoordinate\n && enemyYCoordinate + enemyHeight >= bulletYCoordinate\n && bulletYCoordinate + bulletHeight >= enemyYCoordinate) {\n b.markForRemoval();\n this.markForRemoval();\n\n return new HitEnemy(this.x(), this.y() - 34, hitEnemyImage);\n }\n }\n\n return null;\n }", "public boolean contains(Word x) {\n\t int currentPosition = findPos(x.getContent());\n\t return isActive(array, currentPosition);\n\t }", "public boolean wantsToAttack() {\n boolean ret = false;\n \n potentialAttackers.clear(); //Previous potentials might no longer be adjacent to an enemy\n \n //Look at all my territories. If it has enough troops to smack someone, it does.\n for(Territory t : gameController.getBoard().getAgentsTerritories(this)){\n if(t.getNumTroops() > 1){\n \n //Check adjacent territories to see if we can do anything about it.\n List<Territory> adjs = gameController.getBoard().getAdjacentTerritories(t);\n for(Territory adj : adjs){\n //Record a boolean so we don't need to call it twice;\n boolean yes = !adj.getOwner().equals(this);\n \n //Check if we have an acceptable chance of success\n int tTroops = t.getNumTroops() - 1;\n int aTroops = adj.getNumTroops();\n double odds = MarkovLookupTable.getOddsOfSuccessfulAttack(tTroops, aTroops);\n yes &= Double.compare(odds, ACCEPTABLE_RISK) >= 0;\n \n //If we can attack with this territory, yes will be true, throw this Territory\n //in the list of potential attackers if it isn't already in there.\n if(yes){\n if(!potentialAttackers.contains(t)){\n potentialAttackers.add(t);\n }\n }\n ret |= yes; //Ret will be set to true and can't be unset if even 1 t can attack\n }\n }\n }\n \n return ret;\n }", "private boolean containCreditCard(ArrayList<CreditCard> card){\n\t\tfor (CreditCard creditCard : creditCards){\n\t\t\tfor (CreditCard creditCard1 : card){\n\t\t\t\tif(creditCard.equals(creditCard1))return true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "@Override\n public boolean equals(final Object o) {\n Position position = (Position) o;\n return posX == position.posX && posY == position.posY && Objects.equals(charAlg, position.charAlg);\n }", "private boolean isContoDiLivelloDiLegge() {\n\t\treturn conto.getLivello().equals(livelloDiLegge); \n\t\t\n\t}", "public boolean overlaps(Rectangle2D r2) {\n double xDistance = (Rectangle2D.centerX > centerX) ? Rectangle2D.centerX - centerX : centerX - Rectangle2D.centerX;\n double yDistance = (Rectangle2D.centerY > centerY) ? Rectangle2D.centerY - centerY : centerY - Rectangle2D.centerY;\n\n return (xDistance <= (width + r2.width) / 2 && yDistance <= (height + r2.height) / 2);\n\n }", "protected boolean isValid() {\n return COLLECTION.getList().contains(this);\n }", "public boolean isInRect2(Point p) {\n\t\tLine AB = new Line(A1, B1);\n\t\tLine CD = new Line(C1, AB.getU());\n\t\tLine AD = new Line(A1, D1);\n\t\tLine BC = new Line(B1, AD.getU());\n\n\t\t// if(Line.isBetween2Lines2(AB, CD, p))\n\t\t// System.out.println(1);\n\t\t// if(Line.isBetween2Lines2(AD, BC, p))\n\t\t// System.out.println(2);\n\n\t\tif (Line.isBetween2Lines2(AB, CD, p) && Line.isBetween2Lines2(AD, BC, p)) {\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}", "public boolean graveyardContains(String name) {\n AssassinNode current = gYardFront;\n return contains(name, current);\n }", "private boolean isEnemyOccupied(int x, int y) {\n for (int i = 0; i < player.own.length; i++) {\n if (player.enemy[i].x == x && player.enemy[i].y == y) {\n System.out.println(\"enemy occupied:\" + i);\n return true;\n }\n }\n return false;\n }", "public boolean is_valid(char c1, char c2) {\n return ((c1 == '(' && c2 == ')') || (c1 == '{' && c2 == '}') || (c1 == '[' && c2 == ']'));\n }", "private Boolean isReachable(String C1, String C2) {\n \tif (adjacencyList.get(C2) == null) {\n \t\treturn false;\n \t}\n \tfor (String child : adjacencyList.get(C2)) {\n \t\tif (child.equals(C1)) {\n \t\t\treturn true;\n \t\t} else if ( isReachable(C1, child ) ) {\n \t\t\treturn true;\n \t\t}\n \t}\n \treturn false;\n }", "boolean gameOver() {\n return piecesContiguous(BLACK) || piecesContiguous(WHITE);\n }", "public boolean collidesWith(SpriteBase otherSprite) {\r\n boolean toReturn = false;\r\n\r\n if (distTo(otherSprite.x, x) < collideSize && distTo(otherSprite.y,y) < collideSize){\r\n toReturn = true;\r\n }\r\n\r\n return (toReturn);\r\n }", "public boolean isBattleOver(){\n\n if(battleEnemies.size() == 0) {\n System.out.println(\"Battle over all enemies dead\");\n findDefeated();\n cleanStatuses();\n result = true;\n\n return true;\n }\n if(character.getCurrHP() <= 0){\n System.out.println(\"Battle over character has died\");\n //findDefeated();\n cleanStatuses();\n result = false;\n\n return true;\n }\n //System.out.printf(\"remaining enemies: %s\\n\", battleEnemies.size());\n return false;\n }", "@Override\n public boolean equals(Object o) {\n return (o instanceof ItineraryLeg && equals((ItineraryLeg) o));\n }", "public boolean inArena(Player p)\n {\n return arenaPlayers.contains(p);\n }", "private Set<IntVector2D> canAttackFromDestination() {\n\t\tif(activePath == null || !pf.isValidPath(activePath))\n\t\t\treturn new HashSet<>();\n\t\tGameCharacter gc = getUnitAt(activePath.get(0)).getEnclosed();\n\t\tboolean ranged = gc.isRanged();\n\t\tboolean melee = gc.isMelee();\n\t\tAlignment atkSide = gc.getSide();\n\t\tSet<IntVector2D> attackable = new HashSet<>();\n\t\tint x = activePath.get(activePath.size() - 1).getX();\n\t\tint y = activePath.get(activePath.size() - 1).getY();\n\t\tif(ranged) {\n\t\t\tList<IntVector2D> arr = new LinkedList<>();\n\t\t\tarr.add(new IntVector2D(x + 2, y));\n\t\t\tarr.add(new IntVector2D(x - 2, y));\n\t\t\tarr.add(new IntVector2D(x, y + 2));\n\t\t\tarr.add(new IntVector2D(x, y - 2));\n\t\t\tarr.add(new IntVector2D(x + 1, y + 1));\n\t\t\tarr.add(new IntVector2D(x - 1, y + 1));\n\t\t\tarr.add(new IntVector2D(x + 1, y - 1));\n\t\t\tarr.add(new IntVector2D(x - 1, y - 1));\n\t\t\tattackable.addAll(arr.stream()\n\t\t\t\t\t.filter((vec) -> (\n\t\t\t\t\t\t\tisTileOnMap(vec) // not sure why this is necessary\n\t\t\t\t\t\t\t&& getTileAt(vec).isOccupied()\n\t\t\t\t\t\t\t&& Alignment.areOpposed(atkSide, getUnitAt(vec).getSide())))\n\t\t\t\t\t.collect(Collectors.toList()));\n\t\t}\n\t\tif(melee) {\n\t\t\tList<IntVector2D> arr = new LinkedList<>();\n\t\t\tarr.add(new IntVector2D(x + 1, y));\n\t\t\tarr.add(new IntVector2D(x - 1, y));\n\t\t\tarr.add(new IntVector2D(x, y + 1));\n\t\t\tarr.add(new IntVector2D(x, y - 1));\n\t\t\tattackable.addAll(arr.stream()\n\t\t\t\t\t.filter((vec) -> (\n\t\t\t\t\t\t\tisTileOnMap(vec) // not sure why this is necessary\n\t\t\t\t\t\t\t&& getTileAt(vec).isOccupied()\n\t\t\t\t\t\t\t&& Alignment.areOpposed(atkSide, getUnitAt(vec).getSide())))\n\t\t\t\t\t.collect(Collectors.toList()));\n\t\t}\n\t\treturn attackable;\n\t}", "@Override\n public boolean isValid() {\n return (27 - Inventory.getAll().length <= Inventory.find(\"Soft clay\").length)\n || (Inventory.find(\"Soft clay\").length < 1 || Inventory\n .find(\"Astral rune\").length < 1)\n && !Banking.isBankScreenOpen()\n && GlassBlower.antiban.canInteractObject();\n }", "private boolean enemyCanAttack(PieceColor allyColor, Location loc)\n {\n if (!loc.isValid())\n return false;\n for (Piece other: getPieces())\n {\n if (other.getColor()!=allyColor && canAttack(other,loc))\n return true;\n }\n return false;\n }", "public boolean garretFight(){\n\t\tint XG = 0;\n\t\tint YG = 0;\n\t\tint Xyou = 1;\n\t\tint Yyou = 1;\n\t\tfor(int i = 0 ; i < this.Garret.length;i++){\n\t\t\tfor(int p = 0; p < this.Garret.length;p++){\n\t\t\t\tif(this.Garret[i][p] == 1){\n\t\t\t\t\tYG = i;\n\t\t\t\t\tXG = p;\n\t\t\t\t}\n\t\t\t\tif(this.position[i][p] == 1){\n\t\t\t\t\tYyou = i;\n\t\t\t\t\tXyou = p;\n\t\t\t\t}\n\t\t\t}\n\t\t}//end of outter for\n\t\tif(YG==Yyou && XG==Xyou){\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "boolean isOccupiedByAnimal(Vector2d position);", "public static boolean sameUniqueCharsInBothLists( List<Character> list1, \n List<Character> list2 ) {\n Set<Character> s1 = new TreeSet<Character>( list1 );\n Set<Character> s2 = new TreeSet<Character>( list2 );\n return s1.equals(s2);\n }", "public boolean sameAsGold() {\n\t\tif (this.level == null) {\n\t\t\treturn false;\n\t\t}\n\n\t\tArrayList<Gold> goldObjects = this.level.getGoldObjects();\n\n\t\tfor (int i = 0; i < goldObjects.size(); i++) {\n\t\t\tif (this.tilePositionX == goldObjects.get(i).getPositionX()\n\t\t\t\t\t&& this.tilePositionY == goldObjects.get(i).getPositionY()) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "public boolean isAttackState() {\n return States.attack.contains(this.state);\n }", "public boolean overlapsWith()\r\n\t{\r\n\t\tboolean alive = false;\r\n\t\tfor (Platforms platform : platforms)\r\n\t\t{\r\n\t\t\tif (getAvatar().getX() == platform.getX() && getAvatar().getY() == platform.getY())\r\n\t\t\t{\r\n\t\t\t\talive = true;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn alive;\r\n\t}", "public boolean canPirateShipCardAttack(Battle b, PirateShip c) {\n\t\t\n\t\tAttacker a = b.getAttackerByPlayerId(getId());\n \n\t\tif (a != null) {\n\t\t\tif (a.getAttackCards().getCards().size() > 0) {\n\t\t\t\t// this is to account for the empty ownerAttacker\n\t\t\t\tif (a.getScore() + c.getValue() >= b.getHighScore()) {\n\t\t\t\t\treturn a.getAttackerColor() == c.getColor();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tfor (Attacker at: b.getAttackers()) {\n\t\t\tif (at.getAttackerColor() == c.getColor()){\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (c.getValue() >= b.getHighScore()){\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public boolean isOccupied(int i, int j) {\n\t\tint index = i * 3 + j;\n\t\tint all_moves = this.player1_moves | this.player2_moves;\n\n\t\tall_moves >>= index;\n\t\treturn (all_moves & 1) == 1;\n\t}", "public boolean canSplit() {\r\n if (cards.size() == 2 && cards.get(0).getValue().equals(cards.get(1).getValue())) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }", "private boolean checkGuess(char c){\r\n boolean contains = false;\r\n for (int i = 0; i < wordArray.length; i++) {\r\n if (wordArray[i] == c) {\r\n contains = true;\r\n hidden[i] = c;\r\n }\r\n }\r\n if (!contains){\r\n guesses.add(c);\r\n }\r\n return contains;\r\n }", "public boolean collisionCheck() {\n for (Alien al : aliens) {\n if (you.collide(al)) {\n al.collide(you);\n return true;\n }\n }\n boolean tf = false;\n int index = 0, size = lazers.size();\n while (index < size) {\n if (you.collide(lazers.get(index))) {\n lazers.remove(index);\n size--;\n index--;\n tf = true;\n }\n index++;\n }\n return tf;\n }", "boolean contains(ShortPoint2D position);", "public boolean collidesWith(GameObject other) {\n me.setBounds((int) x, (int) y, sprite.getWidth(), sprite.getHeight());\n him.setBounds((int) other.x, (int) other.y, other.sprite.getWidth(), other.sprite.getHeight());\n\n return me.intersects(him);\n }" ]
[ "0.5774886", "0.55752206", "0.54482347", "0.5396216", "0.5359225", "0.5348576", "0.5337617", "0.5324676", "0.5323021", "0.52447766", "0.5223567", "0.52128977", "0.52103364", "0.5192285", "0.51474905", "0.5126493", "0.51250833", "0.51250833", "0.51250833", "0.51250833", "0.51250833", "0.51250833", "0.5113425", "0.51002103", "0.5093861", "0.50834644", "0.507474", "0.50696856", "0.50674397", "0.50298846", "0.5025161", "0.5021857", "0.50176644", "0.5017093", "0.5014275", "0.49976078", "0.49900648", "0.49864885", "0.498295", "0.49444517", "0.4942694", "0.4937578", "0.49282622", "0.4927846", "0.49217784", "0.49150565", "0.4913236", "0.49131793", "0.49004018", "0.48977518", "0.48944893", "0.48940042", "0.48913902", "0.4888732", "0.4877038", "0.48762143", "0.4869524", "0.4862389", "0.4862389", "0.4862389", "0.48611942", "0.4848507", "0.48451144", "0.4844404", "0.48421994", "0.48323694", "0.48033643", "0.48010254", "0.4799923", "0.4799109", "0.4797813", "0.47963932", "0.47946438", "0.47893602", "0.47858882", "0.4784472", "0.47823295", "0.47804302", "0.47803327", "0.47746632", "0.47735217", "0.47731382", "0.47731346", "0.47652867", "0.47585183", "0.47555453", "0.4751325", "0.4747929", "0.4744917", "0.47413817", "0.4735654", "0.47342926", "0.47320795", "0.47261554", "0.47231218", "0.47167197", "0.47160107", "0.47130713", "0.47123024", "0.47080666" ]
0.5899961
0
Clear the aggroList of the L2Attackable.
public void clearAggroList() { getAggroList().clear(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void clear() {\r\n GiftList.clear();\r\n names = new LinkedList<>();\r\n totalGifts = 0;\r\n totalCost = 0;\r\n }", "public void clearGameList() {\n gameJList.removeAll();\n }", "public void clear(){\n\n \tlist = new ArrayList();\n\n }", "public void Reset()\n {\n this.list1.clear();\n }", "public void clearConcertList(){\n concertList.clear();\n }", "public void clear() {\n\t\tlists.clear();\n\t}", "public void clear()\n {\n int llSize = ll.getSize();\n for(int i=0; i<llSize; i++){\n ll.remove(0);\n }\n }", "private void clearLists() {\n\t\tobjects = new ArrayList<Entity>();\n\t\tenemies.clear();\n\t\titemList.clear();\n\t}", "public void clear() {\n this.layers.clear();\n list.clear();\n }", "public void clear() {\n list = new Object[MIN_CAPACITY];\n n = 0;\n }", "public synchronized void clear()\n\t{\n\t\tthis.mApList.clear();\n\t}", "public void reset() {\n this.list.clear();\n }", "public void clear()\n {\n dessertList.clear();\n }", "public void clear() {\n internalGroup.clear();\n }", "private void reset() {\n\n\n spaceShips.clear();\n playerOne = null;\n playerTwo = null;\n friendlyBullets.clear();\n enemyBullets.clear();\n powerUps.clear();\n enemyGenerator.reset();\n difficulty.reset();\n Bullets.BulletType.resetSpeed();\n\n for (int i = 0; i < enemies.size(); i++) {\n enemies.get(i).getEnemyImage().delete();\n }\n enemies.clear();\n }", "protected void clear() {\n\n\t\tthis.myRRList.clear();\n\t}", "public void clearList()\n\t{\n\t\tnodeManager.clearList();\n\t}", "public void removeAll() {\n this.arrayList = null;\n this.arrayList = new ArrayList<>();\n }", "public void clearGame() {\n\t\tselectedObjects.clear();\n\t}", "public void clearList() {\n\t\tdeletedList.clear();\n\t}", "public void clear() {\n\t\t//Kill all entities\n\t\tentities.parallelStream().forEach(e -> e.kill());\n\n\t\t//Clear the lists\n\t\tentities.clear();\n\t\tdrawables.clear();\n\t\tcollidables.clear();\n\t}", "public void clear() {\n\t\tlist = new ArrayList<String>();\n\t\tword = \"\";\n\t}", "public void clear() {\n\t\tstringList = null;\n\t}", "@Override\n public void clear() {\n beginMyTurn();\n }", "public void clearTheGame() {\n players.clear();\n categories.clear();\n playedRounds = 0;\n indexOfActiveCategory = -1;\n indexOfActivePlayer = 0;\n numberOfRounds = 0;\n }", "public void clear(){\n this.items.clear();\n }", "public void clear() {\r\n\t\titems.clear();\r\n\t}", "public void resetDamages() {\n damages = new ArrayList<>();\n }", "public void clear() {\n\t\twordList.removeAll(wordList);\n\t\t// TODO Add your code here\n\t}", "public void clear() {\n for (int i = 0; i < size; i++) genericArrayList[i] = null;\n size = 0;\n }", "public void clearLobbies() {\n\t\tlobbies.clear();\n\t}", "public void clear() {\n mLeDevices.clear();\n }", "public void clear() {\n items.clear();\n update();\n }", "public void reset() {\r\n setGiftCardList(new ArrayList());\r\n for (int i = 0; i < getMaxNumGiftCards(); i++) {\r\n addBlankGiftCard(getGiftCardList());\r\n }\r\n \r\n setGiftCardTempList(new ArrayList());\r\n for (int i = 0; i < getMaxNumGiftCards(); i++) {\r\n addBlankGiftCard(getGiftCardTempList());\r\n }\r\n }", "public void clear(){\r\n \t\tcollapsingList.clear();\r\n \t}", "@CallSuper\n protected void clear() {\n EventListener eventListener = mUseCaseConfig.getUseCaseEventListener(null);\n if (eventListener != null) {\n eventListener.onUnbind();\n }\n\n mListeners.clear();\n }", "public void clearList() {\n\t\thead = null;\n\t\tlength = 0;\n\t}", "public void clear() {\n doClear();\n }", "public void clearPurchaseList()\r\n\t{\r\n\t\tm_purechaseList.clear();\r\n\t}", "@Override\n\tprotected void clearBuffer() {\n\t\tsynchronized (listLock) {\n\t\t\tif (deleteList != null && deleteList.size() > 0) {\n\t\t\t\tdeleteList.clear();\n\t\t\t}\n\t\t}\n\n\t}", "@Override\n public void removeAll(){\n gameCollection.removeAllElements();\n }", "public void clear()\r\n {\r\n super.clear();\r\n }", "public void clear() {\r\n\t\tboolean enabled = isEnabled() ;\r\n\t\tif (enabled) {\r\n\t\t\tsetEnabled(false);\r\n\t\t}\r\n\t\tlistModel.clear();\r\n\t\tif (enabled) {\r\n\t\t\tsetEnabled(true);\r\n\t\t}\r\n\t}", "private void clearBullet()\n {\n if(playerBullets.size() > 0)\n {\n for(int i = 0; i < playerBullets.size(); ++i)\n {\n int x = playerBullets.get(i).getRectangle().centerX(), y = playerBullets.get(i).getRectangle().centerY();\n if (y <= 0 || y >= Constants.SCREEN_HEIGHT || x <= 0 || x >= Constants.SCREEN_WIDTH)\n {\n playerBullets.remove(i);\n --i;\n SFX_Manager.impact();\n }\n }\n }\n if(enemyBullets.size() > 0)\n {\n for(int i = 0; i < enemyBullets.size(); ++i)\n {\n int x = enemyBullets.get(i).getRectangle().centerX(), y = enemyBullets.get(i).getRectangle().centerY();\n if (y <= 0 || y >= Constants.SCREEN_HEIGHT || x <= 0 || x >= Constants.SCREEN_WIDTH)\n {\n enemyBullets.remove(i);\n --i;\n SFX_Manager.impact();\n }\n }\n }\n }", "public void clear(){\n this.collected.clear();\n }", "public void clear() {\n \tthis.listShapes.clear();\n }", "void clear() {\n\t\tfor (int list = getFirstList(); list != -1;) {\n\t\t\tlist = deleteList(list);\n\t\t}\n\t}", "public void emptyList() {\n coursesTaken = new ArrayList<CourseTaken>();\r\n }", "public void clear() {\n lists = new TernarySearchTree<>();\n }", "public void clear()\r\n {\r\n phoneList = new ArrayList<String>();\r\n }", "public void clear()\n {\n }", "public void cleanupBattle(List<Enemy> defeatedEnemies){\r\n Character character = world.getCharacter();\r\n updateAllies();\r\n\r\n ArrayList<MovingEntity> deadFriendlies = new ArrayList<MovingEntity>();\r\n for (MovingEntity friendly: world.getFriendlyEntities()) {\r\n if (friendly.getCurrHP() <= 0) {\r\n deadFriendlies.add(friendly);\r\n friendly.destroy();\r\n }\r\n }\r\n world.getFriendlyEntities().removeAll(deadFriendlies);\r\n\r\n \r\n //ArrayList<Enemy> defeatedEnemies = battle.getDefeated();\r\n for(Enemy defeatedEnemy : defeatedEnemies) {\r\n killEnemy(defeatedEnemy);\r\n }\r\n\r\n if (character.getCurrHP() <= 0) {\r\n world.setGameStateLose();\r\n }\r\n }", "public void clear() {\r\n items.clear();\r\n keys.clear();\r\n }", "public void clear() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void clear() {\n\t\t\r\n\t}", "public void removeFromGame(GameLevel g) {\r\n for (Enemy e : enemies) {\r\n e.removeFromGame(g);\r\n }\r\n this.startLocations.clear();\r\n }", "public void clear() {\n\t\tnodeList.clear();\n\t}", "private void clear() {\r\n\t\tpstate.clear();\r\n\t\tdisplay.setLegend(\"\");\r\n\t\tship = null;\r\n\t}", "public void clear() {\n doClear( false );\n }", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "public void clear();", "private void reset() {\n PlayerPanel.reset();\n playersAgentsMap.clear();\n agentList.clear();\n playerCount = 0;\n playerList.removeAll();\n iPlayerList.clear();\n dominator = \"\";\n firstBlood = false;\n }", "void clear() {\n _whoseMove = WHITE;\n _gameOver = false;\n\n for (int i = 0; i <= MAX_INDEX; i += 1) {\n set(i, BLACK);\n }\n for (int i : _initWhite) {\n set(i, WHITE);\n }\n set(12, EMPTY);\n _history.clear();\n\n setInitialDirection(MAX_INDEX);\n\n setChanged();\n notifyObservers();\n }", "@Override\n\t\tpublic void clear() {\n\t\t\t\n\t\t}", "@Override\n\t\tpublic void clear() {\n\t\t\t\n\t\t}", "public void clearGroups() {\r\n\t\tthis.groups = null;\r\n\t}", "public void removeAllFightsystems()\r\n {\n\r\n }", "public synchronized void clear()\n {\n clear(false);\n }" ]
[ "0.65611553", "0.6403898", "0.6386481", "0.61763394", "0.61536276", "0.61526644", "0.61196786", "0.6102603", "0.60607433", "0.6053637", "0.6030228", "0.60182023", "0.60174745", "0.5997104", "0.59699076", "0.5969349", "0.5965639", "0.59626824", "0.59438545", "0.59262717", "0.59170496", "0.5889522", "0.5879642", "0.58536386", "0.5822432", "0.5815883", "0.58087444", "0.5797426", "0.5797144", "0.5794294", "0.57649904", "0.57597595", "0.5743337", "0.5741337", "0.573654", "0.57338494", "0.57238317", "0.5716806", "0.5703877", "0.5689586", "0.56823117", "0.5682084", "0.56643915", "0.5660153", "0.5650424", "0.5649264", "0.56396914", "0.5637042", "0.56320804", "0.5630293", "0.5628899", "0.5628326", "0.5627782", "0.5619455", "0.561385", "0.5612949", "0.56055456", "0.5605515", "0.5604267", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5602235", "0.5601682", "0.56004107", "0.5597133", "0.5597133", "0.5593267", "0.55855924", "0.55821586" ]
0.81929934
0
Return table containing all L2ItemInstance that can be spoiled.
public synchronized RewardItem[] takeSweep() { final RewardItem[] sweep = sweepItems; sweepItems = null; return sweep; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public ArrayList<Pile> getPiles() {\n \t\treturn mTable;\n \n \t}", "public HashMap<String, List<OwnedWarp>> getTable() {\n return warps;\n }", "public List<FreeColGameObject> disposeList() {\n List<FreeColGameObject> objects = new ArrayList<FreeColGameObject>();\n if (owner != null\n && getTile() != null\n && getTile().getSettlement() != null) {\n // Defensive tests to handle transition from calling dispose()\n // on both sides to when it is only called on server-side.\n \n // Get off the map\n Tile settlementTile = getTile();\n List<Tile> lostTiles = getOwnedTiles();\n for (Tile tile : lostTiles) {\n tile.changeOwnership(null, null);\n }\n settlementTile.setSettlement(null);\n \n // The owner forgets about the settlement.\n Player oldOwner = owner;\n oldOwner.removeSettlement(this);\n oldOwner.invalidateCanSeeTiles();\n // It is not safe to setOwner(null). When a settlement is\n // destroyed there is a race between this code and some\n // display routines that still need to know who owned the\n // dead settlement.\n }\n \n objects.addAll(super.disposeList());\n return objects;\n }", "@Override\n public List<Bitstream> getNonInternalBitstreams(Item item) throws SQLException\n {\n List<Bitstream> bitstreamList = new ArrayList<Bitstream>();\n\n // Go through the bundles and bitstreams picking out ones which aren't\n // of internal formats\n List<Bundle> bunds = item.getBundles();\n\n for (Bundle bund : bunds) {\n List<BundleBitstream> bitstreams = bund.getBitstreams();\n\n for (BundleBitstream bundleBitstream : bitstreams) {\n Bitstream bitstream = bundleBitstream.getBitstream();\n if (!bitstream.getFormat().isInternal()) {\n // Bitstream is not of an internal format\n bitstreamList.add(bitstream);\n }\n }\n }\n\n return bitstreamList;\n }", "@Override\n public List<SlotType> getSlots() {\n List<SlotType> slots = new ArrayList<SlotType>();\n\n if (sourceObjectId != null) {\n slots.add(RegistryUtil.newStringSlot(\"sourceObjectId\",\n sourceObjectId));\n }\n\n if (targetObjectId != null) {\n slots.add(RegistryUtil.newStringSlot(\"targetObjectId\",\n targetObjectId));\n }\n\n if (sourceObjectType != null) {\n slots.add(RegistryUtil.newStringSlot(\"sourceObjectType\",\n sourceObjectType));\n }\n\n if (targetObjectType != null) {\n slots.add(RegistryUtil.newStringSlot(\"targetObjectType\",\n targetObjectType));\n }\n\n if (associationType != null) {\n slots.add(RegistryUtil.newStringSlot(\"associationType\",\n associationType));\n }\n\n return slots;\n }", "private ObservableList<ExpiringItem> getExpiringItems(ObservableList<Item> itemList) {\n ObservableList<ExpiringItem> tableRows = FXCollections.observableArrayList();\n for (int i = 0; i <= 7; i++) {\n tableRows.add(new ExpiringItem(i, itemList));\n }\n return tableRows;\n }", "public java.util.Enumeration getSitedoc2Splaces() throws java.rmi.RemoteException, javax.ejb.FinderException, javax.naming.NamingException {\n\n instantiateEJB();\n return ejbRef().getSitedoc2Splaces();\n }", "public List<Missile> getFriendlyMissilesOnStage(){\n\t\treturn this.friendlyMissiles;\n\t}", "@Transactional(readOnly = true)\n public Page<ItemInstance> findAll(Pageable pageable) {\n log.debug(\"Request to get all ItemInstances\");\n return itemInstanceRepository.findAll(pageable);\n }", "public List<Tile> getOwnedTiles() {\n return new ArrayList<Tile>(ownedTiles);\n }", "ArrayList<Tile> getTilesPlayerTwo() throws RemoteException;", "List<PilotContainer> getPilots();", "public List<Missile> getMissilesOnStage(){\n\t\treturn this.missiles;\n\t}", "private List<String> asExpiredItemsReportTableRow(Item item) {\n\t\treturn Arrays.asList(item.getProduct().getDescription(), item.getStorageUnitName(),\n\t\t\t\titem.getProductGroupName(), report.formatForReport(item.getEntryDate()),\n\t\t\t\treport.formatForReport(item.getExpirationDate()), item.getBarcode());\n\t}", "@Override\n\tpublic List<DgItemTimeLimitPic> selectAllHPic() {\n\t\treturn dgItemTimeLimitPicMapper.selectAllHPic();\n\t}", "private TileGrid createItemsTileGrid() {\n\t\titemsTileGrid.setBorder(\"1px solid #C0C3C7\");\r\n\t\titemsTileGrid.setTileWidth(100);\r\n\t\titemsTileGrid.setTileHeight(140);\r\n\t\titemsTileGrid.setTileValueAlign(\"left\");\r\n\t\titemsTileGrid.setWidth100();\r\n\t\titemsTileGrid.setHeight100();\r\n\t\titemsTileGrid.setAnimateTileChange(true);\r\n\t\t\r\n\t\titemsTileGrid.setShowAllRecords(true);\r\n\t\titemsTileGrid.setDataSource(SmartGWTRPCDataSource.getInstance());\r\n\t\titemsTileGrid.setAutoFetchData(false);\r\n\r\n\t\tDetailViewerField imageField = new DetailViewerField(\"imageKey\");\r\n\t\tDetailViewerField name = new DetailViewerField(\"name\");\r\n\t\tDetailViewerField company = new DetailViewerField(\"company\");\r\n\t\tDetailViewerField ownerNickName = new DetailViewerField(\"ownerNickName\");\r\n\t\tDetailViewerField averageRating = new DetailViewerField(\"averageRating\");\r\n\t\t//show star images for the average rating\r\n\t\taverageRating.setDetailFormatter(new DetailFormatter() {\r\n\t\t\tpublic String format(Object value, DetailViewerRecord record,\r\n\t\t\t\t\tDetailViewerField field) {\r\n\t\t\t\t\tint averageRating = record.getAttributeAsInt(\"averageRating\");\r\n\t\t\t\t\tint numberOfRatings = record.getAttributeAsInt(\"numberOfRatings\");\r\n\t\t\t\treturn createStarsHTMLString(averageRating) + \" / \" + numberOfRatings;\r\n\t\t\t}\r\n\t\t});\r\n\t\t\r\n\t\tDetailViewerField lastUpdated = new DetailViewerField(\"lastUpdated\");\r\n\t\tlastUpdated.setDetailFormatter(new DetailFormatter() {\r\n\t\t\tpublic String format(Object value, DetailViewerRecord record,\r\n\t\t\t\t\tDetailViewerField field) {\r\n\t\t\t\t\tDate lastUpdated = record.getAttributeAsDate(\"lastUpdated\");\r\n\t\t\t if(lastUpdated == null) return null; \r\n\t\t\t return dateFormatter.format(lastUpdated);\r\n\t\t\t}\r\n\t\t}\r\n\t\t);\r\n\t\titemsTileGrid.setFields(imageField, name, company ,ownerNickName, \r\n\t\t\t\taverageRating, lastUpdated);\r\n\t\titemsTileGrid.addRecordClickHandler(new RecordClickHandler() {\r\n\t\t\tpublic void onRecordClick(RecordClickEvent event) {\r\n\t\t\t\tSwagItemGWTDTO dto = new SwagItemGWTDTO();\r\n\t\t\t\tSmartGWTRPCDataSource.copyValues(event.getRecord(),dto);\r\n\t\t\t\tprepareAndShowEditForm(event.getRecord());\r\n\t\t\t}\r\n\t\t});\r\n\t\treturn itemsTileGrid;\r\n\t}", "Collection<Instance> getInstances();", "private final Item createPileItem(Item posItem, boolean starting) {\n/* */ try {\n/* 4519 */ Item pileItem = ItemFactory.createItem(177, 60.0F, null);\n/* */ \n/* 4521 */ float newXPos = ((this.tilex << 2) + 1) + Server.rand.nextFloat() * 2.0F;\n/* 4522 */ float newYPos = ((this.tiley << 2) + 1) + Server.rand.nextFloat() * 2.0F;\n/* */ \n/* 4524 */ float height = posItem.getPosZ();\n/* 4525 */ if (Server.getSecondsUptime() > 0) {\n/* 4526 */ height = Zones.calculatePosZ(newXPos, newYPos, this, isOnSurface(), false, posItem\n/* 4527 */ .getPosZ(), null, posItem.onBridge());\n/* */ }\n/* */ \n/* */ \n/* */ \n/* 4532 */ pileItem.setPos(newXPos, newYPos, height, posItem\n/* 4533 */ .getRotation(), posItem.getBridgeId());\n/* */ \n/* 4535 */ pileItem.setZoneId(this.zone.getId(), this.surfaced);\n/* 4536 */ int data = posItem.getTemplateId();\n/* 4537 */ pileItem.setData1(data);\n/* 4538 */ byte material = 0;\n/* 4539 */ boolean multipleMaterials = false;\n/* */ \n/* */ \n/* */ \n/* 4543 */ if (this.vitems != null)\n/* */ {\n/* 4545 */ for (Item item : this.vitems.getAllItemsAsArray()) {\n/* */ \n/* 4547 */ if (!item.isDecoration() && item.getFloorLevel() == pileItem.getFloorLevel()) {\n/* */ \n/* 4549 */ if (!starting)\n/* 4550 */ sendRemoveItem(item, false); \n/* 4551 */ if (!multipleMaterials)\n/* */ {\n/* */ \n/* */ \n/* 4555 */ if (item.getMaterial() != material)\n/* */ {\n/* 4557 */ if (material == 0) {\n/* */ \n/* */ \n/* */ \n/* 4561 */ material = item.getMaterial();\n/* */ \n/* */ \n/* */ \n/* */ }\n/* */ else {\n/* */ \n/* */ \n/* */ \n/* 4570 */ material = 0;\n/* 4571 */ multipleMaterials = true;\n/* */ } \n/* */ }\n/* */ }\n/* 4575 */ if (!item.equals(posItem))\n/* 4576 */ pileItem.insertItem(item, true); \n/* 4577 */ if (data != -1 && item.getTemplateId() != data) {\n/* */ \n/* 4579 */ pileItem.setData1(-1);\n/* 4580 */ data = -1;\n/* */ } \n/* */ } \n/* */ } \n/* */ }\n/* 4585 */ String name = pileItem.getName();\n/* 4586 */ String modelname = pileItem.getModelName();\n/* 4587 */ if (data != -1) {\n/* */ \n/* 4589 */ ItemTemplate template = ItemTemplateFactory.getInstance().getTemplate(data);\n/* 4590 */ String tname = template.getName();\n/* 4591 */ name = \"Pile of \" + template.sizeString + tname;\n/* 4592 */ if (material == 0) {\n/* 4593 */ pileItem.setMaterial(template.getMaterial());\n/* */ } else {\n/* 4595 */ pileItem.setMaterial(material);\n/* 4596 */ } StringBuilder build = new StringBuilder();\n/* 4597 */ build.append(pileItem.getTemplate().getModelName());\n/* 4598 */ build.append(tname);\n/* 4599 */ build.append(\".\");\n/* 4600 */ build.append(MaterialUtilities.getMaterialString(material));\n/* 4601 */ modelname = build.toString().replaceAll(\" \", \"\").trim();\n/* 4602 */ pileItem.setName(name);\n/* */ } \n/* */ \n/* */ \n/* 4606 */ if (!starting && this.watchers != null)\n/* */ {\n/* 4608 */ for (VirtualZone vz : getWatchers()) {\n/* */ \n/* */ \n/* */ try {\n/* 4612 */ if (vz.isVisible(pileItem, this)) {\n/* */ \n/* 4614 */ boolean onGroundLevel = true;\n/* 4615 */ if (pileItem.getFloorLevel() > 0) {\n/* 4616 */ onGroundLevel = false;\n/* */ \n/* */ }\n/* 4619 */ else if ((getFloors(0, 0)).length > 0) {\n/* 4620 */ onGroundLevel = false;\n/* */ } \n/* 4622 */ vz.addItem(pileItem, this, onGroundLevel);\n/* 4623 */ if (data != -1) {\n/* 4624 */ vz.renameItem(pileItem, name, modelname);\n/* */ }\n/* */ } \n/* 4627 */ } catch (Exception e) {\n/* */ \n/* 4629 */ logger.log(Level.WARNING, e.getMessage(), e);\n/* */ } \n/* */ } \n/* */ }\n/* 4633 */ return pileItem;\n/* */ }\n/* 4635 */ catch (FailedException fe) {\n/* */ \n/* 4637 */ logger.log(Level.WARNING, fe.getMessage(), (Throwable)fe);\n/* */ }\n/* 4639 */ catch (NoSuchTemplateException nst) {\n/* */ \n/* 4641 */ logger.log(Level.WARNING, nst.getMessage(), (Throwable)nst);\n/* */ } \n/* 4643 */ return null;\n/* */ }", "public ArrayList<Cell> getPseudoLegalMoves() {\n\n int[][] offsetMultiplier = {{-1,-1},{-1,1},{1,-1},{1,1}}; //4 directions NW, NE, SW, SE\n int x = getRow(); int y = getColumn();\n\n\n return Piece.slidingPieceMoves(x,y,this.getColor(),offsetMultiplier);\n\n }", "public List<Item> getAllItemsAvailable();", "@SuppressWarnings(\"unchecked\")\n private void createTable() {\n table = (LinkedList<Item<V>>[])new LinkedList[capacity];\n for(int i = 0; i < table.length; i++) {\n table[i] = new LinkedList<>();\n }\n }", "public Point[] checkSpotsForTwo(ParkingLot p)\r\n {\r\n if(p.getCapacity() >= 2){\r\n ArrayList<Point[]> emptySpots = new ArrayList<>();\r\n for(int i = 0; i < p.getTotalRow(); i++){\r\n for(int j = 0; j < p.getTotalColumn(); j++){\r\n if(!p.getOccupany(i,j)){\r\n if(j+1 <= p.getTotalColumn()-1 && !p.getOccupany(i,j+1)){\r\n emptySpots.add(new Point[]{new Point(i,j),new Point(i,j+1)});\r\n }\r\n }\r\n }\r\n }\r\n if(emptySpots.size() > 0){\r\n Random rand = new Random();\r\n return emptySpots.get(rand.nextInt(emptySpots.size()));\r\n }else{\r\n return moveCars(p);\r\n }\r\n }else{\r\n System.out.println(\"There are not enough spots in this lot to park this car.\");\r\n return null;\r\n }\r\n }", "public List<Square> getSquareGrid();", "public InventoryMenuTabItemSlots() {\n\t\t// Create our item slots list.\n\t\titemSlots = new ArrayList<ItemSlot>();\n\t\t// Populate our item slots list.\n\t\tTexture itemSlotBackground = new Texture(\"graphics/gamemenu/inventory/inventory_gamemenu_itemslot.png\");\n\t\tTexture itemSlotQuantityOverlay = new Texture(\"graphics/gamemenu/inventory/inventory_gamemenu_quantity_overlay.png\");\n\t\tTexture itemSlotSelectedOverlay = new Texture(\"graphics/gamemenu/inventory/inventory_gamemenu_itemslot_selectedoverlay.png\");\n\t\tFreeTypeFontGenerator.FreeTypeFontParameter parameter = new FreeTypeFontGenerator.FreeTypeFontParameter();\n\t\tparameter.size = C.FONT_SIZE_XXSMALL;\n\t\tBitmapFont quantityCountFont = FontPack.getFontPack().getFont(FontPack.FontType.MAIN_FONT, parameter);\n\t\tquantityCountFont.setColor(Color.BLACK);\n\t\tfor(int slotX = 0; slotX < C.MENU_INVENTORY_ITEM_SLOT_WIDTH; slotX++) {\n\t\t\tfor(int slotY = C.MENU_INVENTORY_ITEM_SLOT_HEIGHT - 1; slotY >= 0; slotY--) {\n\t\t\t\titemSlots.add(new ItemSlot(itemSlotBackground, itemSlotQuantityOverlay, itemSlotSelectedOverlay, quantityCountFont, slotX, slotY));\n\t\t\t}\n\t\t}\n\t}", "public Set<Irrigation> getAvailableIrrigationSlots ()\n {\n Set<Irrigation> availableIrrigations = new HashSet<>();\n\n ArrayList<Cell> neightboors;\n\n neightboors = getExistingNeighboors(new Point());\n\n neightboors.forEach(cell -> {\n ArrayList<Cell> touching = getCommonNeighboors(cell.getCoords(), new Point());\n touching.stream()\n .filter(t -> !verifIrrigation(cell.getCoords(), t.getCoords()))\n .forEach(t -> availableIrrigations.add(new Irrigation((Plot) t, (Plot) cell)));\n });\n\n for (Irrigation irg : irrigation)\n {\n\n neightboors = getCommonNeighboors(irg.getPlot1().getCoords(), irg.getPlot2().getCoords());\n\n neightboors.stream().filter(cell -> !(cell.getCoords().equals(new Point()))).forEach(plot -> {\n\n if (!verifIrrigation(plot.getCoords(), irg.getPlot1().getCoords())) availableIrrigations.add(new Irrigation((Plot) plot,\n irg.getPlot1()));\n\n if (!verifIrrigation(plot.getCoords(), irg.getPlot2().getCoords())) availableIrrigations.add(new Irrigation((Plot) plot,\n irg.getPlot2()));\n\n });\n }\n availableIrrigations.removeAll(irrigation);\n return availableIrrigations;\n }", "@Override\n\tpublic List<AvailableSlot> getAvailableSlots() {\n\t\tList<AvailableSlot> slots = (List<AvailableSlot>) availableSlotRepository.findAll();\n\t\treturn slots;\n\t}", "public List<Cell> getFreeSorroundingCells(Cell cell) {\r\n List<Cell> freeCells = new LinkedList<>();\r\n if (!getNorthCell(cell).hasAgent()) {\r\n freeCells.add(getNorthCell(cell));\r\n }\r\n if (!getSouthCell(cell).hasAgent()) {\r\n freeCells.add(getSouthCell(cell));\r\n }\r\n if (!getEastCell(cell).hasAgent()) {\r\n freeCells.add(getEastCell(cell));\r\n }\r\n if (!getWestCell(cell).hasAgent()) {\r\n freeCells.add(getWestCell(cell));\r\n }\r\n return freeCells;\r\n }", "@Override\r\n\tpublic List<Pit> generatePitsFilledWithStones() {\r\n\r\n\t\tList<Pit> pitList = Collections.synchronizedList(new ArrayList<Pit>());\r\n\r\n\t\tint iCurrentIndex = 1;\r\n\r\n\t\tint iTotalNumberOfPits = GameSettings.NUMBER_OF_PITS_PER_PLAYER * 2 + 2;\r\n\r\n\t\tfor (int i = 0; i < iTotalNumberOfPits; i++) {\r\n\r\n\t\t\tPit pit = new Pit(iCurrentIndex++);\r\n\r\n\t\t\tif (!pit.isKalah()) {\r\n\r\n\t\t\t\tfor (int j = 0; j < GameSettings.NUMBER_OF_STONES_PER_PIT; j++) {\r\n\r\n\t\t\t\t\tpit.addStone(new Stone());\r\n\r\n\t\t\t\t}\r\n\r\n\t\t\t}\r\n\r\n\t\t\tpitList.add(pit);\r\n\r\n\t\t}\r\n\r\n\t\treturn pitList;\r\n\r\n\t}", "public List<TicTacToeCoordinates> getAvailableSpots() {\n List<TicTacToeCoordinates> openSpots = new ArrayList<>();\n for (int x = 0; x < boardLength; x++) {\n for (int y = 0; y < boardWidth; y++) {\n if (board[x][y] == '\\u0000') {\n openSpots.add(new TicTacToeCoordinates(x, y));\n }\n }\n }\n return openSpots;\n }", "@Override\n\tpublic ArrayList<Object> getList() {\n\t\tSession session = HibernateUtil.getSession();\n\t\tsession.beginTransaction();\n\t\tString hsql=\"from hibernate.pojo.GmSite as site where site.display='true'\";\n\t\tQuery query = session.createQuery(hsql);\n\t\tsession.getTransaction().commit();\n\t\tArrayList<Object> list = new ArrayList<Object>();\n\t\tlist = (ArrayList<Object>) query.list();\n\t\t\n\t\tsession.close();\n\t\treturn list;\n\t}", "private final List<CardTemplate> m104972b() {\n ArrayList arrayList = new ArrayList();\n try {\n TraceCompat.beginSection(C6969H.m41409d(\"G6A91D01BAB35EB3DE3038044F3F1C6C42985C715B270A726E50F9C\"));\n BaseApplication baseApplication = BaseApplication.INSTANCE;\n C32569u.m150513a((Object) baseApplication, C6969H.m41409d(\"G4B82C61F9E20BB25EF0D915CFBEACD9940ADE62E9E1E880C\"));\n InputStream open = baseApplication.getAssets().open(C6969H.m41409d(\"G7A8BD408BA33A43BE3319349E0E1FCC36C8EC516BE24AE3AA8048347FC\"));\n Throwable th = null;\n BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(open));\n Throwable th2 = null;\n arrayList.addAll(C21014i.m104969a(ReadWrite.m150446a(bufferedReader)));\n Closeable.m150417a(bufferedReader, th2);\n Closeable.m150417a(open, th);\n TraceCompat.endSection();\n } catch (Exception unused) {\n SharePasteurKt gVar = SharePasteurKt.f75319a;\n String d = C6969H.m41409d(\"G4A82C71E8B35A639EA0F844DE1\");\n if (gVar.m105544a()) {\n Pasteur.m114763b(d, C6969H.m41409d(\"G6C91C715AD70A427A61C9549F6ECCDD02990DD1BAD35A826F40BAF4BF3F7C7E87D86D80AB331BF2CF54E965AFDE883DB6680D416\"));\n }\n }\n return arrayList;\n }", "@NotNull\r\n BlockState[] getTileEntities();", "private Map<LinkKey, Set<TributarySlot>> findAvailableTributarySlots(OpticalOduIntent intent, Path path) {\n Set<LinkKey> linkRequest = Sets.newHashSetWithExpectedSize(path.links().size());\n for (int i = 0; i < path.links().size(); i++) {\n LinkKey link = linkKey(path.links().get(i));\n linkRequest.add(link);\n }\n\n return findTributarySlots(intent, linkRequest);\n }", "private List<Block> createBlocks() {\n ArrayList<String> listOfBlocksAndSpacers = new ArrayList<String>();\n boolean buffer = false;\n for (int i = 0; i < level.size(); i++) {\n // if it starts with END_BLOCKS\n if (level.get(i).startsWith(\"END_BLOCKS\")) {\n buffer = false;\n } // if the buffer is true\n if (buffer) {\n listOfBlocksAndSpacers.add(level.get(i));\n } // if it starts with START_BLOCKS\n if (level.get(i).startsWith(\"START_BLOCKS\")) {\n buffer = true;\n } else if (level.get(i).startsWith(\"END_BLOCKS\")) {\n buffer = false;\n }\n }\n // find the x position where it all starts\n int startX = Integer.parseInt(this.map.get(\"blocks_start_x\"));\n int xForSave = startX;\n // find the y position where it all starts\n int startY = Integer.parseInt(this.map.get(\"blocks_start_y\"));\n List<Block> listOfBlocks = new ArrayList<>();\n String[] s;\n setBlocks();\n // go over the list of blocks of spacers\n for (int i = 0; i < listOfBlocksAndSpacers.size(); i++) {\n // split it with empty lines\n s = listOfBlocksAndSpacers.get(i).split(\"\");\n for (int j = 0; j < s.length; j++) {\n if (s[j].equals(\"\")) {\n continue;\n } // if it is a block symbol\n if (this.factory.isBlockSymbol(s[j])) {\n // add to listOfBlocks a block\n listOfBlocks.add(this.factory.getBlock(s[j], startX, startY));\n // continue to the next block with the next location\n startX += this.factory.getBlock(s[j], startX, startY).getCollisionRectangle().getWidth();\n } else if (this.factory.isSpaceSymbol(s[j])) { // move following\n // spacers\n startX += this.factory.getSpaceWidth(s[j]);\n }\n }\n startX = xForSave;\n startY += Integer.parseInt(this.map.get(\"row_height\"));\n }\n // put the blocks in a new blocks list and return it\n List<Block> listOfBlocksCopy = new ArrayList<>();\n for (int z = 0; z < listOfBlocks.size(); z++) {\n listOfBlocksCopy.add(listOfBlocks.get(z).copyBlock());\n }\n return listOfBlocksCopy;\n }", "public HashMap<String, List<String>> getItemMap() {\r\n\r\n\t\thelmet_abilities.add(Game_constants.INTELLIGENCE);\r\n\t\thelmet_abilities.add(Game_constants.WISDOM);\r\n\t\thelmet_abilities.add(Game_constants.ARMOR_CLASS);\r\n\r\n\t\tarmor_abilities.add(Game_constants.ARMOR_CLASS);\r\n\r\n\t\tshield_abilities.add(Game_constants.ARMOR_CLASS);\r\n\r\n\t\tring_abilities.add(Game_constants.ARMOR_CLASS);\r\n\t\tring_abilities.add(Game_constants.STRENGTH);\r\n\t\tring_abilities.add(Game_constants.CONSTITUTION);\r\n\t\tring_abilities.add(Game_constants.WISDOM);\r\n\t\tring_abilities.add(Game_constants.CHARISMA);\r\n\r\n\t\tbelt_abilities.add(Game_constants.CONSTITUTION);\r\n\t\tbelt_abilities.add(Game_constants.STRENGTH);\r\n\r\n\t\tboots_abilities.add(Game_constants.ARMOR_CLASS);\r\n\t\tboots_abilities.add(Game_constants.DEXTERITY);\r\n\r\n\t\tweapon_abilities.add(Game_constants.ATTACK_BONUS);\r\n\t\tweapon_abilities.add(Game_constants.DAMAGE_BONUS);\r\n\r\n\t\titem_map.put(Game_constants.HELMET, helmet_abilities);\r\n\t\titem_map.put(Game_constants.ARMOR, armor_abilities);\r\n\t\titem_map.put(Game_constants.SHIELD, shield_abilities);\r\n\t\titem_map.put(Game_constants.RING, ring_abilities);\r\n\t\titem_map.put(Game_constants.BELT, belt_abilities);\r\n\t\titem_map.put(Game_constants.BOOTS, boots_abilities);\r\n\t\titem_map.put(Game_constants.WEAPON_MELEE, weapon_abilities);\r\n\t\titem_map.put(Game_constants.WEAPON_RANGE, weapon_abilities);\r\n\r\n\t\treturn item_map;\r\n\r\n\t}", "public List<Sq<Sq<Cell>>> explosion() {\n\t\tList<Sq<Sq<Cell>>> explosion = new ArrayList<>();\n\n\t\texplosion.add(explosionArmTowards(Direction.N));\n\t\texplosion.add(explosionArmTowards(Direction.E));\n\t\texplosion.add(explosionArmTowards(Direction.S));\n\t\texplosion.add(explosionArmTowards(Direction.W));\n\n\t\treturn explosion;\n\t}", "java.util.List<org.jetbrains.r.classes.S4ClassInfo.S4ClassSlot> \n getSlotsList();", "public Map<Integer, List<CellEntry>> buildShipMap() {\n Map<Integer, List<CellEntry>> shipCellMap = new HashMap<>();\n for (int i = 0; i < BOARD_CELL_NUM_PER_SIDE; i++) {\n for (int j = 0; j < BOARD_CELL_NUM_PER_SIDE; j++) {\n Cell cell = getCell(i, j);\n if (cell.getShipIndex() != -1) {\n int shipIndex = cell.getShipIndex();\n if (!shipCellMap.containsKey(shipIndex)) {\n shipCellMap.put(shipIndex, new ArrayList<>());\n }\n\n CellEntry cellEntry = new CellEntry(cell.getIndex(), cell.getShipIndex());\n shipCellMap.get(shipIndex).add(cellEntry);\n }\n }\n }\n return shipCellMap;\n }", "public List<DataSource.IntrospectionPlan> getPlans () {\n return plans;\n }", "public PerishableItem(){\n super();\n //perishable = false;\n }", "public List<Item> getItemList();", "ObservableList<Deliverable> getInternalDeliverableList();", "private Collection getInstances() {\n \t\tCollection instances=null;\r\n\r\n //instances = cls.getInstances();\r\n \t\tRDFProperty ready = owlModel.getRDFProperty(oTab.namespacePrefix + \":\" + oTab.pReady);\r\n\r\n \t\tif ( ready != null )\r\n \t\t{\r\n \t\t\tinstances = owlModel.getRDFResourcesWithPropertyValue(ready, true);\r\n \t\t}\r\n \t\telse\r\n \t\t{\r\n \t\t\tSystem.out.println(\"*** Could not lookup property defintion for \" + oTab.namespacePrefix + \":\" + oTab.pReady + \" Ontology not imported\");\r\n \t\t}\r\n\r\n return instances;\r\n }", "@VTID(20)\n @ReturnValue(type=NativeType.VARIANT)\n java.lang.Object getVisibleSlicerItemsList();", "List<RecordItemValidatorIF> getItemValidators();", "public com.dosmil_e.mall.core.ifc.MallShippingIfc[] getShippings( EAIMMCtxtIfc theCtxt) throws EAIException;", "java.util.List<Report.LocationOuterClass.MobileCell> \n getCellsList();", "@SuppressWarnings(\"unchecked\")\r\n\tpublic List<TimeTableBean> getTimeTable() {\n\t\treturn sessionFactory.openSession().createQuery(\"from TimeTableBean\").list();\r\n\t}", "private List<Tile> makeTiles() {\n List<Tile> tiles = new ArrayList<>();\n Board board = (Board) boardManager.getBoard();\n final int numTiles = board.getNumRows() * board.getNumCols();\n for (int tileNum = 0; tileNum != numTiles; tileNum++) {\n tiles.add(new Tile(tileNum + 1, tileNum, 4));\n }\n\n return tiles;\n }", "public List<REPoint> getObstacles();", "private Set<BoardObject> createWeapons(){\r\n\t\tSet<BoardObject> weaps = new HashSet<BoardObject>();\r\n\r\n\t\tweaps.add(new BoardObject(getImage(\"xboardObjects/revolver1.png\"), new Coordinate(3,12), \"Revolver\"));\r\n\t\tweaps.add(new BoardObject(getImage(\"xboardObjects/candlestick3.png\"), new Coordinate(2,3), \"Candlestick\"));\r\n\t\tweaps.add(new BoardObject(getImage(\"xboardObjects/knife1.png\"), new Coordinate(12,3), \"Knife\"));\r\n\t\tweaps.add(new BoardObject(getImage(\"xboardObjects/leadpipe1.png\"), new Coordinate(20,3), \"LeadPipe\"));\r\n\t\tweaps.add(new BoardObject(getImage(\"xboardObjects/rope1.png\"), new Coordinate(20,10), \"Rope\"));\r\n\t\tweaps.add(new BoardObject(getImage(\"xboardObjects/spanner1.png\"), new Coordinate(20,16), \"Wrench\"));\r\n\t\treturn weaps;\r\n\t}", "public SmartList<Square> getSquares() {\n return new SmartList<Square>(this.squares).freeze();\n }", "public List<Move> getAvailableSpaces() {\n List<Move> availableMoves = new ArrayList<>();\n for (int i = 0; i < LENGTH; i++) {\n for (int j = 0; j < LENGTH; j++) {\n Move move = new Move(i, j);\n if (isValidMove(move)) {\n availableMoves.add(move);\n }\n }\n }\n return availableMoves;\n }", "@Override\n\tpublic List<Map> boardPopularList() {\n\t\treturn dao.boardPopularList(session);\n\t}", "@Override\n\tpublic List<StopPoint> listStopPoints() {\n\t\tString jql = \"SELECT s FROM StopPoint s\";\n\t\tList<StopPoint> listStopPoints = this.entityManager.createQuery(jql, StopPoint.class ).getResultList();\n\t\treturn listStopPoints;\n\t}", "@SuppressWarnings(\"unchecked\")\n public List<Item> getListOfTasks() {\n Session session = this.factory.openSession();\n List<Item> list = session.createQuery(\"from Item\").list();\n session.close();\n return list;\n }", "public Tiles() {\n basketWeave();\n med1();\n med2();\n }", "java.util.List<message.Figure.FigureData.FigureLevelTable> \n getLevelTableListList();", "public Ships() {\n\t\tships = new ArrayList<Ship>();\n\t\tships.add(new Ship(ShipType.BATTLESHIP));\n\t\tships.add(new Ship(ShipType.CRUISER));\n\t\tships.add(new Ship(ShipType.CRUISER));\n\t\tships.add(new Ship(ShipType.DESTROYER));\n\t\tships.add(new Ship(ShipType.DESTROYER));\n\t\tships.add(new Ship(ShipType.DESTROYER));\n\t\tships.add(new Ship(ShipType.SUBMARINE));\n\t\tships.add(new Ship(ShipType.SUBMARINE));\n\t\tships.add(new Ship(ShipType.SUBMARINE));\n\t}", "public List<MagicSquare> buildMagicSquares() {\n solutions = new ArrayList<>();\n sampler = new Sampler(Bound.getAllElements(1, totalNumbersCnt));\n\n for (int possibleNumber : sampler.getNumbers(new Bound(1, totalNumbersCnt))) {\n if (sampler.contains(possibleNumber)) {\n buildRow(sampler.getNumber(possibleNumber), 0, 0);\n }\n }\n\n return solutions;\n }", "public boolean canBombThisEnemyAndRunSafe(Player p1, Player p2){\n Maze maze = state.getMaze();\n Cell[][] tabcells = maze.getCells();\n //Cells in range of p1 corresponds to the cells p1 can put a bomb on associated with the number of moves needed\n //to go to the cell where p1 would be when putting the bomb\n ArrayList<Journey> journeysinrangeofp1 = new ArrayList<Journey>();\n //Available moves to flee represents how many moves p1 would still have to run away from its bomb\n int availablemovestoflee;\n //Available cells to flee represents the cells p1 can run to after putting the bomb\n List<Cell> availablecellstoflee = new ArrayList<>();\n List<Cell> bombingavailableslots = new ArrayList<Cell>();\n //Bombing available slots corresponds to the cells where a bomb could be placed to kill p2\n for(int i = 0; i<=p1.getBombRange();i++){\n if((p2.getX()-i)>=0){\n bombingavailableslots.add(tabcells[p2.getX()-i][p2.getY()]);\n }\n if((p2.getX()+i)<maze.getWidth()){\n bombingavailableslots.add(tabcells[p2.getX()+i][p2.getY()]);\n }\n if((p2.getY()-i)>=0){\n bombingavailableslots.add(tabcells[p2.getX()][p2.getY()-i]);\n }\n if((p2.getY()+i)<maze.getHeight()){\n bombingavailableslots.add(tabcells[p2.getX()][p2.getY()+i]);\n }\n }\n journeysinrangeofp1 = getReacheableCellsInRangeWithPath(tabcells[p1.getX()][p1.getY()],p1.getNumberMoveRemaining()+1);\n for(Journey j:journeysinrangeofp1){\n if(bombingavailableslots.contains(j.getDestinationcell())){\n availablemovestoflee = p1.getNumberMoveRemaining() - j.getNbmoves();\n availablecellstoflee = getReacheableCellsInRange(j.getDestinationcell(), availablemovestoflee);\n for(Cell c: availablecellstoflee){\n if(wouldBeSafeFromBomb(p1,j.getDestinationcell(),c)){\n if(isSafeFromAllPlayersExcept(c,p1,p2)){\n return true;\n }\n }\n }\n }\n }\n return false;\n }", "public List<String> getPlanItemIds();", "public List<Object> getShips() {\n return ships;\n }", "public Tile[] generateTiles() {\n return null;\n }", "ArrayList<Tile> getTilesPlayerOne() throws RemoteException;", "private void loadItems() {\n try {\n if (ServerIdUtil.isServerId(memberId)) {\n if (ServerIdUtil.containsServerId(memberId)) {\n memberId = ServerIdUtil.getLocalId(memberId);\n } else {\n return;\n }\n }\n List<VideoReference> videoReferences = new Select().from(VideoReference.class).where(VideoReference_Table.userId.is(memberId)).orderBy(OrderBy.fromProperty(VideoReference_Table.date).descending()).queryList();\n List<String> videoIds = new ArrayList<>();\n for (VideoReference videoReference : videoReferences) {\n videoIds.add(videoReference.getId());\n }\n itemList = new Select().from(Video.class).where(Video_Table.id.in(videoIds)).orderBy(OrderBy.fromProperty(Video_Table.date).descending()).queryList();\n } catch (Throwable t) {\n itemList = new ArrayList<>();\n }\n }", "@SuppressWarnings(\"unchecked\")\n public List<Item> getActiveTasks() {\n Session session = this.factory.openSession();\n List<Item> list = session.createQuery(\"from Item where status = 0\").list();\n session.close();\n return list;\n }", "public FreeCellModel() {\n gameStarted = false;\n foundationPiles = new ArrayList<IPile>();\n cascadePiles = new ArrayList<IPile>();\n openPiles = new ArrayList<IPile>();\n }", "public void createList () {\n imageLocs = new ArrayList <Location> ();\n for (int i = xC; i < xLength * getPixelSize() + xC; i+=getPixelSize()) {\n for (int j = yC; j < yLength * getPixelSize() + yC; j+=getPixelSize()) {\n Location loc = new Location (i, j, LocationType.POWERUP, true);\n\n imageLocs.add (loc);\n getGridCache().add(loc);\n \n }\n }\n }", "private static List<HantoCoordinate> getPerimeterSpaces(Board b) {\n\n\t\tList<HantoCoordinate> perimeter = new ArrayList<HantoCoordinate>();\n\t\tList<HantoCoordinate> toVisit = b.getAllOccupiedCoordinates();\n\n\t\tfor(HantoCoordinate current : toVisit){\n\n\t\t\tfor(HantoCoordinate neighbor : HantoUtil.getAllNeighbors(current)){\n\n\t\t\t\tif(!toVisit.contains(neighbor) && !perimeter.contains(neighbor)){\n\t\t\t\t\tperimeter.add(neighbor);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn perimeter;\n\t}", "@Override\r\n public List<Block> blocks() {\r\n List<Block> blockList = new ArrayList<Block>();\r\n java.awt.Color[] colors = new Color[5];\r\n colors[0] = Color.decode(\"#c1b8b2\");\r\n colors[1] = Color.decode(\"#ef1607\");\r\n colors[2] = Color.decode(\"#ffff1e\");\r\n colors[3] = Color.decode(\"#211ed8\");\r\n colors[4] = Color.decode(\"#fffff6\");\r\n int y = 150;\r\n int[] hitPoints = {2, 1, 1, 1, 1};\r\n for (int i = 0; i < colors.length; i++) {\r\n for (int j = i + 5; j < 15; j++) {\r\n blockList.add(new Block(j * 50 + 25, y, 50, 20, colors[i], hitPoints[i]));\r\n }\r\n y += 20;\r\n }\r\n return blockList;\r\n }", "public List<Cell> getFlaggedCells() {\n List<Cell> gameBoard = new ArrayList<Cell>();\n List<Cell> flaggedCells = new ArrayList<Cell>();\n for (Cell cell : gameBoard)\n if (cell.isFlagged())\n flaggedCells.add(cell);\n return flaggedCells;\n }", "public Array<BlockDrawable> getAllBlocksToDraw() {\r\n \tArray<BlockDrawable> blocksToDraw = new Array<BlockDrawable>();\r\n\t\tblocksToDraw.addAll(tablero);\r\n\t\tif(isGhostActivated()){\r\n\t\t\tblocksToDraw.addAll(getGhostBlocksToDraw());\r\n\t\t}\r\n\t\tif (hasFalling())\r\n\t\t\tblocksToDraw.addAll(falling.allOuterBlocks());\r\n\t\t\r\n\t\treturn blocksToDraw;\r\n }", "private List getMappingTablesInternal() {\n MappingTable primary = getPrimaryMappingTable();\n List tables = new ArrayList();\n\n if (primary != null) {\n MappingReferenceKey[] refKeys = primary.getMappingReferenceKeys();\n int i, count = ((refKeys != null) ? refKeys.length : 0);\n\n tables.add(primary);\n\n for (i = 0; i < count;i++) {\n MappingTable secondaryTable = refKeys[i].getMappingTable();\n\n if (secondaryTable != null)\n tables.add(secondaryTable);\n }\n }\n\n return tables;\n }", "public int getGadgetsSlots() {\n return base.getGadgetSlots();\n \n }", "public SafetyPile(){\r\n this.cards = new ArrayList<Card>();\r\n }", "public List<Block> blocks() {\r\n List<Block> list = new ArrayList<Block>();\r\n double width = 50;\r\n for (int i = 0; i < 7; ++i) {\r\n Color c = new Color(0, 0, 0);\r\n switch (i) {\r\n case 0:\r\n c = Color.gray;\r\n break;\r\n case 1:\r\n c = Color.red;\r\n break;\r\n case 2:\r\n c = Color.yellow;\r\n break;\r\n case 3:\r\n c = Color.green;\r\n break;\r\n case 4:\r\n c = Color.white;\r\n break;\r\n case 5:\r\n c = Color.pink;\r\n break;\r\n default:\r\n c = Color.cyan;\r\n break;\r\n }\r\n for (int j = 0; j < 15; ++j) {\r\n Block b = new Block(new Rectangle(new Point(\r\n 25 + j * width, 100 + i * 20), width, 20));\r\n if (i == 0) {\r\n b.setHitPoints(2);\r\n } else {\r\n b.setHitPoints(1);\r\n }\r\n list.add(b);\r\n }\r\n }\r\n return list;\r\n }", "protected Tile[] newTiles() {\n int len = getWidthInTiles() * getHeightInTiles();\n Tile[] t = new Tile[ len ];\n for(int i = 0; i < len; i++) {\n t[i] = null;\n }\n return t;\n }", "public Map<Pair<ID, ID>, List<Image>> getBulletImages() {\n return bulletImages;\n }", "public int[][] getShips() {\n return ships;\n }", "public static Map<List<Integer>, List<List<Integer>>> CollectTableInstasnces(List<List<Integer>> candidateList,\n Map<Integer,Map<List<Integer>, List<List<Integer>>>> starNeighbor,\n Map<List<Integer>, List<List<Integer>>> tableInstanceSizekSub1,\n int k){\n\n\n // [A, B]:[[1,2],[1,3]]\n // Return table instances\n Map<List<Integer>, List<List<Integer>>> tableInstances = new HashMap<>();\n\n // convert candidate to hashset\n Set<List<Integer>> candidateSet = new HashSet<>(candidateList);\n\n for(List<Integer> candidate: candidateSet){\n if (starNeighbor.containsKey(candidate.get(0))){\n\n // get remain candidate list\n List<Integer> remainCandidateElement = candidate.subList(1, k+1);\n\n // store the table instance of the current candidate\n List<List<Integer>> realCliquesAll = new ArrayList<>();\n\n // Loop hashmap\n Iterator<Map.Entry<List<Integer>, List<List<Integer>>>> itr = starNeighbor.get(candidate.get(0)).entrySet().iterator();\n while (itr.hasNext()){\n Map.Entry<List<Integer>, List<List<Integer>>> entry = itr.next();\n // put remain instance\n List<List<Integer>> tempRemain = new ArrayList<>();\n\n for (Integer feature : remainCandidateElement) {\n List<Integer> remainPoint = entry.getValue().parallelStream().filter( point ->\n point.get(0).equals(feature))\n .map(inst -> inst.get(1))\n .collect(Collectors.toList());\n\n if (!remainPoint.isEmpty()) {\n tempRemain.add(remainPoint);\n }\n }\n\n if (tempRemain.size() == k){\n // store the first instance into it\n tempRemain.add(0, Arrays.asList(entry.getKey().get(1)));\n\n // Cartesian product tempRemain based on combinatoricslib lib\n List<List<Integer>> remainFeatureInstance = MyGenerator.cartesianProductInteger(tempRemain);\n\n // Check real cliques\n List<List<Integer>> realClique = remainFeatureInstance.parallelStream().filter( row -> {\n\n return tableInstanceSizekSub1.get(remainCandidateElement).contains(row.subList(1, k+1));\n\n }).collect(Collectors.toList());\n\n if (!realClique.isEmpty()){\n realCliquesAll.addAll(realClique);\n }\n\n }\n }\n // put in table instances\n if(!realCliquesAll.isEmpty()){\n tableInstances.put(candidate, realCliquesAll);\n }\n }\n\n }\n return tableInstances;\n }", "private static List<Gene> getGenePool() {\n List<Gene> list = new ArrayList<>();\n\n Item item1 = new Item();\n item1.setName(\"Swiss Army Knife\");\n item1.setWeight(0.08125);\n item1.setVal(15);\n Gene gene1 = new Gene(item1);\n\n Item item2 = new Item();\n item2.setName(\"Duct Tape\");\n item2.setWeight(1.3);\n item2.setVal(3);\n Gene gene2 = new Gene(item2);\n\n Item item3 = new Item();\n item3.setName(\"Rope (50 feet)\");\n item3.setWeight(7);\n item3.setVal(10);\n Gene gene3 = new Gene(item3);\n\n Item item4 = new Item();\n item4.setName(\"Satellite phone\");\n item4.setWeight(2);\n item4.setVal(8);\n Gene gene4 = new Gene(item4);\n\n Item item5 = new Item();\n item5.setName(\"Elmer's Glue\");\n item5.setWeight(0.25);\n item5.setVal(2);\n Gene gene5 = new Gene(item5);\n\n Item item6 = new Item();\n item6.setName(\"Toilet Paper Roll\");\n item6.setWeight(.5);\n item6.setVal(4);\n Gene gene6 = new Gene(item6);\n\n Item item7 = new Item();\n item7.setName(\"Binoculars\");\n item7.setWeight(3);\n item7.setVal(5);\n Gene gene7 = new Gene(item7);\n\n Item item8 = new Item();\n item8.setName(\"Compass\");\n item8.setWeight(0.0573202);\n item8.setVal(15);\n Gene gene8 = new Gene(item8);\n\n Item item9 = new Item();\n item9.setName(\"Jug (pre-filled with water)\");\n item9.setWeight(4);\n item9.setVal(6);\n Gene gene9 = new Gene(item9);\n\n Item item10 = new Item();\n item10.setName(\"Flashlight\");\n item10.setWeight(2);\n item10.setVal(4);\n Gene gene10 = new Gene(item10);\n\n Item item11 = new Item();\n item11.setName(\"Box of paper clips\");\n item11.setWeight(.9);\n item11.setVal(2);\n Gene gene11 = new Gene(item11);\n\n Item item12 = new Item();\n item12.setName(\"Gloves (1 pair)\");\n item12.setWeight(.8125);\n item12.setVal(3);\n Gene gene12 = new Gene(item12);\n\n Item item13 = new Item();\n item13.setName(\"Scissors\");\n item13.setWeight(0.2);\n item13.setVal(2);\n Gene gene13 = new Gene(item13);\n\n Item item14 = new Item();\n item14.setName(\"Signal Flair (4pk)\");\n item14.setWeight(4);\n item14.setVal(5);\n Gene gene14 = new Gene(item14);\n\n Item item15 = new Item();\n item15.setName(\"Water Purifying System\");\n item15.setWeight(0.5125);\n item15.setVal(4);\n Gene gene15 = new Gene(item15);\n\n Item item16 = new Item();\n item16.setName(\"Whistle\");\n item16.setWeight(0.075);\n item16.setVal(2);\n Gene gene16 = new Gene(item16);\n\n Item item17 = new Item();\n item17.setName(\"Sleeping Bag\");\n item17.setWeight(0.38125);\n item17.setVal(4);\n Gene gene17 = new Gene(item17);\n\n Item item18 = new Item();\n item18.setName(\"Insect Repellent\");\n item18.setWeight(1.15);\n item18.setVal(3);\n Gene gene18 = new Gene(item18);\n\n Item item19 = new Item();\n item19.setName(\"Trowel\");\n item19.setWeight(0.31875);\n item19.setVal(3);\n Gene gene19 = new Gene(item19);\n\n Item item20 = new Item();\n item20.setName(\"Lighter\");\n item20.setWeight(.2);\n item20.setVal(4);\n Gene gene20 = new Gene(item20);\n\n Item item21 = new Item();\n item21.setName(\"Safety Horn\");\n item21.setWeight(.21);\n item21.setVal(3);\n Gene gene21 = new Gene(item21);\n\n Item item22 = new Item();\n item22.setName(\"Headlamp\");\n item22.setWeight(.8);\n item22.setVal(4);\n Gene gene22 = new Gene(item22);\n\n Item item23 = new Item();\n item23.setName(\"Freeze Dried Food Kit\");\n item23.setWeight(2);\n item23.setVal(6);\n Gene gene23 = new Gene(item23);\n\n Item item24 = new Item();\n item24.setName(\"Sunscreen\");\n item24.setWeight(.5);\n item24.setVal(4);\n Gene gene24 = new Gene(item24);\n\n Item item25 = new Item();\n item25.setName(\"Trekking Pole (Adjustable)\");\n item25.setWeight(1.3);\n item25.setVal(4);\n Gene gene25 = new Gene(item25);\n\n Item item26 = new Item();\n item26.setName(\"Counter Assault Bear Spray\");\n item26.setWeight(.5);\n item26.setVal(4);\n Gene gene26 = new Gene(item26);\n\n Item item27 = new Item();\n item27.setName(\"Insect Spray\");\n item27.setWeight(.5);\n item27.setVal(3);\n Gene gene27 = new Gene(item27);\n\n Item item28 = new Item();\n item28.setName(\"Hand sanitizer\");\n item28.setWeight(.625);\n item28.setVal(3);\n Gene gene28 = new Gene(item28);\n\n Item item29 = new Item();\n item29.setName(\"Mirror\");\n item29.setWeight(.5);\n item29.setVal(3);\n Gene gene29 = new Gene(item29);\n\n Item item30 = new Item();\n item30.setName(\"First Aid Kit\");\n item30.setWeight(3);\n item30.setVal(6);\n Gene gene30 = new Gene(item30);\n\n list.add(gene1);\n list.add(gene2);\n list.add(gene3);\n list.add(gene4);\n list.add(gene5);\n list.add(gene6);\n list.add(gene7);\n list.add(gene8);\n list.add(gene9);\n list.add(gene10);\n list.add(gene11);\n list.add(gene12);\n list.add(gene13);\n list.add(gene14);\n list.add(gene15);\n list.add(gene16);\n list.add(gene17);\n list.add(gene18);\n list.add(gene19);\n list.add(gene20);\n list.add(gene21);\n list.add(gene22);\n list.add(gene23);\n list.add(gene24);\n list.add(gene25);\n list.add(gene26);\n list.add(gene27);\n list.add(gene28);\n list.add(gene29);\n list.add(gene30);\n\n return list;\n }", "public List<TaskItemBean> getItemList(){\n return itemList;\n }", "public PerishableItem[] removePerishables() {\r\n // Check how many perishables items there are in total\r\n int perishableCount = 0;\r\n for (int i = 0; i < numItems; i++) { // Checks how many perishables in the cart (loose items)\r\n if (cart[i] instanceof PerishableItem) {\r\n perishableCount++;\r\n }\r\n }\r\n for (int i = 0; i < pBags.length; i++) { // Checks how many perishables in all the bags in the cart\r\n for (int j = 0; j < pBags[i].getNumItems(); j++) {\r\n if (pBags[i].getItems()[j] instanceof PerishableItem)\r\n perishableCount++;\r\n }\r\n }\r\n\r\n PerishableItem[] perishables = new PerishableItem[perishableCount];\r\n perishableCount = 0;\r\n // Assign any perishable item to 'perishables' variable and remove them from cart/packed bags\r\n for (int i = 0; i < numItems; i++) {\r\n if (cart[i] instanceof PerishableItem) { // Checks each item if its an instance of PerishableItem\r\n perishables[perishableCount++] = (PerishableItem) cart[i]; // Adds it to the perishables variable\r\n removeItem(cart[i]); // Removes it from the cart\r\n i--; // Checks the same element (Since its different now based on the removeItem function)\r\n }\r\n }\r\n for (int i = 0; i < pBags.length; i++) {\r\n PerishableItem[] perishablesInBags = pBags[i].unpackPerishables(); // Unpacks perishables from pbags and stores them into a variable\r\n for (int j = 0; j < perishablesInBags.length; j++) { // Loops through each item in perishablesInBags\r\n perishables[perishableCount++] = perishablesInBags[j]; // Assigns each item to the perishables variable\r\n }\r\n }\r\n return perishables; // Return the perishables items that were removed\r\n }", "List<IMEInventoryHandler> getCellArray();", "public Collection<Long> getAvailableItems();", "public Tiles getTiles() {\n return tiles;\n }", "public Collection<TimePeriod> getTimeSlots() {\n\t\treturn null;\n\t}", "private List getSSSSTransactions(DatasetItem datasetItem, SkillModelItem skillModelItem) {\n Session session = getSession();\n\n SQLQuery sqlQuery = session.createSQLQuery(GET_SSSS_NATIVE_MYSQL_QUERY);\n\n sqlQuery.setInteger(\"datasetId\", ((Integer)datasetItem.getId()).intValue());\n sqlQuery.setLong(\"skillModelId\", ((Long)skillModelItem.getId()).longValue());\n\n //indicate which columns map to which types.\n sqlQuery.addScalar(\"studentId\", Hibernate.LONG);\n sqlQuery.addScalar(\"firstAttempt\", Hibernate.STRING);\n sqlQuery.addScalar(\"stepId\", Hibernate.LONG);\n sqlQuery.addScalar(\"skillId\", Hibernate.LONG);\n sqlQuery.addScalar(\"problemId\", Hibernate.LONG);\n\n sqlQuery.setCacheable(false);\n sqlQuery.setCacheMode(CacheMode.IGNORE);\n\n logTrace(sqlQuery.toString());\n\n List results = sqlQuery.list();\n releaseSession(session);\n return results;\n }", "public List<Card> getDiscardPile() {\r\n return discardPile;\r\n }", "public static ClosableIterator<org.ontoware.rdf2go.model.node.Node> getAllBeatsPerMinute_asNode(Model model, org.ontoware.rdf2go.model.node.Resource instanceResource) {\r\n\t\treturn Base.getAll_asNode(model, instanceResource, BEATSPERMINUTE);\r\n\t}", "private void addSpawnsToList()\n\t{\n\t\tSPAWNS.put(1, new ESSpawn(1, GraciaSeeds.DESTRUCTION, new Location(-245790,220320,-12104), new int[]{TEMPORARY_TELEPORTER}));\n\t\tSPAWNS.put(2, new ESSpawn(2, GraciaSeeds.DESTRUCTION, new Location(-249770,207300,-11952), new int[]{TEMPORARY_TELEPORTER}));\n\t\t//Energy Seeds\n\t\tSPAWNS.put(3, new ESSpawn(3, GraciaSeeds.DESTRUCTION, new Location(-248360,219272,-12448), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(4, new ESSpawn(4, GraciaSeeds.DESTRUCTION, new Location(-249448,219256,-12448), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(5, new ESSpawn(5, GraciaSeeds.DESTRUCTION, new Location(-249432,220872,-12448), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(6, new ESSpawn(6, GraciaSeeds.DESTRUCTION, new Location(-248360,220888,-12448), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(7, new ESSpawn(7, GraciaSeeds.DESTRUCTION, new Location(-250088,219256,-12448), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(8, new ESSpawn(8, GraciaSeeds.DESTRUCTION, new Location(-250600,219272,-12448), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(9, new ESSpawn(9, GraciaSeeds.DESTRUCTION, new Location(-250584,220904,-12448), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(10, new ESSpawn(10, GraciaSeeds.DESTRUCTION, new Location(-250072,220888,-12448), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(11, new ESSpawn(11, GraciaSeeds.DESTRUCTION, new Location(-253096,217704,-12296), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(12, new ESSpawn(12, GraciaSeeds.DESTRUCTION, new Location(-253112,217048,-12288), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(13, new ESSpawn(13, GraciaSeeds.DESTRUCTION, new Location(-251448,217032,-12288), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(14, new ESSpawn(14, GraciaSeeds.DESTRUCTION, new Location(-251416,217672,-12296), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(15, new ESSpawn(15, GraciaSeeds.DESTRUCTION, new Location(-251416,217672,-12296), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(16, new ESSpawn(16, GraciaSeeds.DESTRUCTION, new Location(-251416,217016,-12280), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(17, new ESSpawn(17, GraciaSeeds.DESTRUCTION, new Location(-249752,217016,-12280), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(18, new ESSpawn(18, GraciaSeeds.DESTRUCTION, new Location(-249736,217688,-12296), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(19, new ESSpawn(19, GraciaSeeds.DESTRUCTION, new Location(-252472,215208,-12120), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(20, new ESSpawn(20, GraciaSeeds.DESTRUCTION, new Location(-252552,216760,-12248), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(21, new ESSpawn(21, GraciaSeeds.DESTRUCTION, new Location(-253160,216744,-12248), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(22, new ESSpawn(22, GraciaSeeds.DESTRUCTION, new Location(-253128,215160,-12096), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(23, new ESSpawn(23, GraciaSeeds.DESTRUCTION, new Location(-250392,215208,-12120), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(24, new ESSpawn(24, GraciaSeeds.DESTRUCTION, new Location(-250264,216744,-12248), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(25, new ESSpawn(25, GraciaSeeds.DESTRUCTION, new Location(-249720,216744,-12248), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(26, new ESSpawn(26, GraciaSeeds.DESTRUCTION, new Location(-249752,215128,-12096), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(27, new ESSpawn(27, GraciaSeeds.DESTRUCTION, new Location(-250280,216760,-12248), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(28, new ESSpawn(28, GraciaSeeds.DESTRUCTION, new Location(-250344,216152,-12248), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(29, new ESSpawn(29, GraciaSeeds.DESTRUCTION, new Location(-252504,216152,-12248), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(30, new ESSpawn(30, GraciaSeeds.DESTRUCTION, new Location(-252520,216792,-12248), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(31, new ESSpawn(31, GraciaSeeds.DESTRUCTION, new Location(-242520,217272,-12384), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(32, new ESSpawn(32, GraciaSeeds.DESTRUCTION, new Location(-241432,217288,-12384), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(33, new ESSpawn(33, GraciaSeeds.DESTRUCTION, new Location(-241432,218936,-12384), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(34, new ESSpawn(34, GraciaSeeds.DESTRUCTION, new Location(-242536,218936,-12384), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(35, new ESSpawn(35, GraciaSeeds.DESTRUCTION, new Location(-240808,217272,-12384), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(36, new ESSpawn(36, GraciaSeeds.DESTRUCTION, new Location(-240280,217272,-12384), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(37, new ESSpawn(37, GraciaSeeds.DESTRUCTION, new Location(-240280,218952,-12384), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(38, new ESSpawn(38, GraciaSeeds.DESTRUCTION, new Location(-240792,218936,-12384), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(39, new ESSpawn(39, GraciaSeeds.DESTRUCTION, new Location(-239576,217240,-12640), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(40, new ESSpawn(40, GraciaSeeds.DESTRUCTION, new Location(-239560,216168,-12640), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(41, new ESSpawn(41, GraciaSeeds.DESTRUCTION, new Location(-237896,216152,-12640), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(42, new ESSpawn(42, GraciaSeeds.DESTRUCTION, new Location(-237912,217256,-12640), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(43, new ESSpawn(43, GraciaSeeds.DESTRUCTION, new Location(-237896,215528,-12640), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(44, new ESSpawn(44, GraciaSeeds.DESTRUCTION, new Location(-239560,215528,-12640), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(45, new ESSpawn(45, GraciaSeeds.DESTRUCTION, new Location(-239560,214984,-12640), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(46, new ESSpawn(46, GraciaSeeds.DESTRUCTION, new Location(-237896,215000,-12640), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(47, new ESSpawn(47, GraciaSeeds.DESTRUCTION, new Location(-237896,213640,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(48, new ESSpawn(48, GraciaSeeds.DESTRUCTION, new Location(-239560,213640,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(49, new ESSpawn(49, GraciaSeeds.DESTRUCTION, new Location(-239544,212552,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(50, new ESSpawn(50, GraciaSeeds.DESTRUCTION, new Location(-237912,212552,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(51, new ESSpawn(51, GraciaSeeds.DESTRUCTION, new Location(-237912,211912,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(52, new ESSpawn(52, GraciaSeeds.DESTRUCTION, new Location(-237912,211400,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(53, new ESSpawn(53, GraciaSeeds.DESTRUCTION, new Location(-239560,211400,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(54, new ESSpawn(54, GraciaSeeds.DESTRUCTION, new Location(-239560,211912,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(55, new ESSpawn(55, GraciaSeeds.DESTRUCTION, new Location(-241960,214536,-12512), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(56, new ESSpawn(56, GraciaSeeds.DESTRUCTION, new Location(-241976,213448,-12512), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(57, new ESSpawn(57, GraciaSeeds.DESTRUCTION, new Location(-243624,213448,-12512), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(58, new ESSpawn(58, GraciaSeeds.DESTRUCTION, new Location(-243624,214520,-12512), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(59, new ESSpawn(59, GraciaSeeds.DESTRUCTION, new Location(-241976,212808,-12504), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(60, new ESSpawn(60, GraciaSeeds.DESTRUCTION, new Location(-241960,212280,-12504), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(61, new ESSpawn(61, GraciaSeeds.DESTRUCTION, new Location(-243624,212264,-12504), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(62, new ESSpawn(62, GraciaSeeds.DESTRUCTION, new Location(-243624,212792,-12504), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(63, new ESSpawn(63, GraciaSeeds.DESTRUCTION, new Location(-243640,210920,-12640), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(64, new ESSpawn(64, GraciaSeeds.DESTRUCTION, new Location(-243624,209832,-12640), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(65, new ESSpawn(65, GraciaSeeds.DESTRUCTION, new Location(-241976,209832,-12640), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(66, new ESSpawn(66, GraciaSeeds.DESTRUCTION, new Location(-241976,210920,-12640), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(67, new ESSpawn(67, GraciaSeeds.DESTRUCTION, new Location(-241976,209192,-12640), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(68, new ESSpawn(68, GraciaSeeds.DESTRUCTION, new Location(-241976,208664,-12640), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(69, new ESSpawn(69, GraciaSeeds.DESTRUCTION, new Location(-243624,208664,-12640), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(70, new ESSpawn(70, GraciaSeeds.DESTRUCTION, new Location(-243624,209192,-12640), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(71, new ESSpawn(71, GraciaSeeds.DESTRUCTION, new Location(-241256,208664,-12896), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(72, new ESSpawn(72, GraciaSeeds.DESTRUCTION, new Location(-240168,208648,-12896), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(73, new ESSpawn(73, GraciaSeeds.DESTRUCTION, new Location(-240168,207000,-12896), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(74, new ESSpawn(74, GraciaSeeds.DESTRUCTION, new Location(-241256,207000,-12896), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(75, new ESSpawn(75, GraciaSeeds.DESTRUCTION, new Location(-239528,208648,-12896), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(76, new ESSpawn(76, GraciaSeeds.DESTRUCTION, new Location(-238984,208664,-12896), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(77, new ESSpawn(77, GraciaSeeds.DESTRUCTION, new Location(-239000,207000,-12896), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(78, new ESSpawn(78, GraciaSeeds.DESTRUCTION, new Location(-239512,207000,-12896), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE}));\n\t\tSPAWNS.put(79, new ESSpawn(79, GraciaSeeds.DESTRUCTION, new Location(-245064,213144,-12384), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(80, new ESSpawn(80, GraciaSeeds.DESTRUCTION, new Location(-245064,212072,-12384), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(81, new ESSpawn(81, GraciaSeeds.DESTRUCTION, new Location(-246696,212072,-12384), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(82, new ESSpawn(82, GraciaSeeds.DESTRUCTION, new Location(-246696,213160,-12384), new int[]{ENERGY_SEED_WIND,ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(83, new ESSpawn(83, GraciaSeeds.DESTRUCTION, new Location(-245064,211416,-12384), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(84, new ESSpawn(84, GraciaSeeds.DESTRUCTION, new Location(-245048,210904,-12384), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(85, new ESSpawn(85, GraciaSeeds.DESTRUCTION, new Location(-246712,210888,-12384), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(86, new ESSpawn(86, GraciaSeeds.DESTRUCTION, new Location(-246712,211416,-12384), new int[]{ENERGY_SEED_DARKNESS,ENERGY_SEED_WATER}));\n\t\tSPAWNS.put(87, new ESSpawn(87, GraciaSeeds.DESTRUCTION, new Location(-245048,209544,-12512), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(88, new ESSpawn(88, GraciaSeeds.DESTRUCTION, new Location(-245064,208456,-12512), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(89, new ESSpawn(89, GraciaSeeds.DESTRUCTION, new Location(-246696,208456,-12512), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(90, new ESSpawn(90, GraciaSeeds.DESTRUCTION, new Location(-246712,209544,-12512), new int[]{ENERGY_SEED_FIRE,ENERGY_SEED_WIND,ENERGY_SEED_EARTH}));\n\t\tSPAWNS.put(91, new ESSpawn(91, GraciaSeeds.DESTRUCTION, new Location(-245048,207816,-12512), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(92, new ESSpawn(92, GraciaSeeds.DESTRUCTION, new Location(-245048,207288,-12512), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(93, new ESSpawn(93, GraciaSeeds.DESTRUCTION, new Location(-246696,207304,-12512), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(94, new ESSpawn(94, GraciaSeeds.DESTRUCTION, new Location(-246712,207816,-12512), new int[]{ENERGY_SEED_DIVINITY,ENERGY_SEED_DARKNESS}));\n\t\tSPAWNS.put(95, new ESSpawn(95, GraciaSeeds.DESTRUCTION, new Location(-244328,207272,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(96, new ESSpawn(96, GraciaSeeds.DESTRUCTION, new Location(-243256,207256,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(97, new ESSpawn(97, GraciaSeeds.DESTRUCTION, new Location(-243256,205624,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(98, new ESSpawn(98, GraciaSeeds.DESTRUCTION, new Location(-244328,205608,-12768), new int[]{ENERGY_SEED_WATER,ENERGY_SEED_FIRE,ENERGY_SEED_WIND}));\n\t\tSPAWNS.put(99, new ESSpawn(99, GraciaSeeds.DESTRUCTION, new Location(-242616,207272,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(100, new ESSpawn(100, GraciaSeeds.DESTRUCTION, new Location(-242104,207272,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(101, new ESSpawn(101, GraciaSeeds.DESTRUCTION, new Location(-242088,205624,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\tSPAWNS.put(102, new ESSpawn(102, GraciaSeeds.DESTRUCTION, new Location(-242600,205608,-12768), new int[]{ENERGY_SEED_EARTH,ENERGY_SEED_DIVINITY}));\n\t\t// Seed of Annihilation\n\t\tSPAWNS.put(103, new ESSpawn(103, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184519,183007,-10456), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(104, new ESSpawn(104, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184873,181445,-10488), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(105, new ESSpawn(105, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184009,180962,-10488), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(106, new ESSpawn(106, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-185321,181641,-10448), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(107, new ESSpawn(107, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184035,182775,-10512), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(108, new ESSpawn(108, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-185433,181935,-10424), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(109, new ESSpawn(109, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183309,183007,-10560), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(110, new ESSpawn(110, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184929,181886,-10488), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(111, new ESSpawn(111, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184009,180392,-10424), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(112, new ESSpawn(112, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183793,183239,-10488), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(113, new ESSpawn(113, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184245,180848,-10464), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(114, new ESSpawn(114, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-182704,183761,-10528), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(115, new ESSpawn(115, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184705,181886,-10504), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(116, new ESSpawn(116, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184304,181076,-10488), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(117, new ESSpawn(117, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183596,180430,-10424), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(118, new ESSpawn(118, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184422,181038,-10480), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(119, new ESSpawn(119, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184929,181543,-10496), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(120, new ESSpawn(120, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184398,182891,-10472), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(121, new ESSpawn(121, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-177606,182848,-10584), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(122, new ESSpawn(122, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178104,183224,-10560), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(123, new ESSpawn(123, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-177274,182284,-10600), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(124, new ESSpawn(124, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-177772,183224,-10560), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(125, new ESSpawn(125, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-181532,180364,-10504), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(126, new ESSpawn(126, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-181802,180276,-10496), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(127, new ESSpawn(127, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178429,180444,-10512), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(128, new ESSpawn(128, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-177606,182190,-10600), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(129, new ESSpawn(129, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-177357,181908,-10576), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(130, new ESSpawn(130, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178747,179534,-10408), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(131, new ESSpawn(131, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178429,179534,-10392), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(132, new ESSpawn(132, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178853,180094,-10472), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(133, new ESSpawn(133, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-181937,179660,-10416), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(134, new ESSpawn(134, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-180992,179572,-10416), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(135, new ESSpawn(135, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-185552,179252,-10368), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(136, new ESSpawn(136, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184572,178913,-10400), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(137, new ESSpawn(137, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184768,178348,-10312), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(138, new ESSpawn(138, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-184572,178574,-10352), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(139, new ESSpawn(139, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-185062,178913,-10384), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(140, new ESSpawn(140, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-181397,179484,-10416), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(141, new ESSpawn(141, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-181667,179044,-10408), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(142, new ESSpawn(142, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-185258,177896,-10240), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(143, new ESSpawn(143, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183506,176570,-10280), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(144, new ESSpawn(144, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183719,176804,-10240), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(145, new ESSpawn(145, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183648,177116,-10240), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(146, new ESSpawn(146, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183932,176492,-10240), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(147, new ESSpawn(147, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183861,176570,-10240), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(148, new ESSpawn(148, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-183790,175946,-10240), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(149, new ESSpawn(149, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178641,179604,-10416), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(150, new ESSpawn(150, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-178959,179814,-10432), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(151, new ESSpawn(151, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-176367,178456,-10376), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(152, new ESSpawn(152, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-175845,177172,-10264), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(153, new ESSpawn(153, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-175323,177600,-10248), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(154, new ESSpawn(154, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-174975,177172,-10216), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(155, new ESSpawn(155, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-176019,178242,-10352), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(156, new ESSpawn(156, GraciaSeeds.ANNIHILATION_BISTAKON, new Location(-174801,178456,-10264), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(157, new ESSpawn(157, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185648,183384,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(158, new ESSpawn(158, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-186740,180908,-15528), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(159, new ESSpawn(159, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185297,184658,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(160, new ESSpawn(160, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185697,181601,-15488), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(161, new ESSpawn(161, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-186684,182744,-15536), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(162, new ESSpawn(162, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184908,183384,-15616), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(163, new ESSpawn(163, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184994,185572,-15784), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(164, new ESSpawn(164, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185796,182616,-15608), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(165, new ESSpawn(165, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184970,184385,-15648), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(166, new ESSpawn(166, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185995,180809,-15512), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(167, new ESSpawn(167, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185352,182872,-15632), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(168, new ESSpawn(168, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185624,184294,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(169, new ESSpawn(169, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184486,185774,-15816), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(170, new ESSpawn(170, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-186496,184112,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(171, new ESSpawn(171, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184232,185976,-15816), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(172, new ESSpawn(172, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184994,185673,-15792), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(173, new ESSpawn(173, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185733,184203,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(174, new ESSpawn(174, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185079,184294,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(175, new ESSpawn(175, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184803,180710,-15528), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(176, new ESSpawn(176, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-186293,180413,-15528), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(177, new ESSpawn(177, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185352,182936,-15632), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(178, new ESSpawn(178, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184356,180611,-15496), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(179, new ESSpawn(179, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185375,186784,-15816), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(180, new ESSpawn(180, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184867,186784,-15816), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(181, new ESSpawn(181, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180553,180454,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(182, new ESSpawn(182, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180422,180454,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(183, new ESSpawn(183, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-181863,181138,-15120), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(184, new ESSpawn(184, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-181732,180454,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(185, new ESSpawn(185, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180684,180397,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(186, new ESSpawn(186, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-182256,180682,-15112), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(187, new ESSpawn(187, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185492,179492,-15392), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(188, new ESSpawn(188, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185894,178538,-15336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(189, new ESSpawn(189, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-186028,178856,-15336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(190, new ESSpawn(190, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185224,179068,-15336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(191, new ESSpawn(191, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185492,178538,-15336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(192, new ESSpawn(192, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185894,178538,-15336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(193, new ESSpawn(193, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180619,178855,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(194, new ESSpawn(194, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180255,177892,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(195, new ESSpawn(195, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-185804,176472,-15336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(196, new ESSpawn(196, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184580,176370,-15320), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(197, new ESSpawn(197, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184308,176166,-15320), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(198, new ESSpawn(198, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-183764,177186,-15304), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(199, new ESSpawn(199, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180801,177571,-15144), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(200, new ESSpawn(200, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184716,176064,-15320), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(201, new ESSpawn(201, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-184444,175452,-15296), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(202, new ESSpawn(202, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180164,177464,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(203, new ESSpawn(203, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-180164,178213,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(204, new ESSpawn(204, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-179982,178320,-15152), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(205, new ESSpawn(205, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-176925,177757,-15824), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(206, new ESSpawn(206, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-176164,179282,-15720), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(207, new ESSpawn(207, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175692,177613,-15800), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(208, new ESSpawn(208, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175418,178117,-15824), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(209, new ESSpawn(209, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-176103,177829,-15824), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(210, new ESSpawn(210, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175966,177325,-15792), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(211, new ESSpawn(211, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-174778,179732,-15664), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(212, new ESSpawn(212, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175692,178261,-15824), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(213, new ESSpawn(213, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-176038,179192,-15736), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(214, new ESSpawn(214, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175660,179462,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(215, new ESSpawn(215, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175912,179732,-15664), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(216, new ESSpawn(216, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175156,180182,-15680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(217, new ESSpawn(217, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-174240,182059,-15664), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(218, new ESSpawn(218, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-175590,181478,-15640), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(219, new ESSpawn(219, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-174510,181561,-15616), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(220, new ESSpawn(220, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-174240,182391,-15688), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(221, new ESSpawn(221, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-174105,182806,-15672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(222, new ESSpawn(222, GraciaSeeds.ANNIHILATION_REPTILIKON, new Location(-174645,182806,-15712), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(223, new ESSpawn(223, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-214962,182403,-10992), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(224, new ESSpawn(224, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-215019,182493,-11000), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(225, new ESSpawn(225, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-211374,180793,-11672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(226, new ESSpawn(226, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-211198,180661,-11680), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(227, new ESSpawn(227, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-213097,178936,-12720), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(228, new ESSpawn(228, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-213517,178936,-12712), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(229, new ESSpawn(229, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-214105,179191,-12720), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(230, new ESSpawn(230, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-213769,179446,-12720), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(231, new ESSpawn(231, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-214021,179344,-12720), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(232, new ESSpawn(232, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-210582,180595,-11672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(233, new ESSpawn(233, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-210934,180661,-11696), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(234, new ESSpawn(234, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207058,178460,-12656), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(235, new ESSpawn(235, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207454,179151,-11368), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(236, new ESSpawn(236, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207422,181365,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(237, new ESSpawn(237, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207358,180627,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(238, new ESSpawn(238, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207230,180996,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(239, new ESSpawn(239, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-208515,184160,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(240, new ESSpawn(240, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207613,184000,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(241, new ESSpawn(241, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-208597,183760,-11352), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(242, new ESSpawn(242, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206710,176142,-12656), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(243, new ESSpawn(243, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206361,178136,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(244, new ESSpawn(244, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206178,178630,-12672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(245, new ESSpawn(245, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-205738,178715,-12656), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(246, new ESSpawn(246, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206442,178205,-12648), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(247, new ESSpawn(247, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206585,178874,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(248, new ESSpawn(248, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206073,179366,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(249, new ESSpawn(249, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206009,178628,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(250, new ESSpawn(250, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206155,181301,-12656), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(251, new ESSpawn(251, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206595,181641,-12656), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(252, new ESSpawn(252, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206507,181641,-12656), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(253, new ESSpawn(253, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206507,181471,-12640), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(254, new ESSpawn(254, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206974,175972,-12672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(255, new ESSpawn(255, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206304,175130,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(256, new ESSpawn(256, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206886,175802,-12672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(257, new ESSpawn(257, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207238,175972,-12672), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(258, new ESSpawn(258, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206386,174857,-11328), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(259, new ESSpawn(259, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-206386,175039,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(260, new ESSpawn(260, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-205976,174584,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(261, new ESSpawn(261, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-207367,184320,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(262, new ESSpawn(262, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219002,180419,-12608), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(263, new ESSpawn(263, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218853,182790,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(264, new ESSpawn(264, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218853,183343,-12600), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(265, new ESSpawn(265, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218358,186247,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(266, new ESSpawn(266, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218358,186083,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(267, new ESSpawn(267, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-217574,185796,-11352), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(268, new ESSpawn(268, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219178,181051,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(269, new ESSpawn(269, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-220171,180313,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(270, new ESSpawn(270, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219293,183738,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(271, new ESSpawn(271, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219381,182553,-12584), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(272, new ESSpawn(272, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219600,183024,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(273, new ESSpawn(273, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219940,182680,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(274, new ESSpawn(274, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219260,183884,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(275, new ESSpawn(275, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219855,183540,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(276, new ESSpawn(276, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218946,186575,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(277, new ESSpawn(277, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219882,180103,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(278, new ESSpawn(278, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219266,179787,-12584), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(279, new ESSpawn(279, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219201,178337,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(280, new ESSpawn(280, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219716,179875,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(281, new ESSpawn(281, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219716,180021,-11328), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(282, new ESSpawn(282, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219989,179437,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(283, new ESSpawn(283, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219078,178298,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(284, new ESSpawn(284, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218684,178954,-11328), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(285, new ESSpawn(285, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219089,178456,-11328), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(286, new ESSpawn(286, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-220266,177623,-12608), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(287, new ESSpawn(287, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219201,178025,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(288, new ESSpawn(288, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219142,177044,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(289, new ESSpawn(289, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219690,177895,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(290, new ESSpawn(290, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219754,177623,-12584), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(291, new ESSpawn(291, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218791,177830,-12584), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(292, new ESSpawn(292, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218904,176219,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(293, new ESSpawn(293, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218768,176384,-12584), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(294, new ESSpawn(294, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218774,177626,-11320), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(295, new ESSpawn(295, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218774,177792,-11328), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(296, new ESSpawn(296, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219880,175901,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(297, new ESSpawn(297, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219210,176054,-12592), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(298, new ESSpawn(298, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219850,175991,-12608), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(299, new ESSpawn(299, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-219079,175021,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(300, new ESSpawn(300, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218812,174229,-11344), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\tSPAWNS.put(301, new ESSpawn(301, GraciaSeeds.ANNIHILATION_COKRAKON, new Location(-218723,174669,-11336), new int[]{ ENERGY_SEED_WATER, ENERGY_SEED_FIRE, ENERGY_SEED_WIND, ENERGY_SEED_EARTH, ENERGY_SEED_DIVINITY, ENERGY_SEED_DARKNESS }));\n\t\t//@formatter:on\n\t}", "public List<Embarcation> getAllDisponible(){\n\t\tSQLiteDatabase mDb = open();\n\t\tCursor cursor = mDb.rawQuery(\"SELECT * FROM \" + TABLE_NAME +\" WHERE \"+DISPONIBLE+\" = 1\", null);\n\t\t\n\t\tList<Embarcation> resultList = cursorToEmbarcationList(cursor);\n\t\t\n\t\tmDb.close();\n\t\t\n\t\treturn resultList;\n\t}", "java.util.List<com.rpg.framework.database.Protocol.Item> \n getItemsList();", "public static ArrayList<ScannedItem> getScannedItems() {\n\n String baseUrl = REST_BASE_URL + INCOMING_TAGS;\n ArrayList<ScannedItem> scannedItems = new ArrayList<>();\n\n URL url = null;\n\n try {\n url = new URL(baseUrl);\n } catch (MalformedURLException e) {\n e.printStackTrace();\n }\n\n JSONArray jaResult = null;\n try {\n jaResult = getResponseFromHttpUrl(url);\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n try {\n for (int i = 0; i < jaResult.length(); i++) {\n JSONObject jo = (JSONObject) jaResult.get(i);\n ScannedItem newItem = new ScannedItem(jo.getString(RFID_TAG));\n scannedItems.add(newItem);\n }\n } catch (JSONException e) {\n e.printStackTrace();\n }\n\n return scannedItems;\n }", "public ArrayList<Instance> getTestInstances() {\n ArrayList<Instance> testing = new ArrayList<>();\n testing.addAll(instances.subList(targetsize, instances.size()));\n return testing;\n }", "public ArrayList<ObjectInMap> getVisibleObjects() {\n //To ensure Obstacles will be drawn at last\n objectsInMap.sort((o1, o2) -> {\n if (o1 instanceof Bush)\n return 1;\n else if (o2 instanceof Bush)\n return -1;\n else if (o1 instanceof Obstacle)\n return -1;\n else if (o2 instanceof Obstacle)\n return 1;\n else\n return 0;\n });\n\n Polygon visible = new Polygon(new int[]{viewPoint.x, ((int) (viewPoint.x + zoom * GAME_WIDTH)), ((int) (viewPoint.x + zoom * GAME_WIDTH)), viewPoint.x}\n , new int[]{viewPoint.y, viewPoint.y, ((int) (viewPoint.y + zoom * GAME_HEIGHT)), ((int) (viewPoint.y + zoom * GAME_HEIGHT))}, 4);\n\n return objectsInMap.stream().filter(o -> o.intersects(visible)).collect(Collectors.toCollection(ArrayList::new));\n }", "public ArrayList<PoolMap> get_P_maps(){\n\n\t\treturn poolMaps;\n\t}", "List<IManifestEntry> getTrips();", "public List<ImageResourceWrapper> getMap() {\n // Declare a new list to hold the rendering info for the physics objects.\n List<ImageResourceWrapper> rtrnResources = new ArrayList<>();\n for(PhysicsEntity physicsEntity : this.physModel.getEntities()) {\n // Get the graphics entity corresponding to the current physics entity.\n GraphicsEntity graphicsEntity = this.graphModel.getEntityByID(physicsEntity.getId());\n String imgResource = graphicsEntity.getImgResId(physicsEntity.getOrientation());\n rtrnResources.add(new ImageResourceWrapper(new Point(physicsEntity.getPosition().x, physicsEntity.getPosition().y), imgResource));\n }\n for(Objective objective : this.gameStateModel.getObjectives()) {\n GraphicsEntity graphicsEntity = this.graphModel.getEntityByID(objective.getId());\n // TODO: Orientation for objectives\n String imgResource = graphicsEntity.getImgResId(0);\n rtrnResources.add(new ImageResourceWrapper(new Point(objective.getPosition().x, objective.getPosition().y), imgResource));\n }\n return rtrnResources;\n }", "public List<CardSprite> getDiscardPile() {\n return this.discardPile;\n }" ]
[ "0.5292667", "0.5125101", "0.49352247", "0.48597428", "0.47924435", "0.47485077", "0.47098747", "0.47015968", "0.46942502", "0.4674625", "0.46691558", "0.4646681", "0.46427965", "0.4601528", "0.45721665", "0.45614836", "0.4556481", "0.45556808", "0.45517057", "0.45480728", "0.45396313", "0.45223013", "0.45149878", "0.45131", "0.4511438", "0.4508676", "0.45035976", "0.44714275", "0.44713044", "0.44533396", "0.4421935", "0.44097608", "0.4405149", "0.4398453", "0.43755874", "0.43730837", "0.4368792", "0.4346169", "0.43388957", "0.4332853", "0.43323067", "0.43269828", "0.43264875", "0.43076763", "0.4300556", "0.42976722", "0.42967513", "0.42960078", "0.4294553", "0.42931667", "0.42913073", "0.4290867", "0.42837453", "0.42791215", "0.42757356", "0.42737228", "0.42699388", "0.42661098", "0.42614433", "0.4255706", "0.42460307", "0.4243829", "0.42429394", "0.42421636", "0.42410243", "0.4240698", "0.42393327", "0.42321303", "0.42264363", "0.42259678", "0.4224642", "0.4220048", "0.42135608", "0.4210426", "0.421003", "0.42095444", "0.42067263", "0.42058572", "0.4205295", "0.42021227", "0.42010638", "0.4198993", "0.41968727", "0.41907775", "0.41898733", "0.418961", "0.41820818", "0.41784018", "0.41764718", "0.41762486", "0.41762054", "0.41728252", "0.41711494", "0.41681233", "0.4167886", "0.41676053", "0.41659498", "0.41648582", "0.4164803", "0.41624144", "0.4161587" ]
0.0
-1
Return table containing all L2ItemInstance that can be harvested.
public synchronized RewardItem[] takeHarvest() { final RewardItem[] harvest = harvestItems; harvestItems = null; return harvest; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public List<Item> getAllItemsAvailable();", "public HashMap<String, List<OwnedWarp>> getTable() {\n return warps;\n }", "@Override\r\n\tpublic List<Item> getAllHomework() {\n\t\t\r\n\t\treturn itemdao.find(\"from Item\");\r\n\t}", "@Override\n\tpublic List<Equipment> getAllAviableEquipmet() {\n\t\treturn dao.getAllAviableEquipmet();\n\t}", "@Override\n public List<Workload> getAll() throws InstanceNotFoundException {\n List<Workload> list = new ArrayList<>();\n workloadRepository.findAll().forEach(list::add);\n if (list.isEmpty()) {\n throw new InstanceNotFoundException(\"Here is no Workloads\");\n }\n return list;\n }", "@Override\n\tpublic List<AvailableSlot> getAvailableSlots() {\n\t\tList<AvailableSlot> slots = (List<AvailableSlot>) availableSlotRepository.findAll();\n\t\treturn slots;\n\t}", "@Transactional(readOnly = true)\n public Page<ItemInstance> findAll(Pageable pageable) {\n log.debug(\"Request to get all ItemInstances\");\n return itemInstanceRepository.findAll(pageable);\n }", "public InstanceDescription[] getContainedInstances() {\n return m_containedInstances;\n }", "public ArrayList<Instance> getTestInstances() {\n ArrayList<Instance> testing = new ArrayList<>();\n testing.addAll(instances.subList(targetsize, instances.size()));\n return testing;\n }", "private Collection getInstances() {\n \t\tCollection instances=null;\r\n\r\n //instances = cls.getInstances();\r\n \t\tRDFProperty ready = owlModel.getRDFProperty(oTab.namespacePrefix + \":\" + oTab.pReady);\r\n\r\n \t\tif ( ready != null )\r\n \t\t{\r\n \t\t\tinstances = owlModel.getRDFResourcesWithPropertyValue(ready, true);\r\n \t\t}\r\n \t\telse\r\n \t\t{\r\n \t\t\tSystem.out.println(\"*** Could not lookup property defintion for \" + oTab.namespacePrefix + \":\" + oTab.pReady + \" Ontology not imported\");\r\n \t\t}\r\n\r\n return instances;\r\n }", "Collection<Instance> getInstances();", "List<PhysicalTable> getPhysicalTables();", "@Override\r\n\tpublic List<HouseType> queryAllHtype() {\n\t\treturn adi.queryAllHtype();\r\n\t}", "public List<InventoryEntry> getInventoryEntries();", "ArrayList<Ability> getAbilities() throws RemoteException;", "@SuppressWarnings(\"unchecked\")\n private void createTable() {\n table = (LinkedList<Item<V>>[])new LinkedList[capacity];\n for(int i = 0; i < table.length; i++) {\n table[i] = new LinkedList<>();\n }\n }", "@Override\n public List<SideDishEntity> findAll() {\n return null;\n }", "List<SimpleInventory> getInventories();", "public List<equipment> getAllEquipments (){\n return equiomentResprositery.findAll();\n }", "public List<Equipment> findAllEquipment() {\n Iterable<Equipment> itEquipment = equipmentRepository.findAll();\n List<Equipment> equipment = new ArrayList<>();\n\n itEquipment.forEach(equipment::add);\n\n return equipment;\n }", "public List<HealthInspectorsInfo> availableInspectors() {\n return INSPECTORS.stream().map(HealthInspectorsInfo::new).collect(Collectors.toList());\n }", "@GetMapping(\"/households\")\n public ResultEntity<List<ItemDTO>> getAllHousehold()\n {\n\n return itemService.getItemsBySubCategory(ConstantUtil.TYPE_SALE_RENT,\"Household\");\n }", "public List<Park> getAllAvailableParks();", "@GetMapping(\"/equipment\")\n\tpublic List<Equipment> findAll() {\n\t\treturn inventoryService.findAll();\n\t}", "List<SrInwardTruckQualityCheck> getAll();", "@Test\n void getSlots(){\n Shelf shelf=new Shelf(3);\n\n shelf.addResources(Resource.SHIELD);\n shelf.addResources(Resource.SHIELD);\n\n assertEquals(Resource.SHIELD,shelf.getResources().get(0));\n assertEquals(Resource.SHIELD,shelf.getResources().get(1));\n\n }", "private static Inventory[] createInventoryList() {\n Inventory[] inventory = new Inventory[3];\r\n \r\n Inventory potion = new Inventory();\r\n potion.setDescription(\"potion\");\r\n potion.setQuantityInStock(0);\r\n inventory[Item.potion.ordinal()] = potion;\r\n \r\n Inventory powerup = new Inventory();\r\n powerup.setDescription(\"powerup\");\r\n powerup.setQuantityInStock(0);\r\n inventory[Item.powerup.ordinal()] = powerup;\r\n \r\n Inventory journalclue = new Inventory();\r\n journalclue.setDescription(\"journalclue\");\r\n journalclue.setQuantityInStock(0);\r\n inventory[Item.journalclue.ordinal()] = journalclue;\r\n \r\n return inventory;\r\n }", "@Override\r\n public List<HarvestResponseDto> getAllHarvests(){\r\n return harvestRepository.findAll()\r\n .stream()\r\n .map(harvestMapper::mapToDto)\r\n .collect(Collectors.toList());\r\n }", "public List<Establishment> establishmentCanTrade() {\n List<Establishment> can_take = new ArrayList<> ();\n for(int i = 0; i < Establishments.size(); i++) {\n Establishment check = Establishments.get(i);\n if(check.getName().equals(\"Wheat Field\") || check.getName().equals(\"Bakery\")) {\n if (check.getAvailable() > 1) {\n can_take.add(check);\n }\n } else if(!check.getColor().equals(Card.Color.PURPLE)) {\n can_take.add(check);\n }\n }\n return can_take;\n }", "@VTID(30)\n boolean getShowAllItems();", "public List<Hard> getAllHardQuestion()\n\t\t{\n\t\t\tList<Hard> Hard=(List<Hard>)this.hardRepository.findAll();\t\t\n\t\t\treturn Hard;\n\t\t}", "public List<ServiceInstance> getAllInstances();", "@GetMapping(\"/table/checkAvailabilityList\")\n\tpublic List<TableRestaurant> getAvailabilityList()\n\t{\n\t\tList<TableRestaurant> availableTime = tableRepo.checkTableAvailabilityList();\n\t\tif(availableTime.equals(null))\n\t\t{\n\t\t\tthrow new UniquoNotFoundException(\"The waiting time cannot be calculated\");\n\t\t}\n\t\treturn availableTime;\n\t}", "@Override\n\tpublic List<PermitType> GetAllPermitTypes() {\n\t\tConnection connection = null;\n\t\tPreparedStatement preparedStatement = null;\n\t\tResultSet resultSet = null;\n\t\tint count=1;\n\t\ttry {\n\t\t\tconnection = dataSource.getConnection();\n\t\t\tpreparedStatement = connection\n\t\t\t\t\t.prepareStatement(Queryconstants.getPermitTypes);\n\t\t\tresultSet = preparedStatement.executeQuery();\n\t\t\tList<PermitType> permittypes = new ArrayList<PermitType>();\n\t\t\twhile (resultSet.next()) {\n\t\t\t\tPermitType permitType=new PermitType();\n\n\t\t\t\tpermitType.permitTypeId=resultSet.getInt(\"ID\");\n\t\t\t\tpermitType.permitTypeCode=resultSet.getString(\"permit_type_Code\");\n\t\t\t\tpermitType.permitTypeName=resultSet.getString(\"permit_type_Name\");\n\t\t\t\tpermitType.permitType=resultSet.getString(\"permit_type_code\");\n\t\t\t\tpermitType.permitFee=resultSet.getDouble(\"permit_fee\");\n\t\t\t\tpermitType.active=resultSet.getBoolean(\"active\");\n\t\t\t\tpermitType.respCode=200;\n\t\t\t\tpermitType.count=count;\n\t\t\t\tpermittypes.add(permitType);\n\t\t\t\tcount++;\n\t\t\t}\n\t\t\treturn permittypes;\n\t\t} catch (Exception ex) {\n\t\t\tex.printStackTrace();\n\t\t\treturn null;\n\t\t} finally {\n\t\t\tDBOperations.DisposeSql(connection, preparedStatement, resultSet);\n\t\t}\n\t}", "public List<Resource> getAvailableResources();", "public HashMap<String, List<String>> getItemMap() {\r\n\r\n\t\thelmet_abilities.add(Game_constants.INTELLIGENCE);\r\n\t\thelmet_abilities.add(Game_constants.WISDOM);\r\n\t\thelmet_abilities.add(Game_constants.ARMOR_CLASS);\r\n\r\n\t\tarmor_abilities.add(Game_constants.ARMOR_CLASS);\r\n\r\n\t\tshield_abilities.add(Game_constants.ARMOR_CLASS);\r\n\r\n\t\tring_abilities.add(Game_constants.ARMOR_CLASS);\r\n\t\tring_abilities.add(Game_constants.STRENGTH);\r\n\t\tring_abilities.add(Game_constants.CONSTITUTION);\r\n\t\tring_abilities.add(Game_constants.WISDOM);\r\n\t\tring_abilities.add(Game_constants.CHARISMA);\r\n\r\n\t\tbelt_abilities.add(Game_constants.CONSTITUTION);\r\n\t\tbelt_abilities.add(Game_constants.STRENGTH);\r\n\r\n\t\tboots_abilities.add(Game_constants.ARMOR_CLASS);\r\n\t\tboots_abilities.add(Game_constants.DEXTERITY);\r\n\r\n\t\tweapon_abilities.add(Game_constants.ATTACK_BONUS);\r\n\t\tweapon_abilities.add(Game_constants.DAMAGE_BONUS);\r\n\r\n\t\titem_map.put(Game_constants.HELMET, helmet_abilities);\r\n\t\titem_map.put(Game_constants.ARMOR, armor_abilities);\r\n\t\titem_map.put(Game_constants.SHIELD, shield_abilities);\r\n\t\titem_map.put(Game_constants.RING, ring_abilities);\r\n\t\titem_map.put(Game_constants.BELT, belt_abilities);\r\n\t\titem_map.put(Game_constants.BOOTS, boots_abilities);\r\n\t\titem_map.put(Game_constants.WEAPON_MELEE, weapon_abilities);\r\n\t\titem_map.put(Game_constants.WEAPON_RANGE, weapon_abilities);\r\n\r\n\t\treturn item_map;\r\n\r\n\t}", "public PerishableItem(){\n super();\n //perishable = false;\n }", "public boolean isInterestedInAllItems();", "@Override\r\n\tpublic List<HouseState> queryAllHState() {\n\t\treturn adi.queryAllHState();\r\n\t}", "@Override\n\tpublic List<Parking> employeeavailableParking() {\n\t\treturn parkingRepository.employeeavailableParking();\n\t}", "public java.util.List<suiluppo_equip_allocation> findAll();", "@Override\n\tpublic List<Parking> availableParking() {\n\t\treturn parkingRepository.availableParking();\n\t}", "public List<LeagueTableEntry> getTableEntries() {\n\t\treturn entries;\n\t}", "List<StandardsEntity> STANDARDS_ENTITY_LIST() throws Exception;", "@Override\r\n\tpublic List<CandidateSteps> candidateSteps() {\n\t\treturn new InstanceStepsFactory(configuration(), new AmxBpmSteps()).createCandidateSteps();\r\n\t}", "public List<Treasure> giveInventory() {\r\n return treasures;\r\n }", "public static SortBuilder[] allInstances() {\n \t\treturn (SortBuilder[]) allInstances.toArray(new SortBuilder[allInstances.size()]);\n \t}", "@Shadow public abstract Iterable<ItemStack> getArmorSlots();", "public List<IWeapon> getWeaponsInventory(){\n return weaponsInventory;\n }", "public Collection<Long> getAvailableItems();", "@Override\n\tpublic List<Equipment> getAllEquipmet() {\n\t\treturn dao.getAllEquipmet();\n\t}", "@Override\n\tpublic List<Parking> VIPparkings() {\n\t\treturn parkingRepository.VIPparkings();\n\t}", "@SuppressWarnings(\"unchecked\") \n public List<Item> getItemsVLH(String pID, int start, int chunkSize){\n EntityManager em = emf.createEntityManager();\n \n //make Java Persistence query\n //Query query = em.createNamedQuery(\"Item.getItemsPerProductCategory\");\n Query query = em.createQuery(\"SELECT i FROM Item i WHERE i.productID = :pID AND i.disabled = 0\");\n List<Item> items = query.setParameter(\"pID\",pID).setFirstResult(start).setMaxResults(chunkSize).getResultList();\n em.close();\n return items;\n }", "@Override\r\n\tpublic List<Areas> queryAllHArea() {\n\t\treturn adi.queryAllHArea();\r\n\t}", "public List<ServiceInstance> getAllInstancesByKey(ServiceInstanceQuery query);", "@Override\n\tpublic List<Inventory> getAllInventories() {\n\t\tArrayList<Inventory> inventories = new ArrayList<Inventory>();\n\t\tinventoryDao.findAll().forEach(inventories::add);\n\t\treturn inventories;\n\t}", "List<EquipmentCategory> getAllEquipment() throws PersistenceException;", "@Override\n\tpublic List<InventoryManagement> findAll() {\n\t\treturn inventoryManagementDao.findAll();\n\t}", "List<InventoryItem> getInventory();", "@SuppressWarnings(\"unchecked\")\n public List<Item> getActiveTasks() {\n Session session = this.factory.openSession();\n List<Item> list = session.createQuery(\"from Item where status = 0\").list();\n session.close();\n return list;\n }", "private Map<LinkKey, Set<TributarySlot>> findAvailableTributarySlots(OpticalOduIntent intent, Path path) {\n Set<LinkKey> linkRequest = Sets.newHashSetWithExpectedSize(path.links().size());\n for (int i = 0; i < path.links().size(); i++) {\n LinkKey link = linkKey(path.links().get(i));\n linkRequest.add(link);\n }\n\n return findTributarySlots(intent, linkRequest);\n }", "List<BasicEquipment> selectAll();", "@Override\n public List<Bitstream> getNonInternalBitstreams(Item item) throws SQLException\n {\n List<Bitstream> bitstreamList = new ArrayList<Bitstream>();\n\n // Go through the bundles and bitstreams picking out ones which aren't\n // of internal formats\n List<Bundle> bunds = item.getBundles();\n\n for (Bundle bund : bunds) {\n List<BundleBitstream> bitstreams = bund.getBitstreams();\n\n for (BundleBitstream bundleBitstream : bitstreams) {\n Bitstream bitstream = bundleBitstream.getBitstream();\n if (!bitstream.getFormat().isInternal()) {\n // Bitstream is not of an internal format\n bitstreamList.add(bitstream);\n }\n }\n }\n\n return bitstreamList;\n }", "public List<Park> getParkRegistry() {\n return this.pf.getParkList();\n }", "@Override\n\tpublic List<Parking> vIPOutParking() {\n\t\treturn parkingRepository.vIPOutParking();\n\t}", "@Override\r\n\tpublic List<Units> queryAllHx() {\n\t\treturn adi.queryAllHx();\r\n\t}", "public Item[] getItems() {\n/* 3068 */ if (this.vitems != null) {\n/* 3069 */ return this.vitems.getAllItemsAsArray();\n/* */ }\n/* 3071 */ return emptyItems;\n/* */ }", "public static ArrayList<InstanceEntity> getInstances() {\n ILifeCycleServiceRest resourceserviceproxy =\n ConsumerFactory.createConsumer(MsbUtil.getNsocLifecycleBaseUrl(),\n ILifeCycleServiceRest.class);\n String result = \"\";\n try {\n result = resourceserviceproxy.getVnfInstances();\n } catch (Exception e1) {\n LOG.error(\"query vim info faild.\", e1);\n return null;\n }\n if (ToolUtil.isEmptyString(result)) {\n return null;\n }\n\n Gson gson = new Gson();\n Type listType = new TypeToken<ArrayList<InstanceEntity>>() {}.getType();\n return gson.fromJson(result, listType);\n }", "@SideOnly(Side.CLIENT)\n/* 34: */ public void getSubItems(Item itemId, CreativeTabs table, List list)\n/* 35: */ {\n/* 36:35 */ for (int i = 0; i < 13; i++)\n/* 37: */ {\n/* 38:36 */ ItemStack is = new ItemStack(itemId);\n/* 39:37 */ is.stackTagCompound = new NBTTagCompound();\n/* 40:38 */ is.stackTagCompound.setShort(\"Shield\", (short)i);\n/* 41:39 */ list.add(is);\n/* 42: */ }\n/* 43: */ }", "HashMap getDetailedSuspensionList(HashMap hshParameters)\n throws SQLException, RemoteException, Exception;", "public java.util.Enumeration getSitedoc2Splaces() throws java.rmi.RemoteException, javax.ejb.FinderException, javax.naming.NamingException {\n\n instantiateEJB();\n return ejbRef().getSitedoc2Splaces();\n }", "public List<IBS2101105RsResult> getHouseList() {\n return houseList;\n }", "private List<String> asExpiredItemsReportTableRow(Item item) {\n\t\treturn Arrays.asList(item.getProduct().getDescription(), item.getStorageUnitName(),\n\t\t\t\titem.getProductGroupName(), report.formatForReport(item.getEntryDate()),\n\t\t\t\treport.formatForReport(item.getExpirationDate()), item.getBarcode());\n\t}", "public java.util.List<wsihash> findAll();", "@Override\r\n\tpublic ItemInstance createItemInstance() {\n\t\treturn new HpInstance();\r\n\t}", "public List<KanjiDbFlow> shallowLoad(){\n return new ArrayList<>();\n }", "@Override\n public ItemStack[] getContents() {\n final ItemStack[] items = new ItemStack[36];\n\n items[0] = this.getSword();\n\n for(int i = 0; i < this.getAbilities().length; i++) {\n final Ability ability = this.getAbilities()[i];\n\n if (ability instanceof ItemAbility) {\n items[i+1] = new ItemStack(((ItemAbility) ability).getMaterial());\n }\n }\n\n for (int i = 0; i < items.length; i++) {\n if (items[i] == null) {\n items[i] = this.getHealthType();\n }\n }\n\n return items;\n }", "@Override\n\tpublic List<Item> findItemList() {\n\t\tCriteriaBuilder cb=entityManager.getCriteriaBuilder();\n\t\tCriteriaQuery<Item> query = cb.createQuery(Item.class); \n // Root<Item> item = query.from(Item.class);\n List<Item> itemList= entityManager.createQuery(query).getResultList();\n\t\treturn itemList;\n\t}", "ArrayList<Habit> getHabits();", "@Test\r\n public void getEventTicketInstanceList() {\r\n System.out.println(\"getEventTicketInstanceList begin.\");\r\n\r\n // Model ID of event ticket instances you want to get.\r\n String modelId = \"eventTicketModelTest\";\r\n\r\n // Get a list of the event ticket instances.\r\n String urlSegment = \"eventticket/instance\";\r\n List<HwWalletObject> responseInstances = walletBuildService.getInstances(urlSegment, modelId, 5);\r\n System.out.println(\"Event ticket instances list: \" + CommonUtil.toJson(responseInstances));\r\n }", "public java.util.List<de.fraunhofer.fokus.movepla.model.Entitlement> findAll()\n throws com.liferay.portal.kernel.exception.SystemException;", "public List<Hotel> getAvailableHotels(){\n return databaseManager.findAvailableHotels();\n }", "public List<FreeColGameObject> disposeList() {\n List<FreeColGameObject> objects = new ArrayList<FreeColGameObject>();\n if (owner != null\n && getTile() != null\n && getTile().getSettlement() != null) {\n // Defensive tests to handle transition from calling dispose()\n // on both sides to when it is only called on server-side.\n \n // Get off the map\n Tile settlementTile = getTile();\n List<Tile> lostTiles = getOwnedTiles();\n for (Tile tile : lostTiles) {\n tile.changeOwnership(null, null);\n }\n settlementTile.setSettlement(null);\n \n // The owner forgets about the settlement.\n Player oldOwner = owner;\n oldOwner.removeSettlement(this);\n oldOwner.invalidateCanSeeTiles();\n // It is not safe to setOwner(null). When a settlement is\n // destroyed there is a race between this code and some\n // display routines that still need to know who owned the\n // dead settlement.\n }\n \n objects.addAll(super.disposeList());\n return objects;\n }", "public Collection<TapTable> findAllTables();", "public IPresentablePart[] getPartList() {\r\n\t\treturn tabs.getPartList();\r\n\t}", "public static boolean testPokemonTableGetAll() throws IOException {\r\n PokemonTable inst = new PokemonTable(10);\r\n for (Pokemon item : testList) {\r\n inst.put(item.getName(), item);\r\n }\r\n LinkedList<Pokemon> list = inst.getAll();\r\n if (list.size() != 6)\r\n return false;\r\n for (Pokemon item : testList) {\r\n if (!list.contains(item)) {\r\n return false;\r\n }\r\n }\r\n return true;\r\n }", "@Test(expected = org.apache.axis.AxisFault.class)\n\tpublic void testListInstances_3()\n\t\tthrows Exception {\n\t\tSAPHostControl_BindingStub fixture = new SAPHostControl_BindingStub(new URL(\"\"), new DeployWSServiceLocator());\n\t\tInstanceSelector aSelector = new InstanceSelector();\n\n\t\tSAPInstance[] result = fixture.listInstances(aSelector);\n\n\t\t// add additional test code here\n\t\tassertNotNull(result);\n\t}", "public List<Brand> findActives( )\n {\n List<Brand> result;\n\n //region Instrumentation\n _logger.debug( \"Entrando a BrandDAO.findActives\");\n //endregion\n\n try\n {\n CriteriaQuery<Brand> query = _builder.createQuery( Brand.class );\n Root<Brand> root = query.from( Brand.class );\n\n query.select( root );\n query.where( _builder.equal( root.get( \"_status\" ), MasterStatus.ACTIVE ) );\n\n result = _em.createQuery( query ).getResultList();\n }\n catch ( Exception e )\n {\n throw new FindAllException( e, e.getMessage() );\n }\n\n //region Instrumentation\n _logger.debug( \"Saliendo de BrandDAO.findActives result {}\", result );\n //endregion\n\n return result;\n }", "@Override\n public List getAllSharingProduct() {\n \n List sharingProducts = new ArrayList();\n SharingProduct sharingProduct = null;\n Connection connection = null;\n PreparedStatement preparedStatement = null;\n ResultSet result = null;\n try {\n connection = MySQLDAOFactory.createConnection();\n preparedStatement = connection.prepareStatement(Read_All_Query);\n preparedStatement.execute();\n result = preparedStatement.getResultSet();\n \n while (result.next()) {\n sharingProduct = new SharingProduct(result.getString(1), result.getInt(2) );\n sharingProducts.add(sharingProduct);\n }\n } catch (SQLException e) {\n e.printStackTrace();\n } finally {\n try {\n result.close();\n } catch (Exception rse) {\n rse.printStackTrace();\n }\n try {\n preparedStatement.close();\n } catch (Exception sse) {\n sse.printStackTrace();\n }\n try {\n connection.close();\n } catch (Exception cse) {\n cse.printStackTrace();\n }\n }\n \n return sharingProducts;\n }", "public List<ServiceInstance> queryInstancesByKey(ServiceInstanceQuery query);", "List<IManifestEntry> getTrips();", "@Test\n\tpublic void testListInstances_1()\n\t\tthrows Exception {\n\t\tSAPHostControl_BindingStub fixture = new SAPHostControl_BindingStub(new URL(\"\"), new DeployWSServiceLocator());\n\t\tInstanceSelector aSelector = new InstanceSelector();\n\n\t\tSAPInstance[] result = fixture.listInstances(aSelector);\n\n\t\t// add additional test code here\n\t\tassertNotNull(result);\n\t}", "public List<Pair<String, HLOInformation>> getHLOInformation() {\n if (! wasSuccessful()) {\n return List.of();\n }\n if (getArchitect() == null) {\n return List.of();\n }\n Result<GameLogsRecord> result = jooq.selectFrom(GAME_LOGS)\n .where(GAME_LOGS.GAMEID.equal(gameId))\n .orderBy(GAME_LOGS.ID.asc())\n .fetch();\n\n List<HLOGatherer> hloPlans;\n HashMultiset<Block> presentBlocks = HashMultiset.create();\n String scenario = getScenario();\n if (scenario.equals(\"house\")) {\n hloPlans = readHighlevelPlan(\"/de/saar/minecraft/domains/house-highlevel.plan\")\n .stream()\n .map(HLOGatherer::new)\n .collect(Collectors.toList());\n presentBlocks.addAll(readInitialWorld(\"/de/saar/minecraft/worlds/house.csv\"));\n } else if (scenario.equals(\"bridge\")) {\n hloPlans = readBlockPlan(\"/de/saar/minecraft/domains/bridge-block.plan\").stream()\n .map(HLOGatherer::new)\n .collect(Collectors.toList());\n presentBlocks.addAll(readInitialWorld(\"/de/saar/minecraft/worlds/bridge.csv\"));\n } else {\n throw new NotImplementedException(\"Scenario {} is not implemented\", scenario);\n }\n\n LocalDateTime firstInstructionTime = null;\n int numMistakes = 0;\n\n /* These two booleans implement a work-around for https://github.com/minecraft-saar/infrastructure/issues/19\n Sometimes, a delete message and a create message are in the wrong order. This workaround is for a specific\n game where the player did a put-delete-put sequence for one location. The result should be that there is a\n block, but for some reason the sequence ended up as put-put-delete, meaning the world as we capture it here\n does not have the block even though it was there during the game. If that happens, we disable tracking\n of deletions in that one game.\n */\n boolean dataExtracted = false;\n boolean ignoreDestroyMessages = false;\n while (! dataExtracted) {\n // go through the complete game and keep track of when instructions where given,\n // blocks placed an HLO completed.\n for (GameLogsRecord record : result) {\n switch (record.getMessageType()) {\n case \"BlockPlacedMessage\":\n presentBlocks.add(getBlockFromRecord(record));\n break;\n case \"BlockDestroyedMessage\":\n if (! ignoreDestroyMessages) {\n presentBlocks.remove(getBlockFromRecord(record));\n }\n break;\n case \"TextMessage\":\n if (firstInstructionTime == null) {\n // the first *instruction* has a derivation tree, otherwise it is\n // a welcome message or similar.\n if (record.getMessage().contains(\"\\\\\\\"tree\\\\\\\":\")) {\n firstInstructionTime = record.getTimestamp();\n }\n }\n if (record.getMessage().contains(\"Not there! please remove that block again\")\n || record.getMessage().contains(\"Please add this block again.\"))\n numMistakes += 1;\n break;\n case \"SuccessfullyFinished\": // the game is complete, i.e. the last HLO was completed.\n if (hloPlans.get(hloPlans.size() - 1).timestamp == null) {\n hloPlans.get(hloPlans.size() - 1).timestamp = record.getTimestamp();\n hloPlans.get(hloPlans.size() - 1).mistakes = numMistakes;\n }\n break;\n default:\n break;\n }\n // Check which HLOs are complete\n for (HLOGatherer hlo : hloPlans) {\n if (hlo.timestamp == null) {\n if (presentBlocks.containsAll(hlo.blocks)) {\n hlo.timestamp = record.getTimestamp();\n hlo.mistakes = numMistakes;\n }\n }\n }\n }\n // we are done when we either already had our second try or the data looks good.\n if (ignoreDestroyMessages || hloPlans.stream().noneMatch((x) -> x.timestamp == null)) {\n dataExtracted = true;\n } else {\n ignoreDestroyMessages = true;\n }\n }\n // As this was a successful game, all HLOs should have a time\n assert (hloPlans.stream().noneMatch((x) -> x.timestamp == null));\n\n if (firstInstructionTime == null) {\n logger.error(\"first instruction is null\");\n return List.of();\n }\n if (getScenario().equals(\"bridge\")) {\n return List.of(\n new Pair<>(\"floor\",\n new HLOInformation(\n (int)firstInstructionTime.until(hloPlans.get(0).timestamp, MILLIS),\n hloPlans.get(0).mistakes\n )\n ),\n new Pair<>(\"railing\",\n new HLOInformation(\n (int) hloPlans.get(0).timestamp.until(hloPlans.get(1).timestamp, MILLIS),\n hloPlans.get(1).mistakes - hloPlans.get(0).mistakes\n )\n ),\n new Pair<>(\"railing\",\n new HLOInformation(\n (int) hloPlans.get(1).timestamp.until(hloPlans.get(2).timestamp, MILLIS),\n hloPlans.get(2).mistakes - hloPlans.get(1).mistakes\n )\n )\n );\n } else if (getScenario().equals(\"house\")) {\n return List.of(\n new Pair<>(\"wall\",\n new HLOInformation((int) firstInstructionTime.until(hloPlans.get(0).timestamp, MILLIS),\n hloPlans.get(0).mistakes\n )\n ),\n new Pair<>(\"wall\",\n new HLOInformation((int) hloPlans.get(0).timestamp.until(hloPlans.get(1).timestamp, MILLIS),\n hloPlans.get(1).mistakes - hloPlans.get(0).mistakes\n )\n ),\n new Pair<>(\"wall\",\n new HLOInformation((int) hloPlans.get(1).timestamp.until(hloPlans.get(2).timestamp, MILLIS),\n hloPlans.get(2).mistakes - hloPlans.get(1).mistakes\n )\n ),\n new Pair<>(\"wall\",\n new HLOInformation((int) hloPlans.get(2).timestamp.until(hloPlans.get(3).timestamp, MILLIS),\n hloPlans.get(3).mistakes - hloPlans.get(2).mistakes\n )\n ),\n new Pair<>(\"row\",\n new HLOInformation((int) hloPlans.get(3).timestamp.until(hloPlans.get(4).timestamp, MILLIS),\n hloPlans.get(4).mistakes - hloPlans.get(3).mistakes\n )\n ),\n new Pair<>(\"row\",\n new HLOInformation((int) hloPlans.get(4).timestamp.until(hloPlans.get(5).timestamp, MILLIS),\n hloPlans.get(5).mistakes - hloPlans.get(4).mistakes\n )\n ),\n new Pair<>(\"row\",\n new HLOInformation((int) hloPlans.get(5).timestamp.until(hloPlans.get(6).timestamp, MILLIS),\n hloPlans.get(6).mistakes - hloPlans.get(5).mistakes\n )\n ),\n new Pair<>(\"row\",\n new HLOInformation((int) hloPlans.get(6).timestamp.until(hloPlans.get(7).timestamp, MILLIS),\n hloPlans.get(7).mistakes - hloPlans.get(6).mistakes\n )\n )\n );\n }\n return List.of();\n }", "public List<Item> getItemList();", "public List<Inventory> getInventory();", "List<Elective> loadAllElectives();", "@Override\n\tpublic List<Parking> vIPavailableParking() {\n\t\treturn parkingRepository.vIPavailableParking();\n\t}", "public List<ITemplateStep> getAllSteps();", "private void generateItemEntities(){\n final int NUM_POTIONS = 6;\n final int NUM_IRON_ARMOUR = 1;\n final int NUM_CHESTS = 2;\n final String ITEM_BOX_STYLE = \"volcano\";\n\n\n for (int i = 0; i < NUM_POTIONS; i++) {\n Tile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n Item.randomItemPositionGenerator(DEFAULT_HEIGHT));\n if (Integer.parseInt(tile.getTextureName().split(\"_\")[1]) < 5\n && !tile.hasParent()) {\n HealthPotion potion = new HealthPotion(tile,false,\n (PlayerPeon) getPlayerEntity(), ITEM_BOX_STYLE);\n entities.add(potion);\n this.allVolcanoDialogues.add(potion.getDisplay());\n } else {\n i--;\n }\n }\n for (int i =0; i < NUM_IRON_ARMOUR; i++){\n Tile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n Item.randomItemPositionGenerator(DEFAULT_HEIGHT));\n if (Integer.parseInt(tile.getTextureName().split(\"_\")[1]) < 5\n && !tile.hasParent()) {\n IronArmour ironArmour = new IronArmour(tile, false,\n (PlayerPeon) getPlayerEntity(),ITEM_BOX_STYLE,200);\n entities.add(ironArmour);\n this.allVolcanoDialogues.add(ironArmour.getDisplay());\n } else {\n i--;\n }\n }\n for (int i = 0; i <NUM_CHESTS; i++){\n Tile tile = getTile(Item.randomItemPositionGenerator(DEFAULT_WIDTH),\n Item.randomItemPositionGenerator(DEFAULT_HEIGHT));\n if (Integer.parseInt(tile.getTextureName().split(\"_\")[1]) < 5\n && !tile.hasParent()) {\n Treasure chest = new Treasure(tile, false,\n (PlayerPeon) getPlayerEntity(),ITEM_BOX_STYLE);\n entities.add(chest);\n this.allVolcanoDialogues.add(chest.getDisplay());\n } else {\n i--;\n }\n }\n\n Tile cooldownring = getTile(20,-7);\n CooldownRing cdring = new CooldownRing(cooldownring, false,\n (PlayerPeon) this.getPlayerEntity(), ITEM_BOX_STYLE,0.5f);\n entities.add(cdring);\n this.allVolcanoDialogues.add(cdring.getDisplay());\n\n Tile attackAmuletTile = getTile(2,14);\n Amulet attackAmulet = new Amulet(attackAmuletTile, false,\n (PlayerPeon) this.getPlayerEntity(), ITEM_BOX_STYLE,10);\n entities.add(attackAmulet);\n this.allVolcanoDialogues.add(attackAmulet.getDisplay());\n\n }", "java.util.List<UserOuterClass.ExperimentInfo> \n getExperimentsList();" ]
[ "0.53504896", "0.5081523", "0.50028044", "0.49394208", "0.49358892", "0.49227843", "0.48134187", "0.48029023", "0.47501117", "0.47375134", "0.47159296", "0.46727654", "0.46352026", "0.46347207", "0.46089983", "0.4607921", "0.45722046", "0.45719698", "0.45673293", "0.45638186", "0.45594275", "0.45349994", "0.4520933", "0.45149538", "0.44933733", "0.44911638", "0.44886425", "0.4468483", "0.4464572", "0.44617075", "0.44616958", "0.4460166", "0.44562817", "0.44446236", "0.4421431", "0.44206718", "0.44189087", "0.44161102", "0.44083148", "0.44072884", "0.4392542", "0.4383153", "0.4374771", "0.43745816", "0.43702942", "0.43689516", "0.436767", "0.43656045", "0.4363831", "0.43580094", "0.43484256", "0.43475628", "0.43404436", "0.43400046", "0.43388617", "0.43334797", "0.43253183", "0.43198568", "0.43170005", "0.4307248", "0.43036836", "0.43025357", "0.42868543", "0.42843616", "0.42752713", "0.42704055", "0.42651096", "0.42625493", "0.4261552", "0.42557204", "0.42526856", "0.42522028", "0.42483303", "0.42482218", "0.42479128", "0.42428365", "0.42382497", "0.42375383", "0.4237064", "0.42370307", "0.42362997", "0.42229065", "0.42222163", "0.42124468", "0.42091015", "0.42089424", "0.4207114", "0.42039993", "0.42012453", "0.41965565", "0.41936266", "0.4182656", "0.4182413", "0.41753507", "0.41731313", "0.41717094", "0.41714618", "0.4169611", "0.41673306", "0.41663" ]
0.45322308
22
Set the overhit flag on the L2Attackable.
public void overhitEnabled(final boolean status) { overhit = status; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setOverhitValues(final L2Character attacker, final double damage)\n\t{\n\t\t// Calculate the over-hit damage\n\t\t// Ex: mob had 10 HP left, over-hit skill did 50 damage total, over-hit damage is 40\n\t\tfinal double overhitDmg = (getCurrentHp() - damage) * -1;\n\t\t\n\t\tif (overhitDmg < 0)\n\t\t{\n\t\t\t// we didn't killed the mob with the over-hit strike. (it wasn't really an over-hit strike)\n\t\t\t// let's just clear all the over-hit related values\n\t\t\toverhitEnabled(false);\n\t\t\toverhitDamage = 0;\n\t\t\toverhitAttacker = null;\n\t\t\t\n\t\t\treturn;\n\t\t}\n\t\t\n\t\toverhitEnabled(true);\n\t\toverhitDamage = overhitDmg;\n\t\toverhitAttacker = attacker;\n\t}", "public void secondaryHit(Hit hit) {\n this.setSecondaryHit(hit);\n this.getFlags().flag(Flag.HIT_2);\n\n if (this instanceof Player) {\n Player player = (Player) this;\n\n player.getSkills().getTrainable()[Skill.HITPOINTS.ordinal()].decreaseLevel(player.getPrimaryHit().getDamage());\n SkillManager.getSingleton().refresh(player, Skill.HITPOINTS);\n }\n }", "public void setOver(boolean over) {\r\n isOver = over;\r\n }", "public boolean isOverhit()\n\t{\n\t\treturn overhit;\n\t}", "@Override\n\tpublic void takeHit(int attack) {\n\n\t}", "@Override\r\n\tpublic void gameOver() {\n\t\tover = true;\r\n\t\tupdate();\r\n\t}", "@Override\n public void hitFeedBack(boolean hit, Fleet enemyShips) {\n this.hit = hit;\n }", "public L2Character getOverhitAttacker()\n\t{\n\t\treturn overhitAttacker;\n\t}", "public void setHit(boolean b) {\r\n\t\tthis.hit = b;\r\n\t\t\r\n\t}", "@Override\n public void hit(int atk) {\n hp = hp - atk;\n }", "public final void turnOver() {\n this.currentMovementAllowance = this.details.getMaxMovementAllowance();\n this.onTurnOver();\n }", "public void battleOver()\r\n {\r\n isBattleOver = true;\r\n }", "public void setAttack(int attack) {\n base.setAttack(attack);\n }", "public void attack() {\n this.attacked = true;\n }", "public synchronized void setGameOver(boolean gameOver) {\n\t\tthis.gameOver = gameOver;\n\t}", "private void gameOver() {\n\t\tgameOver=true;\n\t}", "public void levelOver(){\n\t\t// this is called by the model when the user wins the game!\n\t\tif (gameModel.levelOver){\n\t\t\tsynchronized(gameModel){\n\n\t\t\tgameModel.resetGame();\n\t\t\tgameModel.createLevel(2,width,height);\n\t\t\tfor(Square s:gameModel.targets){\n\t\t\t\tLog.d(TAG,\"target = \"+s);\n\t\t\t}\n\t\t\tgameModel.levelOver=false;\n\t\t\t}\n\t\t\t\n\t\t}\n\t}", "@Override\n\tpublic void setAttack(double attack) {\n\n\t}", "@Override\r\n public void onHit(int damage){\n if(box2body != null){\r\n hp -= damage;\r\n screen.getGameManager().get(\"Sounds/orc-34-hit.wav\", Sound.class).play();\r\n if(this.hp <= 0) {\r\n screen.bodiesToDelete.add(box2body);\r\n deleteFlag = true;\r\n screen.spawnedCreatures.remove(this);\r\n screen.getGameManager().get(\"Sounds/orc-32-death.wav\", Sound.class).play();\r\n\r\n //Award Experience\r\n screen.getPlayer().awardExperience(this.experienceValue);\r\n screen.getPlayer().increaseKillCount();\r\n }\r\n }\r\n //Attack player when damaged\r\n //Prevents player from sniping monsters using Wander AI\r\n if(currentState != State.ATTACKING){\r\n Vector2 orcPosition = new Vector2(box2body.getPosition().x, box2body.getPosition().y);\r\n Vector2 playerPosition = new Vector2(screen.getPlayer().box2body.getPosition().x, screen.getPlayer().box2body.getPosition().y);\r\n\r\n currentState = State.HASBEENATTACKED;\r\n velocity = new Vector2(playerPosition.x - orcPosition.x, playerPosition.y - orcPosition.y);\r\n box2body.setLinearVelocity(velocity.scl(speed));\r\n }\r\n }", "public void move2(Pokemon enemy){\n boolean crit = false;\n boolean superEffective = false;\n boolean reduced = false;\n boolean moveHit = true;\n\n int randCrit = (int)(22 * Math.random()+1);\n\n //CHANGE ATTACK TO FALSE IF MOVE DOES NO DAMAGE<<<<<<<<<<<<<\n boolean attack = true;\n //CHANGE TYPE TO TYPE OF MOVE POWER AND ACCURACY<<<<<<<<<<<<<\n String type = \"Bug\";\n int power = 80;\n int accuracy = 100;\n\n //DO NOT CHANGE BELOW THIS\n int damage = ((CONSTANT * power * ( getAtt() / enemy.getDef() )) /50);\n if(randCrit == CONSTANT){\n damage = damage * 2;\n crit = true;\n }\n if(checkSE(type,enemy.getType())){\n damage = damage * 2;\n superEffective = true;\n }\n if(checkNVE(type, enemy.getType())){\n damage = damage / 2;\n reduced = true;\n }\n if(attack && hit(accuracy)){\n enemy.lowerHp(damage);\n }\n else{\n if(hit(accuracy)){\n //DO STATUS EFFECT STUFF HERE (ill figure out later)\n }\n }\n lowerM2PP();\n }", "public void Hit()\n {\n this.numLives--;\n //Oscillate visible and not if the number of lives is greater than zero\n if(this.numLives > 0)\n {\n this.damaged = true;\n this.Blink(1);\n\n }\n }", "public void battleEnemyAttack() {\n if(battleEnemy != null){ // If all enemies have attacked, they cannot attack anymore for this round\n\n MovingEntity target = battleEnemy.getAttackPreference(targetAllies);\n if(target == null){\n target = targetAlly;\n }\n\n battleEnemy.attack(target, targetEnemies, targetAllies);\n //System.out.println(battleEnemy.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still friendly incase of zombify\n targetAlly = checkSideSwap(targetAlly, false, battleEnemies, targetEnemies, battleAllies, targetAllies);\n }\n\n battleEnemy = nextAttacker(battleEnemy, battleEnemies);\n\n }\n }", "void hit(GameObject o){\r\n\t\tif (!shield){ // if sheild is on all hits do nothing\r\n\t\t\tif (!(o instanceof UpPower)){ // if didnt hit a power up the ship loses a life\r\n\t\t\t\tif (lives > 1) {\r\n\t\t\t\t\tlives--;\r\n\t\t\t\t\treset();\r\n\t\t\t\t}\r\n\t\t\t\telse { // once there is no life left the ship dies\r\n\t\t\t\t\tdead = true;\r\n\t\t\t\t\tlives--;\r\n\t\t\t\t}\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t}", "public void ability(LevelManager lm){\n\n int prevDamage = lm.player.getDamage();\n int newDamage = prevDamage+12;\n lm.player.setDamage(newDamage);\n }", "@Override\n\tpublic void skill2(Fightable f) {\n\t\tsuper.setDamage(super.getStrength()*2);\n\t\tsuper.setAtkRange((int)(super.getDamage()/10));\n\t\t\n\t\tthis.attack(f, 3);\n\t}", "public void setCurrentAbilityTarget(int enemyTargetIntentX, int enemyTargetIntentY, boolean hitOrSplat) {\n this.currentAbilityTargetX = enemyTargetIntentX;\n this.currentAbilityTargetY = enemyTargetIntentY;\n this.currentlyAbilityHit = hitOrSplat;\n }", "@Override\r\n\tpublic void gameOver() {\n\t\tgameOver = true;\r\n\t\tupdate();\r\n\t}", "public void setHitCount(int count) {\nthis.hitpoints = count;\n}", "void setGameOver() {\n myGameOver = true;\n myJump.userPauseThreads();\n }", "public double getOverhitDamage()\n\t{\n\t\treturn overhitDamage;\n\t}", "@Override\r\n\tpublic void Attack(Player arg0, Player arg1) {\n\t\t\r\n\t}", "@Override\r\n\tpublic void Attack(Player arg0, Player arg1) {\n\t\t\r\n\t}", "public void setGameOver(boolean gameOver) {\n\t\tthis.gameOver = gameOver;\n\t}", "@Override\n public void applyOnHit(LivingEntity user, LivingEntity target, int level, EntityDamageByEntityEvent event) {\n if (Math.random() * 100 > settings.get(CHANCE, level)) return;\n\n final double range = settings.get(RANGE, level);\n final double damage = settings.get(DAMAGE, level);\n final double speed = settings.get(SPEED, level);\n for (Entity entity : user.getNearbyEntities(range, range, range)) {\n if (!(entity instanceof LivingEntity) || Protection.isAlly(user, (LivingEntity)entity)) continue;\n\n ((LivingEntity) entity).damage(damage, user);\n entity.setVelocity(user.getLocation().subtract(entity.getLocation()).toVector().multiply(speed));\n }\n }", "public void setAttack(double attack) {\n this.attack = attack;\n }", "public void setAttack(int attack) {\r\n\t\tthis.attack = attack;\r\n\t}", "@Override\r\n\tpublic void attack(Ship target) {\r\n\t\t\r\n\t\tSniperVisual visual = (SniperVisual) getVisual();\r\n\t\tvisual.setTarget(target.getVisual().getPosition());\r\n\t\t\r\n\t\tif (this.isHit()) {\r\n\t\t\tdouble damage = this.getDamage();\r\n\t\t\tif (charged) {\r\n\t\t\t\tdamage *= 1.5;\r\n\t\t\t}\r\n\r\n\t\t\tif (this.getCanUseAbility() == true) {\r\n\t\t\t\tif (target.getHull() - target.getFinalDamage(damage) > 0)\r\n\t\t\t\t\ttarget.setHull(target.getHull()\r\n\t\t\t\t\t\t\t- target.getFinalDamage(damage));\r\n\t\t\t\telse\r\n\t\t\t\t\ttarget.setHull(0);\r\n\t\t\t} else {\r\n\t\t\t\tif (target.getHull() - damage > 0)\r\n\t\t\t\t\ttarget.setHull(target.getHull() - damage);\r\n\t\t\t\telse\r\n\t\t\t\t\ttarget.setHull(0);\r\n\t\t\t}\r\n\t\t\r\n\t\t\tsetDidMiss(false);\r\n\t\t} else {\r\n\t\t\tsetDidMiss(true);\r\n\t\t}\r\n\t\tthis.setCanMove(false);\r\n\t\tthis.setCanUseAbility(false);\r\n\t\tthis.setCanUseItem(false);\r\n\t\tthis.setCanAttack(false);\r\n\t\t\r\n\t\tif(charged){\r\n\t\t\tsetCharged(false);\r\n\t\t}\r\n\t}", "@Override\n\tpublic boolean attackEntityFrom(DamageSource src, float par2) {\n\t\tif (isInvulnerableTo(src)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// don't just sit there!\n\t\taiSit.setSitting(false);\n\n\t\treturn super.attackEntityFrom(src, par2);\n\t}", "public InaccurateAttackEffect() {\n\t\tsuper(Effect.Target.OPPONENT, Effect.FLIP_COIN);\n\t\tthis.numberOfHits = 1;\n\t\tthis.hitsPerEnergy = Effect.BOOL_NOT_USED;\n\t\tthis.hitsIndefinitely = Effect.BOOL_NOT_USED;\n\t}", "@Override\n\t\t\tpublic void attack(Base enemy) {\n\t\t\t}", "public void attackEntity(Entity entityToHit) {\n ItemStack item = tinkerProjectile.getItemStack();\n ItemStack launcher = tinkerProjectile.getLaunchingStack();\n\n // deal damage if we have everything\n if(item.getItem() instanceof ToolCore && this.attacker != null) {\n EntityLivingBase attacker = (EntityLivingBase) this.attacker;\n //EntityLivingBase target = (EntityLivingBase) raytraceResult.entityHit;\n\n // find the actual itemstack in the players inventory\n ItemStack inventoryItem = AmmoHelper.getMatchingItemstackFromInventory(tinkerProjectile.getItemStack(), attacker, false);\n if(inventoryItem.isEmpty() || inventoryItem.getItem() != item.getItem()) {\n // backup, use saved itemstack\n inventoryItem = item;\n }\n\n // for the sake of dealing damage we always ensure that the impact itemstack has the correct broken state\n // since the ammo stack can break while the arrow travels/if it's the last arrow\n boolean brokenStateDiffers = ToolHelper.isBroken(inventoryItem) != ToolHelper.isBroken(item);\n if(brokenStateDiffers) {\n toggleBroken(inventoryItem);\n }\n\n Multimap<String, AttributeModifier> projectileAttributes = null;\n // remove stats from held items\n if(!world.isRemote) {\n unequip(attacker, EntityEquipmentSlot.OFFHAND);\n unequip(attacker, EntityEquipmentSlot.MAINHAND);\n\n // apply stats from projectile\n if(item.getItem() instanceof IProjectile) {\n projectileAttributes = ((IProjectile) item.getItem()).getProjectileAttributeModifier(inventoryItem);\n\n if(launcher.getItem() instanceof ILauncher) {\n ((ILauncher) launcher.getItem()).modifyProjectileAttributes(projectileAttributes, tinkerProjectile.getLaunchingStack(), tinkerProjectile.getItemStack(), tinkerProjectile.getPower());\n }\n\n // factor in power\n projectileAttributes.put(SharedMonsterAttributes.ATTACK_DAMAGE.getName(),\n new AttributeModifier(PROJECTILE_POWER_MODIFIER, \"Weapon damage multiplier\", tinkerProjectile.getPower() - 1f, 2));\n\n attacker.getAttributeMap().applyAttributeModifiers(projectileAttributes);\n }\n // deal the damage\n// ToolHelper.attackEntity(item, (ToolCore) item.getItem(), attacker, entityToHit, null);\n// float speed = MathHelper.sqrt(this.motionX * this.motionX + this.motionY * this.motionY + this.motionZ * this.motionZ);\n\n boolean attack = ToolHelper.attackEntity(item, (ToolCore) item.getItem(), attacker, entityToHit, null);\n// if(attack) {\n//// for(IProjectileTrait trait : tinkerProjectile.getProjectileTraits()) {\n//// trait.afterHit(tinkerProjectile.get, this.world, inventoryItem, attacker, entityToHit, (double) 0.0);\n//// }\n//\n// // if on fire, set the entity on fire, like vanilla arrows\n//// if (this.isBurning() && !(entityToHit instanceof EntityEnderman)) {\n//// entityToHit.setFire(5);\n//// }\n// }\n if(brokenStateDiffers) {\n toggleBroken(inventoryItem);\n }\n\n // remove stats from projectile\n // apply stats from projectile\n if(item.getItem() instanceof IProjectile) {\n assert projectileAttributes != null;\n attacker.getAttributeMap().removeAttributeModifiers(projectileAttributes);\n }\n\n // readd stats from held items\n equip(attacker, EntityEquipmentSlot.MAINHAND);\n equip(attacker, EntityEquipmentSlot.OFFHAND);\n }\n }else {\n System.out.println(\"something failed with attacking.\");\n }\n }", "@Override\n\t\tpublic void hit(Npc attacker, Mob defender, Hit hit) {\n\t\t}", "private void tooHigh() {\n if (this.hitPoints > 255) {\n System.out.println(\"You set the value too high! Setting it to 255\");\n this.hitPoints = 255;\n }\n }", "public void attack() {\n energy = 2;\n redBull = 0;\n gun = 0;\n target = 1;\n // if Player is in range take off a life.\n if (CharacterTask.ghostLocation == GameWindow.playerLocation) {\n playerLives = playerLives - 1;\n System.out.println(\"Player Lives: \" + playerLives);\n }\n }", "@Override\n\tpublic void attack() {\n\t}", "public void attack(Person target) {\r\n target.setHealthPoints(target.getHealthPoints() - 1);\r\n }", "@Override\r\n public void hitEvent(Block beingHit, Ball hitter) {\n this.currentScore.increase(5);\r\n if (beingHit.getHitPoints() == 1) {\r\n this.currentScore.increase(10);\r\n }\r\n }", "public PassiveAbility(boolean onSelf, Effects effects) {\r\n\t\t// will be false if from buff;\r\n\t\tsuper(new FixedTargeting((onSelf) ? \"SOURCE\" : \"TARGET\"),\r\n\t\t\t\teffects);\r\n\t}", "@Override\n\tpublic void attack() {\n\n\t}", "private void hitP1(int attack) {\n game_PB_p1HP.setProgress(attack + game_PB_p1HP.getProgress());\n if (game_PB_p1HP.getProgress() > GameVariables.CRITICAL_HP)\n game_PB_p1HP.setProgressDrawable(ContextCompat.getDrawable(this, R.drawable.game_progressbar_low_hp));\n if (game_PB_p1HP.getProgress() >= GameVariables.MAX_HP)\n announceWinner(GameVariables.P2_WIN);\n\n }", "public void battleAllyAttack() {\n if(battleAlly instanceof Character){\n battleTickStatuses();\n updateBattleSides();\n }\n\n // battleAlly now attacks targetEnemy or preference based on the type of battleAlly\n if(battleAlly != null){ // If all allies have attacked, they cannot attack anymore for this round\n MovingEntity target = battleAlly.getAttackPreference(targetEnemies);\n // if not picky, get preference is the default next target\n if(target == null) {\n target = targetEnemy;\n }\n battleAlly.attack(target, targetAllies, targetEnemies);\n //System.out.println(battleAlly.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still unfriendly\n targetEnemy = checkSideSwap(targetEnemy, true, battleAllies, targetAllies, battleEnemies, targetEnemies);\n }\n battleAlly = nextAttacker(battleAlly, battleAllies);\n\n }\n }", "public void attack(Player p){\n p.takeDamage(damage);\n }", "@Override\n\tpublic void attack() {\n\t\t\n\t}", "protected void attackEntity(Entity var1, float var2)\n {\n if (this.attackTime <= 0 && var2 < 2.0F && var1.boundingBox.maxY > this.boundingBox.minY && var1.boundingBox.minY < this.boundingBox.maxY)\n {\n this.attackTime = 20;\n this.attackEntityAsMob(var1);\n }\n }", "@Override\n public void attack(Entity e) {\n e.hit(atk);\n }", "public void abilityTwo() {\n if(map.getCurrentTurnHero().getAbilities().size() < 2){\n return;\n }\n ability(map.getCurrentTurnHero().getAbilities().get(1));\n }", "public void setHitSpeed(double hitSpeed) {\n this.hitSpeed = hitSpeed;\n }", "@Override\n public void attack() {\n\n }", "public void setScenarioIsOver(int value) {\n this.scenarioIsOver = value;\n }", "public void setAttack(int attack) {\n\t\tthis.attack = attack;\n\t}", "public void weaken(float hit) {\n if (!isInvincible()) {\n hp -= hit;\n invincible = true;\n if (hp < 0) {\n hp = 0;\n }\n\n if(isWeak()){ //Play the death animation\n currentAnimation = deathAnimation;\n }\n }\n }", "public void attack() {\n if (activeWeapon == null) {\n return;\n }\n attacking = true;\n }", "public void takesHit()\n {\n // TODO: replace this line with your code\n }", "private void checkForInstability(boolean overshoot) { \n if (overshoot == true) {\n setUnstable();\n } else {\n setStable();\n }\n }", "@Override\n\tpublic int attack( ){\n\t\treturn enemy.attack();\n\t}", "@Override\n\tpublic void bumped(SpaceObject object) {\n\t\thit = true;\t\n\t}", "public L2Attackable(final int objectId, final L2NpcTemplate template)\n\t{\n\t\tsuper(objectId, template);\n\t\tgetKnownList(); // init knownlist\n\t\tmustGiveExpSp = true;\n\t}", "public void setHP(int hp) {\r\n\t\tthis.hp += hp;\r\n\t}", "@Override\n public void setHp(int hp){\n this.hp = hp;\n }", "@Override\n public void onTargetDamaged(LivingEntity user, Entity target, int level) {\n if(target instanceof LivingEntity) {\n\n //target.damage(DamageSource.LAVA, 3F);\n knockUp((PlayerEntity) user, (LivingEntity) target, 3F);\n }\n }", "public void Hitting(Monsters opponent) throws Exception {\n\t\tassert (this != opponent);\n\t\tRandom rand = new Random();\n\t\tint hit = rand.nextInt(30);\n\t\tif(hit >= this.getHitpoints()) \n\t\t\thit = this.getHitpoints();\n\t\tif (hit >= opponent.getProtection()) {\n\t\t\tint power;\n\t\t\tif (this.getAnchor(1) == null)\n\t\t\t\tpower = this.getDamage() + (this.getStrength() - 5) / 3;\n\t\t\telse\n\t\t\t\tpower = this.getDamage() + (this.getStrength() - 5) / 3 + ((Weapons)this.getAnchor(1)).getDamage();\n\t\t\topponent.setHitpoints(opponent.getHitpoints() - power);\n\t\t\tSystem.out.println(this.getName() + \" Deals \" + power + \" damage over \" + opponent.getName());\n\t\t}\n\t\telse\n\t\t\tSystem.out.println(this.getName() + \" attack failed!\");\n\t}", "public void setAttackPoint(int attackPoint) {\r\n\t\tthis.attackPoint = attackPoint;\r\n\t}", "public abstract void attack(Vector2 spawnPos, Vector2 target);", "public void attack() {\n\t\t\n\t\tint row = getPosition().getRow();\n\t\tint column = getPosition().getColumn();\n\t\t\n\t\tgetPosition().setCoordinates(row + 1, column);\n\t\tsetPosition(getPosition()) ;\n\t\t// restore health\n\t\tsetHealth(100);\n\t\t// end hunter mode\n\t\tthis.hunter = false;\n\t\t\n\t}", "@Override\r\n\tpublic void setHealth(int strike) {\n\t\t\r\n\t}", "public InaccurateAttackEffect(boolean hitsIndefinitely) {\n\t\tsuper(Effect.Target.OPPONENT, Effect.FLIP_COIN);\n\t\tthis.numberOfHits = Effect.INT_NOT_USED;\n\t\tthis.hitsIndefinitely = hitsIndefinitely;\n\t\tthis.hitsPerEnergy = Effect.BOOL_NOT_USED;\n\t}", "public void setHp(int hp){\r\n this.hp = hp;\r\n }", "@Override\n public void attack(){\n\n }", "@Override\n\tvoid attack() {\n\n\t}", "@Override\r\n\tpublic void useSkill() {\n\t\tthis.defense+=20;\r\n\t\tthis.maxHp+=(this.maxHp/2);\r\n\t\tthis.hp+=(this.hp/2);\r\n\t\tthis.skillActive = true;\r\n\t\tthis.skillLast = 2;\r\n\t}", "public void hitEvent(Block beingHit, Ball hitter) {\r\n this.currentScore.increase(5);\r\n if (beingHit.getHitPoints() == 0) {\r\n this.currentScore.increase(10);\r\n }\r\n }", "@Override\n public void collide(ScreenObject other) {\n switch (other.getType()) {\n case ASTEROID:\n hp -= other.dealDamage();\n break;\n case ENEMY:\n hp -= other.dealDamage();\n break;\n case ENEMYBULLET:\n hp -= other.dealDamage();\n break;\n case MACGUFFIN:\n macguffinsCollected++;\n break;\n case PORT:\n if (macguffinsCollected >= level.getMacguffinCount()\n && boundingCircle.contains(other.getPosition())) {\n Gdx.app.log(\"Ship\", \"level over\");\n //ends level\n }\n break;\n }\n }", "@Override\r\n\tpublic void attack(DungeonCharacter that)\r\n\t{\n\t}", "public void attackTargetCharacter() {\n }", "public static void playHitObst()\n {\n playHitObst(0);\n }", "@Test\n\tpublic final void hitOutOfBoundsTest() {\n\t\tplayer.hit(4);\n\t\tassertEquals(player.getIsAlive(), false);\n\t\tassertEquals(player.getLives(), 0);\n\t}", "private boolean tryAttack(Tile fromTile) {\r\n\t\tint size = getBoard().getTiles().length;\r\n\r\n\t\t// if attacker is on power-up tile\r\n\t\tif (fromTile.getTileType().equals(\"PowerUp\")) {\r\n\t\t\tif (fromTile.getPiece().getLEAGUE() == League.SHARK && fromTile.getTer().territoryName().equals(\"Shark\")) {\r\n\t\t\t\tfromTile.getPiece().setPower(fromTile.getPiece().getPower() + 1);\r\n\t\t\t}\r\n\r\n\t\t\tif (fromTile.getPiece().getLEAGUE() == League.EAGLE && fromTile.getTer().territoryName().equals(\"Eagle\")) {\r\n\t\t\t\tfromTile.getPiece().setPower(fromTile.getPiece().getPower() + 1);\r\n\t\t\t} else if (fromTile.getTer().territoryName().equals(\"Neutral\")) {\r\n\t\t\t\tfromTile.getPiece().setPower(fromTile.getPiece().getPower() + 1);\r\n\t\t\t}\r\n\r\n\t\t}\r\n\t\t// if the defender is on power-up tile\r\n\t\tif (tile.getTileType().equals(\"PowerUp\")) {\r\n\t\t\tif (tile.getPiece().getLEAGUE() == League.SHARK && tile.getTer().territoryName().equals(\"Shark\")) {\r\n\t\t\t\ttile.getPiece().setPower(tile.getPiece().getPower() + 1);\r\n\t\t\t}\r\n\r\n\t\t\tif (tile.getPiece().getLEAGUE() == League.EAGLE && tile.getTer().territoryName().equals(\"Eagle\")) {\r\n\t\t\t\ttile.getPiece().setPower(tile.getPiece().getPower() + 1);\r\n\t\t\t} else if (tile.getTer().territoryName().equals(\"Neutral\")) {\r\n\t\t\t\ttile.getPiece().setPower(tile.getPiece().getPower() + 1);\r\n\t\t\t}\r\n\r\n\t\t}\r\n\r\n\t\tif (fromTile.getPiece().getPower() >= tile.getPiece().getPower()) {\r\n\t\t\tif (tile.getPiece().getTYPE() == PieceType.FLAG) {\r\n\t\t\t\tfromTile.getPiece().setHasEnemyFlag(true);\r\n\t\t\t\tUtilities.infoAlert(\"Enemy Flag Captured!\", \"Get that piece with the flag back to your territory quickly!\");\r\n\t\t\t} else {\r\n\t\t\t\tif (tile.getPiece().getHasEnemyFlag() == true) {\r\n\t\t\t\t\tUtilities.infoAlert(\"Flag Recaptured!\", \"Enemy piece carrying your flag has been killed.\\nYour flag has respawned in your territory.\");\r\n\r\n\t\t\t\t\t// generate the dropped flag at its original position\r\n\t\t\t\t\t// or generate the dropped flag on first available tile on first or last row\r\n\t\t\t\t\t// if the default position has a piece on it\r\n\t\t\t\t\tif (tile.getPiece().getLEAGUE() == League.EAGLE) {\r\n\t\t\t\t\t\tif (getBoard().getTiles()[size - 1][(size / 2) - 1].getPiece() == null) {\r\n\t\t\t\t\t\t\tgetBoard().getTiles()[size - 1][(size / 2) - 1].setPiece(new SharkFlag());\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\tfor (int sharkCol = 0; sharkCol < getBoard().getTiles().length; sharkCol++) {\r\n\t\t\t\t\t\t\t\tif (getBoard().getTiles()[size - 1][sharkCol].getPiece() == null) {\r\n\t\t\t\t\t\t\t\t\tgetBoard().getTiles()[size - 1][sharkCol].setPiece(new SharkFlag());\r\n\t\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tif (getBoard().getTiles()[0][size / 2].getPiece() == null) {\r\n\t\t\t\t\t\t\tgetBoard().getTiles()[0][size / 2].setPiece(new EagleFlag());\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\tfor (int eagleCol = 0; eagleCol < getBoard().getTiles().length; eagleCol++) {\r\n\t\t\t\t\t\t\t\tif (getBoard().getTiles()[0][eagleCol].getPiece() == null) {\r\n\t\t\t\t\t\t\t\t\tgetBoard().getTiles()[0][eagleCol].setPiece(new EagleFlag());\r\n\t\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn movePiece(fromTile);\r\n\t\t} else {\r\n\t\t\tUtilities.infoAlert(\"Invalid action\", \"Enemy power level higher at level \" + tile.getPiece().getPower()\r\n\t\t\t\t\t+ \". \" + \"\\nYour current piece is not able to defeat it and has cowered back in fear.\");\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "protected void onImpact(RayTraceResult result) {\n\t\tif (result.entityHit != null) {\n\t\t\tfloat i = 2.5F;\n\n\t\t\tif (result.entityHit instanceof EntityBlizzard) {\n\t\t\t\ti = 0;\n\t\t\t}\n\n result.entityHit.attackEntityFrom(WorldsRetold.HAIL, i);\n\n\t\t\tif (result.entityHit instanceof EntityLivingBase) {\n\t\t\t\tEntityLivingBase target = (EntityLivingBase) result.entityHit;\n\t\t\t\tif (!this.world.isRemote) {\n\t\t\t\t\ttarget.addPotionEffect(new PotionEffect(HailstormPotions.FREEZING, 100, 0));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (!this.world.isRemote) {\n\t\t\tthis.world.setEntityState(this, (byte) 3);\n\t\t\tthis.setDead();\n\t\t}\n\t}", "public void damage(int damageTaken) {\n //TODO: Create specific damage methods instead of damage calls everywhere(see damagedByBullet())\n if (!invincible) {\n this.hp -= damageTaken;\n }\n }", "@Override\n public void use(AbstractPlayer p, AbstractMonster m) {\n if (this.dontTriggerOnUseCard) {\n if (damage > 0) {\n AbstractDungeon.actionManager.addToBottom(new DamageAction(AbstractDungeon.getRandomMonster(), new DamageInfo(p, damage, damageTypeForTurn), AttackEffect.BLUNT_HEAVY));\n }\n otherCardsPlayed = 0;\n }\n }", "public void attackEntity(Entity entity)\n/* 79: */ {\n/* 80:71 */ super.attackEntity(entity);\n/* 81: */ }", "public void attack(){\n activity = CreatureActivity.ATTACK;\n createWeapon();\n endAttack = new CountDown(20); //100\n endAnimationAttack = new CountDown(100);\n }", "public void move1(Pokemon enemy){\n int randCrit = (int)(22 * Math.random()+1);\n boolean crit = false;\n boolean superEffective = false;\n boolean reduced = false;\n boolean moveHit = true;\n\n //CHANGE ATTACK TO FALSE IF MOVE DOES NO DAMAGE<<<<<<<<<<<<<\n boolean attack = true;\n //CHANGE TYPE TO TYPE OF MOVE POWER AND ACCURACY<<<<<<<<<<<<<\n String type = \"Dark\";\n int power = 70;\n int accuracy = 100;\n\n //DO NOT CHANGE BELOW THIS\n int damage = ((CONSTANT * power * ( getAtt() / enemy.getDef() )) /50);\n if(randCrit == CONSTANT){\n damage = damage * 2;\n crit = true;\n }\n if(checkSE(type,enemy.getType())){\n damage = damage * 2;\n superEffective = true;\n }\n if(checkNVE(type, enemy.getType())){\n damage = damage / 2;\n reduced = true;\n }\n if(attack && hit(accuracy)){\n enemy.lowerHp(damage);\n }\n else{\n if(hit(accuracy)){\n //DO STATUS EFFECT STUFF HERE (ill figure out later)\n }\n\n }\n lowerM1PP();\n }", "@Override\n public void hit(int damage)\n {\n state.hit(damage, this);\n }", "@Override\n public void attackedByShaman(double attack) {\n damageCounter += (2 * attack) / 3;\n this.attack = Math.max(this.attack - (2 * attack) / 3, 0);\n }", "@Override\n\tpublic void attack(Slime slime) {\n\t\t\n\t}", "public InaccurateAttackEffect(int numberOfHits) {\n\t\tsuper(Effect.Target.OPPONENT, Effect.FLIP_COIN);\n\t\tthis.numberOfHits = numberOfHits;\n\t\tthis.hitsPerEnergy = Effect.BOOL_NOT_USED;\n\t\tthis.hitsIndefinitely = Effect.BOOL_NOT_USED;\n\t}", "public void attemptAttack() {\r\n\t\tattackAttempts += 100;\r\n\t}", "@Override\n\tpublic void OnAttackCommand() {\n\t\tsuper.OnAttackCommand();\n\t\tSoundManage.playSound(atkSound1);\n\t}", "public void setOvertimeHourlyWage(int overtimeHourlyWage) {\n this.overtimeHourlyWage = overtimeHourlyWage;\n }" ]
[ "0.6440863", "0.6307259", "0.60652065", "0.59756804", "0.59407073", "0.5843168", "0.58423376", "0.5839889", "0.5813153", "0.58041537", "0.579936", "0.5718201", "0.56611526", "0.56418896", "0.562023", "0.5575406", "0.5563217", "0.5541754", "0.55378634", "0.55223", "0.55077964", "0.54744226", "0.54689974", "0.5468852", "0.54683423", "0.54572415", "0.5449282", "0.5398279", "0.5394931", "0.538236", "0.5369691", "0.5369691", "0.5355613", "0.53542507", "0.5353029", "0.5347706", "0.53319234", "0.53232527", "0.5312886", "0.52993655", "0.52947897", "0.52915555", "0.52854615", "0.5283454", "0.5276258", "0.5272269", "0.5270495", "0.52585185", "0.52571493", "0.5253371", "0.5245321", "0.52353936", "0.5226299", "0.5225461", "0.5224517", "0.5222847", "0.5220728", "0.52199715", "0.52130026", "0.5212613", "0.5194766", "0.5187573", "0.5186469", "0.5176225", "0.5175887", "0.51640856", "0.5155645", "0.5154891", "0.5145204", "0.5144046", "0.5140597", "0.512215", "0.5118109", "0.5110645", "0.5100822", "0.5098202", "0.5095162", "0.5085285", "0.5069832", "0.50684184", "0.5068017", "0.50650007", "0.50577587", "0.5057416", "0.50518346", "0.50517774", "0.504467", "0.5034714", "0.5034172", "0.5033547", "0.5028223", "0.5024576", "0.5023538", "0.50187516", "0.5016918", "0.5016034", "0.50030595", "0.49996033", "0.49916372", "0.4989407" ]
0.65335584
0
Set the overhit values like the attacker who did the strike and the ammount of damage done by the skill.
public void setOverhitValues(final L2Character attacker, final double damage) { // Calculate the over-hit damage // Ex: mob had 10 HP left, over-hit skill did 50 damage total, over-hit damage is 40 final double overhitDmg = (getCurrentHp() - damage) * -1; if (overhitDmg < 0) { // we didn't killed the mob with the over-hit strike. (it wasn't really an over-hit strike) // let's just clear all the over-hit related values overhitEnabled(false); overhitDamage = 0; overhitAttacker = null; return; } overhitEnabled(true); overhitDamage = overhitDmg; overhitAttacker = attacker; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void hit(int atk) {\n hp = hp - atk;\n }", "private float setAttackAbsorption(HashMap content) {\n\t\tfloat change = calculateAbsorption();\n this.attackDamageModifier = baseDamageModifier + change;\n//System.out.println(\"attack: \" + this.attackDamageModifier);\n content.put(\"attack_damage_modifier\", \"\" + this.attackDamageModifier);\n\t\treturn change*ABSORPTION_PRICE_MULTIPLIER;\n }", "public double getOverhitDamage()\n\t{\n\t\treturn overhitDamage;\n\t}", "@Override\r\n\tpublic void useSkill() {\n\t\tthis.defense+=20;\r\n\t\tthis.maxHp+=(this.maxHp/2);\r\n\t\tthis.hp+=(this.hp/2);\r\n\t\tthis.skillActive = true;\r\n\t\tthis.skillLast = 2;\r\n\t}", "@Override\r\n\tpublic void setHealth(int strike) {\n\t\t\r\n\t}", "public void setAttack(double attack) {\n this.attack = attack;\n }", "@Override\n\tpublic void setAttack(double attack) {\n\n\t}", "@Override\n\tpublic void takeHit(int attack) {\n\n\t}", "public void setHp(int hp){\r\n this.hp = hp;\r\n }", "@Override\n public void attackedByShaman(double attack) {\n damageCounter += (2 * attack) / 3;\n this.attack = Math.max(this.attack - (2 * attack) / 3, 0);\n }", "public void setHP(int hp) {\r\n\t\tthis.hp += hp;\r\n\t}", "public void setHungerDamage(float hunger);", "public void setHitCount(int count) {\nthis.hitpoints = count;\n}", "@Override\n public void setHp(int hp){\n this.hp = hp;\n }", "@Override\n public void attackedByPaladin(double attack) {\n this.attack += (2 * attack) / 3;\n damageCounter = Math.max(damageCounter - (2 * attack) / 3, 0);\n }", "public InaccurateAttackEffect() {\n\t\tsuper(Effect.Target.OPPONENT, Effect.FLIP_COIN);\n\t\tthis.numberOfHits = 1;\n\t\tthis.hitsPerEnergy = Effect.BOOL_NOT_USED;\n\t\tthis.hitsIndefinitely = Effect.BOOL_NOT_USED;\n\t}", "public void setActualHP(int hp) { this.actualHP = Math.max(0, hp); }", "public void setHp(int hp) {\r\n\t\tthis.hp = hp;\r\n\t}", "public void setHits(Hits hits) {\n this.hits = hits;\n }", "public void setAttack(int attack) {\n base.setAttack(attack);\n }", "public InaccurateAttackEffect(int numberOfHits) {\n\t\tsuper(Effect.Target.OPPONENT, Effect.FLIP_COIN);\n\t\tthis.numberOfHits = numberOfHits;\n\t\tthis.hitsPerEnergy = Effect.BOOL_NOT_USED;\n\t\tthis.hitsIndefinitely = Effect.BOOL_NOT_USED;\n\t}", "public void attack(Player player) {\n this.damage = 18 - player.getfPoint(); // the higher the Fighter skill,\n // the lower the damage. change the math.\n int newHealth = player.getShip().getHealth() - damage;\n player.getShip().setHealth(newHealth);\n }", "public void setTowerAttackDamage() {\n\t\tTowerDisplayEntity tower = new TowerDisplayEntity();\n\t\ttower.setAttackDamage(10);\n\t}", "public void setAttack(int attack) {\r\n\t\tthis.attack = attack;\r\n\t}", "public void setHp(int hp) {\n\t\tthis.hp = hp;\n\t}", "public void setStats(int health, int attack, int defense) {\n\t\tmaxHealth = health;\n\t maxAttack = attack;\n\t maxDefense = defense;\n\t curHealth = maxHealth;\n\t curAttack = maxAttack;\n\t curDefense = maxDefense;\n\t}", "void takeDamage(int points) {\n this.health -= points;\n }", "@Override\n\t\tpublic void hit(Npc attacker, Mob defender, Hit hit) {\n\t\t}", "private void strengthen(float hp) {\n this.hp += hp;\n if (this.hp > MAX_HP) {\n this.hp = MAX_HP;\n }\n }", "public void damage(int damageTaken) {\n //TODO: Create specific damage methods instead of damage calls everywhere(see damagedByBullet())\n if (!invincible) {\n this.hp -= damageTaken;\n }\n }", "public void attackEntity(Entity entityToHit) {\n ItemStack item = tinkerProjectile.getItemStack();\n ItemStack launcher = tinkerProjectile.getLaunchingStack();\n\n // deal damage if we have everything\n if(item.getItem() instanceof ToolCore && this.attacker != null) {\n EntityLivingBase attacker = (EntityLivingBase) this.attacker;\n //EntityLivingBase target = (EntityLivingBase) raytraceResult.entityHit;\n\n // find the actual itemstack in the players inventory\n ItemStack inventoryItem = AmmoHelper.getMatchingItemstackFromInventory(tinkerProjectile.getItemStack(), attacker, false);\n if(inventoryItem.isEmpty() || inventoryItem.getItem() != item.getItem()) {\n // backup, use saved itemstack\n inventoryItem = item;\n }\n\n // for the sake of dealing damage we always ensure that the impact itemstack has the correct broken state\n // since the ammo stack can break while the arrow travels/if it's the last arrow\n boolean brokenStateDiffers = ToolHelper.isBroken(inventoryItem) != ToolHelper.isBroken(item);\n if(brokenStateDiffers) {\n toggleBroken(inventoryItem);\n }\n\n Multimap<String, AttributeModifier> projectileAttributes = null;\n // remove stats from held items\n if(!world.isRemote) {\n unequip(attacker, EntityEquipmentSlot.OFFHAND);\n unequip(attacker, EntityEquipmentSlot.MAINHAND);\n\n // apply stats from projectile\n if(item.getItem() instanceof IProjectile) {\n projectileAttributes = ((IProjectile) item.getItem()).getProjectileAttributeModifier(inventoryItem);\n\n if(launcher.getItem() instanceof ILauncher) {\n ((ILauncher) launcher.getItem()).modifyProjectileAttributes(projectileAttributes, tinkerProjectile.getLaunchingStack(), tinkerProjectile.getItemStack(), tinkerProjectile.getPower());\n }\n\n // factor in power\n projectileAttributes.put(SharedMonsterAttributes.ATTACK_DAMAGE.getName(),\n new AttributeModifier(PROJECTILE_POWER_MODIFIER, \"Weapon damage multiplier\", tinkerProjectile.getPower() - 1f, 2));\n\n attacker.getAttributeMap().applyAttributeModifiers(projectileAttributes);\n }\n // deal the damage\n// ToolHelper.attackEntity(item, (ToolCore) item.getItem(), attacker, entityToHit, null);\n// float speed = MathHelper.sqrt(this.motionX * this.motionX + this.motionY * this.motionY + this.motionZ * this.motionZ);\n\n boolean attack = ToolHelper.attackEntity(item, (ToolCore) item.getItem(), attacker, entityToHit, null);\n// if(attack) {\n//// for(IProjectileTrait trait : tinkerProjectile.getProjectileTraits()) {\n//// trait.afterHit(tinkerProjectile.get, this.world, inventoryItem, attacker, entityToHit, (double) 0.0);\n//// }\n//\n// // if on fire, set the entity on fire, like vanilla arrows\n//// if (this.isBurning() && !(entityToHit instanceof EntityEnderman)) {\n//// entityToHit.setFire(5);\n//// }\n// }\n if(brokenStateDiffers) {\n toggleBroken(inventoryItem);\n }\n\n // remove stats from projectile\n // apply stats from projectile\n if(item.getItem() instanceof IProjectile) {\n assert projectileAttributes != null;\n attacker.getAttributeMap().removeAttributeModifiers(projectileAttributes);\n }\n\n // readd stats from held items\n equip(attacker, EntityEquipmentSlot.MAINHAND);\n equip(attacker, EntityEquipmentSlot.OFFHAND);\n }\n }else {\n System.out.println(\"something failed with attacking.\");\n }\n }", "public void setBonus(int firstThrow, int secondThrow) {\r\n\t\t//to be implemented\r\n\t\tfor(int i=0; i<10; i++)\r\n\t\t\tif(frames.get(i).isSpare())\r\n\t\t\t{\r\n\t\t\t\tbonus= frames.get(i+1);\r\n\t\t\t\tbonusGame+=bonus.score();\r\n\t\t\t}\r\n\t\t\telse if(frames.get(i).isStrike())\r\n\t\t\t{\r\n\t\t\t\tbonus = frames.get(i+1);\r\n\t\t\t\tbonusGame+=bonus.score();\r\n\t\t\t\t\r\n\t\t\t}\r\n\t}", "public void heal(){\n\t\thp += potion.getHpBoost();\n\t\tif(hp > max_hp)hp = max_hp;\n\t}", "public void setHP(int h)\n\t{\n\t\tiHP = h;\n\t\t\n\t}", "public void hurt(int damage)\n {\n \t hp -= (damage - ( damage * armor / 100 ));\n \t //System.out.println(\"hp: \" + hp);\n }", "public void weaken(float hit) {\n if (!isInvincible()) {\n hp -= hit;\n invincible = true;\n if (hp < 0) {\n hp = 0;\n }\n\n if(isWeak()){ //Play the death animation\n currentAnimation = deathAnimation;\n }\n }\n }", "@Override\r\n\tpublic void heal() {\n\t\tSystem.out.println(\"Paladin \" + super.getName() + \" heals for 50 points.\");\r\n\t\tsuper.setHitPoints(super.getHitPoints() + 50);\r\n\t}", "protected void takeDamage(int damage)\n {\n health = health - damage;\n \n }", "public void getHits(int newHits) {\r\n\t\thits = newHits;\r\n\t\t\r\n\t\t//set achievement number\r\n\t\tif(hits >=25 && hits<50) {\r\n\t\t\tachievement = 1;\r\n\t\t}\r\n\t\telse if(hits >=50 && hits<100) {\r\n\t\t\tachievement = 2;\r\n\t\t}\r\n\t\telse if(hits >=100 && hits<200) {\r\n\t\t\tachievement = 3;\r\n\t\t}\r\n\t\telse if(hits > 200) {\r\n\t\t\tachievement = 4;\r\n\t\t}\r\n\t}", "public void attack() {\n energy = 2;\n redBull = 0;\n gun = 0;\n target = 1;\n // if Player is in range take off a life.\n if (CharacterTask.ghostLocation == GameWindow.playerLocation) {\n playerLives = playerLives - 1;\n System.out.println(\"Player Lives: \" + playerLives);\n }\n }", "private void enemyAttack() {\n\t\t\n\t\tRandom rand = new Random();\t\n\t\t\n\t\tint roll = rand.nextInt(101);\n\t\t\n\t\tint sroll = rand.nextInt(101);\n\t\t\n\t\tevents.appendText(e.getName() + \" attacks!\\n\");\n\t\t\n\t\tif(roll <= p.getEV()) { // Player evades\n\t\t\t\n\t\t\tevents.appendText(\"You evaded \"+e.getName()+\"\\'s Attack!\\n\");\n\t\t\t\n\t\t}else if(roll > p.getEV()) { // Player is hit and dies if HP is 0 or less\n\t\t\t\n\t\t\tp.setHP(p.getHP() - e.getDMG());\n\t\t\t\n\t\t\tString newHp = p.getHP()+\"/\"+p.getMaxHP();\n\t\t\t\n\t\t\tString effect = e.getSpecial(); // Stats are afflicted\n\t\t\t\n\t\t\tif(sroll < 51){\n\t\t\t\t\n\t\t\tif(effect == \"Bleed\") { // Bleed Special\n\t\t\t\t\n\t\t\t\tp.setHP(p.getHP() - 100);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You bleed profusely. - 100 HP\\n\");\n\t\t\t\t\n\t\t\t\tnewHp = String.valueOf(p.getHP()+\"/\"+p.getMaxHP());\n\t\t\t}\n\t\t\tif(effect == \"Break\") { // Break Special \n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"You feel a bone break restricting movement. - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Fear\") { // Fear Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-40>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 40);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"A crippling fear rattles your resolve. - 40 DMG\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t}\n\t\t\tif(effect == \"Rend\") { // Rend Special \n\t\t\t\t\n\t\t\t\tif(p.getDMG()-30>0)\n\t\t\t\t\tp.setDMG(p.getDMG() - 30);\n\t\t\t\telse\n\t\t\t\t\tp.setDMG(0);\n\t\t\t\t\n\t\t\t\tif(p.getEV()-5>0)\n\t\t\t\t\tp.setEV(p.getEV() - 5);\n\t\t\t\telse\n\t\t\t\t\tp.setEV(0);\n\t\t\t\t\n\t\t\t\tevents.appendText(\"Morthar unleashes a pillar of flame! - 30 DMG and - 5 EV\\n\");\n\t\t\t\t\n\t\t\t\tString newDMG = String.valueOf(p.getDMG());\n\t\t\t\t\n\t\t\t\tString newEV = String.valueOf(p.getEV());\n\t\t\t\t\n\t\t\t\tgdmg.setText(newDMG);\n\t\t\t\t\n\t\t\t\tgev.setText(newEV);\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\t\n\t\t\tif(p.getHP() <= 0) {\n\t\t\t\t\n\t\t\t\tp.setDead(true);\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(0+\"/\"+e.getMaxHP());\n\t\t\t\tplayerHPBar.setProgress((double)0);\n\t\t\t}else {\n\t\t\t\t\n\t\t\t\tcurrentHp.setText(newHp);\n\t\t\t\tplayerHPBar.setProgress((double)p.getHP()/p.getMaxHP());\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tif(p.isDead()) { // Game over if player dies\n\t\t\t\n\t\t\ttry {\n\t\t\t\tLoadGO();\n\t\t\t} catch (IOException e1) {\n\t\t\t\n\t\t\t\te1.printStackTrace();\n\t\t\t}\n\t\t\t\n\t\t\tcombat = false;\n\t\t}\n\t}", "public void setAttack(int attack) {\n\t\tthis.attack = attack;\n\t}", "@Override\n public void attack(Entity e) {\n e.hit(atk);\n }", "public void suffer(int hits)\r\n {\r\n health = health - hits;\r\n if (health < 0)\r\n health = 0;\r\n if (hits == 0)\r\n say(\"Hahaha! I defened myself with \" + armor.getName() + \" and still have \" + health + \" left!\");\r\n else\r\n say(\"Ouch! \" + hits + \" hits is more than I want! I only have \" + health + \" left!\");\r\n if (health <= 0)\r\n die();\r\n }", "public void Hitting(Monsters opponent) throws Exception {\n\t\tassert (this != opponent);\n\t\tRandom rand = new Random();\n\t\tint hit = rand.nextInt(30);\n\t\tif(hit >= this.getHitpoints()) \n\t\t\thit = this.getHitpoints();\n\t\tif (hit >= opponent.getProtection()) {\n\t\t\tint power;\n\t\t\tif (this.getAnchor(1) == null)\n\t\t\t\tpower = this.getDamage() + (this.getStrength() - 5) / 3;\n\t\t\telse\n\t\t\t\tpower = this.getDamage() + (this.getStrength() - 5) / 3 + ((Weapons)this.getAnchor(1)).getDamage();\n\t\t\topponent.setHitpoints(opponent.getHitpoints() - power);\n\t\t\tSystem.out.println(this.getName() + \" Deals \" + power + \" damage over \" + opponent.getName());\n\t\t}\n\t\telse\n\t\t\tSystem.out.println(this.getName() + \" attack failed!\");\n\t}", "@Override\n public int damage() {\n int newDamage=criticalStrike();\n return newDamage;\n }", "public void setHitsLeft(int hits){\n hitsLeft = hits;\n }", "public void secondaryHit(Hit hit) {\n this.setSecondaryHit(hit);\n this.getFlags().flag(Flag.HIT_2);\n\n if (this instanceof Player) {\n Player player = (Player) this;\n\n player.getSkills().getTrainable()[Skill.HITPOINTS.ordinal()].decreaseLevel(player.getPrimaryHit().getDamage());\n SkillManager.getSingleton().refresh(player, Skill.HITPOINTS);\n }\n }", "public void setHandThrowDamage(short handThrowDamage);", "public void attack(Person target) {\r\n target.setHealthPoints(target.getHealthPoints() - 1);\r\n }", "public static void experience(){\n PlayerStats.currentEXP += (12*AC + 8*totalHP);\n System.out.println(\"You gained \" +(12*AC + 8*totalHP)+ \" experience!\");\n }", "public void hit(int melee_dmg,int range_dmg) {\n melee_dmg=this.current_atk-30;\n range_dmg=this.current_atk-60;\n }", "void gainHealth(int points) {\n this.health += points;\n }", "public void applyDamage(int damage)\r\n\t{\r\n\r\n\t}", "public void AIDamage() {\r\n\t\tif (attackStyle == 2) {\r\n\t\t\tfor(int i = 0; i < AIObject.length; i++) {\r\n\t\t\t\tif ((inFlight) && (Math.abs(aX-AIObject[i].getAIX()) < 5) && (Math.abs(aY-AIObject[i].getAIY())) < 4 ) {\r\n\t\t\t\t\tAIObject[i].setHealth(-25 * damageReduction);\r\n\t\t\t\t\tdrawArrow = false;\r\n\t\t\t\t\tcooldown = 15;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}else {\r\n\t\t\tif (mouseLeft) {\r\n\t\t\t\tfor(int i = 0; i < AIObject.length; i++){\r\n\t\t\t\t\tif ((drawSword) && (cooldown == 0) && (playerObject[0].getX() -AIObject[i].getAIX() <85) && (playerObject[0].getX()-AIObject[i].getAIX() >-1) && (playerObject[0].getY() - AIObject[i].getAIY() < 20) && (playerObject[0].getY()-AIObject[i].getAIY()>-5)) {\r\n\t\t\t\t\t\tAIObject[i].setHealth(-50 * damageReduction);\r\n\t\t\t\t\t\tcooldown = 5;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}else {\r\n\t\t\t\tfor(int i=0; i < AIObject.length; i++){\r\n\t\t\t\t\tif ((drawSword) && (cooldown == 0) && (AIObject[i].getAIX()-playerObject[0].getX() <85) && (AIObject[i].getAIX() - playerObject[0].getX() > -1) && (playerObject[0].getY() - AIObject[i].getAIY() < 20) && (playerObject[0].getY()-AIObject[i].getAIY()>-5)) {\r\n\t\t\t\t\t\tAIObject[i].setHealth(-50 * damageReduction);\r\n\t\t\t\t\t\tcooldown = 5;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\tfor(int i=0; i < AIObject.length; i++){\r\n\t\t\t//checks if AI is close enough to attack with melee\r\n\t\t\tfor (int j = 0; j < playerObject.length; j++) {\r\n\t\t\t\tif ((!shield) && (Math.abs(AIObject[i].getAIX() - playerObject[j].getX()) <= 10) && (Math.abs(AIObject[i].getAIY() - playerObject[j].getY())) <= 3) {\r\n\t\t\t\t\tplayerObject[j].setHealth(DAMAGE_AMOUNT * difficulty);\r\n\t\t\t\t\tif (playerObject[j].getHealth() <= 0) {\r\n\t\t\t\t\t\tdead = true;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public static void bullyAttack(){\n int punch = player.getHealth() - bullyHitPoints ;\n player.setHealth(punch);\n //Step 2: Conditional dialogue\n if(bullyHitPoints > 50) {\n System.out.println(textparser.getMassiveDamage() + bullyHitPoints + textparser.getToYou());\n }else if(bullyHitPoints > 25){\n System.out.println(textparser.getPunch() + bullyHitPoints + textparser.getToYou());\n }else{\n System.out.println(textparser.getDidntHurtMuch() + bullyHitPoints + textparser.getToYou());\n }\n }", "public int attack(Character target){ //hw3E#0 //hw46#moreThinking\n lowerHP((int)(strength * attack / 10)); //hw3E#0 //hw46#moreThinking\n return super.attack(target); //hw3E#0 //hw44#3,4 //hw46#moreThinking\n }", "public void setHitSpeed(double hitSpeed) {\n this.hitSpeed = hitSpeed;\n }", "public L2Character getOverhitAttacker()\n\t{\n\t\treturn overhitAttacker;\n\t}", "public void playerAttack() {\n if (playerTurn==true) {\n myMonster.enemHealth=myMonster.enemHealth-battlePlayer.str;\n }\n playerTurn=false;\n enemyMove();\n }", "public void setHealth(double h){\n health = h;\n }", "private void takeDamage(int damage){ health -= damage;}", "public void attack() {\n\t\t\n\t\tint row = getPosition().getRow();\n\t\tint column = getPosition().getColumn();\n\t\t\n\t\tgetPosition().setCoordinates(row + 1, column);\n\t\tsetPosition(getPosition()) ;\n\t\t// restore health\n\t\tsetHealth(100);\n\t\t// end hunter mode\n\t\tthis.hunter = false;\n\t\t\n\t}", "public void setHitpoints(int hitpoints) throws Exception{\n\t\tif(hitpoints > MAX_HITPOINTS)\n\t\t\tthrow new Exception(\"The value for hitpoints is greater than the value for maximum hitpoints.\");\n\t\tthis.hitpoints = hitpoints;\n\t}", "@Override\n public void hardMode() {\n super.setHP(1800);\n super.getFrontAttack().setBaseDamage(37.5);\n super.getRightAttack().setBaseDamage(37.5);\n super.getBackAttack().setBaseDamage(37.5);\n super.getLeftAttack().setBaseDamage(37.5);\n }", "public void rollStats() {\n\t\tRandom roll = new Random();\n\t\tint rolled;\n\t\tint sign;\n\t\t\n\t\t\n\t\trolled = roll.nextInt(4);\n\t\tsign = roll.nextInt(2);\n\t\tif (sign == 0) {\n\t\t\tsetMaxHealth(getMaxHealth() + rolled*(getDifficulty()+5/5));\n\t\t\tsetHealth(getMaxHealth());\n\t\t} else {\n\t\t\tsetMaxHealth(getMaxHealth() - rolled*(getDifficulty()+5/5));\n\t\t\tsetHealth(getMaxHealth());\n\t\t}\n\t\t\n\t\trolled = roll.nextInt(2);\n\t\tsign = roll.nextInt(2);\n\t\tif (sign == 0) {\n\t\t\tsetAttack(getAttack() + rolled*(getDifficulty()+5/5));\n\t\t} else {\n\t\t\tsetAttack(getAttack() - rolled*(getDifficulty()+5/5));\n\t\t}\n\t\t\n\t\trolled = roll.nextInt(2);\n\t\tsign = roll.nextInt(2);\n\t\tif (sign == 0) {\n\t\t\tsetDefense(getDefense() + rolled*(getDifficulty()+5/5));\n\t\t} else {\n\t\t\tsetDefense(getDefense() - rolled*(getDifficulty()+5/5));\n\t\t}\n\t\t\n\t\trolled = roll.nextInt(2);\n\t\tsign = roll.nextInt(2);\n\t\tif (sign == 0) {\n\t\t\tsetSpeed(getSpeed() + rolled*(getDifficulty()+5/5));\n\t\t} else {\n\t\t\tsetSpeed(getSpeed() - rolled*(getDifficulty()+5/5));\n\t\t}\n\t\t\n\t}", "@Override\n public void easyMode() {\n super.setHP(900);\n super.getFrontAttack().setBaseDamage(18.75);\n super.getRightAttack().setBaseDamage(18.75);\n super.getBackAttack().setBaseDamage(18.75);\n super.getLeftAttack().setBaseDamage(18.75);\n }", "public void calibrated() {\n weaponDamage = weaponDamage + 10;\r\n }", "@Override\r\n public void hitEvent(Block beingHit, Ball hitter) {\n this.currentScore.increase(5);\r\n if (beingHit.getHitPoints() == 1) {\r\n this.currentScore.increase(10);\r\n }\r\n }", "public void takeDamage(int dmg){\r\n this.currHP -= dmg;\r\n }", "private void tooHigh() {\n if (this.hitPoints > 255) {\n System.out.println(\"You set the value too high! Setting it to 255\");\n this.hitPoints = 255;\n }\n }", "@Override\n\tpublic void skill2(Fightable f) {\n\t\tsuper.setDamage(super.getStrength()*2);\n\t\tsuper.setAtkRange((int)(super.getDamage()/10));\n\t\t\n\t\tthis.attack(f, 3);\n\t}", "public void updateHp(double amount);", "public void takeDamage(int damage);", "public void takeDamage(int damage) {\n this.damageTaken += damage;\n }", "public int giveDamage();", "public void setDamage() {\n\t\tRandom rand = new Random();\n\t\tint damage = rand.nextInt(getMaxDamage()) + 1;\n\t\tthis.damage = damage;\n\t}", "public static void hitting(weapon weapon, int howManyTimesYouHit)\n {\n for (int i= 1; i <= howManyTimesYouHit; i++)\n {\n weapon.useCounter();\n weapon.attackDamage();\n }\n }", "@Override\n\tpublic void skill1(Fightable f) {\n\t\tsuper.setDamage(super.getStrength()*3);\n\t\tsuper.setAtkRange((int)(super.getDamage()/5));\n\t\t\n\t\tthis.attack(f, 2);\n\t}", "@Override\r\n public void hitEvent(Block beingHit, Ball hitter) {\n this.currentScore.increase(5);\r\n // and destroying a block is worth and additional 10 points\r\n if (beingHit.getHitPointsNumber() == 0) {\r\n this.currentScore.increase(10);\r\n }\r\n }", "public void hitEvent(Block beingHit, Ball hitter) {\r\n this.currentScore.increase(5);\r\n if (beingHit.getHitPoints() == 0) {\r\n this.currentScore.increase(10);\r\n }\r\n }", "@Override\n protected void applyEntityAttributes() {\n super.applyEntityAttributes();\n this.getEntityAttribute(SharedMonsterAttributes.maxHealth).setBaseValue(100.0);\n }", "public void ability(LevelManager lm){\n\n int prevDamage = lm.player.getDamage();\n int newDamage = prevDamage+12;\n lm.player.setDamage(newDamage);\n }", "public void attack(Player p){\n p.takeDamage(damage);\n }", "public void takeDamage(int dmg){ \r\n\t\tif(hitPoints - dmg >= 0){\r\n\t\t\tSystem.out.print(this.getName() + \" took \" + dmg + \" damage! \\n\");\r\n\t\t\tSystem.out.print(this.name + \"'s Hit Points: \" + hitPoints + \" ---> \" + (hitPoints-dmg) + \"\\n\");\r\n\t\t\thitPoints -= dmg;\r\n\r\n\t\t}\r\n\t\telse{\r\n\t\t\tSystem.out.print(this.getName() + \" took \" + dmg + \" damage! \\n\");\r\n\t\t\tSystem.out.print(this.name + \"'s Hit Points: \" + hitPoints + \" ---> \" + 0 + \"\\n\");\r\n\t\t\thitPoints = 0;\r\n\t\t}\r\n\t\tif(hitPoints == 0){\r\n\t\t\tthis.isAlive = false;\r\n\t\t\tSystem.out.print(this.name + \" has been incapacitated.\\n\");\r\n\t\t}\r\n\r\n\t}", "public void Hit()\n {\n this.numLives--;\n //Oscillate visible and not if the number of lives is greater than zero\n if(this.numLives > 0)\n {\n this.damaged = true;\n this.Blink(1);\n\n }\n }", "public void attack(String spell, character opponent){\n Random rand = new Random();\n int prob;\n String attack;\n \n prob = rand.nextInt(2); //we need two random numbers to allow us to use the two attacks:\n if(prob==0){\n attack = \"punch\";\n opponent.setHealth(opponent.getHealth() - 10);\n System.out.println(getName() + \" has landed \" + attack);\n System.out.println(opponent.getName() + \" health now \" + opponent.getHealth());\n }\n \n else if(prob==1){\n attack = \"kick\";\n opponent.setHealth(opponent.getHealth() - 15);\n System.out.println(getName() + \" has landed \" + attack);\n System.out.println(opponent.getName() + \" health now \" + opponent.getHealth());\n }\n \n \n }", "public void setAttackNum(int attackNum)\n {\n this.attackNum = attackNum;\n }", "public void setWeaponDamage (int weaponDamage)\r\n\t{\r\n\t\tthis.weaponDamage = weaponDamage;\r\n\t}", "protected int extraHits(Conveyer info, Combatant striker, Combatant victim) {\n return 0;\n }", "public int getAttack() { return this.attack; }", "public void attack(ItemWeapon w, Monster target) {\n\t\ttarget.takeDamage(w.getDamage()+level*20);\n\t}", "public void primaryHit(Hit hit) {\n this.setPrimaryHit(hit);\n this.getFlags().flag(Flag.HIT);\n\n if (this instanceof Player) {\n Player player = (Player) this;\n\n player.getSkills().getTrainable()[Skill.HITPOINTS.ordinal()].decreaseLevel(player.getPrimaryHit().getDamage());\n SkillManager.getSingleton().refresh(player, Skill.HITPOINTS);\n }\n }", "public void specialEffect() {\n if (getDefense() > 0) {\n setDefense(0);\n setCurrentHealth(currentHealth + 50);\n }\n\n }", "public void setHp(byte hp){\n this.hp = hp;\n }", "public void setOvertimeHourlyWage(int overtimeHourlyWage) {\n this.overtimeHourlyWage = overtimeHourlyWage;\n }", "public void setStatisticalAdvice(Advice coachAdvice){\n\t\tSystem.out.println(\"Inside setter method\");\n\t\tthis.statisticalAdvice = coachAdvice;\n\t}", "@Override\n public void attack(ArrayList<territories> PlayersTerritories,int bonusArmies ) {\n\n // placeArmy(PlayersTerritories,bonusArmies);\n\n\n territories toAttack=getTerritoryGreedyAttack(PlayersTerritories,0);\n\n territories AttackWith = GetMaximumAttacker(PlayersTerritories,toAttack);\n\n Attacking(toAttack,AttackWith);\n\n\n\n }", "public void setHits(String hits) {\n\t\tthis.hits = hits;\n\t}", "@Override\r\n public void onHit(int damage){\n if(box2body != null){\r\n hp -= damage;\r\n screen.getGameManager().get(\"Sounds/orc-34-hit.wav\", Sound.class).play();\r\n if(this.hp <= 0) {\r\n screen.bodiesToDelete.add(box2body);\r\n deleteFlag = true;\r\n screen.spawnedCreatures.remove(this);\r\n screen.getGameManager().get(\"Sounds/orc-32-death.wav\", Sound.class).play();\r\n\r\n //Award Experience\r\n screen.getPlayer().awardExperience(this.experienceValue);\r\n screen.getPlayer().increaseKillCount();\r\n }\r\n }\r\n //Attack player when damaged\r\n //Prevents player from sniping monsters using Wander AI\r\n if(currentState != State.ATTACKING){\r\n Vector2 orcPosition = new Vector2(box2body.getPosition().x, box2body.getPosition().y);\r\n Vector2 playerPosition = new Vector2(screen.getPlayer().box2body.getPosition().x, screen.getPlayer().box2body.getPosition().y);\r\n\r\n currentState = State.HASBEENATTACKED;\r\n velocity = new Vector2(playerPosition.x - orcPosition.x, playerPosition.y - orcPosition.y);\r\n box2body.setLinearVelocity(velocity.scl(speed));\r\n }\r\n }" ]
[ "0.65316916", "0.64875054", "0.6449281", "0.6423179", "0.64082944", "0.63147247", "0.62927943", "0.6254014", "0.62466556", "0.62349564", "0.623406", "0.6207314", "0.620008", "0.61048466", "0.607237", "0.60505205", "0.6046316", "0.6041021", "0.60337925", "0.59936666", "0.5983699", "0.59715676", "0.59524375", "0.59488374", "0.59392154", "0.59378445", "0.5936829", "0.5904951", "0.5904906", "0.5904853", "0.59037024", "0.58983076", "0.5893639", "0.5892871", "0.58906907", "0.58897614", "0.58645207", "0.5849624", "0.58478886", "0.582995", "0.582995", "0.58182836", "0.5781649", "0.5775049", "0.57628375", "0.57561785", "0.5752543", "0.57517976", "0.57425225", "0.5736498", "0.5721015", "0.5713692", "0.57103086", "0.5705043", "0.57048947", "0.57010865", "0.56993675", "0.56830615", "0.56728", "0.567215", "0.5662617", "0.56622684", "0.5661402", "0.5657955", "0.5657092", "0.56558764", "0.56473744", "0.5644183", "0.5637845", "0.5620224", "0.5612204", "0.5609729", "0.56076086", "0.55994946", "0.55901915", "0.5588018", "0.5585003", "0.5578601", "0.55720496", "0.5566454", "0.55611324", "0.5560535", "0.5555438", "0.55510473", "0.5550607", "0.55368227", "0.5536306", "0.5534713", "0.5532429", "0.55222297", "0.5520176", "0.5519534", "0.55140066", "0.5513213", "0.5509822", "0.54994315", "0.5498515", "0.54967123", "0.5494643", "0.54781234" ]
0.7886039
0
Return the L2Character who hit on the L2Attackable using an overhit enabled skill.
public L2Character getOverhitAttacker() { return overhitAttacker; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public L2Attackable getActiveChar() { return (L2Attackable)super.getActiveChar(); }", "public void attackTargetCharacter() {\n }", "protected Entity findPlayerToAttack()\n {\n EntityPlayer var1 = this.worldObj.getClosestVulnerablePlayerToEntity(this, 16.0D);\n return var1 != null && this.canEntityBeSeen(var1) ? var1 : null;\n }", "protected Skill getNpcSuperiorBuff()\r\n\t{\n\t\treturn getSkill(15649, 1); //warrior\r\n//\t\treturn getSkill(15650, 1); //wizzard\r\n\t}", "@Override\n\tpublic L2CharacterAI getAI()\n\t{\n\t\tif (aiCharacter == null)\n\t\t{\n\t\t\tsynchronized (this)\n\t\t\t{\n\t\t\t\tif (aiCharacter == null)\n\t\t\t\t{\n\t\t\t\t\taiCharacter = new L2AttackableAI(new AIAccessor());\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn aiCharacter;\n\t}", "public int attack(Character target){ //hw3E#0 //hw46#moreThinking\n lowerHP((int)(strength * attack / 10)); //hw3E#0 //hw46#moreThinking\n return super.attack(target); //hw3E#0 //hw44#3,4 //hw46#moreThinking\n }", "private EntityLivingBase findPlayerToAttack() {\n EntityPlayer player = entity.worldObj.getClosestVulnerablePlayerToEntity(entity, aggroRange);\n if ( player != null && !player.capabilities.isCreativeMode && entity.canEntityBeSeen(player) )\n \treturn player;\n\n EntityLivingBase target = entity.getLastAttacker();\n if ( isTargetValid(target) && entity.canEntityBeSeen(target) )\n \treturn target;\n\n \treturn null;\n }", "protected Entity findPlayerToAttack() {\n/* 339 */ double var1 = 8.0D;\n/* 340 */ return getIsSummoned() ? null : this.field_70170_p.func_72890_a(this, var1);\n/* */ }", "@Override\n protected Entity findPlayerToAttack() {\n EntityPlayer player = this.worldObj.getClosestVulnerablePlayerToEntity(this, 64.0);\n if (player != null) {\n if (this.shouldAttackPlayer(player)) {\n if (this.lookDelay++ == 5) {\n this.lookDelay = 0;\n return player;\n }\n }\n else {\n this.lookDelay = 0;\n }\n }\n return null;\n }", "int getIndividualAttack();", "public String attack() {\r\n String res;\r\n currentRoom = player.getCurrentRoom();\r\n if (currentRoom.getAmountOfMonsters() != 0) {\r\n player.setHitPoints(player.getHitPoints() - currentRoom.getMonster(0).getAttackPoints());\r\n currentRoom.getMonster(0).setHitPoints((currentRoom.getMonster(0).getHitPoints() - player.getWeapon().getDamage()));\r\n res = \"You hit a \" + currentRoom.getMonster(0).getName() + \"! It now has \" + currentRoom.getMonster(0).getHitPoints() + \" healthpoints left!\" + System.getProperty(\"line.separator\");\r\n res += \"The \" + currentRoom.getMonster(0).getName() + \" hits you back! You now have \" + player.getHitPoints() + \" healthpoints left!\" + System.getProperty(\"line.separator\");\r\n if (currentRoom.getMonster(0).getHitPoints() < 1) {\r\n String monsterName = currentRoom.getMonster(0).getName();\r\n int gainedXp = currentRoom.getMonster(0).getXp();\r\n player.setXp(player.getXp() + gainedXp);\r\n currentRoom.removeMonster(0);\r\n res += \"You have killed a \" + monsterName + \" and you gain \" + gainedXp + \" xp\" + System.getProperty(\"line.separator\");\r\n res += getMonsterDropsLoot();\r\n }\r\n if (player.getHitPoints() < 1) {\r\n res += \"You died a horrible death!\" + System.getProperty(\"line.separator\");\r\n stop = true;\r\n }\r\n if ((currentRoom.getId() - 1) == dungeon.getEndRoom() && currentRoom.getAmountOfMonsters() < 1) {\r\n res += \"You have completed the dungeon...\";\r\n stop = true;\r\n }\r\n return res;\r\n }\r\n return \"There is no monsters left in the room.\" + System.getProperty(\"line.separator\");\r\n\r\n }", "public String attack() {\r\n\t\t\tthis.getCurrentEnemy().setHealth(this.getCurrentEnemy().getHealth()-this.getPlayer().getWeapon().getAttack());\r\n\t\t\tif(this.getCurrentEnemy().isDefeated()) {\r\n\t\t\t\tthis.setInBattle(false);\r\n\t\t\t\t\r\n\t\t\t\tthis.handleQuestrelatedEnemy(this.getCurrentEnemy());\r\n\t\t\t\t\r\n\t\t\t\tif(this.getCurrentEnemy().getLoot() != null) {\r\n\t\t\t\t\tthis.getPlayer().getCurrentLocation().addItem(this.getCurrentEnemy().getLoot());\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tthis.getPlayer().gainXp(this.getCurrentEnemy().getXpYield());\r\n\t\t\t\tthis.getPlayer().getCurrentLocation().removeNpc(this.getCurrentEnemy().getName());\r\n\t\t\t\tif(this.getCurrentEnemy().getClass().getName().equals(\"game.EnemyGuardian\")) {\r\n\t\t\t\t\t// adds paths between current location and location in the guardian, path names are specified in the guardian construction\r\n\t\t\t\t\tthis.getPlayer().getCurrentLocation().addPaths(this.getPlayer().getCurrentLocation(), ((EnemyGuardian)this.getCurrentEnemy()).getPathTo(),\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t((EnemyGuardian)this.getCurrentEnemy()).getGuardedLocation(), ((EnemyGuardian)this.getCurrentEnemy()).getPathFrom());\r\n\t\t\t\t\treturn \"You defeated \" + this.getCurrentEnemy().getName() + \". \\n\"\r\n\t\t\t\t\t\t\t+ ((EnemyGuardian)this.getCurrentEnemy()).getRevelationMessage() + \"\\n\";\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\treturn \"You defeated \" + this.getCurrentEnemy().getName() + \".\";\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\tthis.triggerEnemyAttack();\r\n\t\t\t\t\tif(this.getPlayer().getHealth() <= 0) {\r\n\r\n\t\t\t\t\t\tthis.gameOver();\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\treturn \"You attacked \" + this.getCurrentEnemy().getName() + \" for \" + this.getPlayer().getWeapon().getAttack() + \" damage. \\n You DIED.\";\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse {\r\n\t\t\t\t\t\treturn \"You attacked \" + this.getCurrentEnemy().getName() + \" for \" + this.getPlayer().getWeapon().getAttack() + \" damage. \\n\"\r\n\t\t\t\t\t\t\t\t+ this.getCurrentEnemy().getName() + \" attacked you for \" + this.getCurrentEnemy().getAttack() + \" damage.\\n\"\r\n\t\t\t\t\t\t\t\t\t\t+ this.getCurrentEnemy().printHealth();\r\n\t\t\t\t\t}\r\n\t\t\t}\r\n\t\t}", "public L2Character getMostHated()\n\t{\n\t\tif (getAggroListRP().isEmpty() || isAlikeDead())\n\t\t{\n\t\t\treturn null;\n\t\t}\n\t\t\n\t\tL2Character mostHated = null;\n\t\t\n\t\tint maxHate = 0;\n\t\t\n\t\t// While Interating over This Map Removing Object is Not Allowed\n\t\tsynchronized (getAggroList())\n\t\t{\n\t\t\t// Go through the aggroList of the L2Attackable\n\t\t\tfor (final AggroInfoHolder ai : getAggroListRP().values())\n\t\t\t{\n\t\t\t\tif (ai == null)\n\t\t\t\t{\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (ai.getAttacker().isAlikeDead() || !getKnownList().knowsObject(ai.getAttacker()) || !ai.getAttacker().isVisible() || ai.getAttacker() instanceof L2PcInstance && !((L2PcInstance) ai.getAttacker()).isOnline() && !((L2PcInstance) ai.getAttacker()).isInOfflineMode()) // if player go\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// in offline\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// mode, he\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// must be hated\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// however\n\t\t\t\t{\n\t\t\t\t\tai.initHate();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (ai.getHate() > maxHate)\n\t\t\t\t{\n\t\t\t\t\tmostHated = ai.getAttacker();\n\t\t\t\t\tmaxHate = ai.getHate();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (mostHated != null)\n\t\t{\n\t\t\tthis.mostHated = mostHated;\n\t\t}\n\t\t\n\t\treturn mostHated;\n\t}", "AbilityTarget getAbilityTarget();", "public int getAttack() {\n return base.getAttack();\n }", "public double getOverhitDamage()\n\t{\n\t\treturn overhitDamage;\n\t}", "CharacterInfo getCharacter();", "public void actionCombat(Party p1) {\n System.out.println(\"______________________________________________________________________________\\n\");\n System.out.println(this.Name + \" is attacking ...\");\n int choice = (int)(Math.random() * p1.getTeam().size());\n Character target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n\n if (this.SPEED - target.getSPEED() < 5) {\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n }\n else {\n int n = 0;\n while ((target.actualHP != 0) && (n < 2)) {\n if (n == 1) {\n choice = (int)(Math.random() * p1.getTeam().size() + 1);\n target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n }\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n if (n == 0) System.out.println(this.Name + \" attacks again ...\");\n n++;\n }\n }\n }", "@Override\n\tpublic int attack( ){\n\t\treturn enemy.attack();\n\t}", "void basicAttack(Character attacked);", "public String getAsteroidAttack() {\n\t\tminusShield(2);\n\t\treturn \"Got damaged from the asteroid belt!!\";\n\t}", "public Attack getBestOpponentAttack()\n\t{\n\t\treturn bestOpponentAttack;\n\t}", "public Attack getAttack(int cellID) {\n\t\treturn attacks[cellID];\n\t}", "@Override\r\n\tpublic void attack(DungeonCharacter that)\r\n\t{\n\t}", "public int getAttack() {\r\n\t\treturn attack;\r\n\t}", "public int getAttack() { return this.attack; }", "public void getAttackedByDarknessMagicBook(IEquipableItem item){item.strongAttackTo(this.getOwner());}", "public int getAttack() {\n\t\treturn attack;\n\t}", "public int getAttack() {\n\t\treturn attack;\n\t}", "public AStarCharacter getMyCharacter()\r\n\t{\r\n\t\treturn theGridView.getMyCharacter();\r\n\t}", "@Override\n\tpublic void takeHit(int attack) {\n\n\t}", "@java.lang.Override\n public int getIndividualAttack() {\n return individualAttack_;\n }", "public boolean getAttack(IEntity enemyUnit){\n return tempUnit.getAttack(enemyUnit);\n }", "@Override\n\tpublic double getAttack() {\n return attack;\n\t}", "String attack();", "public int getAttackLevel() {\r\n\t\treturn attackLevel;\r\n\t}", "AbilityDamage getAbilityDamage();", "public Battleable getOpponent()\n\t{\n\t\t/* TODO: Inherited function from Character Interface, requires implementation! */\n\t\treturn null;\n\t}", "CharacterStatistic getCharacterStatistic();", "public char displayHitStatus(){\r\n if(hit){\r\n if(ship != null){\r\n if(ship.isSunk()){\r\n return SUNK_SHIP_SECTION;\r\n }else{\r\n return HIT_SHIP_SECTION;\r\n }\r\n }else{\r\n return HIT_WATER;\r\n }\r\n }else{\r\n return PRISTINE_WATER;\r\n }\r\n }", "public char displayChar(){\r\n if(hit){\r\n if(ship != null){\r\n if(ship.isSunk()){\r\n return SUNK_SHIP_SECTION;\r\n }else{\r\n return HIT_SHIP_SECTION;\r\n }\r\n }else{\r\n return HIT_WATER;\r\n }\r\n }else {\r\n if (ship == null) {\r\n return PRISTINE_WATER;\r\n }else{\r\n return HIDDEN_SHIP_SECTION;\r\n }\r\n }\r\n }", "@java.lang.Override\n public int getIndividualAttack() {\n return individualAttack_;\n }", "AttackResult userAttack();", "public Position attackCell() {\n if (this.strategy == null) {\n return null;\n } else {\n return this.strategy.generateAttackPosn(this.battleMap);\n }\n }", "public boolean isOverhit()\n\t{\n\t\treturn overhit;\n\t}", "CharacterStatistic getBasedOn();", "public static Image attackPoint()\n\t{\n\t\treturn attackPoint;\n\t}", "public double getAttack() {\n return attack;\n }", "public void attack();", "public String attack(String input, boolean playerAttack) {\n\n String result = \" You didn't die\";\n\n int damage = 0;\n\n if (input.toCharArray().length == 1 && playerAttack) {\n\n switch (input.toCharArray()[0]) {\n\n case '1': damage = calculateCharacterDamage(player, 0);\n monster.setHealth(monster.getHealth() - damage);\n result = \" You hit \" + monster.getName() + \" for \" + damage + \"!\";\n break;\n\n case '2': damage = calculateCharacterDamage(player, 1);\n monster.setHealth(monster.getHealth() - damage);\n result = \" You hit \" + monster.getName() + \" for \" + damage + \"!\";\n break;\n\n case '3': damage = calculateCharacterDamage(player, 2);\n monster.setHealth(monster.getHealth() - damage);\n result = \" You hit \" + monster.getName() + \" for \" + damage + \"!\";\n break;\n\n }\n\n }\n else if (input.toCharArray().length == 1 && !playerAttack) {\n\n damage = calculateCharacterDamage(monster, 0);\n\n player.setHealth(player.getHealth() - damage);\n\n result = \"\\n \" + monster.getName() + \" hit you for \" + damage + \"!\";\n\n }\n\n if (player.getHealth() == 0)\n {\n win = monster;\n lose = player;\n try {\n combatdb.addCombat(player.getName(), monster.getName(), monster.getName());\n }\n catch(Exception e)\n {\n System.err.println(e);\n }\n }\n else if (monster.getHealth() == 0)\n {\n win = player;\n lose = monster;\n try {\n combatdb.addCombat(player.getName(), monster.getName(), player.getName());\n }\n catch(Exception e)\n {\n System.err.println(e);\n }\n }\n\n return result + \"\\n\";\n\n }", "public boolean getHitOrSplat() {\n return currentlyAbilityHit;\n }", "@Override\r\n\tpublic int attack() {\r\n\t\treturn rnd.nextInt(MAX_MONSTER_ATTACK_DAMAGE);\r\n\t}", "public int getCharacter() {\n return getStat(character);\n }", "private Attack consoleGetAttack(int player) {\n int row, col;\n System.out.println(\"Player \" + player + \", it is your turn to attack.\");\n while (true) {\n\t while (true) {\n\t System.out.print(\"Row (0 through 9): \");\n\t row = scan.nextInt();\n\t if (row < 0) continue;\n\t if (row > 9) continue;\n\t break;\n\t }\n\t while (true) {\n\t System.out.print(\"Column (0 through 9): \");\n\t col = scan.nextInt();\n\t if (col < 0) continue;\n\t if (col > 9) continue;\n\t break;\n\t }\n\t if (grids[1].peek(row, col) != Grid.UNKNOWN) continue;\n\t break;\n }\n return new Attack(row, col);\n }", "int attack(Unit unit, Unit enemy);", "@Override\n public void onPlayerAttacksOther(LivingAttackEvent event, EntityPlayer victim, @Nonnull ItemStack armorStack, EntityEquipmentSlot slot) {\n DamageSource source = event.getSource();\n Entity sourceEntity = source.getTrueSource();\n if (sourceEntity instanceof EntityLivingBase && !source.isExplosion()) {\n EntityLivingBase entity = (EntityLivingBase) sourceEntity;\n World world = entity.world;\n ItemStack chest = entity.getItemStackFromSlot(EntityEquipmentSlot.CHEST);\n if (entity.getHeldItemMainhand().isEmpty() && entity.isSneaking() &&\n chest.getItem() instanceof ItemSteamExosuitArmor && chest.hasTagCompound()) {\n int consumption = (chest.getTagCompound().getInteger(\"SteamCapacity\") / 2) + ArmorModule.dragonRoarConsumption;\n if (ChargableUtility.hasPower(entity, consumption)) {\n if (world.isRemote) {\n world.playSound(entity.posX, entity.posY, entity.posZ,\n SoundEvents.ENTITY_ENDERDRAGON_GROWL, SoundCategory.PLAYERS, 5.0F,\n 0.8F + world.rand.nextFloat() * 0.3F, false);\n } else {\n world.createExplosion(entity, entity.posX + 0.5F, entity.posY,\n entity.posZ + 0.5F, 10.0F, false);\n }\n ChargableUtility.drainSteam(chest, consumption, entity);\n }\n }\n }\n }", "@Override\n public void attack() {\n\n }", "public BasicCharacter getLoser() {\n\n return lose;\n\n }", "public int getAtk()\r\n {\r\n return attack;\r\n }", "int hit();", "public void attack() {\n energy = 2;\n redBull = 0;\n gun = 0;\n target = 1;\n // if Player is in range take off a life.\n if (CharacterTask.ghostLocation == GameWindow.playerLocation) {\n playerLives = playerLives - 1;\n System.out.println(\"Player Lives: \" + playerLives);\n }\n }", "public Character getOpponent() {\n Character result = null;\n if (this.enemies.getAdversaries().size() > 0) {\n Collections.shuffle(this.enemies.getAdversaries());\n result = this.enemies.getAdversaries().get(0);\n this.enemies.getAdversaries().remove(result);\n }\n return result;\n }", "public String getStandUser(ItemStack stack) {\n/* 204 */ NBTTagCompound nbttagcompound = stack.getTagCompound();\n/* */ \n/* 206 */ if (nbttagcompound == null)\n/* */ {\n/* 208 */ return \"\";\n/* */ }\n/* */ \n/* */ \n/* 212 */ NBTTagCompound nbttagcompound1 = nbttagcompound.getCompoundTag(this.standInfo);\n/* 213 */ return (nbttagcompound1 == null) ? \"\" : (nbttagcompound1.hasKey(this.standUser) ? nbttagcompound1.getString(this.standUser) : \"\");\n/* */ }", "@Override\n\tvoid attack() {\n\n\t}", "@Override\n public Enemy getEnemyPlayer() {\n return batMan.getEnemyPlayer();\n }", "@Override\r\n\tpublic void Attack(Player arg0, Player arg1) {\n\t\t\r\n\t}", "@Override\r\n\tpublic void Attack(Player arg0, Player arg1) {\n\t\t\r\n\t}", "public int rollAttack()\n {\n Random random2 = new Random();\n int atk = random2.nextInt(20) +1 + attackBonus;\n return atk;\n }", "public Integer getOpponentAttacks()\n\t{\n\t\treturn opponentAttacks;\n\t}", "@Override\n public void useSkill(Creature activeChar, Creature targets) {\n }", "@Override\n public void attack(){\n\n }", "@Override\n\tpublic void attack() {\n\t\t\n\t}", "public static short getModFromSkill( CreatureTemplate ctr, String skillName )\n {\n\n // Charisma based skills\n if( \"Bluff\".equals( skillName ) || \"Diplomacy\".equals( skillName ) || \"Intimidate\".equals( skillName ) || \"Streetwise\".equals( skillName ) )\n {\n return (short)((ctr.getAbilityScore( D20Rules.Ability.CHA ) - 10) / 2);\n }\n\n // Constitution based skills\n if( \"Endurance\".equals( skillName ) )\n {\n return (short)((ctr.getAbilityScore( D20Rules.Ability.CON ) - 10) / 2);\n }\n\n // Dex based skills\n if( \"Acrobatics\".equals( skillName ) || \"Stealth\".equals( skillName ) || \"Thievery\".equals( skillName ) )\n {\n return (short)((ctr.getAbilityScore( D20Rules.Ability.DEX ) - 10) / 2);\n }\n\n // Int based skills\n if( \"Arcana\".equals( skillName ) || \"History\".equals( skillName ) || \"Religion\".equals( skillName ) )\n {\n return (short)((ctr.getAbilityScore( D20Rules.Ability.INT ) - 10) / 2);\n }\n\n // STR based skills\n if( \"Athletics\".equals( skillName ) )\n {\n return (short)((ctr.getAbilityScore( D20Rules.Ability.STR ) - 10) / 2);\n }\n // WIS based skills\n if( \"Dungeoneering\".equals( skillName ) || \"Heal\".equals( skillName ) || \"Insight\".equals( skillName ) || \"Nature\".equals( skillName )\n || \"Perception\".equals( skillName ) )\n {\n return (short)((ctr.getAbilityScore( D20Rules.Ability.WIS ) - 10) / 2);\n }\n\n return -10; // Skill not found in list\n }", "public void attack(String spell, character opponent){\n Random rand = new Random();\n int prob;\n String attack;\n \n prob = rand.nextInt(2); //we need two random numbers to allow us to use the two attacks:\n if(prob==0){\n attack = \"punch\";\n opponent.setHealth(opponent.getHealth() - 10);\n System.out.println(getName() + \" has landed \" + attack);\n System.out.println(opponent.getName() + \" health now \" + opponent.getHealth());\n }\n \n else if(prob==1){\n attack = \"kick\";\n opponent.setHealth(opponent.getHealth() - 15);\n System.out.println(getName() + \" has landed \" + attack);\n System.out.println(opponent.getName() + \" health now \" + opponent.getHealth());\n }\n \n \n }", "public String attackTo(PlayerToken trg){\n\t\tString outcome = super.attackTo(trg);\n\t\t//if attack on Trap, lose:\n\t\tif(trg instanceof Trap){\n\t\t\toutcome = new String(\"won\");\n\t\t}\n\t\treturn outcome;\n\t}", "@Override\n\tpublic void attack() {\n\n\t}", "public int getCurAttack() {\n\t\treturn curAttack;\n\t}", "@Override\n\tpublic void attack() {\n\t}", "int getAttackRoll();", "int getAttackRange();", "public float getAttackCooldown ( ) {\n\t\treturn extract ( handle -> handle.getAttackCooldown ( ) );\n\t}", "default void onHitPlayer(@NotNull String name, int damage) {}", "@Override\n\tpublic void skill2(Fightable f) {\n\t\tsuper.setDamage(super.getStrength()*2);\n\t\tsuper.setAtkRange((int)(super.getDamage()/10));\n\t\t\n\t\tthis.attack(f, 3);\n\t}", "public Character pickOpponent()\n {\n int oppIndex = random.nextInt(characterList.size());\n opponent = characterList.get(oppIndex);\n return opponent;\n }", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "public BasicCharacter getWinner() {\n\n return win;\n\n }", "public String attack(Entity e) {\n return super.attack(e) + \"\\n\" + super.attack(e);\n }", "@Override\n\tpublic ArrayList<Unit> useSkill() {\n\t\tArrayList<Unit> canExit = new ArrayList<Unit>();\n\t\tGameBoard gameBoard = GameController.gameBoard;\n\t\tfor (int i = 0; i < gameBoard.getWidth(); i++) {\n\t\t\tfor (int j = 0; j < gameBoard.getHeight(); j++) {\n\t\t\t\tif (gameBoard.getUnit(i, j) instanceof Defender) {\n\t\t\t\t\tdef = (Defender) gameBoard.getUnit(i, j);\n\t\t\t\t\tif (def.getCaptureUnit() == null) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tif (def.getCaptureUnit() instanceof Silva) {\n\t\t\t\t\t\tfor (Unit u: gameBoard.getAdjacentUnit(i, j)) {\n\t\t\t\t\t\t\tif (u instanceof Empty) {\n\t\t\t\t\t\t\t\tcanExit.add(u);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\treturn canExit;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn canExit;\n\t}", "public String getSkill() {\n\t\treturn skill;\n\t}", "public Enemy getEnemy(int whichEnemy);", "public BaseSweetWord getMyCharacter(String character) {\n\t\tBaseSweetWord mychar = pool.get(character);//享元的关键实现\n\t\tif(mychar == null){\n\t\t\tmychar = new SpecialSweetWord(character);\n\t\t\tpool.put(character, mychar);\n\t\t}\n\t\t\n\t\treturn mychar;\n\t\t\n\t}", "AttackResult randomAttack();", "CharacterEntity getOpponent() {\n return opponent;\n }", "public int getAttack(){\r\n return attack;\r\n }", "@Override\r\n\tpublic String attack(int damage) {\n\t\treturn damage +\"로 공격 합니다.\";\r\n\t}", "Skill getSkill(String name);", "public Integer getAttackWins()\n\t{\n\t\treturn attackWins;\n\t}", "public void attack() {\n\n }", "public Warrior checkWarrior(){\n Object obj=charactersOccupiedTheLocation[0];\n if(obj!=null){\n return (Warrior)obj;\n }\n return null;\n }", "public abstract void attack(Vector2 spawnPos, Vector2 target);" ]
[ "0.6737502", "0.60612655", "0.57957137", "0.5725078", "0.56201184", "0.5612858", "0.55523247", "0.54997015", "0.54799134", "0.54765344", "0.5424988", "0.5410128", "0.53980947", "0.5387573", "0.5366997", "0.5364826", "0.53529054", "0.53452754", "0.5315492", "0.5262496", "0.52533025", "0.52461183", "0.52282006", "0.5221583", "0.5183304", "0.5180706", "0.51784605", "0.51428473", "0.51428473", "0.5117339", "0.51156193", "0.5115051", "0.51088876", "0.5099707", "0.5093514", "0.5089978", "0.5089893", "0.50815666", "0.50580573", "0.50554585", "0.50515056", "0.5042176", "0.50280255", "0.5025476", "0.49951482", "0.4984905", "0.49711815", "0.4957181", "0.49503386", "0.4946839", "0.4938279", "0.4934864", "0.49289817", "0.4922401", "0.49154392", "0.49145305", "0.4910449", "0.49067944", "0.49064362", "0.48953965", "0.48899087", "0.48853746", "0.48734084", "0.48718572", "0.48712632", "0.4867726", "0.4867726", "0.4866283", "0.486337", "0.48596883", "0.48514876", "0.48500982", "0.4837152", "0.48363838", "0.48361748", "0.48345244", "0.4833555", "0.48216432", "0.4821228", "0.48199984", "0.48001334", "0.4795508", "0.4791285", "0.4785699", "0.4782854", "0.4775562", "0.47753236", "0.477338", "0.47718522", "0.47710958", "0.47702622", "0.47697416", "0.47605908", "0.47499192", "0.47472832", "0.4743483", "0.4742383", "0.4736191", "0.47350177", "0.4734134" ]
0.72026527
0
Return the ammount of damage done on the L2Attackable using an overhit enabled skill.
public double getOverhitDamage() { return overhitDamage; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int calculateAttack() {\n int attack = 0;\n for (Weapon w : equippedWeapons) {\n attack += w.getType().getDamage();\n }\n return attack;\n }", "public int computeDamageTo(Combatant opponent) { return 0; }", "public int getDamageTaken() {\n return this.damageTaken;\n }", "int getDamage();", "int getDamage();", "int getDamage();", "int getDamage();", "int getDamage();", "public int getAttackStrength(Entity par1Entity)\n {\n ItemStack var2 = this.getHeldItem();\n int var3 = 5;\n\n\n return var3;\n }", "public int giveDamage();", "@Override\n public double getDamageAmount() {\n return this.getStrength().getAbilityValue();\n }", "public int getDamageTaken () {\r\n\t\treturn this.damageTaken;\r\n\t}", "AbilityDamage getAbilityDamage();", "int getSuperEffectiveChargeAttacksUsed();", "@Override\n public int damage() {\n int newDamage=criticalStrike();\n return newDamage;\n }", "@Override\n public int doDamage() {\n if (difficulty <5)\n return damage;\n else \n return damage*2;\n }", "public int computeRangedDamageTo(Combatant opponent) { return 0; }", "public int getDamage() {\n \t\treturn damage + ((int) 0.5*level);\n \t}", "public short getSiegeWeaponDamage();", "int getBonusHP();", "public int getWeaponDamage() {\n return Math.round(type.getWeaponDamage()*type.getItemLevelMultipliers()\n\t\t\t\t[level - 1]);\n }", "public long calculateOverhitExp(final long normalExp)\n\t{\n\t\tdouble overhitPercentage = getOverhitDamage() * 100 / getMaxHp();\n\t\t\n\t\t// Over-hit damage percentages are limited to 25% max\n\t\tif (overhitPercentage > 25)\n\t\t{\n\t\t\toverhitPercentage = 25;\n\t\t}\n\t\t\n\t\t// Get the overhit exp bonus according to the above over-hit damage percentage\n\t\t// (1/1 basis - 13% of over-hit damage, 13% of extra exp is given, and so on...)\n\t\tfinal double overhitExp = overhitPercentage / 100 * normalExp;\n\t\t\n\t\t// Return the rounded ammount of exp points to be added to the player's normal exp reward\n\t\tfinal long bonusOverhit = Math.round(overhitExp);\n\t\t\n\t\treturn bonusOverhit;\n\t}", "public int getDamage() {\n //TODO\n return 1;\n }", "@Override\n\tpublic int calculateDamage() \n\t{\n\t\t// TODO Auto-generated method stub\n\t\treturn 0;\n\t}", "public int getAttackStrength(Entity var1)\n {\n return 2;\n }", "int getAttackRoll();", "public int getAttackLength() {\r\n\t\treturn attackLength;\r\n\t}", "public double attack(Legendary other) {\n double effectiveness = getTypeEffectiveness(other);\n double dmg = computeDamage(effectiveness);\n String attackStatus = Mokedex.getAttackStatus(effectiveness);\n \n LockFactory.getLock(\"mok\").lock();\n other.hp -= dmg;\n System.out.println(name + \" dealt \" + dmg + \"HP to \" + other.name + \"!\\n\");\n System.out.println(attackStatus);\n other.display();\n System.out.println(other.name + \" has \" + Math.max(0, other.hp) + \" remaining health.\\n\");\n if (other.hasFainted()) {\n System.out.println(other.name + \" has fainted!\\n\");\n }\n LockFactory.getLock(\"mok\").unlock();\n other.takeRevenge(this);\n\n return dmg;\n }", "public int attack()\n {\n int percent = Randomizer.nextInt(100) + 1;\n int baseDamage = super.attack();\n if(percent <= 5)\n {\n baseDamage *= 2;\n baseDamage += 50;\n }\n return baseDamage;\n }", "@Override\n\tpublic int calculateCustomDamageTaken(Entity attacker, Entity defender, int damage, int attackType) {\n\t\treturn damage;\n\t}", "public int getEquippedWeaponDamage() {\n return 0;\n }", "public int rollAttack()\n {\n Random random2 = new Random();\n int atk = random2.nextInt(20) +1 + attackBonus;\n return atk;\n }", "public int getDamage() {\n\t\treturn (int) (Math.random() * damageVariance) + damage;\n\t}", "private double enemyKills()\n {\n return (double)enemyResult.shipsLost();\n }", "public int attack(Weapon byWeapon) {\n\t\treturn byWeapon.getDamage();\n\t}", "public int getNumAttacked() {\n return this.numAttacked;\n }", "public void damage(int damageTaken) {\n //TODO: Create specific damage methods instead of damage calls everywhere(see damagedByBullet())\n if (!invincible) {\n this.hp -= damageTaken;\n }\n }", "public float getHungerDamage();", "public int getAttackLevel() {\r\n\t\treturn attackLevel;\r\n\t}", "@Override\n public void attackedByPaladin(double attack) {\n this.attack += (2 * attack) / 3;\n damageCounter = Math.max(damageCounter - (2 * attack) / 3, 0);\n }", "private int attack(int chance, int additionalDamage) {\n if (diceRoll(10) <= chance) { //A statement where we call a diceRoll, if we hit under or equals the chance to hit, we calculate the damage\n int attackValue = player.getAttackValue() * (diceRoll(4) + additionalDamage); //Here we get the players attackValue, which then gets multiplied by a diceRoll + the additionalDamage from the chosen attack\n int damageDealt = 0;\n if (attackValue >= opponent.getArmor()) { //We check if our attackValue is greater than or equals to the opponents armor. If it is not, we don't deal any damage.\n damageDealt = (attackValue - opponent.getArmor()) + 1; //If we attack through the opponents armor, we deal the remaining damage + 1. (if we deal 1 damage and opponent has 1 armor, we still deal 1 damage)\n opponent.changeHealth(damageDealt * -1); //Changes the opponents health\n }\n return damageDealt;\n }\n return -1;\n }", "public int getHardHits(){\n\t\treturn hardhit;\n\t}", "public int getDamage () {\n\t\treturn (this.puissance + stuff.getDegat());\n\t}", "int getMinigameDefenseChancesLeft();", "private static int playerDamageDealt(int playerAttack, int monsterDefense){\r\n int playerDamageDealt;\r\n playerDamageDealt = (playerAttack - monsterDefense);\r\n return playerDamageDealt;\r\n }", "public int calculateDamage(Player enemyPlayer)\n\t{\n\t\tint damage = 0;\n\t\tPokemon enemyPokemon = enemyPlayer.getActivePokemon();\n\t\tif(enemyPokemon.getClass() == FirePokemon.class)\n\t\t{\n\t\t\tdamage = move.getBaseDamage() * 2;\n\t\t}\n\t\tif(enemyPokemon.getClass() == GrassPokemon.class)\n\t\t{\n\t\t\tdamage = (int)Math.round((move.getBaseDamage() * .5));\n\t\t}\n\t\tif(enemyPokemon.getClass() == WaterPokemon.class)\n\t\t{\n\t\t\tdamage = move.getBaseDamage();\n\t\t}\n\t\treturn damage;\n\t}", "public int attackRoll(){\r\n\t\treturn (int) (Math.random() * 100);\r\n\t}", "@Override\n public void attackedByShaman(double attack) {\n damageCounter += (2 * attack) / 3;\n this.attack = Math.max(this.attack - (2 * attack) / 3, 0);\n }", "public int attackRoll(int hitRate, int missRate, int critRate){\r\n\t\treturn (int) (Math.random() * (hitRate + critRate + missRate));\r\n\t}", "@Override\n\tpublic double getAttack() {\n\t\treturn 0;\n\t}", "public Integer getOpponentAttacks()\n\t{\n\t\treturn opponentAttacks;\n\t}", "public int getManaIncreasePerLevel() {\r\n if (_index == 3 || _index == 11 || _index == 6 || _index == 14) {\r\n // Acolytes, High Priests, Druids, or High Druids\r\n return 1;\r\n } else if (isSpellCaster()) {\r\n return 2;\r\n }\r\n return 0;\r\n }", "float getBonusPercentHP();", "public int losses(String team) {\n\n return 0;\n }", "private void takeDamage(int damage){ health -= damage;}", "public short getHandThrowDamage();", "public int takeDamage(Enemy enemy)\n {\n int damage = Items.determineDamage(\n enemy.getWeapon(),\n this.getArmor(),\n enemy.fight()\n );\n this.setHealth(this.getHealth() - damage);\n return damage;\n }", "public int attack(Spell bySpell) {\n\t\tsetMana(getMana() - bySpell.getManaCost());\n\t\treturn bySpell.getDamage();\n\t}", "@Override\n public int viability() {\n int[] newStats = getNewStats();\n return newStats[0] * newStats[1];\n }", "public void takeDamage(int damage) {\n this.damageTaken += damage;\n }", "public int getAttack() { return this.attack; }", "public int getDamage() {\n return damage_;\n }", "public int getDamage() {\n return damage_;\n }", "public int getDamage() {\n return damage_;\n }", "public int getDamage() {\n return damage_;\n }", "public int getDamage() {\n return damage_;\n }", "public int getWeaponDamage()\n {\n \t\treturn mystuff.getWepDmg();\n }", "@Override\r\n\tpublic int attack() {\r\n\t\treturn rnd.nextInt(MAX_MONSTER_ATTACK_DAMAGE);\r\n\t}", "public int getBonusHP() {\n return bonusHP_;\n }", "public int getAttackPower() {\n return attackPower;\n }", "public int getDamage() {\r\n\t\treturn damage;\r\n\t}", "protected void takeDamage(int damage)\n {\n health = health - damage;\n \n }", "public int getDamage() {\r\n\t\treturn myDamage;\r\n\t}", "public void hurt(int damage)\n {\n \t hp -= (damage - ( damage * armor / 100 ));\n \t //System.out.println(\"hp: \" + hp);\n }", "public int attack(Character target){ //hw3E#0 //hw46#moreThinking\n lowerHP((int)(strength * attack / 10)); //hw3E#0 //hw46#moreThinking\n return super.attack(target); //hw3E#0 //hw44#3,4 //hw46#moreThinking\n }", "public int getDamage() {\n return damage_;\n }", "public int getDamage() {\n return damage_;\n }", "public int getDamage() {\n return damage_;\n }", "public int getDamage() {\n return damage_;\n }", "public int getDamage() {\n return damage_;\n }", "public int getDamage()\n\t{\n\t\treturn Damage;\n\t}", "private static int monsterDamageDealt(int monsterAttack, int playerDefense){\r\n int monsterDamageDealt;\r\n monsterDamageDealt = (monsterAttack - playerDefense);\r\n if(monsterDamageDealt < 0){\r\n monsterDamageDealt = 0;\r\n return monsterDamageDealt;\r\n }else{\r\n return monsterDamageDealt;\r\n }\r\n }", "public int getAttack() {\n return base.getAttack();\n }", "public int getDamage() {\n return damage;\n }", "public void takeDamage(int damage);", "public int getBonusHP() {\n return bonusHP_;\n }", "public int getHealthGain();", "public int getTotalOfdefeats() {\n return statistics.get(TypeOfGames.SIMGAME).getNumberOfDefeats()\n + statistics.get(TypeOfGames.EASYCOMPUTERGAME).getNumberOfDefeats()\n + statistics.get(TypeOfGames.HARDCOMPUTERGAME).getNumberOfDefeats();\n }", "public int getDamage() {\n\t\treturn this.damage;\n\t}", "public Integer getAttackWins()\n\t{\n\t\treturn attackWins;\n\t}", "@Override\r\n\tpublic void useSkill() {\n\t\tthis.defense+=20;\r\n\t\tthis.maxHp+=(this.maxHp/2);\r\n\t\tthis.hp+=(this.hp/2);\r\n\t\tthis.skillActive = true;\r\n\t\tthis.skillLast = 2;\r\n\t}", "public void handleAttack(int damage) {\n this.health -= damage;\n }", "@Override\n\tpublic float desireability() {\n\t\tAgentSpace agentSpace = Blackboard.inst().getSpace(AgentSpace.class, _obj.getName());\n\t\tMap<String,FoodEntry> map = agentSpace.getScentMemories().getFirst();\n\t\tif (map == null || map.size() == 0) { \n\t\t\t// we don't smell anything\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tAgentSpace space = Blackboard.inst().getSpace(AgentSpace.class, _obj.getName());\n\t\tBoundedEntry bounded = space.getBounded(Variable.energy);\n\t\tfloat pct = bounded.getValue() / bounded.getMax();\n\t\treturn 1 - (pct*pct);\n\t}", "@Override\n public int getEffectiveDamage(Hero hero){\n return (hero.getDex() + hero.getBonusDex()) * 2 + this.damage;\n }", "public double getAttack() {\n return attack;\n }", "public float getAttackCooldown ( ) {\n\t\treturn extract ( handle -> handle.getAttackCooldown ( ) );\n\t}", "@Override\r\n\tpublic String attack(int damage) {\n\t\treturn damage +\"로 공격 합니다.\";\r\n\t}", "public int getHealthCost();", "public int basicAttack() {\n\t\t// lots of logic\n\t\treturn 5;\n\t}", "int getIndividualAttack();" ]
[ "0.6874811", "0.684529", "0.66867", "0.66321605", "0.66321605", "0.66321605", "0.66321605", "0.66321605", "0.6574335", "0.6573438", "0.6572234", "0.6554478", "0.6525842", "0.6521919", "0.651336", "0.6508497", "0.6485581", "0.6485506", "0.6451041", "0.6433585", "0.6410862", "0.63981694", "0.638245", "0.6372148", "0.6358784", "0.6356241", "0.63467586", "0.63106924", "0.63089824", "0.629084", "0.6290254", "0.6278197", "0.6270559", "0.62661827", "0.62609804", "0.6259395", "0.62497807", "0.62145406", "0.6200741", "0.6198008", "0.6147843", "0.61453766", "0.61404115", "0.6135555", "0.61209184", "0.61121786", "0.6092604", "0.6087131", "0.60732156", "0.6069191", "0.60682607", "0.60680085", "0.6040358", "0.6026132", "0.60235", "0.601387", "0.60124576", "0.60024977", "0.6001173", "0.5997483", "0.5994025", "0.59937215", "0.59937215", "0.59937215", "0.59937215", "0.59937215", "0.5990695", "0.59817", "0.59711355", "0.59684634", "0.5965426", "0.5964018", "0.5960039", "0.5959224", "0.5953323", "0.59533083", "0.59533083", "0.59533083", "0.59533083", "0.59533083", "0.59335774", "0.59298795", "0.59258157", "0.5922842", "0.5920914", "0.5919579", "0.59181684", "0.5915167", "0.59027666", "0.5902535", "0.5893874", "0.5892741", "0.5890898", "0.5870636", "0.58705", "0.5869195", "0.5864275", "0.585021", "0.58408225", "0.5834356" ]
0.72050834
0
Return True if the L2Attackable was hit by an overhit enabled skill.
public boolean isOverhit() { return overhit; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean canHit() {\n\t\treturn this.hand.countValue().first() < 17;\n\t}", "boolean isGameOver() {\n\t\treturn Hit;\n\t}", "public boolean attackAlly(Ally target) {\n\t\tLog.d(TAG, \"Attacking!\");\n\t\tif (target.takeDamage(damage)) {\n\t\t\treturn true;\n\t\t} else\n\t\t\treturn false;\n\t}", "public boolean isOver() {\n\t\treturn over;\n\t}", "public boolean isBonusShotAllowed() {\n\t\treturn isLastFrame() && (isStrike() || isSpare());\n\t}", "public boolean isOver() {\r\n return isOver;\r\n }", "public boolean isHit() { return hit; }", "public boolean isOver() {\n \t\treturn isOver;\n \t}", "boolean hasBonusHP();", "public L2Character getOverhitAttacker()\n\t{\n\t\treturn overhitAttacker;\n\t}", "public boolean isAttack() {\n\t\treturn attack;\n\t}", "public boolean canAttackWithItem() {\n/* 215 */ return false;\n/* */ }", "public boolean canAttackWithItem() {\n/* 253 */ return false;\n/* */ }", "protected boolean isGameOver(){\n return (getShipsSunk()==10);\n }", "public boolean isHit(Point p){\n if(super.getLocation().equals(p)){\n nunMissiles = 0;\n return true;\n } else {\n return false;\n }\n }", "public boolean isBattleOver(){\n\n if(battleEnemies.size() == 0) {\n System.out.println(\"Battle over all enemies dead\");\n findDefeated();\n cleanStatuses();\n result = true;\n\n return true;\n }\n if(character.getCurrHP() <= 0){\n System.out.println(\"Battle over character has died\");\n //findDefeated();\n cleanStatuses();\n result = false;\n\n return true;\n }\n //System.out.printf(\"remaining enemies: %s\\n\", battleEnemies.size());\n return false;\n }", "public boolean isBattleOver() {\n\t\treturn battleOver;\n\t}", "public boolean checkOpportunityAttacks(Creature creature) {\n/* 2073 */ Creature[] lTempCreatures = getCreatures();\n/* 2074 */ for (int x = 0; x < lTempCreatures.length; x++) {\n/* */ \n/* 2076 */ if (lTempCreatures[x] != creature && !lTempCreatures[x].isMoving())\n/* */ {\n/* 2078 */ if (lTempCreatures[x].getAttitude(creature) == 2)\n/* */ {\n/* */ \n/* 2081 */ if (VirtualZone.isCreatureTurnedTowardsTarget(creature, lTempCreatures[x]))\n/* 2082 */ return lTempCreatures[x].opportunityAttack(creature); \n/* */ }\n/* */ }\n/* */ } \n/* 2086 */ return false;\n/* */ }", "public boolean shouldHit() {\r\n\t\tif(getHandVal() < 17) {\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\treturn false; \r\n\t}", "boolean hasDamage();", "boolean hasDamage();", "boolean hasDamage();", "boolean hasDamage();", "boolean hasDamage();", "public boolean getHitOrSplat() {\n return currentlyAbilityHit;\n }", "public boolean isAttackState() {\n return States.attack.contains(this.state);\n }", "public boolean isOver() {\n \treturn status == GameStatus.victory || status == GameStatus.draw || status == GameStatus.quit;\n }", "@Override\n public boolean isUsableEffectTwo() {\n return getEffectsEnable()[1] && getUsableEffect()[1] && ((TargetSquareRequestEvent) getTargetEffectOne()).getPossibleTargetsX().length != 0 && getOwner().canAffortCost(getSecondEffectCost());\n }", "protected boolean attackTargetWith(Weapon weapon) {\r\n\t\tint cth = getChanceToHit(character, target, weapon);\r\n\t\tint roll = GameState.getRandomGenerator().nextInt(100);\r\n\t\tboolean hit = roll < cth;\r\n\r\n\t\tString weaponName = weapon != null ? weapon.getName() : \"fists\";\r\n\t\t\r\n\t\tLog.logLocalized(\"AttackRoll\", LogType.COMBAT, character.getName(), cth, target.getName(),weaponName, roll,hit? Strings.getString(CombatManager.STRING_TABLE, \"hit\") : Strings.getString(CombatManager.STRING_TABLE, \"miss\"));\r\n\t\t\r\n\t\tif (hit) {\r\n\t\t\t// ((Weapon Damage + Weapon Bonus + Weapon Skill) / 100) * Enemy Armor Rating\r\n\t\t\tfloat damage = calculateDamage(weapon, character, target);\r\n\t\t\t\r\n\t\t\tLog.logLocalized(\"attackHit\",LogType.COMBAT, character.getName(), target.getName(), MathUtil.toUIString(damage),weaponName);\r\n\t\t\t\r\n\t\t\ttarget.dealDamage(damage, character);\r\n\t\t\tif (weapon != null) {\r\n\t\t\t\tweapon.executeEffects(character, target);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\ttarget.onAttack(character);\r\n\t\t}\r\n\t\tif (++attackedWeaponCount >= attackingWeapons.size) {\r\n\t\t\tattackFinished = true;\r\n\t\t}\r\n\t\treturn hit;\r\n\t}", "public boolean isLevelOver() {\n\t\treturn waveControl.isLevelEnd();\n\t}", "public boolean wasHit() {\n return(_hit);\n }", "public boolean canAttack(Figure target) {\n return true;\n }", "public boolean isOverThreshold(){return isOverThreshold;}", "public boolean attack(Combatant target) {\r\n for (int i = 0; i < numAttacks; i++) {\r\n int attackRoll = this.basicAttackToHit();\r\n\r\n if (attackRoll == (20 + toHit)) { //Critical case, double number of damage dice\r\n target.setCurrentHitPoints(target.getHitPoints() - (this.basicAttackDamage() + damageDice.roll()));\r\n } else if (attackRoll == 1 + toHit) { //Natural 1 case, auto miss\r\n continue;\r\n } else if (attackRoll > target.getAC()) { //Regular hit case\r\n target.setCurrentHitPoints(target.getHitPoints() - this.basicAttackDamage());\r\n } else { //Miss case\r\n continue;\r\n }\r\n\r\n if (target.getHitPoints() <= 0) {\r\n this.win();\r\n return true;\r\n }\r\n }\r\n return false;\r\n }", "public boolean getOver(){\n\t\t//if the game is over, stop the timer\n\t\tif(this.over){\n\t\t\t//update the total points label\n\t\t\tthis.getPoints();\n\t\t\t\n\t\t\tthis.timer.stop();\n\t\t}\n\t\t\n\t\treturn this.over;\n\t}", "public boolean isGameOver() {\n if (!isFirstTurn) {\n if (state.score().totalPoints(TeamId.TEAM_1)>=Jass.WINNING_POINTS||state.score().totalPoints(TeamId.TEAM_2)>=Jass.WINNING_POINTS) {\n return true;\n }\n else {\n return false;\n }\n } \n else {return false;}\n }", "public boolean hasBonusHP() {\n return ((bitField0_ & 0x00000001) == 0x00000001);\n }", "public boolean hasBonusHP() {\n return ((bitField0_ & 0x00000001) == 0x00000001);\n }", "public boolean isOverState() {\n return overState;\n }", "public boolean gameOver(){\n\t\treturn this.lives < 1;\n\t}", "@Override\n public boolean gameOver() {\n return player1Wins() || player2Wins();\n }", "@Override\n\tpublic boolean getIsOver();", "boolean wasHit();", "public void overhitEnabled(final boolean status)\n\t{\n\t\toverhit = status;\n\t}", "public boolean isMouseOver(){\n\t\treturn this.contains(Main.camera.getMousePos());\n\t}", "public boolean inRange(){\n //System.out.println(\"inRange\");\n return Math.abs(GameView.instance.player.position.x - creationPoint.x) < GameView.instance.cameraSize * attackRange;\n }", "private boolean tryAttack(Tile fromTile) {\r\n\t\tint size = getBoard().getTiles().length;\r\n\r\n\t\t// if attacker is on power-up tile\r\n\t\tif (fromTile.getTileType().equals(\"PowerUp\")) {\r\n\t\t\tif (fromTile.getPiece().getLEAGUE() == League.SHARK && fromTile.getTer().territoryName().equals(\"Shark\")) {\r\n\t\t\t\tfromTile.getPiece().setPower(fromTile.getPiece().getPower() + 1);\r\n\t\t\t}\r\n\r\n\t\t\tif (fromTile.getPiece().getLEAGUE() == League.EAGLE && fromTile.getTer().territoryName().equals(\"Eagle\")) {\r\n\t\t\t\tfromTile.getPiece().setPower(fromTile.getPiece().getPower() + 1);\r\n\t\t\t} else if (fromTile.getTer().territoryName().equals(\"Neutral\")) {\r\n\t\t\t\tfromTile.getPiece().setPower(fromTile.getPiece().getPower() + 1);\r\n\t\t\t}\r\n\r\n\t\t}\r\n\t\t// if the defender is on power-up tile\r\n\t\tif (tile.getTileType().equals(\"PowerUp\")) {\r\n\t\t\tif (tile.getPiece().getLEAGUE() == League.SHARK && tile.getTer().territoryName().equals(\"Shark\")) {\r\n\t\t\t\ttile.getPiece().setPower(tile.getPiece().getPower() + 1);\r\n\t\t\t}\r\n\r\n\t\t\tif (tile.getPiece().getLEAGUE() == League.EAGLE && tile.getTer().territoryName().equals(\"Eagle\")) {\r\n\t\t\t\ttile.getPiece().setPower(tile.getPiece().getPower() + 1);\r\n\t\t\t} else if (tile.getTer().territoryName().equals(\"Neutral\")) {\r\n\t\t\t\ttile.getPiece().setPower(tile.getPiece().getPower() + 1);\r\n\t\t\t}\r\n\r\n\t\t}\r\n\r\n\t\tif (fromTile.getPiece().getPower() >= tile.getPiece().getPower()) {\r\n\t\t\tif (tile.getPiece().getTYPE() == PieceType.FLAG) {\r\n\t\t\t\tfromTile.getPiece().setHasEnemyFlag(true);\r\n\t\t\t\tUtilities.infoAlert(\"Enemy Flag Captured!\", \"Get that piece with the flag back to your territory quickly!\");\r\n\t\t\t} else {\r\n\t\t\t\tif (tile.getPiece().getHasEnemyFlag() == true) {\r\n\t\t\t\t\tUtilities.infoAlert(\"Flag Recaptured!\", \"Enemy piece carrying your flag has been killed.\\nYour flag has respawned in your territory.\");\r\n\r\n\t\t\t\t\t// generate the dropped flag at its original position\r\n\t\t\t\t\t// or generate the dropped flag on first available tile on first or last row\r\n\t\t\t\t\t// if the default position has a piece on it\r\n\t\t\t\t\tif (tile.getPiece().getLEAGUE() == League.EAGLE) {\r\n\t\t\t\t\t\tif (getBoard().getTiles()[size - 1][(size / 2) - 1].getPiece() == null) {\r\n\t\t\t\t\t\t\tgetBoard().getTiles()[size - 1][(size / 2) - 1].setPiece(new SharkFlag());\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\tfor (int sharkCol = 0; sharkCol < getBoard().getTiles().length; sharkCol++) {\r\n\t\t\t\t\t\t\t\tif (getBoard().getTiles()[size - 1][sharkCol].getPiece() == null) {\r\n\t\t\t\t\t\t\t\t\tgetBoard().getTiles()[size - 1][sharkCol].setPiece(new SharkFlag());\r\n\t\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tif (getBoard().getTiles()[0][size / 2].getPiece() == null) {\r\n\t\t\t\t\t\t\tgetBoard().getTiles()[0][size / 2].setPiece(new EagleFlag());\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\tfor (int eagleCol = 0; eagleCol < getBoard().getTiles().length; eagleCol++) {\r\n\t\t\t\t\t\t\t\tif (getBoard().getTiles()[0][eagleCol].getPiece() == null) {\r\n\t\t\t\t\t\t\t\t\tgetBoard().getTiles()[0][eagleCol].setPiece(new EagleFlag());\r\n\t\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn movePiece(fromTile);\r\n\t\t} else {\r\n\t\t\tUtilities.infoAlert(\"Invalid action\", \"Enemy power level higher at level \" + tile.getPiece().getPower()\r\n\t\t\t\t\t+ \". \" + \"\\nYour current piece is not able to defeat it and has cowered back in fear.\");\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "public static boolean calcHitMiss(L2Character attacker, L2Character target)\n\t{\n\t\tdouble chance = 800 + 20 * (attacker.getAccuracy() - target.getEvasionRate(attacker));\n\n\t\t//if (attacker instanceof L2PcInstance && target instanceof L2PcInstance)\n\t\t//\tLog.info(\"P: \" + attacker.getAccuracy() + \" \" + target.getEvasionRate(attacker) + \": \" + chance);\n\n\t\t// Get additional bonus from the conditions when you are attacking\n\t\tchance *= hitConditionBonus.getConditionBonus(attacker, target);\n\n\t\tchance = Math.max(chance, 200);\n\t\tchance = Math.min(chance, 980);\n\n\t\tif (attacker instanceof L2PcInstance)\n\t\t{\n\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\tif (player.getExpertiseWeaponPenalty() != 0)\n\t\t\t{\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\treturn chance < Rnd.get(1000);\n\t}", "@Override\r\n\tpublic boolean canAttackEntity(Entity entity) {\n\t\treturn false;\r\n\t}", "@Override\r\n\tpublic boolean canAttackEntity(Entity entity) {\n\t\treturn false;\r\n\t}", "boolean hasCurHP();", "boolean hasCurHP();", "boolean hasCurHP();", "boolean hasCurHP();", "boolean hasCurHP();", "boolean hasCurHP();", "public boolean interupted(Creature Opponent){\n if (Opponent.selected_manuever.type.equals(\"Attack\") && Opponent.maneuver_pass && this.interruptable) { interupt_count++; return true; }\n else { return false; }\n }", "public boolean gameOver() \n {\n \treturn status() != GAME_NOT_OVER;\n }", "public abstract boolean isHit(int x, int y);", "public double getOverhitDamage()\n\t{\n\t\treturn overhitDamage;\n\t}", "private void checkLoosePLayer(){\n if (hero.getHp()<=0){\n loose();\n }\n\n }", "public boolean hit() {\r\n add(deck.deal());\r\n return getHandValue() <= 21;\r\n }", "public boolean hitOrStand(){\r\n\t\treturn hitOrStand;\r\n\t}", "public boolean gameOver() {\r\n return didPlayerLose() || didPlayerWin();\r\n }", "public boolean isOver() {\n\t\t\n\t\tif(!dealer.hasCards()){\n\t\t\tisOver= true;\n\t\t\treturn isOver;\n\t\t}\n\t\t\n\t\tfor (Player p : players) {\n\t\t\tif (!p.hasCards()) {\n\t\t\t\tisOver = true;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn isOver;\n\t}", "public boolean getIsBattleOver()\r\n {\r\n return isBattleOver;\r\n }", "private boolean isOver() {\r\n return players.size() == 1;\r\n }", "public abstract boolean gameIsOver();", "boolean hasBonusPercentHP();", "private boolean hitMyPaddle() {\n if (b.numX - 60 <= 0) {\n if ((b.numY <= (this.touchedY + 260)) && (b.numY >= (this.touchedY - 260))) {\n } else {\n this.wentOffWall();\n }\n return true;\n } else {\n return false;\n }\n }", "@Override\n\tpublic void canTakeOff() {\n\t\tSystem.out.println(\"I CANNOT TAKE OFF UNLESS YA JUMP ME OVER SOMMAT\");\n\t}", "public boolean gameIsOver() {return revealedShips >= 4;}", "public boolean hit()\n\t{\n\t\taddCardToHand(new BlackJackCard());\n\t\treturn getHandValue() <= 21;\n\t}", "private boolean didPlayerWin() {\r\n for (int i = 0; i < targets.length; i++) {\r\n if (targets[i].getHitPoints() != 0) {\r\n return false;\r\n }\r\n }\r\n return true;\r\n }", "public boolean isSelectingAttackTarget() {\n return false;\n }", "boolean canReceiveManaFromItem(ItemStack otherStack);", "public boolean isHit(Collideable otherCol){\n return this.collideable.getHitX() - otherCol.getHitX() < 50\n && this.collideable.getHitX() - otherCol.getHitX() > -50\n && this.collideable.getHitY() - otherCol.getHitY() > -30\n && this.collideable.getHitY() - otherCol.getHitY() < 30;\n }", "public boolean hasOverlay(ItemStack stack)\n {\n return this.field_77878_bZ == ItemArmor.ArmorMaterial.LEATHER || func_82814_b(stack) != 0x00FFFFFF;\n }", "public boolean isGameOver() {\n return gameOver;\n }", "public abstract boolean attack(KillableItem i);", "private boolean isGameOver() {\n return Snake().isTouching(Wall()) || Snake().isTouching(Snake());\n }", "float shouldAggroOnHit(IGeneticMob geneticMob, EntityLiving attacker);", "public boolean shouldExecute() {\n LivingEntity livingentity = ShulkerEntity.this.getAttackTarget();\n if (livingentity != null && livingentity.isAlive()) {\n return ShulkerEntity.this.world.getDifficulty() != Difficulty.PEACEFUL;\n } else {\n return false;\n }\n }", "public boolean isHitFree()\n {\n // TODO: replace this line with your code\n }", "public boolean gameOver() {\n\t\treturn gameOver;\n\t}", "private boolean hit(int accuracy)\n {\n Random random = new Random();\n int num = random.nextInt(100); //creates random number 0-100\n if(num < accuracy) //if number is lower than the accuracy then you can attack\n {\n return true;\n } else\n {\n return false;\n }\n }", "public boolean successfulHit(CreatureAttack attack, Creature attacked){\r\n return attack.attacker.attributes.health.accuracy.next() >= attacked.attributes.health.evasion.next();\r\n }", "public boolean checkIfPlayerHoldsExplosive () { return noOfExplosives > 0; }", "public boolean handleAttack(Action action) {\n ActorState a = action.getActor();\n if (a.getActor() == actor) {\n // Attacks on oneself always succeed, and we don't want to add ourselves as an enemy\n return true;\n }\n \n //maybeCounter(Augmentation.Type.ATTACK, a, combatants);\n enemies.add(a);\n \n double weaponAccuracy = 1.0; //source.getWeaponAccuracy(action);\n double chance = a.getAccuracy() * weaponAccuracy * (1.0 - getDefense());\n boolean success = Math.random() < chance;\n return success;\n }", "public boolean isGameOver() {\n\t\treturn this.b.isGameOver();\n\t}", "public abstract boolean hit(Rectangle2D r);", "public static boolean onhand() {\n return InventoryManager.getCount(ItemPool.COMBAT_LOVERS_LOCKET) > 0\n || KoLCharacter.hasEquipped(ItemPool.COMBAT_LOVERS_LOCKET);\n }", "public boolean isHitState() {\n return hitState;\n }", "public boolean wantsToAttack() {\n boolean ret = false;\n \n potentialAttackers.clear(); //Previous potentials might no longer be adjacent to an enemy\n \n //Look at all my territories. If it has enough troops to smack someone, it does.\n for(Territory t : gameController.getBoard().getAgentsTerritories(this)){\n if(t.getNumTroops() > 1){\n \n //Check adjacent territories to see if we can do anything about it.\n List<Territory> adjs = gameController.getBoard().getAdjacentTerritories(t);\n for(Territory adj : adjs){\n //Record a boolean so we don't need to call it twice;\n boolean yes = !adj.getOwner().equals(this);\n \n //Check if we have an acceptable chance of success\n int tTroops = t.getNumTroops() - 1;\n int aTroops = adj.getNumTroops();\n double odds = MarkovLookupTable.getOddsOfSuccessfulAttack(tTroops, aTroops);\n yes &= Double.compare(odds, ACCEPTABLE_RISK) >= 0;\n \n //If we can attack with this territory, yes will be true, throw this Territory\n //in the list of potential attackers if it isn't already in there.\n if(yes){\n if(!potentialAttackers.contains(t)){\n potentialAttackers.add(t);\n }\n }\n ret |= yes; //Ret will be set to true and can't be unset if even 1 t can attack\n }\n }\n }\n \n return ret;\n }", "public boolean isSecondBallAllowed() {\n\t\treturn !isStrike() || isBonusShotAllowed();\n\t}", "public boolean gameIsOver() {\r\n int cpt = 0;\r\n for (Player p : players) {\r\n if (p.getLife() > 0) {\r\n cpt++;\r\n }\r\n }\r\n return cpt==1;\r\n }", "public boolean gameOver()\n {\n boolean over = false;\n if (player1Hand.isEmpty()||player2Hand.isEmpty())\n {\n over = true;\n }\n return over;\n }", "public boolean hitSide()\n {\n if(accel.getAcceleration(ADXL345_I2C.Axes.kX)>0)\n return true;\n else\n return false;\n }", "public boolean isAlive(){\r\n if (currHP > 0){\r\n return true;\r\n }\r\n return false;\r\n }", "public boolean getAttack(IEntity enemyUnit){\n return tempUnit.getAttack(enemyUnit);\n }" ]
[ "0.61549515", "0.60413224", "0.6030004", "0.60061675", "0.599668", "0.59963167", "0.59704256", "0.5942161", "0.5941636", "0.5914499", "0.5883908", "0.5881669", "0.58655065", "0.5834891", "0.5816808", "0.5774513", "0.57628727", "0.57587713", "0.5750093", "0.5748531", "0.5748531", "0.5748531", "0.5748531", "0.5748531", "0.57455057", "0.5724807", "0.5702992", "0.56650895", "0.564873", "0.56338745", "0.5632051", "0.56241167", "0.5623351", "0.56213343", "0.56182444", "0.5617174", "0.56075734", "0.56011206", "0.55865735", "0.5556533", "0.55524004", "0.5526577", "0.55126375", "0.55095595", "0.5506527", "0.5501202", "0.54934037", "0.5484233", "0.547772", "0.547772", "0.5473463", "0.5473463", "0.5473463", "0.5473463", "0.5473463", "0.5473463", "0.5461645", "0.5459829", "0.5452957", "0.5448313", "0.54448354", "0.5438784", "0.54360944", "0.541955", "0.5418073", "0.5411601", "0.5407736", "0.5398544", "0.5397609", "0.5392355", "0.5378607", "0.5374046", "0.53641725", "0.5363303", "0.53562343", "0.5353826", "0.53514653", "0.53483915", "0.5348312", "0.53433424", "0.5338826", "0.5330152", "0.53280187", "0.5320047", "0.531695", "0.5316189", "0.5308958", "0.53055525", "0.53004915", "0.5291114", "0.528975", "0.5283374", "0.52831775", "0.5280036", "0.52798116", "0.5272852", "0.52695096", "0.5267655", "0.5263136", "0.5260066" ]
0.72763455
0
Activate the absorbed soul condition on the L2Attackable.
public void absorbSoul() { absorbed = true; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void attack() {\n if (activeWeapon == null) {\n return;\n }\n attacking = true;\n }", "public void activateShield() {\n shield.activate();\n }", "public void attack() {\n this.attacked = true;\n }", "public void activate() {\n\t\t// set cooldown counter\n\t}", "@Override\n public L2Attackable getActiveChar() { return (L2Attackable)super.getActiveChar(); }", "public void activarAceptar() {\n aceptar = false;\n }", "void activate(ConditionContext context);", "@Override\n\tpublic void attack() {\n\n\t}", "public void abilityTwo() {\n if(map.getCurrentTurnHero().getAbilities().size() < 2){\n return;\n }\n ability(map.getCurrentTurnHero().getAbilities().get(1));\n }", "public boolean activate() { //if true continue to execute\n\n if (Inventory.getCount(PowerFletch.LOG) >= 1) {\n System.out.println(\"cutting activated\");\n\n return true;\n }\n\n return false;\n }", "@Override\n public void attack() {\n\n }", "@Override\n\tpublic void attack() {\n\t}", "@Override\n\tpublic void attack() {\n\t\t\n\t}", "private void levelSoulCrystals(final L2Character attacker)\n\t{\n\t\t// Only L2PcInstance can absorb a soul\n\t\tif (!(attacker instanceof L2PcInstance) && !(attacker instanceof L2Summon))\n\t\t{\n\t\t\tresetAbsorbList();\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tfinal int maxAbsorbLevel = getAbsorbLevel();\n\t\tint minAbsorbLevel = 0;\n\t\t\n\t\t// If this is not a valid L2Attackable, clears the absorbersList and just return\n\t\tif (maxAbsorbLevel == 0)\n\t\t{\n\t\t\tresetAbsorbList();\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// All boss mobs with maxAbsorbLevel 13 have minAbsorbLevel of 12 else 10\n\t\tif (maxAbsorbLevel > 10)\n\t\t{\n\t\t\tminAbsorbLevel = maxAbsorbLevel > 12 ? 12 : 10;\n\t\t}\n\t\t\n\t\t// Init some useful vars\n\t\tboolean isSuccess = true;\n\t\tboolean doLevelup = true;\n\t\tfinal boolean isBossMob = maxAbsorbLevel > 10 ? true : false;\n\t\t\n\t\tfinal L2NpcTemplate.AbsorbCrystalType absorbType = getTemplate().absorbType;\n\t\t\n\t\tL2PcInstance killer = attacker instanceof L2Summon ? ((L2Summon) attacker).getOwner() : (L2PcInstance) attacker;\n\t\t\n\t\t// If this mob is a boss, then skip some checkings\n\t\tif (!isBossMob)\n\t\t{\n\t\t\t// Fail if this L2Attackable isn't absorbed or there's no one in its absorbersList\n\t\t\tif (!isAbsorbed() /* || absorbersList == null */)\n\t\t\t{\n\t\t\t\tresetAbsorbList();\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\t// Fail if the killer isn't in the absorbersList of this L2Attackable and mob is not boss\n\t\t\tAbsorberInfo ai = absorbersList.get(killer);\n\t\t\tif (ai == null || ai.absorber.getObjectId() != killer.getObjectId())\n\t\t\t{\n\t\t\t\tisSuccess = false;\n\t\t\t}\n\t\t\t\n\t\t\t// Check if the soul crystal was used when HP of this L2Attackable wasn't higher than half of it\n\t\t\tif (ai != null && ai.absorbedHP > getMaxHp() / 2.0)\n\t\t\t{\n\t\t\t\tisSuccess = false;\n\t\t\t}\n\t\t\t\n\t\t\tif (!isSuccess)\n\t\t\t{\n\t\t\t\tresetAbsorbList();\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tai = null;\n\t\t}\n\t\t\n\t\t// ********\n\t\tString[] crystalNFO = null;\n\t\tString crystalNME = \"\";\n\t\t\n\t\tfinal int dice = Rnd.get(100);\n\t\tint crystalQTY = 0;\n\t\tint crystalLVL = 0;\n\t\tint crystalOLD = 0;\n\t\tint crystalNEW = 0;\n\t\t\n\t\t// ********\n\t\t// Now we have four choices:\n\t\t// 1- The Monster level is too low for the crystal. Nothing happens.\n\t\t// 2- Everything is correct, but it failed. Nothing happens. (57.5%)\n\t\t// 3- Everything is correct, but it failed. The crystal scatters. A sound event is played. (10%)\n\t\t// 4- Everything is correct, the crystal level up. A sound event is played. (32.5%)\n\t\t\n\t\tList<L2PcInstance> players = new ArrayList<>();\n\t\t\n\t\tif (absorbType == L2NpcTemplate.AbsorbCrystalType.FULL_PARTY && killer.isInParty())\n\t\t{\n\t\t\tplayers = killer.getParty().getPartyMembers();\n\t\t}\n\t\telse if (absorbType == L2NpcTemplate.AbsorbCrystalType.PARTY_ONE_RANDOM && killer.isInParty())\n\t\t{\n\t\t\t// This is a naive method for selecting a random member. It gets any random party member and\n\t\t\t// then checks if the member has a valid crystal. It does not select the random party member\n\t\t\t// among those who have crystals, only. However, this might actually be correct (same as retail).\n\t\t\tplayers.add(killer.getParty().getPartyMembers().get(Rnd.get(killer.getParty().getMemberCount())));\n\t\t}\n\t\telse\n\t\t{\n\t\t\tplayers.add(killer);\n\t\t}\n\t\t\n\t\tfor (final L2PcInstance player : players)\n\t\t{\n\t\t\tif (player == null)\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\tcrystalQTY = 0;\n\t\t\t\n\t\t\tL2ItemInstance[] inv = player.getInventory().getItems();\n\t\t\tfor (final L2ItemInstance item : inv)\n\t\t\t{\n\t\t\t\tfinal int itemId = item.getItemId();\n\t\t\t\tfor (final int id : SoulCrystal.SoulCrystalTable)\n\t\t\t\t{\n\t\t\t\t\t// Find any of the 39 possible crystals.\n\t\t\t\t\tif (id == itemId)\n\t\t\t\t\t{\n\t\t\t\t\t\tcrystalQTY++;\n\t\t\t\t\t\t// Keep count but make sure the player has no more than 1 crystal\n\t\t\t\t\t\tif (crystalQTY > 1)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tisSuccess = false;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Validate if the crystal has already leveled\n\t\t\t\t\t\tif (id != SoulCrystal.RED_NEW_CRYSTAL && id != SoulCrystal.GRN_NEW_CYRSTAL && id != SoulCrystal.BLU_NEW_CRYSTAL)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\ttry\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (item.getItem().getName().contains(\"Grade\"))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t// Split the name of the crystal into 'name' & 'level'\n\t\t\t\t\t\t\t\t\tcrystalNFO = item.getItem().getName().trim().replace(\" Grade \", \"-\").split(\"-\");\n\t\t\t\t\t\t\t\t\t// Set Level to 13\n\t\t\t\t\t\t\t\t\tcrystalLVL = 13;\n\t\t\t\t\t\t\t\t\t// Get Name\n\t\t\t\t\t\t\t\t\tcrystalNME = crystalNFO[0].toLowerCase();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t// Split the name of the crystal into 'name' & 'level'\n\t\t\t\t\t\t\t\t\tcrystalNFO = item.getItem().getName().trim().replace(\" Stage \", \"\").split(\"-\");\n\t\t\t\t\t\t\t\t\t// Get Level\n\t\t\t\t\t\t\t\t\tcrystalLVL = Integer.parseInt(crystalNFO[1].trim());\n\t\t\t\t\t\t\t\t\t// Get Name\n\t\t\t\t\t\t\t\t\tcrystalNME = crystalNFO[0].toLowerCase();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t// Allocate current and levelup ids' for higher level crystals\n\t\t\t\t\t\t\t\tif (crystalLVL > 9)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tfor (final int[] element : SoulCrystal.HighSoulConvert)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t// Get the next stage above 10 using array.\n\t\t\t\t\t\t\t\t\t\tif (id == element[0])\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tcrystalNEW = element[1];\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tcrystalNEW = id + 1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tcatch (final NumberFormatException nfe)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tLOGGER.warn(\"An attempt to identify a soul crystal failed, \" + \"verify the names have not changed in etcitem table.\", nfe);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tplayer.sendMessage(\"There has been an error handling your soul crystal.\" + \" Please notify your server admin.\");\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tisSuccess = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tcatch (final Exception e)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t\t\tisSuccess = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcrystalNME = item.getItem().getName().toLowerCase().trim();\n\t\t\t\t\t\t\tcrystalNEW = id + 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Done\n\t\t\t\t\t\tcrystalOLD = id;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (!isSuccess)\n\t\t\t\t{\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tinv = null;\n\t\t\t\n\t\t\t// If the crystal level is way too high for this mob, say that we can't increase it\n\t\t\tif (crystalLVL < minAbsorbLevel || crystalLVL >= maxAbsorbLevel)\n\t\t\t{\n\t\t\t\tdoLevelup = false;\n\t\t\t}\n\t\t\t\n\t\t\t// The player doesn't have any crystals with him get to the next player.\n\t\t\tif (crystalQTY < 1 || crystalQTY > 1 || !isSuccess || !doLevelup)\n\t\t\t{\n\t\t\t\t// Too many crystals in inventory.\n\t\t\t\tif (crystalQTY > 1)\n\t\t\t\t{\n\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_FAILED_RESONATION));\n\t\t\t\t}\n\t\t\t\t// The soul crystal stage of the player is way too high\n\t\t\t\t// Like L2OFF message must not appear if char hasn't crystal on inventory\n\t\t\t\telse if (!doLevelup && crystalQTY > 0)\n\t\t\t\t{\n\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_REFUSED));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tcrystalQTY = 0;\n\t\t\t\t\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\t/*\n\t\t\t * TODO: Confirm boss chance for crystal level up and for crystal breaking. It is known that bosses with FULL_PARTY crystal level ups have 100% success rate, but this is not the case for the other bosses (one-random or last-hit). While not confirmed, it is most reasonable that crystals leveled up at\n\t\t\t * bosses will never break. Also, the chance to level up is guessed as around 70% if not higher.\n\t\t\t */\n\t\t\tfinal int chanceLevelUp = isBossMob ? 70 : SoulCrystal.LEVEL_CHANCE;\n\t\t\t\n\t\t\t// If succeeds or it is a full party absorb, level up the crystal.\n\t\t\tif (absorbType == L2NpcTemplate.AbsorbCrystalType.FULL_PARTY && doLevelup || dice <= chanceLevelUp)\n\t\t\t{\n\t\t\t\t// Give staged crystal\n\t\t\t\texchangeCrystal(player, crystalOLD, crystalNEW, false);\n\t\t\t}\n\t\t\t\n\t\t\t// If true and not a last-hit mob, break the crystal.\n\t\t\telse if (!isBossMob && dice >= 100.0 - SoulCrystal.BREAK_CHANCE)\n\t\t\t{\n\t\t\t\t// Remove current crystal an give a broken open.\n\t\t\t\tif (crystalNME.startsWith(\"red\"))\n\t\t\t\t{\n\t\t\t\t\texchangeCrystal(player, crystalOLD, SoulCrystal.RED_BROKEN_CRYSTAL, true);\n\t\t\t\t}\n\t\t\t\telse if (crystalNME.startsWith(\"gre\"))\n\t\t\t\t{\n\t\t\t\t\texchangeCrystal(player, crystalOLD, SoulCrystal.GRN_BROKEN_CYRSTAL, true);\n\t\t\t\t}\n\t\t\t\telse if (crystalNME.startsWith(\"blu\"))\n\t\t\t\t{\n\t\t\t\t\texchangeCrystal(player, crystalOLD, SoulCrystal.BLU_BROKEN_CRYSTAL, true);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tresetAbsorbList();\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_FAILED));\n\t\t\t}\n\t\t}\n\t\t\n\t\tkiller = null;\n\t\tplayers = null;\n\t\tcrystalNFO = null;\n\t\tcrystalNME = null;\n\t}", "@Override\n\tpublic void activate(Entity caller) {\n\t\tcaller.dealDamage(10);\n\t\t\n\t}", "public boolean attackAlly(Ally target) {\n\t\tLog.d(TAG, \"Attacking!\");\n\t\tif (target.takeDamage(damage)) {\n\t\t\treturn true;\n\t\t} else\n\t\t\treturn false;\n\t}", "@Override\n\tvoid attack() {\n\n\t}", "public void addAbsorber(final L2PcInstance attacker, final int crystalId)\n\t{\n\t\t// This just works for targets like L2MonsterInstance\n\t\tif (!(this instanceof L2MonsterInstance))\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// The attacker must not be null\n\t\tif (attacker == null)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// This L2Attackable must be of one type in the absorbingMOBS_levelXX tables.\n\t\t// OBS: This is done so to avoid triggering the absorbed conditions for mobs that can't be absorbed.\n\t\tif (getAbsorbLevel() == 0)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// If we have no absorbersList initiated, do it\n\t\tAbsorberInfo ai = absorbersList.get(attacker);\n\t\t\n\t\t// If the L2Character attacker isn't already in the absorbersList of this L2Attackable, add it\n\t\tif (ai == null)\n\t\t{\n\t\t\tai = new AbsorberInfo(attacker, crystalId, getCurrentHp());\n\t\t\tabsorbersList.put(attacker, ai);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tai.absorber = attacker;\n\t\t\tai.crystalId = crystalId;\n\t\t\tai.absorbedHP = getCurrentHp();\n\t\t}\n\t\t\n\t\t// Set this L2Attackable as absorbed\n\t\tabsorbSoul();\n\t\t\n\t\tai = null;\n\t}", "private static void decisionWhenAttacking() {\n\t\tif (isNewAttackState()) {\n\t\t\tchangeStateTo(STATE_ATTACK_PENDING);\n\n\t\t\t// We will try to define place for our army where to attack. It\n\t\t\t// probably will be center around a crucial building like Command\n\t\t\t// Center. But what we really need is the point where to go, not the\n\t\t\t// unit. As long as the point is defined we can attack the enemy.\n\n\t\t\t// If we don't have defined point where to attack it means we\n\t\t\t// haven't yet decided where to go. So it's the war's very start.\n\t\t\t// Define this assault point now. It would be reasonable to relate\n\t\t\t// it to a particular unit.\n\t\t\t// if (!isPointWhereToAttackDefined()) {\n\t\t\tStrategyManager.defineInitialAttackTarget();\n\t\t\t// }\n\t\t}\n\n\t\t// Attack is pending, it's quite \"regular\" situation.\n\t\tif (isGlobalAttackInProgress()) {\n\n\t\t\t// Now we surely have defined our point where to attack, but it can\n\t\t\t// be so, that the unit which was the target has been destroyed\n\t\t\t// (e.g. just a second ago), so we're standing in the middle of\n\t\t\t// wasteland.\n\t\t\t// In this case define next target.\n\t\t\t// if (!isSomethingToAttackDefined()) {\n\t\t\tdefineNextTarget();\n\t\t\t// }\n\n\t\t\t// Check again if continue attack or to retreat.\n\t\t\tboolean shouldAttack = decideIfWeAreReadyToAttack();\n\t\t\tif (!shouldAttack) {\n\t\t\t\tretreatsCounter++;\n\t\t\t\tchangeStateTo(STATE_RETREAT);\n\t\t\t}\n\t\t}\n\n\t\t// If we should retreat... fly you fools!\n\t\tif (isRetreatNecessary()) {\n\t\t\tretreat();\n\t\t}\n\t}", "@Override\n public void attack(){\n\n }", "public void acivatePlayer() {\n\t\tthis.setEnabled(true);\n\t}", "public void activate(Player p) throws IllegalArgumentException {\n if (p == null) throw new IllegalArgumentException(\"Argument is null\");\n ability.activateAbility(p);\n isActive = true;\n }", "@Override\n\tpublic boolean attackEntityFrom(DamageSource src, float par2) {\n\t\tif (isInvulnerableTo(src)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// don't just sit there!\n\t\taiSit.setSitting(false);\n\n\t\treturn super.attackEntityFrom(src, par2);\n\t}", "public void battleAllyAttack() {\n if(battleAlly instanceof Character){\n battleTickStatuses();\n updateBattleSides();\n }\n\n // battleAlly now attacks targetEnemy or preference based on the type of battleAlly\n if(battleAlly != null){ // If all allies have attacked, they cannot attack anymore for this round\n MovingEntity target = battleAlly.getAttackPreference(targetEnemies);\n // if not picky, get preference is the default next target\n if(target == null) {\n target = targetEnemy;\n }\n battleAlly.attack(target, targetAllies, targetEnemies);\n //System.out.println(battleAlly.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still unfriendly\n targetEnemy = checkSideSwap(targetEnemy, true, battleAllies, targetAllies, battleEnemies, targetEnemies);\n }\n battleAlly = nextAttacker(battleAlly, battleAllies);\n\n }\n }", "@Override\r\n\tpublic boolean damageEntity(DamageSource damagesource, float f2) {\n\t\tboolean toReturn = super.damageEntity(damagesource, f2);\r\n\t\tif(f2>=3 && !this.isInvulnerable(damagesource) && damagesource.getEntity()!=null && damagesource.getEntity().getBukkitEntity() instanceof Player) { // prevent things like snowball damage from triggering this ability\r\n\t\t\tif(random.nextInt(100)+1<=20) { //prevent boss from getting combo'd to hard in corner\r\n\t\t\t\tif(!teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity())) {\r\n\t\t\t\t\tteleportToEnemy();\t\t\r\n\t\t\t\t\tteleportCooldown.addCooldown((Player)damagesource.getEntity().getBukkitEntity());\r\n\t\t\t\t\tLog.info(teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity()));\r\n\t\t\t\t\tLog.info(((Player)damagesource.getEntity().getBukkitEntity()).getName());\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn toReturn;\r\n\t}", "private void enableBotonAceptar()\r\n\t{\r\n\t\t\r\n\t}", "public void sbbActivate() {\n\t}", "public void activatedBy(final Player player) {\n //Battle with a Boss Unit\n }", "public void weaponAbility() {\n \tlogger.info(\"weapon abilities aren't implemented yet. Using slash ability\");\n \t//ability(map.getCurrentTurnHero().getWeaponAbility());\n \tability(new Slash());\n }", "public void battleEnemyAttack() {\n if(battleEnemy != null){ // If all enemies have attacked, they cannot attack anymore for this round\n\n MovingEntity target = battleEnemy.getAttackPreference(targetAllies);\n if(target == null){\n target = targetAlly;\n }\n\n battleEnemy.attack(target, targetEnemies, targetAllies);\n //System.out.println(battleEnemy.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still friendly incase of zombify\n targetAlly = checkSideSwap(targetAlly, false, battleEnemies, targetEnemies, battleAllies, targetAllies);\n }\n\n battleEnemy = nextAttacker(battleEnemy, battleEnemies);\n\n }\n }", "@Override\n\tpublic void startCooldown() {\n\t\tthis.setSpecialAttackCooldown(HunterKillerConstants.SOLDIER_COOLDOWN);\n\t}", "public abstract boolean attack(KillableItem i);", "public void abilityOne() {\n ability(map.getCurrentTurnHero().getAbilities().get(0));\n }", "public abstract boolean attack(TemporaryCharm i);", "public abstract boolean attack(PermanentCharm i);", "@Override\r\n\tpublic boolean activate() {\n\t\treturn true;\r\n\t}", "@Override\r\n\tpublic boolean activate() {\n\t\treturn true;\r\n\t}", "public void activate(){\r\n\t\tactive=true;\r\n\t}", "@Override\n\tpublic boolean isAutoAttackable(L2Character attacker)\n\t{\n\t\tif ((attacker == null) || !(attacker instanceof L2PcInstance))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\tboolean isFort = ((getFort() != null) && (getFort().getResidenceId() > 0) && getFort().getSiege().isInProgress() && !getFort().getSiege().checkIsDefender(((L2PcInstance) attacker).getClan()));\n\t\t\n\t\t// Attackable during siege by all except defenders\n\t\treturn (isFort);\n\t}", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "public void toSelectingAttackTarget() {\n }", "public void gettingAttacked(HitByBulletEvent e) {\r\n\t\tif (gotTarget) {\r\n\t\t\tfor (int i = 0; i < enemyTracker.getEnemyList().size(); i++) {\r\n\t\t\t\tif (enemyTracker.getEnemyList().get(i).getName().equals(e.getName()) && (!e.getName().equals(radarTarget.getName()))) {\r\n\t\t\t\t\t\tmrRobot.sendMessage(5, \"2\");\r\n\t\t\t\t\t\tradarTarget = enemyTracker.getEnemyList().get(getIndexForEnemy(e.getName()));\r\n\t\t\t\t\t\ttargetTracking.get(getIndexForName(mrRobot.getName())).updateTarget(radarTarget);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public void activate(){\r\n\r\n\t}", "public PassiveAbility(boolean onSelf, Effects effects) {\r\n\t\t// will be false if from buff;\r\n\t\tsuper(new FixedTargeting((onSelf) ? \"SOURCE\" : \"TARGET\"),\r\n\t\t\t\teffects);\r\n\t}", "@Override\n\tpublic boolean activate() {\n\t\treturn true;\n\t}", "@Override\n\tpublic void skill2(Fightable f) {\n\t\tsuper.setDamage(super.getStrength()*2);\n\t\tsuper.setAtkRange((int)(super.getDamage()/10));\n\t\t\n\t\tthis.attack(f, 3);\n\t}", "public void enable(){\r\n\t\tthis.activ = true;\r\n\t}", "public void causeFoodExhaustion(float debug1) {\n/* 1797 */ if (this.abilities.invulnerable) {\n/* */ return;\n/* */ }\n/* */ \n/* 1801 */ if (!this.level.isClientSide) {\n/* 1802 */ this.foodData.addExhaustion(debug1);\n/* */ }\n/* */ }", "@Override\n\tpublic void landedOn() {\n\t\tMonopolyGameController.getInstance();\n\t\tMonopolyGameController.getCurrentPlayer().increaseMoney(300);\n\t\tLogger.getInstance().notifyAll(MonopolyGameController.getCurrentPlayer().getName()+ \" gained 300 dollars by landing on Bonus Square\");\n\t\tMonopolyGameController.allowCurrentPlayerToEndTurn();\n\n\t}", "void hit(GameObject o){\r\n\t\tif (!shield){ // if sheild is on all hits do nothing\r\n\t\t\tif (!(o instanceof UpPower)){ // if didnt hit a power up the ship loses a life\r\n\t\t\t\tif (lives > 1) {\r\n\t\t\t\t\tlives--;\r\n\t\t\t\t\treset();\r\n\t\t\t\t}\r\n\t\t\t\telse { // once there is no life left the ship dies\r\n\t\t\t\t\tdead = true;\r\n\t\t\t\t\tlives--;\r\n\t\t\t\t}\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t}", "@Override\n public void activate(boolean status) {\n godPower.activate(status);\n }", "@Override\n public void activate() {\n \n }", "protected void doActivate() throws FndException\n {\n }", "public void performAbility() { return; }", "@Override\n\tpublic void OnAttackCommand() {\n\t\tsuper.OnAttackCommand();\n\t\tSoundManage.playSound(atkSound1);\n\t}", "public void startTurn() {\n nMovesBeforeGrabbing = 1;\n nMovesBeforeShooting = 0;\n\n if (damages.size() > 2)\n nMovesBeforeGrabbing = 2;\n\n if (damages.size() > 5)\n nMovesBeforeShooting = 1;\n\n playerStatus.isActive = true;\n }", "protected void toggleLaser() {\n laserOn = !laserOn;\n }", "@Override\n public void onTargetDamaged(LivingEntity user, Entity target, int level) {\n if(target instanceof LivingEntity) {\n\n //target.damage(DamageSource.LAVA, 3F);\n knockUp((PlayerEntity) user, (LivingEntity) target, 3F);\n }\n }", "@Override\n public boolean activate() {\n //When will this activate?\n return Areas.FALADOR.contains(ctx.players.local().tile())\n && ctx.widgets.component(1371,0).visible()\n && !ctx.objects.select().name(\"Waterpump\").within(6.0).isEmpty();\n }", "protected void ap() {\n Object object = this.li;\n synchronized (object) {\n if (this.lz != null) {\n return;\n }\n IntentFilter intentFilter = new IntentFilter();\n intentFilter.addAction(\"android.intent.action.SCREEN_ON\");\n intentFilter.addAction(\"android.intent.action.SCREEN_OFF\");\n this.lz = new BroadcastReceiver(){\n\n public void onReceive(Context context, Intent intent) {\n ab.this.d(false);\n }\n };\n this.lp.registerReceiver(this.lz, intentFilter);\n return;\n }\n }", "@Override\n\tpublic void activate() {\n\t\t\n\t}", "public boolean canAttackWithItem() {\n/* 215 */ return false;\n/* */ }", "@Override\n public boolean activate() {\n // We only want to go to the bank if our inventory is full and we aren't already there.\n return Mining.isInvFull() && !Constants.BANK_AREA.contains(Players.getLocal());\n }", "@Override\n public void attack(Entity e) {\n e.hit(atk);\n }", "public void attack()\n {\n getWorld().addObject(new RifleBullet(player.getX(), player.getY(), 1, 6, true), getX(), getY()); \n }", "@Override\n public Building activate(Game game, List<Player> players, Scanner sc) {\n throw new UnsupportedOperationException(\"Residential buildings do not activate\");\n }", "public Boolean makeAttackAction(UnitActor target) {\n if (this.isInRange(target)) {\n PlayBoardActor current = lazyPlayboardActor.get();\n long pvStart = target.getPv();\n current.getPlayBoard().applyAttack(this.point, target.getPoint());\n this.addAction(Actions.sequence(getActionAttack(target), target.getAfterAttack(pvStart - target.getPv())));\n this.disable(true);\n this.setIdle();\n return true;\n } else {\n return false;\n }\n }", "public void ability(LevelManager lm){\n\n int prevDamage = lm.player.getDamage();\n int newDamage = prevDamage+12;\n lm.player.setDamage(newDamage);\n }", "@Override\n\t\t\tpublic void attack(Base enemy) {\n\t\t\t}", "@Override\n\tpublic void activate() {\n\t}", "@Override\n\tpublic void activate() {\n\t}", "public void onScannedRobot(ScannedRobotEvent e)\n {\n BadBoy en = (BadBoy)enemies.get(e.getName());\n \n if(en == null){\n en = new BadBoy();\n enemies.put(e.getName(), en);\n }\n \n \n en.hp = true;\n en.energy = e.getEnergy();\n en.pos = hallarPunto(myPos, e.getDistance(), getHeadingRadians() + e.getBearingRadians());\n \n // normal target selection: the one closer to you is the most dangerous so attack him\n //si no le queda vida al objetivo actual CHANGE TARGET m8\n \n if(!objetivo.hp || e.getDistance() < myPos.distance(objetivo.pos)) {\n objetivo = en;\n }\n \n \n }", "public void enableSurvivialMode()\n\t{\n\t\tthis.player.useFlyingMode = false;\n\t\tthis.player.setHealth(100f);\n\t}", "public void actionCombat(Party p1) {\n System.out.println(\"______________________________________________________________________________\\n\");\n System.out.println(this.Name + \" is attacking ...\");\n int choice = (int)(Math.random() * p1.getTeam().size());\n Character target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n\n if (this.SPEED - target.getSPEED() < 5) {\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n }\n else {\n int n = 0;\n while ((target.actualHP != 0) && (n < 2)) {\n if (n == 1) {\n choice = (int)(Math.random() * p1.getTeam().size() + 1);\n target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n }\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n if (n == 0) System.out.println(this.Name + \" attacks again ...\");\n n++;\n }\n }\n }", "@Test\n\tpublic void testArmingBypassed() {\n\t\tSet<String> armed = addressesOf(addContactSensor(true, false));\n\t\tSet<String> bypassed = addressesOf(addMotionSensor(true, true));\n\t\tstageArmingBypassed(SecuritySubsystemCapability.ALARMMODE_ON, armed, bypassed);\n\n\t\talarm.bind(context);\n\t\tassertArmingBypassed(armed, bypassed);\n\t}", "private void startAttack() {\n\t\tdetermineAttackingWeapons(character, targetPosition.getX(), targetPosition.getY(), attackingWeapons);\r\n\t\tif (shouldStartCombat()) {\r\n\t\t\tgameState.startCombat();\r\n\t\t}\r\n\t\ttotalAPCost = getAPCostToAttack();\r\n\t\tif ((character.\r\n\t\t\t\tstats().getAPAct() >= totalAPCost || !GameState.isCombatInProgress())\r\n\t\t\t\t&& (attackingWeapons.size > 0 || canAttackWithFists())) {\r\n\t\t\tstartedAttack = true;\r\n\t\t\tcharacter.setIsSneaking(false);\r\n\t\t\tcharacter.setOrientation(Orientation\r\n\t\t\t\t\t.calculateOrientationToTarget(character, target));\r\n\t\t\tif (rangedAttack) {\r\n\t\t\t\tcharacter.setState(State.ATTACKRANGED);\r\n\t\t\t} else {\r\n\t\t\t\tcharacter.setState(State.ATTACKMELEE);\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tstartedAttack = true;\r\n\t\t\tactionFinished = true;\r\n\t\t}\r\n\t}", "public void activate() {\n\tif (canBeActive()) {\n\t\tmActive = true;\n\t} else {\n\t\tthrow new IllegalStateException(getClass().getSimpleName() + \" isn't allowed to be activated\");\n\t}\n}", "@Override\n protected boolean preUseCheck(Event event, ItemStack item) {\n return event instanceof EntityShootBowEvent && new Random().nextDouble()<level/20 && ((EntityShootBowEvent)event).getEntity().hasPermission(\"rayken.unsafe\");\n }", "public void activate()\n {\n }", "@Override\n\tpublic void action() {\n\t if (firingBall.getY() + firingBall.getRadius() < this.y) { \n\t //deactivate absorber locally and in GameBoard\n\t firingBall = null;\n\t gb.removeFromActiveList(this);\n\t }\n\t}", "@Override\n public boolean ignoreAbsorbedDamage() {\n return false;\n }", "@Override\n public boolean ignoreAbsorbedDamage() {\n return false;\n }", "@Override\r\n\tpublic void setAbilities() {\n\t\t\r\n\t}", "public void attack() {\n\n }", "public boolean handleAttack(Action action) {\n ActorState a = action.getActor();\n if (a.getActor() == actor) {\n // Attacks on oneself always succeed, and we don't want to add ourselves as an enemy\n return true;\n }\n \n //maybeCounter(Augmentation.Type.ATTACK, a, combatants);\n enemies.add(a);\n \n double weaponAccuracy = 1.0; //source.getWeaponAccuracy(action);\n double chance = a.getAccuracy() * weaponAccuracy * (1.0 - getDefense());\n boolean success = Math.random() < chance;\n return success;\n }", "@Override\n\tpublic void takeHit(int attack) {\n\n\t}", "public void attack();", "@Override\r\n\tpublic void Attack(Player arg0, Player arg1) {\n\t\t\r\n\t}", "@Override\r\n\tpublic void Attack(Player arg0, Player arg1) {\n\t\t\r\n\t}", "@Override\n\tpublic boolean passiveEffect(Character target) {\n\t\treturn false;\n\t}", "public void activate() {\n\t\tactivated = true;\n\t}", "private void c_Activate(String name, boolean activate) {\r\n if(m_active = activate) {\r\n m_botAction.sendSmartPrivateMessage(name, \"Reacting to players who fly over safety tiles.\");\r\n } else {\r\n m_botAction.sendSmartPrivateMessage(name, \"NOT Reacting to players who fly over safety tiles.\");\r\n }\r\n }", "@Override\n public void onActivate() {\n }", "public boolean canAttackWithItem() {\n/* 253 */ return false;\n/* */ }", "public abstract void activatedBy(Player player);", "public void deactivateAbility(LevelManager lm){\n\n int prevDamage = lm.player.getDamage();\n int newDamage = prevDamage-12;\n lm.player.setDamage(newDamage);\n }", "@Override\n\tpublic void attack(Slime slime) {\n\t\t\n\t}", "@Override\n public void activate() {\n\n }", "private void addEnemySheild() {\n this.enemyShield += 1;\n }", "public void activate() {\n\t\t// TODO Auto-generated method stub\n\t}" ]
[ "0.60022086", "0.59808284", "0.5895166", "0.5869993", "0.58539796", "0.5795417", "0.5792679", "0.5704443", "0.56872755", "0.56867313", "0.5675921", "0.5669876", "0.5662793", "0.56623113", "0.56233335", "0.5610221", "0.5610138", "0.55756706", "0.557484", "0.55587643", "0.5537992", "0.5523002", "0.55016416", "0.5472839", "0.5465827", "0.5444693", "0.54183125", "0.54167765", "0.5385989", "0.53708565", "0.5367404", "0.5365288", "0.5363733", "0.5362905", "0.5339633", "0.5330713", "0.5330713", "0.5314122", "0.5311685", "0.5309606", "0.52942693", "0.52905047", "0.5285021", "0.5284126", "0.52828753", "0.5278966", "0.5274065", "0.5273023", "0.52562255", "0.52559555", "0.5253418", "0.5251455", "0.5250134", "0.5246596", "0.5246139", "0.52423114", "0.5241466", "0.52325094", "0.523109", "0.52167296", "0.5216564", "0.5209866", "0.5203627", "0.5194756", "0.5192563", "0.51890373", "0.5184257", "0.5181912", "0.5175039", "0.5173382", "0.5173382", "0.515828", "0.5148704", "0.51484215", "0.5148342", "0.5145823", "0.5144663", "0.51429707", "0.5137473", "0.5136525", "0.51338494", "0.51338494", "0.5133594", "0.5132635", "0.51243824", "0.5121374", "0.51199687", "0.51131594", "0.51131594", "0.51126504", "0.5107823", "0.5107071", "0.51033235", "0.51000595", "0.50943184", "0.509339", "0.50887644", "0.5085403", "0.508519", "0.5083493" ]
0.5870249
3
Return True if the L2Attackable had his soul absorbed.
public boolean isAbsorbed() { return absorbed; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean attackAlly(Ally target) {\n\t\tLog.d(TAG, \"Attacking!\");\n\t\tif (target.takeDamage(damage)) {\n\t\t\treturn true;\n\t\t} else\n\t\t\treturn false;\n\t}", "public boolean shouldExecute() {\n LivingEntity livingentity = ShulkerEntity.this.getAttackTarget();\n if (livingentity != null && livingentity.isAlive()) {\n return ShulkerEntity.this.world.getDifficulty() != Difficulty.PEACEFUL;\n } else {\n return false;\n }\n }", "@Override\n public boolean isUsableEffectTwo() {\n return getEffectsEnable()[1] && getUsableEffect()[1] && ((TargetSquareRequestEvent) getTargetEffectOne()).getPossibleTargetsX().length != 0 && getOwner().canAffortCost(getSecondEffectCost());\n }", "public boolean wantsToAttack() {\n boolean ret = false;\n \n potentialAttackers.clear(); //Previous potentials might no longer be adjacent to an enemy\n \n //Look at all my territories. If it has enough troops to smack someone, it does.\n for(Territory t : gameController.getBoard().getAgentsTerritories(this)){\n if(t.getNumTroops() > 1){\n \n //Check adjacent territories to see if we can do anything about it.\n List<Territory> adjs = gameController.getBoard().getAdjacentTerritories(t);\n for(Territory adj : adjs){\n //Record a boolean so we don't need to call it twice;\n boolean yes = !adj.getOwner().equals(this);\n \n //Check if we have an acceptable chance of success\n int tTroops = t.getNumTroops() - 1;\n int aTroops = adj.getNumTroops();\n double odds = MarkovLookupTable.getOddsOfSuccessfulAttack(tTroops, aTroops);\n yes &= Double.compare(odds, ACCEPTABLE_RISK) >= 0;\n \n //If we can attack with this territory, yes will be true, throw this Territory\n //in the list of potential attackers if it isn't already in there.\n if(yes){\n if(!potentialAttackers.contains(t)){\n potentialAttackers.add(t);\n }\n }\n ret |= yes; //Ret will be set to true and can't be unset if even 1 t can attack\n }\n }\n }\n \n return ret;\n }", "public boolean isAttack() {\n\t\treturn attack;\n\t}", "public boolean isBonusShotAllowed() {\n\t\treturn isLastFrame() && (isStrike() || isSpare());\n\t}", "public boolean canAttack(Figure target) {\n return true;\n }", "public boolean isAttackState() {\n return States.attack.contains(this.state);\n }", "boolean hasDamage();", "boolean hasDamage();", "boolean hasDamage();", "boolean hasDamage();", "boolean hasDamage();", "public boolean hit(Bullet bullet) {\n //System.out.println(\"A golyo nem csapodott meg be semmibe.\");\n return false;\n }", "@Override\n\tpublic boolean isAutoAttackable(L2Character attacker)\n\t{\n\t\tif ((attacker == null) || !(attacker instanceof L2PcInstance))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\tboolean isFort = ((getFort() != null) && (getFort().getResidenceId() > 0) && getFort().getSiege().isInProgress() && !getFort().getSiege().checkIsDefender(((L2PcInstance) attacker).getClan()));\n\t\t\n\t\t// Attackable during siege by all except defenders\n\t\treturn (isFort);\n\t}", "public boolean isSecondBallAllowed() {\n\t\treturn !isStrike() || isBonusShotAllowed();\n\t}", "public boolean hit() {\r\n add(deck.deal());\r\n return getHandValue() <= 21;\r\n }", "protected boolean attackTargetWith(Weapon weapon) {\r\n\t\tint cth = getChanceToHit(character, target, weapon);\r\n\t\tint roll = GameState.getRandomGenerator().nextInt(100);\r\n\t\tboolean hit = roll < cth;\r\n\r\n\t\tString weaponName = weapon != null ? weapon.getName() : \"fists\";\r\n\t\t\r\n\t\tLog.logLocalized(\"AttackRoll\", LogType.COMBAT, character.getName(), cth, target.getName(),weaponName, roll,hit? Strings.getString(CombatManager.STRING_TABLE, \"hit\") : Strings.getString(CombatManager.STRING_TABLE, \"miss\"));\r\n\t\t\r\n\t\tif (hit) {\r\n\t\t\t// ((Weapon Damage + Weapon Bonus + Weapon Skill) / 100) * Enemy Armor Rating\r\n\t\t\tfloat damage = calculateDamage(weapon, character, target);\r\n\t\t\t\r\n\t\t\tLog.logLocalized(\"attackHit\",LogType.COMBAT, character.getName(), target.getName(), MathUtil.toUIString(damage),weaponName);\r\n\t\t\t\r\n\t\t\ttarget.dealDamage(damage, character);\r\n\t\t\tif (weapon != null) {\r\n\t\t\t\tweapon.executeEffects(character, target);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\ttarget.onAttack(character);\r\n\t\t}\r\n\t\tif (++attackedWeaponCount >= attackingWeapons.size) {\r\n\t\t\tattackFinished = true;\r\n\t\t}\r\n\t\treturn hit;\r\n\t}", "@Override\n\tpublic boolean shouldExecute() {\n\t\tif (!theEntityTameable.isTamed())\n\t\t\treturn false;\n\t\telse {\n\t\t\tfinal EntityLivingBase var1 = theEntityTameable.getOwner();\n\n\t\t\tif (var1 == null)\n\t\t\t\treturn false;\n\t\t\telse {\n\t\t\t\ttheTarget = var1.getLastAttacker();\n\t\t\t\tfinal int var2 = var1.getLastAttackerTime();\n\t\t\t\treturn var2 != field_142050_e\n\t\t\t\t\t\t&& isSuitableTarget(theTarget, false)\n\t\t\t\t\t\t&& theEntityTameable.func_142018_a(theTarget, var1);\n\t\t\t}\n\t\t}\n\t}", "public boolean hit()\n\t{\n\t\taddCardToHand(new BlackJackCard());\n\t\treturn getHandValue() <= 21;\n\t}", "public boolean canHit() {\n\t\treturn this.hand.countValue().first() < 17;\n\t}", "public boolean isBusted() {\n\t\tif (hand.checkHandValue() > 21) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public boolean canAttackWithItem() {\n/* 215 */ return false;\n/* */ }", "public boolean gameOver(){\n\t\treturn this.lives < 1;\n\t}", "public boolean canOfferInsurance() {\n\t\treturn this.hand.getCards().get(0) == Card.ACE;\n\t}", "public boolean hitDealer() {\r\n while (getHandValue() <= 16) {\r\n hit();\r\n }\r\n return getHandValue() <= 21;\r\n }", "public boolean canAttackWithItem() {\n/* 253 */ return false;\n/* */ }", "public boolean isTurnOngoing() {\n int numEntitiesWithActions = 0;\n for (Entity entity : entitiesInCombat) {\n if (entity.canAct()) {\n numEntitiesWithActions++;\n }\n }\n return numEntitiesWithActions > 0;\n }", "public boolean isOverhit()\n\t{\n\t\treturn overhit;\n\t}", "public boolean eat() {\n\n if (this.hungerLevel > 0) {\n --this.hungerLevel; // Lower hunger after eating.\n return true;\n }\n return false;\n }", "public boolean checkOpportunityAttacks(Creature creature) {\n/* 2073 */ Creature[] lTempCreatures = getCreatures();\n/* 2074 */ for (int x = 0; x < lTempCreatures.length; x++) {\n/* */ \n/* 2076 */ if (lTempCreatures[x] != creature && !lTempCreatures[x].isMoving())\n/* */ {\n/* 2078 */ if (lTempCreatures[x].getAttitude(creature) == 2)\n/* */ {\n/* */ \n/* 2081 */ if (VirtualZone.isCreatureTurnedTowardsTarget(creature, lTempCreatures[x]))\n/* 2082 */ return lTempCreatures[x].opportunityAttack(creature); \n/* */ }\n/* */ }\n/* */ } \n/* 2086 */ return false;\n/* */ }", "public boolean canFly() {\n\t\treturn !isEgg() && !isHatchling();\n\t}", "private void levelSoulCrystals(final L2Character attacker)\n\t{\n\t\t// Only L2PcInstance can absorb a soul\n\t\tif (!(attacker instanceof L2PcInstance) && !(attacker instanceof L2Summon))\n\t\t{\n\t\t\tresetAbsorbList();\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tfinal int maxAbsorbLevel = getAbsorbLevel();\n\t\tint minAbsorbLevel = 0;\n\t\t\n\t\t// If this is not a valid L2Attackable, clears the absorbersList and just return\n\t\tif (maxAbsorbLevel == 0)\n\t\t{\n\t\t\tresetAbsorbList();\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// All boss mobs with maxAbsorbLevel 13 have minAbsorbLevel of 12 else 10\n\t\tif (maxAbsorbLevel > 10)\n\t\t{\n\t\t\tminAbsorbLevel = maxAbsorbLevel > 12 ? 12 : 10;\n\t\t}\n\t\t\n\t\t// Init some useful vars\n\t\tboolean isSuccess = true;\n\t\tboolean doLevelup = true;\n\t\tfinal boolean isBossMob = maxAbsorbLevel > 10 ? true : false;\n\t\t\n\t\tfinal L2NpcTemplate.AbsorbCrystalType absorbType = getTemplate().absorbType;\n\t\t\n\t\tL2PcInstance killer = attacker instanceof L2Summon ? ((L2Summon) attacker).getOwner() : (L2PcInstance) attacker;\n\t\t\n\t\t// If this mob is a boss, then skip some checkings\n\t\tif (!isBossMob)\n\t\t{\n\t\t\t// Fail if this L2Attackable isn't absorbed or there's no one in its absorbersList\n\t\t\tif (!isAbsorbed() /* || absorbersList == null */)\n\t\t\t{\n\t\t\t\tresetAbsorbList();\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\t// Fail if the killer isn't in the absorbersList of this L2Attackable and mob is not boss\n\t\t\tAbsorberInfo ai = absorbersList.get(killer);\n\t\t\tif (ai == null || ai.absorber.getObjectId() != killer.getObjectId())\n\t\t\t{\n\t\t\t\tisSuccess = false;\n\t\t\t}\n\t\t\t\n\t\t\t// Check if the soul crystal was used when HP of this L2Attackable wasn't higher than half of it\n\t\t\tif (ai != null && ai.absorbedHP > getMaxHp() / 2.0)\n\t\t\t{\n\t\t\t\tisSuccess = false;\n\t\t\t}\n\t\t\t\n\t\t\tif (!isSuccess)\n\t\t\t{\n\t\t\t\tresetAbsorbList();\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tai = null;\n\t\t}\n\t\t\n\t\t// ********\n\t\tString[] crystalNFO = null;\n\t\tString crystalNME = \"\";\n\t\t\n\t\tfinal int dice = Rnd.get(100);\n\t\tint crystalQTY = 0;\n\t\tint crystalLVL = 0;\n\t\tint crystalOLD = 0;\n\t\tint crystalNEW = 0;\n\t\t\n\t\t// ********\n\t\t// Now we have four choices:\n\t\t// 1- The Monster level is too low for the crystal. Nothing happens.\n\t\t// 2- Everything is correct, but it failed. Nothing happens. (57.5%)\n\t\t// 3- Everything is correct, but it failed. The crystal scatters. A sound event is played. (10%)\n\t\t// 4- Everything is correct, the crystal level up. A sound event is played. (32.5%)\n\t\t\n\t\tList<L2PcInstance> players = new ArrayList<>();\n\t\t\n\t\tif (absorbType == L2NpcTemplate.AbsorbCrystalType.FULL_PARTY && killer.isInParty())\n\t\t{\n\t\t\tplayers = killer.getParty().getPartyMembers();\n\t\t}\n\t\telse if (absorbType == L2NpcTemplate.AbsorbCrystalType.PARTY_ONE_RANDOM && killer.isInParty())\n\t\t{\n\t\t\t// This is a naive method for selecting a random member. It gets any random party member and\n\t\t\t// then checks if the member has a valid crystal. It does not select the random party member\n\t\t\t// among those who have crystals, only. However, this might actually be correct (same as retail).\n\t\t\tplayers.add(killer.getParty().getPartyMembers().get(Rnd.get(killer.getParty().getMemberCount())));\n\t\t}\n\t\telse\n\t\t{\n\t\t\tplayers.add(killer);\n\t\t}\n\t\t\n\t\tfor (final L2PcInstance player : players)\n\t\t{\n\t\t\tif (player == null)\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\tcrystalQTY = 0;\n\t\t\t\n\t\t\tL2ItemInstance[] inv = player.getInventory().getItems();\n\t\t\tfor (final L2ItemInstance item : inv)\n\t\t\t{\n\t\t\t\tfinal int itemId = item.getItemId();\n\t\t\t\tfor (final int id : SoulCrystal.SoulCrystalTable)\n\t\t\t\t{\n\t\t\t\t\t// Find any of the 39 possible crystals.\n\t\t\t\t\tif (id == itemId)\n\t\t\t\t\t{\n\t\t\t\t\t\tcrystalQTY++;\n\t\t\t\t\t\t// Keep count but make sure the player has no more than 1 crystal\n\t\t\t\t\t\tif (crystalQTY > 1)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tisSuccess = false;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Validate if the crystal has already leveled\n\t\t\t\t\t\tif (id != SoulCrystal.RED_NEW_CRYSTAL && id != SoulCrystal.GRN_NEW_CYRSTAL && id != SoulCrystal.BLU_NEW_CRYSTAL)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\ttry\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (item.getItem().getName().contains(\"Grade\"))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t// Split the name of the crystal into 'name' & 'level'\n\t\t\t\t\t\t\t\t\tcrystalNFO = item.getItem().getName().trim().replace(\" Grade \", \"-\").split(\"-\");\n\t\t\t\t\t\t\t\t\t// Set Level to 13\n\t\t\t\t\t\t\t\t\tcrystalLVL = 13;\n\t\t\t\t\t\t\t\t\t// Get Name\n\t\t\t\t\t\t\t\t\tcrystalNME = crystalNFO[0].toLowerCase();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t// Split the name of the crystal into 'name' & 'level'\n\t\t\t\t\t\t\t\t\tcrystalNFO = item.getItem().getName().trim().replace(\" Stage \", \"\").split(\"-\");\n\t\t\t\t\t\t\t\t\t// Get Level\n\t\t\t\t\t\t\t\t\tcrystalLVL = Integer.parseInt(crystalNFO[1].trim());\n\t\t\t\t\t\t\t\t\t// Get Name\n\t\t\t\t\t\t\t\t\tcrystalNME = crystalNFO[0].toLowerCase();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t// Allocate current and levelup ids' for higher level crystals\n\t\t\t\t\t\t\t\tif (crystalLVL > 9)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tfor (final int[] element : SoulCrystal.HighSoulConvert)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t// Get the next stage above 10 using array.\n\t\t\t\t\t\t\t\t\t\tif (id == element[0])\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tcrystalNEW = element[1];\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tcrystalNEW = id + 1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tcatch (final NumberFormatException nfe)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tLOGGER.warn(\"An attempt to identify a soul crystal failed, \" + \"verify the names have not changed in etcitem table.\", nfe);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tplayer.sendMessage(\"There has been an error handling your soul crystal.\" + \" Please notify your server admin.\");\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tisSuccess = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tcatch (final Exception e)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t\t\tisSuccess = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcrystalNME = item.getItem().getName().toLowerCase().trim();\n\t\t\t\t\t\t\tcrystalNEW = id + 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Done\n\t\t\t\t\t\tcrystalOLD = id;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (!isSuccess)\n\t\t\t\t{\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tinv = null;\n\t\t\t\n\t\t\t// If the crystal level is way too high for this mob, say that we can't increase it\n\t\t\tif (crystalLVL < minAbsorbLevel || crystalLVL >= maxAbsorbLevel)\n\t\t\t{\n\t\t\t\tdoLevelup = false;\n\t\t\t}\n\t\t\t\n\t\t\t// The player doesn't have any crystals with him get to the next player.\n\t\t\tif (crystalQTY < 1 || crystalQTY > 1 || !isSuccess || !doLevelup)\n\t\t\t{\n\t\t\t\t// Too many crystals in inventory.\n\t\t\t\tif (crystalQTY > 1)\n\t\t\t\t{\n\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_FAILED_RESONATION));\n\t\t\t\t}\n\t\t\t\t// The soul crystal stage of the player is way too high\n\t\t\t\t// Like L2OFF message must not appear if char hasn't crystal on inventory\n\t\t\t\telse if (!doLevelup && crystalQTY > 0)\n\t\t\t\t{\n\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_REFUSED));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tcrystalQTY = 0;\n\t\t\t\t\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\t/*\n\t\t\t * TODO: Confirm boss chance for crystal level up and for crystal breaking. It is known that bosses with FULL_PARTY crystal level ups have 100% success rate, but this is not the case for the other bosses (one-random or last-hit). While not confirmed, it is most reasonable that crystals leveled up at\n\t\t\t * bosses will never break. Also, the chance to level up is guessed as around 70% if not higher.\n\t\t\t */\n\t\t\tfinal int chanceLevelUp = isBossMob ? 70 : SoulCrystal.LEVEL_CHANCE;\n\t\t\t\n\t\t\t// If succeeds or it is a full party absorb, level up the crystal.\n\t\t\tif (absorbType == L2NpcTemplate.AbsorbCrystalType.FULL_PARTY && doLevelup || dice <= chanceLevelUp)\n\t\t\t{\n\t\t\t\t// Give staged crystal\n\t\t\t\texchangeCrystal(player, crystalOLD, crystalNEW, false);\n\t\t\t}\n\t\t\t\n\t\t\t// If true and not a last-hit mob, break the crystal.\n\t\t\telse if (!isBossMob && dice >= 100.0 - SoulCrystal.BREAK_CHANCE)\n\t\t\t{\n\t\t\t\t// Remove current crystal an give a broken open.\n\t\t\t\tif (crystalNME.startsWith(\"red\"))\n\t\t\t\t{\n\t\t\t\t\texchangeCrystal(player, crystalOLD, SoulCrystal.RED_BROKEN_CRYSTAL, true);\n\t\t\t\t}\n\t\t\t\telse if (crystalNME.startsWith(\"gre\"))\n\t\t\t\t{\n\t\t\t\t\texchangeCrystal(player, crystalOLD, SoulCrystal.GRN_BROKEN_CYRSTAL, true);\n\t\t\t\t}\n\t\t\t\telse if (crystalNME.startsWith(\"blu\"))\n\t\t\t\t{\n\t\t\t\t\texchangeCrystal(player, crystalOLD, SoulCrystal.BLU_BROKEN_CRYSTAL, true);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tresetAbsorbList();\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_FAILED));\n\t\t\t}\n\t\t}\n\t\t\n\t\tkiller = null;\n\t\tplayers = null;\n\t\tcrystalNFO = null;\n\t\tcrystalNME = null;\n\t}", "public boolean interupted(Creature Opponent){\n if (Opponent.selected_manuever.type.equals(\"Attack\") && Opponent.maneuver_pass && this.interruptable) { interupt_count++; return true; }\n else { return false; }\n }", "public boolean attack(Combatant target) {\r\n for (int i = 0; i < numAttacks; i++) {\r\n int attackRoll = this.basicAttackToHit();\r\n\r\n if (attackRoll == (20 + toHit)) { //Critical case, double number of damage dice\r\n target.setCurrentHitPoints(target.getHitPoints() - (this.basicAttackDamage() + damageDice.roll()));\r\n } else if (attackRoll == 1 + toHit) { //Natural 1 case, auto miss\r\n continue;\r\n } else if (attackRoll > target.getAC()) { //Regular hit case\r\n target.setCurrentHitPoints(target.getHitPoints() - this.basicAttackDamage());\r\n } else { //Miss case\r\n continue;\r\n }\r\n\r\n if (target.getHitPoints() <= 0) {\r\n this.win();\r\n return true;\r\n }\r\n }\r\n return false;\r\n }", "public boolean checkBonus() {\r\n\t\tif (bonus) {\r\n\t\t\tbonus = false;\r\n\t\t\treturn true;\r\n\t\t} else {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}", "@Override\n public boolean isUsableEffectOne() {\n return getEffectsEnable()[0] && getUsableEffect()[0] && ((TargetSquareRequestEvent) getTargetEffectOne()).getPossibleTargetsX().length != 0;\n }", "public boolean handleAttack(Action action) {\n ActorState a = action.getActor();\n if (a.getActor() == actor) {\n // Attacks on oneself always succeed, and we don't want to add ourselves as an enemy\n return true;\n }\n \n //maybeCounter(Augmentation.Type.ATTACK, a, combatants);\n enemies.add(a);\n \n double weaponAccuracy = 1.0; //source.getWeaponAccuracy(action);\n double chance = a.getAccuracy() * weaponAccuracy * (1.0 - getDefense());\n boolean success = Math.random() < chance;\n return success;\n }", "public boolean shouldExecute() {\n return this.entity.getAttackTarget() != null && this.isBowInMainhand();\n }", "private boolean shouldAttackPlayer(EntityPlayer player) {\n ItemStack itemStack = player.inventory.armorInventory[3];\n if (itemStack != null && itemStack.getItem() == Item.getItemFromBlock(Blocks.pumpkin))\n return false;\n Vec3 lookVec = player.getLook(1.0F).normalize();\n Vec3 posVec = Vec3.createVectorHelper(this.posX - player.posX, this.boundingBox.minY + this.height / 2.0 - player.posY - player.getEyeHeight(), this.posZ - player.posZ);\n double distance = posVec.lengthVector();\n posVec = posVec.normalize();\n double dotProduct = lookVec.dotProduct(posVec);\n return dotProduct > 1.0 - 0.025 / distance ? player.canEntityBeSeen(this) : false;\n }", "public boolean shouldHit() {\r\n\t\tif(getHandVal() < 17) {\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\treturn false; \r\n\t}", "public boolean successfulHit(CreatureAttack attack, Creature attacked){\r\n return attack.attacker.attributes.health.accuracy.next() >= attacked.attributes.health.evasion.next();\r\n }", "public boolean isAlive(){\r\n if (currHP > 0){\r\n return true;\r\n }\r\n return false;\r\n }", "private boolean canTakeBandanaFrom(Unit other) {\n return getCalories() >= (2 * other.getCalories());\n }", "public boolean shouldExecute() {\n return ShulkerEntity.this.getAttackTarget() == null && ShulkerEntity.this.rand.nextInt(40) == 0;\n }", "public boolean canAttack(Combatant aCombatant)\n\t{\n\t\treturn false;\n\t}", "@Override\n public boolean shouldHeal(ActivePokemon p) {\n return p.hasStatus();\n }", "@Override\n public boolean shouldHeal(ActivePokemon p) {\n return p.hasStatus();\n }", "public boolean isAlive() {\r\n\t\treturn hp > 0;\r\n\t}", "private boolean isOver() {\r\n return players.size() == 1;\r\n }", "public abstract boolean attack(Warrior w);", "public Boolean checkBust() {\n\t\tif (getHandValue() > 21) {\n\t\t\tSystem.out.println(name + \" Busted!\");\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}", "private boolean didPlayerLose() {\r\n return mouseListeningMode && bird.getNumThrowsRemaining() == 0;\r\n }", "public boolean isInvulnerable ( ) {\n\t\ttry {\n\t\t\treturn invokeSafe ( \"isInvulnerable\" );\n\t\t} catch ( NoSuchMethodError ex ) { // legacy\n\t\t\tPlayer handle = handleOptional ( ).orElse ( null );\n\t\t\t\n\t\t\treturn handle != null && EntityReflection.isInvulnerable ( handle );\n\t\t}\n\t}", "public boolean completed(){\n return !activeAttackers() && !attackersLeft();\n }", "public static boolean onhand() {\n return InventoryManager.getCount(ItemPool.COMBAT_LOVERS_LOCKET) > 0\n || KoLCharacter.hasEquipped(ItemPool.COMBAT_LOVERS_LOCKET);\n }", "public boolean damagable() {\n return !this.state.equals(\"knockedBack\")\n && !this.state.equals(\"dodge\");\n }", "@Override\n\tpublic boolean shouldExecute() {\n\t\tif (!theEntity.isTamed())\n\t\t\treturn false;\n\t\telse if (theEntity.isInWater())\n\t\t\treturn false;\n\t\telse if (!theEntity.onGround)\n\t\t\treturn false;\n\t\telse {\n\t\t\tfinal EntityLivingBase var1 = theEntity.getOwner();\n\t\t\treturn var1 == null ? true\n\t\t\t\t\t: theEntity.getDistanceSqToEntity(var1) < 144.0D\n\t\t\t\t\t\t\t&& var1.getAITarget() != null ? false : isSitting;\n\t\t}\n\t}", "public void isStillInCombat() {\n isInCombat = enemiesInCombat.size() > 0;\n }", "public boolean Lost()\n {\n return this.numLives <= 0;\n }", "public boolean hitBy(Pweapon weapon, Tower tower) {\r\n\t\tif (!spawned)\r\n\t\t\treturn false;\r\n\r\n\t\t// System.out.println(\"Tir avec arme : \" + weapon.getNameWeapon());\r\n\t\tif (!tower.isControledByPlayer()) {\r\n\t\t\t// if (decideShootMiss(tower)) {\r\n\t\t\tthis.health -= weapon.getDamage();\r\n\t\t\t// }\r\n\t\t} else {\r\n\t\t\tthis.health -= weapon.getDamage();\r\n\t\t}\r\n\t\tif (this.health <= 0) {\r\n\t\t\tthis.health = 0;\r\n\t\t\tthis.spawned = false;\r\n\t\t}\r\n\t\treturn this.health == 0;\r\n\t}", "boolean isGameOver() {\n\t\treturn Hit;\n\t}", "boolean gameOver() {\n return piecesContiguous(BP) || piecesContiguous(WP);\n }", "public static boolean checkVictory(){\n\t\tboolean victory = true;\n\t\t\n\t\tfor (int i = 0; i < enemyList.length && victory; i++) {\n\t\t\tif (enemyList[i].isAlive()) {\n\t\t\t\tvictory = false;\n\t\t\t}\n\t\t}\n\t\treturn victory;\n\t}", "public boolean isUseable()\n {\n if (state == 0)\n {\n return true;\n }\n return false;\n }", "public boolean isAlface(){\n return salada.isAlface();\n }", "boolean collidesEnemy() {\n for(int i = 0; i < barrage.size(); i++) {\n // establish a rectangle for the laser\n Rectangle blaster = new Rectangle((int)barrage.get(i).getX(), (int)barrage.get(i).getY(), WIDTH, HEIGHT);\n \n // determine if the laser intersects an enemy\n for (int q = 0; q < fleet.size(); q++) {\n Rectangle enemy = new Rectangle((int)fleet.get(q).getX(), (int)fleet.get(q).getY(), 40, 36); \n \n // if blaster hits a ship, remove it\n if (blaster.intersects(enemy) && fleet.get(q).getCount() == 0) {\n fleet.get(q).hit = true; // set the enemy hit\n barrage.remove(barrage.get(i));\n score += 100; // add to score\n return true; // hit\n }\n }\n }\n return false; // miss\n }", "public boolean isBurning()\n {\n return this.fuel > 0 && this.canSmelt();\n }", "static boolean willCollideWithMe(BulletInfo bullet) {\n\t\tMapLocation myLocation = rc.getLocation();\n\n\t\t// Get relevant bullet information\n\t\tDirection propagationDirection = bullet.dir;\n\t\tMapLocation bulletLocation = bullet.location;\n\n\t\t// Calculate bullet relations to this robot\n\t\tDirection directionToRobot = bulletLocation.directionTo(myLocation);\n\t\tfloat distToRobot = bulletLocation.distanceTo(myLocation);\n\t\tfloat theta = propagationDirection.radiansBetween(directionToRobot);\n\n\t\t// If theta > 90 degrees, then the bullet is traveling away from us and we can break early\n\t\tif (Math.abs(theta) > Math.PI/2) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// distToRobot is our hypotenuse, theta is our angle, and we want to know this length of the opposite leg.\n\t\t// This is the distance of a line that goes from myLocation and intersects perpendicularly with propagationDirection.\n\t\t// This corresponds to the smallest radius circle centered at our location that would intersect with the\n\t\t// line that is the path of the bullet.\n\t\tfloat perpendicularDist = (float)Math.abs(distToRobot * Math.sin(theta)); // soh cah toa :)\n\n\t\treturn (perpendicularDist <= rc.getType().bodyRadius);\n\t}", "public boolean isInvulnerable() {\n return _invulnerable;\n }", "public boolean isAlive(){\n if(this.hp <= 0){\n return false;\n }\n else{\n return true;\n }\n }", "public static boolean isDealingBurnDamageToBothPlayersAndContinuingGame (int burnDamage) {\r\n boolean isDefeaingPlayer = (burnDamage >= Game.lifePointsPlayer);\r\n boolean isDefeatingCPU = (burnDamage >= Game.lifePointsCPU);\r\n if (isDefeaingPlayer && isDefeatingCPU) {\r\n Game.lifePointsPlayer=0;\r\n Game.lifePointsCPU=0;\r\n YuGiOhJi.informationDialog(\"Both players take \" + burnDamage + \" burn damage.\", \"\");\r\n YuGiOhJi.informationDialog(\"The life points of both players have been reduced to zero.\", \"DRAW!\");\r\n // display some hidden achievements here, if unlocked\r\n YuGiOhJi.informationDialog(\"Hidden achievement found: \\\"Worthy Adversary\\\". You let a game result in a draw.\", \"\"); Game.unlockTrophy(Game.trophyAdversaryUnlocked);\r\n // end of listing of achievements\r\n Game.over();\r\n return false; // GAME OVER\r\n }\r\n else if (isDefeaingPlayer && !isDefeatingCPU) {\r\n isDealingBattleDamageAndContinuingGame(true, burnDamage, false); // GAME OVER already happens inside the method\r\n return false; // GAME OVER\r\n }\r\n else if (!isDefeaingPlayer && isDefeatingCPU) {\r\n isDealingBattleDamageAndContinuingGame(true, burnDamage, true); // GAME OVER already happens inside the method\r\n return false; // GAME OVER\r\n }\r\n else {\r\n YuGiOhJi.informationDialog(\"Both players take \" + burnDamage + \" burn damage.\", \"\");\r\n Game.lifePointsPlayer = Game.lifePointsPlayer-burnDamage;\r\n Game.lifePointsCPU = Game.lifePointsCPU-burnDamage;\r\n YuGiOhJi.updateDisplayedLP();\r\n return true; // game continues\r\n }\r\n }", "private boolean canSmelt()\n {\n ItemStack var1 = FurnaceRecipes.smelting().getSmeltingResult(this.furnaceItemStacks[0]);\n if (var1 == null) return false;\n if (this.furnaceItemStacks[2] == null) return true;\n if (!this.furnaceItemStacks[2].isItemEqual(var1)) return false;\n int result = furnaceItemStacks[2].stackSize + var1.stackSize;\n return (result <= getInventoryStackLimit() && result <= var1.getMaxStackSize());\n }", "public static boolean isSomethingToAttackDefined() {\n\t\treturn _attackTargetUnit != null && !_attackTargetUnit.getType().isOnGeyser();\n\t}", "boolean hasBonusHP();", "public boolean isInCombat() {\n return isInCombat;\n }", "public boolean isOver() {\n\t\t\n\t\tif(!dealer.hasCards()){\n\t\t\tisOver= true;\n\t\t\treturn isOver;\n\t\t}\n\t\t\n\t\tfor (Player p : players) {\n\t\t\tif (!p.hasCards()) {\n\t\t\t\tisOver = true;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn isOver;\n\t}", "public boolean isBattleOver(){\n\n if(battleEnemies.size() == 0) {\n System.out.println(\"Battle over all enemies dead\");\n findDefeated();\n cleanStatuses();\n result = true;\n\n return true;\n }\n if(character.getCurrHP() <= 0){\n System.out.println(\"Battle over character has died\");\n //findDefeated();\n cleanStatuses();\n result = false;\n\n return true;\n }\n //System.out.printf(\"remaining enemies: %s\\n\", battleEnemies.size());\n return false;\n }", "public boolean isCardToAccuse() {\n\t\treturn (getOwner() == CASE_FILE_PLAYER);\n\t}", "@Override\n\tpublic boolean performsAttackAnimation() {\n\t\tif (phase == AbyssalSirePhase.MAGIC_COMBAT && attack == AbyssalSireAttack.POISON) {\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "@Override\n\tpublic boolean attackEntityFrom(DamageSource src, float par2) {\n\t\tif (isInvulnerableTo(src)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// don't just sit there!\n\t\taiSit.setSitting(false);\n\n\t\treturn super.attackEntityFrom(src, par2);\n\t}", "protected boolean IsHighExplosive()\r\n {\r\n \t// Wrapper function to make code a little cleaner.\r\n // isInvulnerable() is wrongly named and instead represents the specific\r\n // skull type the wither has launched\r\n \t\r\n \treturn isInvulnerable();\r\n }", "boolean hasAttackerRoleId();", "private boolean canEnlist() {\n\n return uiStateManager.getState().equals(GameUIState.WAVE_IN_PROGRESS)\n || uiStateManager.getState().equals(GameUIState.STANDBY);\n }", "public boolean isShootUp() {\n return shootUp;\n }", "public abstract boolean attack(KillableItem i);", "@Override\n\tpublic boolean isHungry() {\n\t\treturn false;\n\t}", "@Override\n\tpublic boolean isOnLadder() {\n\t\t// this better doesn't happen...\n\t\treturn false;\n\t}", "@Override\r\n\tpublic boolean canAttackEntity(Entity entity) {\n\t\treturn false;\r\n\t}", "@Override\r\n\tpublic boolean canAttackEntity(Entity entity) {\n\t\treturn false;\r\n\t}", "public boolean attack(int dir) {\n\t\treturn false;\n\t}", "public boolean checkIfPlayerHoldsExplosive () { return noOfExplosives > 0; }", "public boolean isCollition(Sprite sprite2) {\n if (this.x < sprite2.getX() + sprite2.getAncho() &&\n this.x + this.ancho > sprite2.getX() &&\n this.y + this.alto > sprite2.getY() &&\n this.y < sprite2.getY() + sprite2.getAlto()) {\n return true;\n\n } else {\n return false;\n }\n\n }", "public boolean isGoal() {\n return hamming() == 0;\n }", "public boolean isGoal() {\n return hamming() == 0;\n }", "public boolean isGoal() {\n return hamming() == 0;\n }", "public boolean isGoal() {\n return hamming() == 0;\n }", "public boolean isGoal() {\n return hamming() == 0;\n }", "public boolean isGoal() {\n return hamming() == 0;\n }", "public boolean hitOrStand(){\r\n\t\treturn hitOrStand;\r\n\t}" ]
[ "0.6447066", "0.63121957", "0.622723", "0.615383", "0.61070067", "0.6083449", "0.6076714", "0.605486", "0.6047523", "0.6047523", "0.6047523", "0.6047523", "0.6047523", "0.6039982", "0.6032416", "0.6004265", "0.5986198", "0.5967587", "0.59665674", "0.5964459", "0.5940768", "0.5934471", "0.5926092", "0.5918608", "0.5917635", "0.59130806", "0.5906294", "0.5887403", "0.58733946", "0.5835983", "0.5817675", "0.58063036", "0.5806084", "0.579577", "0.57917154", "0.57826275", "0.5768308", "0.57619876", "0.575185", "0.573084", "0.57259125", "0.57258815", "0.5725873", "0.5706707", "0.56985015", "0.5696623", "0.5686648", "0.5686648", "0.5682693", "0.56784695", "0.5671994", "0.56691694", "0.56674886", "0.5662185", "0.5659833", "0.5650282", "0.5648401", "0.5644888", "0.56384534", "0.5631794", "0.5627893", "0.5608284", "0.5602698", "0.56003433", "0.5599643", "0.5592832", "0.55918044", "0.55916435", "0.5590679", "0.5585225", "0.55852085", "0.5584372", "0.558205", "0.55805844", "0.557731", "0.5569721", "0.5566339", "0.5561589", "0.55606174", "0.555907", "0.55555326", "0.5552244", "0.5548843", "0.55468476", "0.5543724", "0.55276436", "0.5526058", "0.5525097", "0.5523971", "0.5523971", "0.55183965", "0.5516769", "0.5510164", "0.55071616", "0.55071616", "0.55071616", "0.55071616", "0.55071616", "0.55071616", "0.5506296" ]
0.57608515
38
Adds an attacker that successfully absorbed the soul of this L2Attackable into the absorbersList.
public void addAbsorber(final L2PcInstance attacker, final int crystalId) { // This just works for targets like L2MonsterInstance if (!(this instanceof L2MonsterInstance)) { return; } // The attacker must not be null if (attacker == null) { return; } // This L2Attackable must be of one type in the absorbingMOBS_levelXX tables. // OBS: This is done so to avoid triggering the absorbed conditions for mobs that can't be absorbed. if (getAbsorbLevel() == 0) { return; } // If we have no absorbersList initiated, do it AbsorberInfo ai = absorbersList.get(attacker); // If the L2Character attacker isn't already in the absorbersList of this L2Attackable, add it if (ai == null) { ai = new AbsorberInfo(attacker, crystalId, getCurrentHp()); absorbersList.put(attacker, ai); } else { ai.absorber = attacker; ai.crystalId = crystalId; ai.absorbedHP = getCurrentHp(); } // Set this L2Attackable as absorbed absorbSoul(); ai = null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void addAttacks(){\n while(!attacksToAdd.isEmpty()){\n attacks.add(attacksToAdd.remove());\n }\n }", "private void addEnemySheild() {\n this.enemyShield += 1;\n }", "void addAttack(AttackObject newAttack) {\n if (canAddAttack(newAttack)) {\n attacksToAdd.add(newAttack);\n if(newAttack.isPlayerAttack()){\n playerAttackCount++;\n }\n }\n }", "private void levelSoulCrystals(final L2Character attacker)\n\t{\n\t\t// Only L2PcInstance can absorb a soul\n\t\tif (!(attacker instanceof L2PcInstance) && !(attacker instanceof L2Summon))\n\t\t{\n\t\t\tresetAbsorbList();\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tfinal int maxAbsorbLevel = getAbsorbLevel();\n\t\tint minAbsorbLevel = 0;\n\t\t\n\t\t// If this is not a valid L2Attackable, clears the absorbersList and just return\n\t\tif (maxAbsorbLevel == 0)\n\t\t{\n\t\t\tresetAbsorbList();\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// All boss mobs with maxAbsorbLevel 13 have minAbsorbLevel of 12 else 10\n\t\tif (maxAbsorbLevel > 10)\n\t\t{\n\t\t\tminAbsorbLevel = maxAbsorbLevel > 12 ? 12 : 10;\n\t\t}\n\t\t\n\t\t// Init some useful vars\n\t\tboolean isSuccess = true;\n\t\tboolean doLevelup = true;\n\t\tfinal boolean isBossMob = maxAbsorbLevel > 10 ? true : false;\n\t\t\n\t\tfinal L2NpcTemplate.AbsorbCrystalType absorbType = getTemplate().absorbType;\n\t\t\n\t\tL2PcInstance killer = attacker instanceof L2Summon ? ((L2Summon) attacker).getOwner() : (L2PcInstance) attacker;\n\t\t\n\t\t// If this mob is a boss, then skip some checkings\n\t\tif (!isBossMob)\n\t\t{\n\t\t\t// Fail if this L2Attackable isn't absorbed or there's no one in its absorbersList\n\t\t\tif (!isAbsorbed() /* || absorbersList == null */)\n\t\t\t{\n\t\t\t\tresetAbsorbList();\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\t// Fail if the killer isn't in the absorbersList of this L2Attackable and mob is not boss\n\t\t\tAbsorberInfo ai = absorbersList.get(killer);\n\t\t\tif (ai == null || ai.absorber.getObjectId() != killer.getObjectId())\n\t\t\t{\n\t\t\t\tisSuccess = false;\n\t\t\t}\n\t\t\t\n\t\t\t// Check if the soul crystal was used when HP of this L2Attackable wasn't higher than half of it\n\t\t\tif (ai != null && ai.absorbedHP > getMaxHp() / 2.0)\n\t\t\t{\n\t\t\t\tisSuccess = false;\n\t\t\t}\n\t\t\t\n\t\t\tif (!isSuccess)\n\t\t\t{\n\t\t\t\tresetAbsorbList();\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tai = null;\n\t\t}\n\t\t\n\t\t// ********\n\t\tString[] crystalNFO = null;\n\t\tString crystalNME = \"\";\n\t\t\n\t\tfinal int dice = Rnd.get(100);\n\t\tint crystalQTY = 0;\n\t\tint crystalLVL = 0;\n\t\tint crystalOLD = 0;\n\t\tint crystalNEW = 0;\n\t\t\n\t\t// ********\n\t\t// Now we have four choices:\n\t\t// 1- The Monster level is too low for the crystal. Nothing happens.\n\t\t// 2- Everything is correct, but it failed. Nothing happens. (57.5%)\n\t\t// 3- Everything is correct, but it failed. The crystal scatters. A sound event is played. (10%)\n\t\t// 4- Everything is correct, the crystal level up. A sound event is played. (32.5%)\n\t\t\n\t\tList<L2PcInstance> players = new ArrayList<>();\n\t\t\n\t\tif (absorbType == L2NpcTemplate.AbsorbCrystalType.FULL_PARTY && killer.isInParty())\n\t\t{\n\t\t\tplayers = killer.getParty().getPartyMembers();\n\t\t}\n\t\telse if (absorbType == L2NpcTemplate.AbsorbCrystalType.PARTY_ONE_RANDOM && killer.isInParty())\n\t\t{\n\t\t\t// This is a naive method for selecting a random member. It gets any random party member and\n\t\t\t// then checks if the member has a valid crystal. It does not select the random party member\n\t\t\t// among those who have crystals, only. However, this might actually be correct (same as retail).\n\t\t\tplayers.add(killer.getParty().getPartyMembers().get(Rnd.get(killer.getParty().getMemberCount())));\n\t\t}\n\t\telse\n\t\t{\n\t\t\tplayers.add(killer);\n\t\t}\n\t\t\n\t\tfor (final L2PcInstance player : players)\n\t\t{\n\t\t\tif (player == null)\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\tcrystalQTY = 0;\n\t\t\t\n\t\t\tL2ItemInstance[] inv = player.getInventory().getItems();\n\t\t\tfor (final L2ItemInstance item : inv)\n\t\t\t{\n\t\t\t\tfinal int itemId = item.getItemId();\n\t\t\t\tfor (final int id : SoulCrystal.SoulCrystalTable)\n\t\t\t\t{\n\t\t\t\t\t// Find any of the 39 possible crystals.\n\t\t\t\t\tif (id == itemId)\n\t\t\t\t\t{\n\t\t\t\t\t\tcrystalQTY++;\n\t\t\t\t\t\t// Keep count but make sure the player has no more than 1 crystal\n\t\t\t\t\t\tif (crystalQTY > 1)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tisSuccess = false;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Validate if the crystal has already leveled\n\t\t\t\t\t\tif (id != SoulCrystal.RED_NEW_CRYSTAL && id != SoulCrystal.GRN_NEW_CYRSTAL && id != SoulCrystal.BLU_NEW_CRYSTAL)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\ttry\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (item.getItem().getName().contains(\"Grade\"))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t// Split the name of the crystal into 'name' & 'level'\n\t\t\t\t\t\t\t\t\tcrystalNFO = item.getItem().getName().trim().replace(\" Grade \", \"-\").split(\"-\");\n\t\t\t\t\t\t\t\t\t// Set Level to 13\n\t\t\t\t\t\t\t\t\tcrystalLVL = 13;\n\t\t\t\t\t\t\t\t\t// Get Name\n\t\t\t\t\t\t\t\t\tcrystalNME = crystalNFO[0].toLowerCase();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t// Split the name of the crystal into 'name' & 'level'\n\t\t\t\t\t\t\t\t\tcrystalNFO = item.getItem().getName().trim().replace(\" Stage \", \"\").split(\"-\");\n\t\t\t\t\t\t\t\t\t// Get Level\n\t\t\t\t\t\t\t\t\tcrystalLVL = Integer.parseInt(crystalNFO[1].trim());\n\t\t\t\t\t\t\t\t\t// Get Name\n\t\t\t\t\t\t\t\t\tcrystalNME = crystalNFO[0].toLowerCase();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t// Allocate current and levelup ids' for higher level crystals\n\t\t\t\t\t\t\t\tif (crystalLVL > 9)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tfor (final int[] element : SoulCrystal.HighSoulConvert)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t// Get the next stage above 10 using array.\n\t\t\t\t\t\t\t\t\t\tif (id == element[0])\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tcrystalNEW = element[1];\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tcrystalNEW = id + 1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tcatch (final NumberFormatException nfe)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tLOGGER.warn(\"An attempt to identify a soul crystal failed, \" + \"verify the names have not changed in etcitem table.\", nfe);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tplayer.sendMessage(\"There has been an error handling your soul crystal.\" + \" Please notify your server admin.\");\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tisSuccess = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tcatch (final Exception e)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t\t\tisSuccess = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcrystalNME = item.getItem().getName().toLowerCase().trim();\n\t\t\t\t\t\t\tcrystalNEW = id + 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Done\n\t\t\t\t\t\tcrystalOLD = id;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (!isSuccess)\n\t\t\t\t{\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tinv = null;\n\t\t\t\n\t\t\t// If the crystal level is way too high for this mob, say that we can't increase it\n\t\t\tif (crystalLVL < minAbsorbLevel || crystalLVL >= maxAbsorbLevel)\n\t\t\t{\n\t\t\t\tdoLevelup = false;\n\t\t\t}\n\t\t\t\n\t\t\t// The player doesn't have any crystals with him get to the next player.\n\t\t\tif (crystalQTY < 1 || crystalQTY > 1 || !isSuccess || !doLevelup)\n\t\t\t{\n\t\t\t\t// Too many crystals in inventory.\n\t\t\t\tif (crystalQTY > 1)\n\t\t\t\t{\n\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_FAILED_RESONATION));\n\t\t\t\t}\n\t\t\t\t// The soul crystal stage of the player is way too high\n\t\t\t\t// Like L2OFF message must not appear if char hasn't crystal on inventory\n\t\t\t\telse if (!doLevelup && crystalQTY > 0)\n\t\t\t\t{\n\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_REFUSED));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tcrystalQTY = 0;\n\t\t\t\t\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t\n\t\t\t/*\n\t\t\t * TODO: Confirm boss chance for crystal level up and for crystal breaking. It is known that bosses with FULL_PARTY crystal level ups have 100% success rate, but this is not the case for the other bosses (one-random or last-hit). While not confirmed, it is most reasonable that crystals leveled up at\n\t\t\t * bosses will never break. Also, the chance to level up is guessed as around 70% if not higher.\n\t\t\t */\n\t\t\tfinal int chanceLevelUp = isBossMob ? 70 : SoulCrystal.LEVEL_CHANCE;\n\t\t\t\n\t\t\t// If succeeds or it is a full party absorb, level up the crystal.\n\t\t\tif (absorbType == L2NpcTemplate.AbsorbCrystalType.FULL_PARTY && doLevelup || dice <= chanceLevelUp)\n\t\t\t{\n\t\t\t\t// Give staged crystal\n\t\t\t\texchangeCrystal(player, crystalOLD, crystalNEW, false);\n\t\t\t}\n\t\t\t\n\t\t\t// If true and not a last-hit mob, break the crystal.\n\t\t\telse if (!isBossMob && dice >= 100.0 - SoulCrystal.BREAK_CHANCE)\n\t\t\t{\n\t\t\t\t// Remove current crystal an give a broken open.\n\t\t\t\tif (crystalNME.startsWith(\"red\"))\n\t\t\t\t{\n\t\t\t\t\texchangeCrystal(player, crystalOLD, SoulCrystal.RED_BROKEN_CRYSTAL, true);\n\t\t\t\t}\n\t\t\t\telse if (crystalNME.startsWith(\"gre\"))\n\t\t\t\t{\n\t\t\t\t\texchangeCrystal(player, crystalOLD, SoulCrystal.GRN_BROKEN_CYRSTAL, true);\n\t\t\t\t}\n\t\t\t\telse if (crystalNME.startsWith(\"blu\"))\n\t\t\t\t{\n\t\t\t\t\texchangeCrystal(player, crystalOLD, SoulCrystal.BLU_BROKEN_CRYSTAL, true);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tresetAbsorbList();\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_FAILED));\n\t\t\t}\n\t\t}\n\t\t\n\t\tkiller = null;\n\t\tplayers = null;\n\t\tcrystalNFO = null;\n\t\tcrystalNME = null;\n\t}", "public void addHabitatAttack(Habitat habitat, Habitat target) {\r\n\t\tif (!habitatToTargetList.containsKey(habitat.getID()+\"\")) habitatToTargetList.put(habitat.getID()+\"\", new ArrayList<Habitat>());\r\n\t\t\r\n\t\t// add attack\r\n\t\thabitatToTargetList.get(habitat.getID()+\"\").add(target);\r\n\t}", "public void addDamageHate(final L2Character attacker, final int damage, int aggro)\n\t{\n\t\tif (attacker == null /* || aggroList == null */)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Get the AggroInfo of the attacker L2Character from the aggroList of the L2Attackable\n\t\tAggroInfoHolder ai = getAggroListRP().get(attacker);\n\t\t\n\t\tif (ai == null)\n\t\t{\n\t\t\tai = new AggroInfoHolder(attacker);\n\t\t\tai.init();\n\t\t\tgetAggroListRP().put(attacker, ai);\n\t\t}\n\t\t\n\t\t// If aggro is negative, its comming from SEE_SPELL, buffs use constant 150\n\t\tif (aggro < 0)\n\t\t{\n\t\t\tai.decHate(aggro * 150 / (getLevel() + 7));\n\t\t\taggro = -aggro;\n\t\t}\n\t\t// if damage == 0 -> this is case of adding only to aggro list, dont apply formula on it\n\t\telse if (damage == 0)\n\t\t{\n\t\t\tai.incHate(aggro);\n\t\t\t// else its damage that must be added using constant 100\n\t\t}\n\t\telse\n\t\t{\n\t\t\tai.incHate(aggro * 100 / (getLevel() + 7));\n\t\t}\n\t\t\n\t\t// Add new damage and aggro (=damage) to the AggroInfo object\n\t\tai.incDmg(damage);\n\t\t\n\t\t// Set the intention to the L2Attackable to AI_INTENTION_ACTIVE\n\t\tif (getAI() != null && aggro > 0 && getAI().getIntention() == CtrlIntention.AI_INTENTION_IDLE)\n\t\t{\n\t\t\tgetAI().setIntention(CtrlIntention.AI_INTENTION_ACTIVE);\n\t\t}\n\t\t\n\t\tai = null;\n\t\t// Notify the L2Attackable AI with EVT_ATTACKED\n\t\tif (damage > 0)\n\t\t{\n\t\t\tif (getAI() != null)\n\t\t\t{\n\t\t\t\tgetAI().notifyEvent(CtrlEvent.EVT_ATTACKED, attacker);\n\t\t\t}\n\t\t\t\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif (attacker instanceof L2PcInstance || attacker instanceof L2Summon)\n\t\t\t\t{\n\t\t\t\t\tL2PcInstance player = attacker instanceof L2PcInstance ? (L2PcInstance) attacker : ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\n\t\t\t\t\tfor (final Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_ATTACK))\n\t\t\t\t\t{\n\t\t\t\t\t\tquest.notifyAttack(this, player, damage, attacker instanceof L2Summon);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tplayer = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\tcatch (final Exception e)\n\t\t\t{\n\t\t\t\tLOGGER.error(\"\", e);\n\t\t\t}\n\t\t}\n\t}", "public void attack()\n {\n getWorld().addObject(new RifleBullet(player.getX(), player.getY(), 1, 6, true), getX(), getY()); \n }", "public void addDamage(final L2Character attacker, final int damage)\n\t{\n\t\taddDamageHate(attacker, damage, damage);\n\t}", "void evadeAttack(IUnit attacker, int incomingDamage);", "public void attack() {\n this.attacked = true;\n }", "@Override\n public void attack(ArrayList<territories> PlayersTerritories,int bonusArmies ) {\n\n // placeArmy(PlayersTerritories,bonusArmies);\n\n\n territories toAttack=getTerritoryGreedyAttack(PlayersTerritories,0);\n\n territories AttackWith = GetMaximumAttacker(PlayersTerritories,toAttack);\n\n Attacking(toAttack,AttackWith);\n\n\n\n }", "protected void addAllowedArmor(Material armor) {\r\n\t\tthis.allowedArmor.add(armor);\r\n\t}", "public boolean handleAttack(Action action) {\n ActorState a = action.getActor();\n if (a.getActor() == actor) {\n // Attacks on oneself always succeed, and we don't want to add ourselves as an enemy\n return true;\n }\n \n //maybeCounter(Augmentation.Type.ATTACK, a, combatants);\n enemies.add(a);\n \n double weaponAccuracy = 1.0; //source.getWeaponAccuracy(action);\n double chance = a.getAccuracy() * weaponAccuracy * (1.0 - getDefense());\n boolean success = Math.random() < chance;\n return success;\n }", "public void attack() {\n if (activeWeapon == null) {\n return;\n }\n attacking = true;\n }", "public void attack() {\n //Grab an attacker.\n Territory attacker = potentialAttackers.remove(0);\n \n //Find the weakest adjacent territory\n int victimStrength = Integer.MAX_VALUE;\n Territory victim = null;\n List<Territory> adjs = gameController.getBoard().getAdjacentTerritories(attacker);\n for(Territory adj : adjs){\n \n //Verify that our odds are good enough for this attack to consider it.\n int aTroops = attacker.getNumTroops() - 1;\n int dTroops = adj.getNumTroops();\n double odds = MarkovLookupTable.getOddsOfSuccessfulAttack(aTroops, dTroops);\n boolean yes = Double.compare(odds, ACCEPTABLE_RISK) >= 0;\n \n //If we have a chance of winning this fight and its the weakest opponent.\n if(yes && adj.getNumTroops() < victimStrength && !adj.getOwner().equals(this)){\n victim = adj;\n victimStrength = adj.getNumTroops();\n }\n }\n \n //Resolve the Attack by building forces and settle the winner in Victim's land\n Force atkForce = attacker.buildForce(attacker.getNumTroops() - 1);\n Force defForce = victim.buildForce(victimStrength); //Guaranteed not null\n Force winner = atkForce.attack(defForce);\n victim.settleForce(winner);\n }", "public void addAwardKillerNotDead() {\n\t\tfor (int i = 0; i < killers.size(); i++) {\n\t\t\tif (killerHasNotDeath(killers.get(i).getName())) {\n\t\t\t\tint awards = killers.get(i).getAwardMatchWithoutDeath();\n\t\t\t\tkillers.get(i).setAwardMatchWithoutDeath(awards + 1);\n\t\t\t}\n\n\t\t}\n\t}", "public void battleEnemyAttack() {\n if(battleEnemy != null){ // If all enemies have attacked, they cannot attack anymore for this round\n\n MovingEntity target = battleEnemy.getAttackPreference(targetAllies);\n if(target == null){\n target = targetAlly;\n }\n\n battleEnemy.attack(target, targetEnemies, targetAllies);\n //System.out.println(battleEnemy.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still friendly incase of zombify\n targetAlly = checkSideSwap(targetAlly, false, battleEnemies, targetEnemies, battleAllies, targetAllies);\n }\n\n battleEnemy = nextAttacker(battleEnemy, battleEnemies);\n\n }\n }", "private void addPlayerSheild() {\n this.playerShield += 1;\n }", "public abstract boolean attack(KillableItem i);", "@Override\n\tpublic void attack() {\n\n\t}", "@Override\n\tpublic void attack() {\n\t}", "@Override\n\tpublic void attack() {\n\t\t\n\t}", "public void attack() {\n\n for (int i = 0; i < Vampiro.getNumVamp(); i++) {\n\n lista[i].attack();\n }\n }", "@Override\n public void applyItem() {\n Player player;\n if (Battle.getRunningBattle().getTurn() % 2 == 1)\n player = Battle.getRunningBattle().getPlayer2();\n else\n player = Battle.getRunningBattle().getPlayer1();\n\n if (player.getInGameCards().size() == 0)\n return;\n Random random = new Random();\n int randomIndex = random.nextInt(player.getInGameCards().size());\n while (!(getPlayer().getInGameCards().get(randomIndex) instanceof Warrior)) {\n randomIndex = random.nextInt(getPlayer().getInGameCards().size());\n }\n\n Buff buff = new PoisonBuff(1, true);\n buff.setWarrior((Warrior) player.getInGameCards().get(randomIndex));\n Battle.getRunningBattle().getPassiveBuffs().add(buff);\n }", "@Override\n public void attack() {\n\n }", "public synchronized void addTheWarrior(Warrior w){\n Warrior obj=(Warrior)charactersOccupiedTheLocation[0];\n while(obj!=null && w.checkMobility() && obj.checkMobility() && obj.checkIsAlive()){\n try {\n wait(1000); //1000\n } catch (InterruptedException ex) {}\n obj=(Warrior)charactersOccupiedTheLocation[0];\n }\n charactersOccupiedTheLocation[0]=w;\n }", "public boolean attackAlly(Ally target) {\n\t\tLog.d(TAG, \"Attacking!\");\n\t\tif (target.takeDamage(damage)) {\n\t\t\treturn true;\n\t\t} else\n\t\t\treturn false;\n\t}", "public void shoot(){\n // boss bullete attract to player\n int bulletPosX = PApplet.parseInt(posX + (speed * cos(angle)));\n int bulletPosY = (int)(posY + hei / 2);\n float bulletAngle = atan2(Main.player.posY - bulletPosY, Main.player.posX - bulletPosX);\n int bulletVelX = (int)(8 * cos(bulletAngle));\n int bulletVelY = (int)(8 * sin(bulletAngle));\n bossBullets.add(new Bullet(bulletPosX,bulletPosY,bulletVelX,bulletVelY,1,attack));\n }", "public void applyEffectUser(Enemy user) {\n\t\tsuper.applyEffectsUser(user);\n\t\tuser.addEnrage(enrage);\n\t}", "public void attack(Player attacker) {\r\n\t\tif (!attacker.isPlayerHuman()) {\r\n\t\t\tbattleAI(attacker);\r\n\t\t} else {\r\n\t\t\tbattleHuman(attacker);\r\n\t\t}\r\n\t}", "public void absorbSoul()\n\t{\n\t\tabsorbed = true;\n\t\t\n\t}", "public AttackableKnownList(L2Attackable activeChar)\n {\n super(activeChar);\n }", "public void addBuddy(IAwarenessUser user) {\n\t\tgetBuddies().add(user);\n\t\tthis.createBuddyIcon(user);\n\t}", "@Override\n\tprotected void calculateRewards(final L2Character lastAttacker)\n\t{\n\t\t// Creates an empty list of rewards\n\t\tfinal Map<L2Character, RewardInfoHolder> rewards = new ConcurrentHashMap<>();\n\t\t\n\t\ttry\n\t\t{\n\t\t\tif (getAggroListRP().isEmpty())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (EngineModsManager.onNpcExpSp(this, lastAttacker))\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tL2PcInstance maxDealer = null;\n\t\t\tint maxDamage = 0;\n\t\t\t\n\t\t\tint damage;\n\t\t\t\n\t\t\tL2Character attacker, ddealer;\n\t\t\t\n\t\t\t// While Interacting over This Map Removing Object is Not Allowed\n\t\t\tsynchronized (getAggroList())\n\t\t\t{\n\t\t\t\t// Go through the aggroList of the L2Attackable\n\t\t\t\tfor (final AggroInfoHolder info : getAggroListRP().values())\n\t\t\t\t{\n\t\t\t\t\tif (info == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Get the L2Character corresponding to this attacker\n\t\t\t\t\tattacker = info.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Get damages done by this attacker\n\t\t\t\t\tdamage = info.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// Prevent unwanted behavior\n\t\t\t\t\tif (damage > 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (attacker instanceof L2SummonInstance || attacker instanceof L2PetInstance && ((L2PetInstance) attacker).getPetData().getOwnerExpTaken() > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = info.getAttacker();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check if ddealer isn't too far from this (killed monster)\n\t\t\t\t\t\tif (!Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, ddealer, true))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate real damages (Summoners should get own damage plus summon's damage)\n\t\t\t\t\t\tRewardInfoHolder reward = rewards.get(ddealer);\n\t\t\t\t\t\tif (reward == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward = new RewardInfoHolder(ddealer, damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward.addDamage(damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\trewards.put(ddealer, reward);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (ddealer instanceof L2PlayableInstance && ((L2PlayableInstance) ddealer).getActingPlayer() != null && reward.getDmg() > maxDamage)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tmaxDealer = ((L2PlayableInstance) ddealer).getActingPlayer();\n\t\t\t\t\t\t\tmaxDamage = reward.getDmg();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// Manage Base, Quests and Sweep drops of the L2Attackable\n\t\t\tdoItemDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\t// Manage drop of Special Events created by GM for a defined period\n\t\t\tdoEventDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\tif (!getMustRewardExpSP())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (!rewards.isEmpty())\n\t\t\t{\n\t\t\t\tL2Party attackerParty;\n\t\t\t\tlong exp;\n\t\t\t\tint levelDiff, partyDmg, partyLvl, sp;\n\t\t\t\tfloat partyMul, penalty;\n\t\t\t\tRewardInfoHolder reward2;\n\t\t\t\tint[] tmp;\n\t\t\t\t\n\t\t\t\tfor (final RewardInfoHolder reward : rewards.values())\n\t\t\t\t{\n\t\t\t\t\tif (reward == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Penalty applied to the attacker's XP\n\t\t\t\t\tpenalty = 0;\n\t\t\t\t\t\n\t\t\t\t\t// Attacker to be rewarded\n\t\t\t\t\tattacker = reward.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Total amount of damage done\n\t\t\t\t\tdamage = reward.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// If the attacker is a Pet, get the party of the owner\n\t\t\t\t\tif (attacker instanceof L2PetInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PetInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse if (attacker instanceof L2PcInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PcInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If this attacker is a L2PcInstance with a summoned L2SummonInstance, get Exp Penalty applied for the current summoned L2SummonInstance\n\t\t\t\t\tif (attacker instanceof L2PcInstance && ((L2PcInstance) attacker).getPet() instanceof L2SummonInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tpenalty = ((L2SummonInstance) ((L2PcInstance) attacker).getPet()).getExpPenalty();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// We must avoid \"over damage\", if any\n\t\t\t\t\tif (damage > getMaxHp())\n\t\t\t\t\t{\n\t\t\t\t\t\tdamage = getMaxHp();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If there's NO party in progress\n\t\t\t\t\tif (attackerParty == null)\n\t\t\t\t\t{\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\tif (attacker.getKnownList().knowsObject(this))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// Calculate the difference of level between this attacker (L2PcInstance or L2SummonInstance owner) and the L2Attackable\n\t\t\t\t\t\t\t// mob = 24, atk = 10, diff = -14 (full xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 28, diff = 4 (some xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 50, diff = 26 (no xp)\n\t\t\t\t\t\t\tlevelDiff = attacker.getLevel() - getLevel();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, damage);\n\t\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\t\texp *= 1 - penalty;\n\t\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Check for an over-hit enabled strike and VIP options\n\t\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif (player.isVIP())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\texp = (long) (exp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t\tsp = (int) (sp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Distribute the Exp and SP between the L2PcInstance and its L2Summon\n\t\t\t\t\t\t\tif (!attacker.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tattacker.addExpAndSp(Math.round(attacker.calcStat(Stats.EXPSP_RATE, exp, null, null)), (int) attacker.calcStat(Stats.EXPSP_RATE, sp, null, null));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t// share with party members\n\t\t\t\t\t\tpartyDmg = 0;\n\t\t\t\t\t\tpartyMul = 1.f;\n\t\t\t\t\t\tpartyLvl = 0;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Get all L2Character that can be rewarded in the party\n\t\t\t\t\t\tfinal List<L2PlayableInstance> rewardedMembers = new ArrayList<>();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Go through all L2PcInstance in the party\n\t\t\t\t\t\tList<L2PcInstance> groupMembers;\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getCommandChannel().getMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getPartyMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tfor (final L2PcInstance pl : groupMembers)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (pl == null || pl.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Get the RewardInfo of this L2PcInstance from L2Attackable rewards\n\t\t\t\t\t\t\treward2 = rewards.get(pl);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// If the L2PcInstance is in the L2Attackable rewards add its damages to party damages\n\t\t\t\t\t\t\tif (reward2 != null)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add L2PcInstance damages to party damages\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\trewards.remove(pl); // Remove the L2PcInstance from the L2Attackable rewards\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t// Add L2PcInstance of the party (that have attacked or not) to members that can be rewarded\n\t\t\t\t\t\t\t\t// and in range of the monster.\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfinal L2PlayableInstance summon = pl.getPet();\n\t\t\t\t\t\t\tif (summon != null && summon instanceof L2PetInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\treward2 = rewards.get(summon);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (reward2 != null) // Pets are only added if they have done damage\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, summon, true))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add summon damages to party damages\n\t\t\t\t\t\t\t\t\t\trewardedMembers.add(summon);\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tif (summon.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = summon.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\trewards.remove(summon); // Remove the summon from the L2Attackable rewards\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// If the party didn't killed this L2Attackable alone\n\t\t\t\t\t\tif (partyDmg < getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyMul = (float) partyDmg / (float) getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Avoid \"over damage\"\n\t\t\t\t\t\tif (partyDmg > getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyDmg = getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate the level difference between Party and L2Attackable\n\t\t\t\t\t\tlevelDiff = partyLvl - getLevel();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, partyDmg);\n\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\texp *= partyMul;\n\t\t\t\t\t\tsp *= partyMul;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check for an over-hit enabled strike\n\t\t\t\t\t\t// (When in party, the over-hit exp bonus is given to the whole party and splitted proportionally through the party members)\n\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Distribute Experience and SP rewards to L2PcInstance Party members in the known area of the last attacker\n\t\t\t\t\t\tif (partyDmg > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tattackerParty.distributeXpAndSp(exp, sp, rewardedMembers, partyLvl);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t}", "void defendAttack(IUnit attacker, int incomingDamage);", "@Override\n public void attackedByPaladin(double attack) {\n this.attack += (2 * attack) / 3;\n damageCounter = Math.max(damageCounter - (2 * attack) / 3, 0);\n }", "@Override\n\t\t\tpublic void attack(Base enemy) {\n\t\t\t}", "public void attack() { \n db.attack(creatures.get(creatureId), players.get(playerId));\n creatures.set(creatureId, db.getCreature(creatures.get(creatureId).getId()));\n players.set(playerId, db.getPlayer(players.get(playerId).getId()));\n setTextFields();\n }", "@Override\n\tpublic boolean isAutoAttackable(L2Character attacker)\n\t{\n\t\tif ((attacker == null) || !(attacker instanceof L2PcInstance))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\tboolean isFort = ((getFort() != null) && (getFort().getResidenceId() > 0) && getFort().getSiege().isInProgress() && !getFort().getSiege().checkIsDefender(((L2PcInstance) attacker).getClan()));\n\t\t\n\t\t// Attackable during siege by all except defenders\n\t\treturn (isFort);\n\t}", "@Override\r\n\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\tfor (Damage damage : actionAttack.damages) {\r\n\t\t\t\t\t\t\t\tBattlerSprite attacked = damage.target.getTag();\r\n\t\t\t\t\t\t\t\tattacked.takeHit(damage.damage);\t\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}", "@Override\n\tvoid attack() {\n\n\t}", "@Override\n public void attack(Entity e) {\n e.hit(atk);\n }", "public void battleAllyAttack() {\n if(battleAlly instanceof Character){\n battleTickStatuses();\n updateBattleSides();\n }\n\n // battleAlly now attacks targetEnemy or preference based on the type of battleAlly\n if(battleAlly != null){ // If all allies have attacked, they cannot attack anymore for this round\n MovingEntity target = battleAlly.getAttackPreference(targetEnemies);\n // if not picky, get preference is the default next target\n if(target == null) {\n target = targetEnemy;\n }\n battleAlly.attack(target, targetAllies, targetEnemies);\n //System.out.println(battleAlly.getID() + \" is attacking \" + target.getID() + \" remaining hp: \" + target.getCurrHP());\n if (updateTarget(target) == false) {\n // if target still alive, check if its still unfriendly\n targetEnemy = checkSideSwap(targetEnemy, true, battleAllies, targetAllies, battleEnemies, targetEnemies);\n }\n battleAlly = nextAttacker(battleAlly, battleAllies);\n\n }\n }", "public void gettingAttacked(HitByBulletEvent e) {\r\n\t\tif (gotTarget) {\r\n\t\t\tfor (int i = 0; i < enemyTracker.getEnemyList().size(); i++) {\r\n\t\t\t\tif (enemyTracker.getEnemyList().get(i).getName().equals(e.getName()) && (!e.getName().equals(radarTarget.getName()))) {\r\n\t\t\t\t\t\tmrRobot.sendMessage(5, \"2\");\r\n\t\t\t\t\t\tradarTarget = enemyTracker.getEnemyList().get(getIndexForEnemy(e.getName()));\r\n\t\t\t\t\t\ttargetTracking.get(getIndexForName(mrRobot.getName())).updateTarget(radarTarget);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public void addEffect(BattleEffect btlEff) {\n effectsToApply.add(btlEff);\n effectsToRemove.add(btlEff);\n }", "public void doEventDrop(final L2Character lastAttacker)\n\t{\n\t\tL2PcInstance player = null;\n\t\t\n\t\tif (lastAttacker instanceof L2PcInstance)\n\t\t{\n\t\t\tplayer = (L2PcInstance) lastAttacker;\n\t\t}\n\t\telse if (lastAttacker instanceof L2Summon)\n\t\t{\n\t\t\tplayer = ((L2Summon) lastAttacker).getOwner();\n\t\t}\n\t\t\n\t\tif (player == null)\n\t\t{\n\t\t\treturn; // Don't drop anything if the last attacker or ownere isn't L2PcInstance\n\t\t}\n\t\t\n\t\tif (player.getLevel() - getLevel() > 9)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Go through DateDrop of EventDroplist allNpcDateDrops within the date range\n\t\tfor (final DateDrop drop : EventDroplist.getInstance().getAllDrops())\n\t\t{\n\t\t\tif (Rnd.get(L2DropData.MAX_CHANCE) < drop.chance)\n\t\t\t{\n\t\t\t\tRewardItem item = new RewardItem(drop.items[Rnd.get(drop.items.length)], Rnd.get(drop.min, drop.max));\n\t\t\t\t\n\t\t\t\tif (Config.AUTO_LOOT)\n\t\t\t\t{\n\t\t\t\t\tfinal L2Item item_templ = ItemTable.getInstance().getTemplate(item.getItemId());\n\t\t\t\t\t\n\t\t\t\t\tif (!player.getInventory().validateCapacity(item_templ))\n\t\t\t\t\t{\n\t\t\t\t\t\tDropItem(player, item);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tplayer.doAutoLoot(this, item); // Give this or these Item(s) to the L2PcInstance that has killed the L2Attackable\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tDropItem(player, item); // drop the item on the ground\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\titem = null;\n\t\t\t}\n\t\t}\n\t\t\n\t\tplayer = null;\n\t}", "@Override\n public void attack(){\n\n }", "public void updateAllies(){\r\n List<Ally> allies = world.getAllies();\r\n ArrayList<Ally> deadAllies = new ArrayList<Ally>();\r\n for(Ally ally : allies){\r\n if(ally.getCurrHP() <= 0){\r\n deadAllies.add(ally);\r\n }\r\n }\r\n\r\n allies.removeAll(deadAllies);\r\n world.setNumAllies(allies.size());\r\n //numAllies.set(allies.size());\r\n }", "@Override\n public void accept(final Ability ability) {\n ability.affect(this);\n }", "@Override\r\n\tpublic void addLettuce() {\r\n\t\tSystem.out.println(\"Sorry, cannot add lettuce to the DeluxBurger!\");\r\n\t}", "public void causeFoodExhaustion(float debug1) {\n/* 1797 */ if (this.abilities.invulnerable) {\n/* */ return;\n/* */ }\n/* */ \n/* 1801 */ if (!this.level.isClientSide) {\n/* 1802 */ this.foodData.addExhaustion(debug1);\n/* */ }\n/* */ }", "public void unlockAdd(){\n\t\tthis.canAdd = true;\n\t}", "@Override\n\t\tpublic void hit(Npc attacker, Mob defender, Hit hit) {\n\t\t}", "public void attemptAttack() {\r\n\t\tattackAttempts += 100;\r\n\t}", "public void attack(Entity entity) {\n\t}", "public void execute() {\n\t\tif (getTargetEnemies() != null && getTargetEnemies().size() > 0) {\n\t\t\tBuff buff = new Buff(getHero().getId(), null, Buff.SPEED, getAbility().getValue(), CHARGE_DURATION, \"0\", 0);\n\t\t\tThread buffDurationThread = new Thread(() -> {\n\t\t\t\ttry {\n\t\t\t\t\tThread.sleep(CHARGE_DURATION);\n\t\t\t\t} catch (InterruptedException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t\tgetHero().removeBuff(buff);\n\t\t\t\tgetGameServer().sendGameStatus();\n\t\t\t\tLog.i(TAG, \"Removed buff, now have these many buffs left : \" + getHero().getBuffs().size());\n\t\t\t});\n\t\t\tbuffDurationThread.start();\n\n\t\t\tgetHero().getBuffs().add(buff);\n\n\t\t\t// Set the cooldown for this ability\n\t\t\tgetAbility().setMillisLastUse(getTime());\n\t\t\tgetAbility().setTimeWhenOffCooldown(\"\" + (getTime() + getAbility().calculateCooldown(getHero(), this)));\n\n\t\t\t// Send castbar information\n\t\t\tgetGameServer().sendCastBarInformation(getHero().getId(), getAbility());\n\n\t\t\t// Add animation to list\n\t\t\tgetGameServer().getAnimations().add(new GameAnimation(\"CHARGE\", 0, getHero().getId(), null, 1));\n\t\t}else{\n\t\t\tLog.i(TAG, \"Hero had no target, canceling ability\");\n\t\t}\n\t\tsuper.execute();\n\t}", "@Override\n public void attackedByShaman(double attack) {\n damageCounter += (2 * attack) / 3;\n this.attack = Math.max(this.attack - (2 * attack) / 3, 0);\n }", "@Override\n public void addBundle(Context context, Item item, Bundle b) throws SQLException, AuthorizeException\n {\n // Check authorisation\n authorizeService.authorizeAction(context, item, Constants.ADD);\n\n log.info(LogManager.getHeader(context, \"add_bundle\", \"item_id=\"\n + item.getID() + \",bundle_id=\" + b.getID()));\n\n // Check it's not already there\n if (item.getBundles().contains(b)) {\n // Bundle is already there; no change\n return;\n }\n\n // now add authorization policies from owning item\n // hmm, not very \"multiple-inclusion\" friendly\n authorizeService.inheritPolicies(context, item, b);\n\n // Add the bundle to in-memory list\n item.addBundle(b);\n b.setItems(Arrays.asList(item));\n\n // Insert the mapping\n context.addEvent(new Event(Event.ADD, Constants.ITEM, item.getID(), Constants.BUNDLE, b.getID(), b.getName()));\n }", "public void attack(Person target) {\r\n target.setHealthPoints(target.getHealthPoints() - 1);\r\n }", "@Override\n\tpublic void attack(Slime slime) {\n\t\t\n\t}", "@Override\n\tpublic void activate(Entity caller) {\n\t\tcaller.dealDamage(10);\n\t\t\n\t}", "@Override\r\n\tpublic void Attack(Player arg0, Player arg1) {\n\t\t\r\n\t}", "@Override\r\n\tpublic void Attack(Player arg0, Player arg1) {\n\t\t\r\n\t}", "protected void addAllowedWeapon(Material weapon) {\r\n\t\tthis.allowedWeapons.add(weapon);\r\n\t}", "public void shootAimingBullet(){\n bossBullet = new BossBullet(bossBulletImage,this.getXposition() + 100, this.getYposition() + 100, 8, player, true);\n bulletList.add(bossBullet);\n }", "protected void onImpact(RayTraceResult result) {\n\t\tif (result.entityHit != null) {\n\t\t\tfloat i = 2.5F;\n\n\t\t\tif (result.entityHit instanceof EntityBlizzard) {\n\t\t\t\ti = 0;\n\t\t\t}\n\n result.entityHit.attackEntityFrom(WorldsRetold.HAIL, i);\n\n\t\t\tif (result.entityHit instanceof EntityLivingBase) {\n\t\t\t\tEntityLivingBase target = (EntityLivingBase) result.entityHit;\n\t\t\t\tif (!this.world.isRemote) {\n\t\t\t\t\ttarget.addPotionEffect(new PotionEffect(HailstormPotions.FREEZING, 100, 0));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (!this.world.isRemote) {\n\t\t\tthis.world.setEntityState(this, (byte) 3);\n\t\t\tthis.setDead();\n\t\t}\n\t}", "public void activatedBy(final Player player) {\n //Battle with a Boss Unit\n }", "@Override\n public void applyEffect(Battle battle, Cell cell, Account player, int activeTime) {\n /* if (activeTime != -1)\n return;\n ManaItemBuff manaItemBuff = new ManaItemBuff(player, 1);\n manaItemBuff.setTurnCounter(-5);\n manaItemBuff.castBuff();\n player.getOwnBuffs().add(manaItemBuff);*/\n }", "public void applyEffects(Enemy user, Hero hero, ArrayList<Enemy> team) {\n\t\tfor (int i=0; i<getAttackNbr(); i++) {\n\t\t\tapplyEffectHero(user, hero);\n\t\t}\n\t\tapplyDebuffHero(user, hero);\n\t\tapplyEffectUser(user);\n\t\t\n\t\tif (invoke != null) { // ajout sbires\n\t\t\tfor (int i=0; i<nbrInvoke; i++) {\n\t\t\t\tteam.add(Datas.getEnemy(invoke));\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (disappear) {\n\t\t\tteam.remove(user);\n\t\t}\n\t\t\n\t\tArrayList<Enemy> allies = new ArrayList<>(team);\n\t\tallies.remove(user);\n\t\tif (allies.size() > 0) {\n\t\t\tEnemy allyToBuff = allies.get(random.nextInt(allies.size()));\n\t\t\tallyToBuff.addBlock(protect);\n\t\t}\n\t}", "protected final void hit() throws InsufficientCardsException {\n hand.add(deck.deal());\n update();\n }", "public abstract boolean attack(Warrior w);", "public void attack();", "@Override\n public void preventEffectOnCard(PhysicalCard card) {\n _preventedCards.add(card);\n }", "public static boolean attacksAcceptedP(Argument attacker, Argument attackee, ArgumentAcceptability aa, Ontology o, FTKBase dm) throws FeatureTermException {\n if (!attacker.m_rule.solution.equivalents(attackee.m_rule.solution)) {\n if (attackee.m_rule.pattern.subsumes(attacker.m_rule.pattern)) {\n if (DEBUG>=1) System.out.println(\"attacksAcceptedP: true (attacker subsumes by attackee)\");\n return true;\n }\n FeatureTerm u = FTUnification.simpleUnification(attacker.m_rule.pattern, attackee.m_rule.pattern, dm);\n Argument a = new Argument(new Rule(u,attacker.m_rule.solution,0.0f,0));\n if (u!=null) {\n if (aa.accepted(a)) {\n if (DEBUG>=1) System.out.println(\"attacksAcceptedP: true (unification is acceptable)\");\n return true;\n } else {\n if (DEBUG>=1) {\n System.out.println(\"attacksAcceptedP: false -> unification is not acceptable:\");\n System.out.println(a.toStringNOOS(dm));\n int tmp = ArgumentAcceptability.DEBUG;\n ArgumentAcceptability.DEBUG = 2;\n aa.accepted(a);\n ArgumentAcceptability.DEBUG = tmp;\n }\n }\n } else {\n if (DEBUG>=1) System.out.println(\"attacksAcceptedP: false -> arguments do not unify \");\n }\n } else {\n if (DEBUG>=1) System.out.println(\"attacksAcceptedP: false -> same solutions \" + attacker.m_rule.solution.toStringNOOS(dm) + \" = \" + attackee.m_rule.solution.toStringNOOS(dm));\n }\n return false;\n }", "public void placeAlienBullet() {\r\n\t\tif (alien != null) {\r\n\t\t\t// If the alien is large fires a bullet in a random direction\r\n\t\t\tif (alien.getSize() == 1 && ship != null) {\r\n\r\n\t\t\t\t// Create the alien bullet\r\n\t\t\t\tab = new AlienBullet(alien.getX(), alien.getY());\r\n\r\n\t\t\t\t// give the alien bullet a random direction and the bullet speed velocity,\r\n\t\t\t\t// then add as participant\r\n\t\t\t\tdouble r = (2 * Math.PI) * RANDOM.nextDouble();\r\n\t\t\t\tab.setVelocity(BULLET_SPEED, r);\r\n\t\t\t\taddParticipant(ab);\r\n\r\n\t\t\t\t// Sets the alien bullet to expire when it reaches the bullet duration time\r\n\t\t\t\t// limit\r\n\t\t\t\tnew ParticipantCountdownTimer(ab, \"expire\", BULLET_DURATION);\r\n\t\t\t}\r\n\r\n\t\t\t// If the alien is small fires a bullet aimed directly at the ship\r\n\t\t\tif (alien.getSize() == 0 && ship != null) {\r\n\t\t\t\tab = new AlienBullet(alien.getX(), alien.getY());\r\n\t\t\t\tab.setSpeed(BULLET_SPEED);\r\n\r\n\t\t\t\t// Aims the alien bullet directly at the ship\r\n\t\t\t\tdouble A = ship.getY() - alien.getY();\r\n\t\t\t\tdouble B = ship.getX() - alien.getX();\r\n\t\t\t\tdouble angle = Math.atan2(A, B);\r\n\t\t\t\tab.setVelocity(BULLET_SPEED, angle);\r\n\r\n\t\t\t\t// Add the alien bullet as a participant and then set it to expire when it\r\n\t\t\t\t// reaches the bullet duration time limit\r\n\t\t\t\taddParticipant(ab);\r\n\t\t\t\tnew ParticipantCountdownTimer(ab, \"expire\", BULLET_DURATION);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t}", "@Override\n\tpublic void takeHit(int attack) {\n\n\t}", "public void injure(int a, PhysicsEntity attacker ){\n\t\ta *= getArmorPercentage();\n\t\tsuper.injure(a,attacker);\n\t}", "@RequiresLock(\"SeaLock\")\r\n private void addDeponent(Drop deponent) {\r\n if (!f_valid || deponent == null) {\r\n return;\r\n }\r\n if (deponent == this) {\r\n return;\r\n }\r\n f_deponents.add(deponent);\r\n }", "public void attack(Entity entity, boolean aoe) {\n if(aoe) entity.damaged((int) (this.damage*0.6));\n else entity.damaged(this.damage);\n if(entity.isDead()){\n incExp(entity.getLevel()*9);\n if(entity instanceof Boss) {\n this.bossesDefeated++;\n }\n }\n }", "void addAction(Action a) {\n ensureNotFrozen();\n ineligibleActions.add(a);\n }", "@Override\n\tpublic void addInformation(ItemStack is, EntityPlayer player, List l, boolean b){\n\t\tl.add(\"This staff is magical!\");\n\t}", "boolean collidesEnemy() {\n for(int i = 0; i < barrage.size(); i++) {\n // establish a rectangle for the laser\n Rectangle blaster = new Rectangle((int)barrage.get(i).getX(), (int)barrage.get(i).getY(), WIDTH, HEIGHT);\n \n // determine if the laser intersects an enemy\n for (int q = 0; q < fleet.size(); q++) {\n Rectangle enemy = new Rectangle((int)fleet.get(q).getX(), (int)fleet.get(q).getY(), 40, 36); \n \n // if blaster hits a ship, remove it\n if (blaster.intersects(enemy) && fleet.get(q).getCount() == 0) {\n fleet.get(q).hit = true; // set the enemy hit\n barrage.remove(barrage.get(i));\n score += 100; // add to score\n return true; // hit\n }\n }\n }\n return false; // miss\n }", "private boolean addAllowedBypass(SshKey key, ApplicationUser stashUser) {\n String bambooUser = pluginSettingsService.getAuthorizedUser();\n String userGroup = pluginSettingsService.getAuthorizedGroup();\n if( bambooUser != null && bambooUser.equals(stashUser.getName())){\n log.debug(\"Username matches configured 'bambooUser', adding record\");\n log.info(\"Bamboo Key {} created by an authorized bamboo system ID {} \", key.getId(), stashUser.getSlug());\n enterpriseKeyRepository.saveExternallyGeneratedKeyDetails(key,stashUser,SshKeyEntity.KeyType.BAMBOO);\n return true;\n }else if( userGroup != null && userService.existsGroup(userGroup) && userService.isUserInGroup(stashUser, userGroup)){\n log.debug(\"Username matches configured 'authorizedGroup', adding record\");\n log.info(\"Bypass Key {} created by an authorized user {} in authorized group\", key.getId(), stashUser.getSlug());\n enterpriseKeyRepository.saveExternallyGeneratedKeyDetails(key,stashUser,SshKeyEntity.KeyType.BYPASS);\n return true;\n }\n log.debug(\"User not in excused roles, do not allow.\");\n return false;\n }", "public void addLobby(Lobby lobby) {\n rrwl_lobbylist.writeLock().lock();\n try {\n lobbyList.add(lobby);\n } finally {\n rrwl_lobbylist.writeLock().unlock();\n }\n }", "private boolean addRestrictedCard2Player(Card card)\n\t{\n\t\treturn restrictedCard2PlayerList.add(card);\n\t}", "public void addHarvestContents(ArrayList ist)\r\n/* 100: */ {\r\n/* 101: 80 */ super.addHarvestContents(ist);\r\n/* 102: 81 */ ist.add(new ur(RedPowerMachine.blockFrame, 1));\r\n/* 103: */ }", "void fire(WarParticipant target, WarParticipant attacker, int noOfShooters);", "private void eat(Person victim)\r\n { \r\n int defense = 0;\r\n if (victim.getEquip(Equip.ARMOR)!=null)\r\n defense = victim.getEquip(Equip.ARMOR).getRating();\r\n \r\n int hits = weapon.getRating() - defense;\r\n if (hits < 0)\r\n hits = 0;\r\n \r\n if (victim != this) //don't eat yourself\r\n {\r\n say(\"Grrr! I eat tasty \" + victim.getName() + \"!\");\r\n victim.suffer(hits);\r\n }\r\n }", "public void attack() {\n\t\t\n\t\tint row = getPosition().getRow();\n\t\tint column = getPosition().getColumn();\n\t\t\n\t\tgetPosition().setCoordinates(row + 1, column);\n\t\tsetPosition(getPosition()) ;\n\t\t// restore health\n\t\tsetHealth(100);\n\t\t// end hunter mode\n\t\tthis.hunter = false;\n\t\t\n\t}", "public void attackTargetCharacter() {\n }", "@Override\n\tpublic int attack( ){\n\t\treturn enemy.attack();\n\t}", "@Override\r\n\tpublic boolean damageEntity(DamageSource damagesource, float f2) {\n\t\tboolean toReturn = super.damageEntity(damagesource, f2);\r\n\t\tif(f2>=3 && !this.isInvulnerable(damagesource) && damagesource.getEntity()!=null && damagesource.getEntity().getBukkitEntity() instanceof Player) { // prevent things like snowball damage from triggering this ability\r\n\t\t\tif(random.nextInt(100)+1<=20) { //prevent boss from getting combo'd to hard in corner\r\n\t\t\t\tif(!teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity())) {\r\n\t\t\t\t\tteleportToEnemy();\t\t\r\n\t\t\t\t\tteleportCooldown.addCooldown((Player)damagesource.getEntity().getBukkitEntity());\r\n\t\t\t\t\tLog.info(teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity()));\r\n\t\t\t\t\tLog.info(((Player)damagesource.getEntity().getBukkitEntity()).getName());\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn toReturn;\r\n\t}", "public void registerSalvageables(List<Salvageable> salvageables);", "@Override\n\tpublic void fire(Ball firer) {\n\t balls.add(firer);\n\t firer.setAbsorbed(true);\n\t setBalls();\n\t firer.setVx(0);\n\t firer.setVy(0);\n\t //somehow ball being fired out came back and hit!\n\t if (firer.equals(firingBall)) {\n\t firingBall = null;\n\t gb.removeFromActiveList(this);\n\t }\n\t gb.resetScore();\n\t\tsuper.fire(firer);\n\t}", "public void performAttack(){\r\n // For every zombie\r\n for (int i = 0 ; i < allZombies.getZombies().size(); i++) {\r\n // Variables used to prevent long getter lines\r\n int zombieX = allZombies.getZombies().get(i).getCurrX();\r\n int zombieY = allZombies.getZombies().get(i).getCurrY();\r\n Zombie zombie = allZombies.getZombies().get(i);\r\n // If the zombie is in range and alive:\r\n if(isInRange(zombieX,zombieY) && zombie.isAlive()) {\r\n // kill the zombie and increase score by 1.\r\n allZombies.getZombies().get(i).setAlive(false);\r\n increaseScore();\r\n }\r\n }\r\n }", "public void useWeapon(Character victim) {\n Weapons weapons = this.getInventory().getFirstWeapon();\n if (weapons == null)\n this.hit(victim);\n else {\n int vStrength = victim.getStrength();\n int mStrength = this.getStrength() * Hero.HERO_BONUS_OVER_ALL_CHARS + weapons.getDamage();\n if (vStrength >= mStrength) return;\n int strDif = mStrength - vStrength;\n int vLife = victim.getLife();\n vLife -= strDif;\n victim.setLife(vLife);\n this.getInventory().removeItems(weapons);\n }\n }", "private static void attack(RobotInfo target) throws GameActionException {\n if (SOLDIER_DEBUG) {\n System.out.println(\"attacking\");\n }\n BulletInfo[] bullets = rc.senseNearbyBullets(EvasiveSoldier.BULLET_DETECT_RADIUS);\n RobotInfo[] robots = rc.senseNearbyRobots(EvasiveSoldier.ENEMY_DETECT_RADIUS);\n MapLocation targetLocation = target.getLocation();\n move(bullets, robots, targetLocation);\n //RobotUtils.tryMoveDestination(targetLocation);\n if (TargetingUtils.clearShot(here, target) || (rc.getType() == RobotType.GARDENER && rc.getOpponentVictoryPoints() > 10)) {\n if (SOLDIER_DEBUG) {\n System.out.println(\"clearShot to target\");\n }\n Direction towardsEnemy = here.directionTo(targetLocation);\n float distanceEnemy = here.distanceTo(targetLocation);\n if (distanceEnemy <= 3.5 && rc.canFirePentadShot() && rc.getTeamBullets() > 200) {\n rc.firePentadShot(towardsEnemy);\n }\n else {\n if (rc.canFireTriadShot() && rc.getTeamBullets() > 50) {\n rc.fireTriadShot(towardsEnemy);\n }\n else if (rc.canFireSingleShot()) {\n rc.fireSingleShot(towardsEnemy);\n }\n }\n }\n }", "public void attack(CreatureAttack attack, Creature attacked){\r\n if(successfulHit(attack, attacked)){\r\n attacked.attributes.health.hit(attack, attacked);\r\n }\r\n }", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "public void addHitListenerToEnemy(HitListener hl) {\r\n for (Enemy e : enemies) {\r\n e.addHitListener(hl);\r\n }\r\n }" ]
[ "0.6045562", "0.57377803", "0.561977", "0.5564495", "0.5469911", "0.53875315", "0.5354545", "0.5354287", "0.5309625", "0.5258605", "0.52385294", "0.5215532", "0.5214745", "0.521199", "0.51829696", "0.5164637", "0.5152156", "0.5142121", "0.50700283", "0.5069423", "0.5044767", "0.5044662", "0.50301945", "0.50031835", "0.49698752", "0.49689743", "0.49631524", "0.49547848", "0.49547115", "0.49528876", "0.49348173", "0.49172702", "0.4907398", "0.49028096", "0.48968974", "0.48873037", "0.48681593", "0.48669603", "0.48599103", "0.48598614", "0.48568425", "0.48218152", "0.48185214", "0.48156092", "0.4814446", "0.4764422", "0.47539878", "0.47511935", "0.4740907", "0.4735181", "0.47322214", "0.47316214", "0.47187477", "0.4704827", "0.47034508", "0.46987846", "0.46950606", "0.4694734", "0.46893045", "0.46858406", "0.4683992", "0.46801272", "0.46801272", "0.46753043", "0.46562392", "0.46554294", "0.4647583", "0.46448213", "0.46392596", "0.46352494", "0.46334162", "0.46329185", "0.46322945", "0.46268955", "0.4618077", "0.46116948", "0.46110708", "0.46102947", "0.46077415", "0.46044537", "0.45988742", "0.45968428", "0.45910868", "0.45882526", "0.45876247", "0.4587524", "0.45793292", "0.45757523", "0.4575521", "0.45723364", "0.4570093", "0.45699832", "0.45697471", "0.4545804", "0.45435148", "0.45428416", "0.45364085", "0.45204318", "0.45173258", "0.45123824" ]
0.6840209
0
Calculate the leveling chance of Soul Crystals based on the attacker that killed this L2Attackable
private void levelSoulCrystals(final L2Character attacker) { // Only L2PcInstance can absorb a soul if (!(attacker instanceof L2PcInstance) && !(attacker instanceof L2Summon)) { resetAbsorbList(); return; } final int maxAbsorbLevel = getAbsorbLevel(); int minAbsorbLevel = 0; // If this is not a valid L2Attackable, clears the absorbersList and just return if (maxAbsorbLevel == 0) { resetAbsorbList(); return; } // All boss mobs with maxAbsorbLevel 13 have minAbsorbLevel of 12 else 10 if (maxAbsorbLevel > 10) { minAbsorbLevel = maxAbsorbLevel > 12 ? 12 : 10; } // Init some useful vars boolean isSuccess = true; boolean doLevelup = true; final boolean isBossMob = maxAbsorbLevel > 10 ? true : false; final L2NpcTemplate.AbsorbCrystalType absorbType = getTemplate().absorbType; L2PcInstance killer = attacker instanceof L2Summon ? ((L2Summon) attacker).getOwner() : (L2PcInstance) attacker; // If this mob is a boss, then skip some checkings if (!isBossMob) { // Fail if this L2Attackable isn't absorbed or there's no one in its absorbersList if (!isAbsorbed() /* || absorbersList == null */) { resetAbsorbList(); return; } // Fail if the killer isn't in the absorbersList of this L2Attackable and mob is not boss AbsorberInfo ai = absorbersList.get(killer); if (ai == null || ai.absorber.getObjectId() != killer.getObjectId()) { isSuccess = false; } // Check if the soul crystal was used when HP of this L2Attackable wasn't higher than half of it if (ai != null && ai.absorbedHP > getMaxHp() / 2.0) { isSuccess = false; } if (!isSuccess) { resetAbsorbList(); return; } ai = null; } // ******** String[] crystalNFO = null; String crystalNME = ""; final int dice = Rnd.get(100); int crystalQTY = 0; int crystalLVL = 0; int crystalOLD = 0; int crystalNEW = 0; // ******** // Now we have four choices: // 1- The Monster level is too low for the crystal. Nothing happens. // 2- Everything is correct, but it failed. Nothing happens. (57.5%) // 3- Everything is correct, but it failed. The crystal scatters. A sound event is played. (10%) // 4- Everything is correct, the crystal level up. A sound event is played. (32.5%) List<L2PcInstance> players = new ArrayList<>(); if (absorbType == L2NpcTemplate.AbsorbCrystalType.FULL_PARTY && killer.isInParty()) { players = killer.getParty().getPartyMembers(); } else if (absorbType == L2NpcTemplate.AbsorbCrystalType.PARTY_ONE_RANDOM && killer.isInParty()) { // This is a naive method for selecting a random member. It gets any random party member and // then checks if the member has a valid crystal. It does not select the random party member // among those who have crystals, only. However, this might actually be correct (same as retail). players.add(killer.getParty().getPartyMembers().get(Rnd.get(killer.getParty().getMemberCount()))); } else { players.add(killer); } for (final L2PcInstance player : players) { if (player == null) { continue; } crystalQTY = 0; L2ItemInstance[] inv = player.getInventory().getItems(); for (final L2ItemInstance item : inv) { final int itemId = item.getItemId(); for (final int id : SoulCrystal.SoulCrystalTable) { // Find any of the 39 possible crystals. if (id == itemId) { crystalQTY++; // Keep count but make sure the player has no more than 1 crystal if (crystalQTY > 1) { isSuccess = false; break; } // Validate if the crystal has already leveled if (id != SoulCrystal.RED_NEW_CRYSTAL && id != SoulCrystal.GRN_NEW_CYRSTAL && id != SoulCrystal.BLU_NEW_CRYSTAL) { try { if (item.getItem().getName().contains("Grade")) { // Split the name of the crystal into 'name' & 'level' crystalNFO = item.getItem().getName().trim().replace(" Grade ", "-").split("-"); // Set Level to 13 crystalLVL = 13; // Get Name crystalNME = crystalNFO[0].toLowerCase(); } else { // Split the name of the crystal into 'name' & 'level' crystalNFO = item.getItem().getName().trim().replace(" Stage ", "").split("-"); // Get Level crystalLVL = Integer.parseInt(crystalNFO[1].trim()); // Get Name crystalNME = crystalNFO[0].toLowerCase(); } // Allocate current and levelup ids' for higher level crystals if (crystalLVL > 9) { for (final int[] element : SoulCrystal.HighSoulConvert) { // Get the next stage above 10 using array. if (id == element[0]) { crystalNEW = element[1]; break; } } } else { crystalNEW = id + 1; } } catch (final NumberFormatException nfe) { LOGGER.warn("An attempt to identify a soul crystal failed, " + "verify the names have not changed in etcitem table.", nfe); player.sendMessage("There has been an error handling your soul crystal." + " Please notify your server admin."); isSuccess = false; break; } catch (final Exception e) { e.printStackTrace(); isSuccess = false; break; } } else { crystalNME = item.getItem().getName().toLowerCase().trim(); crystalNEW = id + 1; } // Done crystalOLD = id; break; } } if (!isSuccess) { break; } } inv = null; // If the crystal level is way too high for this mob, say that we can't increase it if (crystalLVL < minAbsorbLevel || crystalLVL >= maxAbsorbLevel) { doLevelup = false; } // The player doesn't have any crystals with him get to the next player. if (crystalQTY < 1 || crystalQTY > 1 || !isSuccess || !doLevelup) { // Too many crystals in inventory. if (crystalQTY > 1) { player.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_FAILED_RESONATION)); } // The soul crystal stage of the player is way too high // Like L2OFF message must not appear if char hasn't crystal on inventory else if (!doLevelup && crystalQTY > 0) { player.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_REFUSED)); } crystalQTY = 0; continue; } /* * TODO: Confirm boss chance for crystal level up and for crystal breaking. It is known that bosses with FULL_PARTY crystal level ups have 100% success rate, but this is not the case for the other bosses (one-random or last-hit). While not confirmed, it is most reasonable that crystals leveled up at * bosses will never break. Also, the chance to level up is guessed as around 70% if not higher. */ final int chanceLevelUp = isBossMob ? 70 : SoulCrystal.LEVEL_CHANCE; // If succeeds or it is a full party absorb, level up the crystal. if (absorbType == L2NpcTemplate.AbsorbCrystalType.FULL_PARTY && doLevelup || dice <= chanceLevelUp) { // Give staged crystal exchangeCrystal(player, crystalOLD, crystalNEW, false); } // If true and not a last-hit mob, break the crystal. else if (!isBossMob && dice >= 100.0 - SoulCrystal.BREAK_CHANCE) { // Remove current crystal an give a broken open. if (crystalNME.startsWith("red")) { exchangeCrystal(player, crystalOLD, SoulCrystal.RED_BROKEN_CRYSTAL, true); } else if (crystalNME.startsWith("gre")) { exchangeCrystal(player, crystalOLD, SoulCrystal.GRN_BROKEN_CYRSTAL, true); } else if (crystalNME.startsWith("blu")) { exchangeCrystal(player, crystalOLD, SoulCrystal.BLU_BROKEN_CRYSTAL, true); } resetAbsorbList(); } else { player.sendPacket(new SystemMessage(SystemMessageId.SOUL_CRYSTAL_ABSORBING_FAILED)); } } killer = null; players = null; crystalNFO = null; crystalNME = null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static double calcBlowDamage(L2Character attacker, L2Character target, L2Skill skill, byte shld, double ssBonus)\n\t{\n\n\t\tdouble pAtk = attacker.calcStat(Stats.CRITICAL_ATTACK, attacker.getPAtk(target), target, skill);\n\t\tdouble levelMod = attacker.getLevelMod();\n\t\tdouble power = skill.getPower(target instanceof L2Playable, target instanceof L2Attackable);\n\t\tdouble pDef = target.getPDef(attacker);\n\n\t\tpAtk += calcValakasAttribute(attacker, target, skill);\n\n\t\tswitch (shld)\n\t\t{\n\t\t\tcase SHIELD_DEFENSE_SUCCEED:\n\t\t\t\tpDef += target.getShldDef();\n\t\t\t\tbreak;\n\t\t\tcase SHIELD_DEFENSE_PERFECT_BLOCK: // perfect block\n\t\t\t\treturn 1;\n\t\t}\n\n\t\tif (skill.getId() == 10510 && target.getFirstEffect(\"bleeding\") != null) // Chain Blow\n\t\t{\n\t\t\tpower *= 1.20;\n\t\t}\n\n\t\tdouble critBonus = attacker.calcStat(Stats.PSKILL_CRIT_DMG, 1, target, skill);\n\t\tif (critBonus > 1.3)\n\t\t{\n\t\t\tcritBonus = 1.3;\n\t\t}\n\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DAMAGE, critBonus, target, skill);\n\t\tdouble critStaticBonus = attacker.calcStat(Stats.CRITICAL_DAMAGE_ADD, 1, target, null);\n\t\tcritBonus = target.calcStat(Stats.CRIT_VULN, critBonus, target, skill);\n\t\tcritStaticBonus = target.calcStat(Stats.CRIT_ADD_VULN, critStaticBonus, target, skill);\n\n\t\tif (isInFrontOf(target, attacker))\n\t\t{\n\t\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DMG_FRONT, critBonus, target, null);\n\t\t}\n\t\telse if (isBehind(target, attacker))\n\t\t{\n\t\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DMG_BEHIND, critBonus, target, null);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DMG_SIDE, critBonus, target, null);\n\t\t}\n\n\t\t// get the vulnerability for the instance due to skills (buffs, passives, toggles, etc)\n\t\tpAtk = target.calcStat(Stats.DAGGER_WPN_VULN, pAtk, target, null);\n\n\t\tdouble positionBonus = 0.0;\n\t\tif (attacker.isBehind(target))\n\t\t{\n\t\t\tpositionBonus = 0.80; // Behind bonus .20\n\t\t}\n\t\telse if (!attacker.isInFrontOf(target))\n\t\t{\n\t\t\tpositionBonus = 0.05; // Side bonus\n\t\t}\n\n\t\t// Random weapon damage\n\t\tdouble weaponRandom = attacker.getRandomDamageMultiplier();\n\n\t\tdouble finalBonus = 1;\n\t\tif (attacker instanceof L2Playable && target instanceof L2Playable)\n\t\t{\n\t\t\t// Dmg bonuses in PvP fight\n\t\t\tfinalBonus *= attacker.getPvPPhysicalSkillDamage(target);\n\t\t\t// Def bonuses in PvP fight\n\t\t\tfinalBonus /= target.getPvPPhysicalSkillDefense(attacker);\n\t\t}\n\n\t\tfinalBonus *= calcElemental(attacker, target, skill);\n\n\t\tif (target instanceof L2Attackable && !target.isRaid() && !target.isRaidMinion() &&\n\t\t\t\ttarget.getLevel() >= Config.MIN_NPC_LVL_DMG_PENALTY && attacker.getActingPlayer() != null &&\n\t\t\t\ttarget.getLevel() - attacker.getActingPlayer().getLevel() >= 2)\n\t\t{\n\t\t\tint lvlDiff = target.getLevel() - attacker.getActingPlayer().getLevel() - 1;\n\t\t\tif (lvlDiff > Config.NPC_SKILL_DMG_PENALTY.size())\n\t\t\t{\n\t\t\t\tfinalBonus *= Config.NPC_SKILL_DMG_PENALTY.get(Config.NPC_SKILL_DMG_PENALTY.size());\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tfinalBonus *= Config.NPC_SKILL_DMG_PENALTY.get(lvlDiff);\n\t\t\t}\n\t\t}\n\n\t\tif (Config.isServer(Config.TENKAI) && attacker.getActingPlayer() != null)\n\t\t{\n\t\t\tif (pAtk > 180000)\n\t\t\t{\n\t\t\t\tpAtk = 180000 + Math.pow(pAtk - 180000, 0.8);\n\t\t\t}\n\t\t\tif (critBonus > 5)\n\t\t\t{\n\t\t\t\tcritBonus = 4 + Math.pow(critBonus - 4, 0.65);\n\t\t\t}\n\t\t}\n\n\t\tdouble damage = 77.0 *\n\t\t\t\t((pAtk * levelMod + power) * weaponRandom * 0.666 * critBonus * ssBonus + critStaticBonus * 6 +\n\t\t\t\t\t\tpositionBonus * (power + pAtk * ssBonus)) / pDef * finalBonus;\n\n\t\t//System.out.println(attacker.getName());\n\t\t//System.out.println(skill.getName() + \": \" + skill.getPower() + \" | \" + positionBonus + \" | \" + finalBonus\n\t\t//\t\t+ \" | \" + ssBonus + \" | \" + critBonus + \" | \" + damage);\n\n\t\tdamage = calcCustomModifier(attacker, target, damage);\n\n\t\tif (Config.isServer(Config.TENKAI) && damage > 20000 && attacker.getActingPlayer() != null &&\n\t\t\t\ttarget.getActingPlayer() != null)\n\t\t{\n\t\t\tdamage = 20000 + Math.pow(damage - 20000, 0.93);\n\t\t}\n\n\t\tif (attacker instanceof L2PcInstance)\n\t\t{\n\t\t\tL2PcInstance player = (L2PcInstance) attacker;\n\t\t\tplayer.sendSysMessage(\n\t\t\t\t\t\"Formula = (77 * ((pAtk * levelMod + power) * weaponRandom * 0.666 * critBonus * ssBonus + critStaticBonus * 6\" +\n\t\t\t\t\t\t\t\" + positionBonus * (power + pAtk * ssBonus)) / pDef) * finalBonus\");\n\t\t\tplayer.sendSysMessage(\"P.Atk = \" + pAtk + \".\");\n\t\t\tplayer.sendSysMessage(\"Level Mod = \" + attacker.getLevelMod() + \".\");\n\t\t\tplayer.sendSysMessage(\"Power = \" + power + \".\");\n\t\t\tplayer.sendSysMessage(\"Soulshots Multiplier = \" + ssBonus + \".\");\n\t\t\tplayer.sendSysMessage(\"Final Multiplier = \" + finalBonus + \".\");\n\t\t\tplayer.sendSysMessage(\"CritDamageModifier = \" + critBonus + \".\");\n\t\t\tplayer.sendSysMessage(\"PositionBonus = \" + positionBonus + \".\");\n\t\t\t//player.sendSysMessage(\"WeaponVuln = \" + weaponVuln + \".\");\n\t\t\tplayer.sendSysMessage(\"CritDamageAdd = \" + critStaticBonus + \".\");\n\t\t\tplayer.sendSysMessage(\"Defense = \" + pDef + \".\");\n\t\t\tplayer.sendSysMessage(\".......\");\n\t\t}\n\n\t\tif (Config.isServer(Config.TENKAI) && target instanceof L2PcInstance && attacker instanceof L2PcInstance &&\n\t\t\t\tdamage > 10000 && pDef > 5000)\n\t\t{\n\t\t\tConnection con = null;\n\t\t\ttry\n\t\t\t{\n\t\t\t\tcon = L2DatabaseFactory.getInstance().getConnection();\n\t\t\t\tPreparedStatement statement = con.prepareStatement(\n\t\t\t\t\t\t\"INSERT INTO log_damage\" + \"(attacker, target, attackerClass, targetClass, damageType, \" +\n\t\t\t\t\t\t\t\t\"attack, defense, levelMod, power, powerBonus, critBonus, \" +\n\t\t\t\t\t\t\t\t\"critStaticBonus, positionBonus, ssBonus, finalBonus, damage)\" + \"VALUES\" +\n\t\t\t\t\t\t\t\t\"(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)\");\n\t\t\t\tstatement.setString(1, attacker.getName());\n\t\t\t\tstatement.setString(2, target.getName());\n\t\t\t\tstatement.setInt(3, attacker.getActingPlayer().getClassId());\n\t\t\t\tstatement.setInt(4, target.getActingPlayer().getClassId());\n\t\t\t\tstatement.setString(5, \"BLOW\");\n\t\t\t\tstatement.setDouble(6, pAtk);\n\t\t\t\tstatement.setDouble(7, pDef);\n\t\t\t\tstatement.setDouble(8, levelMod);\n\t\t\t\tstatement.setDouble(9, power);\n\t\t\t\tstatement.setDouble(10, 1);\n\t\t\t\tstatement.setDouble(11, critBonus);\n\t\t\t\tstatement.setDouble(12, critStaticBonus);\n\t\t\t\tstatement.setDouble(13, positionBonus);\n\t\t\t\tstatement.setDouble(14, ssBonus);\n\t\t\t\tstatement.setDouble(15, finalBonus);\n\t\t\t\tstatement.setDouble(16, damage);\n\t\t\t\tstatement.execute();\n\t\t\t\tstatement.close();\n\t\t\t}\n\t\t\tcatch (Exception e)\n\t\t\t{\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\tfinally\n\t\t\t{\n\t\t\t\tL2DatabaseFactory.close(con);\n\t\t\t}\n\t\t}\n\n\t\treturn damage;\n\t}", "int getMinigameDefenseChancesLeft();", "public int attackRoll(){\r\n\t\treturn (int) (Math.random() * 100);\r\n\t}", "public int computeRangedDamageTo(Combatant opponent) { return 0; }", "double getCritChance();", "public int calculateCombatLevel() {\r\n if (entity instanceof NPC) {\r\n return ((NPC) entity).getDefinition().getCombatLevel();\r\n }\r\n int combatLevel;\r\n int melee = staticLevels[ATTACK] + staticLevels[STRENGTH];\r\n int range = (int) (1.5 * staticLevels[RANGE]);\r\n int mage = (int) (1.5 * staticLevels[MAGIC]);\r\n if (melee > range && melee > mage) {\r\n combatLevel = melee;\r\n } else if (range > melee && range > mage) {\r\n combatLevel = range;\r\n } else {\r\n combatLevel = mage;\r\n }\r\n combatLevel = staticLevels[DEFENCE] + staticLevels[HITPOINTS] + (staticLevels[PRAYER] / 2) + (int) (1.3 * combatLevel);\r\n return combatLevel / 4;\r\n }", "public static int getEnemyLives(){\n return 1 + currentLvl * 2;\n\n }", "public static byte calcShldUse(L2Character attacker, L2Character target, L2Skill skill, boolean sendSysMsg)\n\t{\n\t\tif (skill != null && (skill.ignoreShield() || skill.isMagic()))\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\n\t\tL2Item item = target.getSecondaryWeaponItem();\n\t\tif (item == null || !(item instanceof L2Armor) || ((L2Armor) item).getItemType() == L2ArmorType.SIGIL)\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\n\t\tdouble shldRate = target.calcStat(Stats.SHIELD_RATE, 0, attacker, null) * BaseStats.DEX.calcBonus(target);\n\t\tif (shldRate == 0.0)\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\n\t\tint degreeside = (int) target.calcStat(Stats.SHIELD_DEFENCE_ANGLE, 120, null, null);\n\t\tif (degreeside < 360 && !target.isFacing(attacker, degreeside))\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\n\t\t// Tenkai custom: Make shields way less effective on non-sigel awakened classes\n\t\t/*if (target instanceof L2PcInstance\n\t\t\t\t&& ((L2PcInstance)target).getClassId() > 139)\n\t\t\tshldRate *= 0.1;*/\n\n\t\tbyte result = SHIELD_DEFENSE_FAILED;\n\t\t// if attacker use bow and target wear shield, shield block rate is multiplied by 1.3 (30%)\n\t\tL2Weapon at_weapon = attacker.getActiveWeaponItem();\n\t\tif (at_weapon != null && at_weapon.getItemType() == L2WeaponType.BOW)\n\t\t{\n\t\t\tshldRate *= 1.3;\n\t\t}\n\n\t\tint rnd = Rnd.get(100);\n\t\tif (shldRate * (Config.ALT_PERFECT_SHLD_BLOCK / 100.0) > rnd)\n\t\t{\n\t\t\tresult = SHIELD_DEFENSE_PERFECT_BLOCK;\n\t\t}\n\t\telse if (shldRate > rnd)\n\t\t{\n\t\t\tresult = SHIELD_DEFENSE_SUCCEED;\n\t\t}\n\n\t\tif (sendSysMsg && target instanceof L2PcInstance)\n\t\t{\n\t\t\tL2PcInstance enemy = (L2PcInstance) target;\n\t\t\tswitch (result)\n\t\t\t{\n\t\t\t\tcase SHIELD_DEFENSE_SUCCEED:\n\t\t\t\t\tenemy.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.SHIELD_DEFENCE_SUCCESSFULL));\n\t\t\t\t\tbreak;\n\t\t\t\tcase SHIELD_DEFENSE_PERFECT_BLOCK:\n\t\t\t\t\tenemy.sendPacket(SystemMessage\n\t\t\t\t\t\t\t.getSystemMessage(SystemMessageId.YOUR_EXCELLENT_SHIELD_DEFENSE_WAS_A_SUCCESS));\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tif (result >= 1)\n\t\t{\n\t\t\t// ON_SHIELD_BLOCK\n\t\t\tif (target.getChanceSkills() != null)\n\t\t\t{\n\t\t\t\ttarget.getChanceSkills().onBlock(target);\n\t\t\t}\n\t\t}\n\n\t\treturn result;\n\t}", "@Override\r\n\tpublic int attack() {\r\n\t\treturn rnd.nextInt(MAX_MONSTER_ATTACK_DAMAGE);\r\n\t}", "public int getLevel(){\n \t\treturn (strength + intelligence + stamina + Math.abs(charm) + Math.abs(cuteness))/5;\n \t}", "public double getHpns(){\r\n switch(this.grlType){\r\n case \"The Choosy\":\r\n return this.chGrlfrnd.iLevel;\r\n case \"The Normal\":\r\n return this.nGrlfrnd.iLevel;\r\n case \"The Desperate\":\r\n return this.dsGrlfrnd.iLevel;\r\n \r\n }\r\n return 0;\r\n }", "public int attack()\n {\n int percent = Randomizer.nextInt(100) + 1;\n int baseDamage = super.attack();\n if(percent <= 5)\n {\n baseDamage *= 2;\n baseDamage += 50;\n }\n return baseDamage;\n }", "private void calculateDamage() {\n this.baseDamage = this.actualBaseDamage;\n this.applyPowers();\n this.baseDamage = Math.max(this.baseDamage - ((this.baseDamage * this.otherCardsPlayed) / this.magicNumber), 0);\n }", "public static double calcPhysSkillDam(L2Character attacker, L2Character target, L2Skill skill, byte shld, boolean crit, boolean dual, double ssBonus)\n\t{\n\t\tfinal boolean isPvP = attacker instanceof L2Playable && target instanceof L2Playable;\n\t\tfinal boolean isPvE = attacker instanceof L2Playable && target instanceof L2Attackable ||\n\t\t\t\tattacker instanceof L2Attackable && target instanceof L2Playable;\n\n\t\tdouble pAtk = attacker.getPAtk(target);\n\t\tdouble levelMod = attacker.getLevelMod();\n\t\tdouble pDef = target.getPDef(attacker);\n\n\t\tpAtk += calcValakasAttribute(attacker, target, skill);\n\n\t\tif (attacker instanceof L2Npc)\n\t\t{\n\t\t\tif (((L2Npc) attacker)._soulshotcharged)\n\t\t\t{\n\t\t\t\tssBonus = L2ItemInstance.CHARGED_SOULSHOT;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tssBonus = L2ItemInstance.CHARGED_NONE;\n\t\t\t}\n\n\t\t\t((L2Npc) attacker)._soulshotcharged = false;\n\t\t}\n\n\t\tswitch (shld)\n\t\t{\n\t\t\tcase SHIELD_DEFENSE_SUCCEED:\n\t\t\t\tpDef += target.getShldDef();\n\t\t\t\tbreak;\n\t\t\tcase SHIELD_DEFENSE_PERFECT_BLOCK: // perfect block\n\t\t\t\treturn 1.;\n\t\t}\n\n\t\tif (skill.getIgnoredDefPercent() > 0)\n\t\t{\n\t\t\tpDef -= pDef * skill.getIgnoredDefPercent() / 100;\n\t\t}\n\n\t\tdouble power = skill.getPower(attacker, target, isPvP, isPvE);\n\t\tdouble powerBonus = 1.0;\n\t\tif (skill.getMaxChargeConsume() > 0)\n\t\t{\n\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t{\n\t\t\t\tint consume = Math.min(((L2PcInstance) attacker).getCharges(), skill.getMaxChargeConsume());\n\t\t\t\tfor (int i = 0; i < consume; i++)\n\t\t\t\t{\n\t\t\t\t\tpowerBonus += 0.1;\n\t\t\t\t}\n\n\t\t\t\t((L2PcInstance) attacker).decreaseCharges(consume);\n\t\t\t}\n\t\t\tpowerBonus = attacker.calcStat(Stats.MOMENTUM_POWER, powerBonus, attacker, skill);\n\t\t}\n\n\t\tif (skill.getId() == 10265 || skill.getId() == 10288) //Eruption, Hurricane Storm\n\t\t{\n\t\t\tL2Weapon attackerWeapon = attacker.getActiveWeaponItem();\n\t\t\tif (attackerWeapon != null)\n\t\t\t{\n\t\t\t\t//Power - 10% when using a sword, dualsword, blunt, or fist weapon. Power + 50% when using a spear.\n\t\t\t\tif (attackerWeapon.getItemType() == L2WeaponType.SWORD ||\n\t\t\t\t\t\tattackerWeapon.getItemType() == L2WeaponType.BIGSWORD ||\n\t\t\t\t\t\tattackerWeapon.getItemType() == L2WeaponType.DUAL ||\n\t\t\t\t\t\tattackerWeapon.getItemType() == L2WeaponType.FIST ||\n\t\t\t\t\t\tattackerWeapon.getItemType() == L2WeaponType.BLUNT ||\n\t\t\t\t\t\tattackerWeapon.getItemType() == L2WeaponType.DUALBLUNT ||\n\t\t\t\t\t\tattackerWeapon.getItemType() == L2WeaponType.BIGBLUNT)\n\t\t\t\t{\n\t\t\t\t\tpowerBonus *= 0.90;\n\t\t\t\t}\n\t\t\t\telse if (attackerWeapon.getItemType() == L2WeaponType.POLE)\n\t\t\t\t{\n\t\t\t\t\tpowerBonus *= 1.50;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// defence modifier depending of the attacker weapon\n\t\tL2Weapon weapon = attacker.getActiveWeaponItem();\n\t\tStats weaponStat = null;\n\t\tboolean isBow = false;\n\t\tboolean isDual = false;\n\t\tif (weapon != null && !attacker.isTransformed())\n\t\t{\n\t\t\tswitch (weapon.getItemType())\n\t\t\t{\n\t\t\t\tcase BOW:\n\t\t\t\t\tisBow = true;\n\t\t\t\t\tweaponStat = Stats.BOW_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase CROSSBOW:\n\t\t\t\tcase CROSSBOWK:\n\t\t\t\t\tisBow = true;\n\t\t\t\t\tweaponStat = Stats.CROSSBOW_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase BLUNT:\n\t\t\t\t\tweaponStat = Stats.BLUNT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUALBLUNT:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.BLUNT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DAGGER:\n\t\t\t\t\tweaponStat = Stats.DAGGER_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUAL:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.DUAL_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUALFIST:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.DUALFIST_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase ETC:\n\t\t\t\t\tweaponStat = Stats.ETC_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase FIST:\n\t\t\t\t\tweaponStat = Stats.FIST_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase POLE:\n\t\t\t\t\tweaponStat = Stats.POLE_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase SWORD:\n\t\t\t\t\tweaponStat = Stats.SWORD_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase BIGSWORD:\n\t\t\t\t\tweaponStat = Stats.BIGSWORD_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase BIGBLUNT:\n\t\t\t\t\tweaponStat = Stats.BIGBLUNT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUALDAGGER:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.DUALDAGGER_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase RAPIER:\n\t\t\t\t\tweaponStat = Stats.RAPIER_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase ANCIENTSWORD:\n\t\t\t\t\tweaponStat = Stats.ANCIENT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tif (isDual && ssBonus >= 2.0)\n\t\t{\n\t\t\tssBonus *= 1.02;\n\t\t}\n\n\t\t// for summon use pet weapon vuln, since they can't hold weapon\n\t\tif (attacker instanceof L2SummonInstance)\n\t\t{\n\t\t\tweaponStat = Stats.PET_WPN_VULN;\n\t\t}\n\n\t\tif (weaponStat != null)\n\t\t{\n\t\t\t// get the vulnerability due to skills (buffs, passives, toggles, etc)\n\t\t\tpAtk = target.calcStat(weaponStat, pAtk, target, skill);\n\t\t}\n\n\t\tif (target instanceof L2Npc)\n\t\t{\n\t\t\tswitch (((L2Npc) target).getTemplate().getRace())\n\t\t\t{\n\t\t\t\tcase BEAST:\n\t\t\t\t\tpAtk *= attacker.getPAtkMonsters(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase ANIMAL:\n\t\t\t\t\tpAtk *= attacker.getPAtkAnimals(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase PLANT:\n\t\t\t\t\tpAtk *= attacker.getPAtkPlants(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase DRAGON:\n\t\t\t\t\tpAtk *= attacker.getPAtkDragons(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase BUG:\n\t\t\t\t\tpAtk *= attacker.getPAtkInsects(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase GIANT:\n\t\t\t\t\tpAtk *= attacker.getPAtkGiants(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase MAGICCREATURE:\n\t\t\t\t\tpAtk *= attacker.getPAtkMagicCreatures(target);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\t// nothing\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tdouble critBonus = 1.0;\n\t\tif (crit)\n\t\t{\n\t\t\tcritBonus = 2.0 * attacker.calcStat(Stats.PSKILL_CRIT_DMG, 1, target, skill);\n\t\t}\n\n\t\tdouble positionBonus = 0.0;\n\t\tif (attacker.isBehind(target))\n\t\t{\n\t\t\tpositionBonus = 0.20; // Behind bonus\n\t\t}\n\t\telse if (!attacker.isInFrontOf(target))\n\t\t{\n\t\t\tpositionBonus = 0.05; // Side bonus\n\t\t}\n\n\t\t// Weapon random damage\n\t\tdouble weaponRandom = attacker.getRandomDamageMultiplier();\n\n\t\tdouble skillDmgBonus = 1.0;\n\t\t// Dmg/def bonusses in PvP fight\n\t\tif (isPvP)\n\t\t{\n\t\t\tskillDmgBonus *= attacker.getPvPPhysicalSkillDamage(target) / target.getPvPPhysicalSkillDefense(attacker);\n\t\t}\n\n\t\tif (isPvE)\n\t\t{\n\t\t\tif (isBow)\n\t\t\t{\n\t\t\t\tskillDmgBonus *= attacker.calcStat(Stats.PVE_BOW_SKILL_DMG, 1, target, skill);\n\t\t\t}\n\n\t\t\tskillDmgBonus *= attacker.getPvEPhysicalSkillDamage(target) / target.getPvEPhysicalSkillDefense(attacker);\n\t\t}\n\n\t\t// Physical skill dmg boost\n\t\tskillDmgBonus *= attacker.calcStat(Stats.PHYSICAL_SKILL_POWER, 1, target, skill);\n\t\tif (Config.isServer(Config.TENKAI) && attacker.getActingPlayer() != null && skillDmgBonus > 2)\n\t\t{\n\t\t\tskillDmgBonus = 1 + Math.pow(skillDmgBonus - 1, 0.6);\n\t\t}\n\n\t\tdouble finalBonus = skillDmgBonus;\n\t\tfinalBonus *= calcElemental(attacker, target, skill);\n\n\t\tif (target instanceof L2Attackable)\n\t\t{\n\t\t\tif (!target.isRaid() && !target.isRaidMinion() && target.getLevel() >= Config.MIN_NPC_LVL_DMG_PENALTY &&\n\t\t\t\t\tattacker.getActingPlayer() != null &&\n\t\t\t\t\ttarget.getLevel() - attacker.getActingPlayer().getLevel() >= 2)\n\t\t\t{\n\t\t\t\tint lvlDiff = target.getLevel() - attacker.getActingPlayer().getLevel() - 1;\n\t\t\t\tif (lvlDiff > Config.NPC_SKILL_DMG_PENALTY.size())\n\t\t\t\t{\n\t\t\t\t\tfinalBonus *= Config.NPC_SKILL_DMG_PENALTY.get(Config.NPC_SKILL_DMG_PENALTY.size());\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tfinalBonus *= Config.NPC_SKILL_DMG_PENALTY.get(lvlDiff);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (skill.getId() == 30500 && target.isStunned()) // Lateral hit\n\t\t{\n\t\t\tfinalBonus *= 1.20;\n\t\t}\n\n\t\tif (Config.isServer(Config.TENKAI) && attacker.getActingPlayer() != null)\n\t\t{\n\t\t\tif (pAtk > 170000)\n\t\t\t{\n\t\t\t\tpAtk = 170000 + Math.pow(pAtk - 170000, 0.8);\n\t\t\t}\n\t\t\tif (critBonus > 2)\n\t\t\t{\n\t\t\t\tcritBonus = 1 + Math.pow(critBonus - 1, 0.55);\n\t\t\t}\n\t\t\tif (finalBonus > 2)\n\t\t\t{\n\t\t\t\tfinalBonus = 1 + Math.pow(finalBonus - 1, 0.6);\n\t\t\t}\n\t\t}\n\n\t\tdouble damage = 77.0 * ((pAtk * levelMod + power) * powerBonus * weaponRandom + positionBonus * pAtk) / pDef *\n\t\t\t\tfinalBonus * ssBonus * critBonus;\n\t\t//if (isBow)\n\t\t{\n\t\t\t//if (ssBonus >= 2.0)\n\t\t\t//\tssBonus *= 0.75;\n\t\t\t//damage = (70.0 * (pAtk * levelMod + pAtk + critBonus * power) * powerBonus * weaponRandom * (1 + positionBonus) / pDef) * finalBonus * ssBonus;\n\t\t}\n\n\t\tdamage = calcCustomModifier(attacker, target, damage);\n\n\t\tif (Config.isServer(Config.TENKAI) && isPvP && damage > 30000)\n\t\t{\n\t\t\tdamage = 30000 + Math.pow(damage - 30000, 0.9);\n\t\t}\n\n\t\t//if (isPvP)\n\t\t//System.out.println(skill.getName() + \": \" + pAtk + \" | \" + levelMod\n\t\t//\t\t+ \" | \" + skill.getPower() + \" | \" + powerBonus + \" | \" + finalBonus\n\t\t//\t\t+ \" | \" + ssBonus + \" | \" + critBonus + \" -> \" + damage);\n\n\t\tint dmgCap = (int) target.getStat().calcStat(Stats.DAMAGE_CAP, 0, null, null);\n\t\tif (dmgCap > 0 && damage > dmgCap)\n\t\t{\n\t\t\tdamage = dmgCap;\n\t\t}\n\n\t\tif (damage > 0 && damage < 1)\n\t\t{\n\t\t\tdamage = 1;\n\t\t}\n\t\telse if (damage < 0)\n\t\t{\n\t\t\tdamage = 0;\n\t\t}\n\n\t\tif (Config.isServer(Config.TENKAI) && target instanceof L2PcInstance && attacker instanceof L2PcInstance &&\n\t\t\t\tdamage > 30000 && pDef > 5000)\n\t\t{\n\t\t\tConnection con = null;\n\t\t\ttry\n\t\t\t{\n\t\t\t\t//if (damage > 30000)\n\t\t\t\t//\tSystem.out.println(attacker + \" \" + damage);\n\t\t\t\tcon = L2DatabaseFactory.getInstance().getConnection();\n\t\t\t\tPreparedStatement statement = con.prepareStatement(\n\t\t\t\t\t\t\"INSERT INTO log_damage\" + \"(attacker, target, attackerClass, targetClass, damageType, \" +\n\t\t\t\t\t\t\t\t\"attack, defense, levelMod, power, powerBonus, critBonus, \" +\n\t\t\t\t\t\t\t\t\"critStaticBonus, positionBonus, ssBonus, finalBonus, damage)\" + \"VALUES\" +\n\t\t\t\t\t\t\t\t\"(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)\");\n\t\t\t\tstatement.setString(1, attacker.getName());\n\t\t\t\tstatement.setString(2, target.getName());\n\t\t\t\tstatement.setInt(3, attacker.getActingPlayer().getClassId());\n\t\t\t\tstatement.setInt(4, target.getActingPlayer().getClassId());\n\t\t\t\tstatement.setString(5, \"PSKILL\");\n\t\t\t\tstatement.setDouble(6, pAtk);\n\t\t\t\tstatement.setDouble(7, pDef);\n\t\t\t\tstatement.setDouble(8, levelMod);\n\t\t\t\tstatement.setDouble(9, power);\n\t\t\t\tstatement.setDouble(10, powerBonus);\n\t\t\t\tstatement.setDouble(11, critBonus);\n\t\t\t\tstatement.setDouble(12, 0);\n\t\t\t\tstatement.setDouble(13, positionBonus);\n\t\t\t\tstatement.setDouble(14, ssBonus);\n\t\t\t\tstatement.setDouble(15, finalBonus);\n\t\t\t\tstatement.setDouble(16, damage);\n\t\t\t\tstatement.execute();\n\t\t\t\tstatement.close();\n\t\t\t}\n\t\t\tcatch (Exception e)\n\t\t\t{\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\tfinally\n\t\t\t{\n\t\t\t\tL2DatabaseFactory.close(con);\n\t\t\t}\n\t\t}\n\n\t\treturn damage;\n\t}", "public int computeDamageTo(Combatant opponent) { return 0; }", "public int getDamage() {\n\t\treturn (int) (Math.random() * damageVariance) + damage;\n\t}", "public static double calcMagicDam(L2CubicInstance attacker, L2Character target, L2Skill skill, boolean mcrit, byte shld)\n\t{\n\t\tdouble mAtk = attacker.getMAtk();\n\t\tfinal boolean isPvP = target instanceof L2Playable;\n\t\tfinal boolean isPvE = target instanceof L2Attackable;\n\t\tdouble mDef = target.getMDef(attacker.getOwner(), skill);\n\n\t\tswitch (shld)\n\t\t{\n\t\t\tcase SHIELD_DEFENSE_SUCCEED:\n\t\t\t\tmDef += target.getShldDef(); // kamael\n\t\t\t\tbreak;\n\t\t\tcase SHIELD_DEFENSE_PERFECT_BLOCK: // perfect block\n\t\t\t\treturn 1;\n\t\t}\n\n\t\tdouble damage = 91 * Math.sqrt(mAtk) * skill.getPower(isPvP, isPvE) / mDef;\n\t\tL2PcInstance owner = attacker.getOwner();\n\t\t// Failure calculation\n\t\tif (Config.ALT_GAME_MAGICFAILURES && !calcMagicSuccess(owner, target, skill))\n\t\t{\n\t\t\tif (target.getLevel() - skill.getMagicLevel() > 9)\n\t\t\t{\n\t\t\t\tSystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.C1_RESISTED_YOUR_S2);\n\t\t\t\tsm.addCharName(target);\n\t\t\t\tsm.addSkillName(skill);\n\t\t\t\towner.sendPacket(sm);\n\n\t\t\t\tdamage = 1;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tif (skill.getSkillType() == L2SkillType.DRAIN)\n\t\t\t\t{\n\t\t\t\t\towner.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.DRAIN_HALF_SUCCESFUL));\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\towner.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.ATTACK_FAILED));\n\t\t\t\t}\n\n\t\t\t\tdamage /= 2;\n\t\t\t}\n\n\t\t\tif (target instanceof L2PcInstance)\n\t\t\t{\n\t\t\t\tif (skill.getSkillType() == L2SkillType.DRAIN)\n\t\t\t\t{\n\t\t\t\t\tSystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.RESISTED_C1_DRAIN);\n\t\t\t\t\tsm.addCharName(owner);\n\t\t\t\t\ttarget.sendPacket(sm);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tSystemMessage sm = SystemMessage.getSystemMessage(SystemMessageId.RESISTED_C1_MAGIC);\n\t\t\t\t\tsm.addCharName(owner);\n\t\t\t\t\ttarget.sendPacket(sm);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse if (mcrit)\n\t\t{\n\t\t\tdamage *= 3;\n\t\t}\n\n\t\t// CT2.3 general magic vuln\n\t\tdamage *= target.calcStat(Stats.MAGIC_DAMAGE_VULN, 1, null, null);\n\n\t\tdamage *= calcElemental(owner, target, skill);\n\n\t\tif (target instanceof L2Attackable)\n\t\t{\n\t\t\tif (!target.isRaid() && !target.isRaidMinion() && target.getLevel() >= Config.MIN_NPC_LVL_DMG_PENALTY &&\n\t\t\t\t\tattacker.getOwner() != null && target.getLevel() - attacker.getOwner().getLevel() >= 2)\n\t\t\t{\n\t\t\t\tint lvlDiff = target.getLevel() - attacker.getOwner().getLevel() - 1;\n\t\t\t\tif (lvlDiff > Config.NPC_SKILL_DMG_PENALTY.size())\n\t\t\t\t{\n\t\t\t\t\tdamage *= Config.NPC_SKILL_DMG_PENALTY.get(Config.NPC_SKILL_DMG_PENALTY.size());\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tdamage *= Config.NPC_SKILL_DMG_PENALTY.get(lvlDiff);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn damage;\n\t}", "private int calculateLevelModifierForDrop(final L2PcInstance lastAttacker)\n\t{\n\t\tif (Config.DEEPBLUE_DROP_RULES)\n\t\t{\n\t\t\tint highestLevel = lastAttacker.getLevel();\n\t\t\t\n\t\t\t// Check to prevent very high level player to nearly kill mob and let low level player do the last hit.\n\t\t\tif (getAttackByList() != null && !getAttackByList().isEmpty())\n\t\t\t{\n\t\t\t\tfor (final L2Character atkChar : getAttackByList())\n\t\t\t\t{\n\t\t\t\t\tif (atkChar != null && atkChar.getLevel() > highestLevel)\n\t\t\t\t\t{\n\t\t\t\t\t\thighestLevel = atkChar.getLevel();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// According to official data (Prima), deep blue mobs are 9 or more levels below players\n\t\t\tif (highestLevel - 9 >= getLevel())\n\t\t\t{\n\t\t\t\treturn (highestLevel - (getLevel() + 8)) * 9;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn 0;\n\t}", "public static double calcPhysDam(L2Character attacker, L2Character target, byte shld, boolean crit, boolean dual, double ssBonus)\n\t{\n\t\tfinal boolean isPvP = attacker instanceof L2Playable && target instanceof L2Playable;\n\t\tfinal boolean isPvE = attacker instanceof L2Playable && target instanceof L2Attackable ||\n\t\t\t\tattacker instanceof L2Attackable && target instanceof L2Playable;\n\n\t\tdouble pAtk = attacker.getPAtk(target);\n\t\tdouble pDef = target.getPDef(attacker);\n\n\t\tpAtk += calcValakasAttribute(attacker, target, null);\n\n\t\tif (attacker instanceof L2Npc)\n\t\t{\n\t\t\tif (((L2Npc) attacker)._soulshotcharged)\n\t\t\t{\n\t\t\t\tssBonus = L2ItemInstance.CHARGED_SOULSHOT;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tssBonus = L2ItemInstance.CHARGED_NONE;\n\t\t\t}\n\n\t\t\t((L2Npc) attacker)._soulshotcharged = false;\n\t\t}\n\n\t\tswitch (shld)\n\t\t{\n\t\t\tcase SHIELD_DEFENSE_SUCCEED:\n\t\t\t\tpDef += target.getShldDef();\n\t\t\t\tbreak;\n\t\t\tcase SHIELD_DEFENSE_PERFECT_BLOCK: // perfect block\n\t\t\t\treturn 1.;\n\t\t}\n\n\t\t// defence modifier depending of the attacker weapon\n\t\tL2Weapon weapon = attacker.getActiveWeaponItem();\n\t\tStats weaponStat = null;\n\t\tboolean isBow = false;\n\t\tboolean isDual = false;\n\t\tif (weapon != null && !attacker.isTransformed())\n\t\t{\n\t\t\tswitch (weapon.getItemType())\n\t\t\t{\n\t\t\t\tcase BOW:\n\t\t\t\t\tisBow = true;\n\t\t\t\t\tweaponStat = Stats.BOW_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase CROSSBOW:\n\t\t\t\tcase CROSSBOWK:\n\t\t\t\t\tisBow = true;\n\t\t\t\t\tweaponStat = Stats.CROSSBOW_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase BLUNT:\n\t\t\t\t\tweaponStat = Stats.BLUNT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUALBLUNT:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.BLUNT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DAGGER:\n\t\t\t\t\tweaponStat = Stats.DAGGER_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUAL:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.DUAL_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUALFIST:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.DUALFIST_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase ETC:\n\t\t\t\t\tweaponStat = Stats.ETC_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase FIST:\n\t\t\t\t\tweaponStat = Stats.FIST_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase POLE:\n\t\t\t\t\tweaponStat = Stats.POLE_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase SWORD:\n\t\t\t\t\tweaponStat = Stats.SWORD_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase BIGSWORD:\n\t\t\t\t\tweaponStat = Stats.BIGSWORD_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase BIGBLUNT:\n\t\t\t\t\tweaponStat = Stats.BIGBLUNT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUALDAGGER:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.DUALDAGGER_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase RAPIER:\n\t\t\t\t\tweaponStat = Stats.RAPIER_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase ANCIENTSWORD:\n\t\t\t\t\tweaponStat = Stats.ANCIENT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tif (isDual && ssBonus >= 2.0)\n\t\t{\n\t\t\tssBonus *= 1.02;\n\t\t}\n\n\t\t// for summon use pet weapon vuln, since they can't hold weapon\n\t\tif (attacker instanceof L2SummonInstance)\n\t\t{\n\t\t\tweaponStat = Stats.PET_WPN_VULN;\n\t\t}\n\n\t\t// Calculate the weakness to the weapon\n\t\tif (weaponStat != null)\n\t\t{\n\t\t\tpAtk = target.calcStat(weaponStat, pAtk, target, null);\n\t\t}\n\n\t\tif (target instanceof L2Npc)\n\t\t{\n\t\t\tswitch (((L2Npc) target).getTemplate().getRace())\n\t\t\t{\n\t\t\t\tcase BEAST:\n\t\t\t\t\tpAtk *= attacker.getPAtkMonsters(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase ANIMAL:\n\t\t\t\t\tpAtk *= attacker.getPAtkAnimals(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase PLANT:\n\t\t\t\t\tpAtk *= attacker.getPAtkPlants(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase DRAGON:\n\t\t\t\t\tpAtk *= attacker.getPAtkDragons(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase BUG:\n\t\t\t\t\tpAtk *= attacker.getPAtkInsects(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase GIANT:\n\t\t\t\t\tpAtk *= attacker.getPAtkGiants(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase MAGICCREATURE:\n\t\t\t\t\tpAtk *= attacker.getPAtkMagicCreatures(target);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\t// nothing\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tdouble critBonus = 1.0;\n\t\tdouble critStaticBonus = 0.0;\n\t\tif (crit)\n\t\t{\n\t\t\tcritBonus = 2.0;\n\t\t\tpAtk = attacker.calcStat(Stats.CRITICAL_ATTACK, pAtk, target, null);\n\n\t\t\tif (isInFrontOf(target, attacker))\n\t\t\t{\n\t\t\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DMG_FRONT, critBonus, target, null);\n\t\t\t}\n\t\t\telse if (isBehind(target, attacker))\n\t\t\t{\n\t\t\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DMG_BEHIND, critBonus, target, null);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DMG_SIDE, critBonus, target, null);\n\t\t\t}\n\n\t\t\tcritBonus = attacker.getPCriticalDamage(target, critBonus, null);\n\t\t\tcritStaticBonus = attacker.calcStat(Stats.CRITICAL_DAMAGE_ADD, critStaticBonus, target, null);\n\n\t\t\tcritBonus = target.calcStat(Stats.CRIT_VULN, critBonus, attacker, null);\n\t\t\tcritStaticBonus = target.calcStat(Stats.CRIT_ADD_VULN, critStaticBonus, attacker, null);\n\t\t}\n\n\t\tdouble positionBonus = 0.0;\n\t\tif (attacker.isBehind(target))\n\t\t{\n\t\t\tpositionBonus = 0.10; // Behind bonus\n\t\t}\n\t\telse if (!attacker.isInFrontOf(target))\n\t\t{\n\t\t\tpositionBonus = 0.05; // Side bonus\n\t\t}\n\n\t\t// Weapon random damage\n\t\tdouble weaponRandom = attacker.getRandomDamageMultiplier();\n\n\t\tdouble finalBonus = 1.0;\n\t\t// Dmg/def bonusses in PvP fight\n\t\tif (isPvP)\n\t\t{\n\t\t\tfinalBonus *= attacker.getPvPPhysicalDamage(target) / target.getPvPPhysicalDefense(attacker);\n\t\t}\n\n\t\tif (isPvE)\n\t\t{\n\t\t\tif (isBow)\n\t\t\t{\n\t\t\t\tfinalBonus *= attacker.calcStat(Stats.PVE_BOW_DMG, 1, target, null);\n\t\t\t}\n\n\t\t\tfinalBonus *= attacker.getPvEPhysicalDamage(target) / target.getPvEPhysicalDefense(attacker);\n\t\t}\n\n\t\t//Eviscerator damage multiplier\n\t\tif (attacker.calcStat(Stats.NORMAL_ATK_DMG, 1, target, null) > 1)\n\t\t{\n\t\t\tfinalBonus = attacker.calcStat(Stats.NORMAL_ATK_DMG, finalBonus, target, null);\n\n\t\t\t//Damage Up is a 1sec buff that should affects only one hit but we can do more hits in one sec so..\n\t\t\tL2Abnormal ab = attacker.getFirstEffect(30521);\n\t\t\tif (ab != null)\n\t\t\t{\n\t\t\t\tab.exit();\n\t\t\t}\n\t\t}\n\n\t\tfinalBonus *= calcElemental(attacker, target, null);\n\n\t\tif (target instanceof L2Attackable)\n\t\t{\n\t\t\tif (!target.isRaid() && !target.isRaidMinion() && target.getLevel() >= Config.MIN_NPC_LVL_DMG_PENALTY &&\n\t\t\t\t\tattacker.getActingPlayer() != null &&\n\t\t\t\t\ttarget.getLevel() - attacker.getActingPlayer().getLevel() >= 2)\n\t\t\t{\n\t\t\t\tint lvlDiff = target.getLevel() - attacker.getActingPlayer().getLevel() - 1;\n\t\t\t\tif (crit)\n\t\t\t\t{\n\t\t\t\t\tif (lvlDiff > Config.NPC_CRIT_DMG_PENALTY.size())\n\t\t\t\t\t{\n\t\t\t\t\t\tfinalBonus *= Config.NPC_CRIT_DMG_PENALTY.get(Config.NPC_CRIT_DMG_PENALTY.size());\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tfinalBonus *= Config.NPC_CRIT_DMG_PENALTY.get(lvlDiff);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tif (lvlDiff > Config.NPC_DMG_PENALTY.size())\n\t\t\t\t\t{\n\t\t\t\t\t\tfinalBonus *= Config.NPC_DMG_PENALTY.get(Config.NPC_DMG_PENALTY.size());\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tfinalBonus *= Config.NPC_DMG_PENALTY.get(lvlDiff);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (Config.isServer(Config.TENKAI) && attacker.getActingPlayer() != null)\n\t\t{\n\t\t\tif (pAtk > 150000)\n\t\t\t{\n\t\t\t\tpAtk = 150000 + Math.pow(pAtk - 150000, 0.85);\n\t\t\t}\n\t\t\tif (critBonus > 2)\n\t\t\t{\n\t\t\t\tcritBonus = 2 + Math.pow(critBonus - 2, 0.45);\n\t\t\t}\n\t\t}\n\n\t\tdouble damage = 100.0 * (weaponRandom * (pAtk * critBonus + pAtk * positionBonus) + critStaticBonus) / pDef *\n\t\t\t\tfinalBonus * ssBonus;\n\t\t//if (isBow)\n\t\t//\tdamage = (70.0 * ((pAtk + pAtk * critBonus) * weaponRandom + critStaticBonus + positionBonus * (pAtk + pAtk)) / pDef) * finalBonus;\n\n\t\t//System.out.println(pAtk + \" | \" + finalBonus\n\t\t//\t\t+ \" | \" + ssBonus + \" | \" + critBonus + \" | \" + damage);\n\n\t\tdamage = calcCustomModifier(attacker, target, damage);\n\n\t\tif (Config.isServer(Config.TENKAI))\n\t\t{\n\t\t\tif (attacker.getActingPlayer() != null)\n\t\t\t{\n\t\t\t\tPlayerClass attackerClass = attacker.getActingPlayer().getCurrentClass();\n\t\t\t\tif (attackerClass.getParent() != null && attackerClass.getParent().getAwakeningClassId() > 0)\n\t\t\t\t{\n\t\t\t\t\t//PHYS DAMAGES CAP\n\t\t\t\t\tint awakening = attackerClass.getParent().getAwakeningClassId();\n\t\t\t\t\tswitch (awakening)\n\t\t\t\t\t{\n\t\t\t\t\t\tcase 139: // Sigel Knight\n\t\t\t\t\t\t\tif (damage > 35000)\n\t\t\t\t\t\t\t\tdamage = 35000 + Math.pow(damage - 35000, 1);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 140: // Tyrr Warrior\n\t\t\t\t\t\t\tif (damage > 45000)\n\t\t\t\t\t\t\t\tdamage = 45000 + Math.pow(damage - 45000, 0.84);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 141: // Othell Rogue\n\t\t\t\t\t\t\tif (damage > 75000)\n\t\t\t\t\t\t\t\tdamage = 75000 + Math.pow(damage - 75000, 1);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 142: // Yul Archer\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tswitch (attackerClass.getId()) {\n\t\t\t\t\t\t\t\tcase 163: //Yull Moonlight Sentinel\n\t\t\t\t\t\t\t\t\tif (damage > 55000)\n\t\t\t\t\t\t\t\t\t\tdamage = 55000 + Math.pow(damage - 55000, 0.85); //.75\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\tdefault: //all other yullz\n\t\t\t\t\t\t\t\t\tif (damage > 65000)\n\t\t\t\t\t\t\t\t\t\tdamage = 65000 + Math.pow(damage - 65000, 0.85); //.75\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcase 143: // Feoh Wizard\n\t\t\t\t\t\t\tif (damage > 28000)\n\t\t\t\t\t\t\t\tdamage = 28000 + Math.pow(damage - 28000, 0.90);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 144: // Iss Enchanter\n\t\t\t\t\t\t\tif (damage > 35000)\n\t\t\t\t\t\t\t\tdamage = 35000 + Math.pow(damage - 35000, 0.93);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 145: // Wynn Summoner\n\t\t\t\t\t\t\tif (damage > 35000)\n\t\t\t\t\t\t\t\tdamage = 35000 + Math.pow(damage - 35000, 0.93);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 146: // Aeore Healer\n\t\t\t\t\t\t\tif (damage > 30000)\n\t\t\t\t\t\t\t\tdamage = 30000 + Math.pow(damage - 30000, 0.93);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\tdamage = 69;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 188: //Eviscerator\n\t\t\t\t\t\t\tif (damage > 85000)\n\t\t\t\t\t\t\t\tdamage = 85000 + Math.pow(damage - 85000, 0.20);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\n\t\t}\n\n\t\tint dmgCap = (int) target.getStat().calcStat(Stats.DAMAGE_CAP, 0, null, null);\n\t\tif (dmgCap > 0 && damage > dmgCap)\n\t\t{\n\t\t\tdamage = dmgCap;\n\t\t}\n\n\t\tif (damage > 0 && damage < 1)\n\t\t{\n\t\t\tdamage = 1;\n\t\t}\n\t\telse if (damage < 0)\n\t\t{\n\t\t\tdamage = 0;\n\t\t}\n\n\t\tif (Config.isServer(Config.TENKAI) && isPvP && damage > 30000 && pDef > 5000)\n\t\t{\n\t\t\tConnection con = null;\n\t\t\ttry\n\t\t\t{\n\t\t\t\tcon = L2DatabaseFactory.getInstance().getConnection();\n\t\t\t\tPreparedStatement statement = con.prepareStatement(\n\t\t\t\t\t\t\"INSERT INTO log_damage\" + \"(attacker, target, attackerClass, targetClass, damageType, \" +\n\t\t\t\t\t\t\t\t\"attack, defense, levelMod, power, powerBonus, critBonus, \" +\n\t\t\t\t\t\t\t\t\"critStaticBonus, positionBonus, ssBonus, finalBonus, damage)\" + \"VALUES\" +\n\t\t\t\t\t\t\t\t\"(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)\");\n\t\t\t\tstatement.setString(1, attacker.getName());\n\t\t\t\tstatement.setString(2, target.getName());\n\t\t\t\tstatement.setInt(3, attacker.getActingPlayer().getClassId());\n\t\t\t\tstatement.setInt(4, target.getActingPlayer().getClassId());\n\t\t\t\tstatement.setString(5, \"PHYSICAL\");\n\t\t\t\tstatement.setDouble(6, pAtk);\n\t\t\t\tstatement.setDouble(7, pDef);\n\t\t\t\tstatement.setDouble(8, 1);\n\t\t\t\tstatement.setDouble(9, 0);\n\t\t\t\tstatement.setDouble(10, 1);\n\t\t\t\tstatement.setDouble(11, critBonus);\n\t\t\t\tstatement.setDouble(12, critStaticBonus);\n\t\t\t\tstatement.setDouble(13, positionBonus);\n\t\t\t\tstatement.setDouble(14, ssBonus);\n\t\t\t\tstatement.setDouble(15, finalBonus);\n\t\t\t\tstatement.setDouble(16, damage);\n\t\t\t\tstatement.execute();\n\t\t\t\tstatement.close();\n\t\t\t}\n\t\t\tcatch (Exception e)\n\t\t\t{\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\tfinally\n\t\t\t{\n\t\t\t\tL2DatabaseFactory.close(con);\n\t\t\t}\n\t\t}\n\n\t\treturn damage;\n\t}", "@Override\n public int doDamage() {\n if (difficulty <5)\n return damage;\n else \n return damage*2;\n }", "public int getDamage() {\n \t\treturn damage + ((int) 0.5*level);\n \t}", "@Override\n protected int strengthViability(Creature c){\n int baseViability = super.strengthViability(c);\n if (Elements.elementDamageMultiplier(c,bossFormation.getFrontCreature().getElement()) > 1){\n baseViability = (int)(baseViability * (double)Elements.DAMAGE_BOOST * 3);\n }\n if (Elements.elementDamageMultiplier(bossFormation.getFrontCreature(),c.getElement()) > 1){\n baseViability = (int)(baseViability * (double)Elements.DAMAGE_BOOST / 3);\n }\n return baseViability;\n }", "public double mageStrike()\r\n\t{\r\n\t\tdouble r = random.nextDouble();\r\n\t\tdmg2 = dmg + ((2*pRange)/100) * (r - 0.5) * dmg;\r\n\t\tif (r < (crit/100))\r\n\t\t{\r\n\t\t\tdmg2 = 2*dmg2;\r\n\t\t\taggro = aggro * 1.4;\r\n\t\t}\r\n\t\taggro = aggro * 1.2;\r\n\t\treturn dmg2;\r\n\t}", "public static double getWeaponDamage(Item weapon, Skill attStrength) {\n/* 2348 */ if (weapon.isBodyPart() && weapon.getAuxData() != 100) {\n/* */ \n/* */ try {\n/* */ \n/* 2352 */ float f = Server.getInstance().getCreature(weapon.getOwnerId()).getCombatDamage(weapon);\n/* */ \n/* 2354 */ return (f + Server.rand.nextFloat() * f * 2.0F);\n/* */ }\n/* 2356 */ catch (NoSuchCreatureException nsc) {\n/* */ \n/* 2358 */ logger.log(Level.WARNING, \"Could not find Creature owner of weapon: \" + weapon + \" due to \" + nsc.getMessage(), (Throwable)nsc);\n/* */ \n/* */ }\n/* 2361 */ catch (NoSuchPlayerException nsp) {\n/* */ \n/* 2363 */ logger.log(Level.WARNING, \"Could not find Player owner of weapon: \" + weapon + \" due to \" + nsp.getMessage(), (Throwable)nsp);\n/* */ } \n/* */ }\n/* */ \n/* */ \n/* 2368 */ float base = 6.0F;\n/* 2369 */ if (weapon.isWeaponSword()) {\n/* */ \n/* 2371 */ base = 24.0F;\n/* */ }\n/* 2373 */ else if (weapon.isWeaponAxe()) {\n/* 2374 */ base = 30.0F;\n/* 2375 */ } else if (weapon.isWeaponPierce()) {\n/* 2376 */ base = 12.0F;\n/* 2377 */ } else if (weapon.isWeaponSlash()) {\n/* 2378 */ base = 18.0F;\n/* 2379 */ } else if (weapon.isWeaponCrush()) {\n/* 2380 */ base = 36.0F;\n/* 2381 */ } else if (weapon.isBodyPart() && weapon.getAuxData() == 100) {\n/* */ \n/* 2383 */ base = 6.0F;\n/* */ } \n/* 2385 */ if (weapon.isWood()) {\n/* 2386 */ base *= 0.1F;\n/* 2387 */ } else if (weapon.isTool()) {\n/* 2388 */ base *= 0.3F;\n/* */ } \n/* 2390 */ base = (float)(base * (1.0D + attStrength.getKnowledge(0.0D) / 100.0D));\n/* */ \n/* 2392 */ float randomizer = (50.0F + Server.rand.nextFloat() * 50.0F) / 100.0F;\n/* */ \n/* 2394 */ return base + (randomizer * base * 4.0F * weapon.getQualityLevel() * weapon.getDamagePercent()) / 10000.0D;\n/* */ }", "@Override\r\n\tpublic boolean damageEntity(DamageSource damagesource, float f2) {\n\t\tboolean toReturn = super.damageEntity(damagesource, f2);\r\n\t\tif(f2>=3 && !this.isInvulnerable(damagesource) && damagesource.getEntity()!=null && damagesource.getEntity().getBukkitEntity() instanceof Player) { // prevent things like snowball damage from triggering this ability\r\n\t\t\tif(random.nextInt(100)+1<=20) { //prevent boss from getting combo'd to hard in corner\r\n\t\t\t\tif(!teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity())) {\r\n\t\t\t\t\tteleportToEnemy();\t\t\r\n\t\t\t\t\tteleportCooldown.addCooldown((Player)damagesource.getEntity().getBukkitEntity());\r\n\t\t\t\t\tLog.info(teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity()));\r\n\t\t\t\t\tLog.info(((Player)damagesource.getEntity().getBukkitEntity()).getName());\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn toReturn;\r\n\t}", "abstract public RandomRange getPlunderRange(Unit attacker);", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "float genChance();", "public abstract int getRandomDamage();", "double getMissChance();", "public static float getDisarmorChance(ItemStack armorStack, ItemStack weapon, int level) {\n\t\tfloat chance = ((float) level * 0.05F);\n\t\tif (armorStack.getItem() instanceof ItemArmor) {\n\t\t\tItemArmor armor = (ItemArmor) armorStack.getItem();\n\t\t\tint i = armor.getArmorMaterial().getDamageReductionAmount(armor.armorType);\n\t\t\tchance += (float)(5 - i) * 0.05F;\n\t\t\ti = EnchantmentHelper.getEnchantmentLevel(Enchantments.UNBREAKING, armorStack);\n\t\t\tif (i > 0) { // -5% per level of Unbreaking\n\t\t\t\tchance -= (float) i * 0.05F;\n\t\t\t}\n\t\t}\n\t\tif (!weapon.isEmpty()) {\n\t\t\tint i = EnchantmentHelper.getEnchantmentLevel(Enchantments.SHARPNESS, weapon);\n\t\t\tif (i > 0) { // +5% per level of Sharpness\n\t\t\t\tchance += (float) i * 0.05F;\n\t\t\t}\n\t\t} else {\n\t\t\tchance -= 1.0F;\n\t\t}\n\t\treturn chance;\n\t}", "public static double evaluateSurvivability(Board b, int team) {\n Optional<Leader> ol = b.getPlayer(team).getLeader();\n if (ol.isEmpty()) {\n return 0;\n }\n Leader l = ol.get();\n if (l.health <= 0) { // if dead\n return -99999 + l.health; // u dont want to be dead\n }\n int shield = l.finalStats.get(Stat.SHIELD);\n Supplier<Stream<Minion>> attackingMinions = () -> b.getMinions(team * -1, true, true);\n // TODO add if can attack check\n // TODO factor in damage limiting effects like durandal\n int potentialDamage = attackingMinions.get()\n .filter(Minion::canAttack)\n .map(m -> m.finalStats.get(Stat.ATTACK) * (m.finalStats.get(Stat.ATTACKS_PER_TURN) - m.attacksThisTurn))\n .reduce(0, Integer::sum);\n int potentialLeaderDamage = attackingMinions.get()\n .filter(Minion::canAttack)\n .filter(Minion::attackLeaderConditions)\n .map(m -> m.finalStats.get(Stat.ATTACK) * (m.finalStats.get(Stat.ATTACKS_PER_TURN) - m.attacksThisTurn))\n .reduce(0, Integer::sum);\n int threatenDamage = attackingMinions.get()\n .filter(Minion::canAttackEventually)\n .map(m -> m.finalStats.get(Stat.ATTACK) * m.finalStats.get(Stat.ATTACKS_PER_TURN))\n .reduce(0, Integer::sum);\n int threatenLeaderDamage = attackingMinions.get()\n .filter(Minion::canAttackEventually)\n .filter(Minion::attackLeaderConditions)\n .map(m -> m.finalStats.get(Stat.ATTACK) * m.finalStats.get(Stat.ATTACKS_PER_TURN))\n .reduce(0, Integer::sum);\n int attackers = attackingMinions.get()\n .map(m -> m.finalStats.get(Stat.ATTACKS_PER_TURN))\n .reduce(0, Integer::sum);\n List<Minion> defendingMinons = b.getMinions(team, false, true)\n .filter(m -> m.finalStats.get(Stat.WARD) > 0)\n .collect(Collectors.toList());\n int leaderhp = l.health + shield;\n int ehp = defendingMinons.stream()\n .map(m -> m.health)\n .reduce(leaderhp, Integer::sum);\n long defenders = defendingMinons.size();\n if (shield > 0) {\n defenders++;\n }\n if (b.getCurrentPlayerTurn() != team) {\n threatenDamage = potentialDamage;\n threatenLeaderDamage = potentialLeaderDamage;\n }\n // if there are more defenders than attacks, then minions shouldn't be\n // able to touch face\n if (defenders >= attackers) {\n ehp = Math.max(ehp - threatenDamage, leaderhp);\n } else {\n ehp = Math.max(ehp - threatenDamage, leaderhp - threatenLeaderDamage);\n if (ehp <= 0) {\n if (team == b.getCurrentPlayerTurn()) {\n // they're threatening lethal if i dont do anything\n return -30 + ehp;\n } else {\n // they have lethal, i am ded\n return -60 + ehp;\n }\n }\n }\n return 6 * Math.log(ehp);\n }", "public int getBreedingLevel()\n\t{\n\t\tint level = (int) Math.pow(m_skillBreedExp / 1.25, 0.333333333333333333333333333);\n\t\treturn Math.min(level, 100);\n\t}", "private static int devilAttackScale(int devilAttack, int playerLevel){\r\n if(playerLevel > 4){\r\n devilAttack = devilAttack + ((2 * (playerLevel - 4)));\r\n \r\n }\r\n return devilAttack;\r\n }", "public short getSiegeWeaponDamage();", "public double getDodgeChance() {\n return Math.min((this.getAgility().getAbilityValue() / 4.0) * 0.01, 1);\n }", "public int getHerbalismLevel()\n\t{\n\t\tint level = (int) Math.pow(m_skillHerbExp, 0.3333);\n\t\tif(level <= 100)\n\t\t\treturn level;\n\t\telse\n\t\t\treturn 100;\n\t}", "@Override\n public void attackedByPaladin(double attack) {\n this.attack += (2 * attack) / 3;\n damageCounter = Math.max(damageCounter - (2 * attack) / 3, 0);\n }", "public int getCooldown() {\n \t\treturn cooldown + ((int) 0.5*level);\n \t}", "int getAttackRoll();", "@Override\n\tpublic int calculateDamage() \n\t{\n\t\t// TODO Auto-generated method stub\n\t\treturn 0;\n\t}", "public float getChance() {\n return chance;\n }", "public static double calcHpRegen(L2Character cha)\n\t{\n\t\tdouble init = cha.getTemplate().getBaseHpReg(cha.getLevel());\n\t\tdouble hpRegenMultiplier = cha.isRaid() ? Config.RAID_HP_REGEN_MULTIPLIER : Config.HP_REGEN_MULTIPLIER;\n\t\tdouble hpRegenBonus = 0;\n\n\t\tif (Config.L2JMOD_CHAMPION_ENABLE && cha.isChampion())\n\t\t{\n\t\t\thpRegenMultiplier *= Config.L2JMOD_CHAMPION_HP_REGEN;\n\t\t}\n\n\t\tif (cha instanceof L2PcInstance)\n\t\t{\n\t\t\tL2PcInstance player = (L2PcInstance) cha;\n\n\t\t\t// Calculate correct baseHpReg value for certain level of PC\n\t\t\tinit += player.getLevel() > 10 ? (player.getLevel() - 1) / 10.0 : 0.5;\n\n\t\t\tdouble siegeModifier = calcSiegeRegenModifer(player);\n\t\t\tif (siegeModifier > 0)\n\t\t\t{\n\t\t\t\thpRegenMultiplier *= siegeModifier;\n\t\t\t}\n\n\t\t\tif (player.isInsideZone(L2Character.ZONE_CLANHALL) && player.getClan() != null &&\n\t\t\t\t\tplayer.getClan().getHasHideout() > 0)\n\t\t\t{\n\t\t\t\tL2ClanHallZone zone = ZoneManager.getInstance().getZone(player, L2ClanHallZone.class);\n\t\t\t\tint posChIndex = zone == null ? -1 : zone.getClanHallId();\n\t\t\t\tint clanHallIndex = player.getClan().getHasHideout();\n\t\t\t\tif (clanHallIndex > 0 && clanHallIndex == posChIndex)\n\t\t\t\t{\n\t\t\t\t\tClanHall clansHall = ClanHallManager.getInstance().getClanHallById(clanHallIndex);\n\t\t\t\t\tif (clansHall != null)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (clansHall.getFunction(ClanHall.FUNC_RESTORE_HP) != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\thpRegenMultiplier *=\n\t\t\t\t\t\t\t\t\t1 + (double) clansHall.getFunction(ClanHall.FUNC_RESTORE_HP).getLvl() / 100;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (player.isInsideZone(L2Character.ZONE_CASTLE) && player.getClan() != null &&\n\t\t\t\t\tplayer.getClan().getHasCastle() > 0)\n\t\t\t{\n\t\t\t\tL2CastleZone zone = ZoneManager.getInstance().getZone(player, L2CastleZone.class);\n\t\t\t\tint posCastleIndex = zone == null ? -1 : zone.getCastleId();\n\t\t\t\tint castleIndex = player.getClan().getHasCastle();\n\t\t\t\tif (castleIndex > 0 && castleIndex == posCastleIndex)\n\t\t\t\t{\n\t\t\t\t\tCastle castle = CastleManager.getInstance().getCastleById(castleIndex);\n\t\t\t\t\tif (castle != null)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (castle.getFunction(Castle.FUNC_RESTORE_HP) != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\thpRegenMultiplier *= 1 + (double) castle.getFunction(Castle.FUNC_RESTORE_HP).getLvl() / 100;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (player.isInsideZone(L2Character.ZONE_FORT) && player.getClan() != null &&\n\t\t\t\t\tplayer.getClan().getHasFort() > 0)\n\t\t\t{\n\t\t\t\tL2FortZone zone = ZoneManager.getInstance().getZone(player, L2FortZone.class);\n\t\t\t\tint posFortIndex = zone == null ? -1 : zone.getFortId();\n\t\t\t\tint fortIndex = player.getClan().getHasFort();\n\t\t\t\tif (fortIndex > 0 && fortIndex == posFortIndex)\n\t\t\t\t{\n\t\t\t\t\tFort fort = FortManager.getInstance().getFortById(fortIndex);\n\t\t\t\t\tif (fort != null)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (fort.getFunction(Fort.FUNC_RESTORE_HP) != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\thpRegenMultiplier *= 1 + (double) fort.getFunction(Fort.FUNC_RESTORE_HP).getLvl() / 100;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Mother Tree effect is calculated at last\n\t\t\tif (player.isInsideZone(L2Character.ZONE_MOTHERTREE))\n\t\t\t{\n\t\t\t\tL2MotherTreeZone zone = ZoneManager.getInstance().getZone(player, L2MotherTreeZone.class);\n\t\t\t\tint hpBonus = zone == null ? 0 : zone.getHpRegenBonus();\n\t\t\t\thpRegenBonus += hpBonus;\n\t\t\t}\n\n\t\t\t// Calculate Movement bonus\n\t\t\tif (player.isSitting())\n\t\t\t{\n\t\t\t\thpRegenMultiplier *= 1.5; // Sitting\n\t\t\t}\n\t\t\telse if (!player.isMoving())\n\t\t\t{\n\t\t\t\thpRegenMultiplier *= 1.1; // Staying\n\t\t\t}\n\t\t\telse if (player.isRunning())\n\t\t\t{\n\t\t\t\thpRegenMultiplier *= 0.7; // Running\n\t\t\t}\n\n\t\t\t// Add CON bonus\n\t\t\tinit *= cha.getLevelMod() * BaseStats.CON.calcBonus(cha);\n\t\t}\n\t\telse if (cha instanceof L2PetInstance)\n\t\t{\n\t\t\tinit = ((L2PetInstance) cha).getPetLevelData().getPetRegenHP() * Config.PET_HP_REGEN_MULTIPLIER;\n\t\t}\n\n\t\tif (init < 1)\n\t\t{\n\t\t\tinit = 1;\n\t\t}\n\n\t\treturn cha.calcStat(Stats.REGENERATE_HP_RATE, init, null, null) * hpRegenMultiplier + hpRegenBonus;\n\t}", "@Override\r\n public int getSpecialValue() {\n int num = this.getCombatLevel();\r\n num += this.levelChangeAgainstCultistPlayer;\r\n \r\n return num;\r\n }", "@Override\n\tpublic int calculateCustomDamage(Entity attacker, Entity defender, int entityAttackType) {\n\t\tif (attacker.getType() == EntityType.NPC && defender.getType() == EntityType.PLAYER) {\n\t\t\tNpc attackerAsNpc = (Npc) attacker;\n\n\t\t\tPlayer defenderAsPlayer = (Player) defender;\n\n\t\t\tif (attack == AbyssalSireAttack.SWIPE) {\n\t\t\t\tif (defenderAsPlayer.prayerActive[ServerConstants.PROTECT_FROM_MELEE]) {\n\t\t\t\t\treturn ThreadLocalRandom.current().nextInt(2, 7);\n\t\t\t\t}\n\t\t\t\treturn NpcHandler.calculateNpcMeleeDamage(attackerAsNpc, defenderAsPlayer, -1, 32);\n\t\t\t} else if (attack == AbyssalSireAttack.TENDRIL_SWIPE) {\n\t\t\t\tif (defenderAsPlayer.prayerActive[ServerConstants.PROTECT_FROM_MELEE]) {\n\t\t\t\t\treturn ThreadLocalRandom.current().nextInt(0, 13);\n\t\t\t\t}\n\t\t\t\treturn NpcHandler.calculateNpcMeleeDamage(attackerAsNpc, defenderAsPlayer, -1, 40);\n\t\t\t} else if (attack == AbyssalSireAttack.DOUBLE_TENDRIL_SWIPE) {\n\t\t\t\tif (defenderAsPlayer.prayerActive[ServerConstants.PROTECT_FROM_MELEE]) {\n\t\t\t\t\treturn ThreadLocalRandom.current().nextInt(0, 26);\n\t\t\t\t}\n\t\t\t\treturn NpcHandler.calculateNpcMeleeDamage(attackerAsNpc, defenderAsPlayer, -1, 66);\n\t\t\t}\n\t\t}\n\t\treturn -1;\n\t}", "public float getHungerDamage();", "public int getPlunder(Unit attacker, Random random) {\n RandomRange range = getPlunderRange(attacker);\n return (range == null) ? 0\n : range.getAmount(\"Plunder \" + getName(), random, false);\n }", "int getDamage();", "int getDamage();", "int getDamage();", "int getDamage();", "int getDamage();", "public float getChance()\n {\n return 1.0f;\n }", "public int getDamage() {\n //TODO\n return 1;\n }", "public int attackRoll(int hitRate, int missRate, int critRate){\r\n\t\treturn (int) (Math.random() * (hitRate + critRate + missRate));\r\n\t}", "@Override\n public int damage(){\n int damage = 0;\n Random rand = new Random();\n int x = rand.nextInt(20) + 1;\n if (x == 1)\n damage = 50;\n return damage; \n }", "public double getChance() {\n return this.chance;\n }", "@Override\n public int damage() {\n int newDamage=criticalStrike();\n return newDamage;\n }", "private static int fireballDamageScale(int fireballDamage, int playerLevel){\r\n int totalDamage = 0;\r\n totalDamage = fireballDamage + (2 * playerLevel);\r\n return totalDamage;\r\n }", "public static int rollStrength(){\n num1 = (int)(Math.random()*(20-0+1)+0);\n return num1;\n }", "public double damageCalculation(Player player, NPC mob) {\r\n double weapon = player.getWeapon().getDamage();\r\n double attack = player.getStats().getAttack();\r\n double defence = mob.getStats().getDefence();\r\n double critMulti = 1;\r\n\r\n// Chance chance = new Chance(player.getLevel(), player.getStats().getDexterity(), player.getCharacterClass());\r\n Chance chance = new Chance(player.getStats().getCritChance());\r\n boolean crit = chance.getSuccess();\r\n\r\n if (crit) {\r\n critMulti = 2;\r\n System.out.println(\"CRIT!\");\r\n } else {\r\n// System.out.println(\"No crit\");\r\n }\r\n\r\n return ((weapon + attack) * 2 - defence) * critMulti;\r\n }", "public static boolean calcHitMiss(L2Character attacker, L2Character target)\n\t{\n\t\tdouble chance = 800 + 20 * (attacker.getAccuracy() - target.getEvasionRate(attacker));\n\n\t\t//if (attacker instanceof L2PcInstance && target instanceof L2PcInstance)\n\t\t//\tLog.info(\"P: \" + attacker.getAccuracy() + \" \" + target.getEvasionRate(attacker) + \": \" + chance);\n\n\t\t// Get additional bonus from the conditions when you are attacking\n\t\tchance *= hitConditionBonus.getConditionBonus(attacker, target);\n\n\t\tchance = Math.max(chance, 200);\n\t\tchance = Math.min(chance, 980);\n\n\t\tif (attacker instanceof L2PcInstance)\n\t\t{\n\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\tif (player.getExpertiseWeaponPenalty() != 0)\n\t\t\t{\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\treturn chance < Rnd.get(1000);\n\t}", "@Override\n\tpublic int calculateAttackType(Entity attacker, Entity defender) {\n\t\tif (attacker.getType() != EntityType.NPC || defender.getType() != EntityType.PLAYER) {\n\t\t\treturn ServerConstants.MELEE_ICON;\n\t\t}\n\t\tNpc attackerAsNpc = (Npc) attacker;\n\n\t\tint randomChanceOfAttack = ThreadLocalRandom.current().nextInt(0, 100);\n\n\t\tif (phase == AbyssalSirePhase.AWAKE) {\n\t\t\tif (randomChanceOfAttack <= 80 || spawns.stream().filter(n -> n != null && !n.isDead()).count() >= 2) {\n\t\t\t\tattack = AbyssalSireAttack.POISON;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.SPAWN;\n\t\t\t}\n\t\t} else if (phase == AbyssalSirePhase.MELEE_COMBAT) {\n\t\t\tif (randomChanceOfAttack <= 50) {\n\t\t\t\tattack = AbyssalSireAttack.SWIPE;\n\t\t\t} else if (randomChanceOfAttack <= 85) {\n\t\t\t\tattack = AbyssalSireAttack.TENDRIL_SWIPE;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.DOUBLE_TENDRIL_SWIPE;\n\t\t\t}\n\t\t} else if (phase == AbyssalSirePhase.MAGIC_COMBAT) {\n\t\t\tif (explosionState == AbyssalSireExplosionState.NONE && attackerAsNpc.getCurrentHitPoints() <= 139) {\n\t\t\t\tattack = AbyssalSireAttack.PORTAL;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.POISON;\n\t\t\t}\n\t\t}\n\t\treturn ServerConstants.MELEE_ICON;\n\t}", "AbilityDamage getAbilityDamage();", "@Override\n public double getDamageAmount() {\n return this.getStrength().getAbilityValue();\n }", "public int getAttackStrength(Entity var1)\n {\n return 2;\n }", "public void secondaryEffect(SeenPokemon Attacker, SeenPokemon Defender, int Damage)\r\n\t{\n\t\tif(!Defender.hasCondition())\r\n\t\t{\r\n\t\t\tint chance = genrand(1, 100);\r\n\t\t\tif(chance <= 10)\r\n\t\t\t{\r\n\t\t\t\tDefender.setCondition(5);\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public void takeDamage(int damage) {\n Random rand = new Random();\n int game = rand.nextInt(51) + 75;\n double game2 = (double) game;\n double percDamage = game2/100.0;\n double realSomething = (double) damage;\n double actualDamageNotReal = realSomething * percDamage;\n int actualDamage = (int) actualDamageNotReal;\n int actualDmg = actualDamage - this.armour;\n if (actualDmg <= 0){\n actualDmg = 0;\n }\n this.health -= actualDmg;\n slowDisplay(String.format(\"%s takes %s damage, now at %s\\n\",this.name,actualDmg,this.health));\n\n }", "public static double calcLethal(L2Character activeChar, L2Character target, int baseLethal, int magiclvl)\n\t{\n\t\tdouble chance = 0;\n\t\tif (magiclvl > 0)\n\t\t{\n\t\t\tint delta = (magiclvl + activeChar.getLevel()) / 2 - 1 - target.getLevel();\n\n\t\t\t// delta [-3,infinite)\n\t\t\tif (delta >= -3)\n\t\t\t{\n\t\t\t\tchance = baseLethal * ((double) activeChar.getLevel() / target.getLevel());\n\t\t\t}\n\t\t\t// delta [-9, -3[\n\t\t\telse if (delta < -3 && delta >= -9)\n\t\t\t{\n\t\t\t\t//\t\t\t baseLethal\n\t\t\t\t// chance = -1 * -----------\n\t\t\t\t//\t\t\t (delta / 3)\n\t\t\t\tchance = -3 * (baseLethal / delta);\n\t\t\t}\n\t\t\t//delta [-infinite,-9[\n\t\t\telse\n\t\t\t{\n\t\t\t\tchance = baseLethal / 15;\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\tchance = baseLethal * ((double) activeChar.getLevel() / target.getLevel());\n\t\t}\n\n\t\tdouble rate = 10 * activeChar.calcStat(Stats.LETHAL_RATE, chance, target, null);\n\t\tif (Config.isServer(Config.TENKAI) && rate > 2 && target instanceof L2Attackable && target.getLevel() >= 100)\n\t\t{\n\t\t\trate /= 2;\n\t\t}\n\t\treturn rate;\n\t}", "public static void damageStep () {\r\n // rough plan:\r\n // #1: flip defending monster, if face down -> see flipMonster(...);\r\n // #2: Ask CPU and player for possible effect negation! (For an attack negation it is too late!) -> see below in this method\r\n // #3: calculate damage, kill monsters, if needed\r\n // (consider also banishing and immunity, also copied passive effect of (Holy) Lance)\r\n // -> see makeDamageCalculation(...);\r\n // #4: decrease life points, if needed -> see isDealingBattleDamageAndContinuingGame(...);\r\n // #5: consider passive (also copied) trap monster effects -> see possibleSuicideEffect(...);\r\n // #6: display Win/Lose dialog and end match, if needed -> see Game.over(...);\r\n // #7: finally end the attack (consider the effects that happen afterwards), thus allowing the next attack -> endDamageStep(...);\r\n \r\n // about #1:\r\n if (Game.ActiveGuardingMonster.isFaceDown) {flipMonster(Game.ActiveGuardingMonster);}\r\n // about #2:\r\n if (Game.ActiveAttackingMonster.canBeNegated() || Game.ActiveGuardingMonster.canBeNegated()) {\r\n AIinterrupts.cpuIsUsingEffectNegateDuringBattlePhase(); // ask CPU to negate effects first\r\n // ask player to negate effect here\r\n boolean isCanceling = false;\r\n boolean hasEffectNegateHandTrap = Hand.lookForEffectNegateOnHand(true);\r\n boolean hasEffectNegateOnField = Hand.lookForEffectNegateOnField(true);\r\n if (hasEffectNegateHandTrap || hasEffectNegateOnField) {\r\n if (hasEffectNegateHandTrap && !hasEffectNegateOnField) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, true);\r\n }\r\n else if (!hasEffectNegateHandTrap && hasEffectNegateOnField) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, false);\r\n }\r\n else {\r\n int intDialogResult = YuGiOhJi.multipleChoiceDialog(\"Do you want to negate effects on the field?\", \"You can negate passive effects.\", new String[]{\"yes, by discarding Neutraliser\", \"yes, by paying the cost worth 1 card\", \"no (default)\"}, \"no (default)\");\r\n if (intDialogResult==0) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, true);\r\n }\r\n else if (intDialogResult==1) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, false);\r\n }\r\n }\r\n }\r\n if (!isCanceling) {\r\n makeDamageCalculation(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster); // whole rest of battle\r\n }\r\n }\r\n else {\r\n makeDamageCalculation(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster); // whole rest of battle\r\n }\r\n \r\n }", "public int CriticalHit(int start)\r\n {\r\n damage = ((int)(Math.random() * 100) % 50 + 80);\r\n int hp = start - damage;\r\n \r\n //modified to turn hp to 0 once it drops below or equals 0.\r\n if(hp <= 0)\r\n hp = 0;\r\n return hp;\r\n }", "public int getDef(Unit attacker, Unit defender){\r\n if(SCOP || COP)return 110;\r\n return 100;\r\n }", "public float getSpawningChance()\n {\n return 0.1F;\n }", "public int giveDamage();", "@Override\n\tprotected void calculateRewards(final L2Character lastAttacker)\n\t{\n\t\t// Creates an empty list of rewards\n\t\tfinal Map<L2Character, RewardInfoHolder> rewards = new ConcurrentHashMap<>();\n\t\t\n\t\ttry\n\t\t{\n\t\t\tif (getAggroListRP().isEmpty())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (EngineModsManager.onNpcExpSp(this, lastAttacker))\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tL2PcInstance maxDealer = null;\n\t\t\tint maxDamage = 0;\n\t\t\t\n\t\t\tint damage;\n\t\t\t\n\t\t\tL2Character attacker, ddealer;\n\t\t\t\n\t\t\t// While Interacting over This Map Removing Object is Not Allowed\n\t\t\tsynchronized (getAggroList())\n\t\t\t{\n\t\t\t\t// Go through the aggroList of the L2Attackable\n\t\t\t\tfor (final AggroInfoHolder info : getAggroListRP().values())\n\t\t\t\t{\n\t\t\t\t\tif (info == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Get the L2Character corresponding to this attacker\n\t\t\t\t\tattacker = info.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Get damages done by this attacker\n\t\t\t\t\tdamage = info.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// Prevent unwanted behavior\n\t\t\t\t\tif (damage > 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (attacker instanceof L2SummonInstance || attacker instanceof L2PetInstance && ((L2PetInstance) attacker).getPetData().getOwnerExpTaken() > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = info.getAttacker();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check if ddealer isn't too far from this (killed monster)\n\t\t\t\t\t\tif (!Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, ddealer, true))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate real damages (Summoners should get own damage plus summon's damage)\n\t\t\t\t\t\tRewardInfoHolder reward = rewards.get(ddealer);\n\t\t\t\t\t\tif (reward == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward = new RewardInfoHolder(ddealer, damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward.addDamage(damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\trewards.put(ddealer, reward);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (ddealer instanceof L2PlayableInstance && ((L2PlayableInstance) ddealer).getActingPlayer() != null && reward.getDmg() > maxDamage)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tmaxDealer = ((L2PlayableInstance) ddealer).getActingPlayer();\n\t\t\t\t\t\t\tmaxDamage = reward.getDmg();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// Manage Base, Quests and Sweep drops of the L2Attackable\n\t\t\tdoItemDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\t// Manage drop of Special Events created by GM for a defined period\n\t\t\tdoEventDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\tif (!getMustRewardExpSP())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (!rewards.isEmpty())\n\t\t\t{\n\t\t\t\tL2Party attackerParty;\n\t\t\t\tlong exp;\n\t\t\t\tint levelDiff, partyDmg, partyLvl, sp;\n\t\t\t\tfloat partyMul, penalty;\n\t\t\t\tRewardInfoHolder reward2;\n\t\t\t\tint[] tmp;\n\t\t\t\t\n\t\t\t\tfor (final RewardInfoHolder reward : rewards.values())\n\t\t\t\t{\n\t\t\t\t\tif (reward == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Penalty applied to the attacker's XP\n\t\t\t\t\tpenalty = 0;\n\t\t\t\t\t\n\t\t\t\t\t// Attacker to be rewarded\n\t\t\t\t\tattacker = reward.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Total amount of damage done\n\t\t\t\t\tdamage = reward.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// If the attacker is a Pet, get the party of the owner\n\t\t\t\t\tif (attacker instanceof L2PetInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PetInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse if (attacker instanceof L2PcInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PcInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If this attacker is a L2PcInstance with a summoned L2SummonInstance, get Exp Penalty applied for the current summoned L2SummonInstance\n\t\t\t\t\tif (attacker instanceof L2PcInstance && ((L2PcInstance) attacker).getPet() instanceof L2SummonInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tpenalty = ((L2SummonInstance) ((L2PcInstance) attacker).getPet()).getExpPenalty();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// We must avoid \"over damage\", if any\n\t\t\t\t\tif (damage > getMaxHp())\n\t\t\t\t\t{\n\t\t\t\t\t\tdamage = getMaxHp();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If there's NO party in progress\n\t\t\t\t\tif (attackerParty == null)\n\t\t\t\t\t{\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\tif (attacker.getKnownList().knowsObject(this))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// Calculate the difference of level between this attacker (L2PcInstance or L2SummonInstance owner) and the L2Attackable\n\t\t\t\t\t\t\t// mob = 24, atk = 10, diff = -14 (full xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 28, diff = 4 (some xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 50, diff = 26 (no xp)\n\t\t\t\t\t\t\tlevelDiff = attacker.getLevel() - getLevel();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, damage);\n\t\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\t\texp *= 1 - penalty;\n\t\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Check for an over-hit enabled strike and VIP options\n\t\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif (player.isVIP())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\texp = (long) (exp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t\tsp = (int) (sp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Distribute the Exp and SP between the L2PcInstance and its L2Summon\n\t\t\t\t\t\t\tif (!attacker.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tattacker.addExpAndSp(Math.round(attacker.calcStat(Stats.EXPSP_RATE, exp, null, null)), (int) attacker.calcStat(Stats.EXPSP_RATE, sp, null, null));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t// share with party members\n\t\t\t\t\t\tpartyDmg = 0;\n\t\t\t\t\t\tpartyMul = 1.f;\n\t\t\t\t\t\tpartyLvl = 0;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Get all L2Character that can be rewarded in the party\n\t\t\t\t\t\tfinal List<L2PlayableInstance> rewardedMembers = new ArrayList<>();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Go through all L2PcInstance in the party\n\t\t\t\t\t\tList<L2PcInstance> groupMembers;\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getCommandChannel().getMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getPartyMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tfor (final L2PcInstance pl : groupMembers)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (pl == null || pl.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Get the RewardInfo of this L2PcInstance from L2Attackable rewards\n\t\t\t\t\t\t\treward2 = rewards.get(pl);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// If the L2PcInstance is in the L2Attackable rewards add its damages to party damages\n\t\t\t\t\t\t\tif (reward2 != null)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add L2PcInstance damages to party damages\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\trewards.remove(pl); // Remove the L2PcInstance from the L2Attackable rewards\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t// Add L2PcInstance of the party (that have attacked or not) to members that can be rewarded\n\t\t\t\t\t\t\t\t// and in range of the monster.\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfinal L2PlayableInstance summon = pl.getPet();\n\t\t\t\t\t\t\tif (summon != null && summon instanceof L2PetInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\treward2 = rewards.get(summon);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (reward2 != null) // Pets are only added if they have done damage\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, summon, true))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add summon damages to party damages\n\t\t\t\t\t\t\t\t\t\trewardedMembers.add(summon);\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tif (summon.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = summon.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\trewards.remove(summon); // Remove the summon from the L2Attackable rewards\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// If the party didn't killed this L2Attackable alone\n\t\t\t\t\t\tif (partyDmg < getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyMul = (float) partyDmg / (float) getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Avoid \"over damage\"\n\t\t\t\t\t\tif (partyDmg > getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyDmg = getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate the level difference between Party and L2Attackable\n\t\t\t\t\t\tlevelDiff = partyLvl - getLevel();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, partyDmg);\n\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\texp *= partyMul;\n\t\t\t\t\t\tsp *= partyMul;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check for an over-hit enabled strike\n\t\t\t\t\t\t// (When in party, the over-hit exp bonus is given to the whole party and splitted proportionally through the party members)\n\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Distribute Experience and SP rewards to L2PcInstance Party members in the known area of the last attacker\n\t\t\t\t\t\tif (partyDmg > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tattackerParty.distributeXpAndSp(exp, sp, rewardedMembers, partyLvl);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t}", "public int rollAttack()\n {\n Random random2 = new Random();\n int atk = random2.nextInt(20) +1 + attackBonus;\n return atk;\n }", "public int attack(Character target){ //hw3E#0 //hw46#moreThinking\n lowerHP((int)(strength * attack / 10)); //hw3E#0 //hw46#moreThinking\n return super.attack(target); //hw3E#0 //hw44#3,4 //hw46#moreThinking\n }", "private double enemyKills()\n {\n return (double)enemyResult.shipsLost();\n }", "@Override\n protected void initializeLevelSpecificChances()\n {\n shopRoomChance = 0.05F;\n restRoomChance = 0.12F;\n treasureRoomChance = 0.0F;\n eventRoomChance = 0.22F;\n eliteRoomChance = 0.08F;\n\n smallChestChance = 50;\n mediumChestChance = 33;\n largeChestChance = 17;\n\n commonRelicChance = 50;\n uncommonRelicChance = 33;\n rareRelicChance = 17;\n\n colorlessRareChance = 0.3F;\n if (AbstractDungeon.ascensionLevel >= 12) {\n cardUpgradedChance = 0.125F;\n } else {\n cardUpgradedChance = 0.25F;\n }\n }", "@Override\n public void attackedByShaman(double attack) {\n damageCounter += (2 * attack) / 3;\n this.attack = Math.max(this.attack - (2 * attack) / 3, 0);\n }", "public int CriticalHitCheck(int creatureSkill){\n \tcriticalChance = genRandom.nextInt(100);\n \tif(criticalChance <= creatureSkill){\n \t\tLog.write(\"A CRITICAL HIT!\");\n \t\treturn 2;\n \t}\n \treturn 1;\n }", "double getDeathFactor();", "public int getManaIncreasePerLevel() {\r\n if (_index == 3 || _index == 11 || _index == 6 || _index == 14) {\r\n // Acolytes, High Priests, Druids, or High Druids\r\n return 1;\r\n } else if (isSpellCaster()) {\r\n return 2;\r\n }\r\n return 0;\r\n }", "int getSuperEffectiveChargeAttacksUsed();", "@Override\n\tpublic boolean doDie(final L2Character killer)\n\t{\n\t\t// Kill the L2NpcInstance (the corpse disappeared after 7 seconds)\n\t\tif (!super.doDie(killer))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\t// Enhance soul crystals of the attacker if this L2Attackable had its soul absorbed\n\t\ttry\n\t\t{\n\t\t\tif (killer instanceof L2PcInstance)\n\t\t\t{\n\t\t\t\tlevelSoulCrystals(killer);\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t\t\n\t\t// Notify the Quest Engine of the L2Attackable death if necessary\n\t\ttry\n\t\t{\n\t\t\tif (killer instanceof L2PcInstance || killer instanceof L2Summon)\n\t\t\t{\n\t\t\t\tfinal L2PcInstance player = killer instanceof L2PcInstance ? (L2PcInstance) killer : ((L2Summon) killer).getOwner();\n\t\t\t\t\n\t\t\t\tEngineModsManager.onKill(killer, this, killer instanceof L2Summon);\n\t\t\t\t\n\t\t\t\t// only 1 randomly choosen quest of all quests registered to this character can be applied\n\t\t\t\tfor (final Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_KILL))\n\t\t\t\t{\n\t\t\t\t\tquest.notifyKill(this, player, killer instanceof L2Summon);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t\t\n\t\tsetChampion(false);\n\t\tif (Config.L2JMOD_CHAMPION_ENABLE && Config.L2JMOD_CHAMPION_FREQUENCY > 0)\n\t\t{\n\t\t\t// Set champion on next spawn\n\t\t\tif (this.getClass().getSimpleName().equalsIgnoreCase(\"L2MonsterInstance\") && getLevel() >= Config.L2JMOD_CHAMP_MIN_LVL && getLevel() <= Config.L2JMOD_CHAMP_MAX_LVL)\n\t\t\t{\n\t\t\t\tint random = ThreadLocalRandom.current().nextInt(100);\n\t\t\t\tif (random < Config.L2JMOD_CHAMPION_FREQUENCY)\n\t\t\t\t{\n\t\t\t\t\tsetChampion(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn true;\n\t}", "@Override\n public int finalScore() {\n if (isBust()) {\n return 0;\n }\n if (isBlackjack()) {\n return 22;\n }\n return higherScore();\n }", "public static void spawnEnemy(){\n RNG.D100();\n if(PlayerStats.LVL <= 2){\n if(RNG.num <= 90){\n enemy = \"imp\";\n }else{\n enemy = \"IMP LORD\";\n }\n }else if(PlayerStats.LVL > 2 && PlayerStats.LVL <= 3){\n if(RNG.num <= 20){\n enemy = \"imp\";\n }else if(RNG.num > 20 && RNG.num <= 90){\n enemy = \"toadman\";\n }else{\n enemy = \"IMP LORD\";\n }\n }else if(PlayerStats.LVL > 3 && PlayerStats.LVL <= 5){\n if(RNG.num <= 10){\n enemy = \"toadman\";\n }else if(RNG.num > 10 && RNG.num <= 90){\n enemy = \"giant spider\";\n }else{\n enemy = \"BROODMOTHER\";\n }\n }else if (PlayerStats.LVL > 5 && PlayerStats.LVL <= 8){\n if(RNG.num <= 30){\n enemy = \"goblin sorceror\";\n }else if(RNG.num > 30 && RNG.num <= 60){\n enemy = \"goblin warrior\";\n }else if(RNG.num >60 && RNG.num <= 90){\n enemy = \"goblin archer\";\n }else if(RNG.num > 90 && RNG.num <= 100){\n enemy = \"GOBLIN CHIEFTAN\"; \n }\n } \n }", "private void checkForPlayerChance()\n\t\t\t{\n\t\t\t\tf = false;\n\t\t\t\tfor (j = 0; j < 8; ++j)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (win[j] == 2 && lose[j] == 0)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tf = true;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t}\n\t\t\t\tif (f == false)\n\t\t\t\t\tj = 10;\n\n\t\t\t}", "public void attack(String spell, character opponent){\n Random rand = new Random();\n int prob;\n String attack;\n \n prob = rand.nextInt(2); //we need two random numbers to allow us to use the two attacks:\n if(prob==0){\n attack = \"punch\";\n opponent.setHealth(opponent.getHealth() - 10);\n System.out.println(getName() + \" has landed \" + attack);\n System.out.println(opponent.getName() + \" health now \" + opponent.getHealth());\n }\n \n else if(prob==1){\n attack = \"kick\";\n opponent.setHealth(opponent.getHealth() - 15);\n System.out.println(getName() + \" has landed \" + attack);\n System.out.println(opponent.getName() + \" health now \" + opponent.getHealth());\n }\n \n \n }", "@Override\n\tpublic float desireability() {\n\t\tAgentSpace agentSpace = Blackboard.inst().getSpace(AgentSpace.class, _obj.getName());\n\t\tMap<String,FoodEntry> map = agentSpace.getScentMemories().getFirst();\n\t\tif (map == null || map.size() == 0) { \n\t\t\t// we don't smell anything\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tAgentSpace space = Blackboard.inst().getSpace(AgentSpace.class, _obj.getName());\n\t\tBoundedEntry bounded = space.getBounded(Variable.energy);\n\t\tfloat pct = bounded.getValue() / bounded.getMax();\n\t\treturn 1 - (pct*pct);\n\t}", "public int getWeaponDamage() {\n return Math.round(type.getWeaponDamage()*type.getItemLevelMultipliers()\n\t\t\t\t[level - 1]);\n }", "@Override\n public int viability() {\n int[] newStats = getNewStats();\n return newStats[0] * newStats[1];\n }", "public int fight() {\r\n\t\treturn -this.randomObject.nextInt(50);\r\n\t}", "public static void handleEffectChances() {\n for (int i=0 ; i<5 ; i++) {\n effectChances.set(i, effectChances.get(i)+((int) Math.ceil(((double)stageCount)/5))*2);\n }\n }", "static public int getHobgoblinArmor(){\n armor = rand.nextInt(4) + 2;\n return armor;\n }", "@java.lang.Override\n public int getMinigameDefenseChancesLeft() {\n return minigameDefenseChancesLeft_;\n }", "private int heavyAttack() {\n return attack(6, 2);\n }", "private void GenerateHealth(){\t\t\n\t\t\n\t\t//Update for the health powerup\n\t\tint randGen = rand.nextInt((int)((float)HEALTH_FREQUENCY * RANDOM_DEVIATION));\n\t\trandGen = (rand.nextBoolean()) ?-randGen :randGen;\n\t\t\n\t\t//D.BUG(\"RandGen is: \" + String.valueOf(randGen));\n\t\t\n\t\tif(timeSinceLastSpawns.get(CollectibleType.Health.ordinal()).intValue() > (HEALTH_FREQUENCY + randGen)){\n\t\t\t\n\t\t\t//D.BUG(\"We have Spawned another health collectible after \" + String.valueOf(randGen + HEALTH_FREQUENCY) + \" milliseconds!\");\n\t\t\ttimeSinceLastSpawns.set(CollectibleType.Health.ordinal(), 0);\n\t\t\t\n\t\t\t//SPAWN HEALTH COLLECTIBLE HERE\n\t\t}\n\t}", "private static int devilGoldScale(int devilGold, int playerLevel){\r\n if(playerLevel > 4){\r\n devilGold = devilGold + ( 1* playerLevel);\r\n return devilGold;\r\n }else{\r\n return devilGold;\r\n }\r\n }", "public short getHandThrowDamage();" ]
[ "0.6382537", "0.63050455", "0.63035935", "0.6296359", "0.6289845", "0.62338114", "0.6221537", "0.6187683", "0.61292464", "0.6127409", "0.6105961", "0.61034566", "0.6100671", "0.607481", "0.6074772", "0.60527086", "0.6045608", "0.6032061", "0.60280037", "0.60207665", "0.60129625", "0.5990683", "0.5987622", "0.59648687", "0.5958716", "0.5956496", "0.5951801", "0.59342086", "0.5933332", "0.5907879", "0.5904647", "0.58929753", "0.58517045", "0.5844166", "0.5844087", "0.58395815", "0.5829737", "0.580956", "0.5805578", "0.5797845", "0.57933253", "0.5783589", "0.5774377", "0.5765685", "0.5763213", "0.5747691", "0.5734902", "0.5726052", "0.5726052", "0.5726052", "0.5726052", "0.5726052", "0.57204896", "0.57192737", "0.5717006", "0.57100445", "0.5683687", "0.5676224", "0.5670419", "0.5667062", "0.5665893", "0.56557727", "0.56495965", "0.5642465", "0.56265396", "0.5618285", "0.56081194", "0.55991423", "0.55908626", "0.5589787", "0.5589421", "0.5578067", "0.5569559", "0.5557449", "0.55445826", "0.55353856", "0.5535042", "0.55307716", "0.5520991", "0.55185014", "0.55152464", "0.5514491", "0.55129653", "0.55106163", "0.5508131", "0.5502686", "0.55018854", "0.5501453", "0.55001205", "0.5498573", "0.5484807", "0.54793507", "0.5479102", "0.5475514", "0.54637575", "0.5459988", "0.5458059", "0.54571694", "0.54535955", "0.5450624" ]
0.728483
0
Calculate the Experience and SP to distribute to attacker (L2PcInstance, L2SummonInstance or L2Party) of the L2Attackable.
private int[] calculateExpAndSp(int diff, final int damage) { double xp; double sp; if (diff < -5) { diff = -5; // makes possible to use ALT_GAME_EXPONENT configuration } xp = (double) getExpReward() * damage / getMaxHp(); if (Config.ALT_GAME_EXPONENT_XP != 0) { xp *= Math.pow(2., -diff / Config.ALT_GAME_EXPONENT_XP); } sp = (double) getSpReward() * damage / getMaxHp(); if (Config.ALT_GAME_EXPONENT_SP != 0) { sp *= Math.pow(2., -diff / Config.ALT_GAME_EXPONENT_SP); } if (Config.ALT_GAME_EXPONENT_XP == 0 && Config.ALT_GAME_EXPONENT_SP == 0) { if (diff > 5) // formula revised May 07 { final double pow = Math.pow((double) 5 / 6, diff - 5); xp = xp * pow; sp = sp * pow; } if (xp <= 0) { xp = 0; sp = 0; } else if (sp <= 0) { sp = 0; } } final int[] tmp = { (int) xp, (int) sp }; return tmp; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tprotected void calculateRewards(final L2Character lastAttacker)\n\t{\n\t\t// Creates an empty list of rewards\n\t\tfinal Map<L2Character, RewardInfoHolder> rewards = new ConcurrentHashMap<>();\n\t\t\n\t\ttry\n\t\t{\n\t\t\tif (getAggroListRP().isEmpty())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (EngineModsManager.onNpcExpSp(this, lastAttacker))\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tL2PcInstance maxDealer = null;\n\t\t\tint maxDamage = 0;\n\t\t\t\n\t\t\tint damage;\n\t\t\t\n\t\t\tL2Character attacker, ddealer;\n\t\t\t\n\t\t\t// While Interacting over This Map Removing Object is Not Allowed\n\t\t\tsynchronized (getAggroList())\n\t\t\t{\n\t\t\t\t// Go through the aggroList of the L2Attackable\n\t\t\t\tfor (final AggroInfoHolder info : getAggroListRP().values())\n\t\t\t\t{\n\t\t\t\t\tif (info == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Get the L2Character corresponding to this attacker\n\t\t\t\t\tattacker = info.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Get damages done by this attacker\n\t\t\t\t\tdamage = info.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// Prevent unwanted behavior\n\t\t\t\t\tif (damage > 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (attacker instanceof L2SummonInstance || attacker instanceof L2PetInstance && ((L2PetInstance) attacker).getPetData().getOwnerExpTaken() > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tddealer = info.getAttacker();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check if ddealer isn't too far from this (killed monster)\n\t\t\t\t\t\tif (!Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, ddealer, true))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate real damages (Summoners should get own damage plus summon's damage)\n\t\t\t\t\t\tRewardInfoHolder reward = rewards.get(ddealer);\n\t\t\t\t\t\tif (reward == null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward = new RewardInfoHolder(ddealer, damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treward.addDamage(damage);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\trewards.put(ddealer, reward);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (ddealer instanceof L2PlayableInstance && ((L2PlayableInstance) ddealer).getActingPlayer() != null && reward.getDmg() > maxDamage)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tmaxDealer = ((L2PlayableInstance) ddealer).getActingPlayer();\n\t\t\t\t\t\t\tmaxDamage = reward.getDmg();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// Manage Base, Quests and Sweep drops of the L2Attackable\n\t\t\tdoItemDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\t// Manage drop of Special Events created by GM for a defined period\n\t\t\tdoEventDrop(maxDealer != null && maxDealer.isOnline() ? maxDealer : lastAttacker);\n\t\t\t\n\t\t\tif (!getMustRewardExpSP())\n\t\t\t{\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\tif (!rewards.isEmpty())\n\t\t\t{\n\t\t\t\tL2Party attackerParty;\n\t\t\t\tlong exp;\n\t\t\t\tint levelDiff, partyDmg, partyLvl, sp;\n\t\t\t\tfloat partyMul, penalty;\n\t\t\t\tRewardInfoHolder reward2;\n\t\t\t\tint[] tmp;\n\t\t\t\t\n\t\t\t\tfor (final RewardInfoHolder reward : rewards.values())\n\t\t\t\t{\n\t\t\t\t\tif (reward == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Penalty applied to the attacker's XP\n\t\t\t\t\tpenalty = 0;\n\t\t\t\t\t\n\t\t\t\t\t// Attacker to be rewarded\n\t\t\t\t\tattacker = reward.getAttacker();\n\t\t\t\t\t\n\t\t\t\t\t// Total amount of damage done\n\t\t\t\t\tdamage = reward.getDmg();\n\t\t\t\t\t\n\t\t\t\t\t// If the attacker is a Pet, get the party of the owner\n\t\t\t\t\tif (attacker instanceof L2PetInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PetInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse if (attacker instanceof L2PcInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tattackerParty = ((L2PcInstance) attacker).getParty();\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If this attacker is a L2PcInstance with a summoned L2SummonInstance, get Exp Penalty applied for the current summoned L2SummonInstance\n\t\t\t\t\tif (attacker instanceof L2PcInstance && ((L2PcInstance) attacker).getPet() instanceof L2SummonInstance)\n\t\t\t\t\t{\n\t\t\t\t\t\tpenalty = ((L2SummonInstance) ((L2PcInstance) attacker).getPet()).getExpPenalty();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// We must avoid \"over damage\", if any\n\t\t\t\t\tif (damage > getMaxHp())\n\t\t\t\t\t{\n\t\t\t\t\t\tdamage = getMaxHp();\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// If there's NO party in progress\n\t\t\t\t\tif (attackerParty == null)\n\t\t\t\t\t{\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\tif (attacker.getKnownList().knowsObject(this))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// Calculate the difference of level between this attacker (L2PcInstance or L2SummonInstance owner) and the L2Attackable\n\t\t\t\t\t\t\t// mob = 24, atk = 10, diff = -14 (full xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 28, diff = 4 (some xp)\n\t\t\t\t\t\t\t// mob = 24, atk = 50, diff = 26 (no xp)\n\t\t\t\t\t\t\tlevelDiff = attacker.getLevel() - getLevel();\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, damage);\n\t\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\t\texp *= 1 - penalty;\n\t\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Check for an over-hit enabled strike and VIP options\n\t\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif (player.isVIP())\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\texp = (long) (exp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t\tsp = (int) (sp * Config.VIP_XPSP_RATE);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Distribute the Exp and SP between the L2PcInstance and its L2Summon\n\t\t\t\t\t\t\tif (!attacker.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tattacker.addExpAndSp(Math.round(attacker.calcStat(Stats.EXPSP_RATE, exp, null, null)), (int) attacker.calcStat(Stats.EXPSP_RATE, sp, null, null));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t// share with party members\n\t\t\t\t\t\tpartyDmg = 0;\n\t\t\t\t\t\tpartyMul = 1.f;\n\t\t\t\t\t\tpartyLvl = 0;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Get all L2Character that can be rewarded in the party\n\t\t\t\t\t\tfinal List<L2PlayableInstance> rewardedMembers = new ArrayList<>();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Go through all L2PcInstance in the party\n\t\t\t\t\t\tList<L2PcInstance> groupMembers;\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getCommandChannel().getMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tgroupMembers = attackerParty.getPartyMembers();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tfor (final L2PcInstance pl : groupMembers)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (pl == null || pl.isDead())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// Get the RewardInfo of this L2PcInstance from L2Attackable rewards\n\t\t\t\t\t\t\treward2 = rewards.get(pl);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// If the L2PcInstance is in the L2Attackable rewards add its damages to party damages\n\t\t\t\t\t\t\tif (reward2 != null)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add L2PcInstance damages to party damages\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\trewards.remove(pl); // Remove the L2PcInstance from the L2Attackable rewards\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t// Add L2PcInstance of the party (that have attacked or not) to members that can be rewarded\n\t\t\t\t\t\t\t\t// and in range of the monster.\n\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, pl, true))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\trewardedMembers.add(pl);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif (pl.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tif (attackerParty.isInCommandChannel())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = attackerParty.getCommandChannel().getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = pl.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfinal L2PlayableInstance summon = pl.getPet();\n\t\t\t\t\t\t\tif (summon != null && summon instanceof L2PetInstance)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\treward2 = rewards.get(summon);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (reward2 != null) // Pets are only added if they have done damage\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif (Util.checkIfInRange(Config.ALT_PARTY_RANGE, this, summon, true))\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tpartyDmg += reward2.getDmg(); // Add summon damages to party damages\n\t\t\t\t\t\t\t\t\t\trewardedMembers.add(summon);\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tif (summon.getLevel() > partyLvl)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tpartyLvl = summon.getLevel();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\trewards.remove(summon); // Remove the summon from the L2Attackable rewards\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// If the party didn't killed this L2Attackable alone\n\t\t\t\t\t\tif (partyDmg < getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyMul = (float) partyDmg / (float) getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Avoid \"over damage\"\n\t\t\t\t\t\tif (partyDmg > getMaxHp())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tpartyDmg = getMaxHp();\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate the level difference between Party and L2Attackable\n\t\t\t\t\t\tlevelDiff = partyLvl - getLevel();\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Calculate Exp and SP rewards\n\t\t\t\t\t\ttmp = calculateExpAndSp(levelDiff, partyDmg);\n\t\t\t\t\t\texp = tmp[0];\n\t\t\t\t\t\tsp = tmp[1];\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (Config.L2JMOD_CHAMPION_ENABLE && isChampion())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\texp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t\tsp *= Config.L2JMOD_CHAMPION_REWARDS;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\texp *= partyMul;\n\t\t\t\t\t\tsp *= partyMul;\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Check for an over-hit enabled strike\n\t\t\t\t\t\t// (When in party, the over-hit exp bonus is given to the whole party and splitted proportionally through the party members)\n\t\t\t\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfinal L2PcInstance player = (L2PcInstance) attacker;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (isOverhit() && attacker == getOverhitAttacker())\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tplayer.sendPacket(new SystemMessage(SystemMessageId.OVER_HIT));\n\t\t\t\t\t\t\t\texp += calculateOverhitExp(exp);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// Distribute Experience and SP rewards to L2PcInstance Party members in the known area of the last attacker\n\t\t\t\t\t\tif (partyDmg > 0)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tattackerParty.distributeXpAndSp(exp, sp, rewardedMembers, partyLvl);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t}", "public static int getEnemyLives(){\n return 1 + currentLvl * 2;\n\n }", "public abstract double experience();", "AbilityDamage getAbilityDamage();", "@Override\n\t\tpublic void calc(Env env)\n\t\t{\n\t\t\tL2PcInstance pc = (L2PcInstance) env.player;\n\t\t\tif (pc != null)\n\t\t\t{\n\t\t\t\tenv.value += pc.getHennaStatDEX();\n\t\t\t}\n\t\t}", "protected int getExperiencePoints(EntityPlayer player)\n {\n return super.getExperiencePoints(player);\n }", "public int computeDamageTo(Combatant opponent) { return 0; }", "@Override\n protected int getBonusPoints() {\n return leadership + experience;\n }", "public int calculateAttack() {\n int attack = 0;\n for (Weapon w : equippedWeapons) {\n attack += w.getType().getDamage();\n }\n return attack;\n }", "public static double calcPhysSkillDam(L2Character attacker, L2Character target, L2Skill skill, byte shld, boolean crit, boolean dual, double ssBonus)\n\t{\n\t\tfinal boolean isPvP = attacker instanceof L2Playable && target instanceof L2Playable;\n\t\tfinal boolean isPvE = attacker instanceof L2Playable && target instanceof L2Attackable ||\n\t\t\t\tattacker instanceof L2Attackable && target instanceof L2Playable;\n\n\t\tdouble pAtk = attacker.getPAtk(target);\n\t\tdouble levelMod = attacker.getLevelMod();\n\t\tdouble pDef = target.getPDef(attacker);\n\n\t\tpAtk += calcValakasAttribute(attacker, target, skill);\n\n\t\tif (attacker instanceof L2Npc)\n\t\t{\n\t\t\tif (((L2Npc) attacker)._soulshotcharged)\n\t\t\t{\n\t\t\t\tssBonus = L2ItemInstance.CHARGED_SOULSHOT;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tssBonus = L2ItemInstance.CHARGED_NONE;\n\t\t\t}\n\n\t\t\t((L2Npc) attacker)._soulshotcharged = false;\n\t\t}\n\n\t\tswitch (shld)\n\t\t{\n\t\t\tcase SHIELD_DEFENSE_SUCCEED:\n\t\t\t\tpDef += target.getShldDef();\n\t\t\t\tbreak;\n\t\t\tcase SHIELD_DEFENSE_PERFECT_BLOCK: // perfect block\n\t\t\t\treturn 1.;\n\t\t}\n\n\t\tif (skill.getIgnoredDefPercent() > 0)\n\t\t{\n\t\t\tpDef -= pDef * skill.getIgnoredDefPercent() / 100;\n\t\t}\n\n\t\tdouble power = skill.getPower(attacker, target, isPvP, isPvE);\n\t\tdouble powerBonus = 1.0;\n\t\tif (skill.getMaxChargeConsume() > 0)\n\t\t{\n\t\t\tif (attacker instanceof L2PcInstance)\n\t\t\t{\n\t\t\t\tint consume = Math.min(((L2PcInstance) attacker).getCharges(), skill.getMaxChargeConsume());\n\t\t\t\tfor (int i = 0; i < consume; i++)\n\t\t\t\t{\n\t\t\t\t\tpowerBonus += 0.1;\n\t\t\t\t}\n\n\t\t\t\t((L2PcInstance) attacker).decreaseCharges(consume);\n\t\t\t}\n\t\t\tpowerBonus = attacker.calcStat(Stats.MOMENTUM_POWER, powerBonus, attacker, skill);\n\t\t}\n\n\t\tif (skill.getId() == 10265 || skill.getId() == 10288) //Eruption, Hurricane Storm\n\t\t{\n\t\t\tL2Weapon attackerWeapon = attacker.getActiveWeaponItem();\n\t\t\tif (attackerWeapon != null)\n\t\t\t{\n\t\t\t\t//Power - 10% when using a sword, dualsword, blunt, or fist weapon. Power + 50% when using a spear.\n\t\t\t\tif (attackerWeapon.getItemType() == L2WeaponType.SWORD ||\n\t\t\t\t\t\tattackerWeapon.getItemType() == L2WeaponType.BIGSWORD ||\n\t\t\t\t\t\tattackerWeapon.getItemType() == L2WeaponType.DUAL ||\n\t\t\t\t\t\tattackerWeapon.getItemType() == L2WeaponType.FIST ||\n\t\t\t\t\t\tattackerWeapon.getItemType() == L2WeaponType.BLUNT ||\n\t\t\t\t\t\tattackerWeapon.getItemType() == L2WeaponType.DUALBLUNT ||\n\t\t\t\t\t\tattackerWeapon.getItemType() == L2WeaponType.BIGBLUNT)\n\t\t\t\t{\n\t\t\t\t\tpowerBonus *= 0.90;\n\t\t\t\t}\n\t\t\t\telse if (attackerWeapon.getItemType() == L2WeaponType.POLE)\n\t\t\t\t{\n\t\t\t\t\tpowerBonus *= 1.50;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// defence modifier depending of the attacker weapon\n\t\tL2Weapon weapon = attacker.getActiveWeaponItem();\n\t\tStats weaponStat = null;\n\t\tboolean isBow = false;\n\t\tboolean isDual = false;\n\t\tif (weapon != null && !attacker.isTransformed())\n\t\t{\n\t\t\tswitch (weapon.getItemType())\n\t\t\t{\n\t\t\t\tcase BOW:\n\t\t\t\t\tisBow = true;\n\t\t\t\t\tweaponStat = Stats.BOW_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase CROSSBOW:\n\t\t\t\tcase CROSSBOWK:\n\t\t\t\t\tisBow = true;\n\t\t\t\t\tweaponStat = Stats.CROSSBOW_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase BLUNT:\n\t\t\t\t\tweaponStat = Stats.BLUNT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUALBLUNT:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.BLUNT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DAGGER:\n\t\t\t\t\tweaponStat = Stats.DAGGER_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUAL:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.DUAL_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUALFIST:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.DUALFIST_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase ETC:\n\t\t\t\t\tweaponStat = Stats.ETC_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase FIST:\n\t\t\t\t\tweaponStat = Stats.FIST_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase POLE:\n\t\t\t\t\tweaponStat = Stats.POLE_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase SWORD:\n\t\t\t\t\tweaponStat = Stats.SWORD_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase BIGSWORD:\n\t\t\t\t\tweaponStat = Stats.BIGSWORD_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase BIGBLUNT:\n\t\t\t\t\tweaponStat = Stats.BIGBLUNT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUALDAGGER:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.DUALDAGGER_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase RAPIER:\n\t\t\t\t\tweaponStat = Stats.RAPIER_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase ANCIENTSWORD:\n\t\t\t\t\tweaponStat = Stats.ANCIENT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tif (isDual && ssBonus >= 2.0)\n\t\t{\n\t\t\tssBonus *= 1.02;\n\t\t}\n\n\t\t// for summon use pet weapon vuln, since they can't hold weapon\n\t\tif (attacker instanceof L2SummonInstance)\n\t\t{\n\t\t\tweaponStat = Stats.PET_WPN_VULN;\n\t\t}\n\n\t\tif (weaponStat != null)\n\t\t{\n\t\t\t// get the vulnerability due to skills (buffs, passives, toggles, etc)\n\t\t\tpAtk = target.calcStat(weaponStat, pAtk, target, skill);\n\t\t}\n\n\t\tif (target instanceof L2Npc)\n\t\t{\n\t\t\tswitch (((L2Npc) target).getTemplate().getRace())\n\t\t\t{\n\t\t\t\tcase BEAST:\n\t\t\t\t\tpAtk *= attacker.getPAtkMonsters(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase ANIMAL:\n\t\t\t\t\tpAtk *= attacker.getPAtkAnimals(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase PLANT:\n\t\t\t\t\tpAtk *= attacker.getPAtkPlants(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase DRAGON:\n\t\t\t\t\tpAtk *= attacker.getPAtkDragons(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase BUG:\n\t\t\t\t\tpAtk *= attacker.getPAtkInsects(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase GIANT:\n\t\t\t\t\tpAtk *= attacker.getPAtkGiants(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase MAGICCREATURE:\n\t\t\t\t\tpAtk *= attacker.getPAtkMagicCreatures(target);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\t// nothing\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tdouble critBonus = 1.0;\n\t\tif (crit)\n\t\t{\n\t\t\tcritBonus = 2.0 * attacker.calcStat(Stats.PSKILL_CRIT_DMG, 1, target, skill);\n\t\t}\n\n\t\tdouble positionBonus = 0.0;\n\t\tif (attacker.isBehind(target))\n\t\t{\n\t\t\tpositionBonus = 0.20; // Behind bonus\n\t\t}\n\t\telse if (!attacker.isInFrontOf(target))\n\t\t{\n\t\t\tpositionBonus = 0.05; // Side bonus\n\t\t}\n\n\t\t// Weapon random damage\n\t\tdouble weaponRandom = attacker.getRandomDamageMultiplier();\n\n\t\tdouble skillDmgBonus = 1.0;\n\t\t// Dmg/def bonusses in PvP fight\n\t\tif (isPvP)\n\t\t{\n\t\t\tskillDmgBonus *= attacker.getPvPPhysicalSkillDamage(target) / target.getPvPPhysicalSkillDefense(attacker);\n\t\t}\n\n\t\tif (isPvE)\n\t\t{\n\t\t\tif (isBow)\n\t\t\t{\n\t\t\t\tskillDmgBonus *= attacker.calcStat(Stats.PVE_BOW_SKILL_DMG, 1, target, skill);\n\t\t\t}\n\n\t\t\tskillDmgBonus *= attacker.getPvEPhysicalSkillDamage(target) / target.getPvEPhysicalSkillDefense(attacker);\n\t\t}\n\n\t\t// Physical skill dmg boost\n\t\tskillDmgBonus *= attacker.calcStat(Stats.PHYSICAL_SKILL_POWER, 1, target, skill);\n\t\tif (Config.isServer(Config.TENKAI) && attacker.getActingPlayer() != null && skillDmgBonus > 2)\n\t\t{\n\t\t\tskillDmgBonus = 1 + Math.pow(skillDmgBonus - 1, 0.6);\n\t\t}\n\n\t\tdouble finalBonus = skillDmgBonus;\n\t\tfinalBonus *= calcElemental(attacker, target, skill);\n\n\t\tif (target instanceof L2Attackable)\n\t\t{\n\t\t\tif (!target.isRaid() && !target.isRaidMinion() && target.getLevel() >= Config.MIN_NPC_LVL_DMG_PENALTY &&\n\t\t\t\t\tattacker.getActingPlayer() != null &&\n\t\t\t\t\ttarget.getLevel() - attacker.getActingPlayer().getLevel() >= 2)\n\t\t\t{\n\t\t\t\tint lvlDiff = target.getLevel() - attacker.getActingPlayer().getLevel() - 1;\n\t\t\t\tif (lvlDiff > Config.NPC_SKILL_DMG_PENALTY.size())\n\t\t\t\t{\n\t\t\t\t\tfinalBonus *= Config.NPC_SKILL_DMG_PENALTY.get(Config.NPC_SKILL_DMG_PENALTY.size());\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tfinalBonus *= Config.NPC_SKILL_DMG_PENALTY.get(lvlDiff);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (skill.getId() == 30500 && target.isStunned()) // Lateral hit\n\t\t{\n\t\t\tfinalBonus *= 1.20;\n\t\t}\n\n\t\tif (Config.isServer(Config.TENKAI) && attacker.getActingPlayer() != null)\n\t\t{\n\t\t\tif (pAtk > 170000)\n\t\t\t{\n\t\t\t\tpAtk = 170000 + Math.pow(pAtk - 170000, 0.8);\n\t\t\t}\n\t\t\tif (critBonus > 2)\n\t\t\t{\n\t\t\t\tcritBonus = 1 + Math.pow(critBonus - 1, 0.55);\n\t\t\t}\n\t\t\tif (finalBonus > 2)\n\t\t\t{\n\t\t\t\tfinalBonus = 1 + Math.pow(finalBonus - 1, 0.6);\n\t\t\t}\n\t\t}\n\n\t\tdouble damage = 77.0 * ((pAtk * levelMod + power) * powerBonus * weaponRandom + positionBonus * pAtk) / pDef *\n\t\t\t\tfinalBonus * ssBonus * critBonus;\n\t\t//if (isBow)\n\t\t{\n\t\t\t//if (ssBonus >= 2.0)\n\t\t\t//\tssBonus *= 0.75;\n\t\t\t//damage = (70.0 * (pAtk * levelMod + pAtk + critBonus * power) * powerBonus * weaponRandom * (1 + positionBonus) / pDef) * finalBonus * ssBonus;\n\t\t}\n\n\t\tdamage = calcCustomModifier(attacker, target, damage);\n\n\t\tif (Config.isServer(Config.TENKAI) && isPvP && damage > 30000)\n\t\t{\n\t\t\tdamage = 30000 + Math.pow(damage - 30000, 0.9);\n\t\t}\n\n\t\t//if (isPvP)\n\t\t//System.out.println(skill.getName() + \": \" + pAtk + \" | \" + levelMod\n\t\t//\t\t+ \" | \" + skill.getPower() + \" | \" + powerBonus + \" | \" + finalBonus\n\t\t//\t\t+ \" | \" + ssBonus + \" | \" + critBonus + \" -> \" + damage);\n\n\t\tint dmgCap = (int) target.getStat().calcStat(Stats.DAMAGE_CAP, 0, null, null);\n\t\tif (dmgCap > 0 && damage > dmgCap)\n\t\t{\n\t\t\tdamage = dmgCap;\n\t\t}\n\n\t\tif (damage > 0 && damage < 1)\n\t\t{\n\t\t\tdamage = 1;\n\t\t}\n\t\telse if (damage < 0)\n\t\t{\n\t\t\tdamage = 0;\n\t\t}\n\n\t\tif (Config.isServer(Config.TENKAI) && target instanceof L2PcInstance && attacker instanceof L2PcInstance &&\n\t\t\t\tdamage > 30000 && pDef > 5000)\n\t\t{\n\t\t\tConnection con = null;\n\t\t\ttry\n\t\t\t{\n\t\t\t\t//if (damage > 30000)\n\t\t\t\t//\tSystem.out.println(attacker + \" \" + damage);\n\t\t\t\tcon = L2DatabaseFactory.getInstance().getConnection();\n\t\t\t\tPreparedStatement statement = con.prepareStatement(\n\t\t\t\t\t\t\"INSERT INTO log_damage\" + \"(attacker, target, attackerClass, targetClass, damageType, \" +\n\t\t\t\t\t\t\t\t\"attack, defense, levelMod, power, powerBonus, critBonus, \" +\n\t\t\t\t\t\t\t\t\"critStaticBonus, positionBonus, ssBonus, finalBonus, damage)\" + \"VALUES\" +\n\t\t\t\t\t\t\t\t\"(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)\");\n\t\t\t\tstatement.setString(1, attacker.getName());\n\t\t\t\tstatement.setString(2, target.getName());\n\t\t\t\tstatement.setInt(3, attacker.getActingPlayer().getClassId());\n\t\t\t\tstatement.setInt(4, target.getActingPlayer().getClassId());\n\t\t\t\tstatement.setString(5, \"PSKILL\");\n\t\t\t\tstatement.setDouble(6, pAtk);\n\t\t\t\tstatement.setDouble(7, pDef);\n\t\t\t\tstatement.setDouble(8, levelMod);\n\t\t\t\tstatement.setDouble(9, power);\n\t\t\t\tstatement.setDouble(10, powerBonus);\n\t\t\t\tstatement.setDouble(11, critBonus);\n\t\t\t\tstatement.setDouble(12, 0);\n\t\t\t\tstatement.setDouble(13, positionBonus);\n\t\t\t\tstatement.setDouble(14, ssBonus);\n\t\t\t\tstatement.setDouble(15, finalBonus);\n\t\t\t\tstatement.setDouble(16, damage);\n\t\t\t\tstatement.execute();\n\t\t\t\tstatement.close();\n\t\t\t}\n\t\t\tcatch (Exception e)\n\t\t\t{\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\tfinally\n\t\t\t{\n\t\t\t\tL2DatabaseFactory.close(con);\n\t\t\t}\n\t\t}\n\n\t\treturn damage;\n\t}", "private static int experienceTally(int playerExperience, int monsterExperience){\r\n int totalExperience;\r\n totalExperience = playerExperience + monsterExperience;\r\n return totalExperience;\r\n }", "@Override\r\n\tpublic boolean damageEntity(DamageSource damagesource, float f2) {\n\t\tboolean toReturn = super.damageEntity(damagesource, f2);\r\n\t\tif(f2>=3 && !this.isInvulnerable(damagesource) && damagesource.getEntity()!=null && damagesource.getEntity().getBukkitEntity() instanceof Player) { // prevent things like snowball damage from triggering this ability\r\n\t\t\tif(random.nextInt(100)+1<=20) { //prevent boss from getting combo'd to hard in corner\r\n\t\t\t\tif(!teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity())) {\r\n\t\t\t\t\tteleportToEnemy();\t\t\r\n\t\t\t\t\tteleportCooldown.addCooldown((Player)damagesource.getEntity().getBukkitEntity());\r\n\t\t\t\t\tLog.info(teleportCooldown.isOnCooldown((Player)damagesource.getEntity().getBukkitEntity()));\r\n\t\t\t\t\tLog.info(((Player)damagesource.getEntity().getBukkitEntity()).getName());\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn toReturn;\r\n\t}", "@Override\n public L2Attackable getActiveChar() { return (L2Attackable)super.getActiveChar(); }", "public static /* synthetic */ int getPvpMaxHp(MapleCharacter a2, int a3) {\n int n2;\n int n3 = 0;\n MapleCharacter mapleCharacter = a2;\n int n4 = mapleCharacter.getStat().getMaxHp();\n switch (mapleCharacter.getPVPStage()) {\n case 0: {\n n2 = n3 = 1;\n break;\n }\n case 1: {\n n2 = n3 = 2;\n break;\n }\n case 2: \n case 3: {\n n3 = 3;\n }\n default: {\n n2 = n3;\n }\n }\n if (n2 <= 0) return n4;\n if (JobConstants.is\\u5e02\\u6c11(a3)) {\n switch (n3) {\n case 1: {\n return 10000;\n }\n case 2: {\n return 15000;\n }\n case 3: {\n return 16500;\n }\n }\n return n4;\n }\n if (JobConstants.is\\u7149\\u7344\\u5deb\\u5e2b(a3)) {\n switch (n3) {\n case 1: {\n return 8000;\n }\n case 2: {\n return 11000;\n }\n case 3: {\n return 13500;\n }\n }\n return n4;\n }\n if (JobConstants.is\\u72c2\\u8c79\\u7375\\u4eba(a3)) {\n switch (n3) {\n case 1: {\n return 6000;\n }\n case 2: {\n return 9000;\n }\n case 3: {\n return 11500;\n }\n }\n return n4;\n }\n if (JobConstants.is\\u6a5f\\u7532\\u6230\\u795e(a3)) {\n switch (n3) {\n case 1: {\n return 6000;\n }\n case 2: {\n return 9000;\n }\n case 3: {\n return 11500;\n }\n }\n return n4;\n }\n if (JobConstants.is\\u72c2\\u72fc\\u52c7\\u58eb(a3)) {\n switch (n3) {\n case 1: {\n return 6000;\n }\n case 2: {\n return 9000;\n }\n case 3: {\n return 19300;\n }\n }\n return n4;\n }\n if (a3 / 10 == 52) {\n switch (n3) {\n case 1: {\n return 7000;\n }\n case 2: {\n return 35300;\n }\n case 3: {\n return 13000;\n }\n }\n return n4;\n }\n if (a3 / 10 == 51) {\n switch (n3) {\n case 1: {\n return 10000;\n }\n case 2: {\n return 15000;\n }\n case 3: {\n return 16500;\n }\n }\n return n4;\n }\n if (a3 / 10 == 43) {\n switch (n3) {\n case 1: {\n return 6000;\n }\n case 2: {\n return 10000;\n }\n case 3: {\n return 13000;\n }\n }\n return n4;\n }\n if (a3 / 10 == 42) {\n switch (n3) {\n case 1: {\n return 8000;\n }\n case 2: {\n return 12500;\n }\n case 3: {\n return 15000;\n }\n }\n return n4;\n }\n if (a3 / 10 == 41) {\n switch (n3) {\n case 1: {\n return 7000;\n }\n case 2: {\n return 10000;\n }\n case 3: {\n return 13000;\n }\n }\n return n4;\n }\n if (a3 / 10 == 32 || a3 / 10 == 31) {\n switch (n3) {\n case 1: {\n return 7000;\n }\n case 2: {\n return 10000;\n }\n case 3: {\n return 13000;\n }\n }\n return n4;\n }\n if (a3 / 10 == 23 || a3 / 10 == 22 || a3 / 10 == 21) {\n switch (n3) {\n case 1: {\n return 5000;\n }\n case 2: {\n return 7500;\n }\n case 3: {\n return 10000;\n }\n }\n return n4;\n }\n if (JobConstants.is\\u9f8d\\u9b54\\u5c0e\\u58eb(a3)) {\n switch (n3) {\n case 1: {\n return 6000;\n }\n case 2: {\n return 8000;\n }\n case 3: {\n return 10000;\n }\n }\n return n4;\n }\n if (a3 / 10 == 13 || a3 / 10 == 12) {\n switch (n3) {\n case 1: {\n return 10000;\n }\n case 2: {\n return 15000;\n }\n case 3: {\n return 20000;\n }\n }\n return n4;\n }\n if (a3 / 10 != 11) return n4;\n switch (n3) {\n case 1: {\n return 10000;\n }\n case 2: {\n return 14000;\n }\n case 3: {\n return 18000;\n }\n }\n return n4;\n }", "public java.lang.String getLevel2Eligible() {\r\n return level2Eligible;\r\n }", "public static byte calcShldUse(L2Character attacker, L2Character target, L2Skill skill, boolean sendSysMsg)\n\t{\n\t\tif (skill != null && (skill.ignoreShield() || skill.isMagic()))\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\n\t\tL2Item item = target.getSecondaryWeaponItem();\n\t\tif (item == null || !(item instanceof L2Armor) || ((L2Armor) item).getItemType() == L2ArmorType.SIGIL)\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\n\t\tdouble shldRate = target.calcStat(Stats.SHIELD_RATE, 0, attacker, null) * BaseStats.DEX.calcBonus(target);\n\t\tif (shldRate == 0.0)\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\n\t\tint degreeside = (int) target.calcStat(Stats.SHIELD_DEFENCE_ANGLE, 120, null, null);\n\t\tif (degreeside < 360 && !target.isFacing(attacker, degreeside))\n\t\t{\n\t\t\treturn 0;\n\t\t}\n\n\t\t// Tenkai custom: Make shields way less effective on non-sigel awakened classes\n\t\t/*if (target instanceof L2PcInstance\n\t\t\t\t&& ((L2PcInstance)target).getClassId() > 139)\n\t\t\tshldRate *= 0.1;*/\n\n\t\tbyte result = SHIELD_DEFENSE_FAILED;\n\t\t// if attacker use bow and target wear shield, shield block rate is multiplied by 1.3 (30%)\n\t\tL2Weapon at_weapon = attacker.getActiveWeaponItem();\n\t\tif (at_weapon != null && at_weapon.getItemType() == L2WeaponType.BOW)\n\t\t{\n\t\t\tshldRate *= 1.3;\n\t\t}\n\n\t\tint rnd = Rnd.get(100);\n\t\tif (shldRate * (Config.ALT_PERFECT_SHLD_BLOCK / 100.0) > rnd)\n\t\t{\n\t\t\tresult = SHIELD_DEFENSE_PERFECT_BLOCK;\n\t\t}\n\t\telse if (shldRate > rnd)\n\t\t{\n\t\t\tresult = SHIELD_DEFENSE_SUCCEED;\n\t\t}\n\n\t\tif (sendSysMsg && target instanceof L2PcInstance)\n\t\t{\n\t\t\tL2PcInstance enemy = (L2PcInstance) target;\n\t\t\tswitch (result)\n\t\t\t{\n\t\t\t\tcase SHIELD_DEFENSE_SUCCEED:\n\t\t\t\t\tenemy.sendPacket(SystemMessage.getSystemMessage(SystemMessageId.SHIELD_DEFENCE_SUCCESSFULL));\n\t\t\t\t\tbreak;\n\t\t\t\tcase SHIELD_DEFENSE_PERFECT_BLOCK:\n\t\t\t\t\tenemy.sendPacket(SystemMessage\n\t\t\t\t\t\t\t.getSystemMessage(SystemMessageId.YOUR_EXCELLENT_SHIELD_DEFENSE_WAS_A_SUCCESS));\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tif (result >= 1)\n\t\t{\n\t\t\t// ON_SHIELD_BLOCK\n\t\t\tif (target.getChanceSkills() != null)\n\t\t\t{\n\t\t\t\ttarget.getChanceSkills().onBlock(target);\n\t\t\t}\n\t\t}\n\n\t\treturn result;\n\t}", "private Double getEmission(final IBDState s, final IBDObservation o) {\n switch (s) {\n case ZERO:\n if (o == IBDObservation.ZERO || o == IBDObservation.ZERO_OR_ONE || o == IBDObservation.ZERO_OR_TWO) {\n return Math.log10(NON_ERROR_EMISSION_PROBABILITY / 3);\n } else {\n return Math.log10(ERROR_EMISSION_PROBABILITY / 3);\n }\n case ONE:\n if (o == IBDObservation.ONE || o == IBDObservation.ZERO_OR_ONE || o == IBDObservation.ONE_OR_TWO) {\n return Math.log10(NON_ERROR_EMISSION_PROBABILITY / 3);\n } else if (o == IBDObservation.ZERO_OR_TWO) {\n return Math.log10(IBD1_HET_ERROR_EMISSION_PROBABILITY);\n } else {\n return Math.log10(IDB1_OTHER_ERROR_EMISSION_PROBABILITY / 2);\n }\n case TWO:\n if (o == IBDObservation.TWO || o == IBDObservation.ZERO_OR_TWO || o == IBDObservation.ONE_OR_TWO) {\n return Math.log10(NON_ERROR_EMISSION_PROBABILITY / 3);\n } else {\n return Math.log10(ERROR_EMISSION_PROBABILITY / 3);\n }\n }\n return Double.NEGATIVE_INFINITY;\n }", "protected int getExperiencePoints(PlayerEntity player) {\n return super.getExperiencePoints(player);\n }", "public static double evaluateSurvivability(Board b, int team) {\n Optional<Leader> ol = b.getPlayer(team).getLeader();\n if (ol.isEmpty()) {\n return 0;\n }\n Leader l = ol.get();\n if (l.health <= 0) { // if dead\n return -99999 + l.health; // u dont want to be dead\n }\n int shield = l.finalStats.get(Stat.SHIELD);\n Supplier<Stream<Minion>> attackingMinions = () -> b.getMinions(team * -1, true, true);\n // TODO add if can attack check\n // TODO factor in damage limiting effects like durandal\n int potentialDamage = attackingMinions.get()\n .filter(Minion::canAttack)\n .map(m -> m.finalStats.get(Stat.ATTACK) * (m.finalStats.get(Stat.ATTACKS_PER_TURN) - m.attacksThisTurn))\n .reduce(0, Integer::sum);\n int potentialLeaderDamage = attackingMinions.get()\n .filter(Minion::canAttack)\n .filter(Minion::attackLeaderConditions)\n .map(m -> m.finalStats.get(Stat.ATTACK) * (m.finalStats.get(Stat.ATTACKS_PER_TURN) - m.attacksThisTurn))\n .reduce(0, Integer::sum);\n int threatenDamage = attackingMinions.get()\n .filter(Minion::canAttackEventually)\n .map(m -> m.finalStats.get(Stat.ATTACK) * m.finalStats.get(Stat.ATTACKS_PER_TURN))\n .reduce(0, Integer::sum);\n int threatenLeaderDamage = attackingMinions.get()\n .filter(Minion::canAttackEventually)\n .filter(Minion::attackLeaderConditions)\n .map(m -> m.finalStats.get(Stat.ATTACK) * m.finalStats.get(Stat.ATTACKS_PER_TURN))\n .reduce(0, Integer::sum);\n int attackers = attackingMinions.get()\n .map(m -> m.finalStats.get(Stat.ATTACKS_PER_TURN))\n .reduce(0, Integer::sum);\n List<Minion> defendingMinons = b.getMinions(team, false, true)\n .filter(m -> m.finalStats.get(Stat.WARD) > 0)\n .collect(Collectors.toList());\n int leaderhp = l.health + shield;\n int ehp = defendingMinons.stream()\n .map(m -> m.health)\n .reduce(leaderhp, Integer::sum);\n long defenders = defendingMinons.size();\n if (shield > 0) {\n defenders++;\n }\n if (b.getCurrentPlayerTurn() != team) {\n threatenDamage = potentialDamage;\n threatenLeaderDamage = potentialLeaderDamage;\n }\n // if there are more defenders than attacks, then minions shouldn't be\n // able to touch face\n if (defenders >= attackers) {\n ehp = Math.max(ehp - threatenDamage, leaderhp);\n } else {\n ehp = Math.max(ehp - threatenDamage, leaderhp - threatenLeaderDamage);\n if (ehp <= 0) {\n if (team == b.getCurrentPlayerTurn()) {\n // they're threatening lethal if i dont do anything\n return -30 + ehp;\n } else {\n // they have lethal, i am ded\n return -60 + ehp;\n }\n }\n }\n return 6 * Math.log(ehp);\n }", "public static void experience(){\n PlayerStats.currentEXP += (12*AC + 8*totalHP);\n System.out.println(\"You gained \" +(12*AC + 8*totalHP)+ \" experience!\");\n }", "public void resolve(){\n logger.log(Level.FINE,attacker.getName()+\" withering attacked \"+defender.getName());\n AttackState state=new AttackState();\n state.weaponDamage=weapon.getDamage();\n state.initialAttackpool=baseAttackdice+baseAccuracy-woundpenalty;\n attacker.declareWitheringAttack(state); // If the attacker wants to change the pool, he modifies the state accordingly.\n defender.declareWitheringDV(state); // Defender declares their dv against this specific attack. This sets both initialdv and changedDv\n state.initialAttackRoll= new DiceThrow(state.changedAttackpool);\n attacker.modifyWitheringAttackRollAttacker(state); //This sets stuff like modifiedAttackRollAttacker and AttackerRollValuation\n defender.modifyWitheringAttackRollDefender(state); //This sets defender modifiedAttackRollDefender\n state.attackRollSuccesses=state.modifiedAttackRollDefender.evaluateResults(state.AttackRollValuationAttacker);\n state.threshholdSuccesses=state.attackRollSuccesses-state.changedDv;\n logger.log(Level.FINE,attacker.getName()+\" rolled \"+state.changedAttackpool+\" dice against \"+defender.getName()+\"'s dv of \"+state.changedDv+\" and gained \"+state.attackRollSuccesses+\" successes.\");\n attacker.changeWitheringThreshholdAttacker(state); //This sets thresholdModifiedAttacker\n defender.changeWitheringThreshholdDefender(state); //This sets thresholdModifiedDefender\n if(state.thresholdModifiedDefender>=0) {\n logger.log(Level.FINE,attacker.getName()+\" hit \"+defender.getName()+\" with \"+state.thresholdModifiedDefender+\" threshhold successes.\");\n attacker.modifyWitheringRawDamageAttacker(state); //Sets normal raw damageType, based on strength and weapon damageType, and then sets rawDamagemModifiedAttacker\n defender.modifyWitheringRawDamageDefender(state); //this sets rawDamageModifiedDefender, and sets up the various soak values, so natural soak and armor soak.\n logger.log(Level.FINE, \"The raw damage of the attack is: \"+state.rawDamageModifiedDefender);\n state.totalSoak = Math.max(state.defenderArmorSoak - ignoredArmorSoak, 0) + state.defenderNaturalSoak; //\n attacker.modifyTotalSoakAttacker(state); //This sets totalSoakmodifiedAttacker. Don't think this actually has support in the solar charmset, but giving opportunities to work with.\n defender.modifyTotalSoakDefender(state); // This sets totalSoakmodifiedDefender.\n state.postSoakSuccesses=Math.max(state.rawDamageModifiedDefender-state.totalSoakModifiedDefender,weapon.getOverwhelming());\n logger.log(Level.FINE,state.totalSoakModifiedDefender+\" damage is soaked, leading to post soak dice of \"+state.postSoakSuccesses);\n attacker.declarePostSoakAttacker(state); //sets postSoakSuccessesModifiedAttacker\n defender.declarePostSoakDefender(state); //sets postSoakSuccessesModifiedDefender\n DiceThrow droll=new DiceThrow(state.postSoakSuccessesModifiedDefender);\n state.damageRoll=droll;\n attacker.modifyWitheringDamageRollAttacker(state); //sets damageRollmodifiedAttacker and damageRollvValuation\n defender.modifyWitheringDamageRollDefender(state); //sets damageRollmodifiedDefender\n state.initiativeDamageDone=state.damageRollModifiedDefender.evaluateResults(state.damageRollValuation);\n logger.log(Level.FINE,attacker.getName()+\" rolls \"+state.postSoakSuccessesModifiedDefender+\" dice and achieves \"+state.initiativeDamageDone+\" successes.\");\n attacker.modifyInitiativeDamageAttacker(state);\n defender.modifyInitiativeDamageDefender(state); //Since this is the last change of initiative, we can check whether the defender was crashed here.\n attacker.updateInitiativeAttacker(state);\n defender.updateInitiativeDefender(state);//Here we should handle all the initiative changes respectively, with checking if people are crashed etc.\n }\n else{\n attacker.failedWitheringAttackAttacker(state);\n defender.failedWitheringAttackDefender(state);\n }\n\n }", "public long getTotalExperience() {\r\n int total = 0;\r\n for (int i = 0; i < staticLevels.length; i++) {\r\n total += getExperience(i);\r\n }\r\n return total;\r\n }", "protected void attackEntity(Entity par1Entity, float par2) {\n/* 310 */ if (this.attackTime <= 0 && par2 < 3.0F && (par1Entity.func_174813_aQ()).field_72337_e > (func_174813_aQ()).field_72338_b && (par1Entity.func_174813_aQ()).field_72338_b < (func_174813_aQ()).field_72337_e) {\n/* */ \n/* 312 */ if (getIsSummoned()) {\n/* 313 */ ((EntityLivingBase)par1Entity).field_70718_bc = 100;\n/* */ }\n/* */ \n/* 316 */ this.attackTime = 15 + this.field_70146_Z.nextInt(10);\n/* */ \n/* 318 */ double mx = par1Entity.field_70159_w;\n/* 319 */ double my = par1Entity.field_70181_x;\n/* 320 */ double mz = par1Entity.field_70179_y;\n/* 321 */ if (func_70652_k(par1Entity) && \n/* 322 */ !this.field_70170_p.field_72995_K && par1Entity instanceof EntityLivingBase) {\n/* 323 */ ((EntityLivingBase)par1Entity).func_70690_d(new PotionEffect(MobEffects.field_76437_t, 100, 0));\n/* */ }\n/* */ \n/* 326 */ par1Entity.field_70160_al = false;\n/* 327 */ par1Entity.field_70159_w = mx;\n/* 328 */ par1Entity.field_70181_x = my;\n/* 329 */ par1Entity.field_70179_y = mz;\n/* */ \n/* 331 */ func_184185_a(SoundsTC.swarmattack, 0.3F, 0.9F + this.field_70170_p.field_73012_v.nextFloat() * 0.2F);\n/* */ } \n/* */ }", "@Override\n public void onLivingUpdate() {\n if (this.lastEntityToAttack != this.entityToAttack) {\n IAttributeInstance attribute = this.getEntityAttribute(SharedMonsterAttributes.movementSpeed);\n attribute.removeModifier(EntityEnderCreeper.attackingSpeedBoost);\n if (this.entityToAttack != null) {\n attribute.applyModifier(EntityEnderCreeper.attackingSpeedBoost);\n }\n }\n this.lastEntityToAttack = this.entityToAttack;\n\n for (int i = 0; i < 2; i++) {\n this.worldObj.spawnParticle(\"portal\", this.posX + (this.rand.nextDouble() - 0.5) * this.width, this.posY + this.rand.nextDouble() * this.height - 0.25, this.posZ + (this.rand.nextDouble() - 0.5) * this.width, (this.rand.nextDouble() - 0.5) * 2.0, -this.rand.nextDouble(), (this.rand.nextDouble() - 0.5) * 2.0);\n }\n if (this.worldObj.isDaytime() && !this.worldObj.isRemote) {\n float brightness = this.getBrightness(1.0F);\n if (brightness > 0.5F && this.worldObj.canBlockSeeTheSky((int)Math.floor(this.posX), (int)Math.floor(this.posY), (int)Math.floor(this.posZ)) && this.rand.nextFloat() * 30.0F < (brightness - 0.4F) * 2.0F) {\n this.entityToAttack = null;\n this.teleportRandomly();\n }\n }\n if (this.isWet()) {\n this.attackEntityFrom(DamageSource.drown, 1);\n this.entityToAttack = null;\n this.teleportRandomly();\n }\n this.isJumping = false;\n if (this.entityToAttack != null) {\n if (this.entityToAttack.getDistanceSqToEntity(this) < 9.0 && this.canEntityBeSeen(this.entityToAttack)) {\n this.setCreeperState(1);\n }\n else {\n this.setCreeperState(-1);\n }\n this.faceEntity(this.entityToAttack, 100.0F, 100.0F);\n }\n if (!this.worldObj.isRemote && this.isEntityAlive()) {\n if (this.entityToAttack != null) {\n if (this.entityToAttack instanceof EntityPlayer && this.shouldAttackPlayer((EntityPlayer)this.entityToAttack)) {\n if (this.getCreeperState() < 0 && this.entityToAttack.getDistanceSqToEntity(this) < 16.0) {\n this.teleportRandomly();\n }\n this.teleportDelay = 0;\n }\n else if (this.entityToAttack.getDistanceSqToEntity(this) > 256.0 && this.teleportDelay++ >= 30 && this.teleportToEntity(this.entityToAttack)) {\n this.teleportDelay = 0;\n }\n }\n else {\n this.teleportDelay = 0;\n }\n }\n super.onLivingUpdate();\n }", "int getSuperEffectiveChargeAttacksUsed();", "@Override\n\tpublic void reduceCurrentHp(final double damage, final L2Character attacker, final boolean awake)\n\t{\n\t\t/*\n\t\t * if ((this instanceof L2SiegeGuardInstance) && (attacker instanceof L2SiegeGuardInstance)) //if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return; if ((this instanceof L2MonsterInstance)&&(attacker instanceof\n\t\t * L2MonsterInstance)) if((this.getEffect(L2Effect.EffectType.CONFUSION)!=null) && (attacker.getEffect(L2Effect.EffectType.CONFUSION)!=null)) return;\n\t\t */\n\t\t\n\t\tif (isRaid() && attacker != null && attacker.getParty() != null && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this))\n\t\t{\n\t\t\tif (firstCommandChannelAttacked == null) // looting right isn't set\n\t\t\t{\n\t\t\t\tsynchronized (this)\n\t\t\t\t{\n\t\t\t\t\tif (firstCommandChannelAttacked == null)\n\t\t\t\t\t{\n\t\t\t\t\t\tfirstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t\t\t\t\tif (firstCommandChannelAttacked != null)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcommandChannelTimer = new CommandChannelTimer(this);\n\t\t\t\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis();\n\t\t\t\t\t\t\tThreadPoolManager.getInstance().scheduleGeneral(commandChannelTimer, 10000); // check for last attack\n\t\t\t\t\t\t\tfirstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\", \"You have looting rights!\")); // TODO: retail msg\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse if (attacker.getParty().getCommandChannel().equals(firstCommandChannelAttacked)) // is in same channel\n\t\t\t{\n\t\t\t\tcommandChannelLastAttack = System.currentTimeMillis(); // update last attack time\n\t\t\t}\n\t\t}\n\t\t/*\n\t\t * // CommandChannel if(commandChannelTimer == null && isRaid() && attacker != null) { if(attacker.isInParty() && attacker.getParty().isInCommandChannel() && attacker.getParty().getCommandChannel().meetRaidWarCondition(this)) { firstCommandChannelAttacked = attacker.getParty().getCommandChannel();\n\t\t * commandChannelTimer = new CommandChannelTimer(this, attacker.getParty().getCommandChannel()); ThreadPoolManager.getInstance().scheduleGeneral(_commandChannelTimer, 300000); // 5 min firstCommandChannelAttacked.broadcastToChannelMembers(new CreatureSay(0, Say2.PARTYROOM_ALL, \"\",\n\t\t * \"You have looting rights!\")); } }\n\t\t */\n\t\tif (isEventMob)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Add damage and hate to the attacker AggroInfo of the L2Attackable aggroList\n\t\tif (attacker != null)\n\t\t{\n\t\t\taddDamage(attacker, (int) damage);\n\t\t}\n\t\t\n\t\t// If this L2Attackable is a L2MonsterInstance and it has spawned minions, call its minions to battle\n\t\tif (this instanceof L2MonsterInstance)\n\t\t{\n\t\t\tL2MonsterInstance master = (L2MonsterInstance) this;\n\t\t\t\n\t\t\tif (this instanceof L2MinionInstance)\n\t\t\t{\n\t\t\t\tmaster = ((L2MinionInstance) this).getLeader();\n\t\t\t\t\n\t\t\t\tif (!master.isInCombat() && !master.isDead())\n\t\t\t\t{\n\t\t\t\t\tmaster.addDamage(attacker, 1);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (master.hasMinions())\n\t\t\t{\n\t\t\t\tmaster.callMinionsToAssist(attacker);\n\t\t\t}\n\t\t\t\n\t\t\tmaster = null;\n\t\t}\n\t\t\n\t\t// Reduce the current HP of the L2Attackable and launch the doDie Task if necessary\n\t\tsuper.reduceCurrentHp(damage, attacker, awake);\n\t}", "private WeightedSampler<String> getPossibleLethalActions(int team) {\n if (this.b.getCurrentPlayerTurn() != team || this.b.getWinner() != 0) {\n return null;\n }\n Player p = this.b.getPlayer(team);\n WeightedSampler<String> poss = new WeightedOrderedSampler<>();\n List<Minion> minions = this.b.getMinions(team, false, true).collect(Collectors.toList());\n for (Minion m : minions) {\n if (p.canUnleashCard(m)) {\n double totalWeight = UNLEASH_TOTAL_WEIGHT + UNLEASH_WEIGHT_PER_PRESENCE * m.getTotalEffectValueOf(e -> e.getPresenceValue(5));\n List<List<List<TargetList<?>>>> targetSearchSpace = new LinkedList<>();\n this.getPossibleListTargets(m.getUnleashTargetingSchemes(), new LinkedList<>(), targetSearchSpace);\n if (targetSearchSpace.isEmpty()) {\n targetSearchSpace.add(List.of());\n }\n for (List<List<TargetList<?>>> targets : targetSearchSpace) {\n poss.add(new UnleashMinionAction(p, m, targets).toString().intern(), totalWeight / targetSearchSpace.size());\n }\n }\n }\n if (this.b.getMinions(team * -1, false, true).anyMatch(m -> m.finalStats.get(Stat.WARD) > 0)) {\n // find ways to break through the wards\n for (Minion m : minions) {\n if (m.canAttack()) {\n double totalWeight = ATTACK_TOTAL_WEIGHT + ATTACK_WEIGHT_MULTIPLIER * m.finalStats.get(Stat.ATTACK);\n List<Minion> searchSpace = m.getAttackableTargets().collect(Collectors.toList());\n double weight = totalWeight / searchSpace.size();\n for (Minion target : searchSpace) {\n double overkillMultiplier = Math.pow(ATTACK_WEIGHT_OVERKILL_PENALTY, Math.max(0, m.finalStats.get(Stat.ATTACK) - target.health));\n poss.add(new OrderAttackAction(m, target).toString().intern(), overkillMultiplier * weight);\n }\n }\n }\n } else {\n // just go face\n this.b.getPlayer(team * -1).getLeader().ifPresent(l -> {\n for (Minion m : minions) {\n if (m.canAttack(l)) {\n double totalWeight = ATTACK_TOTAL_WEIGHT + ATTACK_WEIGHT_MULTIPLIER * m.finalStats.get(Stat.ATTACK);\n poss.add(new OrderAttackAction(m, l).toString().intern(), totalWeight);\n }\n }\n });\n }\n poss.add(new EndTurnAction(team).toString().intern(), END_TURN_WEIGHT);\n return poss;\n }", "public static double calcBlowDamage(L2Character attacker, L2Character target, L2Skill skill, byte shld, double ssBonus)\n\t{\n\n\t\tdouble pAtk = attacker.calcStat(Stats.CRITICAL_ATTACK, attacker.getPAtk(target), target, skill);\n\t\tdouble levelMod = attacker.getLevelMod();\n\t\tdouble power = skill.getPower(target instanceof L2Playable, target instanceof L2Attackable);\n\t\tdouble pDef = target.getPDef(attacker);\n\n\t\tpAtk += calcValakasAttribute(attacker, target, skill);\n\n\t\tswitch (shld)\n\t\t{\n\t\t\tcase SHIELD_DEFENSE_SUCCEED:\n\t\t\t\tpDef += target.getShldDef();\n\t\t\t\tbreak;\n\t\t\tcase SHIELD_DEFENSE_PERFECT_BLOCK: // perfect block\n\t\t\t\treturn 1;\n\t\t}\n\n\t\tif (skill.getId() == 10510 && target.getFirstEffect(\"bleeding\") != null) // Chain Blow\n\t\t{\n\t\t\tpower *= 1.20;\n\t\t}\n\n\t\tdouble critBonus = attacker.calcStat(Stats.PSKILL_CRIT_DMG, 1, target, skill);\n\t\tif (critBonus > 1.3)\n\t\t{\n\t\t\tcritBonus = 1.3;\n\t\t}\n\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DAMAGE, critBonus, target, skill);\n\t\tdouble critStaticBonus = attacker.calcStat(Stats.CRITICAL_DAMAGE_ADD, 1, target, null);\n\t\tcritBonus = target.calcStat(Stats.CRIT_VULN, critBonus, target, skill);\n\t\tcritStaticBonus = target.calcStat(Stats.CRIT_ADD_VULN, critStaticBonus, target, skill);\n\n\t\tif (isInFrontOf(target, attacker))\n\t\t{\n\t\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DMG_FRONT, critBonus, target, null);\n\t\t}\n\t\telse if (isBehind(target, attacker))\n\t\t{\n\t\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DMG_BEHIND, critBonus, target, null);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DMG_SIDE, critBonus, target, null);\n\t\t}\n\n\t\t// get the vulnerability for the instance due to skills (buffs, passives, toggles, etc)\n\t\tpAtk = target.calcStat(Stats.DAGGER_WPN_VULN, pAtk, target, null);\n\n\t\tdouble positionBonus = 0.0;\n\t\tif (attacker.isBehind(target))\n\t\t{\n\t\t\tpositionBonus = 0.80; // Behind bonus .20\n\t\t}\n\t\telse if (!attacker.isInFrontOf(target))\n\t\t{\n\t\t\tpositionBonus = 0.05; // Side bonus\n\t\t}\n\n\t\t// Random weapon damage\n\t\tdouble weaponRandom = attacker.getRandomDamageMultiplier();\n\n\t\tdouble finalBonus = 1;\n\t\tif (attacker instanceof L2Playable && target instanceof L2Playable)\n\t\t{\n\t\t\t// Dmg bonuses in PvP fight\n\t\t\tfinalBonus *= attacker.getPvPPhysicalSkillDamage(target);\n\t\t\t// Def bonuses in PvP fight\n\t\t\tfinalBonus /= target.getPvPPhysicalSkillDefense(attacker);\n\t\t}\n\n\t\tfinalBonus *= calcElemental(attacker, target, skill);\n\n\t\tif (target instanceof L2Attackable && !target.isRaid() && !target.isRaidMinion() &&\n\t\t\t\ttarget.getLevel() >= Config.MIN_NPC_LVL_DMG_PENALTY && attacker.getActingPlayer() != null &&\n\t\t\t\ttarget.getLevel() - attacker.getActingPlayer().getLevel() >= 2)\n\t\t{\n\t\t\tint lvlDiff = target.getLevel() - attacker.getActingPlayer().getLevel() - 1;\n\t\t\tif (lvlDiff > Config.NPC_SKILL_DMG_PENALTY.size())\n\t\t\t{\n\t\t\t\tfinalBonus *= Config.NPC_SKILL_DMG_PENALTY.get(Config.NPC_SKILL_DMG_PENALTY.size());\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tfinalBonus *= Config.NPC_SKILL_DMG_PENALTY.get(lvlDiff);\n\t\t\t}\n\t\t}\n\n\t\tif (Config.isServer(Config.TENKAI) && attacker.getActingPlayer() != null)\n\t\t{\n\t\t\tif (pAtk > 180000)\n\t\t\t{\n\t\t\t\tpAtk = 180000 + Math.pow(pAtk - 180000, 0.8);\n\t\t\t}\n\t\t\tif (critBonus > 5)\n\t\t\t{\n\t\t\t\tcritBonus = 4 + Math.pow(critBonus - 4, 0.65);\n\t\t\t}\n\t\t}\n\n\t\tdouble damage = 77.0 *\n\t\t\t\t((pAtk * levelMod + power) * weaponRandom * 0.666 * critBonus * ssBonus + critStaticBonus * 6 +\n\t\t\t\t\t\tpositionBonus * (power + pAtk * ssBonus)) / pDef * finalBonus;\n\n\t\t//System.out.println(attacker.getName());\n\t\t//System.out.println(skill.getName() + \": \" + skill.getPower() + \" | \" + positionBonus + \" | \" + finalBonus\n\t\t//\t\t+ \" | \" + ssBonus + \" | \" + critBonus + \" | \" + damage);\n\n\t\tdamage = calcCustomModifier(attacker, target, damage);\n\n\t\tif (Config.isServer(Config.TENKAI) && damage > 20000 && attacker.getActingPlayer() != null &&\n\t\t\t\ttarget.getActingPlayer() != null)\n\t\t{\n\t\t\tdamage = 20000 + Math.pow(damage - 20000, 0.93);\n\t\t}\n\n\t\tif (attacker instanceof L2PcInstance)\n\t\t{\n\t\t\tL2PcInstance player = (L2PcInstance) attacker;\n\t\t\tplayer.sendSysMessage(\n\t\t\t\t\t\"Formula = (77 * ((pAtk * levelMod + power) * weaponRandom * 0.666 * critBonus * ssBonus + critStaticBonus * 6\" +\n\t\t\t\t\t\t\t\" + positionBonus * (power + pAtk * ssBonus)) / pDef) * finalBonus\");\n\t\t\tplayer.sendSysMessage(\"P.Atk = \" + pAtk + \".\");\n\t\t\tplayer.sendSysMessage(\"Level Mod = \" + attacker.getLevelMod() + \".\");\n\t\t\tplayer.sendSysMessage(\"Power = \" + power + \".\");\n\t\t\tplayer.sendSysMessage(\"Soulshots Multiplier = \" + ssBonus + \".\");\n\t\t\tplayer.sendSysMessage(\"Final Multiplier = \" + finalBonus + \".\");\n\t\t\tplayer.sendSysMessage(\"CritDamageModifier = \" + critBonus + \".\");\n\t\t\tplayer.sendSysMessage(\"PositionBonus = \" + positionBonus + \".\");\n\t\t\t//player.sendSysMessage(\"WeaponVuln = \" + weaponVuln + \".\");\n\t\t\tplayer.sendSysMessage(\"CritDamageAdd = \" + critStaticBonus + \".\");\n\t\t\tplayer.sendSysMessage(\"Defense = \" + pDef + \".\");\n\t\t\tplayer.sendSysMessage(\".......\");\n\t\t}\n\n\t\tif (Config.isServer(Config.TENKAI) && target instanceof L2PcInstance && attacker instanceof L2PcInstance &&\n\t\t\t\tdamage > 10000 && pDef > 5000)\n\t\t{\n\t\t\tConnection con = null;\n\t\t\ttry\n\t\t\t{\n\t\t\t\tcon = L2DatabaseFactory.getInstance().getConnection();\n\t\t\t\tPreparedStatement statement = con.prepareStatement(\n\t\t\t\t\t\t\"INSERT INTO log_damage\" + \"(attacker, target, attackerClass, targetClass, damageType, \" +\n\t\t\t\t\t\t\t\t\"attack, defense, levelMod, power, powerBonus, critBonus, \" +\n\t\t\t\t\t\t\t\t\"critStaticBonus, positionBonus, ssBonus, finalBonus, damage)\" + \"VALUES\" +\n\t\t\t\t\t\t\t\t\"(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)\");\n\t\t\t\tstatement.setString(1, attacker.getName());\n\t\t\t\tstatement.setString(2, target.getName());\n\t\t\t\tstatement.setInt(3, attacker.getActingPlayer().getClassId());\n\t\t\t\tstatement.setInt(4, target.getActingPlayer().getClassId());\n\t\t\t\tstatement.setString(5, \"BLOW\");\n\t\t\t\tstatement.setDouble(6, pAtk);\n\t\t\t\tstatement.setDouble(7, pDef);\n\t\t\t\tstatement.setDouble(8, levelMod);\n\t\t\t\tstatement.setDouble(9, power);\n\t\t\t\tstatement.setDouble(10, 1);\n\t\t\t\tstatement.setDouble(11, critBonus);\n\t\t\t\tstatement.setDouble(12, critStaticBonus);\n\t\t\t\tstatement.setDouble(13, positionBonus);\n\t\t\t\tstatement.setDouble(14, ssBonus);\n\t\t\t\tstatement.setDouble(15, finalBonus);\n\t\t\t\tstatement.setDouble(16, damage);\n\t\t\t\tstatement.execute();\n\t\t\t\tstatement.close();\n\t\t\t}\n\t\t\tcatch (Exception e)\n\t\t\t{\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\tfinally\n\t\t\t{\n\t\t\t\tL2DatabaseFactory.close(con);\n\t\t\t}\n\t\t}\n\n\t\treturn damage;\n\t}", "@Override\n\tpublic float desireability() {\n\t\tAgentSpace agentSpace = Blackboard.inst().getSpace(AgentSpace.class, _obj.getName());\n\t\tMap<String,FoodEntry> map = agentSpace.getScentMemories().getFirst();\n\t\tif (map == null || map.size() == 0) { \n\t\t\t// we don't smell anything\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tAgentSpace space = Blackboard.inst().getSpace(AgentSpace.class, _obj.getName());\n\t\tBoundedEntry bounded = space.getBounded(Variable.energy);\n\t\tfloat pct = bounded.getValue() / bounded.getMax();\n\t\treturn 1 - (pct*pct);\n\t}", "public void gainExperience(Combatant opponent) { }", "@Override\n\t\tpublic void calc(Env env)\n\t\t{\n\t\t\tL2PcInstance pc = (L2PcInstance) env.player;\n\t\t\tif (pc != null)\n\t\t\t{\n\t\t\t\tenv.value += pc.getHennaStatLUC();\n\t\t\t}\n\t\t}", "public void actionCombat(Party p1) {\n System.out.println(\"______________________________________________________________________________\\n\");\n System.out.println(this.Name + \" is attacking ...\");\n int choice = (int)(Math.random() * p1.getTeam().size());\n Character target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n\n if (this.SPEED - target.getSPEED() < 5) {\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n }\n else {\n int n = 0;\n while ((target.actualHP != 0) && (n < 2)) {\n if (n == 1) {\n choice = (int)(Math.random() * p1.getTeam().size() + 1);\n target = p1.getTeam().get(choice);\n System.out.println(this.Name + \" attacks \" + target.getName() + \"!\");\n }\n int damage = Math.max(this.ATK - target.getDEF(), 0);\n System.out.println(this.Name + \" has inflicted \" + damage + \" damages to \" + target.getName() + \"!\");\n target.setActualHP(Math.max(0, target.getActualHP() - damage));\n if (target.getActualHP() == 0) {\n System.out.println(\"\\n\" + target.getName() + \" is down!\\n\");\n target.setIsDead(true);\n }\n if (n == 0) System.out.println(this.Name + \" attacks again ...\");\n n++;\n }\n }\n }", "public static double calcPhysDam(L2Character attacker, L2Character target, byte shld, boolean crit, boolean dual, double ssBonus)\n\t{\n\t\tfinal boolean isPvP = attacker instanceof L2Playable && target instanceof L2Playable;\n\t\tfinal boolean isPvE = attacker instanceof L2Playable && target instanceof L2Attackable ||\n\t\t\t\tattacker instanceof L2Attackable && target instanceof L2Playable;\n\n\t\tdouble pAtk = attacker.getPAtk(target);\n\t\tdouble pDef = target.getPDef(attacker);\n\n\t\tpAtk += calcValakasAttribute(attacker, target, null);\n\n\t\tif (attacker instanceof L2Npc)\n\t\t{\n\t\t\tif (((L2Npc) attacker)._soulshotcharged)\n\t\t\t{\n\t\t\t\tssBonus = L2ItemInstance.CHARGED_SOULSHOT;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tssBonus = L2ItemInstance.CHARGED_NONE;\n\t\t\t}\n\n\t\t\t((L2Npc) attacker)._soulshotcharged = false;\n\t\t}\n\n\t\tswitch (shld)\n\t\t{\n\t\t\tcase SHIELD_DEFENSE_SUCCEED:\n\t\t\t\tpDef += target.getShldDef();\n\t\t\t\tbreak;\n\t\t\tcase SHIELD_DEFENSE_PERFECT_BLOCK: // perfect block\n\t\t\t\treturn 1.;\n\t\t}\n\n\t\t// defence modifier depending of the attacker weapon\n\t\tL2Weapon weapon = attacker.getActiveWeaponItem();\n\t\tStats weaponStat = null;\n\t\tboolean isBow = false;\n\t\tboolean isDual = false;\n\t\tif (weapon != null && !attacker.isTransformed())\n\t\t{\n\t\t\tswitch (weapon.getItemType())\n\t\t\t{\n\t\t\t\tcase BOW:\n\t\t\t\t\tisBow = true;\n\t\t\t\t\tweaponStat = Stats.BOW_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase CROSSBOW:\n\t\t\t\tcase CROSSBOWK:\n\t\t\t\t\tisBow = true;\n\t\t\t\t\tweaponStat = Stats.CROSSBOW_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase BLUNT:\n\t\t\t\t\tweaponStat = Stats.BLUNT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUALBLUNT:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.BLUNT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DAGGER:\n\t\t\t\t\tweaponStat = Stats.DAGGER_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUAL:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.DUAL_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUALFIST:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.DUALFIST_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase ETC:\n\t\t\t\t\tweaponStat = Stats.ETC_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase FIST:\n\t\t\t\t\tweaponStat = Stats.FIST_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase POLE:\n\t\t\t\t\tweaponStat = Stats.POLE_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase SWORD:\n\t\t\t\t\tweaponStat = Stats.SWORD_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase BIGSWORD:\n\t\t\t\t\tweaponStat = Stats.BIGSWORD_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase BIGBLUNT:\n\t\t\t\t\tweaponStat = Stats.BIGBLUNT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase DUALDAGGER:\n\t\t\t\t\tisDual = true;\n\t\t\t\t\tweaponStat = Stats.DUALDAGGER_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase RAPIER:\n\t\t\t\t\tweaponStat = Stats.RAPIER_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t\tcase ANCIENTSWORD:\n\t\t\t\t\tweaponStat = Stats.ANCIENT_WPN_VULN;\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tif (isDual && ssBonus >= 2.0)\n\t\t{\n\t\t\tssBonus *= 1.02;\n\t\t}\n\n\t\t// for summon use pet weapon vuln, since they can't hold weapon\n\t\tif (attacker instanceof L2SummonInstance)\n\t\t{\n\t\t\tweaponStat = Stats.PET_WPN_VULN;\n\t\t}\n\n\t\t// Calculate the weakness to the weapon\n\t\tif (weaponStat != null)\n\t\t{\n\t\t\tpAtk = target.calcStat(weaponStat, pAtk, target, null);\n\t\t}\n\n\t\tif (target instanceof L2Npc)\n\t\t{\n\t\t\tswitch (((L2Npc) target).getTemplate().getRace())\n\t\t\t{\n\t\t\t\tcase BEAST:\n\t\t\t\t\tpAtk *= attacker.getPAtkMonsters(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase ANIMAL:\n\t\t\t\t\tpAtk *= attacker.getPAtkAnimals(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase PLANT:\n\t\t\t\t\tpAtk *= attacker.getPAtkPlants(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase DRAGON:\n\t\t\t\t\tpAtk *= attacker.getPAtkDragons(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase BUG:\n\t\t\t\t\tpAtk *= attacker.getPAtkInsects(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase GIANT:\n\t\t\t\t\tpAtk *= attacker.getPAtkGiants(target);\n\t\t\t\t\tbreak;\n\t\t\t\tcase MAGICCREATURE:\n\t\t\t\t\tpAtk *= attacker.getPAtkMagicCreatures(target);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\t// nothing\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\tdouble critBonus = 1.0;\n\t\tdouble critStaticBonus = 0.0;\n\t\tif (crit)\n\t\t{\n\t\t\tcritBonus = 2.0;\n\t\t\tpAtk = attacker.calcStat(Stats.CRITICAL_ATTACK, pAtk, target, null);\n\n\t\t\tif (isInFrontOf(target, attacker))\n\t\t\t{\n\t\t\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DMG_FRONT, critBonus, target, null);\n\t\t\t}\n\t\t\telse if (isBehind(target, attacker))\n\t\t\t{\n\t\t\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DMG_BEHIND, critBonus, target, null);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tcritBonus = attacker.calcStat(Stats.CRITICAL_DMG_SIDE, critBonus, target, null);\n\t\t\t}\n\n\t\t\tcritBonus = attacker.getPCriticalDamage(target, critBonus, null);\n\t\t\tcritStaticBonus = attacker.calcStat(Stats.CRITICAL_DAMAGE_ADD, critStaticBonus, target, null);\n\n\t\t\tcritBonus = target.calcStat(Stats.CRIT_VULN, critBonus, attacker, null);\n\t\t\tcritStaticBonus = target.calcStat(Stats.CRIT_ADD_VULN, critStaticBonus, attacker, null);\n\t\t}\n\n\t\tdouble positionBonus = 0.0;\n\t\tif (attacker.isBehind(target))\n\t\t{\n\t\t\tpositionBonus = 0.10; // Behind bonus\n\t\t}\n\t\telse if (!attacker.isInFrontOf(target))\n\t\t{\n\t\t\tpositionBonus = 0.05; // Side bonus\n\t\t}\n\n\t\t// Weapon random damage\n\t\tdouble weaponRandom = attacker.getRandomDamageMultiplier();\n\n\t\tdouble finalBonus = 1.0;\n\t\t// Dmg/def bonusses in PvP fight\n\t\tif (isPvP)\n\t\t{\n\t\t\tfinalBonus *= attacker.getPvPPhysicalDamage(target) / target.getPvPPhysicalDefense(attacker);\n\t\t}\n\n\t\tif (isPvE)\n\t\t{\n\t\t\tif (isBow)\n\t\t\t{\n\t\t\t\tfinalBonus *= attacker.calcStat(Stats.PVE_BOW_DMG, 1, target, null);\n\t\t\t}\n\n\t\t\tfinalBonus *= attacker.getPvEPhysicalDamage(target) / target.getPvEPhysicalDefense(attacker);\n\t\t}\n\n\t\t//Eviscerator damage multiplier\n\t\tif (attacker.calcStat(Stats.NORMAL_ATK_DMG, 1, target, null) > 1)\n\t\t{\n\t\t\tfinalBonus = attacker.calcStat(Stats.NORMAL_ATK_DMG, finalBonus, target, null);\n\n\t\t\t//Damage Up is a 1sec buff that should affects only one hit but we can do more hits in one sec so..\n\t\t\tL2Abnormal ab = attacker.getFirstEffect(30521);\n\t\t\tif (ab != null)\n\t\t\t{\n\t\t\t\tab.exit();\n\t\t\t}\n\t\t}\n\n\t\tfinalBonus *= calcElemental(attacker, target, null);\n\n\t\tif (target instanceof L2Attackable)\n\t\t{\n\t\t\tif (!target.isRaid() && !target.isRaidMinion() && target.getLevel() >= Config.MIN_NPC_LVL_DMG_PENALTY &&\n\t\t\t\t\tattacker.getActingPlayer() != null &&\n\t\t\t\t\ttarget.getLevel() - attacker.getActingPlayer().getLevel() >= 2)\n\t\t\t{\n\t\t\t\tint lvlDiff = target.getLevel() - attacker.getActingPlayer().getLevel() - 1;\n\t\t\t\tif (crit)\n\t\t\t\t{\n\t\t\t\t\tif (lvlDiff > Config.NPC_CRIT_DMG_PENALTY.size())\n\t\t\t\t\t{\n\t\t\t\t\t\tfinalBonus *= Config.NPC_CRIT_DMG_PENALTY.get(Config.NPC_CRIT_DMG_PENALTY.size());\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tfinalBonus *= Config.NPC_CRIT_DMG_PENALTY.get(lvlDiff);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tif (lvlDiff > Config.NPC_DMG_PENALTY.size())\n\t\t\t\t\t{\n\t\t\t\t\t\tfinalBonus *= Config.NPC_DMG_PENALTY.get(Config.NPC_DMG_PENALTY.size());\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tfinalBonus *= Config.NPC_DMG_PENALTY.get(lvlDiff);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (Config.isServer(Config.TENKAI) && attacker.getActingPlayer() != null)\n\t\t{\n\t\t\tif (pAtk > 150000)\n\t\t\t{\n\t\t\t\tpAtk = 150000 + Math.pow(pAtk - 150000, 0.85);\n\t\t\t}\n\t\t\tif (critBonus > 2)\n\t\t\t{\n\t\t\t\tcritBonus = 2 + Math.pow(critBonus - 2, 0.45);\n\t\t\t}\n\t\t}\n\n\t\tdouble damage = 100.0 * (weaponRandom * (pAtk * critBonus + pAtk * positionBonus) + critStaticBonus) / pDef *\n\t\t\t\tfinalBonus * ssBonus;\n\t\t//if (isBow)\n\t\t//\tdamage = (70.0 * ((pAtk + pAtk * critBonus) * weaponRandom + critStaticBonus + positionBonus * (pAtk + pAtk)) / pDef) * finalBonus;\n\n\t\t//System.out.println(pAtk + \" | \" + finalBonus\n\t\t//\t\t+ \" | \" + ssBonus + \" | \" + critBonus + \" | \" + damage);\n\n\t\tdamage = calcCustomModifier(attacker, target, damage);\n\n\t\tif (Config.isServer(Config.TENKAI))\n\t\t{\n\t\t\tif (attacker.getActingPlayer() != null)\n\t\t\t{\n\t\t\t\tPlayerClass attackerClass = attacker.getActingPlayer().getCurrentClass();\n\t\t\t\tif (attackerClass.getParent() != null && attackerClass.getParent().getAwakeningClassId() > 0)\n\t\t\t\t{\n\t\t\t\t\t//PHYS DAMAGES CAP\n\t\t\t\t\tint awakening = attackerClass.getParent().getAwakeningClassId();\n\t\t\t\t\tswitch (awakening)\n\t\t\t\t\t{\n\t\t\t\t\t\tcase 139: // Sigel Knight\n\t\t\t\t\t\t\tif (damage > 35000)\n\t\t\t\t\t\t\t\tdamage = 35000 + Math.pow(damage - 35000, 1);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 140: // Tyrr Warrior\n\t\t\t\t\t\t\tif (damage > 45000)\n\t\t\t\t\t\t\t\tdamage = 45000 + Math.pow(damage - 45000, 0.84);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 141: // Othell Rogue\n\t\t\t\t\t\t\tif (damage > 75000)\n\t\t\t\t\t\t\t\tdamage = 75000 + Math.pow(damage - 75000, 1);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 142: // Yul Archer\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tswitch (attackerClass.getId()) {\n\t\t\t\t\t\t\t\tcase 163: //Yull Moonlight Sentinel\n\t\t\t\t\t\t\t\t\tif (damage > 55000)\n\t\t\t\t\t\t\t\t\t\tdamage = 55000 + Math.pow(damage - 55000, 0.85); //.75\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\tdefault: //all other yullz\n\t\t\t\t\t\t\t\t\tif (damage > 65000)\n\t\t\t\t\t\t\t\t\t\tdamage = 65000 + Math.pow(damage - 65000, 0.85); //.75\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcase 143: // Feoh Wizard\n\t\t\t\t\t\t\tif (damage > 28000)\n\t\t\t\t\t\t\t\tdamage = 28000 + Math.pow(damage - 28000, 0.90);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 144: // Iss Enchanter\n\t\t\t\t\t\t\tif (damage > 35000)\n\t\t\t\t\t\t\t\tdamage = 35000 + Math.pow(damage - 35000, 0.93);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 145: // Wynn Summoner\n\t\t\t\t\t\t\tif (damage > 35000)\n\t\t\t\t\t\t\t\tdamage = 35000 + Math.pow(damage - 35000, 0.93);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 146: // Aeore Healer\n\t\t\t\t\t\t\tif (damage > 30000)\n\t\t\t\t\t\t\t\tdamage = 30000 + Math.pow(damage - 30000, 0.93);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\tdamage = 69;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 188: //Eviscerator\n\t\t\t\t\t\t\tif (damage > 85000)\n\t\t\t\t\t\t\t\tdamage = 85000 + Math.pow(damage - 85000, 0.20);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\n\t\t}\n\n\t\tint dmgCap = (int) target.getStat().calcStat(Stats.DAMAGE_CAP, 0, null, null);\n\t\tif (dmgCap > 0 && damage > dmgCap)\n\t\t{\n\t\t\tdamage = dmgCap;\n\t\t}\n\n\t\tif (damage > 0 && damage < 1)\n\t\t{\n\t\t\tdamage = 1;\n\t\t}\n\t\telse if (damage < 0)\n\t\t{\n\t\t\tdamage = 0;\n\t\t}\n\n\t\tif (Config.isServer(Config.TENKAI) && isPvP && damage > 30000 && pDef > 5000)\n\t\t{\n\t\t\tConnection con = null;\n\t\t\ttry\n\t\t\t{\n\t\t\t\tcon = L2DatabaseFactory.getInstance().getConnection();\n\t\t\t\tPreparedStatement statement = con.prepareStatement(\n\t\t\t\t\t\t\"INSERT INTO log_damage\" + \"(attacker, target, attackerClass, targetClass, damageType, \" +\n\t\t\t\t\t\t\t\t\"attack, defense, levelMod, power, powerBonus, critBonus, \" +\n\t\t\t\t\t\t\t\t\"critStaticBonus, positionBonus, ssBonus, finalBonus, damage)\" + \"VALUES\" +\n\t\t\t\t\t\t\t\t\"(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)\");\n\t\t\t\tstatement.setString(1, attacker.getName());\n\t\t\t\tstatement.setString(2, target.getName());\n\t\t\t\tstatement.setInt(3, attacker.getActingPlayer().getClassId());\n\t\t\t\tstatement.setInt(4, target.getActingPlayer().getClassId());\n\t\t\t\tstatement.setString(5, \"PHYSICAL\");\n\t\t\t\tstatement.setDouble(6, pAtk);\n\t\t\t\tstatement.setDouble(7, pDef);\n\t\t\t\tstatement.setDouble(8, 1);\n\t\t\t\tstatement.setDouble(9, 0);\n\t\t\t\tstatement.setDouble(10, 1);\n\t\t\t\tstatement.setDouble(11, critBonus);\n\t\t\t\tstatement.setDouble(12, critStaticBonus);\n\t\t\t\tstatement.setDouble(13, positionBonus);\n\t\t\t\tstatement.setDouble(14, ssBonus);\n\t\t\t\tstatement.setDouble(15, finalBonus);\n\t\t\t\tstatement.setDouble(16, damage);\n\t\t\t\tstatement.execute();\n\t\t\t\tstatement.close();\n\t\t\t}\n\t\t\tcatch (Exception e)\n\t\t\t{\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\tfinally\n\t\t\t{\n\t\t\t\tL2DatabaseFactory.close(con);\n\t\t\t}\n\t\t}\n\n\t\treturn damage;\n\t}", "@Override\n\t\tpublic void calc(Env env)\n\t\t{\n\t\t\tL2PcInstance pc = (L2PcInstance) env.player;\n\t\t\tif (pc != null)\n\t\t\t{\n\t\t\t\tenv.value += pc.getHennaStatWIT();\n\t\t\t}\n\t\t}", "int getIndividualDefense();", "public int computeRangedDamageTo(Combatant opponent) { return 0; }", "public void setLevel2Eligible(java.lang.String level2Eligible) {\r\n this.level2Eligible = level2Eligible;\r\n }", "public int getExperiencePoints() {\n return experiencePoints;\n }", "public int getExperience();", "public int getExperience() {\r\n\t\treturn experience;\r\n\t}", "private void functionalInterface2() {\n\t\tPokedex.printData(Arrays.asList(charmander));\n\n\t\tguilherme.powerUp(charmander, new BigDecimal(\"-10\"), psRestoreHp // 100\n\t\t\t\t.and(psMinimalDamage) // -10\n\t\t\t\t.and(psIncreaseHp) // +25\n\t\t\t\t.and(psMinimalDamage) // -10\n\t\t\t\t.and(psHugeDamage) // -20\n\t\t);\n\n\t\tPokedex.printData(Arrays.asList(charmander));\n\t}", "int getIndividualAttack();", "@Override\n\t\tpublic void calc(Env env)\n\t\t{\n\t\t\tL2PcInstance pc = (L2PcInstance) env.player;\n\t\t\tif (pc != null)\n\t\t\t{\n\t\t\t\tenv.value += pc.getHennaStatINT();\n\t\t\t}\n\t\t}", "public int getExperience() {\n return _experience;\n }", "protected boolean IsHighExplosive()\r\n {\r\n \t// Wrapper function to make code a little cleaner.\r\n // isInvulnerable() is wrongly named and instead represents the specific\r\n // skull type the wither has launched\r\n \t\r\n \treturn isInvulnerable();\r\n }", "public int getAttackStrength(Entity var1)\n {\n return 2;\n }", "public static Image attackPoint()\n\t{\n\t\treturn attackPoint;\n\t}", "protected Entity findPlayerToAttack() {\n/* 339 */ double var1 = 8.0D;\n/* 340 */ return getIsSummoned() ? null : this.field_70170_p.func_72890_a(this, var1);\n/* */ }", "public void calculateEffectiveness(){\n double[] typeEffective = new double[18];\n \n for(int i = 0; i < 18; i++){\n typeEffective[i] = tc.getEffectiveNumber(i, tc.convertType(type1));\n }\n \n if(type2 != null){\n for(int i = 0; i < 18; i++){\n typeEffective[i] *= tc.getEffectiveNumber(i, tc.convertType(type2));\n }\n }\n \n for(int i = 0; i < 18; i++){\n if(typeEffective[i] != 1){\n if(typeEffective[i] > 1){\n double[] newWeak = {i,typeEffective[i]};\n weak.add(newWeak);\n }else{\n double[] newStrong = {i,typeEffective[i]};\n strong.add(newStrong);\n }\n }\n }\n }", "public static double getWeaponDamage(Item weapon, Skill attStrength) {\n/* 2348 */ if (weapon.isBodyPart() && weapon.getAuxData() != 100) {\n/* */ \n/* */ try {\n/* */ \n/* 2352 */ float f = Server.getInstance().getCreature(weapon.getOwnerId()).getCombatDamage(weapon);\n/* */ \n/* 2354 */ return (f + Server.rand.nextFloat() * f * 2.0F);\n/* */ }\n/* 2356 */ catch (NoSuchCreatureException nsc) {\n/* */ \n/* 2358 */ logger.log(Level.WARNING, \"Could not find Creature owner of weapon: \" + weapon + \" due to \" + nsc.getMessage(), (Throwable)nsc);\n/* */ \n/* */ }\n/* 2361 */ catch (NoSuchPlayerException nsp) {\n/* */ \n/* 2363 */ logger.log(Level.WARNING, \"Could not find Player owner of weapon: \" + weapon + \" due to \" + nsp.getMessage(), (Throwable)nsp);\n/* */ } \n/* */ }\n/* */ \n/* */ \n/* 2368 */ float base = 6.0F;\n/* 2369 */ if (weapon.isWeaponSword()) {\n/* */ \n/* 2371 */ base = 24.0F;\n/* */ }\n/* 2373 */ else if (weapon.isWeaponAxe()) {\n/* 2374 */ base = 30.0F;\n/* 2375 */ } else if (weapon.isWeaponPierce()) {\n/* 2376 */ base = 12.0F;\n/* 2377 */ } else if (weapon.isWeaponSlash()) {\n/* 2378 */ base = 18.0F;\n/* 2379 */ } else if (weapon.isWeaponCrush()) {\n/* 2380 */ base = 36.0F;\n/* 2381 */ } else if (weapon.isBodyPart() && weapon.getAuxData() == 100) {\n/* */ \n/* 2383 */ base = 6.0F;\n/* */ } \n/* 2385 */ if (weapon.isWood()) {\n/* 2386 */ base *= 0.1F;\n/* 2387 */ } else if (weapon.isTool()) {\n/* 2388 */ base *= 0.3F;\n/* */ } \n/* 2390 */ base = (float)(base * (1.0D + attStrength.getKnowledge(0.0D) / 100.0D));\n/* */ \n/* 2392 */ float randomizer = (50.0F + Server.rand.nextFloat() * 50.0F) / 100.0F;\n/* */ \n/* 2394 */ return base + (randomizer * base * 4.0F * weapon.getQualityLevel() * weapon.getDamagePercent()) / 10000.0D;\n/* */ }", "protected Entity findPlayerToAttack()\n {\n EntityPlayer var1 = this.worldObj.getClosestVulnerablePlayerToEntity(this, 16.0D);\n return var1 != null && this.canEntityBeSeen(var1) ? var1 : null;\n }", "public int getExperience() {\n\t\treturn experience;\n\t}", "private void calcEfficiency() {\n \t\tdouble possiblePoints = 0;\n \t\tfor (int i = 0; i < fermentables.size(); i++) {\n \t\t\tFermentable m = ((Fermentable) fermentables.get(i));\n \t\t\tpossiblePoints += (m.getPppg() - 1) * m.getAmountAs(\"lb\")\n \t\t\t\t\t/ postBoilVol.getValueAs(\"gal\");\n \t\t}\n \t\tefficiency = (estOg - 1) / possiblePoints * 100;\n \t}", "@Override\n public ExperienceReport getExperienceReport() {\n int level = killsLevel + damageDealtLevel - 1;\n return new ExperienceReport(level, kills, nextUpgradeKills, (long) damageDealt,\n (long) nextUpgradeDamage);\n }", "@Override\n\t\tpublic void calc(Env env)\n\t\t{\n\t\t\tL2PcInstance pc = (L2PcInstance) env.player;\n\t\t\tif (pc != null)\n\t\t\t{\n\t\t\t\tenv.value += pc.getHennaStatMEN();\n\t\t\t}\n\t\t}", "@Override\n\tpublic boolean attackEntityFrom(DamageSource src, float par2) {\n\t\tif (isInvulnerableTo(src)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// don't just sit there!\n\t\taiSit.setSitting(false);\n\n\t\treturn super.attackEntityFrom(src, par2);\n\t}", "float getSteamSupplyRating2();", "private meterMaidPerception getPerceptions() {\n\t\t\r\n\t\tMessageTemplate mt = MessageTemplate.MatchPerformative(ACLMessage.INFORM);\r\n\t\tACLMessage msg = receive(mt);\r\n\t\tif (msg != null && msg.getContent() != null) {\r\n\t\t\tString[] perceptions = msg.getContent().split(\";\");\r\n\t\t\tif (perceptions.length < 2)\r\n\t\t\t\treturn meterMaidPerception.NOTHING_TO_SAY;\r\n\t\t\tcar = perceptions[1];\r\n\t\t\tif (CAR_PASSED_ON_RED_SIGN.equals(perceptions[0]))\r\n\t\t\t\treturn meterMaidPerception.CAR_IGNORED_RED_SIGN;\r\n\t\t\telse if (CAR_IN_ZEBRA_CROSSING.equals(perceptions[0]))\r\n\t\t\t\treturn meterMaidPerception.CAR_STOP_ON_ZEBRA_CROSSING;\r\n\t\t}\r\n\t\t\r\n\t\treturn meterMaidPerception.NOTHING_TO_SAY;\r\n\t}", "public int getHerbalismExp()\n\t{\n\t\treturn m_skillHerbExp;\n\t}", "public void CalculateXP(ArrayList<Pokemon> team, Pokemon loser){\n \tdouble a, b, L,Lp,s,t,e;\n \tint xp;\n \ta=1;\n \tif(loser.getInfo().getIsWild()==true)a=1.5;\n \tb=loser.getStats().getBaseXP();\n \tL=loser.getInfo().getLvl();\n \ts=0;\n \tfor(int i=0;i<team.size();i++){\n \t\tif(team.get(i).getInfo().getUsedInBattle()==true)s+=2;\n \t}\n \tfor(int i=0;i<team.size();i++){\n \t\tLp=team.get(i).getInfo().getLvl();\n \t\tif (user.getPlayerID()==team.get(i).getInfo().getPlayerID()) t=1;\n \t\telse t=1.5;\n \t\ts=2;\n \t\te=1;\n \t\tif(team.get(i).getInfo().getUsedInBattle()==true){\n \t\t\txp=(int)((a*t*b*e*L)/(5*s)*(L+2)/(Lp+2)+1);\n \t\t\tteam.get(i).getInfo().setXp(xp+team.get(i).getInfo().getXp());\n \t\t\tbattleMessage.add(team.get(i).getInfo().getNickname()+\" has gained \"+xp+\" experience points. \");\n \t\t\tteam.get(i).CheckLevelUp();\n \t\t}\n \t\tteam.get(i).getInfo().setUsedInBattle(false);\n \t}\n }", "public boolean gainExperience(int i) {\n boolean lvlUp = false;\n switch (i) {\n case 1:\n // if a level 1 enemy is defeated\n Experience += 1;\n // if hero levels up\n if ((LVL == 1 && Experience == 1) || (LVL == 2 && Experience == 2) || (LVL == 3 && Experience == 3)) {\n lvlUp = true;\n LVL++;\n HP.setCapacity(HP.getCapacity() + 10); // increasing health bar by 10\n Experience = 0;\n }\n break;\n case 2:\n // if a level 2 enemy is defeated\n Experience += 2;\n // if hero levels up\n if ((LVL == 2 && Experience == 2) || (LVL == 3 && Experience == 3)) {\n lvlUp = true;\n LVL++;\n HP.setCapacity(HP.getCapacity() + 10); // increasing health bar by 10\n Experience = 0;\n }\n break;\n case 3:\n // if a level 3 enemy is defeated\n Experience += 3;\n if (Experience == 3) { // if hero levels up\n lvlUp = true;\n LVL++;\n HP.setCapacity(HP.getCapacity() + 10); // increasing health bar by 10\n Experience = 0;\n }\n break;\n case 4:\n // if a level 4 enemy is defeated\n Experience += 1000;\n if (Experience >=4) { // if hero levels up\n lvlUp = true;\n LVL++;\n HP.setCapacity(HP.getCapacity() + 10); // increasing health bar by 10\n Experience = 0;\n } \n break;\n default:\n break;\n }\n HP.setHealth(HP.getCapacity()); // healing hero to full\n return lvlUp;\n }", "public static void damageStep () {\r\n // rough plan:\r\n // #1: flip defending monster, if face down -> see flipMonster(...);\r\n // #2: Ask CPU and player for possible effect negation! (For an attack negation it is too late!) -> see below in this method\r\n // #3: calculate damage, kill monsters, if needed\r\n // (consider also banishing and immunity, also copied passive effect of (Holy) Lance)\r\n // -> see makeDamageCalculation(...);\r\n // #4: decrease life points, if needed -> see isDealingBattleDamageAndContinuingGame(...);\r\n // #5: consider passive (also copied) trap monster effects -> see possibleSuicideEffect(...);\r\n // #6: display Win/Lose dialog and end match, if needed -> see Game.over(...);\r\n // #7: finally end the attack (consider the effects that happen afterwards), thus allowing the next attack -> endDamageStep(...);\r\n \r\n // about #1:\r\n if (Game.ActiveGuardingMonster.isFaceDown) {flipMonster(Game.ActiveGuardingMonster);}\r\n // about #2:\r\n if (Game.ActiveAttackingMonster.canBeNegated() || Game.ActiveGuardingMonster.canBeNegated()) {\r\n AIinterrupts.cpuIsUsingEffectNegateDuringBattlePhase(); // ask CPU to negate effects first\r\n // ask player to negate effect here\r\n boolean isCanceling = false;\r\n boolean hasEffectNegateHandTrap = Hand.lookForEffectNegateOnHand(true);\r\n boolean hasEffectNegateOnField = Hand.lookForEffectNegateOnField(true);\r\n if (hasEffectNegateHandTrap || hasEffectNegateOnField) {\r\n if (hasEffectNegateHandTrap && !hasEffectNegateOnField) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, true);\r\n }\r\n else if (!hasEffectNegateHandTrap && hasEffectNegateOnField) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, false);\r\n }\r\n else {\r\n int intDialogResult = YuGiOhJi.multipleChoiceDialog(\"Do you want to negate effects on the field?\", \"You can negate passive effects.\", new String[]{\"yes, by discarding Neutraliser\", \"yes, by paying the cost worth 1 card\", \"no (default)\"}, \"no (default)\");\r\n if (intDialogResult==0) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, true);\r\n }\r\n else if (intDialogResult==1) {\r\n isCanceling = PlayerInterrupts.playerMayNegateEffect(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster, false);\r\n }\r\n }\r\n }\r\n if (!isCanceling) {\r\n makeDamageCalculation(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster); // whole rest of battle\r\n }\r\n }\r\n else {\r\n makeDamageCalculation(Game.ActiveAttackingMonster, Game.ActiveGuardingMonster); // whole rest of battle\r\n }\r\n \r\n }", "public void addExperience(int slot, double experience) {\r\n double mod = ((slot == 0 || slot == 1 || slot == 2 || slot == 3 || slot == 4 || slot == 6 || slot == 18) ?\r\n Constants.COMBAT_EXP_MODIFIER : Constants.NON_COMBAT_EXP_MODIFIER);\r\n if (entity instanceof Player) {\r\n Player player = (Player) entity;\r\n if (player.getSavedData().getGlobalData().getExperienceModifierTime() > 0 && player.getSavedData().getGlobalData().getExperienceModifier() > 1) {\r\n mod = (mod * player.getSavedData().getGlobalData().getExperienceModifier());\r\n }\r\n }\r\n if (entity instanceof Player) {\r\n Player p = (Player) entity;\r\n p.getAntiMacroHandler().registerExperience(slot, experience);\r\n }\r\n this.experience[slot] += (experience * mod);\r\n if (this.experience[slot] > 200_000_000) {\r\n this.experience[slot] = 200_000_000;\r\n }\r\n experienceGained = experienceGained + (int) (experience * mod);\r\n int newLevel = getStaticLevelByExperience(slot);\r\n if (newLevel > staticLevels[slot]) {\r\n if (dynamicLevels[slot] < newLevel) {\r\n dynamicLevels[slot] += newLevel - staticLevels[slot];\r\n }\r\n staticLevels[slot] = newLevel;\r\n if (entity instanceof Player) {\r\n Player p = (Player) entity;\r\n if (updateCombatLevel()) {\r\n if (!p.getSavedData().getGlobalData().hasAnnouncedCombat() && p.getProperties().getCurrentCombatLevel() == Constants.MAX_COMBAT_LEVEL) {\r\n p.getSavedData().getGlobalData().setCombatAnnounced(true);\r\n p.sendGlobalNewsMessage(\"ff8c38\", \" has reached the max combat level of \" + Constants.MAX_COMBAT_LEVEL + \"!\", 5);\r\n }\r\n p.getUpdateMasks().register(new AppearanceFlag(p));\r\n }\r\n handleMilestones(p);\r\n if (getExperience(slot) == 200_000_000) {\r\n if (!p.getSavedData().getGlobalData().getExperienceMilestone(slot)) {\r\n p.getSavedData().getGlobalData().setExperienceMilestone(slot);\r\n p.sendGlobalNewsMessage(\"ff0000\", \" has just reached 200,000,000 experience in \" + TextUtils.formatDisplayName(SKILL_NAME[slot]), 6);\r\n }\r\n }\r\n LevelUp.levelUp(p, slot);\r\n }\r\n }\r\n if (entity instanceof Player) {\r\n if (entity.asPlayer().getInterfaceState().get(InterfaceConfiguration.XP_DROP_LOCK) == 0) {\r\n entity.asPlayer().getSavedData().getGlobalData().increaseXpDrops((long) (experience * mod));\r\n }\r\n PacketRepository.send(XPDrop.class, new XPDropContext((Player) entity, slot, (int) (experience * mod)));\r\n PacketRepository.send(SkillLevel.class, new SkillContext((Player) entity, slot));\r\n }\r\n }", "public static int calcAtkSpd(L2Character attacker, L2Skill skill, double skillTime)\n\t{\n\t\tdouble atkSpd;\n\t\tif (skill.isMagic())\n\t\t{\n\t\t\tatkSpd = attacker.getMAtkSpd();\n\t\t}\n\t\telse\n\t\t{\n\t\t\tatkSpd = attacker.getPAtkSpd();\n\t\t}\n\n\t\treturn (int) (skillTime * 333 / atkSpd);\n\t}", "protected void processOffensive(World myWorld,\n\t\t\tArrayList<World> worldsInRange) {\n\t\tTreeSet<World> enemies = new TreeSet<World>(World.enemyComparator);\n\t\tTreeSet<World> allies = new TreeSet<World>(World.allyComparator);\n\t\tWorld victim = null;\n\t\tint neutralCount = 0;\n\n\t\tfor (World w : worldsInRange) {\n\t\t\tif (w.getPower() <= myWorld.getPower()) {\n\t\t\t\tswitch (w.getMode()) {\n\t\t\t\tcase OFFENSIVE:\n\t\t\t\t\tif (w.getOwner() == this) {\n\t\t\t\t\t\tallies.add(w);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tenemies.add(w);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase DEFENSIVE:\n\t\t\t\t\t// Offensive avoids attacking defensive without\n\t\t\t\t\t// advantage\n\t\t\t\t\tif (w.getOwner() != this\n\t\t\t\t\t\t\t&& (w.getPower() <= 0.5 * myWorld.getPower() || myWorld\n\t\t\t\t\t\t\t\t\t.getPower() == 100)) {\n\t\t\t\t\t\tenemies.add(w);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase EXPLORATIVE:\n\t\t\t\t\tif (w.getOwner() != this) {\n\t\t\t\t\t\tenemies.add(w);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase NEUTRAL:\n\t\t\t\t\tif (w.getOwner() != this) {\n\t\t\t\t\t\tneutralCount++;\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Attack the highest priority victim\n\t\tif (!enemies.isEmpty()) {\n\t\t\tvictim = enemies.first();\n\t\t\t// One Offensive can't defeat a Defensive, so prefer to explore\n\t\t\t// rather than attack defensive 50% of the time\n\t\t\tif (neutralCount > 0 && victim.getMode() == WorldMode.DEFENSIVE\n\t\t\t\t\t&& rand.nextInt(100) < 50) {\n\t\t\t\tmyWorld.setMode(WorldMode.EXPLORATIVE);\n\t\t\t} else {\n\t\t\t\tWorld.initializeAttack(myWorld, victim);\n\t\t\t}\n\n\t\t} else if (myWorld.getPower() == 100 && neutralCount > 0\n\t\t\t\t&& rand.nextInt(100) < 25) {\n\t\t\t// If there's nothing to attack but worlds to claim, change to\n\t\t\t// explorative, but leave chance to stay offensive for transfers\n\t\t\tmyWorld.setMode(WorldMode.EXPLORATIVE);\n\t\t}\n\n\t\tprocessTransfers(myWorld, allies);\n\t}", "public void attack() {\n energy = 2;\n redBull = 0;\n gun = 0;\n target = 1;\n // if Player is in range take off a life.\n if (CharacterTask.ghostLocation == GameWindow.playerLocation) {\n playerLives = playerLives - 1;\n System.out.println(\"Player Lives: \" + playerLives);\n }\n }", "public Entity getDamageDealer();", "int getAttackStatStage();", "public Integer getOpponentAttacks()\n\t{\n\t\treturn opponentAttacks;\n\t}", "public int getDamageVsEntity(Entity var1)\r\n {\r\n return this.weaponDamage;\r\n }", "Float attack();", "@Override\n public boolean attack(Player attacker, int mode1, int[] mode2, Player[] attackedPlayers, Position[] movements, PowerupCard[] payment) {\n boolean done = false;\n if(isLoaded() && attackedPlayers.length>=1 && attacker.getPosition().reachable(attackedPlayers[0].getPosition())){\n if(mode1==0 && attackedPlayers.length==1){\n attackedPlayers[0].receivedDamages(attacker);\n attackedPlayers[0].setMarksReceived(attacker,2);\n attacker.setMarksGiven(attackedPlayers[0],2);\n attacker.setPosition(attackedPlayers[0].getPosition());\n loaded=false;\n done=true;\n }else if(mode1==1){\n if(attackedPlayers.length==1 && isPaid(attacker, payment)){\n for(int i=0; i<2; i++)\n attackedPlayers[0].receivedDamages(attacker);\n attacker.setPosition(attackedPlayers[0].getPosition());\n loaded=false;\n done=true;\n }else if(attackedPlayers.length==2 && attackedPlayers[0].getPosition().reachable(attackedPlayers[1].getPosition()) && isPaid(attacker, payment)){\n boolean sameValueOfX = attacker.getPosition().getCoordinate()[0] == attackedPlayers[1].getPosition().getCoordinate()[0];\n boolean sameValueOfY = attacker.getPosition().getCoordinate()[1] == attackedPlayers[1].getPosition().getCoordinate()[1];\n boolean sameDirection = (sameValueOfX || sameValueOfY) && attacker.getPosition() != attackedPlayers[1].getPosition();\n if(sameDirection){\n for (int i = 0; i < 2; i++) {\n attackedPlayers[i].receivedDamages(attacker);\n attackedPlayers[i].receivedDamages(attacker);\n }\n attacker.setPosition(attackedPlayers[1].getPosition());\n loaded = false;\n done = true;\n }\n }\n }\n }\n return done;\n }", "@Override\n\t\tpublic void calc(Env env)\n\t\t{\n\t\t\tL2PcInstance pc = (L2PcInstance) env.player;\n\t\t\tif (pc != null)\n\t\t\t{\n\t\t\t\tenv.value += pc.getHennaStatSTR();\n\t\t\t}\n\t\t}", "int getDamage();", "int getDamage();", "int getDamage();", "int getDamage();", "int getDamage();", "public nl.webservices.www.soap.GCRLiabilities getLiabilities() {\n return liabilities;\n }", "public int getPointsP2() {\r\n\r\n pointsP2 = pointsP + getPointsPlayer3();\r\n\r\n if (pointsP2 >= 10) {\r\n pointsP2 -= 10;\r\n }\r\n return pointsP2;\r\n }", "public int getExperienceForLevel(int level) {\r\n int points = 0;\r\n int output = 0;\r\n for (int lvl = 1; lvl <= level; lvl++) {\r\n points += Math.floor(lvl + 300.0 * Math.pow(2.0, lvl / 7.0));\r\n if (lvl >= level) {\r\n return output;\r\n }\r\n output = (int) Math.floor(points / 4);\r\n }\r\n return 0;\r\n }", "public int getExperienceGained() {\r\n return experienceGained;\r\n }", "public void addDamageHate(final L2Character attacker, final int damage, int aggro)\n\t{\n\t\tif (attacker == null /* || aggroList == null */)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Get the AggroInfo of the attacker L2Character from the aggroList of the L2Attackable\n\t\tAggroInfoHolder ai = getAggroListRP().get(attacker);\n\t\t\n\t\tif (ai == null)\n\t\t{\n\t\t\tai = new AggroInfoHolder(attacker);\n\t\t\tai.init();\n\t\t\tgetAggroListRP().put(attacker, ai);\n\t\t}\n\t\t\n\t\t// If aggro is negative, its comming from SEE_SPELL, buffs use constant 150\n\t\tif (aggro < 0)\n\t\t{\n\t\t\tai.decHate(aggro * 150 / (getLevel() + 7));\n\t\t\taggro = -aggro;\n\t\t}\n\t\t// if damage == 0 -> this is case of adding only to aggro list, dont apply formula on it\n\t\telse if (damage == 0)\n\t\t{\n\t\t\tai.incHate(aggro);\n\t\t\t// else its damage that must be added using constant 100\n\t\t}\n\t\telse\n\t\t{\n\t\t\tai.incHate(aggro * 100 / (getLevel() + 7));\n\t\t}\n\t\t\n\t\t// Add new damage and aggro (=damage) to the AggroInfo object\n\t\tai.incDmg(damage);\n\t\t\n\t\t// Set the intention to the L2Attackable to AI_INTENTION_ACTIVE\n\t\tif (getAI() != null && aggro > 0 && getAI().getIntention() == CtrlIntention.AI_INTENTION_IDLE)\n\t\t{\n\t\t\tgetAI().setIntention(CtrlIntention.AI_INTENTION_ACTIVE);\n\t\t}\n\t\t\n\t\tai = null;\n\t\t// Notify the L2Attackable AI with EVT_ATTACKED\n\t\tif (damage > 0)\n\t\t{\n\t\t\tif (getAI() != null)\n\t\t\t{\n\t\t\t\tgetAI().notifyEvent(CtrlEvent.EVT_ATTACKED, attacker);\n\t\t\t}\n\t\t\t\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif (attacker instanceof L2PcInstance || attacker instanceof L2Summon)\n\t\t\t\t{\n\t\t\t\t\tL2PcInstance player = attacker instanceof L2PcInstance ? (L2PcInstance) attacker : ((L2Summon) attacker).getOwner();\n\t\t\t\t\t\n\t\t\t\t\tfor (final Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_ATTACK))\n\t\t\t\t\t{\n\t\t\t\t\t\tquest.notifyAttack(this, player, damage, attacker instanceof L2Summon);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tplayer = null;\n\t\t\t\t}\n\t\t\t}\n\t\t\tcatch (final Exception e)\n\t\t\t{\n\t\t\t\tLOGGER.error(\"\", e);\n\t\t\t}\n\t\t}\n\t}", "private int heavyAttack() {\n return attack(6, 2);\n }", "@Override\n\tpublic int calculateAttackType(Entity attacker, Entity defender) {\n\t\tif (attacker.getType() != EntityType.NPC || defender.getType() != EntityType.PLAYER) {\n\t\t\treturn ServerConstants.MELEE_ICON;\n\t\t}\n\t\tNpc attackerAsNpc = (Npc) attacker;\n\n\t\tint randomChanceOfAttack = ThreadLocalRandom.current().nextInt(0, 100);\n\n\t\tif (phase == AbyssalSirePhase.AWAKE) {\n\t\t\tif (randomChanceOfAttack <= 80 || spawns.stream().filter(n -> n != null && !n.isDead()).count() >= 2) {\n\t\t\t\tattack = AbyssalSireAttack.POISON;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.SPAWN;\n\t\t\t}\n\t\t} else if (phase == AbyssalSirePhase.MELEE_COMBAT) {\n\t\t\tif (randomChanceOfAttack <= 50) {\n\t\t\t\tattack = AbyssalSireAttack.SWIPE;\n\t\t\t} else if (randomChanceOfAttack <= 85) {\n\t\t\t\tattack = AbyssalSireAttack.TENDRIL_SWIPE;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.DOUBLE_TENDRIL_SWIPE;\n\t\t\t}\n\t\t} else if (phase == AbyssalSirePhase.MAGIC_COMBAT) {\n\t\t\tif (explosionState == AbyssalSireExplosionState.NONE && attackerAsNpc.getCurrentHitPoints() <= 139) {\n\t\t\t\tattack = AbyssalSireAttack.PORTAL;\n\t\t\t} else {\n\t\t\t\tattack = AbyssalSireAttack.POISON;\n\t\t\t}\n\t\t}\n\t\treturn ServerConstants.MELEE_ICON;\n\t}", "int getMinigameDefenseChancesLeft();", "private double individualEvaluation() {\n\t\t//System.out.println(\"indE\"+ myValues.get(myAction.getPurpose()).getStrength(null));\n\t\treturn myValues.get(myAction.getPurpose()).getStrength(null);\n\t}", "public void abilityTwo() {\n if(map.getCurrentTurnHero().getAbilities().size() < 2){\n return;\n }\n ability(map.getCurrentTurnHero().getAbilities().get(1));\n }", "public int getCraftingExp()\n\t{\n\t\treturn m_skillCraftExp;\n\t}", "public LevelExperience getLevelExperience() {\n return levelExperience;\n }", "float getBonusExp();", "public void doOffensiveMicro(RobotInfo[] engageableEnemies, MapLocation rallyPoint) throws GameActionException {\n\n if (engageableEnemies.length > 0) {\n // returns {is winning, is lowest health and not alone}\n int[] metrics = getBattleMetrics(engageableEnemies);\n if (metrics[0] > 0) {\n //rc.setIndicatorString(1, \"winning...\" + Clock.getRoundNum());\n\n if (metrics[1] != -1 || metrics[2] != -1) {\n Messaging.setBattleFront(new MapLocation(metrics[1], metrics[2]));\n }\n MapLocation nearestBattle = Messaging.getClosestBattleFront(rc.getLocation());\n RobotInfo[] attackableEnemies = Cache.getAttackableEnemies();\n if (attackableEnemies.length > 0) {\n if (rc.isWeaponReady()) {\n attackLeastHealthPrioritized(attackableEnemies);\n }\n } else {\n if (metrics[1] != -1 || metrics[2] != -1) {\n if (nearestBattle != null && nearestBattle.distanceSquaredTo(rc.getLocation()) <= 50) {\n //rc.setIndicatorString(1, \"Going to battlefront: \" + nearestBattle + \", \" + Clock.getRoundNum());\n Nav.goTo(nearestBattle, Engage.UNITS);\n } else {\n Nav.goTo(rallyPoint, Engage.NONE);\n }\n }\n }\n } else {\n // \"are we definitely going to die?\"\n if (metrics[1] > 0) {\n SupplyDistribution.setDyingMode();\n SupplyDistribution.manageSupply();\n if (rc.isWeaponReady()) {\n attackLeastHealthPrioritized(Cache.getAttackableEnemies());\n }\n \n // Retreat\n } else {\n if (rc.isCoreReady()) {\n int[] attackingEnemyDirs = calculateNumAttackingEnemyDirs();\n Nav.retreat(attackingEnemyDirs);\n }\n }\n }\n } else {\n if (rc.isCoreReady()) {\n MapLocation nearestBattle = Messaging.getClosestBattleFront(curLoc);\n if (nearestBattle != null ) {\n //rc.setIndicatorString(1, \"Going to battlefront: \" + nearestBattle + \", \" + Clock.getRoundNum());\n Nav.goTo(nearestBattle, Engage.UNITS);\n } else if (rallyPoint != null) {\n Nav.goTo(rallyPoint, Engage.NONE);\n }\n }\n }\n }", "public void addExperienceNoMod(int slot, double experience) {\r\n this.experience[slot] += (experience);\r\n if (this.experience[slot] > 200_000_000) {\r\n this.experience[slot] = 200_000_000;\r\n }\r\n experienceGained = experienceGained + (int) (experience);\r\n int newLevel = getStaticLevelByExperience(slot);\r\n if (newLevel > staticLevels[slot]) {\r\n if (dynamicLevels[slot] < newLevel) {\r\n dynamicLevels[slot] += newLevel - staticLevels[slot];\r\n }\r\n if (slot == HITPOINTS) {\r\n lifepoints += newLevel - staticLevels[slot];\r\n }\r\n staticLevels[slot] = newLevel;\r\n if (entity instanceof Player) {\r\n Player p = (Player) entity;\r\n if (updateCombatLevel()) {\r\n if (!p.getSavedData().getGlobalData().hasAnnouncedCombat() && p.getProperties().getCurrentCombatLevel() == Constants.MAX_COMBAT_LEVEL) {\r\n p.getSavedData().getGlobalData().setCombatAnnounced(true);\r\n p.sendGlobalNewsMessage(\"ff8c38\", \" has reached the max combat level of \" + Constants.MAX_COMBAT_LEVEL + \"!\", 5);\r\n }\r\n p.getUpdateMasks().register(new AppearanceFlag(p));\r\n }\r\n handleMilestones(p);\r\n if (getExperience(slot) == 200_000_000) {\r\n if (!p.getSavedData().getGlobalData().getExperienceMilestone(slot)) {\r\n p.getSavedData().getGlobalData().setExperienceMilestone(slot);\r\n p.sendGlobalNewsMessage(\"ff0000\", \" has just reached 200,000,000 experience in \" + TextUtils.formatDisplayName(SKILL_NAME[slot]), 6);\r\n }\r\n }\r\n LevelUp.levelUp(p, slot);\r\n }\r\n }\r\n if (entity instanceof Player) {\r\n if (entity.asPlayer().getInterfaceState().get(InterfaceConfiguration.XP_DROP_LOCK) == 0) {\r\n entity.asPlayer().getSavedData().getGlobalData().increaseXpDrops((long) experience);\r\n }\r\n PacketRepository.send(XPDrop.class, new XPDropContext((Player) entity, slot, (int) experience));\r\n PacketRepository.send(SkillLevel.class, new SkillContext((Player) entity, slot));\r\n }\r\n }", "int getDefense();", "int getDefense();", "int getDefense();", "int getDefense();", "int getDefense();", "int getDefense();", "public int getAttackStrength(Entity par1Entity)\n {\n ItemStack var2 = this.getHeldItem();\n int var3 = 5;\n\n\n return var3;\n }" ]
[ "0.5578145", "0.5419452", "0.5185114", "0.51287323", "0.51254195", "0.5104775", "0.5071988", "0.5060231", "0.5028599", "0.5009802", "0.495497", "0.4950991", "0.494645", "0.49440795", "0.49396473", "0.49135995", "0.4904655", "0.48987237", "0.4881772", "0.48754528", "0.48670587", "0.48594692", "0.48572475", "0.48555145", "0.48546773", "0.48423904", "0.481491", "0.48134553", "0.4807876", "0.48018545", "0.480015", "0.47749004", "0.47739002", "0.47688904", "0.47649753", "0.47467828", "0.47442782", "0.47418135", "0.47326517", "0.4729547", "0.47262326", "0.47197714", "0.47124034", "0.47122893", "0.47090584", "0.47077954", "0.4695064", "0.4690973", "0.46858802", "0.46562332", "0.46505433", "0.46495402", "0.46473542", "0.4646696", "0.46457493", "0.46450302", "0.46388215", "0.4636311", "0.46290743", "0.4628503", "0.46176606", "0.46160588", "0.4615675", "0.46031433", "0.45971957", "0.4596188", "0.45961508", "0.45955792", "0.45912442", "0.45834783", "0.45799387", "0.45773652", "0.45727602", "0.45688444", "0.45688444", "0.45688444", "0.45688444", "0.45688444", "0.45684284", "0.45660797", "0.45538932", "0.45478067", "0.45450112", "0.45270792", "0.4523815", "0.45200035", "0.4519981", "0.4518909", "0.45166102", "0.451376", "0.45117065", "0.45098677", "0.45095187", "0.450721", "0.450721", "0.450721", "0.450721", "0.450721", "0.450721", "0.44978508" ]
0.53946805
2
Get the percentage based on the total of extra (overhit) damage done relative to the total (maximum) ammount of HP on the L2Attackable
public long calculateOverhitExp(final long normalExp) { double overhitPercentage = getOverhitDamage() * 100 / getMaxHp(); // Over-hit damage percentages are limited to 25% max if (overhitPercentage > 25) { overhitPercentage = 25; } // Get the overhit exp bonus according to the above over-hit damage percentage // (1/1 basis - 13% of over-hit damage, 13% of extra exp is given, and so on...) final double overhitExp = overhitPercentage / 100 * normalExp; // Return the rounded ammount of exp points to be added to the player's normal exp reward final long bonusOverhit = Math.round(overhitExp); return bonusOverhit; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "float getBonusPercentHP();", "public double calculateHpPercent();", "float getPercentHealth();", "public int computeDamageTo(Combatant opponent) { return 0; }", "public double getHitsPercentual()\n\t{\n\t\t//Convert int to double values\n\t\tdouble doubleHits = hits;\n\t\tdouble doubleTotalProcessedStops = totalProcessedStops;\n\t\t\n\t\t//Hits percentual obtained by Jsprit algorithm\n\t\treturn Math.round(100 * (doubleHits / doubleTotalProcessedStops));\n\t}", "public int computeRangedDamageTo(Combatant opponent) { return 0; }", "public float getBonusPercentHP() {\n return bonusPercentHP_;\n }", "public int attack()\n {\n int percent = Randomizer.nextInt(100) + 1;\n int baseDamage = super.attack();\n if(percent <= 5)\n {\n baseDamage *= 2;\n baseDamage += 50;\n }\n return baseDamage;\n }", "public float getBonusPercentHP() {\n return bonusPercentHP_;\n }", "int getBonusHP();", "private void calculateDamage() {\n this.baseDamage = this.actualBaseDamage;\n this.applyPowers();\n this.baseDamage = Math.max(this.baseDamage - ((this.baseDamage * this.otherCardsPlayed) / this.magicNumber), 0);\n }", "private int calculateTotalDamage(double baseAttack, double moveDamage, int totalHealth, double statBonus) {\n\t\tint totalDamage = 0;\n\t\tRandom rand = new Random();\n\t\tfloat accuracy = rand.nextFloat();\n\t\t\n\t\ttotalDamage = (int) Math.round(((double) totalHealth) * ((baseAttack*statBonus) + moveDamage) * ((double) accuracy));\n\t\t\n\t\treturn totalDamage;\n\t}", "public int calculateDamage(Player enemyPlayer)\n\t{\n\t\tint damage = 0;\n\t\tPokemon enemyPokemon = enemyPlayer.getActivePokemon();\n\t\tif(enemyPokemon.getClass() == FirePokemon.class)\n\t\t{\n\t\t\tdamage = move.getBaseDamage() * 2;\n\t\t}\n\t\tif(enemyPokemon.getClass() == GrassPokemon.class)\n\t\t{\n\t\t\tdamage = (int)Math.round((move.getBaseDamage() * .5));\n\t\t}\n\t\tif(enemyPokemon.getClass() == WaterPokemon.class)\n\t\t{\n\t\t\tdamage = move.getBaseDamage();\n\t\t}\n\t\treturn damage;\n\t}", "@Override\n public double calculatePercentageExtra() {\n double percentageExtra = 0;\n \n percentageExtra += getTwoColourCost();\n \n if(getChemicalResistance()) {\n percentageExtra += getChemicalResistanceCost();\n }\n \n return percentageExtra;\n }", "public double getEfficiencyPercentual()\n\t{\n\t\t//Difference from Jsprit algorithm path cost and transport service provider path cost\n\t\tdouble difference = algBestPathDistance - providerBestPathDistance;\n\t\t\n\t\t//Efficiency percentual obtained by Jsprit algorithm\n\t\treturn Math.round(100 * (1 - difference / providerBestPathDistance));\n\t}", "int getPercentageHeated();", "public int calculateAttack() {\n int attack = 0;\n for (Weapon w : equippedWeapons) {\n attack += w.getType().getDamage();\n }\n return attack;\n }", "Float getFedAnimalsPercentage();", "public int getDamage() {\n \t\treturn damage + ((int) 0.5*level);\n \t}", "public int getWeaponDamage() {\n return Math.round(type.getWeaponDamage()*type.getItemLevelMultipliers()\n\t\t\t\t[level - 1]);\n }", "public abstract double getPercentDead();", "public double getPlayerFullHP();", "@Override\n\tpublic int calculateDamage() \n\t{\n\t\t// TODO Auto-generated method stub\n\t\treturn 0;\n\t}", "public void heal(){\n\t\thp += potion.getHpBoost();\n\t\tif(hp > max_hp)hp = max_hp;\n\t}", "public double damageCalculation(Player player, NPC mob) {\r\n double weapon = player.getWeapon().getDamage();\r\n double attack = player.getStats().getAttack();\r\n double defence = mob.getStats().getDefence();\r\n double critMulti = 1;\r\n\r\n// Chance chance = new Chance(player.getLevel(), player.getStats().getDexterity(), player.getCharacterClass());\r\n Chance chance = new Chance(player.getStats().getCritChance());\r\n boolean crit = chance.getSuccess();\r\n\r\n if (crit) {\r\n critMulti = 2;\r\n System.out.println(\"CRIT!\");\r\n } else {\r\n// System.out.println(\"No crit\");\r\n }\r\n\r\n return ((weapon + attack) * 2 - defence) * critMulti;\r\n }", "@Override\n\tpublic int getMetricInternal() {\n// Util.runToAddressNoLimit(0, 0, 0x3d702, 0x3e77f);\n// missed_ = curGb.readMemory(curGb.pokemon.fightAttackMissedAddress);\n// System.out.println(\"missed: \" + missed_);\n\n\t\tEflUtil.runToAddressNoLimit(0, 0, curGb.pokemon.fightBattleCommand0a);\n\t\tint crit = curGb.readMemory(curGb.pokemon.fightCriticalHitAddress);\n\t\tint missed = curGb.readMemory(curGb.pokemon.fightAttackMissedAddress);\n//\t\tSystem.out.println(\"EflCheckMoveDamage crit: \" + crit + \" missed: \" + missed);\n\t\tif (missed != 0 || criticalHit != (crit != 0))\n\t\t return Integer.MIN_VALUE;\n\t\tif (thrashAdditionalTurns > 0 && curGb.readMemory(curGb.pokemon.thrashNumTurnsAddress) < thrashAdditionalTurns) {\n\t\t\tSystem.out.println(\"caught bad thrash \"+ curGb.readMemory(curGb.pokemon.thrashNumTurnsAddress));\n return Integer.MIN_VALUE;\n\t\t}\n\t\tif (PokemonUtil.isGen2()) {\n\t\t\tint effectMissed = curGb.readMemory(curGb.pokemon.fightEffectMissedAddress);\n\t\t\tif (this.effectMiss != (effectMissed != 0))\n\t\t\t return Integer.MIN_VALUE;\n\t\t}\n\t\tint dmg = Util.getMemoryWordBE(curGb.pokemon.fightCurDamageAddress);\n// System.out.println(\"EflCheckMoveDamage dmg: \" + dmg);\n\t\tif (dmg < minDamage || dmg > maxDamage)\n return Integer.MIN_VALUE;\n//\t\t\tSystem.out.println(crit+\" \"+missed+\" \"+effectMissed+\" \"+dmg);\n//\t\tSystem.out.println(\"atk: \"+atk+\", def: \"+def+\", pow: \"+pow+\", lvl: \"+lvl);\n//\t\tSystem.out.println(\"max damage: \"+maxdmg+\", dmg: \"+dmg);\n\t\treturn negateOutputDamage ? -dmg : dmg;\n\t}", "private double calcScorePercent() {\n\t\tdouble adjustedLab = totalPP * labWeight;\n\t\tdouble adjustedProj = totalPP * projWeight;\n\t\tdouble adjustedExam = totalPP * examWeight;\n\t\tdouble adjustedCodeLab = totalPP * codeLabWeight;\n\t\tdouble adjustedFinal = totalPP * finalWeight;\n\n\t\tlabScore = (labScore / labPP) * adjustedLab;\n\t\tprojScore = (projScore / projPP) * adjustedProj;\n\t\texamScore = (examScore / examPP) * adjustedExam;\n\t\tcodeLabScore = (codeLabScore / codeLabPP) * adjustedCodeLab;\n\t\tfinalExamScore = (finalExamScore / finalExamPP) * adjustedFinal;\n\n//\t\tdouble labPercent = labScore / adjustedLab;\n//\t\tdouble projPercent = projScore / adjustedProj;\n//\t\tdouble examPercent = examScore / adjustedExam;\n//\t\tdouble codeLabPercent = codeLabScore / adjustedCodeLab;\n//\t\tdouble finalPercent = finalExamScore / adjustedFinal;\n\n\t\tdouble totalPercent = (labScore + projScore + examScore + codeLabScore + finalExamScore) / totalPP;\n\t\t\n\t\tscorePercent = totalPercent;\n\t\t\n\t\treturn totalPercent;\n\t}", "public double getOverhitDamage()\n\t{\n\t\treturn overhitDamage;\n\t}", "public int getHealthCost();", "public double damageCalculation(NPC mob, Player player) {\r\n double weapon = mob.getWeapon().getDamage();\r\n double attack = mob.getStats().getAttack();\r\n double defence = player.getStats().getDefence();\r\n\r\n return ((weapon + attack) * 2 - defence);\r\n }", "public int getManaIncreasePerLevel() {\r\n if (_index == 3 || _index == 11 || _index == 6 || _index == 14) {\r\n // Acolytes, High Priests, Druids, or High Druids\r\n return 1;\r\n } else if (isSpellCaster()) {\r\n return 2;\r\n }\r\n return 0;\r\n }", "@Override\n\tpublic float desireability() {\n\t\tAgentSpace agentSpace = Blackboard.inst().getSpace(AgentSpace.class, _obj.getName());\n\t\tMap<String,FoodEntry> map = agentSpace.getScentMemories().getFirst();\n\t\tif (map == null || map.size() == 0) { \n\t\t\t// we don't smell anything\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\tAgentSpace space = Blackboard.inst().getSpace(AgentSpace.class, _obj.getName());\n\t\tBoundedEntry bounded = space.getBounded(Variable.energy);\n\t\tfloat pct = bounded.getValue() / bounded.getMax();\n\t\treturn 1 - (pct*pct);\n\t}", "int getSuperEffectiveChargeAttacksUsed();", "public double getPercentRem(){\n return ((double)freeSpace / (double)totalSpace) * 100d;\n }", "public int getPercentage() {\r\n\r\n\t\treturn (getAmount() - offeredQuantity) / 100;\r\n\r\n\t}", "@Override\n public int getEffectiveDamage(Hero hero){\n return (hero.getDex() + hero.getBonusDex()) * 2 + this.damage;\n }", "public double getHealthRelative() {\n\t\treturn getHealth() / (double) getMaxHealth();\n\t}", "public double getAccuracy(){\n return (numOfHits/numOfGuesses);\n }", "int getHPPerSecond();", "@Override\n public double getDamageAmount() {\n return this.getStrength().getAbilityValue();\n }", "public int getMaxHealth() {\n \t\treturn (int)(maxHealthModifier + (stamina/2 + strength/4)*Math.PI);\n \t}", "private static int playerDamageDealt(int playerAttack, int monsterDefense){\r\n int playerDamageDealt;\r\n playerDamageDealt = (playerAttack - monsterDefense);\r\n return playerDamageDealt;\r\n }", "@Override\n public int viability() {\n int[] newStats = getNewStats();\n return newStats[0] * newStats[1];\n }", "public static double getPercentage(int score, int max){\n\t\treturn (double)score /(double)max*100;\n\t}", "@Override\n public void attackedByPaladin(double attack) {\n this.attack += (2 * attack) / 3;\n damageCounter = Math.max(damageCounter - (2 * attack) / 3, 0);\n }", "public float getHungerDamage();", "public double getOccupancyPercentage() throws SQLException {\n\t\tdouble result = (double) getOccupancy() / getMaxOccupancy() * 100;\n\t\tresult = Math.round (result * 100.0) / 100.0; \n\t\treturn result;\n\t}", "public int totalWorth() {\n\t\tint val = 0;\n\t\tfor (Card c : cards) {\n\t\t\tval += c.value();\n\t\t}\n\t\treturn val;\n\t}", "public int getMaxHealth();", "private int calculateHeroDamageDone(Hero h, GenericMonster m){\n\t\t// Take into account armor, magic resist, thoughness, that kind of thing..\n\t\thDmg = h.getWeapon().calculateDamageDelt();\n\t\tcalcDef = new CalculateDefence(h.getWeapon(), m);\n\t\tint def = calcDef.getMonsterDefense();\n\t\t// Getting the defense value and type\n\t\tmResistance = calcDef.getMonsterDefType();\n\t\tmResistanceValue = calcDef.getMonsterDefValue();\n\t\treturn (hDmg - def);\n\t}", "public void takeDamage(int damage) {\n Random rand = new Random();\n int game = rand.nextInt(51) + 75;\n double game2 = (double) game;\n double percDamage = game2/100.0;\n double realSomething = (double) damage;\n double actualDamageNotReal = realSomething * percDamage;\n int actualDamage = (int) actualDamageNotReal;\n int actualDmg = actualDamage - this.armour;\n if (actualDmg <= 0){\n actualDmg = 0;\n }\n this.health -= actualDmg;\n slowDisplay(String.format(\"%s takes %s damage, now at %s\\n\",this.name,actualDmg,this.health));\n\n }", "public double progress() {\n if (damage <= 0) {\n return damage;\n }\n double n = noise.nextValue();\n damage = damage + (k * damage * damage) + l + n;\n return damage;\n }", "public int getHealthGain();", "@Override\n public int doDamage() {\n if (difficulty <5)\n return damage;\n else \n return damage*2;\n }", "public static Integer getAchievementsPercentage(Player p) {\n\n\t\tint NumberOfAch = 0;\n\t\tint NumberCompleted = 0;\n\n\t\tfor(Achievements ach : Achievements.values()) {\n\t\t\tNumberOfAch += 1;\n\t\t\tif(PlayerConfig.hasAchivement(p, ach))\n\t\t\t{\n\t\t\t\tNumberCompleted += 1;\n\t\t\t}\n\t\t}\n\t\tint percent = (int)((NumberCompleted * 100.0f) / NumberOfAch);\n\n\t\treturn percent;\n\t}", "public int getDamage () {\n\t\treturn (this.puissance + stuff.getDegat());\n\t}", "Float getHealth();", "private static int monsterDamageDealt(int monsterAttack, int playerDefense){\r\n int monsterDamageDealt;\r\n monsterDamageDealt = (monsterAttack - playerDefense);\r\n if(monsterDamageDealt < 0){\r\n monsterDamageDealt = 0;\r\n return monsterDamageDealt;\r\n }else{\r\n return monsterDamageDealt;\r\n }\r\n }", "public int calculate_maximum_HP(int level, int mod_from_race) {\n return (level * die_type) + class_hp_mod + mod_from_race;\n }", "public int applyEnemyDamage(BasicEnemy enemy) {\n int enemyDamage = enemy.getDamage();\n boolean enemyCrit = enemy.rollCrit();\n int damageDealt;\n if (enemyCrit) damageDealt = (int)(3 * enemyDamage * getTotalDefenceMultiplier(enemy.getIsBoss()) * getTotalCritDefenceMultiplier());\n else damageDealt = (int)(enemyDamage * this.getTotalDefenceMultiplier(enemy.getIsBoss()));\n this.setHealth(Math.max(0, this.health - damageDealt));\n return health;\n }", "int getDamage();", "int getDamage();", "int getDamage();", "int getDamage();", "int getDamage();", "@Override\n public double getAlcoholPercent() {\n return (getAlcoholVolume() / getVolume()) * 100.0;\n }", "public int calculateCombatLevel() {\r\n if (entity instanceof NPC) {\r\n return ((NPC) entity).getDefinition().getCombatLevel();\r\n }\r\n int combatLevel;\r\n int melee = staticLevels[ATTACK] + staticLevels[STRENGTH];\r\n int range = (int) (1.5 * staticLevels[RANGE]);\r\n int mage = (int) (1.5 * staticLevels[MAGIC]);\r\n if (melee > range && melee > mage) {\r\n combatLevel = melee;\r\n } else if (range > melee && range > mage) {\r\n combatLevel = range;\r\n } else {\r\n combatLevel = mage;\r\n }\r\n combatLevel = staticLevels[DEFENCE] + staticLevels[HITPOINTS] + (staticLevels[PRAYER] / 2) + (int) (1.3 * combatLevel);\r\n return combatLevel / 4;\r\n }", "public float getTotalEffect(Player player)\n {\n return leastAmount + BONUS_MULTIPLIER * player.getIntelligence();\n }", "public static double getPercentToLevel(final int skill, final int level) {\r\n\t\tfinal DecimalFormat df = new DecimalFormat(\"##.##\");\r\n\t\tfinal int lvl = Skills.getRealLevel(skill);\r\n\t\tif (lvl == 99 && skill != Skills.DUNGEONEERING) {\r\n\t\t\treturn 0;\r\n\t\t} else if (lvl == 120 && skill == Skills.DUNGEONEERING) {\r\n\t\t\treturn 0;\r\n\t\t}\r\n\t\tfinal double xpTotal = Skills.XP_TABLE[level] - Skills.XP_TABLE[lvl];\r\n\t\tif (xpTotal == 0) {\r\n\t\t\treturn 0;\r\n\t\t}\r\n\t\tfinal double xpDone = Skills.getCurrentExp(skill) - Skills.XP_TABLE[lvl];\r\n\t\tfinal double progress = 100 * xpDone / xpTotal;\r\n\t\treturn Double.valueOf(df.format(progress));\r\n\t}", "public static int getMaxDamage() {\n\t\treturn MAX_DAMAGE;\n\t}", "@Override\n public double getDefenseAmount() {\n return this.getDefense().getAbilityValue();\n }", "public double getPercentMutants() {\n\t\tdouble count = (double) getNumMutants();\n\t\tdouble pSize = (double) this.getPopSize();\n\n\t\treturn count*100.0 / pSize;\n\t}", "public int getDamage() {\n\t\treturn (int) (Math.random() * damageVariance) + damage;\n\t}", "public short getSiegeWeaponDamage();", "int getMinigameDefenseChancesLeft();", "public int getHealth() {\n return getStat(health);\n }", "private void calcEfficiency() {\n \t\tdouble possiblePoints = 0;\n \t\tfor (int i = 0; i < fermentables.size(); i++) {\n \t\t\tFermentable m = ((Fermentable) fermentables.get(i));\n \t\t\tpossiblePoints += (m.getPppg() - 1) * m.getAmountAs(\"lb\")\n \t\t\t\t\t/ postBoilVol.getValueAs(\"gal\");\n \t\t}\n \t\tefficiency = (estOg - 1) / possiblePoints * 100;\n \t}", "public int getHP()\n\t{\n\t\tUnit u = this;\n\t\tint hp = 0;\n\t\tfor(Command c : u.race.unitcommands)\n\t\t\tif(c.command.equals(\"#hp\"))\n\t\t\t\thp += Integer.parseInt(c.args.get(0));\n\t\t\n\t\tfor(Command c : u.getSlot(\"basesprite\").commands)\n\t\t\tif(c.command.equals(\"#hp\"))\n\t\t\t{\n\t\t\t\tString arg = c.args.get(0);\n\t\t\t\tif(c.args.get(0).startsWith(\"+\"))\n\t\t\t\t\targ = arg.substring(1);\n\t\t\t\t\n\t\t\t\thp += Integer.parseInt(arg);\n\t\t\t}\n\t\t\n\t\tif(hp > 0)\n\t\t\treturn hp;\n\t\telse\n\t\t\treturn 10;\n\t}", "public static float calculatePercent(float numOfSpecificTrees, float totalTrees){\n\t\tfloat percent= numOfSpecificTrees/totalTrees*100;\n\t\treturn percent;\n\t\t\n\t}", "@Override\n\tpublic int calculateCustomDamageTaken(Entity attacker, Entity defender, int damage, int attackType) {\n\t\treturn damage;\n\t}", "AbilityDamage getAbilityDamage();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "int getMaxHP();", "private double getEffectAmount(int skillLevel) {\n\t\tdouble effectAmount = mBase;\n\t\tif (skillLevel == -1)\n\t\t\tskillLevel = mNormalLevel;\n\t\teffectAmount += skillLevel * mLevelIncrease;\n\t\teffectAmount += Math.min(skillLevel, 5) * mLevelIncreaseNovice;\n\t\teffectAmount = Math.min(effectAmount, mMax);\n\t\teffectAmount = Math.max(effectAmount, mMin);\n\t\t\n\t\tif (mException && skillLevel <= mExceptionHigh\n\t\t\t\t&& skillLevel >= mExceptionLow)\n\t\t\teffectAmount = mExceptionValue;\n\t\t\n\t\tif (DwarfCraft.debugMessagesThreshold < 1){\n\t\t\tSystem.out.println(String.format(\"DC1: GetEffectAmmount ID: %d Level: %d Base: %.2f Increase: %.2f Novice: %.2f Max: %.2f Min: %.2f \" +\n\t\t\t\t\t\"Exception: %s Exctpion Low: %.2f Exception High: %.2f Exception Value: %.2f Floor Result: %s\",\n\t\t\t\t\tmID, skillLevel, mBase, mLevelIncrease, mLevelIncreaseNovice, mMax, mMin, \n\t\t\t\t\tmException, mExceptionLow, mExceptionHigh, mExceptionValue, mFloorResult));\n\t\t}\n\t\treturn (mFloorResult ? Math.floor(effectAmount) : effectAmount);\n\t}", "public double getMaxHealth() {\n return maxHealth;\n }", "private static int maxHealth(int health){\r\n int mHealth = 0;\r\n mHealth = health + 5;\r\n return mHealth; \r\n }", "public double getAverageHealthCoefficient() {\n double cumulativeHealth = 0.0;\n int population = this.getPopulation();\n Iterator<Guppy> it = guppiesInPool.iterator();\n\n while (it.hasNext()) {\n Guppy currentGuppy = it.next();\n if (currentGuppy.getIsAlive()) {\n cumulativeHealth += currentGuppy.getHealthCoefficient();\n }\n }\n return (population == 0) ? population : cumulativeHealth / population;\n }", "public double getPercentageOfAvailabilityMeetingSla() {\n final double totalOfAvailabilitySatisfied = getBrokerList()\n .stream()\n .filter(b -> faultInjection.availability(b) * 100 >= getCustomerMinAvailability(b))\n .count();\n return totalOfAvailabilitySatisfied / getBrokerList().size();\n }", "public int getMaxHealth()\r\n\t{\r\n\t\treturn MaxHealth;\r\n\t}", "public static double getWeaponDamage(Item weapon, Skill attStrength) {\n/* 2348 */ if (weapon.isBodyPart() && weapon.getAuxData() != 100) {\n/* */ \n/* */ try {\n/* */ \n/* 2352 */ float f = Server.getInstance().getCreature(weapon.getOwnerId()).getCombatDamage(weapon);\n/* */ \n/* 2354 */ return (f + Server.rand.nextFloat() * f * 2.0F);\n/* */ }\n/* 2356 */ catch (NoSuchCreatureException nsc) {\n/* */ \n/* 2358 */ logger.log(Level.WARNING, \"Could not find Creature owner of weapon: \" + weapon + \" due to \" + nsc.getMessage(), (Throwable)nsc);\n/* */ \n/* */ }\n/* 2361 */ catch (NoSuchPlayerException nsp) {\n/* */ \n/* 2363 */ logger.log(Level.WARNING, \"Could not find Player owner of weapon: \" + weapon + \" due to \" + nsp.getMessage(), (Throwable)nsp);\n/* */ } \n/* */ }\n/* */ \n/* */ \n/* 2368 */ float base = 6.0F;\n/* 2369 */ if (weapon.isWeaponSword()) {\n/* */ \n/* 2371 */ base = 24.0F;\n/* */ }\n/* 2373 */ else if (weapon.isWeaponAxe()) {\n/* 2374 */ base = 30.0F;\n/* 2375 */ } else if (weapon.isWeaponPierce()) {\n/* 2376 */ base = 12.0F;\n/* 2377 */ } else if (weapon.isWeaponSlash()) {\n/* 2378 */ base = 18.0F;\n/* 2379 */ } else if (weapon.isWeaponCrush()) {\n/* 2380 */ base = 36.0F;\n/* 2381 */ } else if (weapon.isBodyPart() && weapon.getAuxData() == 100) {\n/* */ \n/* 2383 */ base = 6.0F;\n/* */ } \n/* 2385 */ if (weapon.isWood()) {\n/* 2386 */ base *= 0.1F;\n/* 2387 */ } else if (weapon.isTool()) {\n/* 2388 */ base *= 0.3F;\n/* */ } \n/* 2390 */ base = (float)(base * (1.0D + attStrength.getKnowledge(0.0D) / 100.0D));\n/* */ \n/* 2392 */ float randomizer = (50.0F + Server.rand.nextFloat() * 50.0F) / 100.0F;\n/* */ \n/* 2394 */ return base + (randomizer * base * 4.0F * weapon.getQualityLevel() * weapon.getDamagePercent()) / 10000.0D;\n/* */ }", "public int getDamage() {\n //TODO\n return 1;\n }", "public int attackRoll(){\r\n\t\treturn (int) (Math.random() * 100);\r\n\t}", "@Override\n public void attackedByShaman(double attack) {\n damageCounter += (2 * attack) / 3;\n this.attack = Math.max(this.attack - (2 * attack) / 3, 0);\n }", "public int percent() {\n\t\tdouble meters = meters();\n\t\tif (meters < MIN_METERS) {\n\t\t\treturn 0;\n\t\t}\n\t\treturn (int) (Math.pow((meters - MIN_METERS)\n\t\t\t\t/ (MAX_METERS - MIN_METERS) * Math.pow(100, CURVE),\n\t\t\t\t1.000d / CURVE));\n\t}", "private int attack(int chance, int additionalDamage) {\n if (diceRoll(10) <= chance) { //A statement where we call a diceRoll, if we hit under or equals the chance to hit, we calculate the damage\n int attackValue = player.getAttackValue() * (diceRoll(4) + additionalDamage); //Here we get the players attackValue, which then gets multiplied by a diceRoll + the additionalDamage from the chosen attack\n int damageDealt = 0;\n if (attackValue >= opponent.getArmor()) { //We check if our attackValue is greater than or equals to the opponents armor. If it is not, we don't deal any damage.\n damageDealt = (attackValue - opponent.getArmor()) + 1; //If we attack through the opponents armor, we deal the remaining damage + 1. (if we deal 1 damage and opponent has 1 armor, we still deal 1 damage)\n opponent.changeHealth(damageDealt * -1); //Changes the opponents health\n }\n return damageDealt;\n }\n return -1;\n }" ]
[ "0.7670183", "0.7410153", "0.70792925", "0.7032433", "0.6883212", "0.68699485", "0.6693979", "0.6661638", "0.6616283", "0.6575612", "0.6569881", "0.65638226", "0.656035", "0.6529186", "0.6516866", "0.6504652", "0.6477197", "0.6469186", "0.6452572", "0.6439364", "0.64361405", "0.63990253", "0.63958067", "0.6385531", "0.638371", "0.6366926", "0.63533765", "0.6351552", "0.63477", "0.6345217", "0.632622", "0.63242257", "0.6321514", "0.63172597", "0.6312879", "0.63110787", "0.6288373", "0.6286506", "0.62787867", "0.6240559", "0.62328357", "0.62314886", "0.6229378", "0.6218845", "0.62142146", "0.62135327", "0.6208924", "0.62041765", "0.6191034", "0.61864716", "0.6184989", "0.6179312", "0.6178575", "0.6174349", "0.6146685", "0.6143545", "0.61379", "0.6129376", "0.61238384", "0.6114399", "0.6107884", "0.6107884", "0.6107884", "0.6107884", "0.6107884", "0.6107042", "0.6068419", "0.60672593", "0.60638535", "0.60514665", "0.60482067", "0.60477316", "0.60470843", "0.60435176", "0.603844", "0.60351104", "0.6029383", "0.60223174", "0.6012002", "0.60109025", "0.600435", "0.6003649", "0.6003649", "0.6003649", "0.6003649", "0.6003649", "0.6003649", "0.6003649", "0.599465", "0.59844303", "0.5979645", "0.5977419", "0.5970853", "0.59702426", "0.59652126", "0.596364", "0.5952655", "0.59516037", "0.59473586", "0.59462476" ]
0.66239
8
Sets state of the mob to seeded. Paramets needed to be set before.
public void setSeeded() { if (seedType != 0 && seeder != null) { setSeeded(seedType, seeder.getLevel()); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void SetState(VehicleState state) {\n this.state = state;\n }", "private void setMechanicState(MechanicState state) {\r\n if (this.state == state) {\r\n return;\r\n }\r\n this.state = state;\r\n }", "public void setAlive(boolean state) {\n alive = state;\n setColor();\n }", "void setState(SimulationState state) {\n\t\tthis.state = state;\n\t}", "@Override\n public void apply() {\n owner.setState(Mob.State.stunned);\n }", "public void setAlive(final Boolean state) {\n this.alive = state;\n this.newState = state;\n }", "private void mRelayStateSet(cKonst.eSerial newState) {\n nRelayState=newState;\n oBTServer.mStateSet( newState);\n }", "public void setState(PlayerState state) {\n this.state = state;\n }", "public synchronized void set() {\n this.currentState = EventState.UP;\n notify();\n }", "private void setMPState(String state) {\n this.mpState = state;\n }", "@Override\n public void set(boolean state) {\n if (isInverted) {\n super.set(!state);\n } else {\n super.set(state);\n }\n }", "public void setState(State state) { model.setState(state); }", "private synchronized void setState(int state) {\n if (D) Log.d(TAG, \"setState() \" + mState + \" -> \" + state);\n mState = state;\n\n // Give the new state to the Handler so the UI Activity can update\n mHandler.obtainMessage(RemoteBluetooth.MESSAGE_STATE_CHANGE, state, -1).sendToTarget();\n }", "public synchronized void setMediationState(MEDIATION_STATE mediation_state) {\n if (this.mMediationState != mediation_state) {\n this.mMediationState = mediation_state;\n IronSourceLoggerManager ironSourceLoggerManager = this.mLoggerManager;\n IronSourceLogger.IronSourceTag ironSourceTag = IronSourceLogger.IronSourceTag.INTERNAL;\n ironSourceLoggerManager.log(ironSourceTag, \"Smart Loading - \" + getInstanceName() + \" state changed to \" + mediation_state.toString(), 0);\n if (this.mAdapter != null && (mediation_state == MEDIATION_STATE.CAPPED_PER_SESSION || mediation_state == MEDIATION_STATE.CAPPED_PER_DAY)) {\n this.mAdapter.setMediationState(mediation_state, getAdUnitString());\n }\n }\n }", "public static void setEnemyFive(boolean state)\r\n\t{\r\n\t\tenemyFive = state;\r\n\t}", "public void setAlive(boolean state) {\n\t\talive = state;\n\t}", "public static void setEnemyOne(boolean state)\r\n\t{\r\n\t\tenemyOne = state;\r\n\t}", "public void setState(State state) {\n this.state = state;\n }", "public void setState(State state) {\n this.state = state;\n }", "public void setState(State state) {\n\t\tthis.state = state;\n\t}", "public synchronized void setTiltTargetState(double goalTiltState){\n targetTiltState = goalTiltState;\n }", "public void setState(Boolean state) {\n this.state = state;\n }", "public void setDefilade(int defiladeState);", "private void setState(STATE state) {\n if (this.state != state) {\n sendStatusChange(MEDIA_STATE, null, (float)state.ordinal());\n }\n this.state = state;\n }", "void setState(boolean state);", "public void setMyState(MesiStates theMesiState)\n\t{\n\t\tmyMesiState = theMesiState;\n\t}", "public void setCargoIntakeState() {\n blueLED.set(false);\n greenLED.set(false);\n if (!redLED.get() && timer.get() >= pulseTime) {\n redLED.startPulse();\n timer.stop();\n timer.reset();\n }\n else if (redLED.get() && timer.get() > pulseTime) {\n redLED.set(false);\n }\n else {\n timer.start();\n }\n }", "public void setState(final State state);", "public void setState(State state) {\n synchronized (stateLock){\n this.state = state;\n }\n }", "public void changeState() {\n if (!isDead) {\n Bitmap temp = getBitmap();\n setBitmap(stateBitmap);\n stateBitmap = temp;\n }\n }", "public void setState(final StateReference state);", "public void setState (State state) {\n synchronized (this) {\n this.state = state;\n }\n }", "public void setMobHasChanged() {\r\n\t\t// method that informs the view(the observer) of the changes\r\n\t\tthis.setChanged();\r\n\t\tthis.notifyObservers();\r\n\t\r\n\t}", "public void setState(boolean state) {\n\t\tthis.state = state;\n\t}", "public void setState(Long state) {\n this.state = state;\n }", "private void setState(WFDState s) {\n Log.d(TAG, \"Moving from \" + sState + \" --> \" + s);\n sState = s;\n }", "protected void setState(final State state) {\n this.state.set(state);\n }", "public void setState(@NotNull State state) {\n this.state = state;\n }", "public void setAlive() {\n\t\tif (this.alive == true) {\n\t\t\tthis.alive = false;\n\t\t} else {\n\t\t\tthis.alive = true;\n\t\t}\n\t}", "void setState(Object state);", "public void setAlive(boolean alive){\n // make sure the enemy can be alive'nt\n this.alive = alive; \n }", "public void applyNewState() {\n this.setAlive(this.newState);\n }", "void setState(State state);", "public abstract void setSensorState(boolean state);", "protected final void setState(State s) {\n state = s;\n }", "public void setState(State newState) {this.state = newState;}", "public void setState(String state) {\n // checkValidState(state);\n if ((!States.special.contains(this.state)\n || !this.inSpecialState)\n && this.state != state) {\n this.spriteNum = 0;\n this.curSpriteFrame = 0;\n this.state = state;\n }\n \n }", "public void setState(Byte state) {\n this.state = state;\n }", "public void setState(Byte state) {\n this.state = state;\n }", "public void setGearState(boolean state) {\n shifter.set(state);\n }", "public void setOn(){\n state = true;\n //System.out.println(\"Se detecto un requerimiento!\");\n\n }", "void setState(forestOrDebrisState state)\n {\n this.state = state;\n }", "public void set(GameState state){\n states.pop();\n states.push(state);\n }", "public void setState( boolean bool ) { state = bool; }", "public void setState(int state) {\n m_state = state;\n }", "public void setState(server.SayHello.shandong.State state) {\n this.state = state;\n }", "void setState(int state);", "public static void setEnemyFour(boolean state)\r\n\t{\r\n\t\tenemyFour = state;\r\n\t}", "public void setScreenState(int state) {\n if (mScreenState != state) {\n if (DEBUG) {\n Slog.d(TAG, \"setScreenState: state=\" + state);\n }\n\n mScreenState = state;\n mScreenReady = false;\n scheduleScreenUpdate();\n }\n }", "public void setState(int state);", "public void setState(int state);", "public void setState(GameState s) {\n this.state = s;\n }", "private void setState( int state )\n {\n m_state.setState( state );\n }", "public void setAwake(boolean aw)\n {\n awake = aw;\n }", "public void set_state(boolean etat) {\r\n this.etat = etat;\r\n }", "private void setState(Element element, State state)\n\t{\n\t\tif (element != null) {\n\t\t\tif (state == State.FULL || state == null)\n\t\t\t\telement.removeAttribute(STATE_ATTR_NAME);\n\t\t\telse\n\t\t\t\telement.setAttribute(STATE_ATTR_NAME, state.toString());\n\t\t}\n\t}", "public static void setEnemyTwo(boolean state)\r\n\t{\r\n\t\tenemyTwo = state;\r\n\t}", "public void setState(int state) {\n\t\t\tmState = state;\n\t\t}", "public void setStateOfMovement(int movementState){stateOfMovement = movementState; }", "protected void setPhysicalState(PhysicalState state) {\n\t\tthis.physicalState = state;\n\t}", "public void setState(NodeState state) {\n this.state = state;\n }", "public void setState(int state) {\n \t\tthis.state = state;\n \t}", "public void setState(long state)\n {\n ((StatefulRandomness)random).setState(state);\n }", "public void setAlive() {\n\t\tif(alive)\n\t\t\talive = false;\n\t\telse\n\t\t\talive = true;\n\t}", "@Override\n\tpublic void setState(STATE state) {\n\n\t}", "public void setOff(){\n state = false;\n //System.out.println(\"El requerimiento esta siendo atendido!\");\n }", "private void mStateSet(cKonst.eSerial nNewState) {\n if (nState_Serial!=nNewState) {\n switch (nNewState) {\n case kBT_Disconnected:\n mMsgDebug(sRemoteDeviceName + \" Disconnected 1\");\n break;\n }\n bDoRedraw = true; //Something has changed redraw controls\n }\n nState_Serial=nNewState;\n }", "public void setState(States s) {\n\t\tthis.state = s;\n\t}", "public void setState(State state)\n\t{\n\t\tsetState(conferenceInfo, state);\n\t}", "public void setMotionState(AcceleratorNode nodeDev, MOTION_STATE state) {\n JComponent cmpMotion = this.mdlCtrlr.getMotionStateDisplay(nodeDev);\n \n cmpMotion.setBackground(state.getColor());\n this.mdlCtrlr.fireTableDataChanged();\n }", "public void setSpecialState(String state, int delay) {\n if (!this.inSpecialState) {\n this.spriteNum = 0;\n this.curSpriteFrame = 0;\n this.state = state;\n this.inSpecialState = true;\n TimedEventQueue.addTask(new TimedTask(this, \"breakSpecialState\", delay));\n }\n }", "final protected void setEntityState(int newState)\n {\n state = newState;\n }", "@Override protected void setState(State s) {\n session.setState(s);\n super.setState(s);\n }", "public ArmPistonSetBothStates(PistonPositions state) {\n // Use requires() here to declare subsystem dependencies\n // eg. requires(chassis);\n \trequires(Robot.armPiston);\n \tthis.state = state;\n }", "public void turnOn ()\n\t{\n\t\tthis.powerState = true;\n\t}", "public static void setEnemyThree(boolean state)\r\n\t{\r\n\t\tenemyThree = state;\r\n\t}", "public void setState(int state) {\n\t\tif (state == CHASE)\n\t\t\tthis.state = CHASE;\n\t\telse if (state == RUN) \n\t\t\tthis.state = RUN;\n\t}", "public ZWavePolling set(Device device, boolean state) {\n super.device = device;\n this.state = state;\n return this;\n }", "public void setState(State state) {\n\t\tenvironmentStatus = state.name();\n\t\tsetupResult = state.name();\n\t}", "public void SetState(int s) {\n this.state=LS[s];\n }", "@Override\n public void setState(int state) {\n synchronized(LOCK_STATE) {\n this.state = state;\n }\n }", "public void turnOn(){\n Logger.getGlobal().log(Level.INFO,\" Turning On..\");\n vendingMachine = new VendingMachine();\n inventoryPopulation();\n idle();\n }", "public void setState(Integer state) {\r\n this.state = state;\r\n }", "public void setState(Integer state) {\r\n this.state = state;\r\n }", "public void setState(StateController state) {\n this.state = state;\n }", "void setAlive(boolean isAlive);", "public void setArmed(boolean b) {\n }", "public static void setState(GameState state) {\r\n\t\tgameState = state;\r\n\t}", "public void setState(org.apache.axis.types.UnsignedInt state) {\n this.state = state;\n }", "public void updateMob(Vector3f target,float tpf) {\n //System.out.println(\"updateMob called with state = \" + this.state);\n switch(this.state) {\n case -1:\n //dead state\n this.handle.removeFromParent();\n this.mobControl.destroy();\n this.state = -2;\n break;\n case 0:\n //default state\n if(this.health < 0f) {\n this.changeState(-1);\n }\n Vector3f temp = target.subtract(this.handle.getLocalTranslation());\n \n this.mobControl.setWalkDirection(Vector3f.ZERO);\n this.setRootPos(this.mobControl.getPhysicsLocation());\n //System.out.println(\"id = \"+ this.id + \". State = 0 (STANDBY) - Dist \" + temp.length());\n if( temp.length() < 50) {\n this.initSeekBehavior();\n }\n break;\n case 1:\n //run seek behavior\n Vector3f temp2 = target.subtract(this.handle.getLocalTranslation());\n //System.out.println(\"id = \"+ this.id + \". State = 1 (SEEK) - Dist \" + temp2.length());\n if( temp2.length() < 70) {\n this.updateSeekBehavior(target, tpf);\n } else {\n this.changeState(0);\n } \n break;\n case 2:\n //melee attack\n }\n }" ]
[ "0.6397018", "0.626632", "0.62382424", "0.6223765", "0.6220844", "0.6158731", "0.6086259", "0.6027284", "0.5970055", "0.59386516", "0.5849457", "0.58247936", "0.58230597", "0.5786157", "0.5760878", "0.5754268", "0.5744269", "0.57413507", "0.57413507", "0.573533", "0.5734382", "0.5734256", "0.5724871", "0.5721181", "0.5713261", "0.5705278", "0.56975347", "0.56953216", "0.5693374", "0.56813484", "0.56790704", "0.56779474", "0.56775635", "0.56619424", "0.5658894", "0.5639008", "0.56377405", "0.56358546", "0.56019884", "0.5594014", "0.5590472", "0.5569478", "0.55674434", "0.5566087", "0.55629647", "0.55626506", "0.5559246", "0.55514604", "0.55514604", "0.5550847", "0.5545898", "0.55438143", "0.5508938", "0.5500769", "0.5499729", "0.5497207", "0.5489963", "0.5489544", "0.54891396", "0.5484021", "0.5484021", "0.5481117", "0.54799485", "0.5478201", "0.54704994", "0.5466263", "0.54638666", "0.5462864", "0.545982", "0.5458948", "0.5458608", "0.5456431", "0.544924", "0.5447645", "0.5426845", "0.54221666", "0.54218686", "0.54188645", "0.5418053", "0.54161733", "0.5416124", "0.5413383", "0.54113585", "0.54038185", "0.5397461", "0.53919405", "0.5388702", "0.53832716", "0.5369972", "0.53628", "0.53517336", "0.5343243", "0.53312874", "0.53312874", "0.5316266", "0.53098935", "0.5300623", "0.5299267", "0.5294372", "0.5284637" ]
0.56598294
34
Sets the seed parametrs, but not the seed state
public void setSeeded(final int id, final L2PcInstance seeder) { if (!seeded) { seedType = id; this.seeder = seeder; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setSeed(int seed){\n this.seed = seed; \n }", "void setSeed(long seed);", "void setSeed(final long seed);", "@Override\n public void setSeed(final int seed) {\n int counterMask = 3;\n int[] status = new int[4];\n status[0] = seed;\n status[1] = parameter.getMat1();\n status[2] = parameter.getMat2();\n status[3] = parameter.getTmat();\n for (int i = 1; i < MIN_LOOP; i++) {\n status[i & counterMask] ^= i + MAGIC_NUMBER3\n * (status[(i - 1) & counterMask]\n ^ (status[(i - 1) & counterMask]\n >>> INITIALIZE_SHIFT2));\n }\n st0 = status[0];\n st1 = status[1];\n st2 = status[2];\n st3 = status[3];\n periodCertification();\n for (int i = 0; i < MIN_LOOP; i++) {\n nextState();\n }\n clear();\n }", "public void setSeed(int seed) {\r\n this.seed = seed;\r\n }", "public void setSeed(String seed) \n\t{\n\t}", "public void seed(long seed) {\n }", "public WB_RandomPoint setSeed(final long seed);", "public void setSeed(long seed) {\n real.setSeed(seed);\n twister.setSeed(seed);\n }", "@Override\n protected void engineSetSeed(byte[] seed) {\n return;\n }", "public void setSeed(Square.State seed) {\n this.mySeed = seed;\n oppSeed = (mySeed == Square.State.CROSS) ? Square.State.NOUGHT : Square.State.CROSS;\n }", "public void setRNG(long seed);", "public void setSeed(int seed){\n\t\tmyRandom = new Random(seed);\n\t}", "void new_seed( Seed seed );", "public void reset(Parameters params) {\r\n pui.resetParameters();\r\n for (String name : params.getSchema().parameterNames()) {\r\n ParameterSchema schema = params.getSchema().getDetails(name);\r\n Object defVal = schema.getDefaultValue();\r\n if (name.equals(ParameterConstants.DEFAULT_RANDOM_SEED_USAGE_NAME) && defVal.equals(Parameters.NULL)) {\r\n int val = (int) System.currentTimeMillis();\r\n // per JIRA 76 - \"Use positive default random seeds\"\r\n if (val < 0) val = Math.abs(val);\r\n params.setValue(ParameterConstants.DEFAULT_RANDOM_SEED_USAGE_NAME, val);\r\n } else {\r\n if (!defVal.equals(Parameters.NULL)) {\r\n params.setValue(name, defVal);\r\n }\r\n }\r\n }\r\n }", "@Override\n public void setSeed(final long seed) {\n if ((seed >= 0) && (seed < LONG_LIMIT)) {\n setSeed((int) seed);\n } else {\n int[] tmp = new int[2];\n tmp[0] = (int) (seed & 0xffffffff);\n tmp[1] = (int) (seed >>> INT_SIZE);\n setSeed(tmp);\n }\n }", "public void setSeed(long seed) {\n\tif (seed < POW3_33 + 100) {\n\t seed += POW3_33 + 100;\n\t}\n\tseed &= (POW2_53 - 1L);\n\tsetSeedRaw(seed);\n }", "@ProgrammaticProperty\n public void setSeed(String seed) {\n m_randomSeed = seed;\n }", "public void setSeedRaw(final long seed) {\n\t// TBD: add check, throw exception\n\tddmuldd(expm2((double) seed - POW3_33, POW3_33), POW3_33_DIV_2, dd1);\n\tdddivd(dd1, POW3_33, dd2);\n\tddmuldd(Math.floor(dd2[0]), POW3_33, dd2);\n\tddsub(dd1, dd2, dd3);\n\td1 = dd3[0];\n }", "@Override\n public void setSeed(final int[] seeds) {\n// Needed if this is a subclass of java.util.Random. (Before Java 7)\n// \n// if (parameter == null) {\n// return;\n// }\n final int lag = 1;\n final int mid = 1;\n final int size = 4;\n int i, j;\n int count;\n int r;\n int keyLength = seeds.length;\n int[] status = { 0,\n parameter.getMat1(),\n parameter.getMat2(),\n parameter.getTmat() };\n if (keyLength + 1 > MIN_LOOP) {\n count = keyLength + 1;\n } else {\n count = MIN_LOOP;\n }\n r = iniFunc1(status[0] ^ status[mid % size]\n ^ status[(size - 1) % size]);\n status[mid % size] += r;\n r += keyLength;\n status[(mid + lag) % size] += r;\n status[0] = r;\n count--;\n for (i = 1, j = 0; (j < count) && (j < keyLength); j++) {\n r = iniFunc1(status[i % size] ^ status[(i + mid) % size]\n ^ status[(i + size - 1) % size]);\n status[(i + mid) % size] += r;\n r += seeds[j] + i;\n status[(i + mid + lag) % size] += r;\n status[i % size] = r;\n i = (i + 1) % size;\n }\n for (; j < count; j++) {\n r = iniFunc1(status[i % size] ^ status[(i + mid) % size]\n ^ status[(i + size - 1) % size]);\n status[(i + mid) % size] += r;\n r += i;\n status[(i + mid + lag) % size] += r;\n status[i % size] = r;\n i = (i + 1) % size;\n }\n for (j = 0; j < size; j++) {\n r = iniFunc2(status[i % size] + status[(i + mid) % size]\n + status[(i + size - 1) % size]);\n status[(i + mid) % size] ^= r;\n r -= i;\n status[(i + mid + lag) % size] ^= r;\n status[i % size] = r;\n i = (i + 1) % size;\n }\n st0 = status[0];\n st1 = status[1];\n st2 = status[2];\n st3 = status[3];\n periodCertification();\n for (i = 0; i < MIN_LOOP; i++) {\n nextState();\n }\n clear();\n }", "Seed(){\r\n seedCells = new ArrayList<>();\r\n edgeCells = new ArrayList<>();\r\n }", "public void setSeed3DPt(Point3D seedPt) {\r\n this.seed3DPt = seedPt;\r\n }", "public void setSeed(ArrayList<Cell> newSeed) {\n\t\n\t\t for (int y=0;y<MAX_Y;y++) {\n\t\t\tfor (int x=0;x<MAX_X;x++) {\n\t\t\t\tseed[x][y] = new Cell(x,y,false);\t\t \n\t\t\t}//end for x\n\t\t }//end for y\n\t\t \n\t\t for (int k=0; k<newSeed.size();k++) {\n\t\t\t int x1 = Math.abs(newSeed.get(k).getX()) % MAX_X;\n\t\t\t int y1 = Math.abs(newSeed.get(k).getY()) % MAX_Y;\n\t\t\t \n\t\t\t seed[x1][y1] = newSeed.get(k);\n\t\t }//end for k\n\t\t repaint(); //repaint's the grid with new generation\n\t\t updateUI();\n\t }", "public void setSeed(int seed) {\n this.seed = seed;\n mersenne = new MersenneTwister(seed);\n }", "public void setSeed(final long seed) {\n random.setSeed(seed);\n }", "public static void setSeed( long seed ) {\n random = new Random( seed );\n }", "public void setRandomSeed(long seed) {\n randomGenerator.setSeed(seed);\n }", "void reseed();", "public void setSeed2DPt(Point seedPt) {\r\n this.seed2DPt = seedPt;\r\n }", "public void setSeed(byte[] value) {\n this.seed = ((byte[]) value);\n }", "public int getSeed(){\n return this.seed; \n }", "private void seedCommand(String seed) {\n try {\n _randomSource.setSeed(Long.parseLong(seed));\n } catch (NumberFormatException excp) {\n error(\"Invalid number: %s\", seed);\n System.out.println();\n }\n }", "void reset(int randomseed);", "protected void setupParameters() {\n \n \n\n }", "public static void setSeed(long s) {\r\n seed = s;\r\n random = new Random(seed);\r\n }", "public Builder<V, E> seed(long seed) {\n this.seed = seed;\n return this;\n }", "public void initialize() {\n\t\tinitialize(seedValue0, seedValue1);\n\t}", "protected void resetParams() {\n\t\treport.report(\"Resetting Test Parameters\");\n\t\t// numberOfRecoverys = 0;\n\t\tstreams = new ArrayList<StreamParams>();\n\t\tlistOfStreamList = new ArrayList<ArrayList<StreamParams>>();\n\t}", "public void setInitialParameters() {\n /** DO NOTHING */\n }", "@Override\n public Builder seed(long randomSeed) {\n super.seed(randomSeed);\n return this;\n }", "public EmployeeSowSeedAction setSeed(Plant seed) {\n this.seed = seed;\n return instance;\n }", "public void seedCommand(String seed) {\r\n try {\r\n _randomSource.setSeed(Long.parseLong(seed));\r\n } catch (NumberFormatException excp) {\r\n error(\"Invalid number: %s\", seed);\r\n }\r\n }", "public final void randomSeed(long what){\n\t\tsetSeed(what);\n\t\trandom();\n\t}", "public GridSimRandom(long seed) {\n random_.setSeed(seed);\n }", "public final void seed(int s0, int s1, int s2)\r\n {\r\n d0 = s0;\r\n d1 = s1;\r\n d2 = s2;\r\n i = 0;\r\n }", "public InternalExternalTour(long seed){\n\t\t\n\t\trandom = new MersenneTwister(seed);\n\t}", "public int getSeed() {\r\n return seed;\r\n }", "public StressChange(long seed) {\n super(seed);\n }", "public void setSeed (long seed[]) {\n // Must use long because there is no unsigned int type.\n if (seed.length < 6)\n throw new IllegalArgumentException (\"Seed must contain 6 values\");\n if (seed[0] == 0 && seed[1] == 0 && seed[2] == 0)\n throw new IllegalArgumentException\n (\"The first 3 values must not be 0\");\n if (seed[3] == 0 && seed[4] == 0 && seed[5] == 0)\n throw new IllegalArgumentException\n (\"The last 3 values must not be 0\");\n final long m1 = 4294967087L;\n if (seed[0] >= m1 || seed[1] >= m1 || seed[2] >= m1)\n throw new IllegalArgumentException\n (\"The first 3 values must be less than \" + m1);\n final long m2 = 4294944443L;\n if (seed[3] >= m2 || seed[4] >= m2 || seed[5] >= m2)\n throw new IllegalArgumentException\n (\"The last 3 values must be less than \" + m2);\n for (int i = 0; i < 6; ++i)\n Ig[i] = seed[i];\n resetStartStream();\n }", "public Mazealgo(long seed) {\n this.seed = seed;\n this.random = new Random(seed);\n }", "@Before\n public void setUp() {\n randSeeder = new Random(42);\n\n //Show we haven't seeded the test's random number generator\n randSeed = RAND_UNSEEDED;\n comp = IntPlus.getIntComparator();\n }", "public int getSeed() {\n return seed;\n }", "public int getSeed() {\n return seed;\n }", "public TrollGame (int seed){\n rand = new Random(seed);\n initBoard(ROWS, COLS, rand);\n }", "public ScenarioGenerator(long seed) {\n rd.setSeed(seed);\n }", "protected void setFixture(SaveParameters fixture) {\n\t\tthis.fixture = fixture;\n\t}", "public void setSeed(final String seed) {\n int[] intSeeds = new int[seed.length()];\n for (int i = 0; i < intSeeds.length; i++) {\n intSeeds[i] = seed.charAt(i);\n }\n setSeed(intSeeds);\n }", "public long getSeed() {\n return seed;\n }", "public long getSeed()\n {\n return randomSeed;\n }", "public DayTradeStrategy(int seed) {\r\n /* If you need some initialization of e.g., instance variables\r\n write here.\r\n */\r\n\r\n fRandom = new Random(seed); // Initialization of random sequence.\r\n }", "public XorShiftRandom(final long seed) {\n\t\tthis.seed = seed;\n\t}", "void setRandomize(Boolean setting);", "public void init( int pointDimension, long randomSeed );", "void setParameters() {\n\t\t\n\t}", "public long getSeed(){\n\t\treturn this.seed;\n\t}", "public void SetRandom(boolean random);", "public void setParameters(int numberOfMiddle, int numberOfIterations, int seed, double rate) {\n\t\tthis.numberOfMiddle = numberOfMiddle;\n\t\tthis.numberOfIterations = numberOfIterations;\n\t\tthis.rate = rate;\n\n\t\t// create random gen\n\t\tRandom random = new Random(seed);\n\n\t\t// create input and output arrays\n\t\tinput = new double[numberOfInputs];\n\t\tmiddle = new double[numberOfMiddle];\n\t\toutput = new double[numberOfOutputs];\n\n\t\t// create error arrays\n\t\terrorMiddle = new double[numberOfMiddle];\n\t\terrorOutput = new double[numberOfOutputs];\n\n\t\t// create theta arrays\n\t\tthetaMiddle = new double[numberOfMiddle];\n\t\tthetaOutput = new double[numberOfOutputs];\n\n\t\t// initialize thetas at hidden nodes\n\t\tfor (int i = 0; i < numberOfMiddle; i++) {\n\t\t\tthetaMiddle[i] = 2 * random.nextDouble() - 1;\n\t\t}\n\n\t\t// initialize thetas at output nodes\n\t\tfor (int i = 0; i < numberOfOutputs; i++) {\n\t\t\tthetaOutput[i] = 2 * random.nextDouble() - 1;\n\t\t}\n\n\t\t// initialize weights between input and hidden nodes\n\t\tmatrixMiddle = new double[numberOfInputs][numberOfMiddle];\n\t\tfor (int i = 0; i < numberOfInputs; i++) {\n\t\t\tfor (int j = 0; j < numberOfMiddle; j++) {\n\t\t\t\tmatrixMiddle[i][j] = 2 * random.nextDouble() - 1;\n\t\t\t}\n\t\t}\n\n\t\t// initialize weights between hidden and output nodes\n\t\tmatrixOutput = new double[numberOfMiddle][numberOfOutputs];\n\t\tfor (int i = 0; i < numberOfInputs; i++) {\n\t\t\tfor (int j = 0; j < numberOfMiddle; j++) {\n\t\t\t\tmatrixMiddle[i][j] = 2 * random.nextDouble() - 1;\n\t\t\t}\n\t\t}\n\t}", "public ARXLogisticRegressionConfiguration setSeed(int seed) {\n this.seed = seed;\n return this;\n }", "public Seed() {\r\n\t\tcards = new Cards();\r\n\t\tseedCards = new ArrayList<Cards>();\r\n\t\tdescription = \"\";\r\n\t\tautoSummary = \"\";\r\n\t}", "public HashPermute(int seed) {\n\t\tthis.seed = HashFunction.getRandomSeed(seed);\n\t}", "public GridSimRandom(long seed, double lessFactorIO, double moreFactorIO,\n double lessFactorExec, double moreFactorExec)\n {\n random_.setSeed(seed);\n lessFactorIO_ = lessFactorIO;\n moreFactorIO_ = moreFactorIO;\n lessFactorExec_ = lessFactorExec;\n moreFactorExec_ = moreFactorExec;\n }", "protected void setFixture(DatabaseOptions fixture) {\n\t\tthis.fixture = fixture;\n\t}", "protected void setFixture(Grid<?, ?> fixture) {\n\t\tthis.fixture = fixture;\n\t}", "private void initConfiguration() {\n\t\tseedList = new ArrayList<String>();\n\t\t// TODO: add other initialization here...\n\t}", "public long getSeed()\r\n {\r\n return this.randomSeed;\r\n }", "protected void setFixture(Colour fixture)\n\t{\n\t\tthis.fixture = fixture;\n\t}", "public DynamicModelPart seeds(ObjectList<DynamicPart[]> seeds) {\n this.seeds = seeds;\n return this;\n }", "private void initState() {\r\n double metaintensity=0;\r\n double diffr=0;\r\n for(int ii=0; ii < Config.numberOfSeeds; ii++)\r\n {\r\n Cur_state[ii] = this.seeds[ii].getDurationMilliSec();\r\n// Zeit2 = this.seeds[1].getDurationMilliSec();\r\n// Zeit3 = this.seeds[2].getDurationMilliSec();\r\n// LogTool.print(\"Zeit 1 : \" + Zeit1 + \"Zeit 2 : \" + Zeit2 + \"Zeit 3 : \" + Zeit3, \"notification\");\r\n// LogTool.print(\"initState: Dwelltime Seed \" + ii + \" : \" + Cur_state[ii], \"notification\");\r\n// Cur_state[0] = Zeit1;\r\n// Cur_state[1] = Zeit2;\r\n// Cur_state[2] = Zeit3;\r\n }\r\n \r\n if ((Config.SACostFunctionType==3)||(Config.SACostFunctionType==1)) {\r\n for(int x=Config.ptvXLow-0; x < Config.ptvXHigh+0; x++) {\r\n// for(int x=Solver.xBoundsTumor[0]; x < Solver.xBoundsTumor[1]; x+= Config.scaleFactor) {\r\n for(int y=Config.ptvYLow-0; y < Config.ptvYHigh+0; y++) {\r\n// for(int y=Solver.yBoundsTumor[0]; y < Solver.yBoundsTumor[1]; y+= Config.scaleFactor) {\r\n for(int z=Config.ptvZLow-0; z < Config.ptvZHigh+0; z++) {\r\n// for(int z=Solver.zBoundsTumor[0]; z < Solver.zBoundsTumor[1]; z+= Config.scaleFactor) {\r\n// this.body2[x][y][z].setCurrentDosis(0.0); //Set currentPtvVoxel Dose to 0 \r\n this.body2[x][y][z].metavalue = 0.0;\r\n for(int i=0; i<Config.numberOfSeeds;++i) { \r\n // Calculate intensity based based on current dwelltime\r\n metaintensity = this.body2[x][y][z].radiationIntensityNoTime((this.seeds2[i].getCoordinate()));\r\n // radiationIntensityNoTime(this.seeds2[i].getCoordinate(), New_state[i]);\r\n if (metaintensity>0) {\r\n // LogTool.print(\"Cost: Intensity :\" + intensity + \"@ \" + x + \" \" + y + \" \" + z,\"notification\");\r\n }\r\n // this.body2[x][y][z].addCurrentDosis(metaintensity);\r\n this.body2[x][y][z].metavalue += metaintensity; \r\n// Das ist implementation one\r\n } \r\n } \r\n }\r\n }\r\n// this.body = this.body2;\r\n } else {\r\n \r\n // for(int x=Config.ptvXLow-0; x < Config.ptvXHigh+0; x++) {\r\n// for(int x=Solver.xBoundsTumor[0]; x < Solver.xBoundsTumor[1]; x+= Config.scaleFactor) { \r\n for(int x=0; x < Solver.dimensions[0]; x+= Config.scaleFactor) {\r\n // for(int y=Config.ptvYLow-0; y < Config.ptvYHigh+0; y++) {\r\n// for(int y=Solver.yBoundsTumor[0]; y < Solver.yBoundsTumor[1]; y+= Config.scaleFactor) {\r\n for(int y=0; y < Solver.dimensions[1]; y+= Config.scaleFactor) {\r\n // for(int z=Config.ptvZLow-0; z < Config.ptvZHigh+0; z++) {\r\n// for(int z=Solver.zBoundsTumor[0]; z < Solver.zBoundsTumor[1]; z+= Config.scaleFactor) {\r\n for(int z=0; z < Solver.dimensions[2]; z+= Config.scaleFactor) {\r\n // this.body2[x][y][z].setCurrentDosis(0.0); //Set currentPtvVoxel Dose to 0 \r\n this.body2[x][y][z].metavalue = 0.0;\r\n for(int i=0; i<Config.numberOfSeeds;++i) { \r\n // Calculate intensity based based on current dwelltime\r\n metaintensity = this.body2[x][y][z].radiationIntensityNoTime((this.seeds2[i].getCoordinate()));\r\n // radiationIntensityNoTime(this.seeds2[i].getCoordinate(), New_state[i]);\r\n if (metaintensity>0) {\r\n // LogTool.print(\"Cost: Intensity :\" + intensity + \"@ \" + x + \" \" + y + \" \" + z,\"notification\");\r\n }\r\n // this.body2[x][y][z].addCurrentDosis(metaintensity);\r\n this.body2[x][y][z].metavalue += metaintensity;\r\n this.body[x][y][z].metavalue = 0; \r\n this.body[x][y][z].metavalue += this.body2[x][y][z].metavalue;\r\n // Das ist implementation one\r\n } \r\n } \r\n }\r\n }\r\n// this.body = this.body2;\r\n diffr = ((this.body[43][43][43].metavalue)-(this.body2[43][43][43].metavalue));\r\n LogTool.print(\"Shallowcopy Check, value should be 0 :\" + diffr + \"@ 43,43,43 \",\"notification\");\r\n }\r\n }", "@Override\r\n protected void setUp()\r\n {\r\n island = new Island(5,5);\r\n position = new Position(island, 4,4);\r\n seed = new BirdFood(position, \"seed\", \"Crunchy Seeds\", 1.0, 2.0, 1.5);\r\n }", "protected void initializeExecutionRandomness() {\r\n\r\n\t}", "public long getSeed() {\n\t\treturn seed;\n\t}", "public void setup(final EvolutionState state, final Parameter base) \r\n {\n }", "@BeforeEach\n void setUp() {\n seed = new Random().nextInt();\n random = new Random().nextInt();\n rng = new Random(seed);\n int strSize = rng.nextInt(20);\n hello = RandomStringUtils.random(strSize, 0, Character.MAX_CODE_POINT, true, false, null, rng);\n int binarySize = rng.nextInt(20)+1;\n binary = RandomStringUtils.random(binarySize, ZeroOne);\n st = new TString(hello);\n bot = new Bool(true);\n bof = new Bool(false);\n bi = new Binary(binary);\n i = new Int(seed); //seed is a random number\n decimal = seed+0.1; //transformed to double\n f = new Float(decimal);\n g = new Float(random);\n j = new Int(random);\n Null = new NullType();\n }", "public void setupTest(JavaSamplerContext context)\n {\n getLogger().debug(whoAmI() + \"\\tsetupTest()\");\n listParameters(context);\n\n sleepTime = context.getLongParameter(\"SleepTime\", DEFAULT_SLEEP_TIME);\n sleepMask = context.getLongParameter(\"SleepMask\", DEFAULT_SLEEP_MASK);\n }", "public void setCoords() \r\n {\r\n \tthis.coordX = rand.nextInt(10);\r\n \tthis.coordY = rand.nextInt(10);\r\n }", "public void setSeeded()\n\t{\n\t\tif (seedType != 0 && seeder != null)\n\t\t{\n\t\t\tsetSeeded(seedType, seeder.getLevel());\n\t\t}\n\t}", "public byte[] newSeed() {\r\n return engineSpi.newSeed();\r\n }", "public static long getSeed() {\r\n return seed;\r\n }", "private void SetParameters(XmlTest test){\r\n\t\t for (Map.Entry<String,String> entry : TestsParamList.get(test.getName()).entrySet()){\r\n\t\t\t test.addParameter(entry.getKey(), entry.getValue());\r\n\t\t }\r\n\t}", "public void initialize() throws IllegalActionException {\n\t\tsuper.initialize();\n\n\t\tlong seedValue = ((LongToken) (seed.getToken())).longValue();\n\n\t\tif (seedValue != 0) {\n\t\t\t_random.setSeed(seedValue);\n\t\t} else {\n\t\t\t_random.setSeed(System.currentTimeMillis() + hashCode());\n\t\t}\n\t}", "@Override\n public void setTestSessionModifyingParam() {\n sessionModifingParams.addParameter(testVT);\n }", "public void setDefaultParameters()\n {\n parameters = new Vector(); // must do this to clear any old parameters\n\n Parameter parameter = new Parameter( \"DataSet to Divide\",\n DataSet.EMPTY_DATA_SET );\n addParameter( parameter );\n\n parameter = new Parameter( \"Create new DataSet?\", new Boolean(false) );\n addParameter( parameter );\n }", "public Mazealgo() {\n Random number = new Random();\n long i = number.nextLong();\n this.random = new Random(i);\n this.seed = i;\n }", "public void setRandom(boolean random){\n this.random = random;\n }", "private void createSeed(Element temp) {\n\n Seed seed = new Seed();\n for(int i = 0; i < temp.getAttributeCount(); i++) { //same principle as createGrape\n Attribute attribute = temp.getAttribute(i);\n String name = attribute.getQualifiedName();\n String value = attribute.getValue();\n\n switch (name) {\n case (\"name\"):\n seed.setId(value);\n break;\n\n case (\"type\"):\n try {\n seed.setSeedClass(Class.forName(\"Examples.\"+value));\n } catch (ReflectiveOperationException e) {\n Class className = this.isPrimitive(value);\n if(className == null)\n e.printStackTrace();\n else\n seed.setSeedClass(className);\n }\n break;\n\n case(\"constructor\"):\n seed.setIsConstructor(Boolean.valueOf(value));\n break;\n\n case (\"isReferenced\"):\n seed.setRef(Boolean.valueOf(value)); //TODO considerar que se hace si es true\n break;\n\n case (\"value\"):\n if(seed.getSeedClass() != null) {\n if(seed.isRef()){//Debo saber si meter un objeto o un valor\n String k =seed.getSeedClass().getSimpleName();\n Object h = singletonGrapes.get(k);\n if(h==null){\n h = this.isPrimitive(seed.getSeedClass().getSimpleName());\n }\n seed.setValue(h);\n }else{\n seed.setValue(value);\n }\n } else {\n System.err.print(\"Objects.Seed parameters not in correct order. Type should be before values.\");\n }\n break;\n\n default:\n System.err.print(\"Invalid parameter \" + name);\n break;\n }\n }\n\n Element parent = (Element) temp.getParent();\n Grape parentGrape = grapes.get(parent.getAttributeValue(\"id\"));\n super.dependencies.computeIfAbsent(parentGrape.getId(), V-> new LinkedList<>());\n super.dependencies.get(parentGrape.getId()).add(seed); //map should store seeds that belong to the same grape TODO revisar estructura\n\n if(seed.isConstructor())\n buildWithConstructors(parentGrape.getId());\n else\n buildWithSetters(parentGrape.getId());\n }", "@Test\n\tpublic void testUpdatesSeeds() {\n\t\t//Arrange\n\t\tint startLoc[] = new int[]{2};\n\t\tint otherLocs[] = new int[]{0,1,3,4};\n\t\t\t\n\t\tMockito.when(randMock.generateRandomNumber(1, 4, seed)).thenReturn(startLoc);\n\t\tMockito.when(randMock.generateRandomNumber(10, 5, seed+1)).thenReturn(otherLocs);\n\t\t\t\n\t\t//Act\n\t\tlong seed = 2;\n\t\t\t\n\t\t//Assert\n\t\tassertEquals(seed, iteratorObj.startVisits());\n\t}", "private void newGame(long seed) {\n ter.initialize(WIDTH, HEIGHT, 0, -3);\n GameWorld world = new GameWorld(seed);\n String toSave = \"N\" + seed + \"S\";\n world.setSaveScript(toSave);\n for (int x = 0; x < WIDTH; x += 1) {\n for (int y = 0; y < HEIGHT; y += 1) {\n world.world[x][y] = Tileset.NOTHING;\n }\n }\n world.buildManyRandomSq();\n GameWorld.Position avatarPosition = randomAvatarPosition(world);\n ter.renderFrame(world.world);\n loadAvatar(world, avatarPosition);\n }", "public void initWorldGenSeed(long p_75905_1_) {\n/* 99 */ this.worldGenSeed = p_75905_1_;\n/* */ \n/* 101 */ if (this.parent != null)\n/* */ {\n/* 103 */ this.parent.initWorldGenSeed(p_75905_1_);\n/* */ }\n/* */ \n/* 106 */ this.worldGenSeed *= (this.worldGenSeed * 6364136223846793005L + 1442695040888963407L);\n/* 107 */ this.worldGenSeed += this.baseSeed;\n/* 108 */ this.worldGenSeed *= (this.worldGenSeed * 6364136223846793005L + 1442695040888963407L);\n/* 109 */ this.worldGenSeed += this.baseSeed;\n/* 110 */ this.worldGenSeed *= (this.worldGenSeed * 6364136223846793005L + 1442695040888963407L);\n/* 111 */ this.worldGenSeed += this.baseSeed;\n/* */ }", "@Setup\n public void setup() {\n randomInput = new RandomComplexGenerator(inputLength).randomInputs();\n }", "@Override\n protected void initializeSample(SamplingContext context) {\n for(int i = 0 ; i < this.EVars.length ; i++) {\n Variable EVar = this.EVars[i];\n int EVal = this.EVals[i];\n int EIndex = Toolkit.indexOf(this.sampledVars, EVar);\n context.sampledVarsAssignment[EIndex] = EVal;\n }\n // produce a few samples to get the network into a more \"normal\" state\n for(int i = 0 ; i < this.resamplingActions.size() * 2 ; i++)\n this.produceSample(context);\n context.sampleWeight = 1.0;\n\n /*WeightedSampleProducer weightedSampler = new WeightedSampleProducer(\n this.bn, this.XVars, this.YVars, this.EVars, this.EVals);\n // the variable values are preserved after the following call\n weightedSampler.produceSample(context); // evidence is correctly set\n context.sampleWeight = 1.0;*/\n }", "public void prepareDEBreeder(EvolutionState state)\r\n {\r\n }" ]
[ "0.76441467", "0.7322818", "0.7202477", "0.7174534", "0.71510655", "0.71022844", "0.7034591", "0.68331605", "0.67429614", "0.67337096", "0.67200124", "0.6648712", "0.664758", "0.66268635", "0.65969425", "0.6525766", "0.64659745", "0.64491254", "0.64391845", "0.64024466", "0.6391954", "0.6388053", "0.6375563", "0.6327001", "0.6234741", "0.6182363", "0.6172446", "0.6167267", "0.6166469", "0.61547256", "0.6116758", "0.607994", "0.6071831", "0.604936", "0.6046677", "0.6036026", "0.60129565", "0.6012939", "0.60013086", "0.59885544", "0.59699106", "0.5959167", "0.5956756", "0.5944587", "0.591679", "0.5902399", "0.5896685", "0.5893793", "0.5855131", "0.5848801", "0.5832803", "0.5822355", "0.5822355", "0.5800966", "0.57921016", "0.5765086", "0.57506883", "0.572168", "0.57122356", "0.5675856", "0.5671685", "0.5668085", "0.56667686", "0.56512004", "0.5639939", "0.5639105", "0.56360614", "0.5634986", "0.56347275", "0.56253326", "0.55845106", "0.5583815", "0.55731994", "0.55615044", "0.55539864", "0.5548672", "0.5535485", "0.5534859", "0.5528417", "0.5527662", "0.5527362", "0.5526426", "0.55101335", "0.55071133", "0.5496544", "0.54943216", "0.5488513", "0.5485736", "0.54856557", "0.54756206", "0.54670674", "0.5457059", "0.5453818", "0.54430383", "0.5439667", "0.5430792", "0.5424395", "0.5417617", "0.5414389", "0.5412575", "0.53962386" ]
0.0
-1
Check if the server allows Random Animation. This is located here because L2Monster and L2FriendlyMob both extend this class. The other nonpc instances extend either L2NpcInstance or L2MonsterInstance.
@Override public boolean hasRandomAnimation() { return Config.MAX_MONSTER_ANIMATION > 0 && !(this instanceof L2GrandBossInstance); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean isRandom(){\r\n\t\treturn isRandom;\r\n\t}", "public abstract boolean isRandom();", "private void randomBehavior() {\n\t\trandom = rand.nextInt(50);\n\t\tif (random == 0) {\n\t\t\trandom = rand.nextInt(4);\n\t\t\tswitch (random) {\n\t\t\t\tcase 0:\n\t\t\t\t\tchangeFacing(ACTION.DOWN);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 1:\n\t\t\t\t\tchangeFacing(ACTION.RIGHT);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 2:\n\t\t\t\t\tchangeFacing(ACTION.UP);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 3:\n\t\t\t\t\tchangeFacing(ACTION.LEFT);\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t}", "public boolean hasRandomMode()\r\n {\r\n return (random == Toggle.On);\r\n }", "boolean spawningEnabled();", "public boolean shouldExecute() {\n return ShulkerEntity.this.getAttackTarget() == null && ShulkerEntity.this.rand.nextInt(40) == 0;\n }", "public boolean getCanSpawnHere()\r\n {\r\n return false;\r\n }", "public boolean getCanSpawnHere()\n {\n return this.isValidLightLevel() && super.getCanSpawnHere();\n }", "@Override\n public final boolean canStand(Playery player) {\n return true;\n }", "public boolean canSpawnLightningBolt()\n {\n return this.func_150559_j() ? false : this.enableRain;\n }", "@Override\n\tpublic boolean isRandomizable() {\n\t\treturn false;\n\t}", "public boolean canRespawnHere()\n {\n return false;\n }", "public boolean canDespawn()\n {\n return false;\n }", "public boolean isGameOver() {\r\n if(timesAvoid == 3) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }", "protected boolean teleportRandomly() {\n double x = this.posX + (this.rand.nextDouble() - 0.5) * 64.0;\n double y = this.posY + (this.rand.nextInt(64) - 32);\n double z = this.posZ + (this.rand.nextDouble() - 0.5) * 64.0;\n return this.teleportTo(x, y, z);\n }", "@Override /* failed to load code for net.minecraft.block.NetherPortalBlock */\r\n\r\n\t\t@OnlyIn(Dist.CLIENT)\r\n\t\t@Override\r\n\t\tpublic void animateTick(BlockState state, World world, BlockPos pos, Random random) {\r\n\t\t\tfor (int i = 0; i < 4; i++) {\r\n\t\t\t\tdouble px = pos.getX() + random.nextFloat();\r\n\t\t\t\tdouble py = pos.getY() + random.nextFloat();\r\n\t\t\t\tdouble pz = pos.getZ() + random.nextFloat();\r\n\t\t\t\tdouble vx = (random.nextFloat() - 0.5) / 2f;\r\n\t\t\t\tdouble vy = (random.nextFloat() - 0.5) / 2f;\r\n\t\t\t\tdouble vz = (random.nextFloat() - 0.5) / 2f;\r\n\t\t\t\tint j = random.nextInt(4) - 1;\r\n\t\t\t\tif (world.getBlockState(pos.west()).getBlock() != this && world.getBlockState(pos.east()).getBlock() != this) {\r\n\t\t\t\t\tpx = pos.getX() + 0.5 + 0.25 * j;\r\n\t\t\t\t\tvx = random.nextFloat() * 2 * j;\r\n\t\t\t\t} else {\r\n\t\t\t\t\tpz = pos.getZ() + 0.5 + 0.25 * j;\r\n\t\t\t\t\tvz = random.nextFloat() * 2 * j;\r\n\t\t\t\t}\r\n\t\t\t\tworld.addParticle(ParticleTypes.PORTAL, px, py, pz, vx, vy, vz);\r\n\t\t\t}\r\n\r\n\t\t}", "@Test\n\tpublic void myRandomTest() throws IllegalArgumentException, IllegalAccessException {\n\t\t\n\t\tif (Configuration.featureamp &&\n\t\t\t\tConfiguration.playengine &&\n\t\t\t\tConfiguration.choosefile &&\n\t\t\t\tConfiguration.mp3 &&\n\t\t\t\tConfiguration.gui &&\n\t\t\t\tConfiguration.skins &&\n\t\t\t\tConfiguration.light &&\n\t\t\t\tConfiguration.filesupport &&\n\t\t\t\tConfiguration.showtime &&\n\t\t\t\tConfiguration.tracktime) {\n\t\t\n\t\tstart();\n\t\tint n = gui.myRandom(1, 1);\n\t\tassertTrue(n == 1);\n\n\t\tn = gui.myRandom(2, 2);\n\t\tassertTrue(n == 2);\n\n\t\tn = gui.myRandom(0, 0);\n\t\tassertTrue(n == 0);\n\t\t\n\t\tn = gui.myRandom(4, 4);\n\t\tassertTrue(n == 4);\n\n\t\tn = gui.myRandom(1000, 1001);\n\t\tassertTrue(n == 1000 || n == 1001);\n\t\t\n\t\t}\n\t}", "public boolean canRespawnHere() {\n\t\treturn false;\n\t}", "public default boolean shouldSpawnEntity(){ return false; }", "public static boolean negateDamage(ItemStack p_92097_0_, int level, Random p_92097_2_) {\n\t\treturn p_92097_0_.getItem() instanceof ItemArmor && p_92097_2_.nextFloat() < 0.6F ? false\n\t\t\t\t: p_92097_2_.nextInt(getTrueLevel(level) + 1) > 0;\n\t}", "@Override\n public boolean act() {\n float variation = (random.nextFloat() / 2f) - 1;\n\n // Reconfigure the time to wait before spawning another enemy.\n this.deltaLimit = Math.max(100, INITIAL_SPAWN_TIME + variation - (100 * round));\n\n spawnEnemy();\n return false;\n }", "public boolean isSpawn()\n\t{\n\t\treturn block == Block.FRUIT_SPAWN || block == Block.GHOST_SPAWN || block == Block.PAC_SPAWN;\n\t}", "public void setRandom(boolean random){\n this.random = random;\n }", "@Override\n\tpublic boolean canRespawnHere()\n\t{\n\t\treturn false;\n\t}", "@Override\n public boolean canDo(World world, EntityPlayer player) {\n return getTimer(player, COOLDOWN_TIMER) == 0;\n }", "@Override\n synchronized public boolean animationHasChanged(Player animationReceiver)\n {\n if(!animation.equals(\"idle1\") && !animation.equals(\"walk\"))\n {\n return super.animationHasChanged(animationReceiver);\n }\n return false;\n }", "public boolean canDespawn()\n {\n return true;\n }", "public boolean isRandomStartImage() {\n return randomStatImage;\n }", "@Override\n\tprotected boolean canDespawn() {\n\t\treturn false;\n\t}", "static boolean getMauled(){\n\t\t\tif (Person.player.inventory.contains(Item.repellent)) //if you have the goose repellent...\n\t\t\t\treturn (MainFile.getRandomNumber(240) == 12); //drastically lowers your chance of being mauled.\n\t\t\treturn (MainFile.getRandomNumber(20) == 12);//generates a random number for if you don't have it, and if it's 12 you get mauled\n\t\t}", "private boolean canWork() throws InterruptedException{\n for(int i = 0; i <4; i++){\n if(!myPlayer().isAnimating() && !myPlayer().isMoving()){\n return true;\n }\n sleep(random(200, 350));\n }\n return false;\n }", "public boolean getRandomBoolean()\r\n {\r\n return Math.random() < 0.5;\r\n }", "public boolean checkIfPlayerHoldsExplosive () { return noOfExplosives > 0; }", "public boolean allowBotSpawn(boolean allowSpawning) {\n if(m_spawnBots == allowSpawning) {\n return false;\n }\n\n m_spawnBots = allowSpawning;\n return true;\n }", "public boolean isCollisionDisabled() { return mover.isCollisionDisabled(); }", "public boolean canSpawnMore() {\n for(int e: enemiesLeft) {\n if(e > 0) {\n return true;\n }\n }\n\n return false;\n }", "@Override\n public boolean isPlayer() {\n return super.isPlayer();\n }", "@Override\n\tpublic void onSpawn()\n\t{\n\t\tsetIsNoRndWalk(true);\n\t\tsuper.onSpawn();\n\n\t\t// check the region where this mob is, do not activate the AI if region is inactive.\n\t\tL2WorldRegion region = WorldManager.getInstance().getRegion(getX(), getY());\n\t\tif(region != null && !region.isActive())\n\t\t{\n\t\t\tgetAI().stopAITask();\n\t\t}\n\t}", "@Override\n\tpublic boolean doDie(final L2Character killer)\n\t{\n\t\t// Kill the L2NpcInstance (the corpse disappeared after 7 seconds)\n\t\tif (!super.doDie(killer))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\t// Enhance soul crystals of the attacker if this L2Attackable had its soul absorbed\n\t\ttry\n\t\t{\n\t\t\tif (killer instanceof L2PcInstance)\n\t\t\t{\n\t\t\t\tlevelSoulCrystals(killer);\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t\t\n\t\t// Notify the Quest Engine of the L2Attackable death if necessary\n\t\ttry\n\t\t{\n\t\t\tif (killer instanceof L2PcInstance || killer instanceof L2Summon)\n\t\t\t{\n\t\t\t\tfinal L2PcInstance player = killer instanceof L2PcInstance ? (L2PcInstance) killer : ((L2Summon) killer).getOwner();\n\t\t\t\t\n\t\t\t\tEngineModsManager.onKill(killer, this, killer instanceof L2Summon);\n\t\t\t\t\n\t\t\t\t// only 1 randomly choosen quest of all quests registered to this character can be applied\n\t\t\t\tfor (final Quest quest : getTemplate().getEventQuests(Quest.QuestEventType.ON_KILL))\n\t\t\t\t{\n\t\t\t\t\tquest.notifyKill(this, player, killer instanceof L2Summon);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (final Exception e)\n\t\t{\n\t\t\tLOGGER.error(\"\", e);\n\t\t}\n\t\t\n\t\tsetChampion(false);\n\t\tif (Config.L2JMOD_CHAMPION_ENABLE && Config.L2JMOD_CHAMPION_FREQUENCY > 0)\n\t\t{\n\t\t\t// Set champion on next spawn\n\t\t\tif (this.getClass().getSimpleName().equalsIgnoreCase(\"L2MonsterInstance\") && getLevel() >= Config.L2JMOD_CHAMP_MIN_LVL && getLevel() <= Config.L2JMOD_CHAMP_MAX_LVL)\n\t\t\t{\n\t\t\t\tint random = ThreadLocalRandom.current().nextInt(100);\n\t\t\t\tif (random < Config.L2JMOD_CHAMPION_FREQUENCY)\n\t\t\t\t{\n\t\t\t\t\tsetChampion(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn true;\n\t}", "protected boolean isMovementNoisy() {\n/* 1861 */ return (!this.abilities.flying && (!this.onGround || !isDiscrete()));\n/* */ }", "private boolean isGetingOneServerFile(){\n\tRandom ran = new Random();\n\tif((ran.nextInt() % 2) == 0)\n\t\treturn true;\n\telse\n\t\treturn false;\n}", "@Override\n protected void init() {\n lastHorizontalDirection = direction = Math.random() < 0.5 ? Direction.LEFT : Direction.RIGHT;\n lastVerticalDirection = Direction.UP;\n setBody(new PolygonShape(BODY_WIDTH2, BODY_HEIGHT2), Body.Mode.CHARACTER);\n body().restitution = 0.0;\n size().set(WIDTH, HEIGHT);\n\n this.addAnimation(\"walk\")\n .addFrames(\"smick\", 4, 5, 0, 2)\n .setSpeed(10)\n .loop(true);\n this.addAnimation(\"eatRadish\")\n .addFrames(\"smick\", 4, 5, 8, 9)\n .setSpeed(10)\n .loop(true);\n this.addAnimation(\"eatHector\")\n .addFrames(\"smick\", 4, 5, 10, 10)\n .setSpeed(10)\n .loop(true);\n this.addAnimation(\"jump\")\n .addFrames(\"smick\", 4, 5, 11, 11)\n .setSpeed(10)\n .loop(false);\n this.addAnimation(\"climb\")\n .addFrames(\"smick\", 4, 5, 12, 13)\n .setSpeed(10)\n .loop(false);\n this.addAnimation(\"eatHectorOnRope\")\n .addFrames(\"smick\", 4, 5, 14, 14)\n .setSpeed(10)\n .loop(false);\n this.addAnimation(\"crushing\")\n .addFrames(\"smick\", 4, 5, 16, 16)\n .setSpeed(10)\n .loop(false);\n }", "@Override\n\tpublic boolean isGameTied() {\t\n\t\treturn false;\n\t}", "public abstract int getRandomDamage();", "public boolean isBonusShotAllowed() {\n\t\treturn isLastFrame() && (isStrike() || isSpare());\n\t}", "public boolean shouldDeathban(Player player) {\n\t\tPlayerInventory pi = player.getInventory();\n\t\ttry {\n\t\t\tfor (Method m : ARMOR_METHODS) {\n\n\t\t\t\tItemStack item = (ItemStack) m.invoke(pi);\n\t\t\t\tif (item == null) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\n\t\t\t\tString name = item.getType().name();\n\n\t\t\t\tif (!(name.contains(\"IRON_\") || name.contains(\"DIAMOND_\"))) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (IllegalAccessException | IllegalArgumentException | InvocationTargetException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\n\t\treturn false;\n\t}", "public boolean isSecondBallAllowed() {\n\t\treturn !isStrike() || isBonusShotAllowed();\n\t}", "public void onLivingUpdate()\n {\n super.onLivingUpdate();\n double moveSpeed = this.getAttributeMap().getAttributeInstance(SharedMonsterAttributes.MOVEMENT_SPEED).getAttributeValue();\n if (timetopee-- < 0 && !bumgave)\n {\n isJumping = false;\n\n if (bumrotation == 999F)\n {\n bumrotation = rotationYaw;\n }\n\n rotationYaw = bumrotation;\n moveSpeed = 0.0F;\n\n if (!onGround)\n {\n motionY -= 0.5D;\n }\n \n /* TODO\n if(worldObj.isRemote)\n {\n \tMCW.proxy.pee(worldObj, posX, posY, posZ, rotationYaw, modelsize);\n } */\n\n if (timetopee < -200)\n {\n timetopee = rand.nextInt(600) + 600;\n bumrotation = 999F;\n int j = MathHelper.floor_double(posX);\n int k = MathHelper.floor_double(posY);\n int l = MathHelper.floor_double(posZ);\n\n for (int i1 = -1; i1 < 2; i1++)\n {\n for (int j1 = -1; j1 < 2; j1++)\n {\n if (rand.nextInt(3) != 0)\n {\n continue;\n }\n\n Block k1 = worldObj.getBlockState(new BlockPos(j + j1, k - 1, l - i1)).getBlock();\n Block l1 = worldObj.getBlockState(new BlockPos(j + j1, k, l - i1)).getBlock();\n\n if (rand.nextInt(2) == 0)\n {\n if ((k1 == Blocks.GRASS || k1 == Blocks.DIRT) && l1 == Blocks.AIR)\n {\n worldObj.setBlockState(new BlockPos(j + j1, k, l - i1), Blocks.YELLOW_FLOWER.getDefaultState());\n }\n\n continue;\n }\n\n if ((k1 == Blocks.GRASS || k1 == Blocks.DIRT) && l1 == Blocks.AIR)\n {\n \tworldObj.setBlockState(new BlockPos(j + j1, k, l - i1), Blocks.RED_FLOWER.getDefaultState());\n }\n }\n }\n }\n }\n }", "public void SetRandom(boolean random);", "@Override\r\n public void initCreature() \r\n {\n \t\r\n if ( worldObj.provider.dimensionId == 1 && worldObj.rand.nextInt( 5 ) == 0 )\r\n \t{\r\n \tsetCarried( Block.whiteStone.blockID );\r\n \tsetCarryingData( 0 );\r\n \t}\r\n }", "public boolean isGenerateRandomly() {\n\t\treturn generateRandomly;\n\t}", "public void onLivingUpdate()\n {\n if (this.worldObj.isDaytime() && !this.worldObj.isRemote && !this.isChild())\n {\n float var1 = this.getBrightness(100.0F);\n\n if (var1 > 0.5F && this.rand.nextFloat() * 30.0F < (var1 - 0.4F) * 2.0F && this.worldObj.canBlockSeeTheSky(MathHelper.floor_double(this.posX), MathHelper.floor_double(this.posY), MathHelper.floor_double(this.posZ)))\n {\n boolean var2 = true;\n ItemStack var3 = this.getEquipmentInSlot(4);\n\n if (var3 != null)\n {\n if (var3.isItemStackDamageable())\n {\n var3.setItemDamage(var3.getItemDamageForDisplay() + this.rand.nextInt(2));\n\n if (var3.getItemDamageForDisplay() >= var3.getMaxDamage())\n {\n this.renderBrokenItemStack(var3);\n this.setCurrentItemOrArmor(4, (ItemStack)null);\n }\n }\n\n var2 = false;\n }\n\n if (var2)\n {\n this.setFire(-99);\n }\n }\n }\n\n super.onLivingUpdate();\n }", "private void checkMovement()\n {\n if (frames % 600 == 0)\n {\n \n ifAllowedToMove = true;\n \n \n }\n \n }", "@Override\n\tpublic boolean canRespawnHere() {\n\t\treturn true;\n\t}", "protected boolean animationsEnabled() {\n if (!isShown()) {\n return false;\n }\n if (getAlpha() != 1f) {\n return false;\n }\n getLocationOnScreen(mLocInScreen);\n return mLocInScreen[1] >= -getHeight();\n }", "public static boolean isPresent() {\n // random genrate\n //double ranValue = Math.floor(Math.random() * 10 ) % 3;\n //int ranValue = 0/1;\n return 1 == new Random().nextInt(1000)%2;\n }", "public boolean generateEnemyMissile(String spriteLocation, MainApplication app){\n\t\tint num = this.rng.nextInt(this.PERCENT) + 1;\n\t\tif(num <= this.MISSILE_GENERATION_PROBILITY){\n\t\t\tMissile missile = new Missile(app, spriteLocation);\n\t\t\tthis.missiles.add(missile);\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public void setRandomlyEnabled(boolean randomlyEnabled) {\n isRandomlyEnabled = randomlyEnabled;\n }", "private boolean isTargetingPlayer(Entity entity) {\n if (!plugin.getConfiguration().relativeAgeEnabled()) return false;\n if (entity instanceof Creature) {\n Creature creature = (Creature) entity;\n if (creature.getTarget() != null && creature.getTarget().getType().equals(EntityType.PLAYER)) {\n lastTargeted.put(entity.getUniqueId(), entity.getTicksLived());\n return true;\n }\n }\n return false;\n }", "public static boolean charRNG() { // Character randoms initilization\n Random randomN = new Random();\n \n int speedP1 = randomN.nextInt(5) + 1; // Super 1\n int speedP2 = randomN.nextInt(5) + 1;\n \n int defP1 = randomN.nextInt(5) + 1; // Super 2\n int defP2 = randomN.nextInt(5) + 1;\n \n int attackP1 = randomN.nextInt(5) + 1; // Super 3\n int attackP2 = randomN.nextInt(5) + 1;\n \n int P1stats = ((speedP1 + defP1) + attackP1);\n int P2stats = ((speedP2 + defP2) + attackP2);\n \n return (P1stats > P2stats);\n }", "public boolean shouldExecute()\n\t{\n\t\tif (this.entity.getAge() >= 100)\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\telse if (this.entity.getRNG().nextInt(120) != 0)\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\telse\n\t\t{\n\t\t\tVec3d Vec3d = RandomPositionGenerator.findRandomTarget(this.entity, 10, 7);\n\n\t\t\tif (Vec3d == null)\n\t\t\t{\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tthis.xPosition = Vec3d.xCoord;\n\t\t\t\tthis.yPosition = Vec3d.yCoord;\n\t\t\t\tthis.zPosition = Vec3d.zCoord;\n\t\t\t\tthis.leapTarget = Vec3d;\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t}", "private boolean canMageHarrasing(Creature m) {\n return (heroC.getX() - m.getX()) * (heroC.getX() - m.getX()) == (heroC.getY() - m.getY()) * (heroC.getY() - m.getY());\n }", "private void random() {\n GameState gs = cc.getGameState();\n ArrayList<int[]> moves = cc.getPlayerMoves(player);\n ArrayList<GameState> states = nextStates(moves, gs);\n for (int[] m : moves) {\n GameState next = checkMove(m, cc);\n states.add(next);\n }\n Random rand = new Random(System.nanoTime());\n int i = rand.nextInt(states.size());\n cc.setAIMove(states.get(i));\n }", "public static boolean randomBoolean() {\n\t\treturn RANDOMIZER.nextBoolean();\n\t}", "public static boolean getEncerado() {\r\n\treturn (Math.random() >= 0.5);\r\n }", "private boolean isCreateBattle() {\r\n int percent = ConfigUtil.getConfigInteger(\"battlePercent\", 30);\r\n if(RandomUtil.nextInt(100) < percent){\r\n return true;\r\n }\r\n return false;\r\n }", "public static boolean chance() {\r\n Random rand = new Random();\r\n int chance = rand.nextInt(10);\r\n return chance > 5;\r\n }", "@Override\r\n\tpublic void updateTick(World world, int x, int y, int z, Random random) {\r\n\t\tif (!world.isRemote) {\r\n\t\t\tint state = getStateFromMeta(world.getBlockMetadata(x, y, z));\r\n\t\t\tif (state != 0) {\r\n\t\t\t\tthis.setStateIfMobInteractsWithMTPlate(world, x, y, z);\r\n\t\t\t}\r\n\t\t}\r\n\t}", "@Override\n public void onLivingUpdate() {\n if (this.lastEntityToAttack != this.entityToAttack) {\n IAttributeInstance attribute = this.getEntityAttribute(SharedMonsterAttributes.movementSpeed);\n attribute.removeModifier(EntityEnderCreeper.attackingSpeedBoost);\n if (this.entityToAttack != null) {\n attribute.applyModifier(EntityEnderCreeper.attackingSpeedBoost);\n }\n }\n this.lastEntityToAttack = this.entityToAttack;\n\n for (int i = 0; i < 2; i++) {\n this.worldObj.spawnParticle(\"portal\", this.posX + (this.rand.nextDouble() - 0.5) * this.width, this.posY + this.rand.nextDouble() * this.height - 0.25, this.posZ + (this.rand.nextDouble() - 0.5) * this.width, (this.rand.nextDouble() - 0.5) * 2.0, -this.rand.nextDouble(), (this.rand.nextDouble() - 0.5) * 2.0);\n }\n if (this.worldObj.isDaytime() && !this.worldObj.isRemote) {\n float brightness = this.getBrightness(1.0F);\n if (brightness > 0.5F && this.worldObj.canBlockSeeTheSky((int)Math.floor(this.posX), (int)Math.floor(this.posY), (int)Math.floor(this.posZ)) && this.rand.nextFloat() * 30.0F < (brightness - 0.4F) * 2.0F) {\n this.entityToAttack = null;\n this.teleportRandomly();\n }\n }\n if (this.isWet()) {\n this.attackEntityFrom(DamageSource.drown, 1);\n this.entityToAttack = null;\n this.teleportRandomly();\n }\n this.isJumping = false;\n if (this.entityToAttack != null) {\n if (this.entityToAttack.getDistanceSqToEntity(this) < 9.0 && this.canEntityBeSeen(this.entityToAttack)) {\n this.setCreeperState(1);\n }\n else {\n this.setCreeperState(-1);\n }\n this.faceEntity(this.entityToAttack, 100.0F, 100.0F);\n }\n if (!this.worldObj.isRemote && this.isEntityAlive()) {\n if (this.entityToAttack != null) {\n if (this.entityToAttack instanceof EntityPlayer && this.shouldAttackPlayer((EntityPlayer)this.entityToAttack)) {\n if (this.getCreeperState() < 0 && this.entityToAttack.getDistanceSqToEntity(this) < 16.0) {\n this.teleportRandomly();\n }\n this.teleportDelay = 0;\n }\n else if (this.entityToAttack.getDistanceSqToEntity(this) > 256.0 && this.teleportDelay++ >= 30 && this.teleportToEntity(this.entityToAttack)) {\n this.teleportDelay = 0;\n }\n }\n else {\n this.teleportDelay = 0;\n }\n }\n super.onLivingUpdate();\n }", "public Boolean IsIOtrminate() {\n Random r = new Random();\n int k = r.nextInt(100);\n //20%\n if (k <= 20) {\n return true;\n }\n return false;\n }", "public void birdDeath(){\n birdDeath[(int)(Math.random()*3)].play(1f);\n }", "public boolean canDie() {\n\t\treturn false;\n\t}", "public boolean isSpawnable(Location loc) {\n Block block = loc.getBlock();\n Block under = loc.getBlock().getRelative(BlockFace.DOWN);\n Block above = loc.getBlock().getRelative(BlockFace.UP);\n if (block.getType().equals(Material.AIR) && !under.getType().equals(Material.AIR) && above.getType().equals(Material.AIR)) {\n if (block.getLightLevel() <= plugin.CONFIG.SPAWNING_LIGHT) {\n return true;\n }\n }\n return false;\n }", "private boolean canMakeSmores() {\n return (Build.VERSION.SDK_INT > Build.VERSION_CODES.LOLLIPOP_MR1);\n }", "public boolean gameIsOver() {return revealedShips >= 4;}", "@SideOnly(Side.CLIENT)\n @Override\n public void randomDisplayTick(IBlockState state, World world, BlockPos pos, Random rand) {\n if(!ResynthConfig.PLANTS_GENERAL.enableSmokingPlants)\n return;\n\n IBlockState iblockstate = world.getBlockState(pos);\n int amount = 3;\n\n if(!MathUtil.chance(2.0F))\n return;\n\n if (iblockstate.getMaterial() != Material.AIR) {\n for (int i = 0; i < amount; ++i){\n double d0 = rand.nextGaussian() * 0.02D;\n double d1 = rand.nextGaussian() * 0.02D;\n double d2 = rand.nextGaussian() * 0.02D;\n world.spawnParticle(EnumParticleTypes.SMOKE_NORMAL,\n (double)((float)pos.getX() + rand.nextFloat()),\n (double)pos.getY() + (double)rand.nextFloat()\n * iblockstate.getBoundingBox(world, pos).maxY,\n (double)((float)pos.getZ() + rand.nextFloat()), d0, d1, d2);\n }\n }\n else {\n for (int i1 = 0; i1 < amount; ++i1) {\n double d0 = rand.nextGaussian() * 0.02D;\n double d1 = rand.nextGaussian() * 0.02D;\n double d2 = rand.nextGaussian() * 0.02D;\n world.spawnParticle(EnumParticleTypes.SMOKE_NORMAL,\n (double)((float)pos.getX() + rand.nextFloat()),\n (double)pos.getY() + (double)rand.nextFloat() * 1.0f,\n (double)((float)pos.getZ() + rand.nextFloat()), d0, d1, d2);\n }\n }\n }", "void move()\n {\n Random rand = new Random();\n int moveOrNot = rand.nextInt(2);//50% chance\n if(moveOrNot == 1)\n super.move();\n }", "protected boolean performActions() {\n try {\n Thread.sleep(5000);\n } catch (InterruptedException e) {\n // This is simulation, so we will not handle it\n }\n\n return Math.rint(Math.random()) % 20 != 0;\n }", "public boolean isSetShowAnimation()\n {\n synchronized (monitor())\n {\n check_orphaned();\n return get_store().find_attribute_user(SHOWANIMATION$20) != null;\n }\n }", "private boolean allowsInstantMessage()\n {\n for(ChatTransport tr : transportMenuItems.keySet())\n {\n if(tr.allowsInstantMessage())\n {\n return true;\n }\n }\n\n return false;\n }", "@Override\n\tpublic boolean performsAttackAnimation() {\n\t\tif (phase == AbyssalSirePhase.MAGIC_COMBAT && attack == AbyssalSireAttack.POISON) {\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "public Location randomSpawn(Match m) {\r\n\t\treturn randomSpawn(teamName.ALONE, m);\r\n\t}", "protected void checkMeteor()\n {\n e= (Explosion)getOneObjectAtOffset(getImage().getWidth()/20, 0, Explosion.class);\n \n if (e!=null)\n {\n if (meteorInflicted == false)\n {\n health = health - 1000;\n meteorInflicted = true;\n }\n \n }\n else{\n meteorInflicted = false;\n }\n }", "public boolean isPossibleSpectate() throws RemoteException {\n return mainScreenProvider.isPossibleSpectate();\n }", "public boolean randomCreate() {\n\t\t// Generates a random genetic code\n\t\t_geneticCode = new GeneticCode();\n\t\t// it has no parent\n\t\t_parentID = -1;\n\t\t_generation = 1;\n\t\t_growthRatio = 16;\n\t\t// initial energy\n\t\t_energy = Math.min(Utils.INITIAL_ENERGY,_world.getCO2());\n\t\t_world.decreaseCO2(_energy);\n\t\t_world.addO2(_energy);\n\t\t// initialize\n\t\tcreate();\n\t\tsymmetric();\n\t\t// put it in the world\n\t\treturn placeRandom();\n\t}", "public static void playRandomDeath() {\n\t\t\n\t\tString[] deathSoundArray = {\"death1\", \"death2\", \"death3\"};\n\t\t\n\t\tint rnd = new Random().nextInt(deathSoundArray.length);\n\t\tplaySound(deathSoundArray[rnd], 0.4f);\n\t}", "private static ResourceLocation getRandomMonster(Random rand)\n\t{\n\t\tRandomCollection<ResourceLocation> monsters = new RandomCollection<ResourceLocation>();\n\t\t\n\t\tmonsters.add(10, EntityList.getKey(EntityZombie.class));\n\t\tmonsters.add(10, EntityList.getKey(EntitySkeleton.class));\n\t\tmonsters.add(10, EntityList.getKey(EntitySpider.class));\n\t\tmonsters.add(7, EntityList.getKey(EntityGhost.class));\n\t\tmonsters.add(7, EntityList.getKey(EntityBarbarian.class));\n\t\t//monsters.add(4, EntityList.getKey(EntityBandit.class));\n\t\tmonsters.add(3, EntityList.getKey(EntityBanshee.class));\n\t\tmonsters.add(1, EntityList.getKey(EntityGolem.class));\n\t\t\n\t\treturn monsters.next(rand);\n\t}", "public boolean muerteInesperada() {\n r = new Random();\r\n return Float.compare(r.nextFloat(), probMuerte) <= 0;\r\n }", "protected boolean isAIEnabled()\n {\n return true;\n }", "public boolean drops() {\r\n\t\tboolean res = drops;\r\n\t\tif(drops) {\r\n\t\t\tRandom r = new Random();\r\n\t\t\tint rand = r.nextInt(2);\r\n\t\t\tres = rand == 0;\r\n\t\t}\r\n\t\treturn res;\r\n\t}", "public static boolean playsAsProtoss() {\n return AtlantisConfig.MY_RACE.equals(RaceTypes.Protoss);\n }", "public static void Random() {\n\t\tRandom ran =new Random();\r\n\t\trandom=ran.nextInt(6)+1;\r\n\t\t//random=1;\r\n\t\twho=A1063307_GUI.who2;\r\n\t\tif((ch[who].status)>0) {\r\n\t\t\tch[who].location=(ch[who].location)+random;\r\n\t\t\tch[who].status=(ch[who].status)-1;\r\n\t\t\t\r\n\t\t}else {\r\n\t\t\t\treturn;\r\n\t\t\t}\t\t\r\n\t}", "public boolean canMove() {\n\n\tArrayList<Location> moveLocs = getValid(getLocation());\n\n\tif (isEnd == true) {\n\t return false;\n\t} \n\tif (!moveLocs.isEmpty()) {\n\t \n\t randomSelect(moveLocs);\n\t // selectMoveLocation(moveLocs);\n\t return true;\n\n\t} else {\n\t return false;\n\t}\n }", "@Override\r\n\tpublic boolean canPlay() {\n\t\treturn false;\r\n\t}", "public boolean hasMonsterID() {\n return ((bitField0_ & 0x00000002) == 0x00000002);\n }", "public boolean immobilises(Pokemon poke) {\n BattleField field = poke.getField();\n if (field.getRandom().nextDouble() <= 0.25) {\n field.showMessage(poke.getName() + \" is paralysed! It can't move!\");\n return true;\n }\n return false;\n }", "private Vector3 randomLocationMonster() {\n\t\t\n\t\tVector3 center = this.getEngine().getSceneManager().getRootSceneNode().getLocalPosition();\n\t\tVector3 randomPosition;\n\t\tfloat[] randomFloat;\n\t\tdo {\n\t\t\trandomFloat = randomFloatArray(1000);\n\t\t\trandomPosition = Vector3f.createFrom(randomFloat[0], 1.5f, randomFloat[2]);\n\t\t} while (distanceFrom(center, randomPosition) > 380f);\n\t\treturn randomPosition;\n\t}", "public boolean hasMonsterID() {\n return ((bitField0_ & 0x00000002) == 0x00000002);\n }", "boolean haveAnySpawn();", "@Override\r\n\tpublic boolean guardMovement() {\r\n\r\n\t\tif(stop == 0) {\r\n\t\t\tstate = 'G';\r\n\t\t\t\r\n\t\t\tRandom rand = new Random();\r\n\t\t\tint tmp = rand.nextInt(10) + 1;\r\n\t\t\t\r\n\t\t\tif(tmp > 8) { \r\n\t\t\t\tstate = 'g';\r\n\t\t\t\tstop = rand.nextInt(3) + 1;\r\n\t\t\t\tdirection = rand.nextBoolean();\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t\treturn checkAndMove();\r\n\t\t}\r\n\t\telse \r\n\t\t\tstop--;\r\n\r\n\t\treturn false;\r\n\t}" ]
[ "0.60476166", "0.589597", "0.56022805", "0.5562677", "0.54478264", "0.5436237", "0.5423398", "0.54026395", "0.5401558", "0.5270961", "0.52701014", "0.5269203", "0.52326524", "0.5214628", "0.52013075", "0.51999015", "0.517678", "0.5127282", "0.50901294", "0.5086948", "0.50766", "0.5072445", "0.50707567", "0.506565", "0.50597304", "0.505407", "0.50501704", "0.50360775", "0.5025977", "0.50172806", "0.5015472", "0.50139767", "0.49972355", "0.49908382", "0.4982298", "0.49770427", "0.49740857", "0.49649936", "0.4955512", "0.49521682", "0.49501792", "0.49238905", "0.4920586", "0.4917507", "0.4912207", "0.49043417", "0.49009454", "0.48883626", "0.48757964", "0.48741236", "0.48621127", "0.48569807", "0.48553732", "0.48546046", "0.4837783", "0.4837054", "0.48353368", "0.48339808", "0.48327067", "0.4829388", "0.48262402", "0.48219848", "0.48140416", "0.4799159", "0.47960684", "0.47937095", "0.47923478", "0.4787583", "0.47849047", "0.4783838", "0.47767743", "0.47711498", "0.47697142", "0.47694156", "0.4758618", "0.47584096", "0.475394", "0.47504786", "0.4749869", "0.47452173", "0.47446164", "0.47430447", "0.47371516", "0.47300842", "0.47255716", "0.4716192", "0.47147757", "0.47111133", "0.47096887", "0.47067672", "0.47056866", "0.47042656", "0.47034597", "0.4698175", "0.46838292", "0.46762818", "0.46749553", "0.46726644", "0.46719486", "0.46708965" ]
0.7392087
0
Add One To Number Problem Description Given a nonnegative number represented as an array of digits, add 1 to the number ( increment the number represented by the digits ). The digits are stored such that the most significant digit is at the head of the list. NOTE: Certain things are intentionally left unclear in this question which you should practice asking the interviewer. For example: for this problem, following are some good questions to ask : Q : Can the input have 0's before the most significant digit. Or in other words, is 0 1 2 3 a valid input? A : For the purpose of this question, YES Q : Can the output have 0's before the most significant digit? Or in other words, is 0 1 2 4 a valid output? A : For the purpose of this question, NO. Even if the input has zeroes before the most significant digit. Problem Constraints 1 <= size of the array <= 1000000 Input Format First argument is an array of digits. Output Format Return the array of digits after adding one. Example Input Input 1: [1, 2, 3] Example Output Output 1: [1, 2, 4] Example Explanation Explanation 1: Given vector is [1, 2, 3]. The returned vector should be [1, 2, 4] as 123 + 1 = 124.
public static void main(String[] args) { int arr[] = { 0, 3, 7, 6, 4, 0, 5, 5, 5 }; plusOne(arr); plusOne1(new ArrayList<Integer>(Arrays.asList(0, 3, 7, 6, 4, 0, 5, 5, 5))); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int[] plusOne(int[] digits) {\n\n if(digits==null || digits.length==0){\n return digits;\n }\n\n int carry =1;\n\n for(int i= digits.length-1;i>=0;i--){\n int sum = digits[i]+ carry;\n if(sum>=10){\n carry =1;\n }else\n carry =0;\n digits[i]= sum%10;\n }\n\n if(carry ==1){\n int [] newResult = new int[digits.length+1];\n newResult[0]=1;\n for(int i=0;i<digits.length;i++){\n newResult[i+1] =digits[i];\n }\n return newResult;\n }\n\n return digits;\n\n\n\n\n /*2nd Method\n int len = digits.length-1;\n\n if(digits[len] !=9)\n digits[len] = digits[len] +1;\n else{\n while(digits[len] == 9 && len!=0){\n digits[len] = 0;\n len--;\n }\n\n if(len==0 && digits[len]==9){\n digits[len] = 0;\n int newArray [] = new int[digits.length+1];\n newArray[0] = 1;\n for(int i=0;i<digits.length;i++){\n newArray[i+1] = digits[i];\n }\n return newArray;\n\n }else{\n digits[len] = digits[len] +1;\n }\n\n }\n return digits;*/\n\n }", "public static int[] plusOne(int[] digits) {\n\n int last = digits.length - 1;\n\n // check if last element less than 9, if so add 1 and return array\n if (digits[last] < 9){\n digits[last] = digits[last] + 1;\n return digits;\n }\n\n //declare variable increment\n int increment = 0;\n for (int i = last; i > -1; i--) {\n if (i == last) {\n digits[i] = digits[i] + 1;\n }\n \n digits[i] = digits[i] + increment;\n increment = 0;\n if (digits[i] > 9) {\n increment++;\n digits[i] = digits[i] % 10;\n }\n }\n\n if (increment > 0) {\n int[] moreDigits = new int[digits.length + 1];\n moreDigits[0] = increment;\n for (int j = 1; j < moreDigits.length; j++) {\n moreDigits[j] = digits[j-1];\n }\n return moreDigits;\n }\n\n return digits;\n }", "public int[] plusOne(int[] digits) {\r\n\t\t// Start typing your Java solution below\r\n\t\t// DO NOT write main() function\r\n\t\tint c = 1;\r\n\t\tint i;\r\n\t\tfor (i = digits.length - 1; i >= 0; i--) {\r\n\t\t\tif (digits[i] < 9) {\r\n\t\t\t\tdigits[i] += c;\r\n\t\t\t\tbreak;\r\n\t\t\t} else if (digits[i] == 9) {\r\n\t\t\t\tdigits[i] = 0;\r\n\t\t\t}\r\n\t\t}\r\n\t\tif (i < 0 && digits[0] == 0) {\r\n\t\t\tint[] newDigits = new int[digits.length + 1];\r\n\t\t\tnewDigits[0] = 1;\r\n\t\t\treturn newDigits;\r\n\t\t} else {\r\n\t\t\treturn digits;\r\n\t\t}\r\n\t}", "public int[] plusOne(int[] digits) {\n\t\tint carry = 0;\n\t\tdigits[digits.length - 1] += 1;\n\t\tfor (int i = digits.length - 1; i >= 0; i--) {\n\t\t\tdigits[i] = digits[i] + carry;\n\t\t\tcarry = digits[i] / 10;\n\t\t\tdigits[i] %= 10;\n\t\t}\n\t\tif (carry == 0) {\n\t\t\treturn digits;\n\t\t} else {\n\t\t\tint[] newDigits = new int[digits.length + 1];\n\t\t\tfor (int i = 0; i < digits.length; i++) {\n\t\t\t\tnewDigits[i + 1] = digits[i];\n\t\t\t\tnewDigits[0] = carry;\n\t\t\t}\n\t\t\treturn newDigits;\n\t\t}\n\t}", "private static List<Integer> addOnePlus(List<Integer> input) {\n\n\t\tint size = input.size();\n\t\tinput.set(size-1, input.get(size-1)+1);//last element of input is updated/replaced by (original value + 1)\n\n\t\tfor(int i=size-1; i>0 && input.get(i)==10; i--) {\n\t\t\tinput.set(i, 0);\n\t\t\tinput.set(i-1, input.get(i-1)+1);\n\t\t}\n\n\t\tif(input.get(0) == 10) {\n\t\t\tinput.set(0, 0);\n\t\t\tinput.add(0, 1);//add 1 at index0 ,shift all elements after to right\n\t\t}\n\n\t\treturn input;//this modifies the original input\n\t}", "public int[] plusOne(int[] digits) {\n\n for (int i=digits.length - 1; i>=0; i--) {\n int val = digits[i];\n if (val == 9) {\n digits[i] = 0;\n }\n else {\n digits[i] = digits[i] + 1;\n return digits;\n }\n }\n\n // All 9's case\n int[] output = new int[digits.length + 1];\n output[0] = 1;\n return output;\n }", "public int[] plusOne(int[] digits) {\r\n\t\tif (digits == null || digits.length == 0) {\r\n\t\t\treturn digits;\r\n\t\t}\r\n\t\tfor (int carry = 1, i = digits.length - 1; i >= 0; i--) {// carry 初始化为1,因为我们要加1\r\n\t\t\tint value = (digits[i] + carry) % 10;\r\n\t\t\tcarry = (digits[i] + carry) / 10;\r\n\t\t\tdigits[i] = value;\r\n\t\t\tif (carry == 0) {// 如果不再进位,i左边的位都不用再检查了\r\n\t\t\t\treturn digits;\r\n\t\t\t}\r\n\t\t}\r\n \t//如果能执行到这一步,说明一直在进位直到加1后的数组比原数组多了一位。\r\n \t//说明原来的数组全是9构成的,而新数组是1加上后面若干个0构成的\r\n \t//初始化int[],默认每一位都是0。所以只需置第0位为1即可\r\n\t\tint[] result = new int[digits.length + 1];\r\n\t\tresult[0] = 1;\r\n\t\treturn result;\r\n }", "private static List<Integer> addOne(List<Integer> input) {\n\n\t\tList<Integer> copy = new ArrayList<>();\n\t\tcopy.addAll(input);\n\n\t\tint size = copy.size();\n\t\tcopy.set(size-1, input.get(size-1)+1);//last element of input is updated/replaced by (original value + 1)\n\n\t\tfor(int i=size-1; i>0 && copy.get(i)==10; i--) {\n\t\t\tcopy.set(i, 0);\n\t\t\tcopy.set(i-1, copy.get(i-1)+1);\n\t\t}\n\n\t\tif(copy.get(0) == 10) {\n\t\t\tcopy.set(0, 0);\n\t\t\tcopy.add(0, 1);//add 1 at index0 ,shift all elements after to right\n\t\t}\n\n\t\treturn copy;//this NOT modifies the original input\n\t}", "public int[] plusOne(int[] digits) {\n if(digits == null){\n return null;\n }\n \n int carry = 1, tmpSum;\n ArrayList<Integer> res = new ArrayList<Integer>();\n int len = digits.length, i = len - 1;\n while(i >= 0 || carry == 1){\n tmpSum = carry;\n if(i >= 0){\n tmpSum += digits[i];\n }\n carry = tmpSum / 10;\n res.add(0, tmpSum % 10);\n i--;\n }\n int[] result = new int[res.size()];\n for(int j = 0; j < result.length; j++){\n result[j] = res.get(j);\n }\n return result;\n }", "static int addOne(int[] a, int offset, int mlen, int carry) {\n offset = a.length-1-mlen-offset;\n long t = (a[offset] & LONG_MASK) + (carry & LONG_MASK);\n\n a[offset] = (int)t;\n if ((t >>> 32) == 0)\n return 0;\n while (--mlen >= 0) {\n if (--offset < 0) { // Carry out of number\n return 1;\n } else {\n a[offset]++;\n if (a[offset] != 0)\n return 0;\n }\n }\n return 1;\n }", "public static void plus1(int[]arr)\r\n\t{\r\n\t\tint i=arr.length-1;\r\n\t\twhile(i>=0&&arr[i]==1)\r\n\t\t\tarr[i--]=0;\r\n\t\tif(i>=0)\r\n\t\t\tarr[i]=1;\r\n\t}", "private int plusOne(int index) {\n if (index + 1 >= array.length) {\n return 0;\n } else {\n return index + 1;\n }\n }", "public static void main(String[] args) {\n int[] digits = {1, 2, 3};\n int[] digits2 = {9, 9, 9};\n System.out.println(Arrays.toString(plusOne(digits)));\n System.out.println(Arrays.toString(plusOne(digits2)));\n }", "private static int[] add(int[] x, long val) {\n int[] y;\n long sum = 0;\n int xIndex = x.length;\n int[] result;\n int highWord = (int)(val >>> 32);\n if (highWord == 0) {\n result = new int[xIndex];\n sum = (x[--xIndex] & LONG_MASK) + val;\n result[xIndex] = (int)sum;\n } else {\n if (xIndex == 1) {\n result = new int[2];\n sum = val + (x[0] & LONG_MASK);\n result[1] = (int)sum;\n result[0] = (int)(sum >>> 32);\n return result;\n } else {\n result = new int[xIndex];\n sum = (x[--xIndex] & LONG_MASK) + (val & LONG_MASK);\n result[xIndex] = (int)sum;\n sum = (x[--xIndex] & LONG_MASK) + (highWord & LONG_MASK) + (sum >>> 32);\n result[xIndex] = (int)sum;\n }\n }\n // Copy remainder of longer number while carry propagation is required\n boolean carry = (sum >>> 32 != 0);\n while (xIndex > 0 && carry)\n carry = ((result[--xIndex] = x[xIndex] + 1) == 0);\n // Copy remainder of longer number\n while (xIndex > 0)\n result[--xIndex] = x[xIndex];\n // Grow result if necessary\n if (carry) {\n int bigger[] = new int[result.length + 1];\n System.arraycopy(result, 0, bigger, 1, result.length);\n bigger[0] = 0x01;\n return bigger;\n }\n return result;\n }", "public static void stepOne(ArrayList<Integer> list) {\n\t\t\n\t\t//keep track of number of times list is passed through\n\t\tint passNumber = 0;\n\t\t\n\t\t//iterate through arraylist from right to left\n\t\tfor(int i = list.size()-1; i >= 0; i--) {\n\n\t\t\tint newNum = list.get(i);\n\t\t\tpassNumber++;\n\t\t\t\n\t\t\t//for every other number beginning with second from the right\n\t\t\t//double number -- if two digit number results, add digits together\n\t\t\tif (passNumber % 2 == 0) {\n\t\t\t\n\t\t\t\tnewNum *= 2;\n\t\t\t\t\n\t\t\t\t//add digits together if two digit number \n\t\t\t\tif (newNum > 9) {\n\t\t\t\t\tint sum = 0;\n\t\t\t\t\t\n\t\t\t\t\twhile(newNum > 0) {\n\t\t\t\t\t\tsum = sum + newNum % 10;\n\t\t\t\t\t\tnewNum = newNum / 10;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tnewNum = sum;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t//replace number in list with new number\n\t\t\t\tlist.set(i, newNum);\n\t\t\t}\n\t\t\t\n\t\t}\n\t}", "public boolean add(int inputIndex, int number) \n\t{\n\t\tif (inputIndex < arraySize)\n\t\t{\n\t\t\tif (arraySize >= array.length)\n\t\t\t{\n\t\t\t\tthis.ensureCapacity(array.length * 2 + 1);\n\t\t\t}\n\t\t\tfor (int index = arraySize; index > inputIndex; index--)\n\t\t\t{\n\t\t\t\tarray[index] = array[index - 1];\n\t\t\t}\n\t\t\tarray[inputIndex] = number;\n\t\t\tarraySize++;\n\t\t\treturn true;\n\t\t}\n\t\tSystem.out.println(\"Syntax error, array is empty.\");\n\t\treturn false;\n\t\t\t\n\t}", "public void add(int number) {\n if(numbers.size() > 0){\n \tSet<Integer> twoSum = numbers.stream().map(Integer::intValue).map(i -> i+number).collect(Collectors.toSet());\n twoSums.addAll(twoSum);\n }\n numbers.add(number);\n }", "public static void main(String[] args) {\n\t\tint[] digits = {9,9,9,8};\n\t\tint[] array = plusOne(digits);\n\t\tfor(int i=0;i<array.length;i++){\n\t\t\tSystem.out.print(array[i]);\n\t\t}\n\t}", "public static boolean solution1(int[] nums, int numToAddTo){\n for (int i = 0; i < nums.length; i++){\n for (int j = i+1; j < nums.length; j++){\n if (nums[i] + nums[j] == numToAddTo){\n return true;\n }\n }\n }\n return false;\n }", "void add (int value) {\n array[fillLength] = value;\n fillLength++;\n for (int i = fillLength - 1; i > 0; i--) {\n if (array[i - 1] > array[i]) {\n int tempHolder = array[i];\n array[i] = array[i - 1];\n array[i - 1] = tempHolder;\n } else {\n break;\n }\n }\n }", "private void removeLeadingZeroes() {\n // Iterate the number until that appears a number greater than 0\n while (number.size() > 0 && number.get(number.size() - 1) == 0) {\n number.remove(number.size() - 1);\n }\n\n // If the list is empty so the number is zero\n if (number.isEmpty()) {\n number.add(0);\n isPositive = true;\n }\n }", "public int addDigits(int num) {\n \tif (num == 0) {\n \t\treturn 0;\n \t}\n\n // the possible solution are between 1 and 9, and they always occur in order beginning from 1\n \tif (num % 9 == 0) {\n \t\treturn 9;\n \t}\n return num % 9;\n }", "static void shortInc(int []x) {\n\t\tint temp = x[0];\n\t\t\n\t\tfor(int i = 0 ; i < x.length; i++) {\n\t\t\tfor(int j = i + 1 ; j < x.length ; j++) {\n\t\t\t\tif(x[i] > x[j]) {\n\t\t\t\t\ttemp = x[i];\n\t\t\t\t\tx[i] = x[j];\n\t\t\t\t\tx[j] = temp;\n\t\t\t\t}\n\t\t\t}\n\t\t\n\t\t}\n\t\tSystem.out.println(\"Mang tang dan la:\\n\");\n\t\tfor(int i = 0 ; i < x.length ; i++) {\n\t\t\tSystem.out.printf(\"%d\\t\",x[i]);\n\t\t}\n\t}", "public int solution(int[] A) {\n // write your code in Java SE 8\n List<Integer> a = new ArrayList<>();\n for(int i = 0 ; i < A.length ; i++) {\n if(A[i] > 0) a.add(A[i]);\n }\n\n if(a.size() == 0) {\n return 1;\n }\n\n Collections.sort(a);\n int result = 1;\n for(Integer number : a) {\n if(number == result)\n result++;\n }\n return result;\n }", "private static void findMissingAndDuplicateNumberFrom1toN(int[] input) {\n\t\tint len = input.length;\n\t\tint i = 0;\n\n\t\twhile (i < len) {\n\t\t\t//if its already in correct place\n\t\t\tif (input[i] == i + 1) {\n\t\t\t\ti++;\n\t\t\t\tcontinue;\n\t\t\t} else if (input[i] == input[input[i] - 1]) { //if the elment to be swapped with are same\n\t\t\t\ti++;\n\t\t\t\tcontinue;\n\t\t\t} else {\n\t\t\t\tint temp = input[i];\n\t\t\t\tinput[i] = input[input[i] - 1];\n\t\t\t\tinput[temp - 1] = temp;\n\t\t\t}\n\t\t}\n\n\t\tfor (i = 0; i < len; i++) {\n\t\t\tif (input[i] != i + 1) {\n\t\t\t\tSystem.out.println(\"Missing number : \" + (i + 1));\n\t\t\t\tSystem.out.println(\"Duplicate number : \" + input[i]);\n\t\t\t}\n\t\t}\n\n\t}", "public List<Integer> addToArrayForm(int[] nums, int k) {\n List<Integer> result = new LinkedList<>();\n int i = nums.length - 1;\n int carry = 0;\n while (i >= 0 || k > 0 || carry > 0) {\n int sum = carry;\n sum += i >= 0 ? nums[i--] : 0;\n sum += k % 10;\n result.add(0, sum % 10);\n carry = sum / 10;\n k /= 10;\n }\n return result;\n }", "static void move_1 (int[] nums) {\n\t\t\n\t\tint j = 0;\n\t\t\n\t\t// Copy all non 0 numbs to start of arry \n\t\t// j will keep count of nums of zeros \n\t\tfor(int i=0; i< nums.length; i++) {\n\t\t\t\n\t\t\tif(nums[i] != 0) {\n\t\t\t\tnums[j] = nums[i];\n\t\t\t\tj++;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// add j number of zeros to end of array\n\t\tfor(int i=j ; i<nums.length; i++) {\n\t\t\t\n\t\t\tnums[i] = 0;\n\t\t}\n\t\t\n\t}", "static Node addOne(Node head){\n Node currentNode = head;\n int carry = 1;\n Node previousNode = null;\n\n while(currentNode!=null){\n int newValue = currentNode.data + carry;\n currentNode.data = newValue%10;\n carry = newValue/10;\n previousNode = currentNode;\n currentNode = currentNode.next;\n }\n if(carry > 0){\n previousNode.next = new Node(carry);\n }\n return head;\n }", "public static int sumDigits(int number){\n if(number < 10){\r\n return -1;\r\n }\r\n\r\n\r\n //need to assign the digit to an empty variable\r\n int sum = 0;\r\n\r\n while(number > 0){\r\n\r\n //assign last digit in number to variable\r\n int last_digit = number%10;\r\n\r\n //add last_digit to sum\r\n sum += last_digit;\r\n\r\n //drop the least significant digit\r\n number = number/10;\r\n\r\n //number is now the digits without the last digit and this new number is used to test the loop\r\n }\r\n\r\n return sum;\r\n\r\n\r\n\r\n }", "public List<Integer> addToArrayForm(int[] nums, int k) {\n List<Integer> result = new ArrayList<>();\n int i = nums.length - 1;\n int carry = 0;\n while (i >= 0 || k > 0 || carry > 0) {\n int sum = carry;\n sum += i >= 0 ? nums[i--] : 0;\n sum += k % 10;\n result.add(sum % 10);\n carry = sum / 10;\n k /= 10;\n }\n Collections.reverse(result);\n return result;\n }", "public static void main(String[] args) {\n Scanner in = new Scanner(System.in);\n int size = in.nextInt();\n int[] a = new int[100];\n for (int i = 0; i < size; i++) {\n int j = in.nextInt();\n a[j] = a[j] + 1;\n }\n\n for(int n : a){\n System.out.print(n+\" \");\n }\n System.out.println(\"\");\n }", "@Override\n public int incrementFirstValue(int key) {\n return array.incrementEntry(key << 1, 1);\n }", "private void addition()\n {\n\tint tempSum = 0;\n\tint carryBit = 0;\n\tsum = new Stack<String>();\n\tStack<String> longerStack = pickLongerStack(number, otherNumber);\n\twhile(!longerStack.isEmpty())\n\t{\n\t tempSum = digitOf(number) + digitOf(otherNumber) + carryBit; //adding\n\t carryBit = tempSum / 10;\n\t sum.push((tempSum % 10) + \"\"); //store the digit which is not carryBit\n\t}\n\tif(carryBit == 1) sum.push(\"1\"); //the last carry bit need to be add as very first digit of sum if there is carry bit\n }", "public int solution(int[] A)\n {\n \n if(A.length == 0 && A.length == 1)\n return 0;\n \n int currentOneSum = 0;\n int totalOneSum = 0;\n int currentZeros = 0;\n \n for (int i = 0; i < A.length; i++)\n \n if(A[i] == 1)\n \n currentOneSum++;\n \n if(A[i] == 0 || i == A.length-1)\n \n totalOneSum += currentZeros * currentOneSum;\n currentOneSum = 0;\n currentZeros++;\n \n return Math.abs(totalOneSum) <= Math.pow(10,9) ? totalOneSum : -1;\n \n }", "private int condense(int[] inputs) {\n\t\tint total = 0;\n\t\tflag = false;\n\t\tfor(int i = 0; i < inputs.length; i++) {\n\t\t\tinputs[i] -= 48;\n\t\t\tif(inputs[i] < 0 || inputs[i] > 9) {\n\t\t\t\tflag = true;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\ttotal *= 10;\n\t\t\ttotal += inputs[i];\n\t\t}\n\t\treturn total;\n\t}", "public void Add(int[] item) {\n Add(item.length * 4);\n\n\n for (int i = 0; i < item.length; i++) {\n AddInt(item[i]);\n }\n mLenght += Integer.SIZE / 8 * item.length;\n mBackOffset = mLenght;\n }", "private void add() {\n // PROGRAM 1: Student must complete this method\n // This method must use the addBit method for bitwise addition.\n adder = addBit(inputA[0],inputB[0], false); //begin adding, no carry in\n output[0] = adder[0]; //place sum of first addBit iteration into output[0]\n //loop thru output beginning at index 1 (since we already computed index 0)\n for (int i = 1; i < output.length; i++) {\n cin = adder[1]; //set carry-out bit of addBit() iteration to cin\n adder = addBit(inputA[i], inputB[i], cin); //call addBit with index i of inputA and inputB and cin and place into adder.\n output[i] = adder[0]; //place sum into output[i]\n }\n }", "public static int[] exe1(int[] arr){ // Solution O(n) in time and constant in Memory\n int nzeros=0;\n\n for (int i=0; i<arr.length; i++) {\n arr[i-nzeros] = arr[i];\n if (arr[i] == 0) {\n nzeros++;\n }\n }\n for (int i=arr.length-1; i>arr.length-nzeros-1; i--) {\n arr[i] = 0;\n }\n\n return arr;\n }", "public static byte[] unsignedCopyAndIncrement(final byte[] input) {\n byte[] copy = copy(input);\n if (copy == null) {\n throw new IllegalArgumentException(\"cannot increment null array\");\n }\n for (int i = copy.length - 1; i >= 0; --i) {\n if (copy[i] == -1) {// -1 is all 1-bits, which is the unsigned maximum\n copy[i] = 0;\n } else {\n ++copy[i];\n return copy;\n }\n }\n // we maxed out the array\n byte[] out = new byte[copy.length + 1];\n out[0] = 1;\n System.arraycopy(copy, 0, out, 1, copy.length);\n return out;\n }", "public static void main(String[] args) {\n\n\t\tint[] digits={9,9,9,9};\n\t\t//System.out.println(plusOne(digits).toString());\n\t}", "public void add(int number) {\n numbers.put(number, numbers.getOrDefault(number, 0)+1);\n }", "static void compute(List<Integer> slate, int[] input) {\n if (input.length == 0)\n System.out.println(slate);\n else {\n int[] copy = Arrays.copyOfRange(input, 1, input.length);\n compute(slate, copy);\n slate.add(input[0]);\n compute(slate, copy);\n slate.remove(slate.size() - 1);\n }\n }", "static int addZero(int num, int n) {\n\t\t\t\n\t\t\treturn 0;\n\t\t}", "public static void main(String[] args) {\n\t\tint[] c = new int[]{9,9};\r\n\t\tint[] s = plusOne(c);\r\n\t\tfor(int i=0;i<s.length;i++)\r\n\t\t\tSystem.out.println(s[i]);\r\n\t}", "public boolean add(int number)\n\t{\n\t\tif (arraySize >= array.length)\n\t\t{\n\t\t\tthis.ensureCapacity(array.length * 2 + 1);\n\t\t} \n\t\tarray[arraySize] = number;\t\n\t\tarraySize++;\n\t\treturn true;\n\t}", "private int[] inc(int[] a)\n {\n int tI = a.length - 1;\n long m = 0;\n\n m = (((long)a[tI]) & IMASK) + 1L;\n a[tI--] = (int)m;\n m >>>= 32;\n\n while (tI >= 0 && m != 0)\n {\n m += (((long)a[tI]) & IMASK);\n a[tI--] = (int)m;\n m >>>= 32;\n }\n\n return a;\n }", "private int[] inc(int[] a)\n {\n int tI = a.length - 1;\n long m = 0;\n\n m = (((long)a[tI]) & IMASK) + 1L;\n a[tI--] = (int)m;\n m >>>= 32;\n\n while (tI >= 0 && m != 0)\n {\n m += (((long)a[tI]) & IMASK);\n a[tI--] = (int)m;\n m >>>= 32;\n }\n\n return a;\n }", "public static int[] process(int[] prevHolder) { \r\n\t\t int[] holder = new int[prevHolder.length + 1];\r\n\t \r\n\t /**the first entry in holder will always be 1*/\t \r\n\t holder[0] = 1;\r\n\t \r\n\t /**this loop populates the numbers inbetween the first and last index values, the first and last values are already handled*/\r\n\t for (int i = 1; i < holder.length - 1; i++) {\r\n\t \t holder[i] = prevHolder[i-1] + prevHolder[i];\r\n\t }\r\n\t \r\n\t /**the last entry in holder is always 1*/\r\n\t holder[holder.length - 1] = 1;\r\n\t \r\n\t \r\n\t /**returns the result from this iteration of the for loop in the main method to be used in the next iteration*/\t \r\n\t return holder;\r\n\t }", "public void addElement(int element) {\n \tif(element > 0) {\n \tarray[head++] = element;\n \t}else {\n \t\tthrow new RuntimeException(\"Invalid element to add\");\n \t}\n }", "public static int addDigits(int x)\n\t{\n\t\t//Method variable\n\t\tint sum = 0;\n\t\t//Assign while loop and return a value.\n\t\twhile(x>0)\n\t\t{\n\t\t\t sum = x%10+sum;\n\t\t\t x=x/10;\n\t\t}\n\t\treturn(sum);\n\t}", "private static int sumDigits(int number)\n {\n if (number < 10)\n return -1;\n int sum = 0, leastSignificantBit = 0;\n\n while (number > 0)\n {\n //extract the least significant bit\n leastSignificantBit = number % 10;\n sum += leastSignificantBit;\n\n //drop the least significant digit\n number /= 10;\n }\n return sum;\n }", "public int addDigits(int num) {\n\t\tint no = num;\n\t\twhile (no / 10 > 0) {\n\t\t\tint sum = 0;\n\t\t\twhile (no > 0) {\n\t\t\t\tint rem = no % 10;\n\t\t\t\tsum += rem;\n\t\t\t\tno = no / 10;\n\t\t\t}\n\n\t\t\tno = sum;\n\n\t\t}\n\t\treturn no;\n\t}", "public void addNumSorted(int a){\n\t\tSystem.out.println(\"Testing... \" + a);\n\t\tif(this.prevNum != null){\n\t\t\tListUtilities temp = new ListUtilities();\n\t\t\tSystem.out.println(\"Reversing \" + a);\n\t\t\ttemp = this.prevNum;\n\t\t\tSystem.out.println(\"Returned to \" + temp.num);\n\t\t\ttemp.addNumSorted(a);\n\t\t\t\n\t\t}\n\t\tif(this.prevNum == null && this.num > a){\n\t\t\t//if at the beginning, and lowest number, insert at beginning\n\t\t\tSystem.out.println(\"Adding to beginning... \" + a);\n\t\t\tListUtilities newNode = new ListUtilities(a);\n\t\t\tnewNode.nextNum = this;\n\t\t\tthis.prevNum = newNode;\n\t\t\tSystem.out.println(this.num + \" is now attached to \" + this.prevNum.num);\n\t\t\treturn;\n\t\t}else if(this.nextNum == null && this.num < a){\n\t\t\t//if at the end and highest number insert at the end\n\t\t\tSystem.out.println(\"Adding to the end... \" + a);\n\t\t\tListUtilities newNode = new ListUtilities(a);\n\t\t\tthis.nextNum = newNode;\n\t\t\tnewNode.prevNum = this;\n\t\t\treturn;\n\t\t}else if (this.num < a && this.nextNum.num > a){\n\t\t\t//insert in between lower and higher numbers\n\t\t\tSystem.out.println(\"Inserting \" + a + \" in between \" + this.num + \" and \" + this.nextNum.num);\n\t\t\tListUtilities newNode = new ListUtilities(a);\n\t\t\tnewNode.nextNum = this.nextNum;\n\t\t\tthis.nextNum.prevNum = newNode;\n\t\t\tthis.nextNum = newNode;\n\t\t\tnewNode.prevNum = this;\n\t\t\treturn;\n\t\t}\n\t}", "public static int missingNumber (int [] nums){\n sort(nums);\n for (int i = 0; i<nums.length-1; i++) {\n if (nums[i+1]>nums[i]+1){ \n return nums[i]+1;\n\n }\n\n }\n\n return 0;\n }", "public int removeDuplicatesMethod1(int[] nums) {\n \tif(nums == null) {\n \t\treturn 0;\n \t}\n int len = nums.length;\n if(len == 0) {\n \treturn 0;\n }\n int endOfNewArray = 0;\n int cnt = 1;\n int temp = nums[0];\n for(int i = 1; i < len; i++) {\n \tif(nums[i] == temp) {\n \t\tif(cnt < 2) {\n \t\t\tcnt++;\n \t\t\tnums[++endOfNewArray] = nums[i];\n \t\t}\n \t}else {\n \t\tcnt = 1;\n \t\tnums[++endOfNewArray] = nums[i];\n \t\ttemp = nums[i];\n \t}\n }\n return ++endOfNewArray;\n }", "public int singleNumber(int[] nums) {\n Map<Integer,Integer> elements_in_nums = new HashMap<>();\n for(int num : nums){\n if(elements_in_nums.containsKey(num)) \n elements_in_nums.put(num, elements_in_nums.get(num) + 1);\n else elements_in_nums.put(num ,1);\n }\n for(int key : elements_in_nums.keySet()) {\n if(elements_in_nums.get(key) == 1) return key;\n }\n return -1; //this part will never be reached because we return the key before here\n }", "private byte[] increment(byte[] array) {\n for (int i = array.length - 1; i >= 0; --i) {\n byte elem = array[i];\n ++elem;\n array[i] = elem;\n if (elem != 0) { // Did not overflow: 0xFF -> 0x00\n return array;\n }\n }\n return null;\n }", "private void addOne(String value){\n\t\tif (numCache.containsKey(value)){\n\t\t\tnumCache.put(value, numCache.get(value) + 1);\n\t\t}else{\n\t\t\tnumCache.put(value, 1);\n\t\t}\n\t}", "private void addNumberToArrayByIndex(Number[] array, Number number, int index) {\n if (index >= array.length) {\n array = arrayExtension(array);\n }\n array[index] = number;\n }", "public int addDigits(int num) {\n\tif(num<10)\n\t return num;\n\telse if(num%9 ==0)\n\t return 9;\n\telse\n\t return num%9; \n}", "public int singleNumber(int[] nums) {\n Arrays.sort(nums);\n for (int i = 0; i < nums.length - 1; i += 2) {\n if (nums[i] != nums[i + 1]) {\n return nums[i];\n }\n }\n return nums[nums.length - 1];\n }", "public static int sumatory(int [] mySingleArray) {\r\n int counter = 0, sum = 0;\r\n while (counter < mySingleArray.length){\r\n sum = sum + mySingleArray[counter];\r\n counter++;\r\n }\r\n return sum;\r\n }", "public String compress(int[] numberList)\n {\n String str=\"\";\n int num = numberList[0];\n int count = 0; // counter\n for (int i=0; i<numberList.length; i++)\n {\n if (numberList[i]!=num) // if number change\n {\n str += \"[\"+count+\"]\"+num; // add the string for this number\n num = numberList[i]; // update the new number\n count = 1; // reset the counter\n } else {\n count ++;\n }\n }\n \n if (count==0) // if the last number is not duplicate one\n {\n str += \"[1]\"+num;\n } else // if the last number is duplicate one\n {\n str += \"[\"+count+\"]\"+num; // add the string\n }\n \n return str;\n }", "public int addValue(int[] array) {\n int val = hashCode();\n for (int i : array) {\n val = addValue(i);\n }\n return val;\n }", "public static int sum1(int[] a, int n) // summen av de n første\n {\n if (n == 1) return a[0]; // summen er verdien selv\n return sum1(a,n-1) + a[n-1]; // summen av de n-1 første + a[n-1]\n }", "private static int[] add(int[] x, int[] y) {\n // If x is shorter, swap the two arrays\n if (x.length < y.length) {\n int[] tmp = x;\n x = y;\n y = tmp;\n }\n\n int xIndex = x.length;\n int yIndex = y.length;\n int result[] = new int[xIndex];\n long sum = 0;\n if (yIndex == 1) {\n sum = (x[--xIndex] & LONG_MASK) + (y[0] & LONG_MASK) ;\n result[xIndex] = (int)sum;\n } else {\n // Add common parts of both numbers\n while (yIndex > 0) {\n sum = (x[--xIndex] & LONG_MASK) +\n (y[--yIndex] & LONG_MASK) + (sum >>> 32);\n result[xIndex] = (int)sum;\n }\n }\n // Copy remainder of longer number while carry propagation is required\n boolean carry = (sum >>> 32 != 0);\n while (xIndex > 0 && carry)\n carry = ((result[--xIndex] = x[xIndex] + 1) == 0);\n\n // Copy remainder of longer number\n while (xIndex > 0)\n result[--xIndex] = x[xIndex];\n\n // Grow result if necessary\n if (carry) {\n int bigger[] = new int[result.length + 1];\n System.arraycopy(result, 0, bigger, 1, result.length);\n bigger[0] = 0x01;\n return bigger;\n }\n return result;\n }", "public static int[] addElement(int[] a, int e) {\n\t a = Arrays.copyOf(a, a.length + 1);\n\t a[a.length - 1] = e;\n\t return a;\n\t}", "public void add(int num) {\n // if the array is not large enough, an array of twice\n // the capacity is created\n if (count + 1 > list.length) {\n int[] temp = new int[list.length * 2];\n for (int i = 0; i < list.length; i++) {\n temp[i] = list[i];\n }\n list = temp;\n temp = null;\n }\n \n // add the element to the array and increment the count\n list[count++] = num;\n }", "static int[] Summe(int[] a, int[] b){\n int index = 0, i = a.length - 1;\n int[] c = new int [a.length + 1];\n Arrays.fill(c, 0);\n while (i >= 0){\n c[i+1] = (a[i] + b[i] + index) % 10;\n if ((a[i] + b[i] + index) > 9) index = 1;\n else index = 0;\n i -= 1;\n }\n if (index == 1) c[0] = 1;\n return c;\n }", "public int addDigits(int num) {\n\t\tif (num <= 0) {\n\t\t\treturn 0;\n\t\t}\n\t\twhile (num >= 10) {\n\t\t\tint n = 0;\n\t\t\twhile (num > 0) {\n\t\t\t\tn += num % 10;\n\t\t\t\tnum /= 10;\n\t\t\t}\n\t\t\tnum = n;\n\t\t}\n\t\treturn num;\n\t}", "public int singleNumber1(int[] nums) {\n HashMap<Integer,Integer> map = new HashMap<>();\n for (int i = 0; i < nums.length; i++) {\n if (!map.containsKey(nums[i])) {\n map.put(nums[i],1);\n }\n else {\n map.remove(nums[i]);\n }\n }\n //set<Integer> keys = map.keySet();\n return (int)map.keySet().toArray()[0];\n \n \n \n }", "private void addTwoNumbers() {\n\t\t\n\t}", "public static void add(int... arr) {\r\n long result = 0;\r\n for (int i : arr) {\r\n result += i;\r\n }\r\n System.out.println(\"Addition is \" + result);\r\n }", "public static int maxOne(int arr[]) {\n\t\tint n =arr.length;\n\t\tint newArr[]= new int[n];\n\t\tint j=0;\n\t\tfor(int i=0; i<n; i++) {\n\t\t\tif (arr[i]== 0) {\n\t\t\t\tnewArr[j]=i;\n\t\t\t\tj++;\n\t\t\t}\n\t\t}\n\t\tint max=0;\n\t\tint temp=0;\n\t\tfor (int i=1; i<=j; i++) {\n\t\t\ttemp=newArr[i]- newArr[i-1];\n\t\t\tmax=Math.max(max, temp);\n\t\t}\n\treturn max+1;\n\t}", "private int plusOne(int i) {\n return (i + 1) % capacity;\n }", "public List<Integer> findDuplicates(int[] nums) {\n List<Integer> list = new ArrayList<>();\n for (int num : nums) {\n num = Math.abs(num);\n if (nums[num - 1] < 0) {\n list.add(num);\n } else {\n nums[num - 1] = - nums[num - 1];\n }\n }\n return list;\n }", "public void add(int number) {\n\t if(!m.containsKey(number)) {\n\t m.put(number, 0);\n\t }\n\t int pre = m.get(number);\n\t m.put(number, pre + 1);\n\t}", "public V addElement(T t) {\n\t\tif(multiSet.containsKey(t)){\n\t\t\tNumber newValue = ((Integer)multiSet.get(t)) + 1;\n\t\t\tmultiSet.replace(t,(V)newValue);\n\t\t\treturn (V)newValue;\n\t\t}\n\t\tNumber firstValue = 1;\n\t\tmultiSet.put(t,(V)firstValue);\n\t\treturn (V)firstValue;\n\t}", "public void add(int x)\n {\n int arrayLength = list.length; // get size of array\n if (length == arrayLength)\n {\n list = Arrays.copyOf(list, 100 + list.length);\n list[length] = x;\n length++;\n\n } else\n {\n list[length] = x;\n length++;\n }\n }", "public static void addOne(int x) {\n // i want to keep adding one to x\n // until x is 10\n // you can do a while loop, or you can do a for loop\n System.out.println(x);\n if (x < 10) {\n addOne(x + 1);\n }\n }", "public static void addNumbers(int... nums) {\n\n // inside the method , it used as regular array\n int sum =0;\n\n for(int each : nums){\n sum += each;\n }\n System.out.println(\"sum = \" + sum);\n\n }", "public void add(BinaryNumber aBinaryNumber) {\n\t\tint c = 0;\n\t\tif(length < aBinaryNumber.length) {\n\t\t\tprepend(Math.abs(this.length - aBinaryNumber.length), this);\n\t\t}\n\t\tif(length > aBinaryNumber.length) {\n\t\t\tprepend(Math.abs(this.length - aBinaryNumber.length), aBinaryNumber);\n\t\t}\n\t\tint added[] = new int[this.length];\n\t\tfor(int i = data.length-1;i >= 0; i--) {\n\t\t\tif(aBinaryNumber.data[i] + data[i] + c == 0) {\n\t\t\t\tadded[i] = 0;\n\t\t\t\tc = 0;\n\t\t\t}\n\t\t\telse if(aBinaryNumber.data[i] + data[i] + c == 2) {\n\t\t\t\tadded[i] = 0;\n\t\t\t\tc = 1;\n\t\t\t}\n\t\t\telse if (aBinaryNumber.data[i] + data[i] + c == 3){\n\t\t\t\tadded[i] = 1;\n\t\t\t\tc = 1;\n\t\t\t}\n\t\t\telse {\n\t\t\t\tadded[i] = 1;\n\t\t\t\tc=0;\n\t\t\t}\n\t\t}\n\t\tthis.data = added.clone();\n\t\tif( c == 1)\n\t\t{\n\t\t\tprepend(c, this);\n\t\t\tdata[0] = 1;\n\t\t}\t\n\t}", "public static int calculateSyndrome1(int[] inputArray) {\n return (inputArray[0] +\n inputArray[1] +\n inputArray[2] +\n inputArray[3] +\n inputArray[4] +\n inputArray[5] +\n inputArray[6] +\n inputArray[7] +\n inputArray[8] +\n inputArray[9]) % 11;\n }", "ListNode addTwoNumbers(ListNode l1, ListNode l2) {\n ListNode curL1 = l1;\n ListNode curL2 = l2;\n int add = 0;\n while (curL1 != null && curL2 != null) {\n int result = 0;\n int total = curL1.val + curL2.val + add;\n if (total >= 10) {\n result = total % 10;\n add = 1;\n } else {\n result = total;\n add = 0;\n }\n curL1.val = result;\n if (curL2.next != null && curL1.next == null) {\n curL2.next.val += add;\n curL1.next = curL2.next;\n break;\n }\n if (curL1.next != null && curL2.next == null) {\n curL1.next.val += add;\n break;\n }\n if (curL1.next == null && curL2.next == null && add == 1) {\n curL1.next = new ListNode(1);\n break;\n }\n curL1 = curL1.next;\n curL2 = curL2.next;\n }\n if (curL1 != null && curL1.next != null) {\n curL1 = curL1.next;\n }\n while (curL1 != null) {\n if (curL1.val >= 10) {\n curL1.val = curL1.val % 10;\n if (curL1.next == null) {\n curL1.next = new ListNode(1);\n curL1 = curL1.next;\n } else {\n curL1 = curL1.next;\n curL1.val += 1;\n }\n\n } else {\n break;\n }\n }\n return l1;\n }", "public int countOnes(int[] a) {\n int tot = 0;\n for (int i=0; i<a.length; i++) {\n tot += a[i];\n }\n return tot;\n }", "private static BigInteger forceAdd(BigInteger first, BigInteger second) {\n\t\tBigInteger i = new BigInteger();\n\t\tint sign1 = first.sign(), sign2 = second.sign();\n\t\ti.front = new DigitNode(0, null); // dummy\n\t\tfor(DigitNode n1 = first.front, n2 = second.front, n = i.front; n1 != null || n2 !=null; n = n.next) {\n\t\t\tint value = 0;\n\t\t\tif (n1 != null) {\n\t\t\t\tvalue += n1.digit*sign1;\n\t\t\t\tn1 = n1.next;\n\t\t\t}\n\t\t\tif (n2 != null) {\n\t\t\t\tvalue += n2.digit*sign2;\n\t\t\t\tn2 = n2.next;\n\t\t\t}\n\t\t\tn.next = new DigitNode(value, null);\n\t\t\tif (value != 0) i.negative = (value < 0);\n\t\t\ti.numDigits++;\n\t\t}\n\t\ti.front = i.front.next; //skip the dummy\n\t\treturn i;\n\t}", "public int findDuplicate(int[] nums) {\n if(nums == null) return 0;\n\n for(int i = 0; i < nums.length; i++) {\n int index = Math.abs(nums[i]);\n if(nums[index - 1] < 0) {\n return index;\n }\n nums[index - 1] = -nums[index - 1];\n }\n return 0;\n}", "public int addValue(short[] array) {\n int val = hashCode();\n for (short i : array) {\n val = addValue(i);\n }\n return val;\n }", "public static void main(String args[] ) throws Exception {\n Scanner in = new Scanner(System.in);\n \n String original = in.next();\n int n = original.length();\n long moda = 1000000007;\n long ones = 1;\n long sum=0; \n for (int s=original.length()-1; s>=0; s--) {\n sum = (sum + (s+1) * (original.charAt(s) - '0') * ones) %moda; \n ones = (ones * 10 + 1) % moda;\n \n }\n \n System.out.println(sum);\n \n }", "private static int missingNumber(int[] nums) {\n\t\t// TODO Auto-generated method stub\n\t\tint sum = 0; \n\t\tint end = nums.length; \n\t\t\n for(int i=0; i<end; i++){\n sum += i;\n sum = sum - nums[i];\n }\n \n sum = sum + end; \n\t\t\t\t\n\t\treturn sum;\n\t}", "public static int missingNumber(int[] nums) {\r\n int length = nums.length;\r\n //as 0 needs to be removed\r\n int sum = 0;\r\n int i=0;\r\n for(i=0; i<length; i++){\r\n \tsum += i;\r\n \tsum -= nums[i];\r\n }\r\n sum += i;\r\n return sum;\r\n }", "public static void main(String[] args) {\n Scanner in = new Scanner(System.in);\n int dec = in.nextInt();\n Stack<Integer> st = new Stack<Integer>();\n int rm = 0;\n while(dec>0){\n rm = dec%2;\n dec = dec/2;\n st.push(rm);\n }\n \n int size = st.size();\n int[] array = new int[size];\n for(int i = 0 ; i < size; i++){\n array[i] = st.pop();\n }\n \n int countOne = 0;\n int maxOne =0;\n for(int j = 0 ; j < size ; j++){\n if(array[j] == 0){\n countOne = 0; \n } \n else{\n countOne++;\n maxOne = Math.max(maxOne,countOne);\n }\n }\n System.out.println(maxOne);\n }", "static int incrementRepsRPE(String input) {\n int value;\n if (input.matches(\"\")) {\n value = 1;\n return value;\n }\n value = Integer.parseInt(input);\n value = value + 1;\n return value;\n }", "void overflowDigits() {\n for (int i = 0; i < preDigits.length(); i++) {\n char digit = preDigits.charAt(i);\n // This could be implemented with a modulo, but compared to the main\n // loop this code is too quick to measure.\n if (digit == '9') {\n preDigits.setCharAt(i, '0');\n } else {\n preDigits.setCharAt(i, (char)(digit + 1));\n }\n }\n }", "private static int solve(ArrayList<Integer> digits, int b, int c) {\n for (int i=0;i<digits.size();i++) {\r\n int num = digits.get(i);\r\n int numDigits=b-1;\r\n for (int j=0; j<i && numDigits>0 ; j++) {\r\n num = num*10 + digits.get(j);\r\n }\r\n for (int j=i+1;j<digits.size();j++) {\r\n num = num*10 + digits.get(j);\r\n }\r\n }\r\n \r\n return 0;\r\n }", "public void missingNumberInArray() {\n\t\tint[] a = { 1, 2, 3, 4, 5, 6, 8 };\n\t\tint sum=0;\n\t\tfor (int i = 0; i < a.length; i++) {\n\t\t\tsum+=a[i];\n\t\t}\n\t\t\n\t\tSystem.out.println(sum);\n\n\t}", "public String multiply(String num1, String num2) {\n int[] n1 = new int[num1.length()];\r\n for(int i = 0; i < num1.length(); i++) {\r\n \tn1[i] = num1.charAt(i) - '0';\r\n }\r\n int[] n2 = new int[num2.length()];\r\n for(int i = 0; i < num2.length(); i++) {\r\n \tn2[i] = num2.charAt(i) - '0';\r\n }\r\n //the result\r\n int[] result = new int[num1.length() + num2.length()];\r\n \r\n //multiple two large numbers\r\n for(int i = n2.length - 1; i >=0; i--) {\r\n \t//the starting point in the result array\r\n \tint v2 = n2[i];\r\n \tint startPoint = result.length - 1 - (n2.length - 1 - i);\r\n \tint carrier = 0;\r\n \tfor(int j = n1.length - 1; j >= 0; j--) {\r\n \t\tint index = startPoint - (n1.length - 1 - j);\r\n \t\tint v1 = n1[j];\r\n \t\t\r\n// \t\tSystem.out.println(\"i: \" + i + \": \" + v2 + \", j: \" + j + \": \" + v1 + \", carrier: \" + carrier);\r\n \t\t\r\n \t\tint finalValue = v1*v2 + carrier + result[index];\r\n \t\tcarrier = finalValue/10;\r\n \t\tresult[index] = finalValue % 10;\r\n \t\t//update the last\r\n \t\tif(j == 0) {\r\n \t\t\tif(carrier > 0) {\r\n \t\t\t\tresult[index - 1] = carrier; //XXX note, need to write to the array cell\r\n \t\t\t}\r\n \t\t}\r\n \t}\r\n// \tthis.printArray(result);\r\n }\r\n \r\n //convert to the result\r\n StringBuilder sb = new StringBuilder();\r\n boolean zero = true;\r\n for(int i : result) {\r\n \tif(i != 0 && zero) {\r\n \t\tzero = false;\r\n \t}\r\n \tif(!zero) {\r\n \t sb.append(i);\r\n \t}\r\n }\r\n if(sb.length() == 0) {\r\n \tsb.append(\"0\"); //all ZERO\r\n }\r\n return sb.toString();\r\n }", "public static void add(int[] n1, int[] n2, int[] sum) {\n\t\tint b = n1.length-1;\n\t\tint carry = 0;\n\t\twhile (b >= 0) {\n\t\t\tint s = n1[b] + n2[b] + carry;\n\t\t\tsum[b+1] = s % 10;\n\t\t\tif (s > 9) { carry = 1; } else { carry = 0; }\n\t\t\tb--;\n\t\t}\n\t\t\n\t\tsum[0] = carry;\n\t}", "public void moveZeroes(int[] nums) {\n int current = 0, last = 0;\n int temp = 0;\n while(current < nums.length){\n if(nums[current] != 0){\n if(nums[last] != 0){\n last++;\n }\n else{\n if(current != last){\n nums[last] = nums[current];\n nums[current] = 0;\n last++;\n }\n }\n }\n current++;\n }\n}", "public static int sum1DArr(int[] myArr1D)\n {\n return sum1DArrRecursive(myArr1D, 0, myArr1D.length - 1);\n }" ]
[ "0.7427237", "0.7336321", "0.72996575", "0.72180974", "0.71509916", "0.70845586", "0.7079726", "0.696575", "0.6790219", "0.64945126", "0.6063319", "0.59304833", "0.5723381", "0.5722884", "0.56191474", "0.56039363", "0.5495289", "0.5468478", "0.54603624", "0.5444913", "0.5432576", "0.53935814", "0.5384187", "0.53624344", "0.5348452", "0.5339214", "0.53270763", "0.53197145", "0.53007114", "0.5300104", "0.5297059", "0.52936786", "0.52908486", "0.52854055", "0.5282614", "0.5278256", "0.52736855", "0.5271391", "0.526666", "0.5256243", "0.52561545", "0.52522945", "0.52259713", "0.5208708", "0.52084225", "0.520402", "0.520402", "0.5202115", "0.52019274", "0.5201114", "0.51774013", "0.5166369", "0.5161714", "0.51613545", "0.5156719", "0.5151221", "0.5150287", "0.5147358", "0.51373416", "0.5128673", "0.5122649", "0.5118354", "0.5110476", "0.511045", "0.50787157", "0.50745565", "0.5071127", "0.5059123", "0.505699", "0.5052272", "0.50487167", "0.50366557", "0.5034724", "0.50211984", "0.5019757", "0.5016758", "0.50076795", "0.50072616", "0.5006276", "0.50044274", "0.50031453", "0.5001386", "0.49895906", "0.49859476", "0.49756485", "0.49715048", "0.49704236", "0.49658796", "0.49600273", "0.4956151", "0.4946892", "0.49468735", "0.4944963", "0.49417403", "0.49225432", "0.4921026", "0.49188793", "0.4915524", "0.49132296", "0.4913015" ]
0.5570675
16
Constructor setting just the message.
public ServerMessage(String message) { this.message = message; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Message() {\n\t\tsuper();\n\t}", "public Message(){\n this(\"Not Specified\",\"Not Specified\");\n }", "public Message() {\n message = \"\";\n senderID = \"\";\n time = 0;\n }", "public Message(){}", "public Message() {}", "public Message() {}", "public Message() {\n }", "public Message() {\n }", "public Message() {\n }", "public Message() {\n\tkey = MessageKey.NULL;\n\tdata = null;\n\n\tattachment = null;\n }", "public Message(){\n\t\ttimeStamp = System.currentTimeMillis();\n\t}", "private Message(){\n // default constructor\n }", "public Message () {\n\t\tthis.setCreationtime(Calendar.getInstance().getTimeInMillis());\n\t\tsetTimestamp();\n\t}", "public MessageClackData() {\n super();\n this.message = DEFAULT_MESSAGE;\n }", "public SystemMessage() {\r\n\t}", "private SocketMessage() {\n initFields();\n }", "public MessageRecord() {\n super(Message.MESSAGE);\n }", "public Message(){\n this.body = null;\n this.contact = null;\n }", "public ImMessage() {\r\n }", "public CallMessage() {\n\t}", "public Message(String message){\n\t\tthis(message, 5000);\n\t}", "public FlowMonMessage(){}", "public DemoMessage(String message) {\n\t\tthis.message = message;\n\t}", "private void setMessage(final String message) {\n }", "public TriggerMessage() {\n\t}", "private Message(MessageType handle, String srcName, String text) {\n msgType = handle;\n // Save the properly formatted identifier for the user sending the\n // message.\n msgSender = srcName;\n // Save the text of the message.\n msgText = text;\n }", "public NetworkMessage(){\n\t\tthis.user = null;\n\t}", "private Message(MessageType handle) {\n this(handle, null, null);\n }", "public MessageInfo() { }", "public JobServiceBusMessage() {\n this.setCustomMessageProperties(new LazyHashMap<String, String>());\n }", "public ChatRequest(String message)\r\n\t{\r\n\t\tthis.message = message;\r\n\t}", "public void setMessage(String message) { this.message = message; }", "public OAuthMessage() {\n\t\t_parameters = new ParameterList();\n\n\t\tif (DEBUG)\n\t\t\t_log.debug(\"Created empty OAuthMessage.\");\n\t}", "public Message(String type, Object message) {\n\t\tthis.type = type;\n\t\tthis.message = message;\n\t}", "public void setMessage(String message);", "public void setMessage(String message);", "public void setMessage(String message);", "public MessageEvent(Message message) {\n super(message);\n this.message = message;\n }", "public LCAmsg2 () { }", "void setMessage(String message);", "void setMessage(String message);", "public Message(User author, String message) {\n this.author = author;\n this.message = message;\n this.date = new Date();\n }", "public MQMsg() {\n\n messageType = \" \";\n service = \"SSSSSSSS\";\n serverUser = \"UUUUUUUU\";\n serverPassword = \"PPPPPPPP\";\n serverAppl = \"AAAAAAAA\";\n cicsTrx = \"CICS\";\n timeout = 30;\n retcode = 0;\n data = \"\";\n\n }", "public AmqpMessage() {}", "public Message(Socket s, Packet p) {\n // userName = \"\";\n socket = s;\n packet = p;\n }", "public MessageRequest() {\n\t}", "public Message(){\n super();\n this.status = RETURN_OK;\n put(\"status\",this.status.getCode());\n put(\"message\", this.status.getMessage());\n }", "public WfController( MsgObject thisMessage )\n {\n messageObject = thisMessage;\n }", "public messages() {\n }", "public PromoMessages() {\n }", "private Message(MessageType handle, String srcName) {\n this(handle, srcName, null);\n }", "public void setMessage(String message) {\r\n\tthis.message = message;\r\n}", "public Builder setMessage(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n bitField0_ |= 0x00000002;\n message_ = value;\n onChanged();\n return this;\n }", "public Builder setMessage(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n bitField0_ |= 0x00000002;\n message_ = value;\n onChanged();\n return this;\n }", "public Builder setMessage(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n bitField0_ |= 0x00000002;\n message_ = value;\n onChanged();\n return this;\n }", "public Builder setMessage(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n bitField0_ |= 0x00000002;\n message_ = value;\n onChanged();\n return this;\n }", "public Builder setMessage(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n bitField0_ |= 0x00000002;\n message_ = value;\n onChanged();\n return this;\n }", "public Builder setMessage(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n bitField0_ |= 0x00000002;\n message_ = value;\n onChanged();\n return this;\n }", "public HazelcastMQMessage() {\n this(new DefaultHeaders(), null);\n }", "public Message(Message m)\r\n\t{\r\n\t\t_msgBody = m._msgBody;\r\n\t\t_mID = m._mID;\r\n\t\t_fatherMessageID = m._fatherMessageID;\r\n\t\t_msgPosterID = m._msgPosterID;\r\n\t\t_msgPostTime = m._msgPostTime;\r\n\t}", "public Message(String s, String r){\n sender = s;\n reciever = r;\n }", "private Messages() {\n\t}", "public MailMessage() {\n }", "public ServiceMessage() {\r\n\t}", "public Builder setMessage(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n \n message_ = value;\n onChanged();\n return this;\n }", "public Builder setMessage(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n \n message_ = value;\n onChanged();\n return this;\n }", "public Message(String text, Person person) {\n\t\tthis(text, person, null, null);\n\t}", "public User(Message message) {\n\t\tthis.message = message;\n\t\tlogger.info(\"Error has occured :(\");\n\t}", "public MessageBus()\r\n\t{\r\n\t\tthis(null);\r\n\t}", "private HeartBeatMessage() {\n initFields();\n }", "Text(String defaultMessage) {\n this(null, defaultMessage);\n }", "public InvalidRequestMsg() {\n\n this(\"\");\n\n }", "public MessageTran() {\n\t}", "public void setMessage(String message){\n this.message = message;\n }", "public Builder setMessage(\n String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n \n message_ = value;\n onChanged();\n return this;\n }", "public Builder setMessage(\n String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n \n message_ = value;\n onChanged();\n return this;\n }", "public Message(MessageKey key, String data) {\n\tthis.key = key;\n\tthis.data = data;\n\n\tattachment = null;\n }", "public Message(String s,String r,String m){\n sender = s;\n reciever = r;\n message = m;\n }", "public MessageResponse() {\r\n\t}", "public AbstractMessage() {\n\t\t//this.idMessage = SecUtils.getHex(SecUtils.getRandomBytes(SecUtils.getSeed(), 20));\n\t\tthis.idMessage = this.hashCode();\n\t\tthis.setChallenge(new Challenge());\n\t}", "public MyPrinter() {\r\n this.message = \"\";\r\n }", "public Message newMessage(String message, Object p0) {\n/* 69 */ return new SimpleMessage(message);\n/* */ }", "public Message(String key) {\n this.key = key;\n }", "public Builder setMessage(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n \n message_ = value;\n onChanged();\n return this;\n }", "public Builder setMessage(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n \n message_ = value;\n onChanged();\n return this;\n }", "public Builder setMessage(\n java.lang.String value) {\n if (value == null) {\n throw new NullPointerException();\n }\n \n message_ = value;\n onChanged();\n return this;\n }", "public void setMessage(String message)\r\n\t{\r\n\t\tthis.message = message;\r\n\t}", "public void setMessage(String message)\n {\n this.message = message;\n }", "public void setMessage(String message)\n {\n this.message = message;\n }", "public FeedbackMessages()\n\t{\n\t}", "public Message newMessage(String message, Object p0, Object p1, Object p2, Object p3) {\n/* 93 */ return new SimpleMessage(message);\n/* */ }", "public ServerMessage(String message, Player player) {\n this.message = message;\n this.player = player;\n }", "public void setMessage(String aMessage) {\n\t\tthis.message = aMessage;\n\t}", "private Message(Parcel in) {\n text = in.readString();\n sender = in.readString();\n target = in.readString();\n sendersLatitude = in.readDouble();\n sendersLongitude = in.readDouble();\n numHops = in.readInt();\n expirationTime = in.readLong();\n createdByUser = in.readInt();\n }", "private Message(String message, long visibleTime, long creationTime, long id){\n\t\tthis(message, visibleTime);\n\t\tthis.creationTime = creationTime;\n\t\tthis.id = id;\n\t}", "private void setupMessage() {\n \tmessage = new GLabel(\"\");\n \tmessage.setFont(\"SansSerif-12\");\n }", "public MassMsgFrame() {\n\t}", "private Message(Builder builder) {\n super(builder);\n }", "public HelperMessagePanel(String message) {\n\t\tthis.message = message;\n\t}", "public EventMessage(Event event)\r\n {\r\n //super(\"EventMessage\");\r\n super(TYPE_IDENT, event);\r\n }" ]
[ "0.79360473", "0.78262585", "0.779054", "0.769326", "0.7564121", "0.7564121", "0.7527258", "0.75064313", "0.75064313", "0.7402559", "0.73077303", "0.7303897", "0.7248638", "0.7234002", "0.7219816", "0.71476495", "0.7115503", "0.7088212", "0.707409", "0.70706844", "0.7030965", "0.70191556", "0.6977955", "0.6954626", "0.6951994", "0.6944187", "0.6910259", "0.68822265", "0.6875637", "0.68306446", "0.6807013", "0.68046474", "0.677223", "0.67693144", "0.67556363", "0.67556363", "0.67556363", "0.6747863", "0.6742255", "0.671881", "0.671881", "0.67007625", "0.6674701", "0.6671876", "0.6663014", "0.6661185", "0.66502064", "0.66498303", "0.66471404", "0.6634713", "0.66311604", "0.66190785", "0.6607051", "0.6607051", "0.6606314", "0.6606314", "0.6606314", "0.6606314", "0.6594326", "0.6587679", "0.65847594", "0.65811825", "0.65738666", "0.65590215", "0.654076", "0.654076", "0.6537355", "0.65362364", "0.6534709", "0.65330774", "0.6527823", "0.65188336", "0.6515853", "0.65129936", "0.6510462", "0.6510462", "0.65068644", "0.65059465", "0.6504744", "0.65031445", "0.6492731", "0.6488917", "0.6488762", "0.6484118", "0.6484118", "0.6484118", "0.6479301", "0.64683425", "0.6465689", "0.64616805", "0.6461197", "0.64600563", "0.6455802", "0.6453902", "0.64508784", "0.64502776", "0.6448585", "0.6447696", "0.6447438", "0.64366096" ]
0.68865854
27
Constructor just the message and board.
public ServerMessage(String message, Board board) { this.message = message; this.board = board; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Message(){}", "public Message() {\n\t\tsuper();\n\t}", "public Board()\r\n\t{\r\n\t\tsuper(8, 8);\r\n\t}", "public Message() {\n }", "public Message() {\n }", "public Message() {\n }", "public Message() {}", "public Message() {}", "public JumbleBoard()\n {\n }", "public ImMessage() {\r\n }", "public Message(){\n this(\"Not Specified\",\"Not Specified\");\n }", "public FlowMonMessage(){}", "private Board() {\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// A private board constructor to ensure only one is created\n\t\tsuper();\n\t}", "public Board() {\n this.board = new byte[][] { new byte[3], new byte[3], new byte[3] };\n }", "public Message() {\n message = \"\";\n senderID = \"\";\n time = 0;\n }", "public Board() {\n initialize(3, null);\n }", "public Board(char[][] board) {\n this.boardWidth = board.length;\n this.boardHeight = board[0].length;\n this.board = board;\n this.numShips = 0;\n boardInit();\n }", "private Message(){\n // default constructor\n }", "public LCAmsg2 () { }", "private SocketMessage() {\n initFields();\n }", "public MassMsgFrame() {\n\t}", "public Board() {\n\t\tboard = new char[9][9];\n\t}", "public Message(){\n\t\ttimeStamp = System.currentTimeMillis();\n\t}", "public PersonalBoard(){\n this(0);\n }", "public Message() {\n\tkey = MessageKey.NULL;\n\tdata = null;\n\n\tattachment = null;\n }", "public Board() {\n this.x = 0;\n this.o = 0;\n }", "public Board()\r\n\t{\r\n\t\treset();\r\n\t}", "public SystemMessage() {\r\n\t}", "public Board(Character[][] matrix) {\n this.matrix = matrix;\n }", "public Board() {\n\t\tmarkCount = 0;\n\t\ttheBoard = new char[3][];\n\t\tfor (int i = 0; i < 3; i++) {\n\t\t\ttheBoard[i] = new char[3];\n\t\t\tfor (int j = 0; j < 3; j++)\n\t\t\t\ttheBoard[i][j] = SPACE_CHAR;\n\t\t}\n\t}", "public Board() {\n\t\tintializeBoard(_RowCountDefault, _ColumnCountDefault, _CountToWinDefault);\n\t}", "private Message(MessageType handle) {\n this(handle, null, null);\n }", "public TriggerMessage() {\n\t}", "public MailMessage() {\n }", "public Message(Socket s, Packet p) {\n // userName = \"\";\n socket = s;\n packet = p;\n }", "public messages() {\n }", "public Board()\r\n {\r\n board = new Piece[8][8];\r\n xLength = yLength = 8;\r\n }", "private GameBoard() {}", "public MessageInfo() { }", "public Chat(){ }", "public Message () {\n\t\tthis.setCreationtime(Calendar.getInstance().getTimeInMillis());\n\t\tsetTimestamp();\n\t}", "public Board() {\n this.actionField = new ActionField();\n this.buyField = new BuyField();\n }", "public MessageClackData() {\n super();\n this.message = DEFAULT_MESSAGE;\n }", "Board() {\n this(INITIAL_PIECES, BLACK);\n _countBlack = 12;\n _countWhite = 12;\n _moveHistory = new ArrayList<Move>();\n _movesMade = 0;\n }", "private Message(MessageType handle, String srcName, String text) {\n msgType = handle;\n // Save the properly formatted identifier for the user sending the\n // message.\n msgSender = srcName;\n // Save the text of the message.\n msgText = text;\n }", "private Message(Parcel in) {\n text = in.readString();\n sender = in.readString();\n target = in.readString();\n sendersLatitude = in.readDouble();\n sendersLongitude = in.readDouble();\n numHops = in.readInt();\n expirationTime = in.readLong();\n createdByUser = in.readInt();\n }", "public Card()\n {\n // initialise instance variables\n message = new ArrayList<String>();\n message.add(\"Sorry!\");\n message.add(\"One\");\n message.add(\"Two\");\n message.add(\"Three\");\n message.add(\"Four\");\n }", "public BitBoardImpl() {\n\tinitialPosition();\n }", "public ComputerPlayer(Board board) \n {\n this.board = board;\n }", "public CloudQueueMessage(byte[] content) {\n\t\tthis(null, content, null, null, 0);\n\t}", "private DAPMessage constructFrom(DatabaseTableRecord record) {\n return DAPMessage.fromXML(record.getStringValue(CommunicationNetworkServiceDatabaseConstants.DAP_MESSAGE_DATA_COLUMN_NAME));\n }", "public AIPlayer(Board board) {\n cells = board.squares;\n }", "public MessageRecord() {\n super(Message.MESSAGE);\n }", "public TetrisBoard() {\n super();\n\n myBoard = new Board();\n myHeight = myBoard.getHeight() * BLOCK_SIZE;\n myWidth = myBoard.getWidth() * BLOCK_SIZE;\n myGameMode = CLASSIC_MODE;\n myBoardString = myBoard.toString();\n myGameOver = false;\n myWelcome = true;\n myTimer = new Timer(INITIAL_TIMER_DELAY, new TimerListener());\n\n setupBoard();\n }", "public Chat() {\n }", "public Board() {\n this.board = new Piece[16];\n }", "public CallMessage() {\n\t}", "public Conversation() {}", "public HazelcastMQMessage() {\n this(new DefaultHeaders(), null);\n }", "public MessageEntity() {\n }", "protected AbstractMessage(byte[] content, UserModel receiver) {\n this.content = content;\n this.sender = receiver;\n this.timestamp = System.currentTimeMillis();\n }", "public Board()\r\n\t{\r\n\t\tfor(int x = 0; x < 9; x++)\r\n\t\t\tfor(int y = 0 ; y < 9; y++)\r\n\t\t\t{\r\n\t\t\t\tboard[x][y] = new Cell();\r\n\t\t\t\tboard[x][y].setBoxID( 3*(x/3) + (y)/3+1);\r\n\t\t\t}\r\n\t}", "public Cell()\n\t{\n\t}", "public Message(String type, String content, String status, Long date, String sender) {\n if (type == null || type.isEmpty()) {\n throw new IllegalArgumentException(\"Type cannot be null or empty\");\n }\n if (!type.equals(\"text\") && !type.equals(\"image\") && !type.equals(\"location\")) {\n throw new IllegalArgumentException(\"Message object needs type of text, image or location\");\n }\n if (content == null || content.isEmpty()) {\n throw new IllegalArgumentException(\"Content cannot be null or empty\");\n }\n if (status == null || status.isEmpty()) {\n throw new IllegalArgumentException(\"Status cannot be null or empty\");\n }\n if (!status.equals(\"read\") && !status.equals(\"unread\")){\n throw new IllegalArgumentException(\"Message object needs a status of read or unread\");\n }\n if (date == null) {\n throw new IllegalArgumentException(\"Date cannot be null\");\n }\n if (sender == null || sender.isEmpty()) {\n throw new IllegalArgumentException(\"Sender cannot be null or empty\");\n }\n\n this.type = type;\n this.content = content;\n this.status = status;\n this.date = date;\n this.sender = sender;\n }", "public Board()\n\t{\n\t\tcols = DEFAULT_WIDTH;\n\t\trows = DEFAULT_HEIGHT;\n\t\t\n\t\tpieces = new int[rows][cols];\n\t\tif (pieces.length > 0)\n\t\t{\n\t\t\tfor (int i = 0; i < pieces.length; i++)\n\t\t\t\tfor (int j = 0; j < pieces[0].length; j++)\n\t\t\t\t\tpieces[i][j] = -1;\n\t\t}\n\t}", "public Message(){\n this.body = null;\n this.contact = null;\n }", "public MessageRequest() {\n\t}", "public FeedbackMessages()\n\t{\n\t}", "public MultiChannelMessageImpl() {\n }", "public AmqpMessage() {}", "public Board() {\n playerNumber = 2;\n deadBlackCount = 0;\n deadWhiteCount = 0;\n deadRedCount = 0;\n deadBlueCount = 0;\n\n fields = new Field[DIMENSION][DIMENSION];\n // init fields\n for (int i = 0; i < DIMENSION; i++) {\n for (int j = 0; j < DIMENSION; j++) {\n fields[i][j] = new Field();\n fields[i][j].setX(i);\n fields[i][j].setY(j);\n }\n }\n }", "public GameBoard() {\n this.gameStarted = false;\n this.turn = 1; \n this.boardState = new char[3][3];\n this.winner = 0; \n this.isDraw = false; \n\n }", "public OAuthMessage() {\n\t\t_parameters = new ParameterList();\n\n\t\tif (DEBUG)\n\t\t\t_log.debug(\"Created empty OAuthMessage.\");\n\t}", "public Board(int lines, int columns, List<String> board) {\r\n\t\tif (lines == 0 || lines % 2 != 0 || lines < 2 || lines > 98) {\r\n\t\t\tthrow new IllegalArgumentException(\"Error! Line length is invalid.\");\r\n\t\t} else if (columns == 0 || columns % 2 != 0 || columns < 2 || columns > 26) {\r\n\t\t\tthrow new IllegalArgumentException(\r\n\t\t\t\t\t\"Error! Column length is invalid.\");\r\n\t\t} else if (board != null) {\r\n\r\n\t\t\tfor (String s : board) {\r\n\t\t\t\tif (!s.matches(\"[W,B,#,,-]+\")) {\r\n\t\t\t\t\tthrow new IllegalArgumentException(\r\n\t\t\t\t\t\t\t\"Error! Invalid board parameters.\");\r\n\t\t\t\t} else if (s.length() != columns) {\r\n\t\t\t\t\tthrow new IllegalArgumentException(\r\n\t\t\t\t\t\t\t\"Error! Board columns not equal to columns.\");\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tif (board.size() != lines) {\r\n\t\t\t\tthrow new IllegalArgumentException(\r\n\t\t\t\t\t\t\"Error! Board lines not equal to lines.\");\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tthis.playBoard = new char[lines][columns];\r\n\t\tthis.possibleMoves = new ArrayList<PossibleMove>();\r\n\r\n\t\tif (board == null) {\r\n\t\t\tthis.init();\r\n\t\t} else {\r\n\t\t\tfor (int i = 0; i < playBoard.length; i++) {\r\n\t\t\t\tfor (int j = 0; j < playBoard[0].length; j++) {\r\n\t\t\t\t\tplayBoard[i][j] = board.get(i).charAt(j);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public Board(int boardHeight, int boardWidth) {\n this.boardWidth = boardHeight+1;\n this.boardHeight = boardWidth+1;\n this.board = new char[this.boardHeight][this.boardWidth];\n this.numShips = 0;\n boardInit();\n }", "public PromoMessages() {\n }", "public ServerThread(Socket client, String name, GomokuBoard board) {\r\n\t\tthis.client = client;\r\n\t\tthis.name = name;\r\n\t\tthis.board = board;\r\n\t\tthis.messages = new LinkedList<>();\r\n\t}", "public Board() {\n for (int y = 0; y < spaces.length; y++) {\n for (int x = 0; x < spaces[0].length; x++) {\n spaces[y][x] = new SubBoard();\n wonBoards[y][x] = ' ';\n }\n }\n }", "private Message(MessageType handle, String srcName) {\n this(handle, srcName, null);\n }", "private Message(Builder builder) {\n super(builder);\n }", "public MessageProcessor(JoeBot bot, MessageContentsSpec msgContents)\n {\n joeBot = bot;\n messageContents = msgContents;\n }", "public void testCtor2() {\n instance = new LogMessage(type, id, operator, message);\n\n assertEquals(\"'type' should be correct.\", type, instance.getType());\n assertEquals(\"'id' should be correct.\", id, instance.getId());\n assertEquals(\"'message' should be correct.\", message, instance.getMessage());\n assertNull(\"'error' should be correct.\", instance.getError());\n }", "private static void messageConstructor(){\n msg = \"These are the ammo you can spend.\\n\" +\n \"Every time you select the corresponding color, the quantity will decrease: \\n\";\n\n paymentSB.append(msg);\n if (tmpAmmoInAmmoBox[GeneralInfo.RED_ROOM_ID] > 0) {\n msg = red + \": Red ammo available: \" + tmpAmmoInAmmoBox[GeneralInfo.RED_ROOM_ID] + \"\\n\";\n paymentSB.append(msg);\n responeForAmmo.add(red);\n }\n if (tmpAmmoInAmmoBox[GeneralInfo.BLUE_ROOM_ID] > 0) {\n msg = blue + \": Blue ammo available: \" + tmpAmmoInAmmoBox[GeneralInfo.BLUE_ROOM_ID] + \"\\n\";\n paymentSB.append(msg);\n responeForAmmo.add(blue);\n }\n if (tmpAmmoInAmmoBox[GeneralInfo.YELLOW_ROOM_ID] > 0) {\n msg = yellow + \": Yellow ammo available: \" + tmpAmmoInAmmoBox[GeneralInfo.YELLOW_ROOM_ID] + \"\\n\";\n paymentSB.append(msg);\n responeForAmmo.add(yellow);\n }\n\n for (i = 0; i < tmpAmmoInPowerUp.size(); i++) {\n msg = (i + 1) + \": \" + tmpAmmoInPowerUp.get(i).getName() + \" COLOR: \" + tmpAmmoInPowerUp.get(i).getGainAmmoColor() + \"\\n\";\n paymentSB.append(msg);\n responseForPowerUp.add(Integer.toString(i + 1));\n }\n\n if (!responeForAmmo.isEmpty()) {\n possibleChoice.addAll(responeForAmmo);\n msg = \"Chose a letter R/B/Y \\n\";\n paymentSB.append(msg);\n }\n\n if(!responseForPowerUp.isEmpty()) {\n possibleChoice.addAll(responseForPowerUp);\n msg = \"choose a number from 1 to \" + i + \": \";\n paymentSB.append(msg);\n }\n }", "private Messages() {\n\t}", "public Board() {\n\n for(int row = 0; row < size; row++) {\n for(int col = 0; col < size; col++) {\n\n grid[row][col] = \"-\";\n\n }\n }\n\n }", "private BeeMessage(Builder builder) {\n super(builder);\n }", "public SudokuBoard()\n\t{\n\t\tcurrentTime = 0;\n\t\tseconds = 0;\n\t\tminutes = 0;\n\t\tnumberOfHints = 0;\n\t\ttimeDisplay = null;\n\t\tuser = null;\n\t\tdifficulty = \"\";\n\t}", "public Message newMessage(String message, Object... params) {\n/* 61 */ return new SimpleMessage(message);\n/* */ }", "public CryptoSchemeMsg () { }", "public EuclideanTrajectoryPointMessage()\n {\n }", "public Board() {\n\t\tboardState = new Field[DIMENSION][DIMENSION];\n\t\tfor(int i = 0; i < DIMENSION; i++) {\n\t\t\tfor(int j = 0; j < DIMENSION; j++) {\n\t\t\t\tboardState[i][j] = new Field();\n\t\t\t}\n\t\t}\n\t}", "public MessagesBox(int rows, int cols) {\n\t\tsuper(rows,cols);\n\t}", "public Board(Piece[] board) {\n this.board = copyOf(board);\n }", "public messageList()\n {\n\n }", "public Alarm_Msg(){ }", "public Packet() {\n\t}", "public Message(Message m)\r\n\t{\r\n\t\t_msgBody = m._msgBody;\r\n\t\t_mID = m._mID;\r\n\t\t_fatherMessageID = m._fatherMessageID;\r\n\t\t_msgPosterID = m._msgPosterID;\r\n\t\t_msgPostTime = m._msgPostTime;\r\n\t}", "public Board()\r\n\t{\r\n\t\tthis.grid = new CellState[GRID_SIZE][GRID_SIZE];\r\n\t\tthis.whiteMarblesCount = MARBLES_COUNT;\r\n\t\tthis.blackMarblesCount = MARBLES_COUNT;\r\n\t\t\r\n\t\t/**\r\n\t\t * Initializes the board with empty value\r\n\t\t */\r\n\t\tfor (int indexcol = 0; indexcol < GRID_SIZE; indexcol++)\r\n\t\t{\r\n\t\t\tfor (int indexrow = 0; indexrow < GRID_SIZE; indexrow++)\r\n\t\t\t{\r\n\t\t\t\tthis.grid[indexrow][indexcol] = CellState.EMPTY;\t\t\t\t\r\n\t\t\t}\t\r\n\t\t}\r\n\t\t\r\n\t\t/**\r\n\t\t * Sets marbles on the board with default style\r\n\t\t */\r\n\t\tfor (int indexcol = 0; indexcol < 5; indexcol++)\r\n\t\t{\r\n\t\t\tthis.grid[0][indexcol] = CellState.WHITE_MARBLE;\r\n\t\t\tthis.grid[8][8 - indexcol] = CellState.BLACK_MARBLE;\r\n\t\t}\r\n\t\tfor (int indexcol = 0; indexcol < 6; indexcol++)\r\n\t\t{\r\n\t\t\tthis.grid[1][indexcol] = CellState.WHITE_MARBLE;\r\n\t\t\tthis.grid[7][8 - indexcol] = CellState.BLACK_MARBLE;\r\n\t\t}\r\n\t\tfor (int indexcol = 2; indexcol < 5; indexcol++)\r\n\t\t{\r\n\t\t\tthis.grid[2][indexcol] = CellState.WHITE_MARBLE;\r\n\t\t\tthis.grid[6][8 - indexcol] = CellState.BLACK_MARBLE;\r\n\t\t}\r\n\t\tthis.grid[3][8] = CellState.INVALID;\r\n\t\tthis.grid[2][7] = CellState.INVALID;\r\n\t\tthis.grid[1][6] = CellState.INVALID;\r\n\t\tthis.grid[0][5] = CellState.INVALID;\r\n\t\tthis.grid[5][0] = CellState.INVALID;\r\n\t\tthis.grid[6][1] = CellState.INVALID;\r\n\t\tthis.grid[7][2] = CellState.INVALID;\r\n\t\tthis.grid[8][3] = CellState.INVALID;\r\n\t}", "public EmoticonBO()\n {}", "public Message(User author, String message) {\n this.author = author;\n this.message = message;\n this.date = new Date();\n }" ]
[ "0.72481453", "0.71406674", "0.7118803", "0.7116348", "0.7104827", "0.7104827", "0.70789456", "0.70789456", "0.70307314", "0.69658047", "0.692624", "0.69203454", "0.68716747", "0.6832576", "0.6788412", "0.674996", "0.67453796", "0.6739742", "0.6739006", "0.67155284", "0.6697533", "0.6641133", "0.66168463", "0.65635693", "0.6547597", "0.653658", "0.6536124", "0.6521564", "0.6520083", "0.64683044", "0.64453095", "0.64447254", "0.64413446", "0.644034", "0.643678", "0.64316225", "0.64236337", "0.64176875", "0.6414492", "0.63972956", "0.63751686", "0.63588375", "0.6355155", "0.6353445", "0.6330986", "0.63193345", "0.6307451", "0.62917656", "0.6262187", "0.62473154", "0.62317634", "0.6220514", "0.6204573", "0.6204177", "0.6204051", "0.61986077", "0.61953056", "0.61940175", "0.61878383", "0.6176391", "0.616966", "0.6165587", "0.61514556", "0.6150926", "0.6142837", "0.61399174", "0.61390525", "0.61368126", "0.61355686", "0.6134244", "0.61322683", "0.61291987", "0.61275744", "0.61274266", "0.61185634", "0.6117667", "0.61017895", "0.6098776", "0.60948616", "0.6074152", "0.6054392", "0.60493916", "0.6041432", "0.60410357", "0.6040652", "0.6034055", "0.6023337", "0.60199785", "0.6019258", "0.6017589", "0.60117143", "0.6005235", "0.6001684", "0.5990089", "0.59871393", "0.5985767", "0.59825176", "0.5977034", "0.5970222", "0.59614927" ]
0.7325126
0
Constructor just the message and status.
public ServerMessage(String message, String status) { this.message = message; this.status = status; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private StatusMessage() {\n\n\t}", "private StatusMessage() {\n\n\t}", "public Message(){\n super();\n this.status = RETURN_OK;\n put(\"status\",this.status.getCode());\n put(\"message\", this.status.getMessage());\n }", "public StatusMessage(int code, String message) {\n _code = code;\n _message = message;\n }", "public Message(){}", "public Status() {\n }", "public Status() {\n\n }", "public Message() {}", "public Message() {}", "public Message(){\n this(\"Not Specified\",\"Not Specified\");\n }", "protected ClientStatus() {\n }", "public Message() {\n\t\tsuper();\n\t}", "public Message() {\n }", "public Message() {\n }", "public Message() {\n }", "public SystemMessage() {\r\n\t}", "public Result(Status status, String message) {\n this.status = status;\n this.message = message;\n this.value = Optional.empty();\n }", "public MessageInfo() { }", "public ResponseBase(Status status) {\n this.status = status;\n }", "public MessageResponse() {\r\n\t}", "public FlowMonMessage(){}", "public JsonResponse(String status, String[] message) {\n this.status = status;\n this.message = message;\n }", "public Message(){\n\t\ttimeStamp = System.currentTimeMillis();\n\t}", "private Message(){\n // default constructor\n }", "public Message(String type, String content, String status, Long date, String sender) {\n if (type == null || type.isEmpty()) {\n throw new IllegalArgumentException(\"Type cannot be null or empty\");\n }\n if (!type.equals(\"text\") && !type.equals(\"image\") && !type.equals(\"location\")) {\n throw new IllegalArgumentException(\"Message object needs type of text, image or location\");\n }\n if (content == null || content.isEmpty()) {\n throw new IllegalArgumentException(\"Content cannot be null or empty\");\n }\n if (status == null || status.isEmpty()) {\n throw new IllegalArgumentException(\"Status cannot be null or empty\");\n }\n if (!status.equals(\"read\") && !status.equals(\"unread\")){\n throw new IllegalArgumentException(\"Message object needs a status of read or unread\");\n }\n if (date == null) {\n throw new IllegalArgumentException(\"Date cannot be null\");\n }\n if (sender == null || sender.isEmpty()) {\n throw new IllegalArgumentException(\"Sender cannot be null or empty\");\n }\n\n this.type = type;\n this.content = content;\n this.status = status;\n this.date = date;\n this.sender = sender;\n }", "public CreateStatus()\n {\n super(new DataMap(), null);\n }", "public TransactionResponse(String statusMessage) {\n this.statusMessage = statusMessage;\n }", "public MessageRequest() {\n\t}", "public LCAmsg2 () { }", "public ServiceMessage() {\r\n\t}", "public Status(){\n this(StatusDescription.REGISTERED);\n }", "public Message () {\n\t\tthis.setCreationtime(Calendar.getInstance().getTimeInMillis());\n\t\tsetTimestamp();\n\t}", "public PromoMessages() {\n }", "public Message() {\n message = \"\";\n senderID = \"\";\n time = 0;\n }", "protected Status() {\r\n\t\t;\r\n\t}", "public StatusComponent()\n {\n }", "public BasicResponse() {\n }", "public JsonResponse(int status) {\n super();\n this.status = status;\n }", "public CallMessage() {\n\t}", "public HttpException(int status, String message, String body) {\r\n\t\tsuper(\"Status: \" + status + \", Response: \" + body);\r\n\t\tmStatus = status;\r\n\t\tmMessage = message;\r\n\t\tmBody = body;\r\n\t}", "public ReadEJStatus2() {\r\n }", "public MessageParseException() {\n }", "public messages() {\n }", "public UpdateTrackingResp() {\n }", "public KVAdminMessageImpl(KVAdminMessage.StatusType status) {\n // This constructor is about simple acknowledge returns to messages like\n // START, STOP, WRITE_LOCK, WRITE_UNLOCK, SHUTDOWN\n // It returns usually a SUCCESS or OPERATION_FAILED\n this.status = status;\n }", "public MessageRecord() {\n super(Message.MESSAGE);\n }", "public ImMessage() {\r\n }", "Wrapper() {\n this(ResponseType.SUCCESS,\"\");\n }", "public Alarm_Msg(){ }", "public FeedbackMessages()\n\t{\n\t}", "public Status(HttpStatus httpStatus, String message, String description) {\n this.statusCode = httpStatus.value();\n this.code = httpStatus.getReasonPhrase();\n this.severity = defaultSeverity;\n this.message = message;\n this.description = description;\n }", "public StatusBar() {\n\t\tthis(DEFAULT_STATUS_MESSAGE, true, 1, 1, true);\n\t}", "public Message(String unparsedData){\n\t\theaderLines = new ArrayList<ArrayList<String>>();\n\t\tString[] headFromEntity = unparsedData.split(\"\\n\\n\", 2);\n\t\tString[] msgInfo = headFromEntity[0].split(\"\\n\");\n\t\tString[] status = msgInfo[0].split(\" \");\n\t\t\n\t\tthis.messageInfo[0]= status[0];\t\t\t\t\t// Version\n\t\tthis.messageInfo[1] = status[1];\t\t\t\t// status code\n\t\tthis.messageInfo[2] = msgInfo[0].substring(2);\t// phrase\n\t\t\n\t\tfor (int i = 1; i < msgInfo.length; i++){\n\t\t\tstatus = msgInfo[i].split(\" \");\n\t\t\theaderLines.add(new ArrayList<String>());\n\t\t\theaderLines.get(headerLines.size()-1).add(status[0]);\n\t\t\theaderLines.get(headerLines.size()-1).add(msgInfo[i].substring(status[0].length()));\n\t\t}\n\t\t\n\t\tentity = headFromEntity[1].getBytes();\n\t}", "public OAuthMessage() {\n\t\t_parameters = new ParameterList();\n\n\t\tif (DEBUG)\n\t\t\t_log.debug(\"Created empty OAuthMessage.\");\n\t}", "public AmqpMessage() {}", "public OperationException(ZonedDateTime timestamp, int status, String error, String message,String path) {\r\n\t\tthis.timestamp = timestamp;\r\n\t\tthis.status = status;\r\n\t\tthis.error = error;\r\n\t\tthis.message = message;\r\n\t\tthis.path = path;\r\n\t}", "public InvalidRequestMsg() {\n\n this(\"\");\n\n }", "public Notification()\n\t{\n\t\t\n\t}", "public MessageTran() {\n\t}", "public ValidationMessage() {\n }", "Status(String description) {\n this.description = description;\n }", "private SocketMessage() {\n initFields();\n }", "private MessageStatus(int value, String name, String literal) {\n\t\tthis.value = value;\n\t\tthis.name = name;\n\t\tthis.literal = literal;\n\t}", "public CashFlowImportStatus() {\n\t\t// empty constructor\n\t}", "public RequestMessage() {\r\n\t\tsuper();\r\n\t\tthis.criteria = new PersonSearchCriteria();\r\n\t\tthis.setSourceSystemID(SOURCE_SYSTEM_ID);\r\n\t\tthis.setSourceUserID(SOURCE_USER_ID);\r\n\t}", "public Notification() {\r\n }", "public Notification() {\r\n }", "public Message() {\n\tkey = MessageKey.NULL;\n\tdata = null;\n\n\tattachment = null;\n }", "public MassMsgFrame() {\n\t}", "public Notification() {\n\n\t}", "public RavelloException(int status, Object errorMessage) {\n this.status = status;\n this.errorMessage = errorMessage;\n }", "public StatusResource() {\n this.statusService = DeathStar.getStatusService();\n logger.log(Level.FINE, \"Status resource instantiated: {0}\", this);\n }", "private Message(Parcel in) {\n text = in.readString();\n sender = in.readString();\n target = in.readString();\n sendersLatitude = in.readDouble();\n sendersLongitude = in.readDouble();\n numHops = in.readInt();\n expirationTime = in.readLong();\n createdByUser = in.readInt();\n }", "public ScriptingException(IStatus status){\n\t\tsuper(status.getMessage());\n\t\tthis.status = status;\n\t}", "public ServiceJobDBUtil(Context context, String message) {\n super(context);\n Log.e(LOG_TAG, message);\n }", "public MessageClackData() {\n super();\n this.message = DEFAULT_MESSAGE;\n }", "public IntegratedAvirUpdateStatus() {\n \n }", "public JsonResponse(String status) {\n this.status = status;\n }", "public SystemCommandRequest()\r\n\t{\r\n\t}", "public EmanagerDatabaseStatusCode()\n {\n }", "public Message(String message){\n\t\tthis(message, 5000);\n\t}", "public void testCtor2() {\n instance = new LogMessage(type, id, operator, message);\n\n assertEquals(\"'type' should be correct.\", type, instance.getType());\n assertEquals(\"'id' should be correct.\", id, instance.getId());\n assertEquals(\"'message' should be correct.\", message, instance.getMessage());\n assertNull(\"'error' should be correct.\", instance.getError());\n }", "public ProgressStatusList() {\n }", "public JsonResponse(String status, String[] message, String userid, String password, String name, String school, BigDecimal edollar) {\n this.status = status;\n this.message = message;\n this.userid = userid;\n this.password = password;\n this.name = name;\n this.school = school;\n this.edollar = edollar;\n }", "private Message(MessageType handle) {\n this(handle, null, null);\n }", "public TriggerMessage() {\n\t}", "private HeartBeatMessage() {\n initFields();\n }", "public MessageEntity() {\n }", "public messageList()\n {\n\n }", "public ErrorMessage() {\n\t}", "public Catelog(Integer id, String name, Integer number, Byte status) {\n this.id = id;\n this.name = name;\n this.number = number;\n this.status = status;\n }", "public Result() {\n success = false;\n messages = new ArrayList<>();\n errMessages = new ArrayList<>();\n }", "public Notification()\n\t{\n\t\t// Start of user code constructor for Notification)\n\t\tsuper();\n\t\t// End of user code\n\t}", "private Messages() {\n\t}", "public Ludo() {\n this.status = \"Created\";\n }", "public Flight() {//Initial flight\n status = \"正常\";\n }", "protected Status(final String name) {\r\n\t\tthis.name = name;\r\n\t}", "public void testCtor1() {\n instance = new LogMessage(type, id, operator, message, error);\n\n assertEquals(\"'type' should be correct.\", type, instance.getType());\n assertEquals(\"'id' should be correct.\", id, instance.getId());\n assertEquals(\"'message' should be correct.\", message, instance.getMessage());\n assertSame(\"'error' should be correct.\", error, instance.getError());\n }", "private Message(MessageType handle, String srcName, String text) {\n msgType = handle;\n // Save the properly formatted identifier for the user sending the\n // message.\n msgSender = srcName;\n // Save the text of the message.\n msgText = text;\n }", "public CodeMessage(HttpStatus code, T message) {\n this.code = code.value();\n this.message = message;\n }" ]
[ "0.8145835", "0.8145835", "0.78155994", "0.7379072", "0.7308107", "0.7258557", "0.71240956", "0.7093038", "0.7093038", "0.704259", "0.70268995", "0.7021113", "0.7013137", "0.69878423", "0.69878423", "0.6954725", "0.6945382", "0.69394165", "0.692513", "0.690581", "0.68673", "0.6855207", "0.68491375", "0.67984647", "0.6796247", "0.67696005", "0.66947895", "0.66917384", "0.6682473", "0.6675067", "0.6628312", "0.6577818", "0.656901", "0.6568663", "0.6564387", "0.6552018", "0.6546963", "0.6534797", "0.649388", "0.6489227", "0.6482476", "0.6440344", "0.63937145", "0.63925225", "0.6387141", "0.63837224", "0.63562214", "0.6353915", "0.63415414", "0.63379145", "0.63338006", "0.6331432", "0.6329003", "0.63254505", "0.6317984", "0.6282208", "0.6270302", "0.6259642", "0.62445027", "0.6229426", "0.6226472", "0.621879", "0.6207741", "0.6207563", "0.6202552", "0.6187829", "0.6187829", "0.61876106", "0.6177511", "0.6175149", "0.61745864", "0.6158209", "0.61507684", "0.61478287", "0.61435485", "0.6141278", "0.6138056", "0.61376965", "0.6136911", "0.6134424", "0.613435", "0.6133965", "0.61333835", "0.6132688", "0.6117653", "0.61125916", "0.61096513", "0.6108693", "0.61064583", "0.61008483", "0.6092932", "0.609273", "0.6091206", "0.6088739", "0.6088686", "0.6087671", "0.60817754", "0.60757065", "0.6074428", "0.6061855" ]
0.7381628
3
Constructor just the message and player.
public ServerMessage(String message, Player player) { this.message = message; this.player = player; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Message(){}", "public Message() {\n\t\tsuper();\n\t}", "public Message() {\n message = \"\";\n senderID = \"\";\n time = 0;\n }", "public Message() {\n }", "public Message() {\n }", "public ImMessage() {\r\n }", "public Message() {\n }", "public Message() {}", "public Message() {}", "public WaitMessage() {\n super(\"Wait for other player...\\n\");\n }", "public IncomingPluginMessageContext(Player player, byte[] message) {\n this.player = player;\n this.message = message;\n }", "public Message(){\n\t\ttimeStamp = System.currentTimeMillis();\n\t}", "public Message(Socket s, Packet p) {\n // userName = \"\";\n socket = s;\n packet = p;\n }", "private Message(MessageType handle, String srcName, String text) {\n msgType = handle;\n // Save the properly formatted identifier for the user sending the\n // message.\n msgSender = srcName;\n // Save the text of the message.\n msgText = text;\n }", "public Player() {\t\n\t}", "public Multi_Player()\r\n {\r\n \r\n }", "public Message() {\n\tkey = MessageKey.NULL;\n\tdata = null;\n\n\tattachment = null;\n }", "private Message(){\n // default constructor\n }", "public FlowMonMessage(){}", "public Player(){}", "public Player(){}", "public Player() {\n this(\"\", \"\", \"\");\n }", "public Player(String username)\n\t{\n\t\tm_username = username;\n\t\tm_requests = new HashMap<String, RequestType>();\n\t}", "public Player(){\r\n\r\n }", "public Player() {}", "public Player() {}", "public Player() {}", "public Player() {}", "public Conversation() {}", "public Chat(){ }", "public Message(){\n this(\"Not Specified\",\"Not Specified\");\n }", "private Message(Parcel in) {\n text = in.readString();\n sender = in.readString();\n target = in.readString();\n sendersLatitude = in.readDouble();\n sendersLongitude = in.readDouble();\n numHops = in.readInt();\n expirationTime = in.readLong();\n createdByUser = in.readInt();\n }", "public Player(){\n\n }", "private SocketMessage() {\n initFields();\n }", "private Message(MessageType handle, String srcName) {\n this(handle, srcName, null);\n }", "public MessageInfo() { }", "public CardMessage(Player toPlayer, Player fromPlayer, List<Card> cards)\n {\n this.toPlayer = toPlayer;\n this.fromPlayer = fromPlayer;\n this.cards = cards;\n }", "public Chat() {\n }", "public CallMessage() {\n\t}", "public messages() {\n }", "private Conversation()\n {\n }", "public Message () {\n\t\tthis.setCreationtime(Calendar.getInstance().getTimeInMillis());\n\t\tsetTimestamp();\n\t}", "public MassMsgFrame() {\n\t}", "ClientMessageSender() {\n\n\t}", "public GamePlayer() {}", "public MessageEntity() {\n }", "public ClientPlayer(String username, Level level) {\r\n\t\tsuper(username, level);\r\n\t}", "public Card()\n {\n // initialise instance variables\n message = new ArrayList<String>();\n message.add(\"Sorry!\");\n message.add(\"One\");\n message.add(\"Two\");\n message.add(\"Three\");\n message.add(\"Four\");\n }", "public MessageHandler() {\n }", "private Message(MessageType handle) {\n this(handle, null, null);\n }", "public PromoMessages() {\n }", "public LCAmsg2 () { }", "public SystemMessage() {\r\n\t}", "public VideoMessage() {\n super(CommsService.class.getName(), VideoMessage.class.getName());\n }", "public Player(){\n default_init();\n }", "public TriggerMessage() {\n\t}", "public NetworkMessage(){\n\t\tthis.user = null;\n\t}", "public AmqpMessage() {}", "public TrackedMessage(int messageType) {\n\tsuper(messageType);\n }", "public MultiChannelMessageImpl() {\n }", "public Command(int Player) {\r\n\t\tmyPlayer = Player;\r\n\t}", "public MessageRequest() {\n\t}", "MessageService(Player[] players) {\n\t\tthis.players = players;\n\t\tlog = new ArrayList<String[]>();\n\t}", "public AbstractPlayer() {\r\n }", "public Message(Account accountSend) {\r\n\t\tm_accountSend = accountSend;\r\n\t\tformatTime();\r\n\t}", "public ServerMessage(String message, Board board) {\n this.message = message;\n this.board = board;\n }", "public FeedbackMessages()\n\t{\n\t}", "public ProtocolWorker(String message){\n this.message = message;\n }", "public MessageManager() {\n }", "public Game(){\n player = new Player(createRooms());\n parser = new Parser(); \n }", "public Player(String s) //only constructor\n {\n \tsuper(s,1,false);\n \tposition=-1;\n \tship=false;\n \tSetHealth();\n \tSetWealth();\n }", "public MessageTran() {\n\t}", "public Packet(PacketId packetId, String message)\n {\n this.packetId = packetId;\n this.message = message;\n\n }", "public MessageResponse() {\r\n\t}", "public Message(Player player, int code, int tick, int newLine, int oldLine) {\r\n\t\tthis.tick = tick;\r\n\t\tthis.code = code;\r\n\t\tthis.player = player;\r\n\t\tthis.newLine = newLine;\r\n\t\tthis.oldLine = oldLine;\r\n\t}", "public ClientPlayer(String username, Integer id, Level level) {\r\n\t\tsuper(username, id, level);\r\n\t}", "public ChatClient() {\n\n }", "public Player(Game game){\r\n this.game = game;\r\n }", "public EuclideanTrajectoryPointMessage()\n {\n }", "public MessageRecord() {\n super(Message.MESSAGE);\n }", "public ClientPlayer(Client client, String username, Integer id, InputHandler input, Level level) {\r\n\t\tthis(0, 0, client, username, id, input, level);\r\n\t}", "public Player(Position position) {\n this.position = position;\n this.image = new Image(\"O\");\n }", "public Packet() {\n\t}", "public Message(int senderId, int receiverId, String text, Vect3 position, Vect3 speed, Vect3 targetPos, Vect3 startPos, double batteryLevel,\n\t\t\tPriority priority, ComInteract interaction, double vSpace) {\n\t\tthis.senderId = senderId;\n\t\tthis.receiverId = receiverId;\n\t\tthis.text = text;\n\t\tthis.position = position;\n\t\tthis.speed = speed;\n\t\tthis.targetPos = targetPos;\n\t\tthis.startPos = startPos;\n\t\tthis.batteryLevel = batteryLevel;\n\t\tthis.priority = priority;\n\t\tthis.interaction = interaction;\n\t\tthis.vSpace=vSpace;\n\t}", "public Player()\r\n\t{\r\n\t\tpCards = new String[DECK_SIZE];\r\n\t\thandCount = 0;\r\n\t\tstand = false;\r\n\t}", "Player(String playerName) {\n this.playerName = playerName;\n }", "public TestPlayer()\n {\n }", "public Player(Player p)\r\n {\r\n this(p.isCompletingGame, p.averageTime, p.fastestTime, p.gamesCompleted, p.rank, p.title, p.username);\r\n }", "public Message(Type type, Player messageSender, String messageContent) {\n\t\tif (type == null) {\n\t\t\tthrow new InvalidParameterException(\"Type cannot be null\");\n\t\t}\n\t\tif (messageSender == null) {\n\t\t\tthrow new InvalidParameterException(\"MessageReceiver cannot be null\");\n\t\t}\n\t\tif (messageContent == null) {\n\t\t\tthrow new InvalidParameterException(\"MessageContent cannot be null\");\n\t\t}\n\t\tthis.type = type;\n\t\tthis.messageSender = messageSender;\n\t\tthis.messageReceiver = new Player(\"SERVER\", Player.Team.SERVER);\n\t\tthis.messageContent = messageContent;\n\t}", "public GameClient(ReadableByteChannel r) {\r\n super(null, null, r);\r\n }", "public Player(String inName)\n {\n // initialise instance variables\n mName = inName;\n mBrokenRules = new RuleBook();\n }", "public Game()//Method was given\n {\n parser = new Parser();\n player = new Player();\n }", "public Message(String s, String r){\n sender = s;\n reciever = r;\n }", "private PlayerBagMsg(Builder builder) {\n super(builder);\n }", "public Player(Keyboard input) {\n\t\tthis.input = input;\n\t}", "public Message(){\n this.body = null;\n this.contact = null;\n }", "public ServerMessage(String message) {\n this.message = message;\n }", "public messageList()\n {\n\n }", "public Message(String message){\n\t\tthis(message, 5000);\n\t}", "public Player() {\n hand = new Hand();\n }" ]
[ "0.7331104", "0.7291653", "0.72884566", "0.72615606", "0.72615606", "0.72603226", "0.72531796", "0.72423637", "0.72423637", "0.714165", "0.6966886", "0.6962798", "0.69437474", "0.6939184", "0.6893356", "0.6889108", "0.6877893", "0.68571925", "0.6856302", "0.6797018", "0.6797018", "0.6774444", "0.6761735", "0.6757781", "0.67483056", "0.67483056", "0.67483056", "0.67483056", "0.67479014", "0.6734636", "0.66903585", "0.66858685", "0.6670147", "0.6651674", "0.66106945", "0.6604908", "0.65861493", "0.6565765", "0.6565685", "0.65391886", "0.6535962", "0.6532993", "0.65292394", "0.6505811", "0.6496056", "0.6491107", "0.64885086", "0.6484954", "0.64789534", "0.6477685", "0.64550227", "0.6437789", "0.6413195", "0.63981324", "0.6390066", "0.6388792", "0.6384558", "0.6373625", "0.63708586", "0.6358112", "0.6352811", "0.6344058", "0.63427085", "0.63409126", "0.6336598", "0.63316864", "0.6327084", "0.6297905", "0.62905514", "0.6268916", "0.6267935", "0.6258918", "0.62498873", "0.6248312", "0.6240992", "0.62391305", "0.6237385", "0.62305444", "0.62288606", "0.6228223", "0.6225383", "0.6224961", "0.6224463", "0.6222601", "0.62157136", "0.62089455", "0.6203901", "0.6200022", "0.6199488", "0.61977345", "0.6194283", "0.6182116", "0.61740243", "0.6171366", "0.61686313", "0.6160373", "0.6160353", "0.6159319", "0.615466", "0.6149379" ]
0.7800709
0
Method to get the exact message.
public String getMessage() { return message; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "java.lang.String getTheMessage();", "java.lang.String getMsg();", "Object getMessage();", "public String getMessage(){\n return(message);\n }", "public String getMessage() {\r\n\treturn messageSB.toString();\r\n }", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getMessage();", "java.lang.String getUserMessage();", "public String getMessage() {\r\n return messageKind.getMessage();\r\n }", "public String getMessage() {\n\t\tString toReturn = message;\n\t\tmessage=\"\";//delete the message\n\t\treturn toReturn;\n\t}", "public String getMessage() {\n String message = this.rawMessage;\n Boolean endsWithDot = false;\n Boolean endsWithQuestionMark = false;\n\n // Check if the last character is a dot\n if (message.charAt(message.length()-1) == '.') {\n message = message.substring(0, message.length()-1);\n endsWithDot = true;\n }\n\n // Check if the last character is a question mark\n if (message.charAt(message.length()-1) == '?') {\n message = message.substring(0, message.length()-1);\n endsWithQuestionMark = true;\n }\n\n if (templateName != null) {\n message += \" in \\\"\" + templateName + \"\\\"\";\n }\n\n if (lineNumber != null && lineNumber > -1) {\n message += \" at line \" + lineNumber;\n }\n\n if (endsWithDot) {\n message += \".\";\n }\n if (endsWithQuestionMark) {\n message += \"?\";\n }\n\n return message;\n }", "Message getCurrentMessage();", "public Object getMessage() {\n return m_message;\n }", "public String getMessage()\r\n\t{\r\n\t\treturn message;\r\n\t}", "public String getMessage() {\n\t\treturn this.nbt.getString(MESSAGE_KEY);\n\t}", "public String getMessage(){\n\t\treturn this.message;\n\t}", "public String getMessage() {\n return message == null ? new StringBuilder().append(\"??\").append(key).append(\"??\").toString() : message;\n }", "public String getMessage() {\n \t\treturn message;\n \t}", "public String getMessage()\n\t{\n\t\treturn message;\n\t}", "public String getMessage(){\r\n\t\treturn message;\r\n\t}", "public String getMessage() {\r\n return getPayload().optString(\"message\");\r\n }", "protected String getMessage() {\n if (allMessage == null)\n return allMessage;\n return allMessage.trim();\n }", "public java.lang.String getMessage()\r\n {\r\n return message;\r\n }", "public String getMessage()\n\t{\n\t\treturn this.message;\n\t}", "public String getMessage()\n {\n return fMessage;\n }", "public String getMessage()\n\t\t{\n\t\t\treturn message;\n\t\t}", "public String getMessage() {\r\n\t\treturn this.message;\r\n\t}", "String getRawMessage();", "public String getMessage()\r\n {\r\n return message;\r\n }", "public String getMessage()\r\n {\r\n return message;\r\n }", "String getMessage();", "String getMessage();", "String getMessage();", "public java.lang.String getMESSAGE() {\n return MESSAGE;\n }", "public String getMessage() {\n\t\treturn this.message;\n\t}", "public String getMessage() {\n\t\treturn this.message;\n\t}", "public java.lang.String getMessage() {\n return localMessage;\n }", "public String getMessage() {\n\t\treturn message;\n\t\t\n\t}", "public String getMessage() {\r\n\t\treturn message;\r\n\t}", "public String getMessage() {\r\n\t\treturn message;\r\n\t}", "public String getMessage() {\r\n\t\treturn message;\r\n\t}", "public String getMessage() {\r\n\t\treturn message;\r\n\t}", "public String getMessage() {\r\n return message;\r\n }", "public String getMessage() {\r\n return message;\r\n }", "public String getMessage() {\r\n\t\treturn m_message;\r\n\t}", "public java.lang.String getMessage() {\n java.lang.Object ref = message_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n message_ = s;\n }\n return s;\n }\n }", "public java.lang.String getMessage() {\n java.lang.Object ref = message_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n message_ = s;\n }\n return s;\n }\n }", "public java.lang.String getMessage() {\n java.lang.Object ref = message_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n message_ = s;\n }\n return s;\n }\n }", "public java.lang.String getMessage() {\n java.lang.Object ref = message_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n message_ = s;\n }\n return s;\n }\n }", "public java.lang.String getMessage() {\n java.lang.Object ref = message_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n message_ = s;\n }\n return s;\n }\n }", "public java.lang.String getMessage() {\n java.lang.Object ref = message_;\n if (ref instanceof java.lang.String) {\n return (java.lang.String) ref;\n } else {\n com.google.protobuf.ByteString bs = \n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n message_ = s;\n }\n return s;\n }\n }", "@Accessor(qualifier = \"message\", type = Accessor.Type.GETTER)\n\tpublic String getMessage()\n\t{\n\t\treturn getMessage(null);\n\t}", "public java.lang.String getMessage() {\n java.lang.Object ref = message_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n message_ = s;\n }\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }", "public java.lang.String getMessage() {\n java.lang.Object ref = message_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n message_ = s;\n }\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }", "public java.lang.String getMessage() {\n java.lang.Object ref = message_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n message_ = s;\n }\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }", "public java.lang.String getMessage() {\n java.lang.Object ref = message_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n message_ = s;\n }\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }", "public java.lang.String getMessage() {\n java.lang.Object ref = message_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n message_ = s;\n }\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }", "public java.lang.String getMessage() {\n java.lang.Object ref = message_;\n if (!(ref instanceof java.lang.String)) {\n com.google.protobuf.ByteString bs =\n (com.google.protobuf.ByteString) ref;\n java.lang.String s = bs.toStringUtf8();\n if (bs.isValidUtf8()) {\n message_ = s;\n }\n return s;\n } else {\n return (java.lang.String) ref;\n }\n }", "public String getMessage()\r\n {\r\n return myMessage;\r\n }", "public String getMessage() {\n\t\treturn message;\n\t}", "public String getMessage() {\n\t\treturn message;\n\t}", "public String getMessage() {\n\t\treturn message;\n\t}", "public String getMessage() { return message; }", "@Override\r\n\tpublic String getMessage() {\n\t\treturn this.message;\r\n\t}", "public String getMessage() {\n return getMessage(this.key, (Object[]) null, this.key, (Locale) null);\n }", "public String getMessage () {\n return message;\n }", "public String getMessage(){\r\n return message;\r\n }", "public String getMessage(){\r\n return message;\r\n }", "public String getMessage() {\r\n\t\treturn mMessage;\r\n\t}", "public java.lang.String getMessage() {\n return message;\n }", "public String getMessageText();", "public final String getMessage() {\n return this.message;\n }", "public String getMessage(){\n return this.message;\n }", "public String getMessage()\n\t{\n\t\treturn messageArea.getText();\n\t}", "public V getMessage() {\n return this.message;\n }", "public String getMessage() {\n\t\t\treturn message;\n\t\t}", "public String getMessage()\n\t{\n\t\tif(response.containsKey(\"MESSAGE\")) {\n\t\t\treturn response.get(\"MESSAGE\");\n\t\t} else {\n\t\t\treturn null;\n\t\t}\n\t}", "public String getMessage() {\n return this.message;\n }", "public String getMessage() {\n return this.message;\n }", "public String getMessage() {\n return this.message;\n }", "public String getMessage() {\n return this.message;\n }", "public String getMessage() {\n return this.message;\n }", "public String getMessage() {\n return this.message;\n }", "public String getMessage() {\n return this.message;\n }", "public String getMessage() {\n\n\t\treturn message;\n\n\t}", "public String getMessage() {\n String message = super.getMessage();\n\n if (message == null) {\n message = \"\";\n }\n\n if (buffer != null) {\n return message + ((message.length() > 0) ? \" \" : \"\")\n + \"(Hexdump: \" + ByteBuffers.getHexdump(buffer) + ')';\n } else {\n return message;\n }\n }" ]
[ "0.8536966", "0.8045785", "0.78340733", "0.7823031", "0.7816968", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7790793", "0.7749748", "0.77412003", "0.77371466", "0.7715561", "0.7689786", "0.76847696", "0.7668983", "0.7644153", "0.76296324", "0.76146847", "0.7613283", "0.75994474", "0.75993395", "0.7595576", "0.7593327", "0.7588301", "0.75881106", "0.7587736", "0.7578598", "0.7573569", "0.75673205", "0.7564503", "0.7564503", "0.75626886", "0.75626886", "0.75626886", "0.7555535", "0.7552125", "0.7552125", "0.754714", "0.75466406", "0.75425625", "0.75425625", "0.75425625", "0.75425625", "0.7531454", "0.7531454", "0.75258774", "0.7520851", "0.7520851", "0.7520851", "0.7520851", "0.7520707", "0.7520707", "0.7519743", "0.75176907", "0.75176907", "0.75168294", "0.75168294", "0.75168294", "0.75168294", "0.75097615", "0.75052434", "0.75052434", "0.75052434", "0.749834", "0.7496043", "0.7494683", "0.74891233", "0.74880993", "0.74880993", "0.7485486", "0.74817187", "0.7477499", "0.7477298", "0.7470308", "0.7469209", "0.7468004", "0.7467024", "0.7459807", "0.74584866", "0.74584866", "0.74584866", "0.74584866", "0.74584866", "0.74584866", "0.74584866", "0.7455605", "0.74421126" ]
0.0
-1
Method to get the status.
public String getStatus() { return status; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int getStatus ()\n {\n return status;\n }", "public int getStatus ()\n {\n return status;\n }", "public Status getStatus();", "public String getStatus () {\r\n return status;\r\n }", "public int getStatus()\n {\n return status;\n }", "public int getStatus() {\n return status;\n }", "public int getStatus() {\n return status;\n }", "public int getStatus() {\n return status;\n }", "public int getStatus() {\n return status;\n }", "public int getStatus() {\n return status;\n }", "public Status getStatus()\n\t{\n\t\treturn status;\n\t}", "public synchronized String getStatus(){\n\t\treturn status;\n\t}", "public Status getStatus() {\r\n return status;\r\n }", "public java.lang.Object getStatus() {\n return status;\n }", "public Status getStatus()\n {\n return (this.status);\n }", "public String getStatus(){\r\n\t\treturn status;\r\n\t}", "public int getStatus();", "public int getStatus();", "public int getStatus();", "public long getStatus() {\r\n return status;\r\n }", "public Status getStatus() {\r\n\t return status;\r\n\t }", "public String getStatus() {\r\n return status;\r\n }", "public String getStatus() {\r\n return status;\r\n }", "public String getStatus() {\r\n return status;\r\n }", "public String getStatus() {\r\n return status;\r\n }", "public String getStatus() {\r\n return status;\r\n }", "public java.lang.String getStatus() {\r\n return status;\r\n }", "public int status() {\n return status;\n }", "public Status getStatus()\n {\n return status;\n }", "public String getStatus() {\r\n return status;\r\n }", "public String getStatus() {\r\n return status;\r\n }", "public Integer getStatus() {\r\n return status;\r\n }", "public Integer getStatus() {\r\n return status;\r\n }", "public Status getStatus() {\n return status;\n }", "public Status getStatus() {\n return status;\n }", "public Status getStatus() {\n return status;\n }", "public String getStatus(){\n\t\t\n\t\treturn this.status;\n\t}", "int getStatus();", "int getStatus();", "int getStatus();", "int getStatus();", "int getStatus();", "int getStatus();", "int getStatus();", "int getStatus();", "int getStatus();", "int getStatus();", "int getStatus();", "public java.lang.String getStatus () {\r\n\t\treturn status;\r\n\t}", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public Integer getStatus() {\n return status;\n }", "public String getStatus() { return status; }", "public java.lang.String getStatus() {\n return status;\n }", "public java.lang.String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }", "public String getStatus() {\n return status;\n }" ]
[ "0.8634437", "0.8634437", "0.857843", "0.85566664", "0.85139936", "0.8477326", "0.8477326", "0.8477326", "0.8477326", "0.8477326", "0.84763736", "0.8473222", "0.8470247", "0.84584945", "0.8452482", "0.84502923", "0.84400487", "0.84400487", "0.84400487", "0.843686", "0.8432289", "0.84293514", "0.84293514", "0.84293514", "0.84293514", "0.84293514", "0.84252274", "0.84178734", "0.841364", "0.8412087", "0.8412087", "0.84095216", "0.84095216", "0.8404261", "0.8404261", "0.8404261", "0.83938885", "0.83927554", "0.83927554", "0.83927554", "0.83927554", "0.83927554", "0.83927554", "0.83927554", "0.83927554", "0.83927554", "0.83927554", "0.83927554", "0.83925104", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.83842605", "0.8384036", "0.8379418", "0.8379418", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867", "0.8363867" ]
0.0
-1
Method to get the board.
public Board getBoard() { return board; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static Board getBoard(){\n\t\treturn board;\n\t}", "private Board getBoard() {\n return gameStatus.getBoard();\n }", "public Board getBoard ();", "protected Board getBoard() { // nao vou deixar public, vou deixar privado\n\t\treturn board;\n\t}", "public static WildBoard getBoard()\n {\n System.out.println(\"*** WildApp.getBoard() called\");\n \n return myBoard;\n }", "public Board getBoard() {\r\n return board;\r\n }", "public Board getBoard() {\n return board;\n }", "public Board getBoard() {\n return this.board;\n }", "public Board getBoard() {\n return this.board;\n }", "private void getBoard() {\n gameBoard = BoardFactory.makeBoard();\n }", "public Board getBoard() {\n\t\treturn this.board;\n\t}", "public Board getBoard() {\n\t\treturn board;\n\t}", "public Board getBoard() {\n\t\treturn board;\n\t}", "public Board getBoard()\r\n {\r\n return gameBoard;\r\n }", "public Board getBoard() {\n\t\treturn (this.gameBoard);\n\t}", "public GUIBoard getBoard() {\n return board;\n }", "Board getBoard() {\r\n return _board;\r\n }", "public Board getBoard() {\n return gameBoard;\n }", "public GameBoard getBoard() {\n return board;\n }", "public Integer[][] getBoard() {\n\t\treturn _board;\n\t}", "public Tile[][] getBoard() {\r\n return board;\r\n }", "public static char[][] getBoard() {\n\t\treturn board;\n\t}", "public Board getBoard(){\n return m_board;\n }", "Board getBoard() {\n return _board;\n }", "String getBoard();", "public Piece[][] getBoard(){\r\n\t\treturn this.board;\r\n\t}", "public int[][] getBoard() {\r\n\t\treturn board;\r\n\t}", "public Piece[][] getBoard() {\n return _board;\n }", "public int[][] getBoard() {\n\t\treturn board;\n\t}", "public Board getBoardObject() {\n return boardObject;\n }", "public Board aiGetBoard() {\n return b;\n }", "public Board getBoard(){\n return board;\n }", "public int[][] getBoard();", "public Board getCurrentBoard() {\n return boardIterator.board;\n }", "public Piece[] getBoard() {\n return board;\n }", "public FloorTile[][] getBoard(){\r\n return board;\r\n }", "public BlockFor2048[][] getBoard() {\n\t\treturn this.myBoard;\n\t}", "public int[] getBoard() {\n\t return board;\n }", "public GameToken[][] getBoard() {\n\t\treturn this.board;\n\t}", "public char[][] getBoard() {\n return board;\n\t}", "public Board getBoard(){return board;}", "public SudokuBoard getBoard() {\n return board;\n }", "public EditableBoard getBoard() {\n\treturn board;\n }", "public SudokuBoard getBoard() {\n return sb;\n }", "public List<GameBoard> getBoardList() {\r\n return new ArrayList<GameBoard>(this.boards);\r\n }", "public Board getBoard(){\n return undoBoards.peek();\n }", "public GoPlayingBoard getCurrentBoard() {\n \t\treturn currentBoard.clone();\n \t}", "public int[] getBoard() {\n return board.clone(); //return board.clone();\n }", "public Marker[][] getBoard() { return board; }", "public boolean[][] getBoard() {\r\n return board;\r\n }", "protected int[][] getBoard() {\n\t// EDIT: usar directamente .clone() referencia al mismo objeto, para\n\t// reutilizar el método en las rotaciones copiamos la matriz de forma\n\t// que no se referencien entre sí.\n\treturn deepCopy(board);\n }", "public FourBoard getBoard() {\n return board;\n }", "public BoardInterface[] getBoards();", "private CurrentBoard board() throws IOException, EncodeException {\n\n //obtain current board state to init POJO\n boolean[][] player = new boolean[model.BOARD_SIZE][model.BOARD_SIZE];\n boolean[][] occupied = new boolean[model.BOARD_SIZE][model.BOARD_SIZE];\n boolean[][] king = new boolean[model.BOARD_SIZE][model.BOARD_SIZE];\n for(int row = 0; row < model.getBoard().length; row++){\n for(int col = 0; col < model.getBoard()[row].length; col++) {\n player[row][col] = model.isPlayerOne(row, col);\n occupied[row][col] = model.squareIsOccupied(row, col);\n king[row][col] = model.squareHoldsKing(row,col);\n }\n }\n currentBoard.setDoubleJump(model.canDoubleJump);\n currentBoard.setPlayerOne(player);\n currentBoard.setKing(king);\n currentBoard.setOccupied(occupied);\n return currentBoard;\n }", "@Override\r\n\tpublic ArrayList<BoardVO> getBoardList() {\n\t\treturn boardDao.getBoardList();\r\n\t}", "public String getBoard() {\r\n\t\tString r = \"\";\r\n\t\tfor (int y = 0; y < 3; y++) {\r\n\t\t\tfor (int x = 0; x < 3; x++) {\r\n\t\t\t\tr = r + board[y][x];\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn r;\r\n\t}", "public Integer[][] GetCurrentBoard()\n {\n return new Integer[2][3];\n }", "public Board getPlayersBoard() {\n return playersBoard;\n }", "public BoardView getActiveBoard() {\n if (activePlayer == Piece.COLOR.RED)\n return getRedBoard();\n else\n return getWhiteBoard();\n }", "String[][] getBoard();", "public static Board getInstance(){\n\t\treturn instance;\n\t}", "@Override\n public Board getBoard(int id) {\n Board b = boardDataGateway.getBoardByID(id);\n if (b != null)\n b.setPins(getPinsOnBoard(b.getCreator().getUsername(), b.getName()));\n return b;\n }", "public JButton[][] getBoard(){\n return jbtnBoard;\n }", "@Override\n public BlockGrid getBoard() {\n return checkersBoard;\n }", "public Board<?> makeBoard() throws EscapeException {\n\t\tswitch (bi.getCoordinateId()) {\n\t\t\tcase HEX:\n\t\t\t\treturn makeHexBoard();\n\t\t\tcase ORTHOSQUARE:\n\t\t\t\treturn makeOrthoBoard();\n\t\t\tcase SQUARE:\n\t\t\t\treturn makeSquareBoard();\n\t\t\tdefault:\n\t\t\t\tthrow new EscapeException(\"Board does not exist!\");\n\t\t}\n\t}", "public int[][] get() {\r\n return gameBoard;\r\n }", "@Override\n\tpublic List<Board2DTO> getBoardList() throws Exception {\n\t\treturn board2Mapper.getBoardList();\n\t}", "public static Board getInstance() {\n\t\t\n\t\tif(boardObj == null)\n\t\t\tboardObj = new Board();\n\t\t\n\t\treturn boardObj;\n\t}", "public static SquareBoard getFullBoard() {\n\n\t\tSquareBoard fullBoard = new SquareBoard(BOARD_SIZE);\n\t\t\n\t\tfor (int ctr = 0; ctr < (BOARD_SIZE * BOARD_SIZE); ctr++) {\n\t\t\tfullBoard.getSpaceByIndex(ctr).setPiece(\n\t\t\t\t\tnew BasicPieceHelper(String.valueOf(ctr), null));\n\t\t}\n\t\t\n\t\treturn fullBoard;\n\t}", "@Override\n public Board getBoard(String username, String boardname) {\n return boardDataGateway.getBoard(username, boardname);\n }", "@Override\n\tpublic List<Map> boardList() {\n\t\treturn dao.boardList(session);\n\t}", "public static Board getInstance() {\n\t\treturn theInstance;\n\t}", "public GameCell[] getBoardCells(){\r\n return this.boardCells;\r\n }", "public char[][] getBoardState(){\n\t\treturn board;\n\t}", "public GameBoard getBoard(int i, int j) {\n return board[i][j];\n }", "public static GameBoard getGame(){\n\t\t\treturn gameBoard;\n\t\t}", "public Board getOpponentsBoard() {\n return opponentsBoard;\n }", "public BoardView getWhiteBoard() {\n return whiteBoard;\n }", "public char[][] getBoardState(){\n return board;\n }", "public ArrayList<Integer> getCurBoard() {\n return curBoard;\n }", "public GraphicalBoard getGraphicalBoard() {\n\treturn gb;\n }", "public Blackboard getBlackboard() {\r\n return blackboard;\r\n }", "String getBoardString();", "Data<List<Boards>> getBoards();", "public Pawn[][] getBoardGrid() {\n\t\treturn boardGrid;\n\t}", "private Board nextBoard () {\n while (!hasExhaustedDirections()) {\n getNextMove();\n directions_checked++;\n if (inBounds(move)) {\n return createMovedBoard(free, move);\n }\n }\n return null;\n }", "public Playboard getPlayboard();", "public BoardType getBoardType() {\r\n return this.boardType;\r\n }", "public BufferedImage getImage() {\n return boardImage;\n }", "public int getBoardLocation() {return boardLocation;}", "protected BoardGrid getGrid() {\n return GameController.getInstance().getGrid();\n }", "Color get(int col, int row) {\n return _board[row][col]; // FIXED.\n }", "public List<Building> getBoardBuildings() {\n return mPersonalBoardCards.getBoardBuildings();\n }", "public int getBoard_id(){\n return Board_id;\n }", "public static Board getInstance(){\n\t\tif (instance == null) \n\t\t{ \n\t\t\tinstance = new Board(); \n\t\t} \n\t\treturn instance; \n\t}", "public PentagoBoard getPentagoBoard() {\n return board;\n }", "public BoardView getRedBoard() {\n return redBoard;\n }", "public static Draw getRunningDrawBoard() {\r\n\t\tif (STATUS.equals(Gamestatus.RUNNING)) {\r\n\t\t\tGameplayMenu menu = (GameplayMenu) gui.getCurrentMenu();\r\n\t\t\treturn menu.getDrawBoard();\r\n\t\t}\r\n\t\treturn null;\r\n\t}", "public Node getBoardNode() {\r\n return tilesNode;\r\n }", "public long getBitboard() {\r\n return bitboard;\r\n }" ]
[ "0.8466777", "0.8408734", "0.84054905", "0.8283205", "0.8220366", "0.8215245", "0.8171079", "0.8160813", "0.8160813", "0.8157105", "0.806646", "0.8026628", "0.8026628", "0.79997015", "0.79624856", "0.78900695", "0.7882883", "0.7880713", "0.78638524", "0.7828765", "0.782561", "0.7789202", "0.7787495", "0.77873033", "0.7785332", "0.7784737", "0.7782072", "0.778088", "0.7760279", "0.76968056", "0.7675745", "0.76668036", "0.7649077", "0.76292366", "0.75729704", "0.75663656", "0.7563956", "0.75258374", "0.75236666", "0.7515105", "0.7490707", "0.7473389", "0.7472705", "0.74689734", "0.7399112", "0.738882", "0.7384876", "0.7366108", "0.7335816", "0.73312396", "0.733026", "0.72989357", "0.72665304", "0.72141004", "0.7129841", "0.7128662", "0.71262133", "0.7123829", "0.7123691", "0.6994183", "0.6984546", "0.69825995", "0.6978974", "0.6975722", "0.6969797", "0.6934328", "0.69248265", "0.68826103", "0.6881164", "0.6874136", "0.68708", "0.68583125", "0.68525237", "0.68420756", "0.6833804", "0.6807892", "0.67838883", "0.6762231", "0.6749962", "0.6749214", "0.67390203", "0.67209893", "0.6707502", "0.6662706", "0.6659252", "0.66558427", "0.6654735", "0.66390043", "0.663583", "0.66200435", "0.66107076", "0.6602955", "0.6592102", "0.6548163", "0.65432644", "0.6533542", "0.65150154", "0.6512729", "0.6503529", "0.6478817" ]
0.81974727
6
Method to get the player.
public Player getPlayer() { return player; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public Player getPlayer() {\r\n return world.getPlayer();\r\n }", "public Player getPlayer()\r\n\t{\r\n\t\treturn mPlayer;\r\n\t}", "public final Player getPlayer() {\n return player;\n }", "public Player getPlayer() {\r\n\t\treturn player;\r\n\t}", "public Player getPlayer() {\n\t\treturn this.player;\r\n\t}", "protected Player getPlayer() {\n return getGame().getPlayers().get(0);\n }", "public Player getPlayer() {\n\t\t\treturn player;\n\t\t}", "public Player getPlayer() {\n\t\treturn this.player;\n\t}", "public Player getPlayer() {\n\t\treturn player;\n\t}", "public Player getPlayer() {\n\t\treturn player;\n\t}", "public Player getPlayer() {\n\t\treturn player;\n\t}", "public Player getPlayer() {\n\t\treturn player;\n\t}", "public Player getPlayer() {\n\t\treturn player;\n\t}", "public Player getPlayer() {\n\t\treturn player;\n\t}", "public Player getPlayer() {\n\t\treturn player;\n\t}", "Player getPlayer();", "public Player getPlayer();", "public Player getPlayer();", "public Player getPlayer() {\n return player;\n }", "public Player getPlayer(){\n\t\treturn this.player;\n\t}", "public Player getPlayer() {\r\n return player;\r\n }", "public AbstractGameObject getPlayer() {\n return this.player;\n }", "public Player getPlayer() {\n return player;\n }", "public Player getPlayer() {\n return player;\n }", "public Player getPlayer() {\n return player;\n }", "public Player getPlayer() {\n return player;\n }", "public Player getPlayer() {\n return player;\n }", "public Player getPlayer() {\n\t\treturn p;\n\t}", "public Player getPlayer()\r\n {\r\n return player;\r\n }", "public String getPlayer() {\r\n return player;\r\n }", "public static EntityPlayer getPlayer() {\n\t\treturn ModLoader.getMinecraftInstance().thePlayer;\n\t}", "public PlayerID getPlayer(){\n\t\treturn this.player;\n\t}", "Player getCurrentPlayer();", "Player getCurrentPlayer();", "public Player getPlayer() {\n return p;\n }", "public Player getPlayer() {\n return (roomPlayer);\n }", "public Player getPlayer() {\n return me;\n }", "public PlayerEntity getPlayer() {\n return player;\n }", "public PlayerEntity getPlayer() {\n return player;\n }", "protected Player getPlayer() { return player; }", "public Player getCurrentPlayer(){\n String playerId = getUser().get_playerId();\n\n Player player = null;\n\n try {\n player = getCurrentGame().getPlayer(playerId);\n } catch(InvalidGameException e) {\n e.printStackTrace();\n System.out.println(\"This is the real Error\");\n }\n\n return player;\n }", "public int getPlayer() {\r\n\t\treturn myPlayer;\r\n\t}", "public Player getCurrentPlayer(){\n return this.currentPlayer;\n }", "public ServerPlayer getCurrentPlayer() {\r\n\t\treturn this.currentPlayer;\r\n\t}", "public Sprite getPlayer() {\n\t\treturn player;\n\t}", "public Player getCurrentPlayer() {\n return currentPlayer;\n }", "public Player getCurrentPlayer() {\n return currentPlayer;\n }", "public ViewerManager2 getPlayer() {\n return this.player;\n }", "public Player getPlayer() { return player; }", "public Player getPlayer() {\n return humanPlayer;\n }", "public int getPlayer() {\r\n\t\treturn player;\r\n\t}", "public Player getClientPlayer() {\n\t\treturn players.get(0);\n\t}", "public int getCurrentPlayer() {\n return player;\n }", "public Strider getPlayer() {\n return player;\n }", "String getPlayer();", "public String getPlayer() {\n return p;\n }", "public Player getPlayer(String username){\n return this.players.get(username);\n }", "public Player getPlayer() { return player;}", "public int getPlayer()\n {\n return this.player;\n }", "Player currentPlayer();", "@java.lang.Override\n public POGOProtos.Rpc.CombatProto.CombatPlayerProto getPlayer() {\n return player_ == null ? POGOProtos.Rpc.CombatProto.CombatPlayerProto.getDefaultInstance() : player_;\n }", "public Player getPlayer(){\r\n return player;\r\n }", "public int getCurrentPlayer() {\n\t\treturn player;\n\t}", "public POGOProtos.Rpc.CombatProto.CombatPlayerProto getPlayer() {\n if (playerBuilder_ == null) {\n return player_ == null ? POGOProtos.Rpc.CombatProto.CombatPlayerProto.getDefaultInstance() : player_;\n } else {\n return playerBuilder_.getMessage();\n }\n }", "public String getCurrentPlayer() {\n\t\treturn _currentPlayer;\n\t}", "public PlayerProfile getPlayer(P player){\n\n if(playerMap.containsKey(player)){\n //Player is safe to send\n return playerMap.get(player);\n } else {\n //Player isn't safe to send\n System.out.println(\"Tried to grab player \" + player.getName() + \"'s data, but it's not available\");\n return null;\n }\n }", "public User getCurrentPlayer() {\n\t\treturn currentPlayer;\n\t}", "@Override\n\tpublic List<Player> getPlayer() {\n\t\treturn ofy().load().type(Player.class).list();\n\t}", "public PlayerShared getPlayer(String token) throws RemoteException {\n return mainScreenProvider.getPlayer(token);\n }", "public String getCurrentPlayer() {\n return currentPlayer;\n }", "public Player getCurrentPlayer()\n\t{\n\t\treturn current;\n\t}", "public static Player getPlayer(Player player){\n Player returnPlayer = null;\n if (player != null) {\n try {\n returnPlayer = mapper.readValue(new File(\"Data\\\\PlayerData\\\\\" + getFileName(player) + \".json\"), Player.class);\n } catch (Exception e) {\n e.printStackTrace();\n }\n }\n return returnPlayer;\n }", "public PlayerView getPlayerView() {\n return playerView;\n }", "Player getPlayer(UUID playerId);", "@Override\n\tpublic Player getPlayer() {\n\t\treturn null;\n\t}", "public char getPlayer() {\n return player;\n }", "public PlayerData getPlayerData() {\n return player;\n }", "@SuppressWarnings(\"unused\")\n public static IHubParkourPlayer getPlayer(Player player) throws NullPointerException {\n if (player == null) {\n throw new NullPointerException(\"Player cannot be null\");\n }\n return CacheManager.getPlayer(player);\n }", "public Player currentPlayer() {\n\t\treturn (currentPlayer);\n\t}", "@Override\n\tpublic Player getBukkitPlayer() {\n\t\treturn this.bukkitPlayer;\n\t}", "public Player getPlayer(String name){ \n\t\tif (players.containsKey(name)) return players.get(name);\n\t\tPlayer player = getModPlayer(name);\n\t\tif (player != null) {\n\t\t\tplayers.put(name, player);\n\t\t\treturn player;\n\t\t}\n\t\treturn player;\n\t}", "public Player getPlayer(String username) {\n for (Player p : players) {\n if (p.username.equals(username))\n return p;\n }\n return null;\n }", "public final static PlayerHandler getPlayerHandler() {\r\n\t\treturn playerHandler;\r\n\t}", "public String getCurrentPlayer() {\r\n return this.playerIds[this.currentPlayer];\r\n }", "public static synchronized Player getInstance(){\n if(Player.player == null){\n Player.player = new Player();\n }\n return Player.player;\n }", "public PlayerModel getOwnerPlayer() {\r\n\t\treturn ownerPlayer;\r\n\t}", "public Player getPlayer(){\r\n\t\treturn acquiredBy;\r\n\t}", "@Override\n\tpublic String getPlayer() {\n\t\treturn null;\n\t}", "public int getCurrentPlayer(){\n return this.currentPlayer;\n }", "@Override\n public String getCurrentPlayer() {\n return godPower.getCurrentPlayer();\n }", "public String getPlayerName() {\n return this.playerName;\n }", "Player getSelectedPlayer();", "public Player getActivePlayer() {\n return activePlayer;\n }", "public Player getActivePlayer() {\r\n return activePlayer;\r\n }", "@Override\n @OnlyIn(value = Dist.CLIENT)\n public Player getPlayer(final UUID uuid)\n {\n if (Minecraft.getInstance().getCurrentServer() == null) return super.getPlayer(uuid);\n // Otherwise ask the world for the player.\n return this.getWorld().getPlayerByUUID(uuid);\n }", "public Player getFromPlayer()\n {\n // RETURN the CardMessage's fromPlayer\n return this.fromPlayer;\n }", "public PlayerParticipant getPlayer(int playerId) {\n try {\n String query = \"SELECT * from playerparticpant WHERE Id = \" + playerId;\n ResultSet resultSet = dbhelper.ExecuteSqlQuery(query);\n if (resultSet.next()) {\n PlayerParticipant playerParticipant = new PlayerParticipant();\n playerParticipant.matchHistoryUri = resultSet.getString(\"MatchHistoryUri\");\n playerParticipant.profileIcon = resultSet.getInt(\"ProfileIconId\");\n playerParticipant.summonerId = resultSet.getLong(\"SummonerId\");\n playerParticipant.summonerName = resultSet.getString(\"SummonerName\");\n \n return playerParticipant;\n }\n } catch (SQLException | IllegalStateException ex) {\n System.out.println(\"An error occurred: \" + ex.getMessage());\n }\n \n return null;\n }", "Player getPlayer(int playerNumber){\n return players.get(playerNumber);\n }", "Player getDormantPlayer();", "public String getPlayerName() {\n return playerName;\n }" ]
[ "0.8542545", "0.85092056", "0.8505778", "0.841649", "0.8410961", "0.8367053", "0.83547264", "0.8353832", "0.83325535", "0.83325535", "0.83325535", "0.83325535", "0.83325535", "0.83325535", "0.83325535", "0.8303289", "0.828025", "0.828025", "0.8274137", "0.8225734", "0.8206989", "0.81702316", "0.81699765", "0.81699765", "0.81699765", "0.81699765", "0.81699765", "0.8129723", "0.8101589", "0.8064766", "0.8046465", "0.80343115", "0.8017395", "0.8017395", "0.7940582", "0.79128146", "0.79112744", "0.79041624", "0.79041624", "0.78836447", "0.7882687", "0.7874949", "0.7848636", "0.77936006", "0.77546424", "0.77365714", "0.77365714", "0.772187", "0.7706728", "0.77062", "0.77048874", "0.7653859", "0.764445", "0.7635634", "0.7629544", "0.7597119", "0.7564537", "0.7551878", "0.75421387", "0.75005484", "0.7484484", "0.7471604", "0.7448224", "0.7442779", "0.74328077", "0.7430365", "0.7406698", "0.73969924", "0.73871475", "0.7387129", "0.7384362", "0.73678356", "0.7363241", "0.7361386", "0.7357401", "0.7351336", "0.7330057", "0.73257184", "0.7296687", "0.7279675", "0.72775364", "0.7218437", "0.72161824", "0.7185517", "0.71775407", "0.7161004", "0.71599054", "0.71302843", "0.71281034", "0.7128098", "0.7111191", "0.71079713", "0.70986784", "0.70958006", "0.7084521", "0.7070779", "0.70473427", "0.70446765", "0.704213", "0.7017551" ]
0.8179261
21
Populate the pets arraylist
private void populatepets(){ pets.add(new Cat("UnNamed")); pets.add(new Cow("UnNamed")); pets.add(new Dog("UnNamed")); pets.add(new Rabbit("UnNamed")); pets.add(new Rat("UnNamed")); pets.add(new Velociraptor("UnNamed")); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private void getPets(){\r\n\t\tfor(Player p : players){\r\n\t\t\tArrayList<Pet> currentpets = new ArrayList<>();\r\n\r\n\t\t\tSystem.out.println(\"How many pets for \" + p.getName() + \": \");\r\n\t\t\tint petnum = getNumber(1,3);\r\n\t\t\tfor(int i = 0; i < petnum; i++){\r\n\t\t\t\tSystem.out.println(\"Pet options are:\");\r\n\t\t\t\tint c = 1; //Counter for which pet, relating to which option\r\n\t\t\t\tfor(Pet option : pets){\r\n\t\t\t\t\tSystem.out.println(c + \". \" + option.getClass().getSimpleName() + \".\");\r\n\t\t\t\t\tc++;\r\n\t\t\t\t}\r\n\t\t\t\tSystem.out.println(\"Please Choose Your Pet With A Number:\");\r\n\t\t\t\tint selected = getNumber(1, 6);\r\n\t\t\t\tPet selectedpet = pets.get(selected - 1);\r\n\t\t\t\tSystem.out.println(\"Please Enter A Name For Your Pet: \");\r\n\t\t\t\tString petname = sc.next();\r\n\t\t\t\tselectedpet.setPetname(petname);\r\n\t\t\t\tSystem.out.println(\"You now have a pet named \" + selectedpet.getPetname());\r\n\t\t\t\tcurrentpets.add(selectedpet);\r\n\t\t\t}\r\n\t\t\tp.setPets(currentpets);\r\n\t\t}\r\n\t}", "public ArrayList<Pets> getPets(){\n DataBase db = new DataBase(context);\n initPets(db);\n return db.getPets();\n }", "private void populatePlantList(){\n\n for (Document doc : getPlantList()) {\n String picture = doc.getString(\"picture_url\");\n String name = doc.getString(\"plant_name\");\n String description = doc.getString(\"description\");\n ArrayList sunlightArray = doc.get(\"sunlight\", ArrayList.class);\n String min_sun = sunlightArray.get(0).toString();\n String max_sun = sunlightArray.get(1).toString();\n ArrayList temperatureArray = doc.get(\"temperature\", ArrayList.class);\n String min_temp = temperatureArray.get(0).toString();\n String max_temp = temperatureArray.get(1).toString();\n ArrayList humidityArray = doc.get(\"humidity\", ArrayList.class);\n String min_humidity = humidityArray.get(0).toString();\n String max_humidity = humidityArray.get(1).toString();\n\n listOfPlants.add(new RecyclerViewPlantItem(picture, name, description, min_sun, max_sun, min_temp, max_temp, min_humidity, max_humidity));\n }\n }", "public ArrayOfPetModel getPets() {\n return localPets;\n }", "private PotCollection loadPotList(){\n SharedPreferences preferences = getSharedPreferences(SHAREDPREF_SET, MODE_PRIVATE);\n int sizeOfPotList = preferences.getInt(SHAREDPREF_ITEM_POTLIST_SIZE, 0);\n for(int i = 0; i<sizeOfPotList; i++){\n Log.i(\"serving calculator\", \"once\");\n String potName = preferences.getString(SHAREDPREF_ITEM_POTLIST_NAME+i, \"N\");\n int potWeight = preferences.getInt(SHAREDPREF_ITEM_POTLIST_WEIGHT+i, 0);\n Pot tempPot = new Pot(potName, potWeight);\n potList.addPot(tempPot);\n }\n return potList;\n }", "public void addPets(PetPOJO pet) {\n pets.add(pet);\n }", "public void setPets(ArrayOfPetModel param) {\n localPetsTracker = true;\n\n this.localPets = param;\n }", "public void addItems() {\r\n\t\tproductSet.add(new FoodItems(1000, \"maggi\", 12.0, 100, new Date(), new Date(), \"yes\"));\r\n\t\tproductSet.add(new FoodItems(1001, \"Pulses\", 55.0, 50, new Date(), new Date(), \"yes\"));\r\n\t\tproductSet.add(new FoodItems(1004, \"Meat\", 101.53, 5, new Date(), new Date(), \"no\"));\r\n\t\tproductSet.add(new FoodItems(1006, \"Jelly\", 30.0, 73, new Date(), new Date(), \"no\"));\r\n\t\t\r\n\t\tproductSet.add(new Apparels(1005, \"t-shirt\", 1000.0, 10, \"small\", \"cotton\"));\r\n\t\tproductSet.add(new Apparels(1002, \"sweater\", 2000.0, 5,\"medium\", \"woolen\"));\r\n\t\tproductSet.add(new Apparels(1003, \"cardigan\", 1001.53,22, \"large\", \"cotton\"));\r\n\t\tproductSet.add(new Apparels(1007, \"shirt\", 500.99, 45,\"large\",\"woolen\"));\r\n\t\t\r\n\t\tproductSet.add(new Electronics(1010, \"tv\", 100000.0, 13, 10));\r\n\t\tproductSet.add(new Electronics(1012, \"mobile\", 20000.0, 20,12));\r\n\t\tproductSet.add(new Electronics(1013, \"watch\", 1101.53,50, 5));\r\n\t\tproductSet.add(new Electronics(1009, \"headphones\", 300.0, 60,2));\r\n\t\t\r\n\t}", "public void populateVehicleList() {\n\t\tfor (int i = 0; i < VEHICLE_LIST_SIZE; i++) {\n\t\t\tvehicleList[i] = createNewVehicle();\n\t\t}\n\t}", "public void setWeaponCardsAndPieces() {\n List<WeaponCard> weaponCards = new ArrayList<>(); // empty list for the new weapon cards\n List<WeaponPiece> weaponPieces = new ArrayList<>(); // empty list for the new weapon pieces\n\n Data data = new Data(\"data.json\"); // read data from data.json\n JSONObject weaponData = (JSONObject) data.getJsonData().get(\"Weapons\"); // get the weapon data from the data\n for (int i = 0; i < 6; i++) { // for loop 0 to 5\n String weaponName = String.valueOf(weaponData.get(String.valueOf(i))); // get the weapon name\n //Make and add weaponCard and WeaponPiece to their specified lists.\n weaponCards.add(new WeaponCard(weaponName));\n weaponPieces.add(new WeaponPiece(weaponName));\n }\n //Assign the lists into their class variables\n this.weaponCards = weaponCards;\n this.weaponPieces = weaponPieces;\n }", "public ArrayList<Pets> getPetList() {\n\n ArrayList<Pets> petList = new ArrayList<>();\n\n try {\n Statement statement = conn.createStatement();\n String sqlStatement = \"SELECT name FROM pets\";\n\n ResultSet rs = statement.executeQuery(sqlStatement);\n\n while (rs.next()) {\n //Create a new Pets object\n Pets pet = new Pets();\n pet.setName(rs.getString(\"name\"));\n\n System.out.println(pet.getName());\n\n }\n } catch (SQLException exception) {\n System.out.println(\"Error getting Pet name list: \" + exception);\n }\n return petList;\n }", "private ArrayList<SearchModel> initData() {\n // items in the arraylist\n ArrayList<SearchModel> foodList = new ArrayList<>();\n List<FoodModel> foods = foodModelList;\n for(int i=0; i< foods.size(); i++)\n {\n foodList.add(new SearchModel(foods.get(i).getName()));\n }\n return foodList;\n }", "private void populateData() {\n animals.add(new Animal(\"Bear Arlan\", 10, true, \"Student\",\n \"Watch cartoons\", R.drawable.bear));\n animals.add(new Animal(\"Marten Chrisst\", 15, true, \"McDonald employee\",\n \"Play video games\", R.drawable.marten));\n animals.add(new Animal(\"Octopus Tenta\", 18, false, \"Ink producer\",\n \"Camouflage and attack jellyfish\", R.drawable.octopus));\n animals.add(new Animal(\"Ostrich Mellow\", 19, false, \"Zoo runner\",\n \"Peck other animals\", R.drawable.ostrich));\n animals.add(new Animal(\"Raccoon Garack\", 21, true, \"Office worker\",\n \"Build diagrams for statistics\", R.drawable.racoon));\n animals.add(new Animal(\"Rooster Billo\", 16, true, \"Early waker\",\n \"Fly and chirp in morning\", R.drawable.rooster));\n animals.add(new Animal(\"Seagull Ranch\", 23, false, \"Scout\",\n \"Practice carrying water in mouth\", R.drawable.seagull));\n animals.add(new Animal(\"Seal Arlan\", 25, true, \"Security\",\n \"Work on belly muscles\", R.drawable.seal));\n animals.add(new Animal(\"Tiger Stitch\", 30, false, \"Hunter\",\n \"Make soup\", R.drawable.tiger));\n animals.add(new Animal(\"Zebra Dillian\", 6, true, \"Student\",\n \"Watch movies about zebras\", R.drawable.zebra));\n }", "public Collection<VirtualPet> pets() {\n\t\treturn shelterPets.values();\n\t}", "public void initialiseGodList() {\n PlayerCreator playerCreator = new PlayerCreator();\n for (int i = 0; i < playerCreator.getArrayGods().size(); i++)\n godListNames.add(playerCreator.getArrayGods().get(i).getGodName());\n }", "public Pizza(String _name, ArrayList<String> _toppings){\n this.name = _name;\n this.toppings = _toppings;\n }", "void updateList() throws Exception {\n\t\tlist.getItems().clear();\n\t\tfor(Plant p : plantsInBasket) {\n\t\t\tAnchorPane ap = new AnchorPane();\n\t\t\tLabel sname = new Label(p.getScientificName() + \" |\");\n\t\t\tLabel cname = new Label(p.getCommonName());\n\t\t\tsname.setFont(Font.loadFont(getClass().getResourceAsStream(\"/fonts/Roboto-Italic.ttf\"), 21));\n\t\t\tcname.setFont(Font.loadFont(getClass().getResourceAsStream(\"/fonts/Roboto-Italic.ttf\"), 21));\n HBox hBox = new HBox();\n hBox.setAlignment(Pos.CENTER_LEFT);\n \n \t\tImageView iv = new ImageView();\n \t\tiv.setImage(p.getPlantPic());\n \t\tiv.setPreserveRatio(true);\n \t iv.setFitHeight(PLANT_WD_HT);\n \t iv.setFitWidth(PLANT_WD_HT);\n \n \t Tooltip tooltip = new Tooltip(\"Common Name: \" + p.getCommonName() + System.lineSeparator()\n \t\t+ \"Spread: \" + p.getSpread() + \" ft.\" + System.lineSeparator() + \n \t\t\"Soil type: \" + p.getSoilType() + System.lineSeparator() +\n \t\t\"Sun level: \" + p.getSun() + System.lineSeparator() + \n \t\t\"Moisture: \" + p.getMoisture() + System.lineSeparator() +\"Lep Species Supported: \" + p.getLep().getNumLeps() + System.lineSeparator() +\n \t\t\"Most common lep: \" + p.getLep().getSpecies());\n \t ImageView ivLep = new ImageView(p.getLepPic());\n \t ivLep.setFitHeight(LEP_WD_HT);\n \t ivLep.setFitWidth(LEP_WD_HT);\n \t tooltip.setGraphic(ivLep);\n \t tooltip.setPrefWidth(TOOLTIP_SIZE);\n \n \t tooltip.setWrapText(true);\n \t Tooltip.install(iv, tooltip);\n // Add the values from our piece to the HBox\n hBox.getChildren().addAll(iv, sname, cname);\n \n \tImageView compost = new ImageView(new Image(getClass().getResourceAsStream(\"/img/compost.png\")));\n \tcompost.setFitHeight(COMPOST_SIZE);\n compost.setFitWidth(COMPOST_SIZE);\n \n Button b = new Button();\n b.setGraphic(compost);\n b.setStyle(\"-fx-background-color: #99B898;\");\n \n ap.getChildren().addAll(hBox, b);\n AnchorPane.setLeftAnchor(hBox, root.getWidth() / 3);\n AnchorPane.setRightAnchor(b, COMPOST_RIGHT);\n AnchorPane.setTopAnchor(b, COMPOST_TOP);\n \n b.setOnAction(e -> {\n \ttry {\n\t\t\t\t\tView.getGarden().removeFromBasket(p);\n\t\t\t\t\tupdateList();\n\t\t\t\t} catch (Exception e1) {\n\t\t\t\t\te1.printStackTrace();\n\t\t\t\t}\n \t\n \t\n });\n list.getItems().add(ap);\n\t\t}\n\t}", "public Pizza(){\n this.name = \"Plain Pizza\";\n this.toppings = new ArrayList<String>(Arrays.asList(\"Olive\", \"Cheese\"));\n }", "private void populateAltitudes()\r\n {\r\n for(int i=0; i<9; i++)\r\n {\r\n cboAltitude.addItem(aryAltitudes[i]);\r\n }\r\n }", "public CalcPriceTest() {\n goods = new ArrayList<>(NUM_PLANETS);\n planets = new ArrayList<>(NUM_PLANETS);\n for (int i = 0; i < planets.size(); i++) {\n planets.add(new Planet());\n goods.add(new ArrayList<>(NUM_GOODS));\n }\n for (int i = 0; i < planets.size(); i++) {\n Planet thisPlanet = planets.get(i);\n ArrayList<TradeGood> theseGoods = goods.get(i);\n for (TradeGood.GoodType type : TradeGood.GoodType.values()) {\n TradeGood newGood = new TradeGood(type, thisPlanet);\n theseGoods.add(newGood);\n }\n }\n }", "public void feedAll() {\n\t\tfor (VirtualPet p : shelterPets.values()) {\n\t\t\tp.feedPet();\n\t\t}\n\t}", "private ArrayList<Exoplanet> initExoplanets() throws IOException {\n Exoplanet e = new Exoplanet();\n ArrayList<Exoplanet> exoplanets = new ArrayList<Exoplanet>();\n for (int i = 0; i < e.getNumPlanets(); i++) {\n exoplanets.add(new Exoplanet(i));\n }\n return exoplanets;\n }", "@Override\n public List<Vessel> getVessels() {\n return new ArrayList<>(boats);\n }", "private void initFruits() {\n\t\tthis.fruits.clear();\n\t\tGraphFruit fruit = new GraphFruit();\n\t\tList<String> f = game.getFruits();\n\t\tfor(String s : f) {\n\t\t\tfruit.initFruit(s);\n\t\t\tthis.fruits.add(fruit);\n\t\t}\n\t}", "public void createAnimalsCollection() {\n ArrayList<DataSetAnimal> animalsFetched = getDFO().getAnimalData(getFILE_NAME()).getAnimals();\n setAnimals(new ArrayList<>());\n for (DataSetAnimal animal: animalsFetched) {\n String tmpBreed = animal.getBreedOrType().substring(animal.getBreedOrType().lastIndexOf(\" \") + 1);\n switch (tmpBreed) {\n case \"dolphin\":\n getAnimals().add(new AnimalDolphin(animal.getBreedOrType(), animal.getName(), animal.getYearOfBirth()));\n break;\n case \"duck\":\n getAnimals().add(new AnimalDuck(animal.getBreedOrType(), animal.getName(), animal.getYearOfBirth()));\n break;\n case \"cat\":\n getAnimals().add(new AnimalCat(animal.getBreedOrType(), animal.getName(), animal.getYearOfBirth()));\n break;\n case \"chicken\":\n getAnimals().add(new AnimalChicken(animal.getBreedOrType(), animal.getName(), animal.getYearOfBirth()));\n break;\n case \"horse\":\n getAnimals().add(new AnimalHorse(animal.getBreedOrType(), animal.getName(), animal.getYearOfBirth()));\n break;\n case \"shark\":\n getAnimals().add(new AnimalShark(animal.getBreedOrType(), animal.getName(), animal.getYearOfBirth()));\n break;\n case \"parakeet\":\n getAnimals().add(new AnimalParakeet(animal.getBreedOrType(), animal.getName(), animal.getYearOfBirth()));\n break;\n default:\n getAnimals().add(new AnimalDog(animal.getBreedOrType(), animal.getName(), animal.getYearOfBirth()));\n break;\n }\n }\n }", "public List<Box> packThings (List<Thing> things){\n List<Box> boxes = new ArrayList<Box>();\r\n \r\n for (Thing thing : things){\r\n Box box = new Box(boxesVolume); //creates new box with specified volume\r\n box.addThing(thing); //adds things to the Box\r\n boxes.add(box); //adds box to list of boxes\r\n }\r\n \r\n return boxes;\r\n }", "public List<Plant> initPlantList(final FieldPlant species)\n {\n final List<Plant> plantList = new ArrayList<>();\n\n if( species == FieldPlant.MORE )\n {\n final int randomCount = new Random().nextInt(25) + 25;\n for( int i = 0; i < randomCount; i++ )\n {\n plantList.add(new More(new Random().nextFloat() * 70));\n }\n }\n else if( species == FieldPlant.WHEAT )\n {\n final int randomCount = new Random().nextInt(25) + 25;\n for( int i = 0; i < randomCount; i++ )\n {\n plantList.add(new Wheat(new Random().nextFloat() * 70));\n }\n }\n else\n {\n LOG.warn(\"unauthorized entry - no data passed on\");\n }\n\n return plantList;\n }", "public static void stats(ArrayList<Player> playerList){\n \n //{\"blue\", \"pink\", \"yellow\", \"green\" }\n int colorArray[] = {0,0,0,0} ;\n //{ \"Cadbury Egg\", \"Reese's Egg\", \"pink Starburst\", \"yellow Peep\", \"25 cents\", \"50 cents\", \"one dollar\" }\n int contentsArray[] = {0,0,0,0,0,0,0};\n //creates an array the size of how many players are in the user picks\n int ps = playerList.size();\n int eggsFound[] = new int[ps];\n for (int i = 0; i < ps ;i++){\n //adds the number of eggs each player found to the eggsFound array\n eggsFound[i] = playerList.get(i).getNumEggs();\n\n //created this variable since we use it for a lot of upper bounds in our for loop\n int bs = playerList.get(i).getBasket().size();\n\n //for each player's basket it looks at every egg and 1 to the contentsArray in the index that coresponds to the egg's contents\n for (int e = 0; e < bs; e++){\n String color = playerList.get(i).getBasket().get(e).getEggColor();\n if(color.equals(\"blue\")){\n colorArray[0] += 1;\n }else if(color.equals(\"pink\")){\n colorArray[1] += 1;\n }else if(color.equals(\"yellow\")){\n colorArray[2] += 1;\n }else{\n colorArray[3] += 1;\n }\n }\n //for each player's basket it looks at every egg and 1 to the contentsArray in the index that coresponds to the egg's contents\n //Extra Credit 2: display contents\n for (int c = 0; c < bs; c++){\n String contents = playerList.get(i).getBasket().get(c).getEggContents();\n if(contents.equals(\"Cadbury Egg\")){\n contentsArray[0] += 1;\n }else if(contents.equals(\"Reese's Egg\")){\n contentsArray[1] += 1;\n }else if(contents.equals(\"pink Starburst\")){\n contentsArray[2] += 1;\n }else if(contents.equals(\"yellow Peep\")){\n contentsArray[3] += 1;\n }else if(contents.equals(\"25 cents\")){\n contentsArray[4] += 1;\n }else if(contents.equals(\"50 cents\")){\n contentsArray[5] += 1;\n }else{\n contentsArray[6] += 1;\n }\n }\n }\n //find the max number from the eggsFound array by comparing the first index to each subsequent one and replacing the comparision number with the higest one.\n int maxEggs = eggsFound[0];\n for(int k = 0; k < eggsFound.length; k++){\n maxEggs = Math.max(maxEggs, eggsFound[k]);\n }\n //creating an ArrayList to track winners. using a for loop and the eggsFound array to save \"winner string\" for each player who found the higest number of eggs\n ArrayList<String> winnerArray = new ArrayList<String>();\n for(int m = 0; m < eggsFound.length; m++){\n if (eggsFound[m] == maxEggs){\n winnerArray.add(\n \"Player \" + m + \" found the most eggs, with \" + eggsFound[m] + \" eggs!\");\n }\n }\n\n //sum up the number of eggs found by summing the values in the colorArray\n int totalEggs = 0;\n for(int x=0; x < colorArray.length; x++) {\n totalEggs += colorArray[x];\n }\n\n //Winner print out & find ties\n //Extra credit 3 : Additional features\n if(winnerArray.size() > 1){\n System.out.println(\"There is a Tie!\");\n System.out.println(\"Winners:\");\n for (String w : winnerArray) {\n\t System.out.println(w);\n }\n }else{\n System.out.println(\"Winner:\");\n for (String w : winnerArray) {\n\t System.out.println(w);\n }\n }\n \n \n System.out.println();\n //print out summary statistics for eggcolor\n System.out.println(\"Total eggs found: \" + totalEggs);\n System.out.println(\"Blue eggs: \" + colorArray[0]);\n System.out.println(\"Pink eggs: \" + colorArray[1]);\n System.out.println(\"Yellow eggs: \" + colorArray[2]);\n System.out.println(\"Green eggs: \" + colorArray[3]);\n \n System.out.println();\n //print out summary statistics for EggContents\n System.out.println(\"Total prizes found: \" + totalEggs);\n System.out.println(\"Cadbury Egg: \" + contentsArray[0]);\n System.out.println(\"Reese's Egg: \" + contentsArray[1]);\n System.out.println(\"pink Starburst: \" + contentsArray[2]);\n System.out.println(\"yellow Peep: \" + contentsArray[3]);\n System.out.println(\"25 cents: \" + contentsArray[4]);\n System.out.println(\"50 cents: \" + contentsArray[5]);\n System.out.println(\"one dollar: \" + contentsArray[6]);\n\n }", "@Before\r\n\tpublic void setList() {\r\n\t\tthis.list = new DoubleList();\r\n\t\tfor (int i = 0; i < 15; i++) {\r\n\t\t\tlist.add(new Munitions(i, i + 1, \"iron\"));\r\n\t\t}\r\n\t}", "public Pile(){\n pile = new ArrayList<Card>();\n }", "public void populateList() {\n }", "public static void setPlanets(ArrayList<Planet> planet){\n //ArrayList is a mutable reference type, so I should make a copy of the input ArrayList when \n //initializing the attribute. \n ArrayList<Planet> copy=new ArrayList<Planet>();\n for(int i=0;i<planet.size();i++){\n copy.add(planet.get(i));\n }\n planets=copy;\n //print out the details of every planet using toString method(the println will automatically using toString method)\n for(int j=0;j<planets.size();j++){\n System.out.println(planets.get(j));\n }\n }", "private void populate()\n\t{\n\t\tages = new int[] { 15, 18, 16, 16, 15, 16 }; \n\t}", "private void loadParkingLots() {\n ParkingLot metrotown = new ParkingLot(\"Metrotown\", 4);\n ParkingLot pacificcenter = new ParkingLot(\"PacificCenter\", 5);\n\n for (int i = 0; i < 3; i++) {\n metrotown.addParkingSpot(new ParkingSpot(\"M\" + i, \"medium\", 5));\n pacificcenter.addParkingSpot(new ParkingSpot(\"PC\" + i, \"large\", 4));\n }\n\n parkinglots.add(metrotown);\n parkinglots.add(pacificcenter);\n }", "private void setupListView() {\n potList = loadPotList();\n arrayofpots = potList.getPotDescriptions();\n refresher(arrayofpots);\n }", "private void buildShipsList() {\r\n ObservableList<ShipBar> lstShips = FXCollections.observableArrayList();\r\n Map<String, ShipType> ships = Data.SHIPS.get();\r\n for (String s : planet.getShips()) {\r\n ShipType ship = ships.get(s);\r\n ShipBar u = new ShipBar();\r\n u.setKey(s);\r\n u.setText(ship.getName());\r\n u.setPrice(ship.getPrice() - currentShip.getNetWorth());\r\n u.setToggleGroup(shipGroup);\r\n lstShips.add(u);\r\n }\r\n buyShips.setItems(lstShips);\r\n }", "private ArrayList<String> initList(String[] vastitems){\n return new ArrayList<>(Arrays.asList(vastitems));\n }", "private void fillFruitList()\n\t{\n\t\tfruitList.add(\"apple\");\n\t\tfruitList.add(\"kiwi\");\n\t\tfruitList.add(\"coconut\");\n\t\tfruitList.add(\"orange\");\n\t\tfruitList.add(\"pineapple\");\n\t\tfruitList.add(\"pear\");\n\t\tfruitList.add(\"banana\");\n\t\tfruitList.add(\"papaya\");\n\t\tfruitList.add(\"blueberry\");\n\t}", "public List<Pizza> getPizzas(){\n return new ArrayList<>(pizzas);\n }", "public void addComponents()\r\n\t{\n\t\tSteveTechFarming.fruit = new BlockFruit(SteveTechFarming.config.getBlockID(1202, \"Fruit\", null)).setBlockName(\"WiduX-SteveTech-Farm-Fruit\");\r\n\t\tSteveTechFarming.crops = new BlockCrops(SteveTechFarming.config.getBlockID(1203, \"Crops\", null)).setBlockName(\"WiduX-SteveTech-Farm-Crops\");\r\n\t\t\r\n\t\tSteveTechFarming.seeds = new ItemSeeds(SteveTechFarming.config.getItemID(11000, \"Seeds\", null)).setItemName(\"WiduX-SteveTech-Farm-Seeds\");\r\n\t\tSteveTechFarming.harvestedItems = new ItemHarvest(SteveTechFarming.config.getItemID(11002, \"Harvest\", null)).setItemName(\"WiduX-SteveTech-Farm-Harvest\");\r\n\t\tSteveTechFarming.creativeTools = new ItemCreativeTools(SteveTechFarming.config.getItemID(11001, \"Creative Tools\", null)).setItemName(\"WiduX-SteveTech-Farm-CTools\");\r\n\t\tSteveTechFarming.foods = new Item[EnumFood.getNumberFoods()];\r\n\t\tint firstFoodItemID = SteveTechFarming.config.getItemID(11003, \"Foods Array\", \"This is the first item ID in the list of foods. Item IDs used will start here, and use the next \" + EnumFood.getNumberFoods() + \" IDs. Make sure they are all available.\");\r\n\t\tfor(int idOffset = 0; idOffset < SteveTechFarming.foods.length; idOffset++)\r\n\t\t{\r\n\t\t\tEnumFood food = EnumFood.getFood(idOffset);\r\n\t\t\tSteveTechFarming.foods[idOffset] = new ItemSTFood(firstFoodItemID + idOffset, food).setItemName(\"WiduX-SteveTech-Farm-Foods-Food\" + idOffset);\r\n\t\t}\r\n\t}", "ArrayList<RecipeObject> getRecipes();", "public void limpaPontos() {\n\t\tthis.pontos = new ArrayList<Point>();\n\t}", "public void setFoods(ArrayList<Food> foods)\n {\n this.foods = foods;\n }", "public static void putCraftableItemInArrayList() {\n\n craftableItem.addItemToCraftableList(campfire);\n craftableItem.addItemToCraftableList(raft);\n craftableItem.addItemToCraftableList(axe);\n craftableItem.addItemToCraftableList(spear);\n }", "public void creatList()\n\t{\n\t\tbowlers.add(new Bowler(\"A\",44));\n\t\tbowlers.add(new Bowler(\"B\",25));\n\t\tbowlers.add(new Bowler(\"C\",2));\n\t\tbowlers.add(new Bowler(\"D\",10));\n\t\tbowlers.add(new Bowler(\"E\",6));\n\t}", "private void populateList(){\n //Build name list\n this.names = new String[] {\"Guy1\",\"Guy2\",\"Guy3\",\"Guy4\",\"Guy5\",\"Guy6\"};\n //Get adapter\n //ArrayAdapter<String>(Context, Layout to be used, Items to be placed)\n ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, R.layout.list_items, names);\n //Filling the list view\n ListView list = findViewById(R.id.transaction_list);\n list.setAdapter(adapter);\n }", "private void initList() {\n\n\t\tfor (int i = 0; i < lstPool.size(); i++) {\n\t\t\tpoolList.add(createPool(\"nomPool\", lstPool.get(i).getNomPool()));\n\t\t}\n\t}", "private void initItems() {\n\t\t// clouds\n\t\tclouds = new ArrayList<Cloud>();\n\t\tfor (int i = 0; i < CLOUDS_NUMBER; i++) {\n\t\t\tswitch (i) {\n\t\t\tcase 1:\n\t\t\t\tCloud cloud = new Cloud(20, 400);\n\t\t\t\tcloud.isRight = false;\n\t\t\t\tcloud.velocity.set(Cloud.CLOUD_MAX_VELOCITY, 0);\n\t\t\t\tclouds.add(cloud);\n\t\t\t\tbreak;\n\t\t\tcase 2:\n\t\t\t\tcloud = new Cloud(800, 300);\n\t\t\t\tcloud.isRight = false;\n\t\t\t\tcloud.velocity.set(Cloud.CLOUD_MAX_VELOCITY, 0);\n\t\t\t\tclouds.add(cloud);\n\t\t\tcase 3:\n\t\t\t\tcloud = new Cloud(800, 200);\n\t\t\t\tcloud.isRight = true;\n\t\t\t\tcloud.velocity.set(-Cloud.CLOUD_MAX_VELOCITY / 2, 0);\n\t\t\t\tclouds.add(cloud);\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\t// bats\n\t\tbats = new ArrayList<Bat>();\n\t\tfor (int i = 0; i < BATS_NUMBER; i++) {\n\t\t\tswitch (i) {\n\t\t\tcase 1:\n\t\t\t\tBat bat = new Bat(410, 400, Assets.BatRegion.getRegionWidth() / 3.4f,\n\t\t\t\t\t\tAssets.BatRegion.getRegionHeight() / 3.4f);\n\t\t\t\tbat.isRight = false;\n\t\t\t\tbat.angle = 0f;\n\t\t\t\tbat.fixAngle = 0f;\n\t\t\t\tbat.interval = 16;\n\t\t\t\tbats.add(bat);\n\t\t\t\tbreak;\n\t\t\tcase 2:\n\t\t\t\tbat = new Bat(100, 250, Assets.BatRegion.getRegionWidth() / 5.0f,\n\t\t\t\t\t\tAssets.BatRegion.getRegionHeight() / 5.0f);\n\t\t\t\tbat.isRight = false;\n\t\t\t\tbat.angle = 0f;\n\t\t\t\tbat.fixAngle = 0f;\n\t\t\t\tbat.interval = 16;\n\t\t\t\tbats.add(bat);\n\t\t\tcase 3:\n\t\t\t\tbat = new Bat(700, 140, Assets.BatRegion.getRegionWidth() / 2.4f,\n\t\t\t\t\t\tAssets.BatRegion.getRegionHeight() / 2.4f);\n\t\t\t\tbat.isRight = false;\n\t\t\t\tbat.angle = 360f - 20f;\n\t\t\t\tbat.fixAngle = 360f - 20f;\n\t\t\t\tbat.interval = 16;\n\t\t\t\tbats.add(bat);\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t}", "private void populatesetlist() {\n\t\tmyset.add(new set(\"Password\", R.drawable.passwordop, \"hello\"));\n\t\tmyset.add(new set(\"Help\", R.drawable.helpso4, \"hello\"));\n\t\tmyset.add(new set(\"About Developers\", R.drawable.aboutusop2, \"hello\"));\n\t\tmyset.add(new set(\"Home\", R.drawable.homefi, \"hello\"));\n\t}", "private void populateItems() {\n \t try {\n \t File myObj = new File(\"items.txt\");\n \t Scanner myReader = new Scanner(myObj);\n \t while (myReader.hasNextLine()) {\n\t \t String data = myReader.nextLine();\n\t \t String[] variables = data.split(\",\");\n\t \t int price = (int) Math.floor(Math.random() * 100); \n\t \t \n\t \t itemList += variables[0] + \",\"+ variables[1] +\",\" + \"0\" + \", \"+ \",\"+price + \",\";\n\t \t Item x = new Item(variables[0], 0, \"\", price, variables[1]);\n\t \t items.add(x);\n \t }\n \t myReader.close();\n \t } catch (FileNotFoundException e) {\n \t System.out.println(\"An error occurred.\");\n \t e.printStackTrace();\n \t }\n\t\t\n\t}", "protected void putItems() {\n\t\tlevelSetup[0][5].putItem(new Dynamite());\n\t\tlevelSetup[6][6].putItem(new Flint());\n\t\tlevelSetup[6][3].putItem(new ManaPotion());\n\t\tlevelSetup[5][0].putItem(new ManaPotion());\n\t\tlevelSetup[2][1].putItem(new HealthPotion());\n\t\tlevelSetup[3][6].putItem(new HealthPotion());\n\t\tlevelSetup[4][2].putItem(new Spinach());\n\t}", "public ArrayList<Integer> createList(){\r\n \tArrayList<Integer> test = new ArrayList<>();\r\n \tstarLabels = new ArrayList<>();\r\n \tconstLabels = new ArrayList<>();\r\n \tplanetLabels = new ArrayList<>();\r\n \tmesrLabels = new ArrayList<>();\r\n \tmoonLabel = new ArrayList<>();\r\n \t\r\n \tint a = 0;\r\n \tint b = 1;\r\n \tint c = 2;\r\n \tint d = 3;\r\n \t\r\n \tint size;\r\n \t\r\n \t//Go through the spaceobjectlist\r\n \tfor(int i = 0; i < AlexxWork2.spaceObjList.size(); i++) {\r\n \t\t\r\n \t\t//If object is visible and object has positive altitude continue\r\n \t\tif(AlexxWork2.spaceObjList.get(i).getMagnitude() != null \r\n \t\t\t\t&& (Double.valueOf(AlexxWork2.spaceObjList.get(i).getMagnitude()) <= 6.0) \r\n \t\t\t\t&& AlexxWork2.spaceObjList.get(i).getAltitude() > 0.5) {\r\n\t \t\t\r\n \t\t\t\r\n \t\t\t//Calculate X and Y\r\n \t\t\tint x = getX(2250, 2250, 1000, \r\n \t\t\t\t\t(int)AlexxWork2.spaceObjList.get(i).getAzimuth(), \r\n \t\t\t\t\t(int)AlexxWork2.spaceObjList.get(i).getAltitude());\r\n \t\t\t\r\n\t\t\t\tint y = getY(2250, 2250, 1000, \r\n\t\t\t\t\t\t(int)AlexxWork2.spaceObjList.get(i).getAzimuth(), \r\n\t\t\t\t\t\t(int)AlexxWork2.spaceObjList.get(i).getAltitude());\r\n\t\t\t\t\r\n\t\t\t\t//Load stars\r\n\t\t\t\tif(AlexxWork2.spaceObjList.get(i).getType() == \"STAR\" \r\n\t\t\t\t\t\t&& AlexxWork2.spaceObjList.get(i).getProperName() != null \r\n\t\t\t\t\t\t&& AlexxWork2.spaceObjList.get(i).getProperName() != \"\") {\r\n\t\t\t\t\t\r\n\t\t\t\t\tif(AlexxWork2.starNamesCB \r\n\t\t\t\t\t\t\t&& Double.valueOf(AlexxWork2.spaceObjList.get(i).getMagnitude()) <= 6.0) {\r\n\t\t\t\t\t\ttry {\r\n\t\t\t\t\t\t\t//Filter out number only star names\r\n\t\t\t\t\t\t\tint testInt = Integer.parseInt(AlexxWork2.spaceObjList.get(i).getProperName());\r\n\t\t\t\t\t\t\t} catch (NumberFormatException | NullPointerException nfe) {\r\n\t\t\t\t\t\t\t\tstarLabels.add(AlexxWork2.spaceObjList.get(i).getProperName());\r\n\t\t\t\t\t\t\t\tstarLabels.add(String.valueOf(x));\r\n\t\t\t\t\t\t\t\tstarLabels.add(String.valueOf(y));\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t//Load constellation data\r\n\t\t\t\t\tif(herculesNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tString name = AlexxWork2.spaceObjList.get(i).getProperName();\r\n\t\t\t\t\t\tloadHerculesLocation(name, x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(ursaMinorNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tString name = AlexxWork2.spaceObjList.get(i).getProperName();\r\n\t\t\t\t\t\tloadUrsaMinorLocation(name, x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(ursaMajorNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tString name = AlexxWork2.spaceObjList.get(i).getProperName();\r\n\t\t\t\t\t\tloadUrsaMajorLocation(name, x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(libraNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tString name = AlexxWork2.spaceObjList.get(i).getProperName();\r\n\t\t\t\t\t\tloadLibraLocation(name, x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(andromedaNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadAndromedaLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(aquariusNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadAquariusLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(aquilaNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadAquilaLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(ariesNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadAriesLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(aurigaNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadAurigaLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(bootesNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadBootesLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(cancerNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadCancerLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(canisMajorNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadCanisMajorLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(canisMinorNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadCanisMinorLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(capricornusNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadCapricornusLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(cassiopeiaNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadCassiopeiaLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(centaurusNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadCentaurusLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(cepheusNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadCepheusLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(cruxNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadCruxLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(cygnusNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadCygnusLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(dracoNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadDracoLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(geminiNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadGeminiLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(hydraNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadHydraLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(leoNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadLeoLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(lyraNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadLyraLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(orionNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadOrionLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(pegasusNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadPegasusLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(perseusNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadPerseusLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(piscesNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadPiscesLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(sagittariusNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadSagittariusLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(scorpioNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadScorpioLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(taurusNames.contains(AlexxWork2.spaceObjList.get(i).getProperName())) {\r\n\t\t\t\t\t\tloadTaurusLocation(AlexxWork2.spaceObjList.get(i).getProperName(), x, y);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t//Add coordinates to list\r\n\t \t\ttest.add(a, x);\r\n\t \t\ttest.add(b, y);\r\n\t \t\t\r\n\t \t\t//Add moon information if visible\r\n\t \t\tif(AlexxWork2.spaceObjList.get(i).getProperName() == \"MOON\") {\r\n size = 22;\r\n String moonName = AlexxWork2.spaceObjList.get(i).getProperName() + \": \" + AlexxWork2.spaceObjList.get(i).getType();\r\n moonLabel.add(0, moonName);\r\n moonLabel.add(1, String.valueOf(x));\r\n moonLabel.add(2, String.valueOf(y));\r\n }\r\n\t \t\t\r\n\t \t\t//If object is planet, set the size\r\n\t \t\telse if(AlexxWork2.spaceObjList.get(i).getType() == \"PLAN\"){\r\n\t \t\t\tsize = 16;\r\n\t \t\t}\r\n\t \t\t\r\n\t \t\t//Else set size based on mag\r\n\t \t\telse{\r\n\t \t\t\tsize = getSize(Double.valueOf(AlexxWork2.spaceObjList.get(i).getMagnitude()));\r\n\t \t\t}\r\n\t \t\t\r\n\t \t\t//Add size to list\r\n\t \t\ttest.add(c, size);\r\n\t \t\ttest.add(d, size);\r\n\t \t\ta = d + 1;\r\n\t \t\tb = a + 1;\r\n\t \t\tc = b + 1;\r\n\t \t\td = c + 1;\r\n \t\t}\r\n \t\t\r\n \t\t//Load constellation labels\r\n \t\tif(AlexxWork2.constellationsCB) {\r\n\t\t\t\tif(AlexxWork2.spaceObjList.get(i).getType() == \"CONST\" \r\n\t\t\t\t\t\t&& AlexxWork2.spaceObjList.get(i).getConstName() != null \r\n\t\t\t\t\t\t&& AlexxWork2.spaceObjList.get(i).getConstName() != \"\"\r\n\t\t\t\t\t\t&& AlexxWork2.spaceObjList.get(i).getAltitude() > 1) {\r\n\t\t\t\t\tint x = getX(2250, 2250, 1000, (int)AlexxWork2.spaceObjList.get(i).getAzimuth(), (int)AlexxWork2.spaceObjList.get(i).getAltitude());\r\n\t\t\t\t\tint y = getY(2250, 2250, 1000, (int)AlexxWork2.spaceObjList.get(i).getAzimuth(), (int)AlexxWork2.spaceObjList.get(i).getAltitude());\r\n\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\tconstLabels.add(AlexxWork2.spaceObjList.get(i).getConstName());\r\n\t\t\t\t\tconstLabels.add(String.valueOf(x));\r\n\t\t\t\t\tconstLabels.add(String.valueOf(y));\r\n\t\t\t\t}\r\n\t\t\t}\r\n \t\t\r\n \t\t//Load planet labels\r\n \t\tif(AlexxWork2.planetsCB) {\r\n\t\t\t\tif(AlexxWork2.spaceObjList.get(i).getType() == \"PLAN\" \r\n\t\t\t\t\t\t&& AlexxWork2.spaceObjList.get(i).getProperName() != null \r\n\t\t\t\t\t\t&& AlexxWork2.spaceObjList.get(i).getProperName() != \"\"\r\n\t\t\t\t\t\t&& AlexxWork2.spaceObjList.get(i).getAltitude() > 1) {\r\n\t\t\t\t\tint x = getX(2250, 2250, 1000, (int)AlexxWork2.spaceObjList.get(i).getAzimuth(), (int)AlexxWork2.spaceObjList.get(i).getAltitude());\r\n\t\t\t\t\tint y = getY(2250, 2250, 1000, (int)AlexxWork2.spaceObjList.get(i).getAzimuth(), (int)AlexxWork2.spaceObjList.get(i).getAltitude());\r\n\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\tplanetLabels.add(AlexxWork2.spaceObjList.get(i).getProperName());\r\n\t\t\t\t\tplanetLabels.add(String.valueOf(x));\r\n\t\t\t\t\tplanetLabels.add(String.valueOf(y));\r\n\t\t\t\t}\r\n\t\t\t}\r\n \t\t\r\n \t\t//Load messier labels\r\n \t\tif(AlexxWork2.messierCB) {\r\n\t\t\t\tif(AlexxWork2.spaceObjList.get(i).getType() == \"MESR\" \r\n\t\t\t\t\t\t&& AlexxWork2.spaceObjList.get(i).getProperName() != null \r\n\t\t\t\t\t\t&& AlexxWork2.spaceObjList.get(i).getProperName() != \"\"\r\n\t\t\t\t\t\t&& AlexxWork2.spaceObjList.get(i).getAltitude() > 1) {\r\n\t\t\t\t\tint x = getX(2250, 2250, 1000, (int)AlexxWork2.spaceObjList.get(i).getAzimuth(), (int)AlexxWork2.spaceObjList.get(i).getAltitude());\r\n\t\t\t\t\tint y = getY(2250, 2250, 1000, (int)AlexxWork2.spaceObjList.get(i).getAzimuth(), (int)AlexxWork2.spaceObjList.get(i).getAltitude());\r\n\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\tmesrLabels.add(AlexxWork2.spaceObjList.get(i).getProperName());\r\n\t\t\t\t\tmesrLabels.add(String.valueOf(x));\r\n\t\t\t\t\tmesrLabels.add(String.valueOf(y));\r\n\t\t\t\t}\r\n\t\t\t}\r\n \t}\r\n \t\r\n \t//Return list \r\n \treturn test;\r\n }", "public void addIngredientRecipe(ArrayList<IngredientRecipePOJO> ingr);", "public static void hunt(ArrayList<Player> playerList){\n Random r = new Random();\n for (int i = 0; i < playerList.size();i++){\n int eggNum = r.nextInt(11);\n for(int e = 0; e < eggNum; e++){\n Egg egg = new Egg();\n playerList.get(i).foundEgg(egg);\n }\n }\n }", "private void addDog() {\n\t\tfor (int i = 0; i < 5; i++) {\n\t\t\tString numID = id.get(i);\n\t\t\tString name = names.get(i);\n\t\t\tString breed = breeds.get(i);\n\t\t\tString dateBirth = date.get(i+1);\n\t\t\tString img = dogImg.get(i);\n\t\t\t\t\t\t\n\t\t\t//Adding the dogs to the list\n\t\t\tlistOfDogs.add(new Dog(app, numID, name, breed, dateBirth, img));\n\t\t}\t\t\n\t}", "public void populatePalicoWeaponList()\r\n\t{\r\n\t\tpalicoWeapons = FXCollections.observableArrayList();\r\n\t\tselect(\"SELECT * FROM Palico_Weapon\");\r\n\t}", "private static void generate_potions_list(File fp) {\r\n\t\tpotions_database = new ArrayList<Potion>();\r\n\t\tString line;\r\n\t\tString[] potion_info;\r\n\t\tString[] ingredients = new String[2]; //2 ingredients per potion\r\n\t\t\r\n\t\ttry {\r\n\t\t\tScanner scnr = new Scanner(fp);\r\n\r\n\t\t\twhile(scnr.hasNextLine()) {\r\n\t\t\t\tline = scnr.nextLine();\r\n\t\t\t\tpotion_info = line.split(line,',');\r\n\t\t\t\tingredients[0] = potion_info[1];\r\n\t\t\t\tingredients[1] = potion_info[2];\r\n\t\t\t\t\r\n\t\t\t\tPotion pot = new Potion(potion_info[0], ingredients, Integer.parseInt(potion_info[3]));\r\n\t\t\t\tpotions_database.add(pot);\r\n\t\t\t}\r\n\t\t\tscnr.close();\r\n\t\t} catch(FileNotFoundException e) {\r\n\t\t\tSystem.out.println(\"The file was not located. Check file name.\");\r\n\t\t}\r\n\t\t\r\n\t\t//sort the database by potion value\r\n\t\tCollections.sort(potions_database, new PotionComparator());\r\n\t\t\r\n\t}", "Sharks() {\n sharks = new ArrayList<Shark>(); // Initialize the ArrayList\n }", "public void setAnimals(ArrayList<Animal> animals) { this.animals = animals; }", "private void filllist() {\n mAlLocationBox.clear();\n DatabaseHandler databaseHandler=new DatabaseHandler(this);\n ArrayList<ArrayList<Object>> data = databaseHandler.listIitems();\n\n for (int p = 0; p < data.size(); p++) {\n mLocationBox = new LocationBox();\n ArrayList<Object> temp = data.get(p);\n Log.e(\"List\", temp.get(0).toString());\n Log.e(\"List\", temp.get(1).toString());\n Log.e(\"List\", temp.get(2).toString());\n Log.e(\"List\", temp.get(3).toString());\n mLocationBox.setId(Integer.valueOf(temp.get(0).toString()));\n mLocationBox.setName(temp.get(1).toString());\n mLocationBox.setMode(temp.get(2).toString());\n mLocationBox.setStatus(temp.get(3).toString());\n mAlLocationBox.add(mLocationBox);\n }\n LocationBoxAdapter locationBoxAdapter = new LocationBoxAdapter(LocationBoxListActivity.this,mAlLocationBox);\n listcontent.setAdapter(locationBoxAdapter);\n }", "private void prepareAlbums() {\n\n Album a;\n\n for(HashMap.Entry<String,ArrayList<String>> entry : Test.subcatList.get(name).entrySet()){\n key = entry.getKey();\n value = entry.getValue();\n a = new Album(key , value.get(2));\n albumList.add(a);\n System.out.println(\"dddd : \" + key + \" \" + value.get(2));\n }\n\n adapter.notifyDataSetChanged();\n\n }", "private void addItems() {\n int random3 = 0;\n for (int i = 0; i < MAP_LENGTH; i++) {\n for (int j = 0; j < MAP_LENGTH; j++) {\n random3 = (int)(Math.round(Math.random()*9));\n if (tileMap[i][j].getTerrain() instanceof Grass) {\n if (adjacentCity(i, j) && tileMap[i][j].getCity() == null) { //Only have an item if possibly within city borders\n if (random3 == 0) {\n tileMap[i][j].setResource(new Fruit(i,j)); //Rep Fruit\n } else if (random3 == 1) {\n tileMap[i][j].setResource(new Animal(i,j)); //Rep Animal\n } else if (random3 == 2) {\n tileMap[i][j].setResource(new Forest(i,j)); //Rep Trees (forest)\n } else if (random3 == 3) {\n tileMap[i][j].setResource(new Crop(i,j)); //Rep Crop\n }\n }\n } else {\n if (adjacentCity(i, j)) {\n if (random3 < 2) {\n tileMap[i][j].setResource(new Fish(i, j)); //Rep fish\n } else if (random3 == 4) {\n if (Math.random() < 0.5) {\n tileMap[i][j].setResource(new Whale(i, j)); //Rep whale\n }\n }\n }\n }\n }\n }\n }", "public Pokedex() {\n pokedex = new ArrayList<PokemonSpecies>();\n }", "private void listParkingLots() {\n for (ParkingLot pl: parkinglots) {\n System.out.println(pl.getName() + \" | price: \" + pl.getPrice() + \" /hour\");\n }\n }", "private void createItems()\n {\n Item belt, nappies, phone, money, cigarretes, \n jacket, cereal, shoes, keys, comics, bra, \n bread, bowl, computer;\n\n belt = new Item(2,\"Keeps something from falling\",\"Belt\");\n nappies = new Item(7,\"Holds the unspeakable\",\"Nappies\");\n phone = new Item(4, \"A electronic device that holds every answer\",\"Iphone 10\");\n money = new Item(1, \"A form of currency\",\"Money\");\n cigarretes = new Item(2,\"It's bad for health\",\"Cigarretes\");\n jacket = new Item(3,\"Keeps you warm and cozy\", \"Jacket\");\n cereal = new Item(3, \"What you eat for breakfast\",\"Kellog's Rice Kripsies\");\n shoes = new Item(5,\"Used for walking\", \"Sneakers\");\n keys = new Item(2, \"Unlock stuff\", \"Keys\");\n comics = new Item(2, \"A popular comic\",\"Batman Chronicles\");\n bra = new Item(3,\"What is this thing?, Eeeewww\", \"Bra\");\n bread = new Item(6,\"Your best source of carbohydrates\",\"Bread\");\n bowl = new Item(4,\"where food is placed\",\"Plate\");\n computer = new Item(10,\"A computational machine\",\"Computer\");\n\n items.add(belt);\n items.add(nappies);\n items.add(phone);\n items.add(money);\n items.add(cigarretes);\n items.add(jacket);\n items.add(cereal);\n items.add(shoes);\n items.add(keys);\n items.add(comics);\n items.add(bra);\n items.add(bread);\n items.add(bowl);\n items.add(computer);\n }", "public static void recap(ArrayList<Player> playerList){\n for (int i = 0; i < playerList.size();i++){\n System.out.println(\"Player \" + i + \" found \" + playerList.get(i).getNumEggs() + \" eggs\");\n playerList.get(i).printBasket();\n System.out.println();\n } \n }", "private ArrayList<Item> getData() { // generates an array containing 3 Item class objects\n\n // cost\n String[] cost = getResources().getStringArray(R.array.elvCostItems);\n Item i1=new Item(cost[0], new ArrayList<>(Collections.singletonList(cost[5])),false); // Define an Item object call i1\n i1.elements.add(cost[1]); // child elements below\n i1.elements.add(cost[2]);\n i1.elements.add(cost[3]);\n i1.elements.add(cost[4]);\n i1.elements.add(cost[5]);\n i1.elements.add(cost[6]);\n\n // activity or event\n String[] category = getResources().getStringArray(R.array.elvCategoryItems);\n Item i2=new Item(category[0], new ArrayList<>(Arrays.asList(category[1],category[2])),true); // Item.Option is set by the arg1 and default selection is set by arg 2\n i2.elements.add(category[1]);\n i2.elements.add(category[2]);\n\n // city\n String[] location = getResources().getStringArray(R.array.elvLocationItems);\n Item i4=new Item(location[0],new ArrayList<>(Collections.singletonList(location[1])),false);\n i4.elements.add(location[1]);\n\n // distance away\n String[] distance = getResources().getStringArray(R.array.elvDistanceItems);\n Item i5=new Item(distance[0],new ArrayList<>(Collections.singletonList(distance[4])),false);\n i5.elements.add(distance[1]);\n i5.elements.add(distance[2]);\n i5.elements.add(distance[3]);\n i5.elements.add(distance[4]);\n i5.elements.add(distance[5]);\n\n // other - disabled access, indoors, etc\n String[] other = getResources().getStringArray(R.array.elvOtherItems);\n ArrayList<String> temp = new ArrayList<>();\n Item i6=new Item(other[0], temp,true);\n i6.elements.add(other[1]);\n i6.elements.add(other[2]);\n i6.elements.add(other[3]);\n i6.elements.add(other[4]);\n i6.elements.add(other[5]);\n i6.elements.add(other[6]);\n\n // add items to the elv\n ArrayList<Item> allItems=new ArrayList<>(); // append all Item objects into an ArrayList\n allItems.add(i1);\n allItems.add(i2);\n allItems.add(i4);\n allItems.add(i5);\n allItems.add(i6);\n\n return allItems;\n }", "public boolean getPets() {\n\t\treturn this.pets;\n\t}", "public void setSuspectCardsAndPlayerPieces() {\n List<SuspectCard> suspectCards = new ArrayList<SuspectCard>(); // empty list for the suspect cards\n List<PlayerPiece> playerPieces = new ArrayList<PlayerPiece>(); // empty list for playerPieces\n Data data = new Data(\"data.json\");// read data from file data.json\n JSONObject suspectData = (JSONObject) data.getJsonData().get(\"Suspects\");// get the data within the class suspects\n for (int i = 0; i < 6; i++) {// for i from 0 to 5\n String suspectName = String.valueOf(suspectData.get(String.valueOf(i))); // Get name of suspect\n PlayerPiece playerPiece = new PlayerPiece(suspectName); // new playerPiece instance\n suspectCards.add(new SuspectCard(suspectName)); // add a new instance of suspectCard into suspectCards\n playerPieces.add(playerPiece);// add playerPiece instance into playerPieces\n\n }\n // assign the lists to class variables.\n this.suspectCards = suspectCards;\n this.playerPieces = playerPieces;\n }", "@Override\r\n\tpublic List<Pilot> getAllPilots() {\r\n\t\tList<Pilot> cloned = new ArrayList<>(pilots);\r\n\t\treturn cloned;\r\n\t}", "public void bindPlatsDataExample(){\n Categorie categorie = new Categorie();\n categorie.setId(1);\n for (String value : getTajineExampleList()) {\n Plat plat = new Plat();\n plat.setNom(value);\n plat.setCategorie(categorie);\n this.add(plat);\n }\n\n //INSERT CATEGORIE COUSCOUS PLAT (la categorie couscous est 2 dans notre exemple\n Categorie categorie2 = new Categorie();\n categorie2.setId(2);\n for (String value : getCouscousExampleList()) {\n Plat plat = new Plat();\n plat.setNom(value);\n plat.setCategorie(categorie2);\n this.add(plat);\n }\n\n //INSERT CATEGORIE CASSOLETTES PLAT (la categorie couscous est 3 dans notre exemple\n Categorie categorie3 = new Categorie();\n categorie3.setId(3);\n for (String value : getCassoletteExampleList()) {\n Plat plat = new Plat();\n plat.setNom(value);\n plat.setCategorie(categorie3);\n this.add(plat);\n }\n }", "public static void createPlanets() {\n\t\tplanets = new PlanetV4[planetNames.length];\n\t\tfor (int i = 0; i < planetNames.length; i ++) {\n\t\t\tplanets[i] = new PlanetV4(planetNames[i], planetMasses[i], planetDiameters[i], planetPositions[i], planetVelocities[i], planetCircles[i]);\n\t\t\t//mainFrame.add(planets[i]);\n\t\t}\n\t}", "public Recipes()\n {\n\t\titems = new ArrayList<food>();\n }", "private void prepareArrayLits(){\t\n\t\tprogressDialog_1 = ProgressDialog.show(SlyThemesActivity.this, \"\",Constants.PROCESSING_REQUEST);\n\n\t\tadapter = new ListViewNewRestaurantAdapter(this, itemList);\n\t\tlistview.setAdapter(adapter);\n\t\tprogressDialog_1.dismiss();\n\t}", "private void fillMusicList()\n\t{\n\t\tmusicList.add(\"violin\");\n\t\tmusicList.add(\"viola\");\n\t\tmusicList.add(\"cello\");\n\t\tmusicList.add(\"bass\");\n\t\tmusicList.add(\"guitar\");\n\t\tmusicList.add(\"drums\");\n\t\tmusicList.add(\"tuba\");\n\t\tmusicList.add(\"flute\");\n\t\tmusicList.add(\"harp\");\n\t}", "public ArrayList<Pokemon> getAllPokemon(){\n\t\treturn caughtPokemon; \n\t}", "public void popItems() {\n\t\t\n\t\tItemList.add(HPup);\n\t\tItemList.add(SHPup);\n\t\tItemList.add(DMGup);\n\t\tItemList.add(SDMGup);\n\t\tItemList.add(EVup);\n\t\tItemList.add(SEVup);\n\t\t\n\t\trandomDrops.add(HPup);\n\t\trandomDrops.add(SHPup);\n\t\trandomDrops.add(DMGup);\n\t\trandomDrops.add(SDMGup);\n\t\trandomDrops.add(EVup);\n\t\trandomDrops.add(SEVup);\n\t\t\n\t\tcombatDrops.add(SHPup);\n\t\tcombatDrops.add(SDMGup);\n\t\tcombatDrops.add(SEVup);\n\t}", "private static ArrayList<Galaxy> createGalaxies() {\n ArrayList<Galaxy> galaxies = new ArrayList<>();\n try {\n String bareJSON = new String(Files.readAllBytes(Paths.get(\"Galaxies.json\")));\n JSONArray jarray = new JSONArray(bareJSON);\n\n for(int i = 0; i<jarray.length(); i++) {\n JSONObject JSONgalaxy = jarray.getJSONObject(i);\n\n //System.out.println(\"Galaxyname = \" + JSONgalaxy.getString(\"galaxy\").charAt(0));\n Galaxy galaxy = new Galaxy(JSONgalaxy.getString(\"galaxy\").charAt(0));\n galaxies.add(galaxy);\n\n JSONArray stars = JSONgalaxy.getJSONArray(\"stars\");\n for (int y = 0; y<stars.length(); y++) {\n int number = y+1;\n char colour = stars.getJSONObject(y).getString(\"colour\").charAt(0);\n galaxy.addStar(new Star(colour, number, galaxy));\n }\n setStarNeighbours(galaxy, stars);\n }\n setGalaxyNeighbours(galaxies, jarray);\n } catch (FileNotFoundException fnf) {\n System.out.println(\"File not found\");\n } catch (IOException ieo) {\n System.out.println(\"Could not read file.\");\n }\n return galaxies;\n }", "public static ArrayList<Pets> sortArrayList(ArrayList<Pets> input){\n\t\t// destination ArrayList\n\t\tArrayList<Pets> sortedPets = new ArrayList<Pets>();\n\t\t\n\t\t// for each element read from the input list, compare it to the values in the destination list\n\t\t// and insert it.\n\t\tfor (int inputIndex = 0; inputIndex < input.size(); inputIndex++){\n\t\t\tint addIndex = 0;\n\t\t\tfor (int spIndex = 0; spIndex < sortedPets.size(); spIndex++) {\n\t\t\t\tif (input.get(inputIndex).getId() > sortedPets.get(spIndex).getId()) {\n\t\t\t\t\taddIndex++;\n\t\t\t\t} \n\t\t\t}\n\t\t\tsortedPets.add(addIndex, input.get(inputIndex));\n\t\t}\n\t\treturn sortedPets;\n\t}", "public ArrayList<ArrayList<Dog>> getVetSchedule() {\n\t\t\tint initialCapacity = 10;\r\n\t\t\tArrayList<ArrayList<Dog>> list = new ArrayList<ArrayList<Dog>>(initialCapacity); //list to put in lists of dogs\r\n\t\t\t//intialize ArrayList with size ArrayList\r\n\t\t\tlist.add(new ArrayList<Dog>());\r\n\t\t\t/*for(int i=0; i<=10; i++){\r\n\t\t\t\tlist.add(new ArrayList<Dog>());\r\n\t\t\t}\r\n\t\t\t*/\r\n\t\t\tDogShelterIterator iterator = new DogShelterIterator();\r\n\t\t\twhile(iterator.hasNext()){\r\n\t\t\t\tDog nextDog = iterator.next();\r\n\t\t\t\tint index = nextDog.getDaysToNextVetAppointment()/7;\r\n\t\t\t\tif(index < list.size())list.get(index).add(nextDog);\r\n\t\t\t\telse{\r\n\t\t\t\t\t//index out of range --> create larger list\r\n\t\t\t\t\tArrayList<ArrayList<Dog>> newList = new ArrayList<ArrayList<Dog>>(index+1);\r\n\t\t\t\t\tnewList.addAll(list); //add all lists from the old list\r\n\t\t\t\t\tfor(int i=0; i<(index+1)-list.size(); i++){ //initialize the other half with new ArrayLists\r\n\t\t\t\t\t\tnewList.add(new ArrayList<Dog>());\r\n\t\t\t\t\t}\r\n\t\t\t\t\tlist = newList; //update list to the larger newList\r\n\t\t\t\t\tlist.get(index).add(nextDog);\r\n\t\t\t\t}\r\n\t\t\t}\r\n return list;\r\n\t\t}", "public void loadItems() {\n\t\tArrayList<String> lines = readData();\n\t\tfor (int i = 1; i < lines.size(); i++) {\n\t\t\tString line = lines.get(i);\n\t\t\t\n\t\t\tString[] parts = line.split(\",\");\n\t\t\t\n//\t\t\tSystem.out.println(\"Name: \" + parts[0]);\n//\t\t\tSystem.out.println(\"Amount: \" + parts[1]);\n//\t\t\tSystem.out.println(\"Price: \" + parts[2]);\n//\t\t\tSystem.out.println(\"-------\");\n\t\t\t\n\t\t\tString name = parts[0].trim();\n\t\t\tint amount = Integer.parseInt(parts[1].trim());\n\t\t\tdouble price = Double.parseDouble(parts[2].trim());\n\t\t\t\n\t\t\tItem item = new Item(name, amount, price);\n\t\t\titemsInStock.add(item);\n\t\t}\n\t}", "public static void main(String[] args) {\n Dog[] dogPark={new Dog(),new Dog(),new Dog(),new Dog(),new Dog()};\n //0 1 2 3 4\n\n for (int i = 0; i <= dogPark.length-1 ; i++) {\n dogPark[i].getDogInfo();\n\n }\n System.out.println(\"====================================\");\n dogPark[0].setDogInfo(\"Karaoglan\", \"German Shepperd\", \"Medium\", 6, \"Black\");\n dogPark[1].setDogInfo(\"Red\", \"Golden\", \"Medium\", 4, \"Yellow\");\n dogPark[2].setDogInfo(\"Akbas\", \"Anatolian Sheppard\", \"Large\", 2, \"White\");\n dogPark[3].setDogInfo(\"mike\",\"Poodle\",\"Big\",8,\"brown\");\n dogPark[4].setDogInfo(\"Grizzly\",\"BoxerPitt\",\"Large\",3,\"Mix\");\n\n for (int i = 0; i <= dogPark.length-1 ; i++) {\n dogPark[i].getDogInfo();\n }\n\n System.out.println(\"=============================================================\");\n for (Dog eachdog:dogPark) {\n eachdog.getDogInfo();\n }\n\n System.out.println(\"=============================================================\");\n String food=\"treat\";\n for (Dog eachdog:dogPark) {\n eachdog.eat(food);\n }\n\n System.out.println(\"=============================================================\");\n String drink=\"milk\";\n for (Dog eachdog:dogPark) {\n eachdog.drink(drink);\n }\n\n\n System.out.println(\"=============================================================\");\n //play\n for (Dog eachdog:dogPark) {\n eachdog.sleep();\n }\n\n System.out.println(\"=============================================================\");\n //sleep\n for (Dog eachdog:dogPark) {\n eachdog.sleep();\n }\n }", "private void refreshPlayerList() {\n List<MarketItem> items = new ArrayList<>();\n EntityRef player = localPlayer.getCharacterEntity();\n for (int i = 0; i < inventoryManager.getNumSlots(player); i++) {\n EntityRef entity = inventoryManager.getItemInSlot(player, i);\n\n if (entity.getParentPrefab() != null) {\n MarketItem item;\n\n if (entity.hasComponent(BlockItemComponent.class)) {\n String itemName = entity.getComponent(BlockItemComponent.class).blockFamily.getURI().toString();\n item = marketItemRegistry.get(itemName, 1);\n } else {\n item = marketItemRegistry.get(entity.getParentPrefab().getName(), 1);\n }\n\n items.add(item);\n }\n }\n\n tradingScreen.setPlayerItems(items);\n }", "public void loadShoppingList(){\n try{\n //load the shopping list from the external file\n List<Ingredient> returnedList = Data.<Ingredient>loadList(shoppingListFile);\n if (returnedList != null){\n //convert list to an observableList\n shoppingListIngredients = FXCollections.observableList(returnedList);\n //set to the shopping list\n shoppingList.setItems(shoppingListIngredients);\n } else {\n System.out.println(\"No Shopping List Loaded \");\n }\n } catch (Exception e){\n System.out.println(\"Unable to load shopping list from file \" + shoppingListFile +\n \", the file may not exist\");\n e.printStackTrace();\n }\n }", "public LlistaPistes() {\n _llistaPistes = new ArrayList();\n }", "private void setItems()\n {\n sewers.setItem(rope); \n promenade.setItem(rope);\n bridge.setItem(potion);\n tower.setItem(potion);\n throneRoomEntrance.setItem(potion);\n depths.setItem(shovel);\n crypt.setItem(shovel);\n }", "public static void main(String[] args) {\n\t\tBufferedReader bufferedReader = new BufferedReader(new InputStreamReader(System.in));\n\t\t\n\t\tPets pet1 = new Pets(null, null, 0, null, null, 0);\n\t\tPets pet2 = new Pets(null, null, 0, null, null, 0);\n\t\tPets pet3 = new Pets(null, null, 0, null, null, 0);\n\t\tPets pet4 = new Pets(null, null, 0, null, null, 0);\n\t\tPets pet5 = new Pets(null, null, 0, null, null, 0);\n\t\tPets pet6 = new Pets(null, null, 0, null, null, 0);\n\t\tPets pet7 = new Pets(null, null, 0, null, null, 0);\n\t\tPets pet8 = new Pets(null, null, 0, null, null, 0);\n\t\tPets pet9 = new Pets(null, null, 0, null, null, 0);\n\t\tPets pet10 = new Pets(null, null, 0, null, null, 0);\n\t\t\n\t\tPets[] allPets = {pet1,pet2,pet3,pet4,pet5,pet6,pet7,pet8,pet9,pet10};\n\t\tint i = 0;\n\t\tfor (Pets individualPets : allPets) {\n\t\t\ti++;\n\t\t\tSystem.out.println(\"Enter the data for the \" + i + \" pet\");\n\t\t\ttry {\n\t\t\t\tSystem.out.println(\"Enter the name\");\n\t\t\t\tindividualPets.name = bufferedReader.readLine();\n\t\t\t\tSystem.out.println(\"Enter the type\");\n\t\t\t\tindividualPets.type = bufferedReader.readLine();\n\t\t\t\tSystem.out.println(\"Enter the age\");\n\t\t\t\tString age = bufferedReader.readLine();\n\t\t\t\tindividualPets.age = Integer.parseInt(age);\n\t\t\t\tSystem.out.println(\"Enter the gender\");\n\t\t\t\tindividualPets.gender = bufferedReader.readLine();\n\t\t\t\tSystem.out.println(\"Enter the color\");\n\t\t\t\tindividualPets.color = bufferedReader.readLine();\n\t\t\t\tSystem.out.println(\"Enter the size\");\n\t\t\t\tString size = bufferedReader.readLine();\n\t\t\t\tindividualPets.size = Integer.parseInt(size);\n\t\t\t} \n\t\t\t\tcatch(IOException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tfor (Pets individualPets : allPets) {\n\t\t\tSystem.out.println(\"-------------------\");\n\t\t\tSystem.out.println(\"name: \" + individualPets.name);\n\t\t\tSystem.out.println(\"type:\" + individualPets.type);\n\t\t\tSystem.out.println(\"age:\" + individualPets.age);\n\t\t\tSystem.out.println(\"gender:\" + individualPets.gender);\n\t\t\tSystem.out.println(\"color:\" + individualPets.color);\n\t\t\tSystem.out.println(\"size:\" + individualPets.size);\n\t\t}\n\t}", "static void addNewPieces() {\n ArrayList<Block> news = new ArrayList<>();\n news.add(new Block(new int[]{2, 3}, Tetrominos.I));\n news.add(new Block(new int[]{2, 3}, Tetrominos.J));\n news.add(new Block(new int[]{2, 3}, Tetrominos.L));\n news.add(new Block(new int[]{2, 3}, Tetrominos.O));\n news.add(new Block(new int[]{2, 3}, Tetrominos.S));\n news.add(new Block(new int[]{2, 3}, Tetrominos.T));\n news.add(new Block(new int[]{2, 3}, Tetrominos.Z));\n\n\n Collections.shuffle(news);\n newPiece.addAll(news);\n }", "public void fillPassengersOnPlane(){//private, ändrar till public för grafiska\r\n //int i = 0;\r\n //for (Passenger p : passengers) {//fel med foreach tror jag\r\n for(int i = 0; i < 10; i++){\r\n if (passengers.size() >= 10) {\r\n passengers.get(i).setFirstName(\"Passenger\");//p\r\n passengers.get(i).setLastName(\"Unnamed\" + i);\r\n passengers.get(i).setAge(35 + i);\r\n passengers.get(i).setDestination(getDestination());\r\n passengers.get(i).setSeatNr(i + 1);\r\n if (i < 5) {\r\n passengers.get(i).setTicketPrice(21500);\r\n } else {\r\n passengers.get(i).setTicketPrice(5300);\r\n }\r\n if (seats.size() >= 10) {\r\n seats.get(i).setBooked(true);\r\n seats.get(i).setSeatNumber(i + 1);\r\n seats.get(i).setPassenger(passengers.get(i)); \r\n } else {\r\n seats.add(i, new Seat(i + 1, passengers.get(i)));\r\n }\r\n }\r\n else {\r\n Passenger nyP = new Passenger();\r\n nyP.setFirstName(\"Passenger\");//p\r\n nyP.setLastName(\"Unnamed\" + i);\r\n nyP.setAge(35 + i);\r\n nyP.setDestination(getDestination());\r\n nyP.setSeatNr(i + 1);\r\n if (i < 5) {\r\n nyP.setTicketPrice(21500);\r\n } else {\r\n nyP.setTicketPrice(5300);\r\n }\r\n passengers.add(nyP);\r\n \r\n if (seats.size() >= 10) {\r\n seats.get(i).setBooked(true);\r\n seats.get(i).setSeatNumber(i + 1);\r\n seats.get(i).setPassenger(nyP); \r\n } else {\r\n seats.add(i, new Seat(i + 1, nyP));\r\n }\r\n } \r\n }\r\n }", "public void generateVehicles(JSONObject resp) throws JSONException {\n birds = new ArrayList<Vehicle>();\n JSONArray items = resp.getJSONArray(\"birds\");\n double lat = 0;\n double lng = 0;\n String id = \"\";\n int bat = 0;\n System.out.println(items.toString());\n System.out.println(\"parsing.....\");\n for(int i=0;i<items.length();++i){\n JSONObject current = (JSONObject) items.get(i);\n //Vehicle(String vendor,String id, int battery, double lat, double lng, double startPrice, double minutePrice)\n //birds.add(new Vehicle(\"bird\",items.get(i).getString(\"id\");\n if(current.getString(\"captive\").equals(\"false\")) {\n JSONObject loc = current.getJSONObject(\"location\");\n lat = loc.getDouble(\"latitude\");\n lng = loc.getDouble(\"longitude\");\n bat = Integer.parseInt(current.getString(\"battery_level\"));\n id = current.getString(\"id\");\n\n Vehicle veh = new Vehicle(\"bird\",id,bat,lat,lng,\"$1 to unlock $0.27 / 1 min\");\n veh.setType(\"scooter\");\n System.out.print(veh);\n\n birds.add(veh);\n }\n }\n/* for(int i=0;i<birds.size();++i){\n System.out.println(birds.get(i));\n }\n */\n\n }", "public void parsePopulation(ArrayList<Entity> players){\n for (int i = 0; i < players.size(); i++) {\n players.get(i).getComponent(PlayerComponent.class).setStudent(students.get(i));\n students.get(i).setPlayer(players.get(i));\n students.get(i).setIdNum(i);\n }\n }", "private void initializeData() {\n ListaOfertas.removeAll(ListaOfertas);\n for(Articulo listaJuegos: ArticuloRepository.getListArticulo()){\n if(listaJuegos.getOferta().contains(\"S\")){\n listaJuegos.setValorDescuento(String.valueOf(listaJuegos.getPrecioArticulo()-(listaJuegos.getPrecioArticulo()*listaJuegos.getPorcentajeDescuento()/100)));\n ListaOfertas.add(listaJuegos);\n }\n\n }\n }", "@Override\r\n\tpublic List<Pit> generatePitsFilledWithStones() {\r\n\r\n\t\tList<Pit> pitList = Collections.synchronizedList(new ArrayList<Pit>());\r\n\r\n\t\tint iCurrentIndex = 1;\r\n\r\n\t\tint iTotalNumberOfPits = GameSettings.NUMBER_OF_PITS_PER_PLAYER * 2 + 2;\r\n\r\n\t\tfor (int i = 0; i < iTotalNumberOfPits; i++) {\r\n\r\n\t\t\tPit pit = new Pit(iCurrentIndex++);\r\n\r\n\t\t\tif (!pit.isKalah()) {\r\n\r\n\t\t\t\tfor (int j = 0; j < GameSettings.NUMBER_OF_STONES_PER_PIT; j++) {\r\n\r\n\t\t\t\t\tpit.addStone(new Stone());\r\n\r\n\t\t\t\t}\r\n\r\n\t\t\t}\r\n\r\n\t\t\tpitList.add(pit);\r\n\r\n\t\t}\r\n\r\n\t\treturn pitList;\r\n\r\n\t}", "protected void newPlayerList() {\n int len = getPlayerCount();\n mPlayerStartList = new PlayerStart[ len ];\n for(int i = 0; i < len; i++) {\n mPlayerStartList[i] = new PlayerStart( 0.f, 0.f );\n }\n }", "List<SimpleInventory> getInventories();", "public void setAllPokemon()\n {\n PokemonFactory pFactory = new PokemonFactory();\n this.allPokemon = pFactory.getRandomPokemon();\n\n }", "public void populateDeck(){\n\n //Add everything to r\n for(int i=0;i<LUMBER;i++){\n deck.add(new ResourceCard(container, Resource.WOOD, cardStartPoint));\n }\n\n for(int i=0;i<WOOL;i++){\n deck.add(new ResourceCard(container, Resource.WOOL, cardStartPoint));\n }\n\n for(int i=0;i<GRAIN;i++){\n deck.add(new ResourceCard(container, Resource.WHEAT, cardStartPoint));\n }\n\n for(int i=0;i<BRICK;i++){\n deck.add(new ResourceCard(container, Resource.BRICKS, cardStartPoint));\n }\n\n for(int i=0;i<ORE;i++){\n deck.add(new ResourceCard(container, Resource.ORE, cardStartPoint));\n }\n //Collections.shuffle(deck);\n\n }", "java.util.List<WorldUps.UGoPickup> \n getPickupsList();", "static void examine( List pets){\n\t\tSystem.out.println(\"Your pets need urgent attention.\");\n\t}", "private void getArbeitspaketArray(ObservableList<ArbeitspaketTableData> paketList) {\r\n\t\t// Initialisieren des Arrays\r\n\t\tpakete = new Arbeitspaket[paketList.size()];\r\n\r\n\t\tfor (int i = 0; i < paketList.size(); i++) {\r\n\t\t\t// herauslesen der externen ID, damit diese nicht verloren geht (Konstruktor\r\n\t\t\t// nimmt nur einen Parameter für die ID entgegen und setzt die interne und\r\n\t\t\t// externe ID auf diesen Wert)\r\n\t\t\tString idExtern = paketList.get(i).getIdExtern();\r\n\r\n\t\t\t// automatisches Setzen der Vorgangsdauer, da diese in der Tabelle nicht\r\n\t\t\t// angegeben wird\r\n\t\t\tint vorgangsdauer = paketList.get(i).getFez() - paketList.get(i).getFaz() + 1;\r\n\r\n\t\t\t// setzen der einzelnen Werte der Arbeitspakte\r\n\t\t\tpakete[i] = new Arbeitspaket(paketList.get(i).getIdIntern(), paketList.get(i).getFaz(),\r\n\t\t\t\t\tpaketList.get(i).getFez(), paketList.get(i).getSaz(), paketList.get(i).getSez(), vorgangsdauer,\r\n\t\t\t\t\tpaketList.get(i).getMitarbeiteranzahl(), paketList.get(i).getAufwand());\r\n\r\n\t\t\t// Da die externe ID auf die interne ID gesetzt wurde, wird diese nun wieder auf\r\n\t\t\t// die vorher herausgelesene externe ID gesetzt\r\n\t\t\tpakete[i].setIdExtern(idExtern);\r\n\t\t}\r\n\t}" ]
[ "0.74788165", "0.7128553", "0.65034795", "0.636627", "0.62166476", "0.6179287", "0.6138471", "0.609317", "0.60631937", "0.6042638", "0.60393554", "0.5948945", "0.5914461", "0.5879932", "0.5864538", "0.58525515", "0.58516824", "0.58449626", "0.5781633", "0.5771727", "0.5736889", "0.5724716", "0.5723902", "0.5717694", "0.5686475", "0.5673995", "0.5658963", "0.56588155", "0.56506956", "0.5647451", "0.563164", "0.5619268", "0.56127757", "0.55801255", "0.55745953", "0.5545966", "0.55304086", "0.55259347", "0.5524301", "0.55148125", "0.5510772", "0.5503562", "0.55002487", "0.549954", "0.54841673", "0.54808915", "0.54768467", "0.5459519", "0.5448135", "0.5446735", "0.54449356", "0.5436393", "0.5421183", "0.54209995", "0.5403745", "0.53974175", "0.5391266", "0.53904754", "0.5388823", "0.53884447", "0.53868735", "0.5382446", "0.53763825", "0.5356107", "0.5354615", "0.5349067", "0.5348581", "0.5322012", "0.53209305", "0.53198475", "0.53107095", "0.53080106", "0.5305499", "0.5304618", "0.5292495", "0.5291706", "0.5291277", "0.528544", "0.527969", "0.52796596", "0.52787083", "0.52776176", "0.52697194", "0.5267859", "0.5259557", "0.5254897", "0.52516305", "0.5248888", "0.5246744", "0.52441883", "0.52409774", "0.52374756", "0.52323294", "0.5229388", "0.52275956", "0.5226531", "0.5226292", "0.522591", "0.5217788", "0.52132696" ]
0.7526413
0
Keeps Trying for a value between two options.
public int getNumber(int ln, int hn){ System.out.println("Please Enter A Number Between " + ln + " and " + hn); int num = sc.nextInt(); if(num > ln && num < hn){ return num; }else{ while(num < ln || num > hn){ System.out.println("Number was not between " + ln + " and " + hn); System.out.println("Please Enter A Number Between " + ln + " and " + hn); num = sc.nextInt(); } return num; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private int correctOption(final String options, final int lastOption) {\n\n// Take int value by user thorough command line\n int option;\n\n// Count the iterations of while loop and show the options again to the user if user has chosen wrong option.\n int loop = 0;\n\n while (true) {\n\n System.out.println(options);\n option = scanner.nextInt();\n\n// If the input is in between the range specified, just break the loop and return the value\n if (option <= lastOption && option > 0)\n break;\n\n// If the attempts exceed close the resources and return -1 value which will close the program\n if (loop >= 2) {\n option = -1;\n break;\n } else\n System.err.println(\"\\nPlease select correct option\");\n\n loop++;\n }\n return option;\n }", "private void checkSelectedValue(Value value) {\n\t\tconflictingAssignmentId = -1;\r\n\t\tconflictingValue = null;\r\n\t\tDimension rootDimension = value.getRootDimension();\r\n\t\tfor (int i = 0; i < query.getAssignments().size(); i++) {\r\n\t\t\tAssignmentProxy assignment = query.getAssignments().get(i);\r\n\t\t\tValue assignmentValue = ContextProxyManager.getInstance()\r\n\t\t\t\t\t.getProxy().findValue(assignment.getValueURI());\r\n\t\t\tif (assignmentValue.getRootDimension().equals(rootDimension)) {\r\n\t\t\t\tconflictingAssignmentId = i;\r\n\t\t\t\tconflictingValue = assignmentValue;\r\n\t\t\t\tpendingValue = value;\r\n\t\t\t\tconflictingRootDimension = rootDimension;\r\n\t\t\t\tshowDialog(DIALOG_REPLACE_ASSIGNMENT);\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tAssignmentProxy assignment = new AssignmentProxy(value.getURI());\r\n\t\tassignmentAdded(assignment);\r\n\t}", "public void setFromValue (double fromValue){\n firstValue = fromValue;\n }", "boolean updateValue() {\n boolean ret;\n\n if (Math.abs(curUtilityValue - nextUtilityValue) < Math.abs(curUtilityValue) * MAX_ERR_PERCENT / 100)\n ret = true;\n else {\n ret = false;\n // System.out.println(\" no match cell: x: \"+x+\" y: \"+y);\n }\n curUtilityValue = nextUtilityValue;\n return ret;\n\n }", "public boolean test_entry() {\n\t\tboolean t = false;\n\t\tdouble val = Double.parseDouble(numericfield.getText());\n\n\t\tif (val == opt) {\n\t\t\tt = true;\n\t\t\tJOptionPane.showMessageDialog(null,\n\t\t\t\t\t\"Vous avez trouvé le bon parametre pour ce remede\");\n\t\t}\n\t\t// case init > opt ---> on doit diminuer la valeur !!!!\n\t\tif (init > opt) {\n\t\t\tif (init > val && val > opt)\n\t\t\t\tJOptionPane.showMessageDialog(null,\n\t\t\t\t\t\t\"Vous allez dans le bon sens , continuez\");\n\t\t\tif (init > val && opt > val)\n\t\t\t\tJOptionPane\n\t\t\t\t\t\t.showMessageDialog(null,\n\t\t\t\t\t\t\t\t\" Vous avez raté le parametre optimale et vous allez dans le mauvais sens\");\n\t\t\tif (val > init)\n\t\t\t\tJOptionPane.showMessageDialog(null,\n\t\t\t\t\t\t\" Vous allez dans le mauvais sens\");\n\t\t}\n\n\t\t// case init < opt ---> on doit augmenter la valeur !!!!\n\t\tif (init < opt) {\n\t\t\tif (init < val && val < opt)\n\t\t\t\tJOptionPane.showMessageDialog(null,\n\t\t\t\t\t\t\"Vous allez dans le bon sens , continuez\");\n\t\t\tif (init < val && opt < val)\n\t\t\t\tJOptionPane\n\t\t\t\t\t\t.showMessageDialog(null,\n\t\t\t\t\t\t\t\t\" Vous avez raté le parametre optimale et vous allez dans le mauvais sens\");\n\t\t\tif (val < init)\n\t\t\t\tJOptionPane.showMessageDialog(null,\n\t\t\t\t\t\t\" Vous allez dans le mauvais sens\");\n\t\t}\n\t\treturn t;\n\t}", "private void pickTime() {\n System.out.println(\"what time would you like to reserve?\");\n boolean keepgoing = true;\n int time;\n while (keepgoing) {\n time = input.nextInt();\n if (time < 0 || time > 23) {\n System.out.println(\"Invalid time, try again.\");\n } else {\n pickedtime = time;\n keepgoing = false;\n }\n }\n }", "private boolean isParamValueConflicted(int paramIndex, int offset, int value)\n {\n boolean ret = false;\n\n if (constantAkParamsDefined_)\n {\n if (paramIndex == getAkParamIndex(\"genb\") && value != akParam_genb_)\n {\n Log.e(LOG_TAG, \"genb = \" + value + \" conflicts with the predefined value \" + akParam_genb_);\n ret = true;\n }\n else if (paramIndex == getAkParamIndex(\"ienb\") && value != akParam_ienb_)\n {\n Log.e(LOG_TAG, \"ienb = \" + value + \" conflicts with the predefined value \" + akParam_ienb_);\n ret = true;\n }\n else if (paramIndex == getAkParamIndex(\"aonb\") && value != akParam_aonb_)\n {\n Log.e(LOG_TAG, \"aonb = \" + value + \" conflicts with the predefined value \" + akParam_aonb_);\n ret = true;\n }\n else if (paramIndex == getAkParamIndex(\"arnb\") && value != akParam_aonb_)\n {\n Log.e(LOG_TAG, \"arnb = \" + value + \" conflicts with the predefined value \" + akParam_aonb_);\n ret = true;\n }\n else if (paramIndex == getAkParamIndex(\"aocc\") && value != AKPARAM_AOCC)\n {\n Log.e(LOG_TAG, \"aocc = \" + value + \" conflicts with the predefined value \" + AKPARAM_AOCC);\n ret = true;\n }\n }\n else\n {\n Log.e(LOG_TAG, \"Settable settings not defined yet\");\n ret = true;\n }\n\n return ret;\n }", "void addInconsistency(Integer optionId1, Integer optionId2) throws\n OptionInconsistencyImpossibleException;", "static private <T> boolean setIfDifferent(Channel<T> ch, T value) throws CAException, TimeoutException {\n if (!value.equals(ch.getFirst())) {\n ch.setValue(value);\n return true;\n } else {\n return false;\n }\n }", "public void setPricePerSquareFoot(double newPricePerSquareFoot){\nif(newPricePerSquareFoot > 0){\npricePerSquareFoot = newPricePerSquareFoot;\n}\n}", "private Conjunction(String newValue)\r\n\t{\r\n\t\tthis.value = newValue;\r\n\t}", "@Override\n\tprotected boolean isUserWishToKeepChanges() {\n\t\tString newValue = convertPairsToText().replace(\" \", \"\");\n\t\tString oldValue = result.get().replace(\" \", \"\");\n\t\t\n\t\tif(oldValue.equals(newValue))\n\t\t\treturn false;\n\t\t\n\t\treturn not(showConfirmActionDialog());\n\t}", "private double correctToRange(double value, double min, double max) {\r\n\t\t// If the value is below the range, set it equal to the minimum.\r\n\t\tif (value < min) {\r\n\t\t\treturn min;\r\n\t\t\t// If it is above the range, set it equal to the maximum.\r\n\t\t} else if (value > max) {\r\n\t\t\treturn max;\r\n\t\t}\r\n\t\t// Otherwise, it is in-range and no adjustments are needed.\r\n\t\treturn value;\r\n\t}", "private static Option chooseWinner(Option op1, Option op2) {\n\t\tif(op1 == op2) {\n\t\t\treturn null;\n\t\t}else if(op1 == Option.ROCK) {\n\t\t\tif(op2 == Option.PAPER) {\n\t\t\t\treturn Option.PAPER;\n\t\t\t}\n\t\t\treturn Option.ROCK;\n\t\t}else if(op1 == Option.SCISSORS) {\n\t\t\tif(op2 == Option.ROCK) {\n\t\t\t\treturn Option.ROCK;\n\t\t\t}\n\t\t\treturn Option.SCISSORS;\n\t\t}else if(op1 == Option.PAPER) {\n\t\t\tif(op2 == Option.SCISSORS) {\n\t\t\t\treturn Option.SCISSORS;\n\t\t\t}\n\t\t\treturn Option.PAPER;\n\t\t}\n\t\treturn null;\n\t}", "public int chooseDirection(){\n int direction;\n do{\n Scanner scanner = new Scanner(System.in);\n System.out.println(\"Choose a transfer method.\\n(1) from saving to checking.\\n(2) from checking to saving.\");\n direction = scanner.nextInt();\n } while(!(direction !=1 || direction !=2));\n return direction;\n }", "void removeInconsistency(Integer optionId1, Integer optionId2);", "private boolean isValidOption(int option){\n return (option >= 0) && (option < this.count());\n }", "private boolean caculate(double currentValue, double lastValue, NotifyStrategy.Expression expr,\n Map<String, Object> judgeResult) {\n\n double diff = currentValue - lastValue;\n double upperLimit = 0;\n String upperLimitString = expr.getUpperLimit();\n\n // get upperLimit\n if (upperLimitString.contains(\"#\")) {\n upperLimit = Double.parseDouble(upperLimitString.substring(upperLimitString.indexOf('#') + 1));\n }\n else if (upperLimitString.contains(\"%\")) {\n upperLimit = Double.parseDouble(upperLimitString.substring(0, upperLimitString.indexOf('%')));\n diff = diff * 100 / lastValue;\n }\n else if (!upperLimitString.contains(\"*\")) {\n upperLimit = Double.parseDouble(upperLimitString);\n }\n\n if (!upperLimitString.contains(\"*\") && diff > upperLimit) {\n judgeResult.put(\"actualValue\", String.format(\"%.2f\", diff) + (upperLimitString.contains(\"%\") ? \"%\" : \"\"));\n judgeResult.put(\"expectedValue\", upperLimitString);\n judgeResult.put(\"upperORlower\", \"upper\");\n\n return true;\n }\n\n diff = currentValue - lastValue;\n double lowerLimit = 0;\n String lowerLimitString = expr.getLowerLimit();\n\n // get lowerLimit\n if (lowerLimitString.contains(\"#\")) {\n lowerLimit = 0 - Double.parseDouble(lowerLimitString.substring(lowerLimitString.indexOf('#') + 1));\n }\n else if (lowerLimitString.contains(\"%\")) {\n lowerLimit = Double.parseDouble(lowerLimitString.substring(0, lowerLimitString.indexOf('%')));\n diff = diff * 100 / lastValue;\n }\n else if (!lowerLimitString.contains(\"*\")) {\n lowerLimit = Double.parseDouble(lowerLimitString);\n }\n\n if (!lowerLimitString.contains(\"*\") && diff < 0 - lowerLimit) {\n judgeResult.put(\"actualValue\", String.format(\"%.2f\", diff) + (lowerLimitString.contains(\"%\") ? \"%\" : \"\"));\n judgeResult.put(\"expectedValue\", lowerLimitString);\n judgeResult.put(\"upperORlower\", \"lower\");\n\n return true;\n }\n\n return false;\n }", "public void setBothValue(String value) {\r\n\t\ttxtPassword.setValue(value);\r\n\t\ttxtRetypePassword.setValue(value);\r\n\t}", "public void checkBestScoreAndChangeIt() {\n \tbestTime = readPreference(difficulty);\n \t\n \tif (currentTime < bestTime) {\n \t\tbestTime = currentTime;\n \t\tsavePreference(bestTime, difficulty);\n \t}\n }", "abstract public Decision askKeepOrLiquidate(int fundValue, int timespan);", "private static <T> T choose(T opt1, T opt2) {\n\t\tint choice = randInt(1, 2);\n\t\tswitch (choice) {\n\t\tcase 1:\n\t\t\treturn opt1;\n\t\tcase 2:\n\t\t\treturn opt2;\n\t\tdefault:\n\t\t\tSystem.err.println(\"Error: Invalid choice: \" + choice);\n\t\t\treturn null;\n\t\t}\n\t}", "public void brake(double amount){\n if(acceptedValueRange(amount)){\n decrementSpeed(Math.abs(amount));\n }\n }", "protected final boolean toIsDefault() {\n return to < 0;\n }", "private void pickDuration() {\n boolean keepgoing;\n System.out.println(\"for how long?\");\n keepgoing = true;\n while (keepgoing) {\n int temp = input.nextInt();\n if (temp <= 0 || temp + pickedtime >= 24) {\n System.out.println(\"Invalid duration\");\n } else {\n pickedduration = temp;\n keepgoing = false;\n }\n }\n }", "public static ChangeResults changeOption(WebElement dropDownElement, DropDown future,\n\t\t\tString sDefaultVisible, String sDefaultValue, String sDefaultIndex)\n\t{\n\t\t// Index of drop down option to switch to\n\t\tint nIndex;\n\n\t\tDropDown current = future.copy();\n\n\t\t/*\n\t\t * Need to update the option.\n\t\t * \n\t\t * NOTE: If future.using is purposely set to an invalid option, then current.option will not be\n\t\t * updated. This means that both the current & future drop downs will match which could cause the\n\t\t * results to be invalid\n\t\t */\n\t\tif (future.using == Selection.Index)\n\t\t\tcurrent.option = String.valueOf(Framework.getSelectedIndex(dropDownElement));\n\n\t\tif (future.using == Selection.VisibleText)\n\t\t\tcurrent.option = Conversion.nonNull(Framework.getSelectedOption(dropDownElement));\n\n\t\tif (future.using == Selection.RegEx)\n\t\t{\n\t\t\t// Get the exact drop down option selected (visible text)\n\t\t\tcurrent.option = Conversion.nonNull(Framework.getSelectedOption(dropDownElement));\n\n\t\t\t/*\n\t\t\t * If the current selection matches the future selection, then make current = future by updating\n\t\t\t * current.option\n\t\t\t */\n\t\t\tif (current.option.matches(future.option))\n\t\t\t\tcurrent.option = future.option;\n\t\t}\n\n\t\tif (future.using == Selection.ValueHTML)\n\t\t\tcurrent.option = String.valueOf(Framework.getSelectedValue(dropDownElement));\n\n\t\t/*\n\t\t * If the current selection equals the future selection, then we need to switch to a different option.\n\t\t */\n\t\tif (current.equals(future))\n\t\t{\n\t\t\t// Value should always be greater than 0 but just in case log a warning for troubleshooting\n\t\t\tint nDefaultIndex = Conversion.parseInt(sDefaultIndex);\n\t\t\tif (nDefaultIndex < 0)\n\t\t\t\tLogs.log.warn(\"Default Index could not be parsed to an integer\");\n\n\t\t\t// Can we use the default index to switch to?\n\t\t\tif (DropDown.isDefault(future, sDefaultVisible, sDefaultValue, sDefaultIndex))\n\t\t\t{\n\t\t\t\t/*\n\t\t\t\t * Future index is the default. So, we will choose a different index\n\t\t\t\t * \n\t\t\t\t * Notes:\n\t\t\t\t * 1) This assumes that there are at least 2 options\n\t\t\t\t * 2) If sDefaultIndex cannot be parsed, then it is assumed that index 0 is fine\n\t\t\t\t */\n\t\t\t\tif (nDefaultIndex == 0)\n\t\t\t\t\tnIndex = 1;\n\t\t\t\telse\n\t\t\t\t\tnIndex = 0;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// Future Index is not the default. So, we can choose this index\n\t\t\t\tnIndex = nDefaultIndex;\n\t\t\t}\n\n\t\t\treturn new ChangeResults(true, nIndex);\n\t\t}\n\n\t\treturn new ChangeResults(false, 0);\n\t}", "private static double Optimo(double valor1, double valor2, String metodo) {\n if (metodo.equals(\"Min\")) {\n return Math.min(valor1, valor2);\n } else {\n return Math.max(valor1, valor2);\n }\n }", "public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n System.out.println(\"Do you want food or drink? \");\n System.out.println(\"If your answer is food you want meal or snack? \");\n System.out.println(\"If your answer is drink you want soda or juice? \");\n String mainOption= scan.next();\n String secondaryOption = scan.next();\n\n if(mainOption.equalsIgnoreCase(\"food\")){\n System.out.println(\"You have selected food\");\n if(secondaryOption.equalsIgnoreCase(\"meal\")){\n System.out.println(\"You have selected meal\");\n }else if (secondaryOption.equalsIgnoreCase(\"snack\")) {\n System.out.println(\"You have selected snack\");\n }else if(mainOption.equalsIgnoreCase(\"drink\")){\n System.out.println(\"You have selected drink\");\n }else if(secondaryOption.equalsIgnoreCase(\"soda\")) {\n System.out.println(\"You have selected soda\");\n }else if(secondaryOption.equalsIgnoreCase(\"juice\")) {\n System.out.println(\"You have selected juice\");\n\n }\n\n }\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n }", "private void updatePickupValue(WxValue wxValue) {\n this.parm.getParmState().setPickUpValue(wxValue);\n process();\n }", "boolean isOptionsConsistentIncludingAllRequired(Integer optionId1,\n Integer optionId2);", "private void updateValue() {\n int minValue = 100; //Minimum value to be calculated, initialized to a large number\n value = 0; //Value reinitialized to 0\n for (Integer i : values) {\n if (i > value && i <= 21) {\n value = i; //Sets value to maximum value less than or equal to 21\n }\n if (i < minValue) {\n minValue = i; //Sets minimum value to lowest value in the list\n }\n }\n if (value == 0) {\n value = minValue; //Sets value to minValue if no values 21 or less\n }\n valueLabel.setText(\"Value: \" + value); //Sets text of value label\n if (value > 21) {\n bust(); //Busts if value greater than 21\n }\n }", "@Test\n\tpublic void testOptionsValid(){\n\t\t// TEST 1\n\t\tGameTypeOptions.TrumpSuit trump = GameTypeOptions.TrumpSuit.Clubs;\n\t\tGameTypeOptions.SkatHandType skathandType = GameTypeOptions.SkatHandType.Skat;\n\t\tGameTypeOptions.GameType actualGameType = GameTypeOptions.GameType.Suit;\n\t\tboolean ouvert = true;\n\t\tboolean schwarz = false;\n\t\tboolean schneider = true;\t\n\t\t// Create our GameType.\n\t\tGameTypeOptions gameType = new GameTypeOptions(skathandType, actualGameType, trump, ouvert, schneider, schwarz);\n\t\t\n\t\t// Assert our options.\n\t\tassertEquals(\"Invalid Trump Suit set in GameTypeOptions, should be \" + trump + \" got \" + gameType.getTrumpSuit(), trump, gameType.getTrumpSuit());\n\t\tassertEquals(\"Invalid Skat Hand Type set in GameTypeOptions, should be \" + skathandType + \" got \" + gameType.getHandType(), skathandType, gameType.getHandType());\n\t\tassertEquals(\"Invalid GameType set in GameTypeOptions, should be \" + actualGameType + \" got \" + gameType.getGameType(), actualGameType, gameType.getGameType());\n\t\tassertEquals(\"Invalid ouvert status in GameTypeOptions, should be \" + ouvert + \" got \" + gameType.getOuvert(), ouvert, gameType.getOuvert());\n\t\tassertEquals(\"Invalid schwarz status in GameTypeOptions, should be \" + schwarz + \" got \" + gameType.getSchwarz(), schwarz, gameType.getSchwarz());\n\t\tassertEquals(\"Invalid schneider status in GameTypeOptions, should be \" + schneider + \" got \" + gameType.getSchneider(), schneider, gameType.getSchneider());\n\t\t\n\t\t// TEST 2\n\t\ttrump = GameTypeOptions.TrumpSuit.None;\n\t\tskathandType = GameTypeOptions.SkatHandType.Hand;\n\t\tactualGameType = GameTypeOptions.GameType.Null;\n\t\touvert = true;\n\t\tschwarz = false;\n\t\tschneider = false;\t\n\t\t// Create our GameType.\n\t\tgameType = new GameTypeOptions(skathandType, actualGameType, trump, ouvert, schneider, schwarz);\n\t\t\n\t\t// Assert our options.\n\t\tassertEquals(\"Invalid Trump Suit set in GameTypeOptions, should be \" + trump + \" got \" + gameType.getTrumpSuit(), trump, gameType.getTrumpSuit());\n\t\tassertEquals(\"Invalid Skat Hand Type set in GameTypeOptions, should be \" + skathandType + \" got \" + gameType.getHandType(), skathandType, gameType.getHandType());\n\t\tassertEquals(\"Invalid GameType set in GameTypeOptions, should be \" + actualGameType + \" got \" + gameType.getGameType(), actualGameType, gameType.getGameType());\n\t\tassertEquals(\"Invalid ouvert status in GameTypeOptions, should be \" + ouvert + \" got \" + gameType.getOuvert(), ouvert, gameType.getOuvert());\n\t\tassertEquals(\"Invalid schwarz status in GameTypeOptions, should be \" + schwarz + \" got \" + gameType.getSchwarz(), schwarz, gameType.getSchwarz());\n\t\tassertEquals(\"Invalid schneider status in GameTypeOptions, should be \" + schneider + \" got \" + gameType.getSchneider(), schneider, gameType.getSchneider());\n\t\t\n\t\t// TEST 3\n\t\ttrump = GameTypeOptions.TrumpSuit.None;\n\t\tskathandType = GameTypeOptions.SkatHandType.Hand;\n\t\tactualGameType = GameTypeOptions.GameType.Grand;\n\t\touvert = false;\n\t\tschwarz = false;\n\t\tschneider = false;\t\n\t\t// Create our GameType.\n\t\tgameType = new GameTypeOptions(skathandType, actualGameType, trump, ouvert, schneider, schwarz);\n\t\t\n\t\t// Assert our options.\n\t\tassertEquals(\"Invalid Trump Suit set in GameTypeOptions, should be \" + trump + \" got \" + gameType.getTrumpSuit(), trump, gameType.getTrumpSuit());\n\t\tassertEquals(\"Invalid Skat Hand Type set in GameTypeOptions, should be \" + skathandType + \" got \" + gameType.getHandType(), skathandType, gameType.getHandType());\n\t\tassertEquals(\"Invalid GameType set in GameTypeOptions, should be \" + actualGameType + \" got \" + gameType.getGameType(), actualGameType, gameType.getGameType());\n\t\tassertEquals(\"Invalid ouvert status in GameTypeOptions, should be \" + ouvert + \" got \" + gameType.getOuvert(), ouvert, gameType.getOuvert());\n\t\tassertEquals(\"Invalid schwarz status in GameTypeOptions, should be \" + schwarz + \" got \" + gameType.getSchwarz(), schwarz, gameType.getSchwarz());\n\t\tassertEquals(\"Invalid schneider status in GameTypeOptions, should be \" + schneider + \" got \" + gameType.getSchneider(), schneider, gameType.getSchneider());\n\t\t\n\t}", "synchronized void reset() {\n\n // no change if called before getValue() or called twice\n lastValue = currValue = startValue;\n }", "private static char availabilityOrGoBack() {\n Scanner input = new Scanner(System.in);\n\n System.out.print(\"Enter (a)vailability, or \"\n\t + \"(b)ack to go back: \");\n char option = input.next().toLowerCase().charAt(0);\n\n return option;\n }", "public String verifyDropdownLastValue(String object, String data) {\n\t\tlogger.debug(\"Entered into verifyDropdownLastValue()\");\n\t\ttry {\n\t\t\tWebElement select = wait.until(explicitWaitForElement(By.xpath(OR.getProperty(object))));\n\t\t\tSelect sel = new Select(select);\n\t\t\tList<WebElement> l1 = sel.getOptions();\n\t\t\tint lastvalue = Integer.parseInt(sel.getFirstSelectedOption().getText());\n\t\t\tlogger.debug(lastvalue);\n\t\t\tif (lastvalue == l1.size()) {\n\t\t\t\treturn Constants.KEYWORD_PASS + \" -- Last value attained\";\n\t\t\t} else {\n\t\t\t\treturn Constants.KEYWORD_FAIL + \" -- Last Value is not attained \";\n\t\t\t}\n\t\t} \n\t\tcatch(TimeoutException ex)\n\t\t\n\t\t{\n\t\t\treturn Constants.KEYWORD_FAIL +\"Cause: \"+ ex.getCause();\n\t\t}\n\t\tcatch (Exception e) {\n\t\t\n\t\t\treturn Constants.KEYWORD_FAIL + \" - Could not select from list. \" + e.getMessage();\n\t\t}\n\t}", "private int isFormValid() {\n Calendar start = new GregorianCalendar(datePicker1.year, datePicker1.month, datePicker1.day, timePicker1.hour, timePicker1.minute);\n Calendar end = new GregorianCalendar(datePicker2.year, datePicker2.month, datePicker2.day, timePicker2.hour, timePicker2.minute);\n if (end.before(start))\n return ERR_START_AFTER_END;\n Switch onOffSwitch = (Switch) findViewById(R.id.toggBtn);\n if (!onOffSwitch.isChecked()) {\n long seconds = (end.getTimeInMillis() - start.getTimeInMillis()) / 1000;\n if (seconds > SECONDS_IN_A_DAY)\n return ERR_START_AFTER_END;\n }\n return NO_ERR;\n }", "public void test_no_adjustment_basic() {\n // ## Arrange ##\n String expected = \"2008-12-14 12:34:56\";\n FromToOption option = createOption();\n\n // ## Act ##\n Date fromDate = option.filterFromDate(DfTypeUtil.toDate(expected));\n Date toDate = option.filterToDate(DfTypeUtil.toDate(expected));\n\n // ## Assert ##\n assertEquals(ConditionKey.CK_GREATER_EQUAL, option.getFromDateConditionKey());\n assertEquals(ConditionKey.CK_LESS_EQUAL, option.getToDateConditionKey());\n assertEquals(expected, DfTypeUtil.toString(fromDate, \"yyyy-MM-dd HH:mm:ss\"));\n assertEquals(expected, DfTypeUtil.toString(toDate, \"yyyy-MM-dd HH:mm:ss\"));\n }", "private void landOrTakeoff(String land_or_takeoff) {\n\t\ttry {\n\t\tthis.baggage = Integer.valueOf(land_or_takeoff);\n\t\tthis.isLanding = true;\n\t\t}catch(NumberFormatException e) {\n\t\t\tthis.isLanding = false;\n\t\t\tthis.destination = land_or_takeoff;\n\t\t}//catch\n\t}", "public void select ()\r\n \t\t{\r\n \t\t\tString sinput;\t\t\t\r\n \t\t\t\r\n \t\t\tdo {\r\n \t\t\t\tErrorLog.debug (\"Setting size: \" + getSize()); //Need to check if Short values\r\n \t\t\t\t//Can be passed in.\r\n \t\t\t\t\r\n \t\t\t\tprint (\"The current \" + name + \" is: \" + setting + type);\r\n \t\t\t\tprint (\"Would you like to change this? (\"+yes+\"/\"+no+\")\");\r\n \t\t\t\tsinput = read ();\r\n \t\t\t\t\r\n \t\t\t\tif (sinput.equalsIgnoreCase(yes)){\r\n \t\t\t\t\tprint (\"Please enter the \" + name + \" in \" + type);\r\n \t\t\t\t\tsinput = read ();\r\n \t\t\t\t\t\r\n \t\t\t\t\ttry {\r\n \t\t\t\t\t\tsetting = Short.parseShort(sinput);\r\n \t\t\t\t\t\tprint (name + \" changed.\");\r\n \t\t\t\t\t}\r\n \t\t\t\t\tcatch (NumberFormatException e){\t\t\t\t\t\r\n \t\t\t\t\t\tprint (\"That's not a valid number!\");\r\n \t\t\t\t\t}\t\t\t\t\t\r\n \t\t\t\t}\r\n \t\t\t\telse if (sinput.equalsIgnoreCase(no)){\r\n \t\t\t\t\tprint (\"Setting kept.\");\r\n \t\t\t\t\tbreak;\r\n \t\t\t\t}\r\n \t\t\t\telse {\r\n \t\t\t\t\tprint (\"That's not an option.\");\r\n \t\t\t\t}\r\n \t\t\t\t\r\n \t\t\t} while (true);\r\n \t\t}", "private Value chooseSuggestion(PermissionOutcome outcome) {\n Value suggestedValue;\n if (outcome.highestAcceptedValue != null) {\n suggestedValue = outcome.highestAcceptedValue;\n } else {\n try {\n suggestedValue = queue.peek();\n } catch (NoSuchElementException e) {\n suggestedValue = new Value();\n }\n }\n return suggestedValue;\n }", "private void menuOptionTwo(){\n int menuOption = printOptionsTwo();\n while(menuOption != 0){\n switch (menuOption){\n case 1:\n SimulatorFacade.printTransactions(\"Big A\");\n pressAnyKey();\n break;\n case 2:\n SimulatorFacade.printTransactions(\"Big B\");\n pressAnyKey();\n break;\n case 3:\n SimulatorFacade.printTransactions(\"Big C\");\n pressAnyKey();\n break;\n default:\n System.out.println(\"That's not a valid option. Please try again.\");\n break;\n }\n\n menuOption = printOptionsTwo();\n }\n }", "public BooleanChoiceCalculation(\n\t\t\tProp<Boolean> choice,\n\t\t\tProp<? extends V> first,\n\t\t\tProp<? extends V> second) {\n\t\t\n\t\tthis.choice = choice;\n\t\tthis.first = first;\n\t\tthis.second = second;\n\t\t\n\t\tIdentityHashSet<Changeable> sourcesM = new IdentityHashSet<Changeable>();\n\t\tsourcesM.add(choice);\n\t\tsourcesM.add(first);\n\t\tsourcesM.add(second);\n\t\tsources = Collections.unmodifiableSet(sourcesM);\n\t}", "private SettingsContainer valueChecker() {\n String generationCount = jTextFieldGenerationsCount.getText();\n String refreshTime = jTextFieldRefreshTime.getText();\n return checkSettingsFieldsValue(settingsContainer, jLabelCommunicats,\n generationCount, refreshTime);\n }", "protected void subtract() {\n\t\tfinal float previous = value;\n\t\tvalue = Math.max(min, value - incrementStep);\n\n\t\tif (value != previous) {\n\t\t\tupdateAndAlertListener();\n\t\t}\n\n\t\treturn;\n\t}", "private boolean checkPrevious(String id1, String id2, double[] distances) {\n boolean retVal;\n // Create a string pair.\n var pair = new StringPair(id1, id2);\n double[] oldDistances = this.oldResultMap.get(pair);\n if (oldDistances == null)\n retVal = false;\n else {\n // Copy the cached results to the provided result array.\n System.arraycopy(oldDistances, 0, distances, 0, distances.length);\n retVal = true;\n }\n return retVal;\n }", "private static double demandInput(String requestedValue) {\n\t\tString token = \"\";\n\n\t\twhile (true) {\n\t\t\tSystem.out.print(\"Unesite \" + requestedValue + \" > \");\n\t\t\ttoken = scan.next();\n\t\t\tif (checkInput(token) != ERROR) {\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\treturn checkInput(token);\n\t}", "@Override\n\tpublic void useSavedNumber(double num)\n\t{\n\t\tString[] options = {\"Solubility - before\", \"Solubility - after\", \"Pressure - before\", \"Pressure - after\"};\n\t\tString result = (String)JOptionPane.showInputDialog(panel, \"Choose where to use the number.\", \"Choose number\", JOptionPane.PLAIN_MESSAGE, null, \n\t\t\t\toptions, options[0]);\n\t\tif(result == null) return;\n\t\tif(result.equals(options[0])) solubility.setBeforeValue(num);\n\t\telse if(result.equals(options[1])) solubility.setAfterValue(num);\n\t\telse if(result.equals(options[2])) pressure.setBeforeValue(num);\n\t\telse pressure.setAfterValue(num);\n\t}", "public void setFromValue(double fromValue) {\n value = fromValue;\n }", "private void checkAndSet() {\n if (value == null) {\n throw new IllegalArgumentException(EXC_NodeCannotBeNull());\n }\n\n if (equalNodes(value, selectedNodes)) {\n return;\n }\n\n List<Node> validNodes = null;\n for (int i = 0; i < value.length; i++) {\n if (value[i] == null) {\n throw new IllegalArgumentException(EXC_NoElementOfNodeSelectionMayBeNull());\n }\n \n if (!isUnderRoot(value[i])) {\n if (validNodes == null) {\n validNodes = new ArrayList<Node>(value.length);\n for (int j = 0; j < i; j++) {\n validNodes.add(value[j]);\n }\n }\n } else if (validNodes != null) {\n validNodes.add(value[i]);\n }\n }\n if (validNodes != null) {\n newValue = validNodes.toArray(new Node[validNodes.size()]);\n if (equalNodes(newValue, selectedNodes)) {\n return;\n } \n } else {\n newValue = value;\n }\n\n if ((newValue.length != 0) && (vetoableSupport != null)) {\n try {\n // we send the vetoable change event only for non-empty selections\n vetoableSupport.fireVetoableChange(PROP_SELECTED_NODES, selectedNodes, newValue);\n } catch (PropertyVetoException ex) {\n veto = ex;\n return;\n }\n }\n updateSelection();\n }", "@Override\n public void acceptReject(boolean accept)\n {\n if (!accept)\n variable.setValue(savedValue);\n \n }", "private static char reserveOrGoBack() {\n Scanner input = new Scanner(System.in);\n\n System.out.print(\"Enter (r)eserve to place a reservation, \"\n\t + \"or (b)ack to go back: \");\n char option = input.next().toLowerCase().charAt(0);\n\n return option;\n }", "public static void defaultGameOptions() {\r\n\t\tGameOptions.doubleNilValueTextField.setText(\"200\");\r\n\t\tGameOptions.winScoreTextField.setText(\"500\");\r\n\t\tGameOptions.loseScoreTextField.setText(\"-200\");\r\n\t\t\r\n\t\tMain.doubleNilValue = \"200\";\r\n\t\tMain.winScore = \"500\";\r\n\t\tMain.loseScore = \"-200\";\r\n\r\n\t\t//Use the appropriate value for bagValue when three handed.\r\n\t\tif (Main.isThreeHanded){\r\n\t\t\tGameOptions.bagValue.select(\"2\");\r\n\t\t\tGameOptions.nilValueTextField.setText(\"100\");\r\n\t\t\tGameOptions.nilAllowed.setState(true);\r\n\t\t\tGameOptions.doubleNilAllowed.setState(true);\r\n\t\t\tGameOptions.nilValueTextField.setEditable(true);\r\n\t\t\tGameOptions.doubleNilValueTextField.setEditable(true);\r\n\r\n\t\t\tMain.bagValue = \"2\";\r\n\t\t\tMain.nilValue = \"100\";\r\n\t\t\tMain.isNilAllowed = true;\r\n\t\t\tMain.isDoubleNilAllowed = true;\r\n\t\t//Use the appropriate value for bagValue when four handed single.\r\n\t\t} else if (Main.isFourHandedSingle){\r\n\t\t\tGameOptions.bagValue.select(\"1\");\r\n\t\t\tGameOptions.nilValueTextField.setText(\"50\");\r\n\t\t\tGameOptions.nilAllowed.setState(true);\r\n\t\t\tGameOptions.doubleNilAllowed.setState(false);\r\n\t\t\tGameOptions.nilValueTextField.setEditable(true);\r\n\t\t\tGameOptions.doubleNilValueTextField.setEditable(false);\r\n\r\n\t\t\tMain.bagValue = \"1\";\r\n\t\t\tMain.nilValue = \"50\";\r\n\t\t\tMain.isNilAllowed = true;\r\n\t\t\tMain.isDoubleNilAllowed = false;\r\n\t\t//Use the appropriate value for bagValue when four handed teams.\r\n\t\t} else {\r\n\t\t\tGameOptions.bagValue.select(\"1\");\r\n\t\t\tGameOptions.nilValueTextField.setText(\"50\");\r\n\t\t\tGameOptions.nilAllowed.setState(true);\r\n\t\t\tGameOptions.doubleNilAllowed.setState(true);\r\n\t\t\tGameOptions.nilValueTextField.setEditable(true);\r\n\t\t\tGameOptions.doubleNilValueTextField.setEditable(true);\r\n\r\n\t\t\tMain.bagValue = \"1\";\r\n\t\t\tMain.nilValue = \"50\";\r\n\t\t\tMain.isNilAllowed = true;\r\n\t\t\tMain.isDoubleNilAllowed = true;\r\n\t\t}\r\n\t}", "protected void mapValueToWithinBounds() {\n if (getAllele() != null) {\n \tFloat d_value = ( (Float) getAllele());\n if (d_value.isInfinite()) {\n // Here we have to break to avoid a stack overflow.\n // ------------------------------------------------\n return;\n }\n // If the value exceeds either the upper or lower bounds, then\n // map the value to within the legal range. To do this, we basically\n // calculate the distance between the value and the float min,\n // then multiply it with a random number and then care that the lower\n // boundary is added.\n // ------------------------------------------------------------------\n if (d_value.floatValue() > m_upperBound ||\n d_value.floatValue() < m_lowerBound) {\n RandomGenerator rn;\n if (getConfiguration() != null) {\n rn = getConfiguration().getRandomGenerator();\n }\n else {\n rn = new StockRandomGenerator();\n }\n setAllele(new Float((rn.nextFloat()\n * ((m_upperBound - m_lowerBound))) + m_lowerBound));\n }\n }\n }", "private PropertySpecBuilder<T> options(boolean mustMatch, Collection<?> options)\n {\n Preconditions.checkArgument(this.valueOptions == null, \"value options already set\");\n Preconditions.checkArgument(options != null && !options.isEmpty(), \"at least one value option must be set\");\n this.valueOptions = options.stream()\n .map(option -> option instanceof PropertySpec.Value ? (PropertySpec.Value<T>) option :\n PropertySpec.Value.of((T) option))\n .collect(Collectors.toList());\n this.valueOptionsMustMatch = mustMatch;\n return this;\n }", "public void validateMinimum() {\n/* */ double newMin;\n/* */ try {\n/* 373 */ newMin = Double.parseDouble(this.minimumRangeValue.getText());\n/* 374 */ if (newMin >= this.maximumValue) {\n/* 375 */ newMin = this.minimumValue;\n/* */ }\n/* */ }\n/* 378 */ catch (NumberFormatException e) {\n/* 379 */ newMin = this.minimumValue;\n/* */ } \n/* */ \n/* 382 */ this.minimumValue = newMin;\n/* 383 */ this.minimumRangeValue.setText(Double.toString(this.minimumValue));\n/* */ }", "private boolean acceptedValueRange(double amount){\n if(amount <= 1.0 && amount >= 0.0){\n return true;\n }\n else{\n throw new IllegalArgumentException(\"Number must be in range of [0,1]\");\n }\n }", "@Test\r\n\tpublic void testChooseResultWithUnChangeCarPositionSecond() {\r\n\t\tMontyHall monty = new MontyHall();\r\n\t\tmonty.setTheDoorWithCar(1);\r\n\t\tmonty.setChanged(false);\r\n\t\tmonty.setUserChoosedDoor(0);\r\n\t\tassertEquals(2, monty.getTheDoorChoosedBycompere());\r\n\t\tassertEquals(false, monty.winThePrize());\r\n\r\n\t\tmonty.setUserChoosedDoor(1);\r\n\t\tassertNotEquals(1, monty.getTheDoorChoosedBycompere());\r\n\t\tassertEquals(true, monty.winThePrize());\r\n\r\n\t\tmonty.setUserChoosedDoor(2);\r\n\t\tassertEquals(0, monty.getTheDoorChoosedBycompere());\r\n\t\tassertEquals(false, monty.winThePrize());\r\n\t}", "public void setOldPVal(double pVal) { this.pValBefore = pVal; }", "public boolean merge(Case from, Case to)\n {\n if (from.getValue() == to.getValue() && from.getValue() != 0)\n {\n to.setValue(to.getValue()+from.getValue());\n from.setValue(0);\n return true;\n }\n return false;\n }", "private void matchValues(String vConfValue, String resValue, Comparison comparison, String param) {\r\n\r\n if (vConfValue != null && (Double.parseDouble(vConfValue) == Double.parseDouble(resValue)\r\n || (Double.parseDouble(vConfValue) == (Double.parseDouble(resValue) * m_Fact_1024))\r\n || (Double.parseDouble(resValue) * m_Fact_1000 - Double.parseDouble(vConfValue) <10 ) && (Double.parseDouble(resValue) * m_Fact_1000 - Double.parseDouble(vConfValue) >=0 ) )) {\r\n comparison.setMatchSatus(\"MATCH\");\r\n } else {\r\n comparison.setMatchSatus(\"MISMATCH\");\r\n matchResult = false;\r\n }\r\n }", "private void userChoice(int x) {\n int choice;\n while (true) { // loop for validation\n try {\n choice = Integer.parseInt(sc.next());\n if (choice < 0 || choice > x) {\n System.out.println(\"Error! Please enter a valid number from the option above\");\n } else {\n this.choice = choice;\n return;\n }\n } catch (Exception e) {\n System.out.println(\"Error! Please enter a valid number from the option above\");\n }\n }\n }", "public static boolean checkTwoStringsAreZeroOrOneEditsAway(String first, String second) {\n if (first.length() == second.length()) {\n return oneEditReplace(first, second);\n }else if(first.length() - 1 == second.length()){\n return oneEditInsert(second, first);\n }else if(first.length() + 1 == second.length())\n return oneEditInsert(first, second);\n\n return false;\n }", "public static void setGsSearchLosDiscard(double val) {\n gsSearchLosDiscard = val;\n }", "private void checkSendOption(SendOptions options) {\n if(options.getFrom() == null || !Utils.isAddress(options.getFrom())) {\n throw new IllegalArgumentException(\"Invalid 'from' parameter : \" + options.getFrom());\n }\n\n if(options.getGas() == null || !Utils.isNumber(options.getGas())) {\n throw new IllegalArgumentException(\"Invalid 'gas' parameter : \" + options.getGas());\n }\n\n if(options.getValue() == null || !Utils.isNumber(options.getValue())) {\n throw new IllegalArgumentException(\"Invalid 'value' parameter : \" + options.getValue());\n }\n }", "public void tensionRangeCheck(){\n if(motor.get() < 0){\n if(Bottom_Limit_Switch.get() | tenPot.pidGet()> tenPotMAX ){\n motor.set(0.0);\n }\n }else if(motor.get() > 0){\n if(Top_Limit_Switch.get() | tenPot.pidGet()< tenPotMIN){\n motor.set(0.0);\n }\n }\n }", "private void resetIfInvalid(ListPreference pref) {\n String value = pref.getValue();\n if (pref.findIndexOfValue(value) == NOT_FOUND) {\n \tif(pref.getKey().equalsIgnoreCase(KEY_VIDEO_QUALITY)) {\n \t\treturn;\n \t}\n pref.setValueIndex(0);\n }\n }", "private boolean isValidOption(int choice, int maxChoice)\n {\n return choice > 0 && choice <= maxChoice;\n }", "@Override\n public boolean distributesDown() {\n return betterOrEqual(P);\n }", "public static void options(){\n //player 1 not enough cards\n if(hand1.isEmpty()){\n System.out.println();\n System.out.println(\"Player 1 cards: \" + hand1.cardsLeft());\n System.out.println(\"Player 2 cards: \" + hand2.cardsLeft()+\"\\n\");\n System.out.println(\"Not enough cards, Player 1 loses\");\n outcome = 2;\n outcomes();\n //player 2 not enough cards\n }else if(hand2.isEmpty()){\n System.out.println();\n System.out.println(\"Player 1 cards: \" + hand1.cardsLeft());\n System.out.println(\"Player 2 cards: \" + hand2.cardsLeft()+\"\\n\");\n System.out.println(\"Not enough cards, Player 2 loses\");\n outcome = 1;\n outcomes();\n //tie by both 0 cards\n }else if(hand1.isEmpty()&&hand2.isEmpty()){\n System.out.println();\n System.out.println(\"Player 1 cards: \" + hand1.cardsLeft());\n System.out.println(\"Player 2 cards: \" + hand2.cardsLeft()+\"\\n\");\n System.out.println(\"No winner\");\n outcome = 3;\n outcomes();\n }\n }", "public static void showPreviousOptions() {\r\n\t\tGameOptions.bagValue.select(Main.bagValue);\r\n\t\tGameOptions.nilValueTextField.setText(Main.nilValue);\r\n\t\tGameOptions.doubleNilValueTextField.setText(Main.doubleNilValue);\r\n\t\tGameOptions.winScoreTextField.setText(Main.winScore);\r\n\t\tGameOptions.loseScoreTextField.setText(Main.loseScore);\r\n\t}", "void updateValue( float time ) {\n\tboolean newVal = in1 | in2;\n\tif (newVal != value) {\n\t value = newVal;\n\t Simulator.schedule(\n\t new Simulator.Event( time + (delay * 0.95f)\n\t\t+ PRNG.randomFloat( delay * 0.1f ) ) {\n\t\t void trigger() {\n\t\t\toutputChangeEvent( this.time );\n\t\t }\n\t\t}\n\t );\n\t}\n }", "private void getMinPrice(String firstPrice, String secondPrice) {\n int price1 = Integer.parseInt(firstPrice);\n int price2 = Integer.parseInt(secondPrice);\n if (price1 < price2) {\n minPrice = firstPrice;\n maxPrice = secondPrice;\n } else {\n minPrice = secondPrice;\n maxPrice = firstPrice;\n }\n }", "public static int getUserOption(){\n\n String numberAsString;\n int userOption;\n java.util.Scanner scanner = new java.util.Scanner(System.in);\n\n listMenuOptions();\n numberAsString = scanner.nextLine();\n userOption = Integer.parseInt(numberAsString); // Convert string to a integer\n while ( ( userOption < 0 )|| (userOption > 4 ) ) { // check if input is valid\n System.out.println(\"You did not enter a valid option. Try again.\");\n listMenuOptions();\n numberAsString = scanner.nextLine();\n userOption = Integer.parseInt(numberAsString); // Convert string to a integer\n }\n return userOption;\n }", "public void setValue2 (String Value2);", "@Test\r\n\tpublic void testChangeTheOriginalChooseIsBetterThanNotChange() {\r\n\t\tMontyHall monty = new MontyHall();\r\n\t\tmonty.setChanged(true);\r\n\t\tfloat rateOfChange = monty.rateOfWinThePrizeWithChangeTheOriginalChoose(10);\r\n\t\tmonty.setChanged(false);\r\n\t\tfloat rateOfNotChange = monty.rateOfWinThePrizeWithoutChangeTheOriginalChoose(10);\r\n\t\tassertTrue(rateOfChange > rateOfNotChange);\r\n\r\n\t\t/* count is 100 */\r\n\t\tmonty.setChanged(true);\r\n\t\trateOfChange = monty.rateOfWinThePrizeWithChangeTheOriginalChoose(100);\r\n\t\tmonty.setChanged(false);\r\n\t\trateOfNotChange = monty.rateOfWinThePrizeWithoutChangeTheOriginalChoose(100);\r\n\t\tassertTrue(rateOfChange > rateOfNotChange);\r\n\r\n\t\t/* count is 10000 */\r\n\t\tmonty.setChanged(true);\r\n\t\trateOfChange = monty.rateOfWinThePrizeWithChangeTheOriginalChoose(10000);\r\n\t\tmonty.setChanged(false);\r\n\t\trateOfNotChange = monty.rateOfWinThePrizeWithoutChangeTheOriginalChoose(10000);\r\n\t\tassertTrue(rateOfChange > rateOfNotChange);\r\n\r\n\t\t/* count is 1000000 */\r\n\t\tmonty.setChanged(true);\r\n\t\trateOfChange = monty.rateOfWinThePrizeWithChangeTheOriginalChoose(1000000);\r\n\t\tmonty.setChanged(false);\r\n\t\trateOfNotChange = monty.rateOfWinThePrizeWithoutChangeTheOriginalChoose(1000000);\r\n\t\tassertTrue(rateOfChange > rateOfNotChange);\r\n\t}", "public void keepRange(E a, E b) {\n\n keepRangeRecur(root, a, b);\n }", "public void testSumAtSelectionOnOthersAccount() {\r\n addAccount();\r\n addAccount2();\r\n solo.pressSpinnerItem(0, 1);\r\n addOp();\r\n tools.printCurrentTextViews();\r\n assertTrue(solo.getText(FIRST_SUM_AT_SEL_IDX).getText().toString().contains(Formater.getSumFormater().format(2000.50 - 10.50)));\r\n }", "private void createTwoValueSet()\n\t{\n\t\tm_mockery.checking(new Expectations()\n\t\t{\n\t\t\t{\n\t\t\t\tallowing(m_values).getItemCount();\n\t\t\t\twill(returnValue(2));\n\t\t\t\t\n\t\t\t\t// Keys.\n\t\t\t\tallowing(m_values).getKey(0);\n\t\t\t\twill(returnValue(0));\n\t\t\t\tallowing(m_values).getKey(1);\n\t\t\t\twill(returnValue(1));\n\t\t\t\t\n\t\t\t\tallowing(m_values).getIndex(0);\n\t\t\t\twill(returnValue(0));\n\t\t\t\tallowing(m_values).getIndex(1);\n\t\t\t\twill(returnValue(1));\n\t\t\t\t\n\t\t\t\tallowing(m_values).getKeys();\n\t\t\t\twill(returnValue(new ArrayList<Integer>() {{ add(0); add(1); }}));\n\t\t\t\t\n\t\t\t\t// Values.\n\t\t\t\tallowing(m_values).getValue(0);\n\t\t\t\twill(returnValue(0));\n\t\t\t\tallowing(m_values).getValue(1);\n\t\t\t\twill(returnValue(3));\n\t\t\t}\n\t\t});\n\t}", "void setMinValue();", "public boolean use(int value){durability -= value; if(durability == 0) return true; return false;}", "@FXML\n private void handleConfirm() {\n try {\n\n int value = Integer.parseInt(bet_field.getText());\n\n if ((value > 0) && (value <= currentPlayer.getWallet())) {\n currentPlayer.getCurrentHand().setBet(value);\n bet.setValue(value);\n }\n } catch (NumberFormatException err) {\n // Ne rien faire car c'est juste que le champ de la mise est vide\n }\n }", "private void validChoice(Weapon w0) throws WrongValueException {\n for(Weapon w : getWeaponSpawnpoint().getWeapons()){\n if (w==w0) {\n return;\n }\n }\n throw new WrongValueException();\n }", "public void setReputation(double reputation) {\n if(reputation >= 0.0 && reputation <= 100.0){\n this.reputation = reputation;\n }\n else if(reputation > 100.0){\n this.reputation = 100.0;\n }\n else{\n this.reputation = 0.0;\n }\n}", "public TDropListItem combineStrategies(TDropListItem selectedItem1, TDropListItem selectedItem2);", "private void caculateJudgeResult(Map<String, Long> timeMap, Map<String, Object> judgeResult, Slice slice,\n Expression expr, ConditionResult cr) {\n if (judgeResult.get(\"time_to\") != null && judgeResult.get(\"time_to\")\n .equals(DateTimeHelper.toFormat(\"yyyy-MM-dd HH:mm\", timeMap.get(\"time_to\")))) {\n return;\n }\n\n Double currentValue = queryValue(slice, expr, timeMap.get(\"time_from\"),\n timeMap.get(\"time_to\"));\n Double lastValue = 0.0;\n\n if ((expr.getLowerLimit().contains(\"#\") || expr.getLowerLimit().contains(\"*\"))\n && (expr.getUpperLimit().contains(\"#\") || expr.getUpperLimit().contains(\"*\"))) {\n // do nothing\n }\n // if the last judgeResult is really the last judgeTime's result, use it's currentValue as lastValue.\n else if (judgeResult.get(\"time_to\") != null\n && judgeResult.get(\"time_to\")\n .equals(DateTimeHelper.toFormat(\"yyyy-MM-dd HH:mm\", timeMap.get(\"last_time_to\")))\n && judgeResult.get(\"currentValue\") != null) {\n lastValue = Double.parseDouble(String.valueOf(judgeResult.get(\"currentValue\")));\n }\n else {\n lastValue = queryValue(slice, expr, timeMap.get(\"last_time_from\"),\n timeMap.get(\"last_time_to\"));\n }\n\n judgeResult.put(\"instance\", slice.getKey());\n\n for (String key : timeMap.keySet()) {\n judgeResult.put(key, DateTimeHelper.dateFormat(new Date(timeMap.get(key)), \"yyyy-MM-dd HH:mm\"));\n\n }\n judgeResult.put(\"currentValue\", currentValue);\n judgeResult.put(\"lastValue\", lastValue);\n\n if (currentValue == null || lastValue == null) {\n judgeResult.put(\"fire\", false);\n }\n else {\n judgeResult.put(\"fire\", caculate(currentValue, lastValue, expr, judgeResult));\n }\n\n // cache the judgeResult\n cm.putHash(RuntimeNotifyCatcher.UAV_CACHE_REGION, TIMER_JUDGE_RESULT, slice.getKey() + expr.getHashCode(),\n JSONHelper.toString(judgeResult));\n\n // set there is a judge event\n cr.setIsJudgeTime(true);\n\n }", "public static void Turno(){\n\t\tif (pl1){\n\t\t\tpl1=false;\n\t\t\tpl2=true;\t\n\t\t\tvalore = 1;\n\t\t}\n\t\telse{\n\t\t\tpl1=true;\n\t\t\tpl2=false;\n\t\t\tvalore = 2;\n\t\t}\n\t}", "@Override\n public Possible<T> or(Possible<T> alternate) {\n AbstractDynamicPossible<T> self = this;\n return new AbstractDynamicPossible<T>() {\n @Override\n public boolean isPresent() {\n return self.isPresent() || alternate.isPresent();\n }\n\n @Override\n public T get() {\n if (self.isPresent()) {\n try {\n return self.get();\n } catch (NoSuchElementException e) {\n // in case there was a race and the value became absent, fall through\n }\n }\n return alternate.get();\n }\n };\n }", "private boolean checkBoth(String input1, String input2){\r\n\t\tboolean pass=true;\r\n\t\tstart=aptManager.search(input1); //convert input into index\r\n\t\tdestn=aptManager.search(input2); //^^^\r\n\t\tif(start<0 && destn<0){//check if start and destination is valid\r\n\t\t\tJOptionPane.showMessageDialog(this,\"CANNOT IDENTIFY THE STARTING AIRPORT AND DESTINATION AIRPORT\");\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\telse if(destn<0){\r\n\t\t\tJOptionPane.showMessageDialog(this,\"CANNOT IDENTIFY THE DESTINATION AIRPORT\");\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\telse if(start<0){\r\n\t\t\tJOptionPane.showMessageDialog(this,\"CANNOT IDENTIFY THE STARTING AIRPORT\");\r\n\t\t\treturn false;\r\n\t\t}\r\n \t\telse if(start==destn){ //check if start and destination is same\r\n \t\t\tJOptionPane.showMessageDialog(this,\"THE STARTING AIRPORT AND DESTINATION AIRPORT CANNOT BE THE SAME\");\r\n \t\t\treturn false;\r\n \t\t}\r\n \t\telse if(!multiDestn.isEmpty()){\r\n \t\t\tif(destn==multiDestn.get(0)){ //if multiple destination exist, check if destination 1 and destination 2 is same\r\n \t\t\t\t\tJOptionPane.showMessageDialog(this,\"The Second Destination Airport cannot be the same as its Departing Airport\");\r\n \t\t\t\treturn false;\r\n \t\t\t}\r\n \t\t}\r\n \t\treturn pass;\r\n }", "public double selectCurrentBalance(int choice, String getUser);", "int selectValue(IntVar v) {\r\n int c = (v.max() + v.min())/2;\r\n return c;\r\n }", "double getBasedOnValue();", "boolean valueCheckMatch(String value) {\r\n\t\tif (value.length() > intLength) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\tif (hasRange) {\r\n\t\t\tLong ulongValue = Long.valueOf(Long.parseLong(value));\r\n\t\t\tif ((ulongValue.compareTo(minimum) < 0)\r\n\t\t\t\t\t|| (ulongValue.compareTo(maximum) > 0)) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn true;\r\n\t}", "@Override\n\t\t\tpublic void onClick(DialogInterface dialog, int which) {\n\t\t\t\tEditText teg = (EditText)settings.findViewById(R.id.settings_text2);\n\t\t\t\tEditText wish_teg = (EditText)settings.findViewById(R.id.settings_text1);\n\t\t\t\tSharedPreferences.Editor editora = preferences1.edit();\n\t\t\t\t\n\t\t\t\tfloat wight = preferences1.getFloat(\"weight\", 0);\n\t\t\t\tfloat w_wight = preferences1.getFloat(\"wish_weight\", 0);\n\t\t\t\t\n\t\t\t\tif ((!teg.getText().toString().equals(\"\"))&&(!wish_teg.getText().toString().equals(\"\"))){\n\t\t\t\t\t\n\t\t\t\t\teditora.putFloat(\"weight\", Float.valueOf(teg.getText().toString())).commit();\n\t\t\t \teditora.putFloat(\"wish_weight\", Float.valueOf(wish_teg.getText().toString())).commit();\n\t\t\t \t\n\t\t\t \tpoint_limit();\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tIntent intent = getIntent();\n\t\t\t \tfinish();\n\t\t\t \tstartActivity(intent);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t\n\t\t\t\telse if ((teg.getText().toString().equals(\"\"))&&(wish_teg.getText().toString().equals(\"\")))\n\t\t\t\t\t\n\t\t\t\t\t{Toast.makeText(getBaseContext(), \n\t\t\t\t \t\t \"Въведете данни за теглото!\", \n\t\t\t Toast.LENGTH_SHORT).show();\n\t\t\t\t\t\t\n\t\t\t\t\t}\t\t\n\t\t\t\t\t\n\t\t\t\telse {\n\t\t\t\t\t if((!teg.getText().toString().equals(\"\"))&&(wish_teg.getText().toString().equals(\"\"))) {\n\t\t\t\t\t\t\n\t\t\t\t\t\teditora.putFloat(\"weight\", Float.valueOf(teg.getText().toString())).commit();\n\t\t\t\t\t\tpoint_limit();\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\tIntent intent = getIntent();\n\t\t\t\t \tfinish();\n\t\t\t\t \tstartActivity(intent);\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\teditora.putFloat(\"wish_weight\", Float.valueOf(wish_teg.getText().toString())).commit();\n\t\t\t\t\t\t\n\t\t\t\t\t\tpoint_limit();\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\tIntent intent = getIntent();\n\t\t\t\t \tfinish();\n\t\t\t\t \tstartActivity(intent);\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\n\t\t\t\t\n\t\t\t}", "private void setValueToRule() {\n\t\t\n\t\tif(!currRule.isEmpty()) {\n\t\t\tAntiSpamFilterControl.setWeigthByRuleManual(currRule, Double.parseDouble(manualRuleValue.getText()));\n\t\t}\n\t\t\n\t\tif(manualCBRules.isValid()) {\n\t\t\tcurrRule = manualCBRules.getSelectedItem().toString();\n\t\t}\n\t\tmanualRuleValue.setText(AntiSpamFilterControl.getWeigthByRule(currRule, true) + \"\");\n\t}", "private void select() {\n\t\tif (selected.equals(mealSelect) && !eating) {\n\t\t\tmakeMeal();\n\t\t} else if (selected.equals(snackSelect) && !eating) {\n\t\t\tmakeSnack();\n\t\t} else if (selected.equals(medicineSelect) && !eating){\n\t\t\tmakeMedicine();\n\t\t} else if (selected.equals(playSelect) && !eating){\n\t\t\tmakePlay();\n\t\t}\n\t\t\n\t}", "protected void synchronizeOptionsToComponents() {\r\n periodTime = (long) Double.parseDouble( periodTimeComponent.getValue().toString() );\r\n maxNumberOfPlayers = (int) Double.parseDouble( maxNumberOfPlayersComponent.getValue().toString() );\r\n mapWidth = Integer.parseInt( mapWidthComponent.getSelectedItem().toString() );\r\n mapHeight = (int) Double.parseDouble( mapHeightComponent.getValue().toString() );\r\n welcomeMessage = welcomeMessageComponent.getText();\r\n gameType = gameTypeComponent.getSelectedIndex();\r\n isKillLimit = isKillLimitComponent.isSelected();\r\n killLimit = (int) Double.parseDouble( killLimitComponent.getValue().toString() );\r\n isTimeLimit = isTimeLimitComponent.isSelected();\r\n timeLimit = (int) Double.parseDouble( timeLimitComponent.getValue().toString() );\r\n password = passwordComponent.getText();\r\n amountOfWallRubbles = (int) Double.parseDouble( amountOfWallRubblesComponent.getValue().toString() );\r\n amountOfBlood = (int) Double.parseDouble( amountOfBloodComponent.getValue().toString() );\r\n amountOfWall = (int) Double.parseDouble( amountOfWallComponent.getValue().toString() );\r\n amountOfStone = (int) Double.parseDouble( amountOfStoneComponent.getValue().toString() );\r\n amountOfWater = (int) Double.parseDouble( amountOfWaterComponent.getValue().toString() );\r\n }", "private static Option pickRandom() {\n\t\treturn Option.values()[rand.nextInt(3)];\n\t}", "private void setDefaultValueIfMissing() {\n if (!getType().isNumber() || !hasValidation()) {\n return;\n }\n if (!hasDefaultValue()) {\n if (validation.hasMinimum()) {\n setDefaultValue(validation.getMinimum());\n } else {\n if (validation.hasMaximum()) {\n setDefaultValue(validation.getMaximum());\n }\n }\n }\n }", "private HandRankingValue checkAbovePair() {\n HandRankingValue aboveTrips = checkAboveTrips();\n if(aboveTrips != null)\n return aboveTrips;\n else {\n if(validTwoPair())\n return HandRankingValue.TWOPAIR;\n makePair();\n return HandRankingValue.PAIR;\n }\n }", "boolean updatePolicy() {\n double maxUtilityVal = -Double.MAX_VALUE;\n //if(x==19&&y==0)\n // System.out.println(\"minVal: \"+maxUtilityVal);\n for (int i = 0; i < AbsoluteDirection.values().length; i++) {\n double proposedValue = calculateUtility(AbsoluteDirection.values()[i]);\n // if(x==19&&y==0) {\n // System.out.println(\"Proposed value at cell \" + x + \", \" + y + \" is\" + proposedValue);\n\n // }\n if (proposedValue > maxUtilityVal) {\n policyDirection = AbsoluteDirection.values()[i];\n nextUtilityValue = proposedValue; // update curValues to nextValues at the end of iteration\n maxUtilityVal = proposedValue;\n }\n }\n\n return true;\n }", "void updateValue( float time ) {\n\tboolean newVal = in1 & in2;\n\tif (newVal != value) {\n\t value = newVal;\n\t Simulator.schedule(\n\t new Simulator.Event(\n\t\ttime + (delay * 0.95f)\n\t\t+ PRNG.randomFloat( delay * 0.1f ) ) {\n\t\t void trigger() {\n\t\t\toutputChangeEvent( this.time );\n\t\t }\n\t\t}\n\t );\n\t}\n }" ]
[ "0.5431297", "0.5249994", "0.5086695", "0.5022646", "0.49436575", "0.48967674", "0.48644307", "0.48257625", "0.47754937", "0.47585458", "0.47375986", "0.47360694", "0.47124296", "0.4711856", "0.47097412", "0.46853203", "0.46831426", "0.46653104", "0.46410072", "0.46405253", "0.4626906", "0.46239835", "0.46227515", "0.45935613", "0.45832142", "0.4579896", "0.45627707", "0.45559216", "0.45536524", "0.45478466", "0.45467645", "0.4517534", "0.45157915", "0.4499528", "0.44967532", "0.44865862", "0.44855547", "0.4474102", "0.44650233", "0.44576204", "0.44481218", "0.444789", "0.4443924", "0.44428483", "0.44367805", "0.44353104", "0.4425882", "0.44050798", "0.439799", "0.43957838", "0.43941358", "0.43902883", "0.43822607", "0.43794355", "0.43785867", "0.43757242", "0.4374287", "0.43730247", "0.43628287", "0.43491614", "0.43439433", "0.43438426", "0.43390512", "0.4333568", "0.4332973", "0.4328239", "0.43254942", "0.43228346", "0.43136993", "0.43114203", "0.4307861", "0.43073815", "0.4298833", "0.42985564", "0.4297974", "0.4296104", "0.42940634", "0.4291862", "0.42778555", "0.42776656", "0.42766136", "0.42759803", "0.42751485", "0.42690408", "0.42647517", "0.42600867", "0.4257385", "0.4251095", "0.42464873", "0.42429513", "0.4238394", "0.42377493", "0.4237308", "0.42365295", "0.42358908", "0.4235128", "0.4234481", "0.42285767", "0.4226477", "0.42204234", "0.42182907" ]
0.0
-1
Gets the players. No return value, but edits a list.
private void getPlayers() { System.out.println("How Many Players: "); pnum = getNumber(1, 3); for(int i=0; i < pnum; i++){ System.out.println("What is player " + (i + 1) + "'s name? "); String name = sc.next(); boolean dupe = true; while(dupe){ int samecounter = 0; for(Player p : players){ if(name.equals(p.getName())){ samecounter += 1; System.out.println("Name is the same as another players. Please choose another name: "); name = sc.next(); } } if(samecounter == 0){ dupe = false; } } players.add(new Player(name)); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "List<Player> getPlayers();", "@Override\n public List<Player> getPlayers() {\n return new ArrayList<Player>(players);\n }", "@Override\n public List<Player> getPlayers() {\n return players;\n }", "public List<Player> getPlayers() {\r\n return players;\r\n }", "public List<Player> getPlayers() {\r\n return players;\r\n }", "public ListResponse<PlayerResponse> getPlayers() {\n\t\tcheckProvided();\n\t\treturn players;\n\t}", "public List<Player> getPlayerList(){\n return this.players;\n }", "public List<Player> getPlayers() {\r\n\t\treturn players;\r\n\t}", "List<Player> listPlayers();", "public ArrayList<Player> getPlayers() {\n return players;\n }", "public List<Player> getPlayers() {\n\t\treturn players;\n\t}", "public ArrayList<Player> getPlayerList() {\n ArrayList<Player> ret = new ArrayList<>();\n ret.addAll(playerList);\n return ret;\n }", "public ArrayList<Entity> getPlayers() {\n ArrayList<Entity> players = new ArrayList<>();\n students.forEach(student -> players.add(student.getPlayer()));\n return players;\n }", "public List<Player> getPlayers() {\n\n\t\treturn players;\n\t}", "@Override\n public ArrayList<Player> getPlayers() {return steadyPlayers;}", "public ArrayList<Player> getPlayers() {\n return players;\n }", "@Override\n public ArrayList<Player> getPlayers() throws RemoteException {\n return players;\n }", "public List<Player> getPlayerList()\n\t{\n\t\treturn playerList;\n\t}", "public List<Player> getPlayers() {\r\n\t\tList<Player> playerList = new ArrayList<Player>();\r\n\r\n\t\tfor (Player p : players.values()) {\r\n\t\t\tif (p != null)\r\n\t\t\t\tplayerList.add(p);\r\n\t\t}\r\n\r\n\t\treturn playerList;\r\n\t}", "@Override\r\n\tpublic ArrayList<PlayerPO> getAllPlayers() {\n\t\treturn playerController.getAllPlayers();\r\n\t}", "public CopyOnWriteArrayList<Player> getPlayerList() \t\t\t\t\t\t\t{ return this.playerList; }", "public EntityList<Player> getPlayers() {\n\t\treturn players;\n\t}", "static List<Player> getAllPlayers() {\n\t\treturn null;\r\n\t}", "private void getPlayerList(){\r\n\r\n PlayerDAO playerDAO = new PlayerDAO(Statistics.this);\r\n players = playerDAO.readListofPlayerNameswDefaultFirst();\r\n\r\n }", "public List<ServerPlayerEntity> getPlayerList() {\n return this.players;\n }", "public Player[] getPlayers() {\r\n return players;\r\n }", "public Player[] getPlayers()\r\n\t{\r\n\t\treturn this.players;\r\n\t}", "public Player[] getPlayers()\n\t{\n\t\treturn players;\n\t}", "public Player[] getPlayers() {\n return players;\n }", "public List<Player> getAllPlayers() {\r\n // TODO fix actual order of players in the List.\r\n\r\n List<Player> players = new ArrayList<>();\r\n players.addAll(teamRed.getPlayers());\r\n players.addAll(teamBlue.getPlayers());\r\n\r\n return players;\r\n }", "public Player[] getPlayers() {\n return this.players;\n }", "public Player[] getPlayers() {\n return this.players;\n }", "public ArrayList<Player> getPlayers() {\n return players;\n}", "public LinkedList<Player> getPlayers() {\n\t\treturn this.players;\n\t}", "protected ClientList getCurrentPlayers() {\r\n\t\treturn this.players;\r\n\t}", "private Collection<Player> getPlayers() {\n\t\treturn players;\n\t}", "ArrayList<Player> getAllPlayer();", "public List<Player> findAllPlayers(){\n\t\treturn playerRepository.findAll();\n\t}", "public String[] getPlayers() {\r\n return playerIds;\r\n }", "public Set<Player> getPlayers() {\n return players;\n }", "public ArrayList<CardGamePlayer> getPlayerList(){\n\t\treturn this.playerList;\n\t}", "@Override\n\tpublic List<Player> getPlayer() {\n\t\treturn ofy().load().type(Player.class).list();\n\t}", "public void getPlayerList() {\n if (connected == true) {\n try {\n write(\"get playerlist\");\n } catch (IOException e) {\n System.out.println(\"No connecting with server:ServerCommunication:getPlayerList()\");\n }\n }\n }", "public static ArrayList<Player> getWinners(){return winners;}", "public List<PlayerItem> getAll();", "public List<PlayerItem> getAllPlayerItemById(Player player);", "public static ArrayList<Player> getPlayerAry(){\n\t\treturn players;\n\t}", "public Set<String> getPlayers()\n\t{\n\t\tSet<String> player = playerPieces.keySet();\n\t\treturn player;\n\t}", "public List <FootballPlayer> getAllPlayers() {\n\t\treturn market.getAllPlayers();\n\t}", "public CompactPlayer[] getPlayers()\n {\n return players;\n }", "public ArrayList<CardGamePlayer> getPlayerList() {\n\t\treturn playerList;\n\t}", "public List<Player> getPlayersOrdered() {\r\n ArrayList<Player> result = new ArrayList<>();\r\n for (PlayerContainer container : players) {\r\n result.add(container.player);\r\n }\r\n return result;\r\n }", "public List<String> listPlayerNames() {\n return this.playersNames;\n }", "public static Collection<? extends Player> getOnlinePlayers() {\n return Bukkit.getServer().getOnlinePlayers();\n }", "Collection<User> players();", "public ArrayList<Player> getPlayersInGame() {\n return playersInGame;\n }", "public void setPlayers(ArrayList<Player> players) {\n this.players = players;\n }", "public Set<UUID> getAlivePlayers() {\n return new HashSet<>(players);\n }", "public Hashtable<Integer, Player> getPlayers() {\r\n\t\treturn players;\r\n\t}", "Set<String> getPlayers();", "public List<Player> getAll() {\n PlayerDB pdb = new PlayerDB();\n return pdb.getAll();\n }", "public TennisPlayer[] getAllPlayers() throws TennisDatabaseRuntimeException {\n\t\t \t\n\t\tTennisPlayerContainerIterator iterator = this.iterator();\n\t\t\n iterator.setInorder();\n \t\n TennisPlayer[] outputArray = new TennisPlayer[playerCount];\n \n int index = 0;\n \n while (iterator.hasNext()) {\n \t\n outputArray[index] = iterator.next();\n \n index++;\n \n }\n \n return outputArray;\n \n\t}", "public List<PlayerInfo> getPlayerList(GameInfo gi){\n\t\tClientModelFacade facade = ClientModelFacade.getInstance(null);\n\t\t\n\t\tGameInfo[] gameList = facade.getGamesList();\n\n\t\tfor(int i = 0; i < gameList.length; i++){\n\t\t\tif(gameList[i].getId() == gi.getId()){\n\t\t\t\treturn gameList[i].getPlayers();\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}", "public List<String> getAllPlayers() throws ServerProblem {\r\n\ttry (Connection connTDB = ConnectionManager.getInstance().getConnection()) {\r\n\t LOGGER.debug(\"Getting all players\");\r\n\t List<String> results = engine.getAllPlayers(connTDB);\r\n\t LOGGER.debug(\"Players found in the database: \" + results);\r\n\t return results;\r\n\t} catch (Exception ex) {\r\n\t String error = \"Problem encountered getting all players: \" + ex;\r\n\t LOGGER.error(error);\r\n\t throw new ServerProblem(error, ex);\r\n\t}\r\n }", "List<Player> findAllPlayers();", "private void updatePlayerList() \n\t{\n\t\tplayerStatus.clear();\n\n\t\tfor(Player thisPlayer: players) // Add the status of each player to the default list model.\n\t\t{\n\t\t\tplayerStatus.addElement(thisPlayer.toString());\n\t\t}\n\n\t}", "private void loadPlayers() {\r\n this.passive_players.clear();\r\n this.clearRoster();\r\n //Map which holds the active and passive players' list\r\n Map<Boolean, List<PlayerFX>> m = ServiceHandler.getInstance().getDbService().getPlayersOfTeam(this.team.getID())\r\n .stream().map(PlayerFX::new)\r\n .collect(Collectors.partitioningBy(x -> x.isActive()));\r\n this.passive_players.addAll(m.get(false));\r\n m.get(true).stream().forEach(E -> {\r\n //System.out.println(\"positioning \"+E.toString());\r\n PlayerRosterPosition pos = this.getPlayerPosition(E.getCapnum());\r\n if (pos != null) {\r\n pos.setPlayer(E);\r\n }\r\n });\r\n }", "public List<ColorId> getPlayerList() {\n return playerList;\n }", "@RequestMapping(\"/players\")\n public List<Player> getAllPlayers() {\n return playerService.getPlayerList();\n }", "ArrayList<IPlayer> buildPlayerList();", "public List<Colour> getPlayerList();", "public Player getPlayerFromList(String name){\n for (Player player : players){\n if (player.getName().equals(name)){\n return player;\n }\n }\n return null; //This will never happen. Will always be found. Only called from the takeoverTerritory method\n }", "private void refreshPlayerList() {\n List<MarketItem> items = new ArrayList<>();\n EntityRef player = localPlayer.getCharacterEntity();\n for (int i = 0; i < inventoryManager.getNumSlots(player); i++) {\n EntityRef entity = inventoryManager.getItemInSlot(player, i);\n\n if (entity.getParentPrefab() != null) {\n MarketItem item;\n\n if (entity.hasComponent(BlockItemComponent.class)) {\n String itemName = entity.getComponent(BlockItemComponent.class).blockFamily.getURI().toString();\n item = marketItemRegistry.get(itemName, 1);\n } else {\n item = marketItemRegistry.get(entity.getParentPrefab().getName(), 1);\n }\n\n items.add(item);\n }\n }\n\n tradingScreen.setPlayerItems(items);\n }", "public void setPlayers(ArrayList<Player> players) {\n\t\tthis.players = players;\n\t}", "public ArrayList<Player> getOtherPlayers() {\r\n\t\tArrayList<Player> output = new ArrayList<Player>();\r\n\t\toutput.addAll(players);\r\n\t\toutput.remove(getWhoseTurn() - 1);\r\n\t\treturn output;\r\n\t}", "public List<Player> getPlayersInRoom() {\n\t\treturn playersInRoom;\n\t}", "public Collection<Player> getPlayersChunk() {\n var chunk = new Chunk<Player>();\n var playersChunk = chunk.get(this.players, ALL_PLAYERS_CHUNK_SIZE, allPlayersChunkIndex);\n\n // up to ALL_PLAYERS_CHUNK_SIZE with empty players\n // to have an even view\n var startIndex = playersChunk.size();\n for (var i = startIndex; i < ALL_PLAYERS_CHUNK_SIZE; i++) {\n playersChunk.add(new Player(new Person()));\n }\n\n return playersChunk;\n }", "public static List<Player> getTrackablePlayers() {\n\t\tPlayer[] players = Bukkit.getOnlinePlayers();\n\t\tList<Player> players1 = new ArrayList<Player>();\n\t\tfor (int i = 0; i < players.length; i++) {\n\t\t\tif (!players[i].hasMetadata(\"invisible\")) {\n\t\t\t\tplayers1.add(players[i]);\n\t\t\t}\n\n\t\t}\n\t\treturn players1;\n\t}", "public List<PlayerInstance> getAllPlayers()\n\t{\n\t\tfinal List<PlayerInstance> players = new ArrayList<>();\n\t\tfor (Creature temp : getCharactersInside())\n\t\t{\n\t\t\tif (temp instanceof PlayerInstance)\n\t\t\t{\n\t\t\t\tplayers.add((PlayerInstance) temp);\n\t\t\t}\n\t\t}\n\t\treturn players;\n\t}", "public static ArrayList<Player> getAllPlayingPlayers() {\n // Anton fix: Would copy the list itself, we want just the items.\n // Remove/add manipulations would affect original list\n /*\n * ArrayList<Player> all = players; for (Player player: all) { if\n * (!player.isPlaying()) { all.remove(player); } }\n */\n\n ArrayList<Player> all = new ArrayList<Player>();\n for (Player player : players) {\n if (player.isPlaying()) all.add(player);\n }\n\n return all;\n }", "public List<Player> getAllOrdered() {\n PlayerDB pdb = new PlayerDB();\n return pdb.getAllOrdered();\n }", "public List<OpenPlayer> getOpenPlayers() {\r\n if(actuelAktionators.isEmpty()){\r\n throw new IllegalStateException(\"In der Liste der Spieler muss mindestens ein Spieler sein (der Hoechtbietende)\");\r\n }\r\n return actuelAktionators;\r\n }", "@Override\r\n\tpublic List<Player> getAllPlayer(String email) {\n\t\treturn dao.getAllPlayer(email);\r\n\t}", "public static Map<String, PlayerConfig> getPlayers() {\n return players;\n }", "public List<Player> getAttackedPlayers() {\r\n\t\tArrayList<Player> output = new ArrayList<Player>();\r\n\t\tfor(Player p : getOtherPlayers()) {\r\n\t\t\tif(!(p.deck.hand.contains(new Moat()) \r\n\t\t\t\t\t|| p.deck.duration.contains(new Lighthouse()) \r\n\t\t\t\t\t|| p.deck.duration.contains(new Champion()) \r\n\t\t\t\t\t|| p.getPlayerNum() == getWhoseTurn())) {\r\n\t\t\t\toutput.add(p);\r\n\t\t\t}\r\n\t\t\tArrayList<Card> reactions = new ArrayList<Card>();\r\n\t\t\tfor(Card c : p.deck.hand) {\r\n\t\t\t\tif(c.isReaction()) reactions.add(c);\r\n\t\t\t}\r\n\t\t\tfor(Card c : reactions) {\r\n\t\t\t\tc.reactAttack();\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn output;\r\n\t}", "public List<Player> getDisplayList(){\n\t\tList<Player> dis = new ArrayList<>(1);\n\t\tif(!playersFinished.isEmpty()){\n\t\t\tdis.add(playersFinished.get(tempNumber -1));//last to finish\n\t\t}\n\t\treturn dis;\n\t}", "public List<String> getAllPlayerNames() {\n List<String> playerNames = new ArrayList<>(10);\n for (Player p : players) {\n playerNames.add(p.getName());\n }\n return playerNames;\n }", "public List<String> getToggledPlayers() {\n return toggledPlayers;\n }", "public List<Player> getPassengers() {\n\t\tList<Player> ret = new ArrayList<Player>();\n\t\t\n\t\tfor (Player p : Bukkit.getOnlinePlayers()) {\n\t\t\tif (isPassenger(p))\n\t\t\t\tret.add(p);\n\t\t}\n\t\treturn ret;\n\t}", "public Map<String, Player> getPlayersMap(){\n return this.players;\n }", "public void setPlayers(ArrayList<Integer> players) {\n this.players= new ArrayList<>(players);\n }", "public Set<Player> getParticipants() { //TODO: not sure the validation needs to happend here\n\t\t// Run through the results and make sure all players have been pushed into the participants set.\n\t\tfor ( Result result : results ) {\n\t\t\tparticipants.add(result.getWinner());\n\t\t\tparticipants.add(result.getLoser());\n\t\t}\n\n\t\treturn participants;\n\t}", "public synchronized List<Card> getCardsInPlay(){\n cardsInPlay.clear();\r\n \r\n for(Player player: players){\r\n if(player == null){\r\n continue;\r\n }\r\n if(player.getCardsInHand().isEmpty()){\r\n continue;\r\n }\r\n for(Card card: player.getCardsInHand()){\r\n cardsInPlay.add(card);\r\n }\r\n }\r\n return cardsInPlay;\r\n }", "public java.util.List<java.lang.Long>\n getPlayerIdsList() {\n return java.util.Collections.unmodifiableList(playerIds_);\n }", "@Override\n public Player getPlayerOnIndex(int index) {\n return players.get(index);\n }", "public JList<Player> getPlayerListGui() {\r\n return playerListGui;\r\n }", "public java.util.List<java.lang.Long>\n getPlayerIdsList() {\n return playerIds_;\n }", "public static ArrayList<Player> getOtherPlayers() {\n ArrayList<Player> all = getAllPlayingPlayers();\n all.remove(getCurrentPlayer());\n\n return all;\n }", "public ArrayList<Player> getLeaderboard() {\n ArrayList<Player> result = new ArrayList(players);\n for (Player player : players) {\n Collections.sort(result);\n Collections.reverse(result);\n }\n return result;\n}", "public List<SkungeePlayer> getPlayers(SkungeeServer... servers) throws TimeoutException, InterruptedException, ExecutionException {\n\t\tPlayersPacket packet = new PlayersPacket();\n\t\tpacket.setServers(servers);\n\t\treturn japson.sendPacket(packet);\n\t}" ]
[ "0.81489414", "0.81489134", "0.81304044", "0.7962072", "0.7962072", "0.79062784", "0.7878739", "0.78022283", "0.7774813", "0.7733472", "0.7709327", "0.77087826", "0.7685664", "0.766434", "0.76585495", "0.76458246", "0.7637918", "0.7628428", "0.76126975", "0.7588723", "0.7581262", "0.75627667", "0.7511621", "0.7481984", "0.7458369", "0.7452134", "0.7442999", "0.74275506", "0.741902", "0.7418291", "0.7392367", "0.7392367", "0.73784584", "0.73549545", "0.73518306", "0.7345499", "0.7338199", "0.7298362", "0.7295281", "0.7286352", "0.7153819", "0.7132959", "0.7106055", "0.7058674", "0.7045689", "0.70340526", "0.7003098", "0.6978907", "0.69688356", "0.6967969", "0.69612473", "0.6957644", "0.69514436", "0.69486785", "0.6938423", "0.69333255", "0.6918161", "0.69108075", "0.6893714", "0.68780595", "0.6862179", "0.68533593", "0.68363476", "0.6803541", "0.6799336", "0.6794288", "0.678586", "0.67800665", "0.67769027", "0.6773882", "0.6767162", "0.6747728", "0.6726321", "0.6719533", "0.6716321", "0.6692177", "0.6689948", "0.66605943", "0.66596305", "0.6638828", "0.66110605", "0.6607248", "0.6596241", "0.6573852", "0.6568409", "0.65586764", "0.65457374", "0.651966", "0.6501169", "0.648734", "0.64709306", "0.6467659", "0.64575195", "0.6442586", "0.64260966", "0.6422077", "0.64182264", "0.6412916", "0.6393618", "0.63891137" ]
0.6771411
70
Gets the pets. Again, no return value but edits a list.
private void getPets(){ for(Player p : players){ ArrayList<Pet> currentpets = new ArrayList<>(); System.out.println("How many pets for " + p.getName() + ": "); int petnum = getNumber(1,3); for(int i = 0; i < petnum; i++){ System.out.println("Pet options are:"); int c = 1; //Counter for which pet, relating to which option for(Pet option : pets){ System.out.println(c + ". " + option.getClass().getSimpleName() + "."); c++; } System.out.println("Please Choose Your Pet With A Number:"); int selected = getNumber(1, 6); Pet selectedpet = pets.get(selected - 1); System.out.println("Please Enter A Name For Your Pet: "); String petname = sc.next(); selectedpet.setPetname(petname); System.out.println("You now have a pet named " + selectedpet.getPetname()); currentpets.add(selectedpet); } p.setPets(currentpets); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public ArrayList<Pets> getPets(){\n DataBase db = new DataBase(context);\n initPets(db);\n return db.getPets();\n }", "public ArrayOfPetModel getPets() {\n return localPets;\n }", "public Collection<VirtualPet> pets() {\n\t\treturn shelterPets.values();\n\t}", "public ArrayList<Pets> getPetList() {\n\n ArrayList<Pets> petList = new ArrayList<>();\n\n try {\n Statement statement = conn.createStatement();\n String sqlStatement = \"SELECT name FROM pets\";\n\n ResultSet rs = statement.executeQuery(sqlStatement);\n\n while (rs.next()) {\n //Create a new Pets object\n Pets pet = new Pets();\n pet.setName(rs.getString(\"name\"));\n\n System.out.println(pet.getName());\n\n }\n } catch (SQLException exception) {\n System.out.println(\"Error getting Pet name list: \" + exception);\n }\n return petList;\n }", "public boolean getPets() {\n\t\treturn this.pets;\n\t}", "public ArrayList<Planet> getModifiedPlanets()\n\t{\n\t\treturn planetList;\n\t}", "private PotCollection loadPotList(){\n SharedPreferences preferences = getSharedPreferences(SHAREDPREF_SET, MODE_PRIVATE);\n int sizeOfPotList = preferences.getInt(SHAREDPREF_ITEM_POTLIST_SIZE, 0);\n for(int i = 0; i<sizeOfPotList; i++){\n Log.i(\"serving calculator\", \"once\");\n String potName = preferences.getString(SHAREDPREF_ITEM_POTLIST_NAME+i, \"N\");\n int potWeight = preferences.getInt(SHAREDPREF_ITEM_POTLIST_WEIGHT+i, 0);\n Pot tempPot = new Pot(potName, potWeight);\n potList.addPot(tempPot);\n }\n return potList;\n }", "public void setPets(ArrayOfPetModel param) {\n localPetsTracker = true;\n\n this.localPets = param;\n }", "public VirtualPet getPet(String name) {\n\t\treturn shelterPets.get(name);\n\n\t}", "public List<Planet> getPlanets() {\n return planetList;\n }", "public Planet[] getPlanets() {\n return this.planets;\n }", "@Override\r\n\tpublic List<shopPet> getAll() {\n\t\treturn dao.getAll();\r\n\t}", "private void populatepets(){\r\n\t\tpets.add(new Cat(\"UnNamed\"));\r\n\t\tpets.add(new Cow(\"UnNamed\"));\r\n\t\tpets.add(new Dog(\"UnNamed\"));\r\n\t\tpets.add(new Rabbit(\"UnNamed\"));\r\n\t\tpets.add(new Rat(\"UnNamed\"));\r\n\t\tpets.add(new Velociraptor(\"UnNamed\"));\r\n\t}", "@Override\n public List<Vessel> getVessels() {\n return new ArrayList<>(boats);\n }", "public Flux<Pet> findPetsAvailable() {\n\n\t\treturn client.get().uri(urlFindByStatus).retrieve().bodyToFlux(Pet.class);\n\t}", "List<PilotContainer> getPilots();", "public List<Planet> getPlanets() {\n return planet;\n }", "@Override\r\n\tpublic List<Pilot> getAllPilots() {\r\n\t\tList<Pilot> cloned = new ArrayList<>(pilots);\r\n\t\treturn cloned;\r\n\t}", "public ArrayList<Thing> getThings()\r\n {\r\n \tArrayList<Thing> inventory = new ArrayList<Thing>();\r\n \tfor (int i=0; i<items.size(); i++)\r\n \t\tinventory.add(items.get(i));\r\n \treturn inventory;\r\n }", "public List<Vet> getAllVets() {\n\t\tentityManager = JPAUtils.getEntityManager();\n\t\tentityManager.getTransaction().begin();\n\t\tvets = entityManager.createQuery(\"from Vet\", Vet.class).getResultList();\n\t\tentityManager.getTransaction().commit();\n\t\tentityManager.close();\n\t\treturn vets;\n\t}", "private static List<PitDto> getPits(List<Pit> pits) {\n return pits.stream().map(GameMapper::getPit).collect(Collectors.toList());\n }", "public ArrayList<Pokemon> getAllPokemon(){\n\t\treturn caughtPokemon; \n\t}", "ArrayList<RecipeObject> getRecipes();", "public List<Cheese> getCheeseList() {\n\t\tif (cheesesInStock.isEmpty())\n\t\t\treturn Collections.emptyList();\t// Always return same list\n\t\telse\n\t\t\treturn new ArrayList<Cheese>(cheesesInStock);\n\t}", "public List<Pet> listPets(Integer limit) throws RestClientException {\n return listPetsWithHttpInfo(limit).getBody();\n }", "List<SimpleInventory> getInventories();", "public List<PetDTO> getAllPetsLivingDTO() {\n EntityManager em = emf.createEntityManager();\n Query query = em.createQuery(\"SELECT NEW dto.PetDTO(p) FROM Pet AS p WHERE p.death = null\");\n return query.getResultList();\n }", "public Pet getPet() {\n return pet;\n }", "List<PricedItem> getItems() {\n return Collections.unmodifiableList(items);\n }", "List<InventoryItem> getInventory();", "public List<Inventory> getInventory();", "public LiveData<List<Spot>> getAllSpots() { return mAllSpots; }", "public ArrayList<Item> getList() {\r\n\t\treturn inventory;\r\n\t}", "java.util.List<WorldUps.UGoPickup> \n getPickupsList();", "public ArrayList getPrice() {\n return priceArray;\n }", "public Vector<EntityWeapon> getWeaponList();", "public List<Pizza> getPizzas(){\n return new ArrayList<>(pizzas);\n }", "public PetModel[] getPetModel() {\n return localPetModel;\n }", "public List<StockItem> getStockList();", "List<Goods> getGoodsList();", "public ArrayList<Double> GetPrices()\r\n\t{\r\n\t\treturn dayStockPrices;\r\n\t}", "List<SpotPrice> getAll();", "@GetMapping({ \"/vets\" })\n\tpublic @ResponseBody Vets showResourcesVetList() {\n\t\tVets vets = new Vets();\n\t\tvets.getVetList().addAll(this.vetRepository.findAll());\n\t\treturn vets;\n\t}", "public List<ProductDto> getProducts() {\n\t\tString url = URL_BASE + \"/list\";\n\n\t\tResponseEntity<List<ProductDto>> responseEntity = restTemplate.exchange(url, HttpMethod.GET, HttpEntity.EMPTY,\n\t\t\t\tnew ParameterizedTypeReference<List<ProductDto>>() {\n\t\t\t\t});\n\t\tList<ProductDto> playerList = responseEntity.getBody();\n\t\treturn playerList;\n\t}", "public void addPets(PetPOJO pet) {\n pets.add(pet);\n }", "public ArrayList<PersonStocks> getStock(){\n return myStocks;\n }", "public ArrayList<Player> getPlayers() {\n return players;\n}", "public Weet[] getWeets() {\n return array.getWeetsFromStore();\n //return tree.toArray();\n }", "@JsonIgnore\n public ArrayList<Ingredient> getShoppingList() {\n ArrayList<Ingredient> results = new ArrayList<>();\n for (Location location : route) {\n for (PreOrder preOrder : location.getPreOrders()) {\n for (DishWrapper dishWrapper : preOrder.getItems()) {\n for (Ingredient ingredient : dishWrapper.getDish().getIngredients()) {\n if (results.contains(ingredient)) {\n results.get(results.indexOf(ingredient)).addAmount(ingredient.getAmount() * dishWrapper.getAmount());\n } else {\n ingredient.setAmount(ingredient.getAmount() * dishWrapper.getAmount());\n }\n results.add(ingredient);\n }\n }\n }\n }\n return results;\n }", "public double getPotatoesPrice();", "public ArrayList<Particle> getParticles()\n\t{\n\t\treturn particles;\n\t}", "public List<Integer> getLives() {\n return lives;\n }", "List<Player> getPlayers();", "public ReservedInstancePriceItem [] getPrices() {\n return this.Prices;\n }", "public static List<Integer> calcPriceList(List<TradeGood> allGoods, Planet planet) {\n List<Integer> priceList = new ArrayList<>();\n for (int i = 0; i < allGoods.size(); i++) {\n priceList.add(calcPrice(allGoods.get(i), planet));\n }\n return priceList;\n }", "public List<Product> getProducts();", "public List<Product> getProducts();", "public abstract List<String> getInventory();", "static void examine( List pets){\n\t\tSystem.out.println(\"Your pets need urgent attention.\");\n\t}", "public ArrayList<AbstractPokemon> getPokemon()\n {\n return caughtPokemon;\n }", "public ArrayList<Entity> getPlayers() {\n ArrayList<Entity> players = new ArrayList<>();\n students.forEach(student -> players.add(student.getPlayer()));\n return players;\n }", "private void listParkingLots() {\n for (ParkingLot pl: parkinglots) {\n System.out.println(pl.getName() + \" | price: \" + pl.getPrice() + \" /hour\");\n }\n }", "ArrayList<Bet> takeBets(ResultSet set) throws SQLException;", "public List<Object> getShips() {\n return ships;\n }", "public List<Vegetable> getVegetables() {\n ArrayList<Vegetable> vegetables = new ArrayList<>();\n for (VegetablePortion vegetablePortion : list) {\n vegetables.add(vegetablePortion.getVegetable());\n }\n return vegetables;\n }", "public void setPlanets(List<Planet> planets) {\n planetList = planets;\n }", "public ArrayList<Food> getFoods()\n {\n return foods;\n }", "public List<PlayerItem> getAll();", "public void feedAll() {\n\t\tfor (VirtualPet p : shelterPets.values()) {\n\t\t\tp.feedPet();\n\t\t}\n\t}", "public Pet getPet(String name) {\n\t\treturn getPet(name, false);\n\t}", "public PriceList getPriceList() {\n\t\treturn priceList;\n\t}", "public List<Ship> getShips()\n {\n return this.fleet;\n }", "private void refreshPlayerList() {\n List<MarketItem> items = new ArrayList<>();\n EntityRef player = localPlayer.getCharacterEntity();\n for (int i = 0; i < inventoryManager.getNumSlots(player); i++) {\n EntityRef entity = inventoryManager.getItemInSlot(player, i);\n\n if (entity.getParentPrefab() != null) {\n MarketItem item;\n\n if (entity.hasComponent(BlockItemComponent.class)) {\n String itemName = entity.getComponent(BlockItemComponent.class).blockFamily.getURI().toString();\n item = marketItemRegistry.get(itemName, 1);\n } else {\n item = marketItemRegistry.get(entity.getParentPrefab().getName(), 1);\n }\n\n items.add(item);\n }\n }\n\n tradingScreen.setPlayerItems(items);\n }", "java.util.List<cosmos.base.v1beta1.CoinOuterClass.Coin> \n getPriceList();", "public static void setPlanets(ArrayList<Planet> planet){\n //ArrayList is a mutable reference type, so I should make a copy of the input ArrayList when \n //initializing the attribute. \n ArrayList<Planet> copy=new ArrayList<Planet>();\n for(int i=0;i<planet.size();i++){\n copy.add(planet.get(i));\n }\n planets=copy;\n //print out the details of every planet using toString method(the println will automatically using toString method)\n for(int j=0;j<planets.size();j++){\n System.out.println(planets.get(j));\n }\n }", "java.util.List<com.message.EquipmentProto.PlayerEquipmentMsg> \n getListPlayerEquipmentsList();", "@Override\n public ArrayList<Player> getPlayers() {return steadyPlayers;}", "public List<Volume> list() {\n List<Volume> volumes = new ArrayList<Volume>();\n\n try {\n\n HttpResponse<Volume[]> jsonResponse = Unirest.get(rootUrl + ENDPOINT_DATASET_LIST)\n .basicAuth(auth.getUsername(),auth.getPassword())\n .header(\"accept\", \"application/json\")\n .asObject(Volume[].class);\n //System.out.print(jsonResponse.getBody());\n\n if (jsonResponse.getStatus() == HttpStatus.SC_OK) {\n Volume [] body = jsonResponse.getBody();\n System.out.println(body);\n\n for (Volume b: body){\n volumes.add(b);\n }\n }\n\n } catch (UnirestException e) {\n e.printStackTrace();\n }\n\n return volumes;\n }", "@Override\n\t public ArrayList<ItemStack> getDrops(World world, int x, int y, int z, int metadata, int fortune)\n {\n \t// DEBUG\n \tSystem.out.println(\"BlockTomato getDrops()\");\n ArrayList<ItemStack> ret = new ArrayList<ItemStack>();\n\n int count = quantityDropped(metadata, fortune, world.rand);\n for(int i = 0; i < count; i++)\n {\n Item item = getItemDropped(metadata, world.rand, fortune);\n if (item != null)\n {\n ret.add(new ItemStack(item, 1, damageDropped(metadata)));\n }\n }\n return ret;\n }", "@Override\n\tpublic void getOil(ArrayList<Olive> olives) {\n\t\tint oil = 0;\n\t\t\n\t\tfor (Olive olive : olives) {\n\t\t\toil += olive.crush();\n\t\t}\n\t\t\n\t\tsetTotalOil(oil);\n\n\t}", "public java.util.List<PoP> getPopsList() {\n return pops_;\n }", "public List<NoteToken> getElts(){\r\n List<NoteToken> returnList = new ArrayList<NoteToken>();\r\n for (Iterator<Bars> i = BarsList.iterator(); i.hasNext();){\r\n returnList.addAll(i.next().getElts());\r\n }\r\n return returnList;\r\n }", "public long getPriceList() {\r\n return priceList;\r\n }", "public List<PlayerItem> getSpecific(int playerItemId);", "private void getTeam() {\n Set<Integer> set = getRandomNumberSet();\n // clear new team list each time to allow for serial clicks on \"Generate New Random Team\"\n team.clear();\n for (Integer i : set) {\n getPokemon(i);\n }\n }", "public double getPotatoesPrice() {\n return potatoesPrice;\n }", "public List<Equipment> getEquipments() {\n return equipments;\n }", "public ArrayList<Pets> selectCurrentPet(Scanner scanner, Pets currentPet) {\n\n ArrayList<Pets> currentPetList = new ArrayList<>();\n\n try {\n\n Statement statement = conn.createStatement();\n String sqlStatement = \"SELECT * FROM pets WHERE name = \" + \"'\" + scanner.next() + \"'\";\n\n ResultSet rs = statement.executeQuery(sqlStatement);\n\n while (rs.next()) {\n\n // Create new Pet object\n currentPet.setName(rs.getString(\"name\"));\n currentPet.setAnimalType(rs.getString(\"animal_type\"));\n currentPet.setAnimalBreed(rs.getString(\"animal_breed\"));\n currentPet.setDateOfBirth(rs.getString(\"date_of_birth\"));\n currentPet.setGender(rs.getString(\"gender\").charAt(0));\n currentPet.setWeight(rs.getInt(\"weight\"));\n currentPet.setOwner(rs.getString(\"owner\"));\n currentPet.setId(rs.getInt(\"id\"));\n\n// System.out.println(currentPet);\n }\n\n\n } catch (SQLException exception) {\n System.out.println(\"Error getting current pet: \" + exception);\n }\n\n System.out.println();\n if (currentPet.getId() > 0) {\n System.out.println(\"Log In successful!\");\n } else if (currentPet.getId() == 0) {\n System.out.println(\"Hmm.. Seems like this pet hasn't been added yet!\");\n }\n return currentPetList;\n }", "public ArrayOfPetModel getArrayOfPetModel() {\n return localArrayOfPetModel;\n }", "public ArrayList getLecturers();", "@Override\n public List<Player> getPlayers() {\n return new ArrayList<Player>(players);\n }", "public List<Velocity> getVelocitiesForLevel() {\n List<Velocity> listOfVelocities = new ArrayList<>();\n String velocities = this.map.get(\"ball_velocities\");\n // create an array of velocities\n String[] listOfVelocitiesString = velocities.split(\" \");\n int size = listOfVelocitiesString.length;\n // run over all of the possible velocities\n for (int i = 0; i < size; i++) {\n // in every velocity split it to speed and angel\n String[] oneVel = listOfVelocitiesString[i].split(\",\");\n Velocity v = Velocity.fromAngleAndSpeed(Integer.parseInt(oneVel[0]), Integer.parseInt(oneVel[1]));\n // add the veloctiy to the list of velocities\n listOfVelocities.add(v);\n }\n return listOfVelocities;\n }", "private void endPetWalking(SharedPreferences sharedPreferences, @Nullable List<Pet> pets) {\n SharedPreferences.Editor editor = sharedPreferences.edit();\n\n for (Pet pet : user.getPets()) {\n String userPet = getUserPetIdentifier(pet.getName());\n boolean isWalking = sharedPreferences.getBoolean(userPet, false);\n\n if (isWalking) {\n editor.putBoolean(userPet, false);\n\n if (pets != null) {\n pets.add(pet);\n }\n }\n }\n\n editor.apply();\n }", "public List<PetOwnerDTO> getAllPetsOwnerDTO() {\n EntityManager em = emf.createEntityManager();\n Query query = em.createQuery(\"SELECT NEW dto.PetOwnerDTO(p) FROM Pet AS p\");\n return query.getResultList();\n }", "public ArrayList<Pokemon> getOwnedPokemon() {\r\n\t\treturn ownedPokemon;\r\n\t}", "static void buildCatsList(int zipCode, ArrayList<PetModel> pets) {\n\n String zip = \"\" + zipCode;\n String key = System.getenv(\"PETFINDER_KEY\");\n String urlString = \"http://api.petfinder.com/pet.find?key=\" + key + \"&animal=cat&location=\" + zip\n + \"&format=json\";\n\n System.out.println(\"URL to 'get' from: \" + urlString);\n\n URL url = null;\n try {\n url = new URL(urlString);\n } catch (MalformedURLException e) {\n System.out.println(\"URL malformed\");\n }\n HttpURLConnection connection = null;\n try {\n connection = (HttpURLConnection) url.openConnection();\n } catch (IOException e) {\n e.printStackTrace();\n System.out.println(\"oh no\");\n }\n // because we are retrieving...\n try {\n connection.setRequestMethod(\"GET\");\n } catch (ProtocolException e) {\n System.out.println(\"cannot set request method\");\n }\n try {\n connection.connect();\n } catch (IOException e) {\n e.printStackTrace();\n System.out.println(\"ahh\");\n }\n try {\n int responseCode = connection.getResponseCode();\n } catch (IOException e) {\n System.out.println(\"response code failed\");\n }\n\n\n Scanner sc = null;\n try {\n sc = new Scanner(url.openStream());\n } catch (IOException e) {\n e.printStackTrace();\n System.out.println(\"crap\");\n }\n String inline = \"\";\n while (sc.hasNext()) {\n inline += sc.nextLine();\n }\n sc.close();\n\n JSONObject json = new JSONObject(inline);\n json = (JSONObject) json.get(\"petfinder\");\n json = (JSONObject) json.get(\"pets\");\n\n JSONArray json_pets = (JSONArray) json.get(\"pet\");\n for (int i = 0; i < json_pets.length(); i++) {\n PetModel pet = new PetModel();\n JSONObject json_pet = (JSONObject) json_pets.get(i);\n JSONObject json_pet_name = (JSONObject) json_pet.get(\"name\");\n JSONObject json_pet_gender = (JSONObject) json_pet.get(\"sex\");\n JSONObject json_pet_description = (JSONObject) json_pet.get(\"description\");\n JSONObject json_pet_img = (JSONObject) json_pet.get(\"media\");\n\n if (json_pet_img.length() != 0) {\n json_pet_img = (JSONObject) json_pet_img.get(\"photos\");\n JSONArray json_pet_img_arr = (JSONArray) json_pet_img.get(\"photo\");\n\n if (json_pet_img_arr.length() != 0) {\n for (int k = 0; k < json_pet_img_arr.length(); k++) {\n json_pet_img = (JSONObject) json_pet_img_arr.get(k);\n //search for one with better quality...\n //JSONObject json_img_size = (JSONObject) json_pet_img.get(\"@size\");\n if (Objects.equals(json_pet_img.get(\"@size\").toString(), \"x\")) {\n break;\n }\n }\n }\n\n pet.img = json_pet_img.get(\"$t\").toString();\n }\n\n //System.out.println(json_pet_name.get(\"$t\"));\n if (json_pet_name.length() != 0) {\n pet.name = json_pet_name.get(\"$t\").toString();\n }\n if (json_pet_description.length() != 0) {\n pet.description = json_pet_description.get(\"$t\").toString();\n }\n if (json_pet_gender.length() != 0) {\n pet.gender = json_pet_gender.get(\"$t\").toString();\n }\n\n //System.out.println(\"name: \" + pet.name);\n //System.out.println(\"gender: \" + pet.gender);\n //System.out.println(\"description: \" + pet.description);\n\n pets.add(pet);\n }\n }", "Collection<Item> getInventory();", "java.util.List<POGOProtos.Rpc.CombatProto.CombatPokemonProto> \n getReservePokemonList();", "public List<PlayerItem> getAllPlayerItemById(Player player);", "public List<VerbPhrase> getVpList(){\n\t\tSet<NounPhrase> entitySet = this.getEntConsiderPass(\"O\");\n\t\tList<VerbPhrase> vpList = new ArrayList<VerbPhrase>();\n\t\t\n\t\tfor(NounPhrase object : entitySet){\t\t\n\t\t\t//vpList.add(new VerbPhrase(this.getActionStr(), object));\n\t\t\tvpList.add(new VerbPhrase(this.action, object));\n\t\t}\t\t\n\t\treturn vpList;\n\t}" ]
[ "0.7753982", "0.7148992", "0.6947399", "0.6468138", "0.6368956", "0.62451434", "0.6118168", "0.60786813", "0.59863514", "0.59682435", "0.5946662", "0.59155804", "0.59028554", "0.5902453", "0.5866222", "0.58395326", "0.58335966", "0.58231044", "0.5807222", "0.57766306", "0.5763804", "0.56024784", "0.5574677", "0.55641174", "0.5547214", "0.55409414", "0.55129975", "0.54865867", "0.5480272", "0.5440328", "0.543977", "0.54337275", "0.54174787", "0.54168975", "0.54053825", "0.53897274", "0.53831714", "0.5382233", "0.53791034", "0.5378662", "0.53779864", "0.53675926", "0.53503597", "0.534148", "0.5339143", "0.5336858", "0.5324178", "0.5323284", "0.53213394", "0.53099537", "0.53072476", "0.5304894", "0.5295277", "0.52807426", "0.52797633", "0.5277453", "0.5277453", "0.52724737", "0.5267666", "0.52534413", "0.5239914", "0.52364194", "0.52340025", "0.5233624", "0.5232608", "0.52316475", "0.52244246", "0.5222815", "0.52187335", "0.52099675", "0.51964426", "0.51861364", "0.5180956", "0.5179605", "0.5171407", "0.51674324", "0.5165166", "0.5162807", "0.51601696", "0.51584804", "0.51542056", "0.51366633", "0.5126118", "0.51232374", "0.5122166", "0.5108476", "0.5107521", "0.51049286", "0.51012576", "0.50982404", "0.50966215", "0.50858", "0.5075295", "0.50734687", "0.5068495", "0.5066347", "0.5062419", "0.50618255", "0.50590736", "0.50517815" ]
0.7157201
1
Feed a pet, given a player.
private void feed(Player p){ System.out.println("What pet would you like to feed?"); ArrayList<Food> foodlist = p.getFood(); int c = 1; for(Pet pet : p.getPets()){ System.out.println(c + ". " + pet.getPetname()); c++; } int selectedpetindex = getNumber(1, p.getPets().size()); Pet selectedpet = p.getPets().get(selectedpetindex - 1); System.out.println("What food do you want to feed " + selectedpet.getPetname() + " with?"); c = 1; for(Food f : foodlist){ System.out.println(c + ". " + f.getName()); c++; } int foodindex = getNumber(1, foodlist.size()); Food selectedfood = foodlist.get(foodindex); selectedpet.feed(selectedfood); foodlist.remove(foodindex); p.setFood(foodlist); p.setActions(p.getActions() - 1); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public boolean feedPet(String food) {\r\n switch (food) {\r\n case (\"apple\"): {\r\n if ((this.player.getMoney() - apple.getCost()) >= 0) {\r\n player.feed(apple);\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n case (\"honey\"): {\r\n if ((this.player.getMoney() - honey.getCost()) >= 0) {\r\n player.feed(honey);\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n case (\"spinach\"): {\r\n if ((this.player.getMoney() - spinach.getCost()) >= 0) {\r\n player.feed(spinach);\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n case (\"steak\"): {\r\n if ((this.player.getMoney() - steak.getCost()) >= 0) {\r\n player.feed(steak);\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n }\r\n return false;\r\n }", "public void addPets(PetPOJO pet) {\n pets.add(pet);\n }", "public void addPet(VirtualPet pet) {\n\t\tshelterPets.put(pet.name, pet);\n\t}", "public void playOne(VirtualPet player) {\n\t\tplayer.playPet();\n\t}", "public void pet() {\n this.hunger += 1;\n this.mood += 1;\n\n if (!muted) {\n System.out.println(\"pet\\t\\t|\\t*purrr*\");\n }\n }", "public void feedAll() {\n\t\tfor (VirtualPet p : shelterPets.values()) {\n\t\t\tp.feedPet();\n\t\t}\n\t}", "@Override\n\tpublic void apply(final ItemStack scrap, final World world, final EntityPlayer player) {\n\t\tif(player instanceof FakePlayer)\n\t\t\treturn;\n\t\t\n\t\tfinal int count = this.rnd.nextInt(this.maxCount) + 1;\n\t\tfor(int i = 0; i < count; i++) {\n\t\t\tEntityHelper.summon(player, this.type, this.jsonTags);\n\t\t}\n\t}", "public void createPet(Pets pet) {\n\n try {\n\n Statement statement = conn.createStatement();\n String sqlStatement = \"INSERT INTO pets (\" +\n \"name, animal_type, animal_breed, date_of_birth, gender, weight, owner) \" +\n \"VALUES (\" +\n \"'\" + pet.getName() + \"',\" +\n \"'\" + pet.getAnimalType() + \"',\" +\n \"'\" + pet.getAnimalBreed() + \"',\" +\n \"'\" + pet.getDateOfBirth() + \"',\" +\n \"'\" + pet.getGender() + \"',\" +\n +pet.getWeight() + \",\" +\n \"'\" + pet.getOwner() + \"'\" +\n \")\";\n\n int rowsAffected = statement.executeUpdate(sqlStatement);\n\n if (rowsAffected != 0) {\n System.out.println(\"Pet added successfully!\");\n } else {\n System.out.println(\"Sorry.. Something went wrong! Try again.\");\n }\n\n } catch (SQLException exception) {\n System.out.println(\"Error creating a Pet : \" + exception);\n }\n }", "private void play(Player p){\r\n\t\tSystem.out.println(\"What pet would you like to play with?\");\r\n\t\tint c = 1;\r\n\t\tArrayList<Toy> toys = p.getToys();\r\n\r\n\t\tfor(Pet pet : p.getPets()){\r\n\t\t\tSystem.out.println(c + \". \" + pet.getPetname());\r\n\t\t\tc++;\r\n\t\t}\r\n\t\tint selectedpetindex = getNumber(1, p.getPets().size());\r\n\t\tPet selectedpet = p.getPets().get(selectedpetindex - 1);\r\n\t\tSystem.out.println(\"What toy do you want to use to play with \" + selectedpet.getPetname());\r\n\r\n\t\tc = 1;\r\n\t\tfor(Toy t : toys){\r\n\t\t\tSystem.out.println(c + \". \" + t.getName());\r\n\t\t\tc++;\r\n\t\t}\r\n\t\tint toyindex = getNumber(1, toys.size());\r\n\t\tToy selectedtoy = toys.get(toyindex);\r\n\r\n\t\tselectedpet.play(selectedtoy);\r\n\t\tselectedtoy.setDurability(selectedtoy.getDurability() - selectedpet.getRoughness());\r\n\r\n\t\tif(selectedtoy.getDurability() < 1){\r\n\t\t\ttoys.remove(toyindex);\r\n\t\t}else{\r\n\t\t\ttoys.set(toyindex, selectedtoy);\r\n\t\t}\r\n\r\n\t\tp.setToys(toys);\r\n\t\tp.setActions(p.getActions() - 1);\r\n\t}", "public Pet getPet() {\n return pet;\n }", "static public void viewPet(int petId) {\n User user = LocalUserManager.getCurrentUser();\n Pet pet = LocalPetManager.findPet(petId);\n assert pet != null;\n Presenter.showInstruction(\"You see a \"+pet.getPetColour()+\", \"+\n pet.getPetSex()+\" pet named \"+pet.getPetName()+\"\\n\");\n Presenter.showInstruction(pet.getPetName()+\": \"+pet.getGreeting()+\".\\n\");\n while (true) {\n boolean userInput = GameController.getUserYesOrNo(\"Enter 'y' to feed it or 'n' to go back\");\n if (userInput) {\n Presenter.showInstruction(pet.getPetName()+\": Yummy Yummy! Thank you, \" + user.getUsername()+\"\\n\");\n }\n else {\n return;\n }\n }\n }", "void addPerson(Player player);", "private void getPets(){\r\n\t\tfor(Player p : players){\r\n\t\t\tArrayList<Pet> currentpets = new ArrayList<>();\r\n\r\n\t\t\tSystem.out.println(\"How many pets for \" + p.getName() + \": \");\r\n\t\t\tint petnum = getNumber(1,3);\r\n\t\t\tfor(int i = 0; i < petnum; i++){\r\n\t\t\t\tSystem.out.println(\"Pet options are:\");\r\n\t\t\t\tint c = 1; //Counter for which pet, relating to which option\r\n\t\t\t\tfor(Pet option : pets){\r\n\t\t\t\t\tSystem.out.println(c + \". \" + option.getClass().getSimpleName() + \".\");\r\n\t\t\t\t\tc++;\r\n\t\t\t\t}\r\n\t\t\t\tSystem.out.println(\"Please Choose Your Pet With A Number:\");\r\n\t\t\t\tint selected = getNumber(1, 6);\r\n\t\t\t\tPet selectedpet = pets.get(selected - 1);\r\n\t\t\t\tSystem.out.println(\"Please Enter A Name For Your Pet: \");\r\n\t\t\t\tString petname = sc.next();\r\n\t\t\t\tselectedpet.setPetname(petname);\r\n\t\t\t\tSystem.out.println(\"You now have a pet named \" + selectedpet.getPetname());\r\n\t\t\t\tcurrentpets.add(selectedpet);\r\n\t\t\t}\r\n\t\t\tp.setPets(currentpets);\r\n\t\t}\r\n\t}", "public abstract void fruitEffect(Player p);", "@Override\n public void onTake(@Nonnull Player player, @Nonnull ItemStack stack) {\n super.onTake(player, stack);\n }", "@Override\r\n\tpublic void onPlayerHit(Player p) {\n\t\tParUtils.createParticle(Particles.EXPLOSION, loc, 0, 0, 0, 1, 0);\r\n\t\tplaySound(Sound.ENTITY_DRAGON_FIREBALL_EXPLODE,loc,1,1);\r\n\t\t//p.setVelocity(dir.multiply(speed/2));\r\n\t\tdoKnockback(p, caster.getLocation(), 1 );\r\n\t\tdamage(p, 2, caster);\r\n\t}", "void sendPacketToPlayer(Player player, Object packet);", "@Override\n\tpublic void registerPet(PetVO vo) {\n\t\t\n\t}", "static void feedPet() {\r\n\t\tJOptionPane.showMessageDialog(null, \"Your \" + pet + \" is happy and full.\");\r\n\t\thappinessLevel+=3;\r\n\t}", "public static void showParticle(Player p, Location loc, EnumParticle particle, int amount){\n PacketPlayOutWorldParticles pckt = new PacketPlayOutWorldParticles(particle, false, (float) loc.getX(), (float) loc.getY(), (float) loc.getZ(), 0f, 0f, 0f, /*speed*/0f, amount);\n ((CraftPlayer) p).getHandle().playerConnection.sendPacket(pckt);\n }", "@Override\n\tpublic void updatePet(PetVO vo) {\n\t\t\n\t}", "public Prayer(Player player) {\n this.player = player;\n }", "@Override\r\n public void dealCardToPlayer(int dealerDeckPosition, int player, \r\n int plDeckPosition) {\r\n // Get the card from the dealer\r\n Card card = this.dealer.getCard(dealerDeckPosition);\r\n \r\n // Give the card to the player\r\n this.players.get(player).addCard(plDeckPosition, card);\r\n }", "@Override\r\n public void giveCardToPlayer(Card card, int player, int plDeckPosition) {\r\n this.players.get(player).addCard(plDeckPosition, card);\r\n }", "public void attack(Player p){\n p.takeDamage(damage);\n }", "public final void give(final Player player) {\n\t\tplayer.getInventory().addItem(this.getItem());\n\t}", "@ForgeSubscribe(priority = EventPriority.HIGHEST)\n public void onPlayerDrops(PlayerDropsEvent event) {\n if (_PlayerHeads.debug);\n else if (_PlayerHeads.pvp && !event.recentlyHit || _PlayerHeads.dropRates[3] <= 0.0 || _PlayerHeads.random.nextDouble() - 0.005 * (double)event.lootingLevel >= _PlayerHeads.dropRates[3])\n return;\n ItemStack head = new ItemStack(Item.skull, 1, 3);\n head.setTagInfo(\"SkullOwner\", new NBTTagString(\"\", event.entityPlayer.username));\n EntityItem drop = new EntityItem(event.entityPlayer.worldObj, event.entityPlayer.posX, event.entityPlayer.posY, event.entityPlayer.posZ, head);\n drop.delayBeforeCanPickup = 10;\n event.drops.add(drop);\n }", "public void addEntity(Player player) {\n\t\tentities.add(player);\n\t}", "@Override\n\tpublic void onHitPlayer(EntityDamageByEntityEvent e, Player damager, Player victim) {\n\t\t\n\t}", "public void setPet(Pet pet) {\n this.pet = pet;\n Util.getInstance().loadImage(pet.getId(), avatarImageView, false, new com.squareup.picasso.Callback(){\n @Override\n public void onSuccess() {\n\n }\n\n @Override\n public void onError() {\n\n }\n });\n\n idEditText.setText(pet.getId());\n nameEditText.setText(pet.getName());\n femaleButton.setChecked(pet.isFemale());\n switch (pet.getSpecies()) {\n case \"Cat\":\n speciesSpinner.setSelection(0);\n break;\n case \"Dog\":\n speciesSpinner.setSelection(1);\n break;\n case \"Bird\":\n speciesSpinner.setSelection(2);\n break;\n case \"Rabbit\":\n speciesSpinner.setSelection(3);\n break;\n case \"Others\":\n speciesSpinner.setSelection(4);\n break;\n default:\n break;\n\n }\n if(pet.getBirthday() == null){\n birthdayEditText.setText(\"\");\n } else{\n birthdayEditText.setText(Util.getInstance().dateFormatter().format(pet.getBirthday()));\n }\n vetPhoneEditText.setText(pet.getVetPhone());\n vetNameEditText.setText(pet.getVetName());\n medicationsEditText.setText(pet.getMedications());\n chipIdEditText.setText(pet.getChipId());\n chipCompanyEditText.setText(pet.getChipCompany());\n }", "public void setpetID(String petID){\n this.petID = petID;\n }", "public void serveFood() {\r\n System.out.println(\"Serving food from \" + name + \" is a \" + type + \" restaurant\");\r\n }", "@Transactional\n\tpublic PetDTO createPet(PetDTO petDTO) {\n\t\tUser user = validateParametersAdd(petDTO);\n\t\tPet pet = new Pet();\n\t\tpetSetters(pet, petDTO);\n\t\tif (petDTO.getAdvertisement() != null\n\t\t\t\t&& advertisementRepository.findAdvertisementById(petDTO.getAdvertisement()) != null) {\n\t\t\tpet.setAdvertisement(advertisementRepository.findAdvertisementById(petDTO.getAdvertisement()));\n\t\t}\n\t\tSet<PetDTO> allUserPets = getPetsByUser(petDTO.getUserName());\n\t\tallUserPets.add(petDTO);\n\n\t\tuser.getPets().add(pet);\n\n\t\tpetRepository.save(pet);\n\t\tuserRepository.save(user);\n\t\tpetDTO.setId(pet.getId());\n\n\t\treturn petDTO;\n\t}", "public void addPlayer(Player player) {\n //int id = Repository.getNextUniqueID();\n this.player = player;\n }", "@Override\n public void consume(Player p) {\n if(boostType.equals(\"force\")){\n p.setStrength(p.getStrength() + 1);\n }else if(boostType.equals(\"life\")){\n p.modifyLife(1);\n }else if(boostType.equals(\"force+\")){\n p.setStrength(p.getStrength() + 2);\n }else if(boostType.equals(\"life+\")) {\n p.modifyLife(2);\n }else if(boostType.equals(\"force++\")){\n p.setStrength(p.getStrength() + 3);\n }else if(boostType.equals(\"life++\")) {\n p.modifyLife(3);\n }\n Thread t = new Thread(this);\n t.start();\n }", "@Override\n public void onPetLoaded(Pet pet) {\n if (mCachedPets == null) {\n mCachedPets = new LinkedHashMap<>();\n }\n mCachedPets.put(pet.getId(), pet);\n callback.onPetLoaded(pet);\n }", "void sendPacket(Player player, Object packet);", "@Override\r\n\tpublic void onPlayerHit(Player p) {\n\t\t\r\n\t}", "@Override\r\n\tpublic void onPlayerHit(Player p) {\n\t\t\r\n\t}", "public void cardToOne(ClientThread player) {\n\t\tCard thisCard = deck.draw();\n\t\tplayer.clientCards.add(thisCard);\n\t\tplayer.send(new Package(\"CARD\",thisCard));\n\t\tview.writeLog(player.name +\" draws: \" + thisCard.toString());\n\t}", "@Override\r\n\tpublic void ThrowPotion(Player arg0, Player arg1) {\n\t\t\r\n\t}", "@Override\r\n\tpublic void ThrowPotion(Player arg0, Player arg1) {\n\t\t\r\n\t}", "boolean addSteam(ItemStack me, int amount, EntityPlayer player);", "public void addVps(Player player) {\n }", "static void pickup(Player player, String what) {\n if (player.getLocation().contains(what)) {\n Thing thing = player.pickup(what);\n if (thing != null) {\n System.out.println(\"You now have \" + thing);\n }\n else {\n System.out.println(\"You can't carry that. You may need to drop something first.\");\n }\n }\n else {\n System.out.println(\"I don't see a \" + what);\n }\n }", "@Override\n public void applyParticleAtAttacker(int type, Entity target, float[] vec)\n {\n \t\tTargetPoint point = new TargetPoint(this.dimension, this.posX, this.posY, this.posZ, 64D);\n \n \t\tswitch (type)\n \t\t{\n \t\tcase 1: //light cannon\n \t double shotHeight = 1.85D;\n \t \n \t if(this.isRiding() && this.getRidingEntity() instanceof BasicEntityMount)\n \t {\n \t \tshotHeight = 0.8D;\n \t }\n \t \n \t\t\tCommonProxy.channelP.sendToAllAround(new S2CSpawnParticle(this, target, shotHeight, 0D, 0D, 0, true), point);\n \t\tbreak;\n \t\tcase 2: //heavy cannon\n \t\tcase 3: //light aircraft\n \t\tcase 4: //heavy aircraft\n\t\tdefault: //melee\n\t\t\tCommonProxy.channelP.sendToAllAround(new S2CSpawnParticle(this, 0, true), point);\n\t\tbreak;\n \t\t}\n \t}", "public static void teleportPlayer(GamePlayer player, List<Location> spawnpoint) {\r\n\t\tRandom rand = new Random();\r\n\t\tLocation spawn = spawnpoint.get(rand.nextInt(spawnpoint.size()));\r\n\t\t\r\n\t\tplayer.getPlayer().setSaturation(100000);\r\n\t\tplayer.getPlayer().setHealth(20);\r\n\t\tplayer.getPlayer().teleport(spawn);\r\n\t\tgiveStuff(player);\r\n\t}", "public FoodAmountAndPet(int foodAmount, Pet pet) {\n requireNonNull(pet);\n checkArgument(isValidFoodAmount(foodAmount), MESSAGE_AMOUNT_CONSTRAINTS);\n this.foodAmount = foodAmount;\n this.pet = pet;\n }", "protected void handleFeeding(AbstractHorse abstractHorse, SavedHorse savedHorse, Player player) {\n // Handle health training only if the event was not cancelled.\n ItemStack foodItem = player.getEquipment().getItemInMainHand();\n int nuggetValue = getNuggetValue(foodItem);\n if (CONFIG.DEBUG_EVENTS && savedHorse.isDebug()) {\n getLogger().info(\"Nugget value: \" + nuggetValue);\n }\n\n if (nuggetValue > 0) {\n // For undead horses, they take the food right away.\n if (Util.isUndeadHorse(abstractHorse)) {\n foodItem.setAmount(foodItem.getAmount() - 1);\n player.getEquipment().setItemInMainHand(foodItem);\n consumeGoldenFood(savedHorse, abstractHorse, nuggetValue, player);\n\n // And let's simulate healing with golden food too.\n // Golden apples (both types) heal (10); carrots heal 4.\n int foodValue = (foodItem.getType() == Material.GOLDEN_APPLE) ? 10 : 4;\n AttributeInstance maxHealth = abstractHorse.getAttribute(Attribute.GENERIC_MAX_HEALTH);\n abstractHorse.setHealth(Math.min(maxHealth.getValue(), abstractHorse.getHealth() + foodValue));\n\n } else {\n // For other types of horses, detect whether the food\n // was consumed by running a task in the next tick.\n Bukkit.getScheduler().runTaskLater(this, new GoldConsumerTask(\n player, abstractHorse, foodItem, nuggetValue, player.getInventory().getHeldItemSlot()), 0);\n }\n } else if (foodItem != null && foodItem.getType() == Material.WATER_BUCKET) {\n // Handle rehydration.\n if (!savedHorse.isFullyHydrated()) {\n player.getEquipment().setItemInMainHand(new ItemStack(Material.BUCKET, 1));\n savedHorse.setHydration(savedHorse.getHydration() + EasyRider.CONFIG.BUCKET_HYDRATION);\n Location loc = abstractHorse.getLocation();\n loc.getWorld().playSound(loc, Sound.ENTITY_GENERIC_DRINK, SoundCategory.NEUTRAL, 2.0f, 1.0f);\n }\n\n if (savedHorse.isFullyHydrated()) {\n player.sendMessage(ChatColor.GOLD + savedHorse.getMessageName() + \" is no longer thirsty.\");\n } else {\n player.sendMessage(ChatColor.GOLD + savedHorse.getMessageName() + \" is still thirsty.\");\n }\n }\n }", "public void setPetId(java.lang.String param) {\n localPetIdTracker = true;\n\n this.localPetId = param;\n }", "public abstract void fire(Player holder);", "public void adoptPet(String removedPet) {\n\t\tshelterPets.remove(removedPet);\n\t}", "public static void main(String[] args) {\n\t\tPet cat = new Cat(false,4);\n\t\tcat.run(getPetName(cat));\n\t\tPet parrot = new Parrot(true,2);\n\t\tparrot.run(getPetName(parrot));\n\t\t\n\t\tParrot pr = (Parrot) parrot;\n\t\tpr.fly(getPetName(pr));\n\t\t\n\t\tPet pet = pr;\n\t\n\t}", "@PostMapping(\"/pets\")\n public ResponseEntity<Pet> createPet(@RequestBody Pet pet) throws URISyntaxException {\n log.debug(\"REST request to save Pet : {}\", pet);\n if (pet.getId() != null) {\n throw new BadRequestAlertException(\"A new pet cannot already have an ID\", ENTITY_NAME, \"idexists\");\n }\n Pet result = petService.save(pet);\n return ResponseEntity.created(new URI(\"/api/pets/\" + result.getId()))\n .headers(HeaderUtil.createEntityCreationAlert(ENTITY_NAME, result.getId().toString()))\n .body(result);\n }", "public VirtualPet getPet(String name) {\n\t\treturn shelterPets.get(name);\n\n\t}", "public void petSpeak(ArrayList<Pet> petList) {\n System.out.println(\"Pets say: \");\n for (Pet each : petList) {\n System.out.println(each.getName() + \" says \" + each.speak());\n }\n System.out.println();\n }", "@Override\n public boolean isPet(Entity entity) {\n return entity.hasMetadata(\"pet\");\n }", "@PostMapping\n public PetDTO savePet(@RequestBody PetDTO petDTO) {\n Customer customer = null;\n if ((Long) petDTO.getOwnerId() != null) {\n customer = customerService.getCustomerById(petDTO.getOwnerId());\n }\n Pet pet = ConvertService.convertDTOToPetEntity(petDTO);\n pet.setCustomer(customer);\n\n pet = petService.save(pet);\n petDTO.setId(pet.getId());\n\n return petDTO;\n }", "public Animal feedPetWithCannedFoodAllowed(Animal pet, Set<String> recommendations) {\n recommendations.forEach(food -> pet.feed(food));\n return pet;\n }", "public void thankYouVet(){\n System.out.println(\"PetOwner says ... thank you Vet!\");\n }", "public void talking(){\n System.out.println(\"PetOwner : *says something*\");\n }", "public void take(Thing t)\r\n {\r\n if (t==null)\r\n System.out.println(\"That item does not exist in this room\");\r\n \t\r\n \telse if (t.getOwner().equals(this))\r\n \t\tSystem.out.println(this.getName() + \" is already carrying that!\");\r\n \r\n \telse\r\n \t{\r\n \t\tif (this.getRoom().equals(t.getOwner()))\r\n \t\t{\r\n \t\t\tif (t.getType()==Equip.WEAPON)\r\n \t\t\t say(\"I took \" + t.getName() + \" which has \" + ((Equip)t).getRating() + \" ATK\");\r\n \t\t\telse if (t.getType()==Equip.ARMOR)\r\n \t\t\t say(\"I took \" + t.getName() + \" which has \" + ((Equip)t).getRating() + \" DEF\");\r\n \t\t\telse if (t.getType()==Consume.POTION)\r\n \t\t\t say(\"I took \" + t.getName() + \" which has \" + ((Consume)t).getRating() + \" Healing\");\r\n \t\t\telse \r\n \t\t\t say(\"I took \" + t.getName() + \" from \" + room.getName());\r\n \t\t}\r\n \t\tt.changeOwner(this);\r\n \t}\r\n }", "public void examine (Player player) {\n\t\tString desc = getType().getDescription()+\" (id=\"+id+\", amount=\"+amount+\")\";\n\t\tplayer.getDispatcher().sendGameMessage(desc);\n\t\tint value = Virtue.getInstance().getExchange().lookupPrice(id);\n\t\tif (value != -1) {\n\t\t\tplayer.getDispatcher().sendGameMessage(\"This item is worth: \"+StringUtility.formatNumber(value)\n\t\t\t\t\t+\"gp on the Grand Exchange.\");\n\t\t}\n\t}", "@Test\n\tpublic void testTheTickMethodForEachPet() {\n\t\tVirtualPetShelter testPetShelter = new VirtualPetShelter();\n\t\ttestPetShelter.addPet(\"Rusty\", new VirtualPet(\"Rusty\", \"He doesn't get hungry, he's Dead!\", 5, 30, 20));\n\t\ttestPetShelter.addPet(\"Grazer\", new VirtualPet(\"Grazer\", \"She cant leave.. she's dead too!\", 10, 20, 30));\n\t\ttestPetShelter.tick(); // I created a tick, eclipse erred and asked me to create tick in VPS\n\t\tAssert.assertEquals(32, testPetShelter.virtualPets.get(\"Rusty\").boredom);\n\t\tAssert.assertEquals(22, testPetShelter.virtualPets.get(\"Grazer\").boredom);\n\t}", "public void giveAndTake(Player a){\n\t\tString type = typetoString();\r\n\t\tint totalDice = a.getDice1() + a.getDice2(), purpleRent = owner.numPurple(), lightGreenRent = owner.numLightGreen(), violetRent = owner.numViolet(), orangeRent = owner.numOrange(), redRent = owner.numRed(), yellowRent = owner.numYellow(), darkGreenRent = owner.numDarkGreen(), darkBlueRent = owner.numDarkBlue(), utilitiesRent = owner.numUtilities(), railRent = owner.numRails(), modRent = 0;\r\n\t\tif(type.equals(\"PURPLE\")){\r\n\t\t\tif(purpleRent == 1){\r\n\t\t\t\tmodRent = rent;\r\n\t\t\t}else if(purpleRent == 2){\r\n\t\t\t\t\tmodRent = (rent * 2) + houseRent;\r\n\t\t\t\t\t\tif(numHouses == -1)\r\n\t\t\t\t\t\t\tmodRent = rent * 2;\r\n\t\t\t\t\t\telse\r\n\t\t\t\t\t\t\tmodRent = (houses[numHouses].getRent());\r\n\t\t\t}\r\n\t\t}\r\n\t\tif(type.equals(\"LIGHTGREEN\")){\r\n\t\t\tif(lightGreenRent == 1 || lightGreenRent == 2){\r\n\t\t\t\tmodRent = rent;\r\n\t\t\t}else if(lightGreenRent == 3){\r\n\t\t\t\t\tmodRent = (rent * 2) + houseRent;\r\n\t\t\t\t\t\tif(numHouses == -1)\r\n\t\t\t\t\t\t\tmodRent = rent * 2;\r\n\t\t\t\t\t\telse\r\n\t\t\t\t\t\t\tmodRent = (houses[numHouses].getRent());\r\n\t\t\t}\r\n\t\t}\r\n\t\tif(type.equals(\"VIOLET\")){\r\n\t\t\tif(violetRent == 1 || violetRent == 2){\r\n\t\t\t\tmodRent = rent;\r\n\t\t\t}else if(violetRent == 3){\r\n\t\t\t\t\tmodRent = (rent * 2) + houseRent;\r\n\t\t\t\t\t\tif(numHouses == -1)\r\n\t\t\t\t\t\t\tmodRent = rent * 2;\r\n\t\t\t\t\t\telse\r\n\t\t\t\t\t\t\tmodRent = (houses[numHouses].getRent());\r\n\t\t\t}\r\n\t\t}\r\n\t\tif(type.equals(\"ORANGE\")){\r\n\t\t\tif(orangeRent == 1 || orangeRent == 2){\r\n\t\t\t\tmodRent = rent;\r\n\t\t\t}else if(orangeRent == 3){\r\n\t\t\t\t\tmodRent = (rent * 2) + houseRent;\r\n\t\t\t\t\t\tif(numHouses == -1)\r\n\t\t\t\t\t\t\tmodRent = rent * 2;\r\n\t\t\t\t\t\telse\r\n\t\t\t\t\t\t\tmodRent = (houses[numHouses].getRent());\r\n\t\t\t}\r\n\t\t}\r\n\t\tif(type.equals(\"RED\")){\r\n\t\t\tif(redRent == 1 || redRent == 2){\r\n\t\t\t\tmodRent = rent;\r\n\t\t\t}else if(redRent == 3){\r\n\t\t\t\t\tmodRent = (rent * 2) + houseRent;\r\n\t\t\t\t\t\tif(numHouses == -1)\r\n\t\t\t\t\t\t\tmodRent = rent * 2;\r\n\t\t\t\t\t\telse\r\n\t\t\t\t\t\t\tmodRent = (houses[numHouses].getRent());\r\n\t\t\t}\r\n\t\t}\r\n\t\tif(type.equals(\"YELLOW\")){\r\n\t\t\tif(yellowRent == 1 || yellowRent == 2){\r\n\t\t\t\tmodRent = rent;\r\n\t\t\t}else if(yellowRent == 3){\r\n\t\t\t\t\r\n\t\t\t\t\tmodRent = (rent * 2) + houseRent;\r\n\t\t\t\t\r\n\t\t\t\t\t\tif(numHouses == -1)\r\n\t\t\t\t\t\t\tmodRent = rent * 2;\r\n\t\t\t\t\t\telse\r\n\t\t\t\t\t\t\tmodRent = (houses[numHouses].getRent());\r\n\t\t\t}\r\n\t\t}\r\n\t\tif(type.equals(\"DARKGREEN\")){\r\n\t\t\tif(darkGreenRent == 1 || darkGreenRent == 2){\r\n\t\t\t\tmodRent = rent;\r\n\t\t\t}else if(darkGreenRent == 3){\r\n\t\t\t\t\tmodRent = (rent * 2) + houseRent;\r\n\t\t\t\t\t\tif(numHouses == -1)\r\n\t\t\t\t\t\t\tmodRent = rent * 2;\r\n\t\t\t\t\t\telse\r\n\t\t\t\t\t\t\tmodRent = (houses[numHouses].getRent());\r\n\t\t\t}\r\n\t\t}\r\n\t\tif(type.equals(\"DARKBLUE\")){\r\n\t\t\tif(darkBlueRent == 1){\r\n\t\t\t\tmodRent = rent;\r\n\t\t\t}else if(darkBlueRent == 2){\r\n\t\t\t\t\tmodRent = (rent * 2) + houseRent;\r\n\t\t\t\t\t\tif(numHouses == -1)\r\n\t\t\t\t\t\t\tmodRent = rent * 2;\r\n\t\t\t\t\t\telse\r\n\t\t\t\t\t\t\tmodRent = (houses[numHouses].getRent());\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t}\r\n\t\tif(type.equals(\"UTILITIES\")){\r\n\t\t\tif(utilitiesRent == 1){\r\n\t\t\t\tmodRent = 4 * totalDice;\r\n\t\t\t}else if(utilitiesRent == 2){\r\n\t\t\t\tmodRent = 10 * totalDice;\r\n\t\t\t}\r\n\t\t}\r\n\t\tif(type.equals(\"RAILROAD\")){\r\n\t\t\tif(railRent == 1){\r\n\t\t\t\tmodRent = rent;\r\n\t\t\t}else if(railRent == 2){\r\n\t\t\t\tmodRent = rent * 2;\r\n\t\t\t}else if(railRent == 3){\r\n\t\t\t\tmodRent = rent * 4;\r\n\t\t\t}else if(railRent == 4){\r\n\t\t\t\tmodRent = rent * 8;\r\n\t\t\t}\r\n\t\t}\r\n\t\tSystem.out.println(a.returnName()+\" has paid $\"+modRent+\" to \"+owner.returnName());\r\n\t\ta.subtractMoney(modRent);\r\n\t\towner.addMoney(modRent);\r\n\t}", "public void onBetPlaced(Bet bet);", "@PostMapping(\"person/{personId}/pets\")\n\tpublic PetModel createComment(@PathVariable (value = \"personId\") Long personId,\n\t\t\t@Valid @RequestBody PetModel pet) {\n\t\treturn personRepo.findById(personId).map(PersonModel -> {\n\t\t\tpet.setPerson(PersonModel);\n\t\t\treturn petRepo.save(pet);\n\t\t}).orElseThrow(() -> new ResourceNotFoundException(\"Person\", \"id\", pet));\n\t}", "@Override\r\n\tpublic void onPlayerHit(Player p) {\n\r\n\t}", "public void placeBets(){\n System.out.println();\n System.out.println(\"Let's place your bet!\");\n System.out.println();\n for(Player player: players){\n player.placeBet(minBet, maxBet);\n }\n System.out.println();\n }", "public static void teleport(PlayerEntity player, BlockPos pos, int dim) {\n teleport(player, pos, dim, p -> {\n });\n }", "boolean placeBet(Player player, int bet);", "public void feed() {\n\t\tif (health + 20 > 100) {\n\t\t\thealth = 100;\n\t\t} else {\n\t\t\thealth += 20;\n\t\t}\n\t}", "public void action(Player myPlayer)\n {\n if (getNbUtilisation() == 0) {\n System.out.println(\"Not possible\");\n } else {\n int nHealthy = getPointsHealthy();\n myPlayer.addLifePoints(nHealthy);\n\n }\n }", "private void playOneTurnWithPlayer(Player player, RolledDice rolledDice) throws NotEnoughMoneyException {\n int position = player.increasePosition(rolledDice.getValue() - 1, fields.size());\n Field field = fields.get(position);\n field.playerStepped(player);\n //System.out.println(player);\n }", "public static void main(String[] args) {\n\n Pet pet = new Pet(\"Larry\",5) {\n @Override\n public void say() {\n System.out.println(\"wow, wow, wow\");\n }\n };\n System.out.println(pet);\n\n pet.say();\n // ((Cat) pet).getPredator();---> преобразовал тип pet в cat ---> можно, но нельзя\n\n }", "public void shoot(Point p, Graphics g, Player player){\r\n if(p.getX() > getXCoord()-20){ //not sure if -20 needed (it is to make cetner by the shoulder of arm)\r\n setFacing(1);\r\n } else{\r\n setFacing(0);\r\n }\r\n this.setAttackSpeedTimer(this.getAttackSpeedTimer() + 1);\r\n if(this.getAttackSpeedTimer() == this.getAttackSpeed()){\r\n\t\t Bullet bullet = new Bullet(this.getXCoord(), \r\n\t\t\t\t\t this.getYCoord(), this.getFacing(), g, findAngle(p), player);\r\n\t\t\t\t\t bullet.setAttack(50);\r\n\t\t bullet.setMouseY(this.getMouseY());\r\n\t\t bullet.setMouseX(this.getMouseX());\r\n\t\t bullet.setMouseAngle(this.getMouseAngle());\r\n\t \t bullet.setPlayerDirection(this.getPlayerDirection());\r\n\t\t this.addProjectile(bullet);\r\n\t\t this.setAttackSpeedTimer(0);\r\n\t\t //System.out.println(findAngle(p)*180/Math.PI);\r\n\t\t this.playSound();\r\n }\r\n }", "private void Deal(Player player, Dealer dealer) {\n\n //Adds the top card of the deck to each player's hand 1 at a time.\n for (int i = 0; i < 2; i++) {\n player.getHand().add(player.TakeTopCard(deck));\n dealer.getHand().add(dealer.TakeTopCard(deck));\n }\n //Displays the top card of the dealer's hand\n dealer.ShowTopCard(dealer.getHand());\n }", "private void insertPet() {\n\n // Create a ContentValues object where column names are the keys,\n // and Toto's pet attributes are the values.\n ContentValues values = new ContentValues();\n values.put(PetEntry.COLUMN_PET_NAME, \"Toto\");\n values.put(PetEntry.COLUMN_PET_BREED, \"Terrier\");\n values.put(PetEntry.COLUMN_PET_GENDER, PetEntry.GENDER_MALE);\n values.put(PetEntry.COLUMN_PET_WEIGHT, 7);\n\n // Insert a new row for Toto in the database, returning the ID of that new row.\n // The first argument for db.insert() is the pets table name.\n // The second argument provides the name of a column in which the framework\n // can insert NULL in the event that the ContentValues is empty (if\n // this is set to \"null\", then the framework will not insert a row when\n // there are no values).\n // The third argument is the ContentValues object containing the info for Toto.\n Uri newUri=getContentResolver().insert(PetEntry.CONTENT_URI,values);\n if (newUri == null) {\n // If the row ID is -1, then there was an error with insertion.\n Toast.makeText(this, \"Error with saving pet\", Toast.LENGTH_SHORT).show();\n } else {\n // Otherwise, the insertion was successful and we can display a toast with the row ID.\n Toast.makeText(this, \"Pet saved with row id: \" + newUri, Toast.LENGTH_SHORT).show();\n }\n }", "public void tag(Player taggedplayer, Player taggerplayer) {\n \t\tIterator<PearlTag> i = tags.iterator();\n \t\twhile (i.hasNext()) {\n \t\t\tPearlTag tag = i.next();\n \t\t\tif (tag.getTaggedPlayer() == taggedplayer) {\n \t\t\t\ti.remove();\n \t\t\t\ttagEvent(tag, PearlTagEvent.Type.SWITCHED, taggerplayer);\n \t\t\t\tbreak;\n \t\t\t}\n \t\t}\n \t\t\n \t\t// then, make the tag and generate a new tag event\n \t\tlong expires = getNowTick() + expiresticks;\n \t\tPearlTag tag = new PearlTag(taggedplayer, taggerplayer, expires);\n \t\ttags.add(tag);\n \t\ttagEvent(tag, PearlTagEvent.Type.NEW);\n \t\t\n\t\t// schedule the expire task\n\t\tscheduleExpireTask();\n \t}", "public void spawnParticle ( Particle particle , Location location , int count ) {\n\t\thandleOptional ( ).ifPresent ( handle -> {\n\t\t\tof ( particle ).display ( location , 0.0F , 0.0F , 0.0F , 1.0F , count , null , handle );\n\t\t} );\n\t}", "public void buy(Player p, TradeGood good, Planet planet, int numGoods) {\n // decrement money and add to cargoArr\n p.setCredits(p.getCredits() - numGoods*calcPrice(good, planet));\n for(int i = 0; i < numGoods; i++) {\n p.getShip().addCargo(good);\n }\n }", "public final void give(final Player player, final int slot) {\n\t\tplayer.getInventory().setItem(slot, this.getItem());\n\t}", "void doAction(Player player);", "public void sell(Player p, TradeGood good, Planet planet, int numGoods) {\n // increment money and remove from cargoArr\n p.setCredits(p.getCredits() + numGoods*calcPrice(good, planet));\n// for(int i = 0; i < numGoods; i++) {\n// p.getShip().sellCargo(good, numGoods);\n// }\n p.getShip().sellCargo(good, numGoods);\n }", "public void spawnParticle ( Particle particle , Location location , int count , double offsetX , double offsetY ,\n\t\t\tdouble offsetZ , double extra ) {\n\t\thandleOptional ( ).ifPresent ( handle -> {\n\t\t\tof ( particle ).display ( location ,\n\t\t\t\t\t\t\t\t\t ( float ) offsetX , ( float ) offsetY , ( float ) offsetZ ,\n\t\t\t\t\t\t\t\t\t 1.0F , count , null , handle );\n\t\t} );\n\t}", "private void harvestProduction(Player player) {\n player.incrementFunds(calculatePotentialProduction(player));\n eventListener.addEventObject(new PlayerEvent(player.getPlayerName(),EventNamesConstants.FundsIncrement));\n }", "public static void main(String[] args) {\n Person p = new Person();\n Dog dog = new Dog();\n p.feed(dog);\n dog.swim();\n\n Frog frog = new Frog();\n p.feed(frog);\n frog.swim();\n\n Sheep sheep = new Sheep();\n p.feed(sheep);\n\n }", "public void allotCard(Player p_player) {\n Card l_Card = new Card();\n Random l_RandomNumber = new Random();\n l_Card.setD_CardType(l_Card.TYPES[l_RandomNumber.nextInt(l_Card.TYPES.length)]);\n p_player.addCard(l_Card);\n Console.displayMsg(\"Player \" + p_player.getD_Name() + \" has received \" + l_Card.getD_CardType() + \" card!\");\n }", "@Override\n\tpublic void onPacketSending(PacketEvent event) {\n\t\t//requires updating to the hooked entity id field on http://wiki.vg/Entities#FishingHook\n\t\tfinal int HOOK_ENTITYID_FIELD = 6;\n\t\t\n\t\tif (event.getPacketType() != PacketType.Play.Server.ENTITY_METADATA) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tPacketContainer container = event.getPacket();\n\t\t// Is this a fish hook?\n\t\tint entId = container.getIntegers().read(0);\n\t\tFishHook hook = hooks.getIfPresent(entId);\n\t\t\n\t\tif (hook == null) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// See if this hook has hooked something\n\t\tList<?> dataWatcherItems = container.getSpecificModifier(List.class).read(0);\n\t\tIterator<?> it = dataWatcherItems.iterator();\n\t\twhile (it.hasNext()) {\n\t\t\tDataWatcher.Item<?> item = (DataWatcher.Item<?>)it.next();\n\t\t\tif (item.a().a() == HOOK_ENTITYID_FIELD) {\n\t\t\t\t// This hook has hooked something\n\t\t\t\t//.b() returns the actual item we are watching....\n\t\t\t\tint targetId = (Integer)item.b() - 1;\n\t\t\t\tHumanEntity hookedPlayer = getPlayer(event.getPlayer().getWorld(), targetId);\n\t\t\t\t\n\t\t\t\tif (hookedPlayer != null) {\n\t\t\t\t\t// It hooked a player\n\t\t\t\t\t// Can this player be hooked?\n\t\t\t\t\tif (!(hookedPlayer instanceof Player) || hookedPlayer.hasPermission(\"pandora.movement.nohook\")) {\n\t\t\t\t\t\t// Remove hook status\n\t\t\t\t\t\tit.remove();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (dataWatcherItems.isEmpty()) {\n\t\t\tevent.setCancelled(true);\n\t\t}\n\t}", "public void use(Player player) {\n\n\t}", "public PetMarshallerWorker(final PetMarshaller petMarshaller, final Pet pet) {\n this.pet = pet;\n this.petMarshaller = petMarshaller;\n }", "public static boolean spellPullEntityToPlayer(EntityPlayer caster,\r\n\t\t\tBlockPos pos, EnumFacing face, Vec3d hitVec)\r\n\t{\r\n\t\tif(pos == null)\r\n\t\t{\r\n\t\t\tWorld world = caster.worldObj;\r\n\t\t\tVec3d lookingAt = caster.getLookVec();\r\n\t\t\tdouble accelX = lookingAt.xCoord;\r\n\t\t\tdouble accelY = lookingAt.yCoord;\r\n\t\t\tdouble accelZ = lookingAt.zCoord;\r\n\t\t\tEntitySpellPull spellLightningBolt = new EntitySpellPull(world,\r\n\t\t\t\t\tcaster, accelX, accelY, accelZ,\r\n\t\t\t\t\tcaster.getPosition());\r\n\t\t\tworld.spawnEntityInWorld(spellLightningBolt);\r\n\t\t\tworld.updateEntities();\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "@Override\r\n\tpublic void onEntityHit(LivingEntity ent) {\n\t\tParUtils.createParticle(Particles.EXPLOSION, loc, 0, 0, 0, 1, 0);\r\n\t\tplaySound(Sound.ENTITY_DRAGON_FIREBALL_EXPLODE,loc,1,1);\r\n\t\tent.setVelocity(dir.multiply(speed));\r\n\t\tdamage(ent, 2, caster);\r\n\t}", "void feed (int amount);", "public void spawnParticle ( Particle particle , Location location , int count ,\n\t\t\tdouble offsetX , double offsetY , double offsetZ ) {\n\t\thandleOptional ( ).ifPresent ( handle -> {\n\t\t\tof ( particle ).display ( location ,\n\t\t\t\t\t\t\t\t\t ( float ) offsetX , ( float ) offsetY , ( float ) offsetZ ,\n\t\t\t\t\t\t\t\t\t 1.0F , count , null , handle );\n\t\t} );\n\t}", "@Override\n public void hitFeedBack(boolean hit, Fleet enemyShips) {\n this.hit = hit;\n }", "public void spawnItemStack(ItemStack stack, Point3d point){\r\n\t\tworld.spawnEntity(new EntityItem(world, point.x, point.y, point.z, stack));\r\n\t}", "public void setPetName(java.lang.String param) {\n localPetNameTracker = true;\n\n this.localPetName = param;\n }", "public abstract BossBar addPlayer(UUID player);", "public Pet getPet(String name) {\n\t\treturn getPet(name, false);\n\t}" ]
[ "0.6375122", "0.6091629", "0.59282523", "0.586873", "0.56481016", "0.55996543", "0.5595897", "0.5579275", "0.5513693", "0.54844326", "0.5395976", "0.5338195", "0.53216285", "0.5259343", "0.5247835", "0.52366173", "0.5208046", "0.5187004", "0.5185213", "0.51795787", "0.51603764", "0.515912", "0.51271814", "0.51190555", "0.51136667", "0.51051825", "0.50801796", "0.50625795", "0.5054128", "0.50438654", "0.50422335", "0.5018303", "0.50081515", "0.5007729", "0.5007135", "0.50038296", "0.5003064", "0.49968997", "0.49968997", "0.4989289", "0.49864367", "0.49864367", "0.49724957", "0.49717638", "0.49673024", "0.49653733", "0.49565375", "0.4949535", "0.4945692", "0.49244055", "0.49214187", "0.4915327", "0.49124935", "0.49085024", "0.49038953", "0.49001238", "0.48958433", "0.48936787", "0.48932117", "0.48894513", "0.48750466", "0.48656943", "0.4861666", "0.48595297", "0.48586354", "0.48555824", "0.48489267", "0.48406005", "0.48403344", "0.48203424", "0.48098698", "0.48004818", "0.4798592", "0.47932574", "0.47913435", "0.47890773", "0.4782846", "0.47811404", "0.47731918", "0.4771712", "0.4769931", "0.47577947", "0.47546384", "0.47545537", "0.47531295", "0.47510853", "0.47492167", "0.47463137", "0.47408238", "0.4732088", "0.47284347", "0.4725456", "0.47219548", "0.47204754", "0.47184473", "0.47175398", "0.47156045", "0.47144416", "0.47120434", "0.47119588" ]
0.73928124
0
Play with a pet.
private void play(Player p){ System.out.println("What pet would you like to play with?"); int c = 1; ArrayList<Toy> toys = p.getToys(); for(Pet pet : p.getPets()){ System.out.println(c + ". " + pet.getPetname()); c++; } int selectedpetindex = getNumber(1, p.getPets().size()); Pet selectedpet = p.getPets().get(selectedpetindex - 1); System.out.println("What toy do you want to use to play with " + selectedpet.getPetname()); c = 1; for(Toy t : toys){ System.out.println(c + ". " + t.getName()); c++; } int toyindex = getNumber(1, toys.size()); Toy selectedtoy = toys.get(toyindex); selectedpet.play(selectedtoy); selectedtoy.setDurability(selectedtoy.getDurability() - selectedpet.getRoughness()); if(selectedtoy.getDurability() < 1){ toys.remove(toyindex); }else{ toys.set(toyindex, selectedtoy); } p.setToys(toys); p.setActions(p.getActions() - 1); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void playOne(VirtualPet player) {\n\t\tplayer.playPet();\n\t}", "public void pet() {\n this.hunger += 1;\n this.mood += 1;\n\n if (!muted) {\n System.out.println(\"pet\\t\\t|\\t*purrr*\");\n }\n }", "public void talking(){\n System.out.println(\"PetOwner : *says something*\");\n }", "@Override\n public void play(Puppy puppy) {\n System.out.println(\"The puppy is asleep enjoying its wonderful dreams, it currently does not have the desire to play with you right now.\");\n }", "public void play() {\r\n\t\tSystem.out.println(\"Playing Cricket with ball and bat\");\r\n\t}", "public void play() {\n\t\tSystem.out.println(\"ting.. ting...\");\n\t}", "public void petSpeak(ArrayList<Pet> petList) {\n System.out.println(\"Pets say: \");\n for (Pet each : petList) {\n System.out.println(each.getName() + \" says \" + each.speak());\n }\n System.out.println();\n }", "public boolean playPet(String toy) {\r\n switch (toy) {\r\n case (\"ball\"): {\r\n if ((this.player.getMoney() - ball.getCost()) >= 0) {\r\n player.play(ball);\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n\r\n case (\"doll\"): {\r\n if ((this.player.getMoney() - doll.getCost()) >= 0) {\r\n player.play(doll);\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n\r\n case (\"frisbee\"): {\r\n if ((this.player.getMoney() - frisbee.getCost()) >= 0) {\r\n player.play(frisbee);\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n case (\"feather toy\"): {\r\n if ((this.player.getMoney() - featherToy.getCost()) >= 0) {\r\n player.play(featherToy);\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }\r\n }\r\n return false;\r\n }", "public void Play();", "public void play(){\n\t\t\n\t}", "public void play() {\n\t\t\r\n\t}", "static public void viewPet(int petId) {\n User user = LocalUserManager.getCurrentUser();\n Pet pet = LocalPetManager.findPet(petId);\n assert pet != null;\n Presenter.showInstruction(\"You see a \"+pet.getPetColour()+\", \"+\n pet.getPetSex()+\" pet named \"+pet.getPetName()+\"\\n\");\n Presenter.showInstruction(pet.getPetName()+\": \"+pet.getGreeting()+\".\\n\");\n while (true) {\n boolean userInput = GameController.getUserYesOrNo(\"Enter 'y' to feed it or 'n' to go back\");\n if (userInput) {\n Presenter.showInstruction(pet.getPetName()+\": Yummy Yummy! Thank you, \" + user.getUsername()+\"\\n\");\n }\n else {\n return;\n }\n }\n }", "@Override\n\tpublic void play() {\n\t\tSystem.out.println(\"We played Snokker today\");\n\t\t\n\t\t\n\t}", "@Override\n\tpublic void play() {\n\t\t\n\t}", "public void play() {\n if (!isHungry()) {\n hunger += 2;\n mood += 2;\n fatigue += 3;\n\n if (!muted) {\n System.out.println(\"play\\t|\\tPlaying is fun!\");\n }\n }\n }", "@Override\n\tpublic void play() {\n\n\t}", "public void speak() {\r\n\t\tSystem.out.print(\"This animal speaks\");\r\n\t}", "private void makePlay() {\n\t\teating = true;\n\t\ttama.setLayoutX(200);\n\n\t\tplay = new Sprite(6, 6, 360, 379, new Image(\"file:./res/images/basketball.png\"), 1, 1000);\n\t\tplay.setLayoutX(140);\n\t\tplay.setLayoutY(190);\n\t\tplay.setScaleX(0.5);\n\t\tplay.setScaleY(0.5);\n\t\tgrid.getChildren().addAll(play);\n\t\tPauseTransition pause = new PauseTransition(Duration.millis(1000));\n\t\tpause.setOnFinished(e -> {\n\t\t\tgrid.getChildren().remove(play);\n\t\t\ttama.setLayoutX(190);\n\t\t\teating = false;\n\t\t\tmodel.getController().playWith();\n\t\t});\n\t\tpause.play();\n\n\t}", "private void play() {\n\t\tParcel pc = Parcel.obtain();\n\t\tParcel pc_reply = Parcel.obtain();\n\t\ttry {\n\t\t\tSystem.out.println(\"DEBUG>>>pc\" + pc.toString());\n\t\t\tSystem.out.println(\"DEBUG>>>pc_replay\" + pc_reply.toString());\n\t\t\tib.transact(1, pc, pc_reply, 0);\n\t\t} catch (RemoteException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\n\t}", "void play();", "void letToPlay(Shape shape);", "public void howToPlay() {\r\n // An item has been added to the ticket. Fire an event and let everyone know.\r\n System.out.println(\"Step 1: Have no life. \\nStep 2: Deal cards\\nStep 3: Cry yourself to sleep.\");\r\n }", "protected void playParticle(){\n\t\teffectData.getPlayParticles().playParticles(effectData, effectData.getDisplayAt());\n\t}", "@Override\r\n\tpublic void sound() {\r\n\t\tsuper.sound();\r\n\t\tSystem.out.println(\"SportsCar sound: Vutututututu\");\r\n\t}", "public abstract CardAction play(Player p);", "void play ();", "public void playHitWall() {\r\n hitWall.play(soundFxVol);\r\n }", "@Test\n\tpublic void testTheTickMethodForEachPet() {\n\t\tVirtualPetShelter testPetShelter = new VirtualPetShelter();\n\t\ttestPetShelter.addPet(\"Rusty\", new VirtualPet(\"Rusty\", \"He doesn't get hungry, he's Dead!\", 5, 30, 20));\n\t\ttestPetShelter.addPet(\"Grazer\", new VirtualPet(\"Grazer\", \"She cant leave.. she's dead too!\", 10, 20, 30));\n\t\ttestPetShelter.tick(); // I created a tick, eclipse erred and asked me to create tick in VPS\n\t\tAssert.assertEquals(32, testPetShelter.virtualPets.get(\"Rusty\").boredom);\n\t\tAssert.assertEquals(22, testPetShelter.virtualPets.get(\"Grazer\").boredom);\n\t}", "public abstract void fruitEffect(Player p);", "private void play() {\n\t\tlog.finest(\"Playing sound\");\n\t\ttone.trigger();\n\t}", "public void play() {\n\t\tplay(true, true);\n\t}", "@Override\n public String speak()\n {\n return \"peep\";\n }", "public static void playScream()\n {\n scream.play();\n }", "static void feedPet() {\r\n\t\tJOptionPane.showMessageDialog(null, \"Your \" + pet + \" is happy and full.\");\r\n\t\thappinessLevel+=3;\r\n\t}", "public Pet getPet() {\n return pet;\n }", "public abstract void play();", "public abstract void play();", "public void speak() {\r\n\t\tSystem.out.print(\"This Goose speaks\");\r\n\t}", "public void playAI() {\r\n // An item has been added to the ticket. Fire an event and let everyone know.\r\n System.out.println(\"You're going to lose foolish human!\");\r\n }", "@Override\n\tpublic void playLivingSound() {\n\t\tgetSoundManager().playLivingSound();\n\t}", "public void addPet(VirtualPet pet) {\n\t\tshelterPets.put(pet.name, pet);\n\t}", "public void play() {\n System.out.println(\"Player \" + this.name + \" started to play...\");\n System.out.println(\"Current balance: \" + getTotalAsset());\n\n // roll a dice to move\n int steps = rollDice();\n System.out.println(\"Player diced \" + steps);\n\n // move\n move(steps);\n Land land = Map.getLandbyIndex(position);\n\n // land triggered purchase or opportunity events\n land.trigger();\n\n System.out.println(\"Player \" + this.name + \"has finished.\");\n }", "@Override\n\tpublic void play() {\n\t\tGuitar.super.play();\n\t\tPiano.super.play();\n\t}", "public static play() {\n\t\t\n\t}", "public void play() {\n\t\tSystem.out.println(\"playing \"+title+\" by \" +artist);\n\t}", "void playMonopolyCard(String resource);", "public static void main(String[] args) {\n\t\tPet cat = new Cat(false,4);\n\t\tcat.run(getPetName(cat));\n\t\tPet parrot = new Parrot(true,2);\n\t\tparrot.run(getPetName(parrot));\n\t\t\n\t\tParrot pr = (Parrot) parrot;\n\t\tpr.fly(getPetName(pr));\n\t\t\n\t\tPet pet = pr;\n\t\n\t}", "@Override\n\tpublic void sound() {\n\t\tSystem.out.println(\"Dog2..sound.\");\n\t\t\n\t}", "protected void playPatch(Patch p) {\n if (AppConfig.getSequencerEnable())\n playSequence();\n else\n playNote();\n }", "public void explosion(){\n explosionEffect.play(pitch, volume);\n }", "public void play() {\n\t\tSystem.out.println(\"playing \"+title);\r\n\t}", "public void play() {\n\t\tif (happiness + 10 > 100) {\n\t\t\thappiness = 100;\n\t\t} else {\n\t\t\thappiness += 10;\n\t\t}\n\t}", "void makePlay(int player) {\n }", "@Override\n\tpublic void speak() {\n\t\tsuper.speak();\n\t\tSystem.out.println(\"I am a cat.\");\n\t}", "void playMonumentCard();", "@Override\r\npublic void Play() {\n\t\r\n}", "private void play(Poker pokerInstance, int action) {\n if (this.playing) {\n if (action == Poker.ACTION_BET) {\n actionBet(pokerInstance, 50);\n } else if (action == Poker.ACTION_FOLLOW) {\n actionFollow(pokerInstance);\n } else if (action == Poker.ACTION_CHECK) {\n actionCheck();\n } else if (action == Poker.ACTION_BED) {\n actionLeave();\n }\n }\n }", "@Override\n public void beHelpful() {\n this.playPiano();\n this.takeABow();\n }", "public void speak(){\n System.out.println(\"Smile and wave boys. Smile and wave.\");\n }", "@Test\n\tpublic void testAdoptionOfAShelterPet() {\n\t\tVirtualPetShelter testPetShelter = new VirtualPetShelter(); \n\t\ttestPetShelter.addPet(\"Rusty\", new VirtualPet(\"Rusty\", \"He doesn't get hungry, he's Dead!\", 0, 0, 0));\n\t\ttestPetShelter.addPet(\"Grazer\", new VirtualPet(\"Grazer\", \"She cant leave.. she's dead too!\", 0, 0, 0));\n\t\ttestPetShelter.adoptPet(\"Grazer\"); // I created adoptPet, eclipse erred and asked me to create adoptPet in VPS \n\t\tAssert.assertEquals(1, testPetShelter.getVirtualPets().size()); // Pet is now removed from VP's collection\n\t}", "@Override\r\n\tpublic void play() {\n\t\tSystem.out.println(\"Play Movie\");\r\n\t\t\r\n\t}", "public void play(String s, Player p)\n\t{\n\t\tif(contains(s))\n\t\t{\n\t\t\tget(s).play(p);\n\t\t}\n\t}", "public void speak(){\n System.out.println(\"Shark bait oooh ha haa!\");\n }", "public void playPaper(ActionEvent e) throws IOException {\n try {\n //System.out.println(\"Class play: \" + game.getClass().toString());\n getWinnerRPS(game.play(2));\n playerPlays = \"Player plays paper\";\n computerPlays = \"Computer plays \" + addRPSPlayed(game.getComputerPlays());\n myctr.setLabels();\n } catch(Exception n) {\n System.out.println(\"Game \\\"RockPaperScissors\\\" not initialized!\");\n }\n }", "@Override\n public void play() {\n System.out.println(\"AppleTV, opened\");\n }", "public void thankYouVet(){\n System.out.println(\"PetOwner says ... thank you Vet!\");\n }", "public static void playShootingSound(){\n String musicFile = \"Sounds\\\\Shoot.mp3\";\n Media sound = new Media(new File(musicFile).toURI().toString());\n MediaPlayer mediaPlayer = new MediaPlayer(sound);\n mediaPlayer.setVolume(App.getVolume());\n mediaPlayer.play();\n }", "public static void main(String[] args) {\n\n Pet pet = new Pet(\"Larry\",5) {\n @Override\n public void say() {\n System.out.println(\"wow, wow, wow\");\n }\n };\n System.out.println(pet);\n\n pet.say();\n // ((Cat) pet).getPredator();---> преобразовал тип pet в cat ---> можно, но нельзя\n\n }", "public final void play() {\n\t\tinitialize();\n\t\tstartPlay();\n\t\tendPlay();\n\t}", "public void cowSound() {\n System.out.println(\"The cow sounds : meeee\");\n }", "public static void playSound(Player p, Location loc, Sound sound, float pitch, float volume){\n p.playSound(loc, sound, volume, pitch);\n }", "private void feed(Player p){\r\n\t\tSystem.out.println(\"What pet would you like to feed?\");\r\n\t\tArrayList<Food> foodlist = p.getFood();\r\n\r\n\t\tint c = 1;\r\n\t\tfor(Pet pet : p.getPets()){\r\n\t\t\tSystem.out.println(c + \". \" + pet.getPetname());\r\n\t\t\tc++;\r\n\t\t}\r\n\r\n\t\tint selectedpetindex = getNumber(1, p.getPets().size());\r\n\t\tPet selectedpet = p.getPets().get(selectedpetindex - 1);\r\n\t\tSystem.out.println(\"What food do you want to feed \" + selectedpet.getPetname() + \" with?\");\r\n\r\n\t\tc = 1;\r\n\t\tfor(Food f : foodlist){\r\n\t\t\tSystem.out.println(c + \". \" + f.getName());\r\n\t\t\tc++;\r\n\t\t}\r\n\r\n\t\tint foodindex = getNumber(1, foodlist.size());\r\n\t\tFood selectedfood = foodlist.get(foodindex);\r\n\r\n\t\tselectedpet.feed(selectedfood);\r\n\t\tfoodlist.remove(foodindex);\r\n\t\tp.setFood(foodlist);\r\n\r\n\t\tp.setActions(p.getActions() - 1);\r\n\t}", "@Override\n\tpublic void compete() {\n\t\tSystem.out.println(\"Pawan is competing as a swimming Athlete \");\n\t\t\n\t}", "@Override\n public void play() {\n quest();\n if ((int) (Math.random() * 10) % 2 == 0) {\n won = true;\n System.out.println(\"You beat the last quest!\");\n } else {\n System.out.println(\"There are many more adventures for you, young warrior\");\n }\n }", "public void setPet(Pet pet) {\n this.pet = pet;\n Util.getInstance().loadImage(pet.getId(), avatarImageView, false, new com.squareup.picasso.Callback(){\n @Override\n public void onSuccess() {\n\n }\n\n @Override\n public void onError() {\n\n }\n });\n\n idEditText.setText(pet.getId());\n nameEditText.setText(pet.getName());\n femaleButton.setChecked(pet.isFemale());\n switch (pet.getSpecies()) {\n case \"Cat\":\n speciesSpinner.setSelection(0);\n break;\n case \"Dog\":\n speciesSpinner.setSelection(1);\n break;\n case \"Bird\":\n speciesSpinner.setSelection(2);\n break;\n case \"Rabbit\":\n speciesSpinner.setSelection(3);\n break;\n case \"Others\":\n speciesSpinner.setSelection(4);\n break;\n default:\n break;\n\n }\n if(pet.getBirthday() == null){\n birthdayEditText.setText(\"\");\n } else{\n birthdayEditText.setText(Util.getInstance().dateFormatter().format(pet.getBirthday()));\n }\n vetPhoneEditText.setText(pet.getVetPhone());\n vetNameEditText.setText(pet.getVetName());\n medicationsEditText.setText(pet.getMedications());\n chipIdEditText.setText(pet.getChipId());\n chipCompanyEditText.setText(pet.getChipCompany());\n }", "@Override\n\tpublic void speak() {\n\t\tSystem.out.println(\"tik tik.......\");\n\t}", "public void printVictoryMessage() { //main playing method\r\n System.out.println(\"Congrats \" + name + \" you won!!!\");\r\n }", "public void addPets(PetPOJO pet) {\n pets.add(pet);\n }", "public void setpetID(String petID){\n this.petID = petID;\n }", "@Override\r\n public void play()\r\n {\n\r\n }", "protected abstract void internalPlay();", "@Override\n\tpublic void play() {\n\t\tSystem.out.println(\"打击乐器奏乐~~!\");\n\t}", "public void play(Player p) {\n\t\tthis.player=p;\n\t\tplayer.setActualRoom(this.currentRoom);\n\t\twhile (!this.isFinished()) {\n\t\t\tthis.currentRoom=p.getActualRoom();\n\t\t\tif (this.GameOver()) {\n\t\t\t\tSystem.out.println(\"You LOOSE !\");\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif (this.isFinished()) {\n\t\t\t\tSystem.out.println(\"You WIN !\");\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tp.act();\n\t\t}\n\t\tif (this.isFinished()) {\n\t\t\tSystem.out.println(\"You WIN !\");\n\t\t}\n\t\n\t\t\n\t}", "public void playPvC() {\n boolean computerFirst = true;\n playPvC(computerFirst);\n }", "public void speak() {\r\n\t\tSystem.out.print(\"This Tiger speaks\");\r\n\t}", "@Override\r\n\tpublic void playSoldierCard() {\n\t\t\r\n\t}", "@Override\n\tpublic void playCard() {\n\t\t\n\t}", "public void talk() {\n\n\t}", "public VirtualPet getPet(String name) {\n\t\treturn shelterPets.get(name);\n\n\t}", "boolean play();", "@Test\n\tpublic void testAllowIntakeOfAHomelessPet() {\n\t\tVirtualPetShelter testPetShelter = new VirtualPetShelter(); //eclipse ask me to create addPet in VPS\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\ttestPetShelter.addPet(new String(), new VirtualPet(\"Rusty\", \"He doesn't get hungry, he's Dead!\", 0, 0, 0));\n\t\tAssert.assertEquals(1, testPetShelter.getVirtualPets().size()); // I test # of values (pets) in collection\n\t}", "void play(boolean fromUser);", "protected void playStepSound(int par1, int par2, int par3, int par4)\n {\n this.playSound(\"mob.spider.step\", 0.15F, 1.0F);\n }", "@Override\r\n\tpublic void playCard() {\n\t\t\r\n\t}", "public void createPet(Pets pet) {\n\n try {\n\n Statement statement = conn.createStatement();\n String sqlStatement = \"INSERT INTO pets (\" +\n \"name, animal_type, animal_breed, date_of_birth, gender, weight, owner) \" +\n \"VALUES (\" +\n \"'\" + pet.getName() + \"',\" +\n \"'\" + pet.getAnimalType() + \"',\" +\n \"'\" + pet.getAnimalBreed() + \"',\" +\n \"'\" + pet.getDateOfBirth() + \"',\" +\n \"'\" + pet.getGender() + \"',\" +\n +pet.getWeight() + \",\" +\n \"'\" + pet.getOwner() + \"'\" +\n \")\";\n\n int rowsAffected = statement.executeUpdate(sqlStatement);\n\n if (rowsAffected != 0) {\n System.out.println(\"Pet added successfully!\");\n } else {\n System.out.println(\"Sorry.. Something went wrong! Try again.\");\n }\n\n } catch (SQLException exception) {\n System.out.println(\"Error creating a Pet : \" + exception);\n }\n }", "public static void playPickupSound(){\n String musicFile = \"Sounds\\\\Pickup.mp3\";\n Media sound = new Media(new File(musicFile).toURI().toString());\n MediaPlayer mediaPlayer = new MediaPlayer(sound);\n mediaPlayer.setVolume(App.getVolume());\n mediaPlayer.play();\n }", "public void play() {\n try {\n mSessionBinder.play(mContext.getPackageName(), mCbStub);\n } catch (RemoteException e) {\n Log.wtf(TAG, \"Error calling play.\", e);\n }\n }", "public void shootIntoRocket(){\n shoot.set(ROCKET_SHOOT);\n }", "static public void editPet() {\n User user = LocalUserManager.getCurrentUser();\n Pet pet = LocalPetManager.findPet(user.getPetId());\n while (true) {\n Presenter.showMenu(new String[]{\"Edit pet name\", \"Set pet public/private\", \"Re-create pet\", \"Back\"},\n \"\\nThis is the pet editor menu, you can:\");\n int userChoice = GameController.getUserNum(4);\n if (userChoice == 1) {\n assert pet != null;\n String newPetName = GameController.getUserString(\"Your previous pet name is \"+\n pet.getPetName()+\". Please enter a new name...\");\n if (newPetName.equals(pet.getPetName())){\n Presenter.showNotice(\"That's the same name from before!\");\n }\n else {\n LocalPetManager.changePetName(user.getPetId(), newPetName);\n Presenter.showNotice(\"You have changed your pet name to \"+pet.getPetName()+\" successfully!\");\n }\n }\n else if (userChoice == 2) {\n boolean petPublic = GameController.getUserYesOrNo(\n \"Your pet is \"+LocalPetManager.checkPublicity(user.getPetId())+\" to others now.\\n\" +\n \"Enter 'y' to make it public or 'n' to make it private\");\n assert pet != null;\n pet.setPublicity(petPublic);\n Presenter.showNotice(\"You have change your pet to \"+\n LocalPetManager.checkPublicity(user.getPetId())+\" successfully!\");\n }\n else if (userChoice == 3){\n boolean reCreatePet = GameController.getUserYesOrNo(\n \"Are you sure you want to create a new pet? You will lose \" + pet.getPetName()+\" in the process.\\n\" +\n \"Enter 'y' to create a new pet or 'n' to go back\"\n );\n if (reCreatePet){\n UserController.createUserPet();\n Presenter.showNotice(\"\\nYou have successfully created a new pet!\\n\");\n }\n return;\n }\n else {\n return;\n }\n }\n }", "public interface Playable {\n\n String play();\n}" ]
[ "0.74441373", "0.6894918", "0.671059", "0.6568307", "0.6470529", "0.64614755", "0.64026654", "0.63966787", "0.6368773", "0.6295992", "0.6277741", "0.6250279", "0.6215427", "0.6138985", "0.6114505", "0.6092412", "0.6073087", "0.60559857", "0.605146", "0.6044268", "0.600324", "0.60031563", "0.5997982", "0.5991186", "0.5978433", "0.5958964", "0.5950876", "0.5942926", "0.5938843", "0.5927779", "0.5927239", "0.59224844", "0.59186506", "0.5915558", "0.5907242", "0.5906625", "0.5906625", "0.589484", "0.5894389", "0.5892624", "0.5847949", "0.58237195", "0.58009046", "0.58005846", "0.57993853", "0.579569", "0.5793257", "0.57765055", "0.5768456", "0.57637835", "0.5763394", "0.5757443", "0.57551277", "0.57498", "0.5743033", "0.57342494", "0.57329375", "0.57035184", "0.5686378", "0.5684143", "0.5681466", "0.5678254", "0.5675411", "0.56711274", "0.56684786", "0.56664014", "0.5663213", "0.5648392", "0.5644801", "0.56395465", "0.56334203", "0.5624391", "0.5619463", "0.56062865", "0.56035984", "0.5602766", "0.5601655", "0.55929583", "0.55821097", "0.55744994", "0.55744845", "0.5573031", "0.55704653", "0.5563433", "0.55523413", "0.55459833", "0.5542522", "0.5538439", "0.5534324", "0.5534141", "0.55336463", "0.5529494", "0.5528656", "0.55283934", "0.5528364", "0.5526174", "0.5521666", "0.5520362", "0.5517471", "0.5514329" ]
0.76413554
0
Go to the store.
private void storeTrip(Player p){ System.out.println("Welcome to the store!"); System.out.println("Just a reminder, you have $" + p.getMoney() + " to spend!"); System.out.println("Please Select An Option: "); System.out.println("1. Buy Food"); System.out.println("2. Buy Toys"); System.out.println("3. Leave the store"); ArrayList<Toy> storetoys = store.getToys(); ArrayList<Food> storefood = store.getFoods(); int[] toyamounts = store.getToyamounts(); int[] foodamounts = store.getFoodamounts(); int buyoption; //The buying option int c; //Counter int selectedoption = getNumber(1, 3); switch(selectedoption){ //Buy food case 1: c = 1; for(Food f : storefood){ System.out.println(c + ". " + f.getName() + "\nPrice: $" + f.getValue() + " Stock: " + foodamounts[c-1]); System.out.println(""); c++; } buyoption = getNumber(1, storefood.size()); Food selectedfood = storefood.get(buyoption -1); if(p.getMoney() > selectedfood.getValue() && foodamounts[buyoption-1] > 0){ p.setMoney(p.getMoney() - selectedfood.getValue()); foodamounts[buyoption -1]--; //Take one away, as it has been sold. p.addFood(selectedfood); store.setFoodamounts(foodamounts); } break; //Buy toys case 2: c = 1; for(Toy t : storetoys){ System.out.println(c + ". " + t.getName() + "\nPrice: $" + t.getPrice() + " Stock: " + toyamounts[c-1]); System.out.println(""); c++; } buyoption = getNumber(1, storetoys.size()); Toy selectedtoy = storetoys.get(buyoption -1); if(p.getMoney() > selectedtoy.getPrice() && toyamounts[buyoption-1] > 0){ p.setMoney(p.getMoney() - selectedtoy.getPrice()); toyamounts[buyoption -1]--; //Take one away, as it has been sold. p.addToy(selectedtoy); store.setToyamounts(toyamounts); } else{ System.out.println("\n\n\n\n\n\nError. Either the store was out of stock for the selected product or the player was out of money."); } case 3: break; default: System.out.println("ERROR"); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void navigateToStoreOrders() {\n Intent gotoStoreOrders = new Intent(this, StoreOrdersActivity.class);\n startActivity(gotoStoreOrders);\n }", "@FXML\r\n\tpublic void goToCheckout() {\r\n\t\tViewNavigator.loadScene(\"Checkout\", ViewNavigator.CHECKOUT_SCENE);\r\n\t}", "private void retrieve() {\r\n\t\ttry {\r\n\t\t\tif (store == null) {\r\n\t\t\t\tstore = Store.retrieve();\r\n\t\t\t\tif (store != null) {\r\n\t\t\t\t\tSystem.out.println(\" The store has been successfully retrieved from the file StoreData. \\n\");\r\n\t\t\t\t} else {\r\n\t\t\t\t\tstore = Store.instance();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t} catch (Exception cnfe) {\r\n\t\t\tcnfe.printStackTrace();\r\n\t\t}\r\n\t}", "@FXML\r\n\tpublic void goToShoppingCart() {\r\n\t\tViewNavigator.loadScene(\"Your Shopping Cart\", ViewNavigator.SHOPPING_CART_SCENE);\r\n\t}", "public void goTo() { // Navigate to home page\n\t\tBrowser.goTo(url);\n\t}", "public void startStore(View view) {\n Intent intent = new Intent(this, Store.class);\n intent.putExtra(\"User\", user);\n startActivity(intent);\n }", "private void goToShop() {\n shopMenu.runMenu();\n }", "public void handleStore()\r\n {\r\n //\r\n }", "@Override\n\tpublic void enterStore(Store store) {\n\t\tHashMap<Goods, Integer> sellGoods = store.getSellGoods();\n\t\tHashMap<Goods, Integer> interestedGoods = store.getInteresedGoods();\n\t\tEquipment equipment = store.getEquipment();\n\t\tint currentMoney = game.getMoney();\n\t\tboolean state = false;\n\t\twhile (state == false) {\n\t\t\tSystem.out.println(\"Your current money is: \" + currentMoney);\n\t\t\tif (!game.checkMyShipHealth()) {\n\t\t\t\tint cost = 100 - (game.getSelectedShip().getShipsStatus());\n\t\t\t\tSystem.out.println(\"Your ship repairment cost is: \" + cost);\n\t\t\t}\n\t\t\tSystem.out.println(\"Choose your actions: \");\n\t\t\tSystem.out.println(\"(1) Go back!\");\n\t\t\tSystem.out.println(\"(2) See goods that for sale\");\n\t\t\tSystem.out.println(\"(3) See goods that interested by the store\");\n\t\t\tSystem.out.println(\"(4) See equipment for your ship\");\n\t\t\tSystem.out.println(\"(5) Repair my ship\");\n\t\t\ttry { \n\t\t\t\tint selectedAction = scanner.nextInt();\n\t\t\t\tif (selectedAction <= 5 && selectedAction > 0) {\n\t\t\t\tstate = true;\n\t\t\t\tif (selectedAction == 1) {\n\t\t\t\t\tgame.backToMain();\n\t\t\t\t}\n\t\t\t\telse if (selectedAction == 2) \n\t\t\t\t{\n\t\t\t\t\tbuyGoodsFromStore(sellGoods);\n\t\n\t\t\t\t}\n\t\t\t\telse if (selectedAction == 3) {\n\t\t\t\t\tsellGoodsForStore(interestedGoods);\n\t\t\t\t}\n\t\t\t\telse if (selectedAction == 4) {\n\t\t\t\t\tthis.buyEquipment(equipment, store);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tgame.repairMyShip();\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t\telse {\n\t\t\t\t\tSystem.out.println(\"Please choose from actions above\");\n\t\t\t\t}\n\t\t\t\t\n\t\t\t} catch (Exception e) {\n\t\t\t\tSystem.out.println(INPUT_REQUIREMENTS);\n\t\t\t\tscanner.nextLine();\n\t\t\t}\n\t\t}\n\t}", "public void goToCart() throws IOException {\n logic.switchScene(\"fxml/CartFxml.fxml\", cartBtn, fxmlLoader);\n ((CartController) fxmlLoader.getController()).init();\n }", "public static void goTo() {\n Browser.driver.get(\"https://www.amazon.co.uk/\");\n Browser.driver.manage().window().maximize();\n }", "public void openStore() throws IOException {\n Store selectedStore = storeList.getSelectionModel().getSelectedItem();\n\n if(selectedStore != null) {\n Stage primaryStage = Main.primaryStage;\n FXMLLoader loader = new FXMLLoader();\n loader.setLocation(getClass().getResource(\"./GUI/categoryScreen.fxml\"));\n Parent root = loader.load();\n categoryScreenController csc = loader.getController();\n csc.setValues(selectedStore, eu);\n primaryStage.setTitle(\"Category Screen\");\n primaryStage.resizableProperty().setValue(Boolean.FALSE);\n primaryStage.setScene(new Scene(root, 800, 600));\n primaryStage.show();\n }\n\n }", "public static void goToCart() {\n click(SHOPPING_CART_UPPER_MENU);\n }", "@Override\r\n\tpublic void navigate() {\n\t\t\r\n\t}", "private void save() {\r\n\t\tif (Store.save()) {\r\n\t\t\tSystem.out.println(\" > The store has been successfully saved in the file StoreData.\\n\");\r\n\t\t} else {\r\n\t\t\tSystem.out.println(\" > An error occurred during saving.\\n\");\r\n\t\t}\r\n\t}", "public final void go() {\n this.getView().showCountries(this.getModel().getCountries());\n CountryFindChoice choice;\n do {\n choice = this.getView().askUserFindChoice();\n } while (choice == CountryFindChoice.error);\n String codeOrName = this.getView().askCodeOrName(choice);\n Country country = null;\n switch (choice) {\n case byCode:\n country = this.getModel().getCountryByCode(codeOrName);\n break;\n case byName:\n country = this.getModel().getCountryByName(codeOrName);\n break;\n }\n if(country != null) {\n this.getView().printMessage(country.getHelloWorld().getMessage());\n }\n this.getModel().close();\n }", "void navigateToCurrentOrder() {\n Intent gotoCurrentOrder = new Intent(this, CurrentOrderActivity.class);\n startActivity(gotoCurrentOrder);\n }", "public void go() {\n try {\n go(pc);\n dp.refresh(pc, stackRegister, compareRegister);\n } catch (Exception e) {\n con.cPrintln(\"Error : \" + e.toString());\n } catch (Error e) {\n con.cPrintln(\"Error : \" + e.getMessage());\n }\n }", "private void redirectStore(String updateUrl) {\n final Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(updateUrl));\n intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n startActivity(intent);\n }", "private void goShopping(User user, Scanner sc) {\n\t\tboolean run = true;\n\t\tdo {\n\t\t\tlog.info(\"Store Inventory\\n\");\n\t\t\tList<Item> items = cService.seeItemsOnSale();\n\t\t\titems.stream().forEach(item -> log.info(item));\n\n\t\t\tlog.info(\"Welcome to the NYC Grocery Store\\n\");\n\n\t\t\tlog.info(\"Choose an option:\");\n\t\t\tlog.info(\"\t\tPress 1 to Make an Offer on an Item\");\n\t\t\tlog.info(\"\t\tPress anything else to go to the MAIN CUSTOMER DASHBOARD\");\n\t\t\tString choice = sc.nextLine();\n\t\t\tswitch (choice) {\n\t\t\tcase \"1\":\n\t\t\t\tmakeAnOffer(user, sc);\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tlog.info(\"\\nGoing back to the CUSTOMER DASHBOARD\\n\");\n\t\t\t\trun = false;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t} while (run);\n\n\t}", "public void navigateToRoot()\r\n\t{\r\n\t\tnavigateTo(m_rootInstance, false);\r\n\t}", "public static void goToCheckout() {\n click(CHECKOUT_UPPER_MENU);\n }", "public void gotoDetailSalesOrder() {\n\t}", "@FXML\n public void goToShop(ActionEvent event) {\n this.myController.setScreen(MainView.shop);\n }", "public void goShopping() {\n shop1.theShop();\n\n }", "@FXML\r\n\tpublic void goToMain() {\r\n\t\tViewNavigator.loadScene(\"Welcome to WatchPlace\", ViewNavigator.HOME_SCENE);\r\n\t}", "protected void goTo(String url) {\n \t\tcontext.goTo(url);\n \t}", "public void performSearch() {\n OASelect<CorpToStore> sel = getCorpToStoreSearch().getSelect();\n sel.setSearchHub(getSearchFromHub());\n sel.setFinder(getFinder());\n getHub().select(sel);\n }", "private void goToMenu() {\n\t\tgame.setScreen(new MainMenuScreen(game));\n\n\t}", "private Store openStore() throws MessagingException {\n\t\tStore store = getStore();\n\t\tstore.connect(host, port, name, password);\n\t\treturn store;\n\t}", "@Override\n\tpublic void goToStings() {\n\t\t\n\t}", "private void openStore()\n throws Exception {\n\n dbStore = Utils.openStore(master, Utils.DB_NAME);\n primaryIndex = \n dbStore.getPrimaryIndex(Integer.class, RepTestData.class);\n }", "void navigateToOrderingCoffee() {\n Intent gotoOrderCoffee = new Intent(this, OrderingCoffeeActivity.class);\n startActivity(gotoOrderCoffee);\n }", "public void gotoCoachLogin(){ application.gotoCoachLogin(); }", "@Override\r\n\tpublic void goTo(Place place) {\r\n\t\tclientFactory.getPlaceController().goTo(place);\r\n\t}", "@Override\n public void goToNextScreen(Home.HomeTo presenter) {\n toMapsState = new MapState();\n toMapsState.shop = presenter.getShop();\n\n Context view = presenter.getManagedContext();\n if (view != null) {\n Log.d(TAG, \"calling startingMapsScreen()\");\n view.startActivity(new Intent(view, MapsView.class));\n Log.d(TAG, \"calling destroyView()\");\n presenter.destroyView();\n }\n }", "@Override\n\tpublic void goToLogin() {\n\t\t\n\t}", "public void ViewCart() {\r\n\t\tthis.ViewCart.click();\r\n\t}", "Transfer retrieveFirst( final List<? extends ArtifactStore> stores , final String path , EventMetadata eventMetadata )\n throws IndyWorkflowException;", "public String saveStore() {\n\t\tsuper.setPageTitle(\"label.menu.group.store\");\n\n\t\tMerchantStore store = null;\n\t\ttry {\n\n\t\t\tContext ctx = (Context) super.getServletRequest().getSession()\n\t\t\t\t\t.getAttribute(ProfileConstants.context);\n\t\t\tInteger merchantid = ctx.getMerchantid();\n\n\t\t\tMerchantService mservice = (MerchantService) ServiceFactory\n\t\t\t\t\t.getService(ServiceFactory.MerchantService);\n\t\t\tstore = mservice.getMerchantStore(merchantid.intValue());\n\t\t\t\n\t\t\t//validation\n/*\t\t\tif (StringUtils.isBlank(merchantProfile.getTemplateModule())) {\n\t\t\t\tsuper.setErrorMessage(\"errors.store.emptytemplate\");\n\t\t\t\treturn INPUT;\n\t\t\t} */\n\n\t\t\tif (store == null) {\n\t\t\t\tstore = new MerchantStore();\n\t\t\t\tstore.setTemplateModule(CatalogConstants.DEFAULT_TEMPLATE);\n\t\t\t}else {\n\t\t\t\tstore.setTemplateModule(merchantProfile.getTemplateModule());\n\t\t\t}\n\t\t\t\n\n\n\t\t\tjava.util.Date dt = new java.util.Date();\n\n\t\t\tStringBuffer languages = new StringBuffer();\n\t\t\tList langs = this.getSupportedLanguages();\n\t\t\tif (langs != null && langs.size() > 0) {\n\t\t\t\tint sz = 0;\n\t\t\t\tIterator i = langs.iterator();\n\n\t\t\t\twhile (i.hasNext()) {\n\t\t\t\t\tString lang = (String) i.next();\n\t\t\t\t\tlanguages.append(lang);\n\n\t\t\t\t\tif (sz < langs.size() - 1) {\n\t\t\t\t\t\tlanguages.append(\";\");\n\t\t\t\t\t}\n\t\t\t\t\tsz++;\n\n\t\t\t\t}\n\t\t\t\tstore.setSupportedlanguages(languages.toString());\n\t\t\t} else {\n\t\t\t\tMessageUtil.addErrorMessage(super.getServletRequest(),\n\t\t\t\t\t\tLabelUtil.getInstance().getText(\n\t\t\t\t\t\t\t\t\"message.confirmation.languagerequired\"));\n\t\t\t\tstore.setSupportedlanguages(Constants.ENGLISH_CODE);\n\t\t\t\treturn SUCCESS;\n\t\t\t}\n\n\t\t\tstore.setStorename(merchantProfile.getStorename());\n\t\t\tstore.setStoreemailaddress(merchantProfile.getStoreemailaddress());\n\t\t\tstore.setStoreaddress(merchantProfile.getStoreaddress());\n\t\t\tstore.setStorecity(merchantProfile.getStorecity());\n\t\t\tstore.setStorepostalcode(merchantProfile.getStorepostalcode());\n\t\t\tstore.setCountry(merchantProfile.getCountry());\n\t\t\tstore.setZone(merchantProfile.getZone());\n\t\t\tstore.setCurrency(merchantProfile.getCurrency());\n\t\t\t\n\n\t\t\tif (!StringUtils.isBlank(merchantProfile.getWeightunitcode())) {\n\t\t\t\tstore.setWeightunitcode(merchantProfile.getWeightunitcode()\n\t\t\t\t\t\t.trim());\n\t\t\t}\n\t\t\tif (!StringUtils.isBlank(merchantProfile.getSeizeunitcode())) {\n\t\t\t\tstore.setSeizeunitcode(merchantProfile.getSeizeunitcode()\n\t\t\t\t\t\t.trim());\n\t\t\t}\n\t\t\tstore.setStorelogo(merchantProfile.getStorelogo());\n\t\t\tstore.setStorephone(merchantProfile.getStorephone());\n\t\t\tstore.setBgcolorcode(merchantProfile.getBgcolorcode());\n\t\t\tstore.setContinueshoppingurl(merchantProfile\n\t\t\t\t\t.getContinueshoppingurl());\n\t\t\tstore.setUseCache(merchantProfile.isUseCache());\n\t\t\tstore.setDomainName(merchantProfile.getDomainName());\n\n\t\t\tstore.setMerchantId(merchantid.intValue());\n\t\t\tstore.setLastModified(new java.util.Date(dt.getTime()));\n\n\t\t\tif (!StringUtils.isNumeric(merchantProfile.getZone())) {\n\t\t\t\tstore.setStorestateprovince(merchantProfile\n\t\t\t\t\t\t.getStorestateprovince());\n\t\t\t\tctx.setZoneid(0);\n\t\t\t} else {// get the value from zone\n\t\t\t\tctx.setZoneid(Integer.parseInt(merchantProfile.getZone()));\n\t\t\t\tMap zones = RefCache.getInstance().getAllZonesmap(\n\t\t\t\t\t\tLanguageUtil.getLanguageNumberCode(ctx.getLang()));\n\t\t\t\tZone z = (Zone) zones.get(Integer.parseInt(merchantProfile\n\t\t\t\t\t\t.getZone()));\n\t\t\t\tif (z != null) {\n\t\t\t\t\tstore.setStorestateprovince(z.getZoneName());// @todo,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// localization\n\t\t\t\t} else {\n\t\t\t\t\tstore.setStorestateprovince(\"N/A\");\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (!StringUtils.isBlank(this.getInBusinessSince())) {\n\t\t\t\tDate businessDate = DateUtil.getDate(this.getInBusinessSince());\n\t\t\t\tstore.setInBusinessSince(businessDate);\n\t\t\t}\n\n\t\t\tsuper.prepareSelections(store.getCountry());\n\t\t\tmservice.saveOrUpdateMerchantStore(store);\n\n\t\t\tsuper.getContext().setExistingStore(true);\n\n\t\t\t// refresh context\n\n\t\t\tctx.setCountryid(merchantProfile.getCountry());\n\t\t\tctx.setSizeunit(merchantProfile.getSeizeunitcode());\n\t\t\tctx.setWeightunit(merchantProfile.getWeightunitcode());\n\t\t\tLanguageHelper.setLanguages(languages.toString(), ctx);\n\t\t\tctx.setCurrency(merchantProfile.getCurrency());\n\n\t\t\t// refresh the locale\n\t\t\tMap countries = RefCache.getAllcountriesmap(LanguageUtil\n\t\t\t\t\t.getLanguageNumberCode(ctx.getLang()));\n\t\t\tCountry c = (Country) countries.get(merchantProfile.getCountry());\n\t\t\tLocale locale = new Locale(\"en\", c.getCountryIsoCode2());\n\t\t\tActionContext.getContext().setLocale(locale);\n\t\t\tMap sessions = ActionContext.getContext().getSession();\n\t\t\tsessions.put(\"WW_TRANS_I18N_LOCALE\", locale);\n\n\n\t\t\tMessageUtil.addMessage(super.getServletRequest(), LabelUtil\n\t\t\t\t\t.getInstance().getText(\"message.confirmation.success\"));\n\n\t\t} catch (Exception e) {\n\t\t\tlog.error(e);\n\t\t\tsuper.setTechnicalMessage();\n\t\t}\n\n\t\treturn SUCCESS;\n\n\t}", "@Override\n\tpublic void DoGoToCashier() {\n\t\t\n\t}", "public void Cart() {\r\n\t\tthis.cart.click();\r\n\t}", "public void goTo(Place place) {\n\t\tclientFactory.getPlaceController().goTo(place);\n\t}", "private void store()\tthrows DAOSysException\t\t{\n\t\tif (_debug) System.out.println(\"AL:store()\");\n\t\tAnnualLeaseDAO dao = null;\n\t\ttry\t{\n\t\t\tdao = getDAO();\n\t\t\tdao.dbStore(getModel());\n\t\t} catch (Exception ex)\t{\n\t\t\tthrow new DAOSysException(ex.getMessage());\n\t\t}\n\t}", "Transfer retrieveFirst( final List<? extends ArtifactStore> stores, final String path )\n throws IndyWorkflowException;", "void navigateToOrderingDonut() {\n Intent gotoOrderDonut = new Intent(this, OrderingDonutActivity.class);\n startActivity(gotoOrderDonut);\n }", "private void gotoPlay() {\n Intent launchPlay = new Intent(this, GameConfig.class);\n startActivity(launchPlay);\n }", "public void switchTo() {\n\towner.ioContainer().select(this);\n }", "public void gotoLogin() {\n try {\n LoginController login = (LoginController) replaceSceneContent(\"Login.fxml\");\n login.setApp(this);\n } catch (Exception ex) {\n Logger.getLogger(IndieAirwaysClient.class.getName()).log(Level.SEVERE, null, ex);\n }\n }", "private void goToMenu() {\n game.setScreen(new MainMenuScreen(game));\n\n }", "public void goHome() throws ManipulatorException;", "@Given(\"User is logging on MyStore\")\r\n public void searchingForProduct() {\n LoginPageNew login = new LoginPageNew(driver);\r\n MainPage main = new MainPage(driver);\r\n AccountPage accPage = new AccountPage(driver);\r\n AddingAnAddressForm addressForm = new AddingAnAddressForm(driver);\r\n login.loginAs(\"[email protected]\", \"123456\");\r\n main.goToAccPage();\r\n accPage.goToAddAddressForm();\r\n addressForm.fillingAddressForm(\"12\",\"Street Fighting Man\",\"02-223\",\"Sandia\",\"112322031\");\r\n accPage.goToMainPage();\r\n }", "public void navigateToForward() {\n WebDriverManager.getDriver().navigate().forward();\n }", "public void navigateTo() {\n LOGGER.info(\"Navigating to:\" + BASE_URL);\n driver.navigate().to(BASE_URL);\n }", "@Override\n\tpublic void execute(Frame frame) {\n\t\tDSTORE._dstore(frame, 1);\n\t}", "public void goBack() throws IOException { DashboardController.dbc.loadHomeScene(); }", "@Override\n\tpublic Store save(Store store) {\n\t\treturn storeRepository.save(store);\n\t}", "public void goToLoginPage()\n\t{\n\t\tclickAccountNameIcon();\n\t\tclickSignInLink();\n\t}", "public void navigateToLoginPage() {\r\n\t\tBrowser.open(PhpTravelsGlobal.PHP_TRAVELS_LOGIN_URL);\r\n\t}", "protected void setStore(String store) {\n this.store = store;\n }", "public void proceedToLetsGo() {\n\t\tBrowser.click(\"xpath=.//*[@id='DisplayNavigatorBrokerLandingPage']/div/div/div/div/div/div/div/div/div[5]/a/img\");\n\t}", "public void checkout() {\n\t}", "@FXML\n public void goToObst(ActionEvent event) throws IOException, SQLException { //PREVIOUS SCENE\n \tdoChecking();\n \t\n \ttry {\n\t \tif(checkIntPos && checkFloatPos && checkIntPosMatl && checkFloatPosMatl) {\n\t \t\t//store the values\n\t \t\tstoreValues();\n\t \t\t\n\t \t\tFXMLLoader loader = new FXMLLoader(getClass().getResource(\"Obst.fxml\"));\n\t \t\tParent root = loader.load();\n\t \t\t\n\t \t\tObstController obstCont = loader.getController(); //Get the next page's controller\n\t \t\tobstCont.showInfo(); //Set the values of the page \n\t \t\tScene obstScene = new Scene(root);\n\t \t\tStage mainWindow = (Stage)((Node)event.getSource()).getScene().getWindow();\n\t \t\tmainWindow.setScene(obstScene);\n\t \t\tmainWindow.show();\n\t \t}\n \t} catch(Exception e) {\n\t\t\tValues.showError();\n\t\t}\n \t\n }", "private void go() {\n\t\t\tgo2(new Tree(), new Chrome());\n\t\t\t//go2((Chrome) new Tree(),new Chrome());\n\t\t}", "public KVCommInterface getStore();", "public void goToMainScene() {\n\n scenesSeen.clear();\n this.window.setScene(firstScene.createAndReturnScene());\n scenesSeen.add(firstScene);\n }", "public void setStoreName(String storeName) {\r\n this.storeName = storeName;\r\n }", "public void setStoreName(String storeName) {\n this.storeName = storeName;\n }", "void goMainScreen(){\n\t\tcheckSavePwd();\n\t\tActionEvent e = new ActionEvent();\n\t\te.sender = this;\n\t\te.action = ActionEventConstant.ACTION_SWITH_TO_CATEGORY_SCREEN;\n\t\tUserController.getInstance().handleSwitchActivity(e);\n\t}", "@Override\n protected void execute() throws Exception\n {\n loadPageByClick(viewCartLink);\n }", "private void GoToLogin() {\n\t\tstartActivity(new Intent(this, LoginActivity.class));\r\n\t\tapp.user.sessionID = \"\";\r\n\t\tMassVigUtil.setPreferenceStringData(this, \"SESSIONID\", \"\");\r\n\t}", "public void gotoHome(){ application.gotoHome(); }", "public void clickCheckout()\n\t{\n\t\twaitForVisibility(checkout);\n\t\tcheckout.click();\n\t}", "public abstract Datastore launchGUI(Datastore theDatastore);", "private void viewPageClicked(ActionEvent event) {\n\n Item tempItem = new Item();\n String itemURL = tempItem.itemURL;\n Desktop dk = Desktop.getDesktop();\n try{\n dk.browse(new java.net.URI(itemURL));\n }catch(IOException | URISyntaxException e){\n System.out.println(\"The URL on file is invalid.\");\n }\n\n showMessage(\"Visiting Item Web Page\");\n\n }", "private void startGoToCartAct() {\n Intent intent = new Intent(this, EcomCartActivity.class);\n startActivity(intent);\n }", "@Override\r\n\tpublic void goForward() {\n\t\t\r\n\t}", "public void goTo(View view, Object data) {\n if (stage != null) {\n try {\n FXMLLoader loader = new FXMLLoader(getClass().getResource(\"../ui/\" + view.toString() + \".fxml\"));\n Parent root = loader.load();\n OnLoad controller = loader.getController();\n controller.onLoad(data);\n stage.setTitle(APP_NAME);\n stage.setScene(new Scene(root, APP_WIDTH, APP_HEIGHT));\n stage.show();\n } catch (IOException e) {\n System.err.println(\"The view \" + \"../ui/\" + view.toString() + \".fxml\" + \" doesn't exist.\");\n e.printStackTrace();\n }\n }\n }", "public static void goTo() {\n Browser.driver.get(\"https://www.abv.bg/\");\n Browser.driver.manage().window().maximize();\n }", "@Override\n public void onItemClick(RecyclerView parent, View view, int position) {\n ARouter.getInstance().build(\"/module_local/LocalStoreActivity\").withSerializable(\"bean\", shopBeans.get(position)).navigation();\n }", "public void gotoAdminLogin(){ application.gotoAdminLogin(); }", "public void goToEntry() {\n this.step(GameMap.instance().getEntryTile());\n }", "protected void loadStore() throws IOException {\n // auto create starting directory if needed\n if (!fileStore.exists()) {\n LOG.debug(\"Creating filestore: {}\", fileStore);\n File parent = fileStore.getParentFile();\n if (parent != null && !parent.exists()) {\n boolean mkdirsResult = parent.mkdirs();\n if (!mkdirsResult) {\n LOG.warn(\"Cannot create the filestore directory at: {}\", parent);\n }\n }\n boolean created = FileUtil.createNewFile(fileStore);\n if (!created) {\n throw new IOException(\"Cannot create filestore: \" + fileStore);\n }\n }\n\n LOG.trace(\"Loading to 1st level cache from state filestore: {}\", fileStore);\n\n cache.clear();\n try (Scanner scanner = new Scanner(fileStore, null, STORE_DELIMITER)) {\n while (scanner.hasNext()) {\n String line = scanner.next();\n int separatorIndex = line.indexOf(KEY_VALUE_DELIMITER);\n String key = line.substring(0, separatorIndex);\n String value = line.substring(separatorIndex + KEY_VALUE_DELIMITER.length());\n cache.put(key, value);\n }\n } catch (IOException e) {\n throw RuntimeCamelException.wrapRuntimeCamelException(e);\n }\n\n LOG.debug(\"Loaded {} to the 1st level cache from state filestore: {}\", cache.size(), fileStore);\n }", "public void enter() {\n // get data from current level\n GameState gs = (GameState) getStateMachine().getStates().get(\"game\");\n currentLevel = gs.getCurrentLevel();\n\n // TODO: for testing\n currentLevel.getCurrentquardant().setCleared(true);\n currentLevel.getCurrentquardant().setVisited(true);\n\n // set layout and add different panels\n getGamePanel().setLayout(layout);\n getGamePanel().add(shopPanel, BorderLayout.PAGE_START);\n //getGamePanel().add(mapPanel, BorderLayout.CENTER);\n\n // play backgroundmusic and toggle sound\n SoundBoard.BACKGROUND.play();\n SoundBoard.ERROR.play();\n\n }", "public void setStoreId(String storeId) {\n\t doSetStoreId(storeId);\n\t return;\n\t }", "public void returnToMainMenu() {\n AppStateManager stateManager = getStateManager();\n setEnabled(false);\n\n EnginePowerGraphState enginePowerGraphState\n = getState(EnginePowerGraphState.class);\n stateManager.detach(enginePowerGraphState);\n\n TireDataState tireDataState = getState(TireDataState.class);\n stateManager.detach(tireDataState);\n\n VehicleEditorState vehicleEditorState\n = getState(VehicleEditorState.class);\n stateManager.detach(vehicleEditorState);\n\n DebugTabState debugTabState = getState(DebugTabState.class);\n stateManager.detach(debugTabState);\n\n getState(DriverHud.class).setEnabled(false);\n\n Vehicle vehicle = MavDemo1.getVehicle();\n Vehicle newVehicle;\n try {\n Class<? extends Vehicle> clazz = vehicle.getClass();\n newVehicle = clazz.getDeclaredConstructor().newInstance();\n } catch (ReflectiveOperationException exception) {\n throw new RuntimeException(exception);\n }\n MavDemo1 main = MavDemo1.getApplication();\n AssetManager assetManager = main.getAssetManager();\n newVehicle.load(assetManager);\n MavDemo1.setVehicle(newVehicle);\n\n stateManager.attach(new MainMenu());\n getState(CameraInputMode.class).orbit();\n }", "public void doSetStoreId(String storeId) {\n\t this.storeId = storeId;\n\t return;\n\t }", "public void returnToMenu(){\n client.moveToState(ClientState.WELCOME_SCREEN);\n }", "public void store() {\r\n\t\tdata = busExt.get();\r\n\t}", "public void onStoreReady() {\n mMxEventDispatcher.dispatchOnStoreReady();\n }", "@Secured(\"@\")\n public void doBackPage() {\n infoOrderDetail = false;\n haveDepositPrice = false;\n orderStockTag.resetOrderStock();\n }", "Transfer retrieve( final ArtifactStore store, final String path )\n throws IndyWorkflowException;", "public final void navigateFromLogin() {\n SharedPrefsHelper sharedPrefsHelper2 = this.sharedPrefsHelper;\n if (sharedPrefsHelper2 == null) {\n Intrinsics.throwUninitializedPropertyAccessException(\"sharedPrefsHelper\");\n }\n String str = sharedPrefsHelper2.get(Constants_MVVM.FCM_REGISTERED_TOKEN, \"\");\n if (str.length() > 0) {\n LoginViewModel loginViewModel = this.viewModel;\n if (loginViewModel == null) {\n Intrinsics.throwUninitializedPropertyAccessException(\"viewModel\");\n }\n loginViewModel.registerFCMToken(this.username, this.password, str);\n }\n setResult(-1);\n finish();\n }", "public final void store(final boolean store) {\n\t\tthis.store = store;\n\t}", "protected void fireStoreEvent (DBConnectionInfo connInfo)\n {\n\tif (connInfo == null) {\n trc.show (\"fireStoreEvent\", \"report will not be stored: \"\n\t\t\t+ \"unable to connect to database\");\n\t return;\n\t} // if\n\n\tJsimEvent evt;\n\tString xmlStr;\n\tString\t SLASH = System.getProperty (\"file.separator\");\n\tString fname = System.getProperty (\"user.home\");\n\n Store store = new Store (\"Store\", scenarioID,\n collectAgentData (),\n propCache, modelReport);\n\tString sdata = store.toString ();\n\tSystem.out.println (sdata);\n\n\tVector data = new Vector ();\n\tdata.add (store); data.add (connInfo);\n\t\n\tif (use_xml) {\n try {\n\t if (generate_xml_files) {\n\t\t fname += SLASH + \"JSIM\" + SLASH + \"jsim\" + SLASH +\n \"jmessage\" + SLASH + \"store.xml\";\n xmlStr = XMLSerializer.serialize (data, fname);\n\t } else {\n\t\t xmlStr = XMLSerializer.serialize (data);\n\t }; // if\n evt = new JsimEvent (this, EventMap.STORE_EVT, xmlStr);\n } catch (Exception e) {\n trc.tell (\"fireStoreEvent\", e.getMessage ()); \n e.printStackTrace ();\n return;\n }\n\n\t} else {\n\t evt = new JsimEvent (this, EventMap.STORE_EVT, data);\n\t}; // if\n\n\tfireJsimEvent (evt);\n\n }", "public void visitLSTORE(LSTORE o){\n\t\t//visitStoreInstruction(StoreInstruction) is called before.\n\t\t\n\t\t// Nothing else needs to be done here.\n\t}", "void setUserStore(UserStore userStore) {\n this.userStore = userStore;\n }", "void setUserStore(UserStore userStore) {\n this.userStore = userStore;\n }", "@Override\n public Navigation run() throws Exception {\n Map<String, Object> input = null;\n Key cafeKey=null;\n String returnKey = null;\n \n //投稿ボタンを押した場合\n if(request.getParameter(\"dataPost\") != null){\n \n input = new RequestMap(request);\n \n //店舗名称をセット\n \n \n //エリア系のデータを取得\n String geohash4 = null;\n String geohash5 = null;\n String geohash6 = null;\n String geohash8 = null;\n String geohashAll = null;\n String geohashAround = null;\n String storeFullName = null;\n \n \n if(input.get(\"storeName\") != null && \n !\"\".equals(input.get(\"storeName\")) && \n !\"(null)\".equals(input.get(\"storeName\")) &&\n input.get(\"storeFlag\") != null && \n !\"\".equals(input.get(\"storeFlag\")) && \n !\"(null)\".equals(input.get(\"storeFlag\"))\n ){\n String storeMainName = CafeUtil.createStoreMainName(EscapeUtil.toHtmlStringForObject(input.get(\"storeFlag\")).trim());\n String storeSubName = EscapeUtil.toHtmlStringForObject(input.get(\"storeName\")).trim();\n storeFullName = storeMainName+\" \"+storeSubName;\n input.put(\"storeFullName\", storeFullName);\n }\n \n //住所から緯度経度を取得\n double lat = 0;\n double lng = 0;\n //時間を取得\n String nowTime = DateTimeUtil.getDateTimeString();\n if(request.getParameter(\"storeAddress\") != null && request.getParameter(\"storeAddress\") != \"\"){\n //エリア系データを取得して、DBにいるか問い合わせ\n String[] areaAry = AreaHandle.feedGeoHash(request.getParameter(\"storeAddress\"));\n if(areaAry != null){\n if(areaAry.length == 7){\n geohashAll = areaAry[0];\n geohash4 = areaAry[6];\n geohash5 = areaAry[5];\n geohash6 = areaAry[1];\n geohash8 = areaAry[2];\n lat = Double.valueOf(areaAry[3]);\n lng = Double.valueOf(areaAry[4]);\n }\n }\n //geohashの周りの値を取得\n geohashAround = CafeUtil.geohashAround(geohash6);\n \n input.put(\"lat\", String.valueOf(lat));\n input.put(\"lon\", String.valueOf(lng));\n input.put(\"geohash4\", geohash4);\n input.put(\"geohash5\", geohash5);\n input.put(\"geohash6\", geohash6);\n input.put(\"geohash8\", geohash8);\n input.put(\"geohashAround\", geohashAround);\n input.put(\"geohashAll\", geohashAll);\n input.put(\"deleteFlag\", \"0\");\n input.put(\"updateDateTime\", nowTime);\n }\n \n \n //更新の場合\n if(request.getParameter(\"key\") != null && request.getParameter(\"key\") != \"\"){\n \n //input.put(\"iine\", \"0\");\n input.put(\"key\",request.getParameter(\"key\"));\n //DBを更新\n cafeKey = service.updateData(input);\n }else{\n //フォームのパラメータを取得\n //String StoreName = (String )createStoreName(request.getParameter(\"storeName\"),request.getParameter(\"storeFlag\"));\n //input.put(\"storeName\", StoreName);\n \n //イイネ\n /*\n if(request.getParameter(\"iine\") != null && request.getParameter(\"iine\") != \"\"){\n input.put(\"iine\", 1);\n }\n */\n \n //DBに投入\n cafeKey = service.postData(input);\n \n }\n }\n \n //削除の場合\n if(request.getParameter(\"delete\") != null && request.getParameter(\"delete\") != \"\"){\n input = new RequestMap(request);\n input.put(\"deleteFlag\", \"1\");\n input.put(\"key\",request.getParameter(\"key\"));\n //DBを更新\n cafeKey = service.deleteData(input);\n }\n if(cafeKey != null){\n returnKey = String.valueOf(cafeKey.getId());\n } \n requestScope(\"returnKey\", returnKey);\n //nullがセットされないため対策\n input = notNullinput(input);\n requestScope(\"reqParam\", input);\n return forward(\"index.vm\");\n }", "public static void Goto()\n\t{\n\t\tUserLogin.Login();\n\t\t\t\t\n\t\t//Choose community\n\t\tWebElement Community= Driver.Instance.findElement(PageObjRef.CommunityTab);\n\t\tCommunity.click();\n\t\tWebElement CommunityToJoin= Driver.Instance.findElement(PageObjRef.CommunityToJoin);\n\t CommunityToJoin.click();\n\t\t\n\t}", "@FXML\n public void openFolder()\n {\n try\n {\n Desktop.getDesktop().open(nng.getStorePopulation().getParentFile());\n }\n catch (IOException e)\n {\n }\n }" ]
[ "0.6445366", "0.62688816", "0.625532", "0.61397815", "0.61171454", "0.61086655", "0.60799193", "0.6011", "0.58925927", "0.5794164", "0.57458127", "0.57186806", "0.56586605", "0.5565751", "0.5534331", "0.54250383", "0.5414188", "0.54095167", "0.54048556", "0.5359651", "0.5359166", "0.53211844", "0.5310164", "0.5307058", "0.5304034", "0.53024715", "0.5300361", "0.5274694", "0.5272071", "0.5266318", "0.5256444", "0.5249184", "0.5245364", "0.5205265", "0.52029306", "0.5201321", "0.5199024", "0.5192351", "0.5174488", "0.5173126", "0.51632077", "0.51600355", "0.514855", "0.51456326", "0.5126175", "0.5114079", "0.51118994", "0.5107506", "0.51074874", "0.5076279", "0.5067163", "0.50628483", "0.50599587", "0.50578177", "0.504522", "0.50422865", "0.5032453", "0.5028041", "0.5025238", "0.50113523", "0.49979216", "0.49787116", "0.49778375", "0.49720618", "0.4961492", "0.49595395", "0.49591163", "0.4957669", "0.49555457", "0.49554977", "0.49528837", "0.4935297", "0.49304694", "0.49297386", "0.49279577", "0.4926344", "0.49167284", "0.4911103", "0.49021426", "0.48965964", "0.48890102", "0.48712486", "0.48711643", "0.48705423", "0.4868292", "0.486489", "0.48633608", "0.4861323", "0.4858073", "0.48548943", "0.48537338", "0.48524812", "0.4852076", "0.48463762", "0.48449895", "0.48425868", "0.48414823", "0.48414823", "0.48368156", "0.48350626", "0.48305556" ]
0.0
-1
End the day for the player.
private void endDay(Player p){ p.setActions(2); ArrayList<Pet> pets = p.getPets(); for(Pet pet : pets){ pet.nextDay(); } store.nextDay(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void endGame() {\n Player player = playerManager.getWinner();\n MainActivity mainActivity = (MainActivity) this.getContext();\n updateLiveComment(\"Winner : \" + player.getName());\n mainActivity.setAlertDialog(player.getName()+\" Wins !\", \"Congratulations\", true);\n }", "@Override\n\tpublic void endGame() {\n\t\tsuper.endGame();\n\t}", "public static void end() {\n\t\tif(firstTime)\r\n\t\t\tfirstTime=false;\r\n\t\tif (over) {\r\n\t\t\treset();\r\n\t\t\tover = false;\r\n\t\t}\r\n\t\tGUI.panel.changeGame();\r\n\t}", "@Override\n public void playEnd() {\n }", "public void exit() {\n\tif (hasPlayed) {\n\t hasPlayed = false;\n\t lastExit = System.currentTimeMillis(); // note the time of exit\n\t}\n }", "public void endGame() {\n for (Player player : this.players.values()) {\n if (player.getBankroll() == this.playerAmount * DEFAULT_BANKROLL) {\n this.doPokerEnds = true;\n break;\n }\n }\n this.startingGamePlayer = ++this.startingGamePlayer % this.playerAmount;\n }", "@Override\r\n\tpublic void endTurn() {\n\t\t\r\n\t}", "protected void end() {\n drivebase.setArcade(0, 0);\n drivebase.disableTurnController();\n }", "private void endTurn() {\n currentTurn = getNextPlayer();\n }", "public void endTurn() {\n }", "public void endTurn(){\n game.setNextActivePlayer();\n myTurn = false;\n\n stb.updateData(\"playerManager\", game.getPlayerManager());\n stb.updateData(\"aktivePlayer\", game.getPlayerManager().getAktivePlayer());\n stb.updateData(\"roomList\", game.getRoomManager().getRoomList());\n\n getIntent().putExtra(\"GAME\",game);\n getIntent().putExtra(\"myTurn\", false);\n finish();\n if(!game.getPlayerManager().getPlayerList().get(whoAmI).isDead())\n startActivity(getIntent());\n else\n fcm.unbindListeners();\n }", "public void endRace(){\n\t\tstartTime =-1;\n\t\tfor(Player p: playersFinished){\n\t\t\twhile(!setPlayerID(p.getID())){\n\t\t\t\ttempNumber++;\n\t\t\t\tsetPlayerID(tempNumber);\n\t\t\t}\n\t\t}\n\t}", "private void endGame(){\n if (winner){\n Toast.makeText(this, \"Fin del Juego: Tu ganas\", Toast.LENGTH_SHORT).show();\n finish();\n } else {\n Toast.makeText(this, \"Fin del Juego: Tu pierdes\", Toast.LENGTH_SHORT).show();\n finish();\n }\n }", "public void endGame() {\n\t\twaitingPlayers.addAll(players);\n\t\tplayers.clear();\n\t\tfor(ClientThread player: waitingPlayers) {\n\t\t\tplayer.points = 0;\n\t\t\tplayer.clientCards.clear();\n\t\t}\n\t\twinners = 0;\n\t\tlosers = 0;\n\t\tpassCounter = 0;\n\t\tdeck.init();\n\t\tview.changeInAndWait(players.size(), waitingPlayers.size());\n\t\tview.writeLog(\"-------------GAME END--------------\");\n\t\tstatus = \"waiting\";\n\t\tstatusCheck();\n\t}", "boolean end() {\r\n\t\tif (this.gameOver == true)\r\n\t\t\treturn true;\r\n\t\treturn false;\r\n\t}", "public void endsGameAndSetsWinner(Player player) {\n this.winner = player.getId(); \n this.gameStarted = false; \n \n }", "public synchronized void setEndGame() {\n this.endGame = true;\n }", "protected void end() {\n \tshooterWheel.shooterWheelSpeedControllerAft.Pause();\n }", "public void buttonEndTurn() {\n\t\tendTurn();\n\t\t}", "public void endTurn() {\n\t\tturnEnd = false;\n\t\tmadeMove = false;\n\t\tcurrentPlayer.resetUndos();\n\t\tif (currentPlayer == player1) {\n\t\t\tcurrentPlayer = player2;\n\t\t} else {\n\t\t\tcurrentPlayer = player1;\n\t\t}\n\t\t//printBoard();\n\t\tSystem.out.println(\"It is now \" + currentPlayer.getName() + \"'s turn\");\n\t}", "protected void end() {\n \n \n }", "private void endTurn(){\r\n String currentPlayer = cantStop.getGameBoard().getCurrentPlayer().getName();\r\n\t\tgameOver = cantStop.getGameBoard().endTurn(didBust);\r\n\t\t\r\n\t\tif(gameOver){\r\n\t\t\tstatusLabel.setText(currentPlayer + \r\n\t\t\t\t\t\" wins! Go again?\");\r\n\t\t\tupdate();\r\n\t\t} else {\r\n\t\t\tcantStop.getGameBoard().startNewTurn();\r\n\t\t\tallowNewRoll();\r\n\t\t}\r\n\t}", "public void endGame() {\n\r\n\t\tplaying = false;\r\n\t\tstopShip();\r\n\t\tstopUfo();\r\n\t\tstopMissle();\r\n\t}", "public void end() {\n\t\tSystem.out.print(\"Game ends - \");\n\t\tif (player1.getPoints() > player2.getPoints()) {\n\t\t\tSystem.out.printf(\"%s wins by %d points\\n\", player1.getName(), player1.getPoints()-player2.getPoints());\n\t\t} else if (player1.getPoints() < player2.getPoints()) {\n\t\t\tSystem.out.printf(\"%s wins by %d points\\n\", player2.getName(), player2.getPoints()-player1.getPoints());\n\t\t} else {\n\t\t\tSystem.out.println(\"Game tied\");\n\t\t}\n\t}", "public void roundEnded() {\n\t\t\n\t\t// Deduct a life from the currently active player.\n\t\t// Increment the current round number by 1.\n\t\tdeductLife();\n\t\tincrementCurrentRoundNumber();\n\t\t\n\t\t// Switch which player is now active. \n\t\tswitchPlayer();\n\t}", "private void endGame() {\n pauseTimer();\n if (!myGameOver && !myWelcome) {\n final int result = JOptionPane.showOptionDialog(null, \n \"Are you sure you want to end this game?\",\n \"End Current Game\", JOptionPane.YES_NO_OPTION,\n JOptionPane.QUESTION_MESSAGE, null, null,\n JOptionPane.NO_OPTION);\n if (result == JOptionPane.YES_OPTION) {\n myGameOver = true;\n repaint();\n } else {\n startTimer();\n }\n }\n }", "public void endOfTurn();", "public void endTurn() {\n \t\t// add new cards to the set of usable cards\n \t\tfor (int i = 0; i < newCards.size(); i++)\n \t\t\tcards[newCards.get(i).ordinal()] += 1;\n \n \t\tnewCards.clear();\n \t\tusedCard = false;\n \n \t\tappendAction(R.string.player_ended_turn);\n \t}", "private void endMyTurn() {\n // end my turn, then.\n Entity next = clientgui.getClient().getGame()\n .getNextEntity(clientgui.getClient().getGame().getTurnIndex());\n if ((IGame.Phase.PHASE_DEPLOYMENT == clientgui.getClient().getGame()\n .getPhase())\n && (null != next)\n && (null != ce())\n && (next.getOwnerId() != ce().getOwnerId())) {\n clientgui.setDisplayVisible(false);\n }\n cen = Entity.NONE;\n clientgui.getBoardView().select(null);\n clientgui.getBoardView().highlight(null);\n clientgui.getBoardView().cursor(null);\n clientgui.bv.markDeploymentHexesFor(null);\n disableButtons();\n }", "public void endCurrentStage() {\n \n stages.getItem(currentStage - 1).setIsFinished(true);\n stages.getItem(currentStage - 1).setEndDate(super.getTimeFormat().format(LocalDateTime.now()));\n if (stages.getItem(currentStage - 1).isFinished()) {\n currentStage++;\n } else {\n System.out.println(\"Por favor, revise y emprenda acciones en su producción \" +\n \"para cumplir con los estándares de calidad, tome nuevos datos e intente de nuevo.\");\n }\n }", "void endLife();", "@Override\n public void endGameAsWin()\n {\n // UPDATE THE GAME STATE USING THE INHERITED FUNCTIONALITY\n super.endGameAsWin();\n \n // RECORD THE TIME IT TOOK TO COMPLETE THE GAME\n long gameTime = endTime.getTimeInMillis() - startTime.getTimeInMillis();\n \n // RECORD IT AS A WIN\n ((MahjongSolitaireMiniGame)miniGame).getPlayerRecord().addWin(currentLevel, gameTime);\n ((MahjongSolitaireMiniGame)miniGame).savePlayerRecord();\n \n // DISPLAY THE WIN DIALOG\n miniGame.getGUIDialogs().get(WIN_DIALOG_TYPE).setState(VISIBLE_STATE); \n\n // AND PLAY THE WIN ANIMATION\n playWinAnimation();\n \n // AND PLAY THE WIN AUDIO\n miniGame.getAudio().stop(MahjongSolitairePropertyType.SPLASH_SCREEN_SONG_CUE.toString()); \n miniGame.getAudio().stop(MahjongSolitairePropertyType.GAMEPLAY_SONG_CUE.toString());\n miniGame.getAudio().play(MahjongSolitairePropertyType.WIN_AUDIO_CUE.toString(), false);\n }", "@Override\r\n\tpublic void exit(long dateTime) {\n\t\t\r\n\t}", "public void cycleDay() {\r\n player.gametick();\r\n }", "public void onTurnEnd() {\n\n\t}", "@Override\n\tpublic void OnGameEnd() {\n\t\tsuper.OnGameEnd();\n\t}", "public void toEndingTurn() {\n }", "public void endGame() {\n dispose();\n System.out.println(\"Thank you for playing\");\n System.exit(0);\n }", "protected void end() {\n \tdrivemotors.stop();\n }", "protected void end() {\n \tnew GearCommand().start();\n \t/*if(!didZach){\n \t\tcurrentTime = time.get();\n \t\twhile(time.get() < currentTime + .5){\n \t\t\tDrive.setLeft(0);\n \t\t\tDrive.setRight(0);\n \t\t}\n \t\tcurrentTime = time.get();\n \t\twhile(time.get() < currentTime + 1.5){\n \t\t\tDrive.setLeft(-.5);\n \t\t\tDrive.setRight(-.5);\n \t\t}\n \t\tcurrentTime = time.get();\n \t\twhile(time.get() < (currentTime + .6)){\n\t\t\t\tDrive.setLeft(.5);\n\t\t\t\tDrive.setRight(-.5);\n\t\t\t}\n \t\tcurrentTime = time.get();\n \t\twhile(time.get() < currentTime + 1.5){\n \t\t\tDrive.setLeft(.5);\n \t\t\tDrive.setRight(.5);\n \t\t}\n \t\tcurrentTime = time.get();\n \t\twhile(time.get() < (currentTime + .6)){\n\t\t\t\tDrive.setLeft(-.5);\n\t\t\t\tDrive.setRight(.5);\n\t\t\t}\n \t\twhile(time.get() < currentTime + 1.5){\n \t\t\tDrive.setLeft(.5);\n \t\t\tDrive.setRight(.5);\n \t\t}\n \t}*/\n }", "ConferenceScheduleBuilderService endEvent();", "private void endGame() {\r\n\r\n m_state.setState(State.ENDING_GAME);\r\n\r\n /* find winner */\r\n for(KimTeam team : m_survivingTeams) {\r\n if(team != null) {\r\n if(!team.isOut()) {\r\n m_winner = team;\r\n }\r\n\r\n //remove survivors from m_teams so not to duplicate stats\r\n m_teams[team.m_freq] = null;\r\n }\r\n }\r\n\r\n /* end poll */\r\n if(m_poll != null) {\r\n m_poll.endPoll(m_winner, m_connectionName);\r\n m_poll = null;\r\n }\r\n\r\n /* display scoresheet */\r\n m_botAction.sendArenaMessage(\"--------Base1--------W--L --------Base2--------W--L --------Base3--------W--L --------Base4--------W--L\");\r\n\r\n if(!m_skipFirstRound) {\r\n printFormattedTeams(m_teams, m_numTeams);\r\n m_botAction.sendArenaMessage(\"------------------------- ------------------------- ------------------------- -------------------------\");\r\n }\r\n\r\n printFormattedTeams(m_survivingTeams, 4);\r\n m_botAction.sendArenaMessage(\"-------------------------------------------------------------------------------------------------------\");\r\n\r\n if(m_winner != null) {\r\n m_botAction.sendArenaMessage(\"Winner: \" + m_winner.toString(), 5);\r\n\r\n for(KimPlayer kp : m_winner) {\r\n Player p = m_botAction.getPlayer(kp.m_name);\r\n\r\n if(p != null && p.isPlaying()) {\r\n m_botAction.warpTo(p.getPlayerID(), 512, 277);\r\n }\r\n }\r\n } else {\r\n m_botAction.sendArenaMessage(\"No winner.\");\r\n }\r\n\r\n updateDB();\r\n\r\n /* announce mvp and clean up */\r\n m_botAction.scheduleTask(new TimerTask() {\r\n public void run() {\r\n m_botAction.sendArenaMessage(\"MVP: \" + m_mvp.m_name, 7);\r\n //refreshScoreboard();\r\n cleanUp();\r\n resetArena();\r\n m_state.setState(State.STOPPED);\r\n }\r\n }, 4000);\r\n }", "public static void endGame(){\n\t\tmainPanel.grid1.enabledGrid(false);\n\t\tif(speler.heleVlootKapot){\n\t\t\tmainPanel.melding2.setText(\"Helaas, de computer heeft gewonnen.\");\n\t\t}else{\n\t\t\tmainPanel.melding2.setText(\"Gefeliciteerd, u heeft gewonnen.\");\n\t\t}\n\t}", "public void endTurn() {\n controller.endTurn();\n }", "public void endGame() {\n \t\tisOver = true;\n \t\ttimeGameEnded = System.nanoTime();\n \t\tremoveAll();\n \t\trequestFocusInWindow();\n \t}", "private void gameEnd(String loser) {\n }", "public void endGameMessage() {\n gameArena.addText(endGameMsg);\n }", "protected void end() {\r\n }", "protected void end() {\r\n }", "protected void end() {\r\n }", "protected void end() {\r\n }", "public abstract void end();", "@Override\n public void endGame(){\n gameOver = true;\n }", "public void goToEnd() {\n\t\tcurrentClip.stop();\n\t\tsetPosition(currentClip.getMicrosecondLength());\n\t\tisPlaying = false;\n\t}", "protected void end() {\n\t\tshooter.stopShooter();\n\t}", "protected void end() {\n \tRobot.driveBase.stopDead();\n }", "public void endOfTurn() {\n if (playerInTurn.equals(Player.RED)) {\n playerInTurn = Player.BLUE;\n observers.turnEnds(playerInTurn, age);\n controlStrategy.playRound(this);\n return;\n }\n\n // If blue is in turn, change player in turn to red and do end-of-round processing.\n playerInTurn = Player.RED;\n\n // Calculate the age of the game in the next round.\n age = ageStrategy.calculateAge(age);\n\n // Restore the move count of all the units.\n for (Position p : world.getUnitPositions()) {\n world.getUnitAt(p).restoreMoveCount();\n }\n\n // For each city, add 6 to the current amount of production, and produce as many units as it can afford.\n for (Position p : world.getCityPositions()) {\n ModifiableCity city = world.getCityAt(p);\n\n workForceStrategy.gatherFoodAndProduction(world, p);\n\n populationStrategy.populationGrowth(world, p);\n\n // produce units!\n city.produceUnits(world, p, observers);\n }\n // Add to the counter of rounds played in the game.\n roundsPlayed++;\n\n observers.turnEnds(playerInTurn, age);\n\n controlStrategy.playRound(this);\n\n }", "protected void end() {\n \tRobot.gearIntake.setIsDown(false);\n \tRobot.gearIntake.setGearRollerSpeed(0);\n }", "protected void end() {\n \tRobot.hand.setWrist(0.0);\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end() {\n }", "protected void end( LocalDate date ) {\n\t\t//optional to implement, default noop\n\t\t}", "public void endTurnCurrent() {\n playerStatus.nActionsDone = 0;\n playerStatus.isActive = false;\n playerStatus.isFirstTurn = false;\n }", "void askEndTurn();", "public void endGame(){\n updateHighscore();\n reset();\n }", "public void end() {\n\n }", "public void end() {\n\t\tend = System.currentTimeMillis();\n\t\t\n\t\tLogger.d(\"[Stopwatch] \" + msg + \" finished in : \" + duration() + \" milliseconds.\");\n\t}", "public void endGameReached(LocalDate gameDate) {\n\t\tthis.endGameReached.setValue(true);\n\t}", "protected void end() {\n\t\tRobot.conveyor.Stop();\n\t}", "void endGame () {\n gameOver = true;\n System.out.println(\"Game over\");\n timer.cancel();\n }", "public void endGame()\r\n {\r\n for (Cell c : gameBoard.bombList)\r\n {\r\n if (c.isBomb())\r\n {\r\n if (c.getText() == \"X\")\r\n {\r\n c.setId(\"correctFlag\");\r\n }\r\n else\r\n {\r\n c.setId(\"bombClicked\");\r\n }\r\n }\r\n else if (c.getText() == \"X\")\r\n {\r\n c.setId(\"incorrectFlag\");\r\n }\r\n c.setDisable(true);\r\n }\r\n if (gameBoard.emptyRemaining == 0)\r\n {\r\n win();\r\n }\r\n else\r\n {\r\n lose();\r\n }\r\n System.out.println(\"Game Over...\");\r\n scoreBoard.resetBtn.setDisable(false);\r\n }" ]
[ "0.70474917", "0.6781529", "0.6777761", "0.67645544", "0.6745736", "0.67301965", "0.6680288", "0.6678136", "0.66201836", "0.65892017", "0.65762216", "0.6515894", "0.64942104", "0.648551", "0.64851916", "0.64842165", "0.6471328", "0.6461639", "0.6445247", "0.6436303", "0.6430269", "0.6428954", "0.6420677", "0.64004296", "0.639721", "0.6392718", "0.63825494", "0.6376614", "0.63513005", "0.63487214", "0.633885", "0.6334082", "0.6332151", "0.6329332", "0.6321585", "0.6317025", "0.6313589", "0.6313272", "0.62862104", "0.62715024", "0.6262318", "0.626111", "0.62581855", "0.6252789", "0.62514764", "0.62435055", "0.62420166", "0.62383264", "0.62383264", "0.62383264", "0.62383264", "0.6236779", "0.62360525", "0.6230213", "0.6229284", "0.6225093", "0.62205976", "0.6219529", "0.6213334", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.62113744", "0.6211372", "0.62102944", "0.6204146", "0.6201168", "0.61976904", "0.6196883", "0.6195606", "0.6189623", "0.6189", "0.6184094" ]
0.77968544
0
Day loop for the player.
private void dayLoop(Player p){ //Loop for every day. System.out.println("*******************"); System.out.println("It is now " + p.getName() + "'s turn on this day."); while(p.getActions() > 0){ System.out.println("Choose what you're going to do with the day."); System.out.println(p.getName() + " has " + p.getActions() + " actions left for the day."); System.out.println("1. Play with a pet."); System.out.println("2. Feed a pet."); System.out.println("3. Go to the store."); System.out.println("4. Print out pet status."); System.out.println("5. End the day early."); int selected = getNumber(1,5); switch(selected){ //Playing with a pet. case 1: play(p); break; //Feeding a pet. case 2: feed(p); break; //Code for the store. case 3: storeTrip(p); break; //Print Pet Status case 4: for(Pet pet : p.getPets()){ System.out.println(pet.printStatus()); } break; //Print Player inventory. case 5: p.printInventory(); //Finish the day early. case 6: p.setActions(0); break; default: System.out.println("Fatal Error."); } } endDay(p); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void cycleDay() {\r\n player.gametick();\r\n }", "protected void runEachDay() {\n \n }", "private void endDay(Player p){\r\n\t\tp.setActions(2);\r\n\t\tArrayList<Pet> pets = p.getPets();\r\n\t\tfor(Pet pet : pets){\r\n\t\t\tpet.nextDay();\r\n\t\t}\r\n\t\tstore.nextDay();\r\n\t}", "private void changeNextDay(){\n\t\tplanet.getClimate().nextDay();\n\t}", "public void dayNightCycle(boolean debug) {\r\n float distance;\r\n int timeUnit;\r\n float max;\r\n if (debug) {\r\n timeUnit = seconds - 5;\r\n max = 60 / 2f;\r\n } else {\r\n timeUnit = hours - 2;\r\n max = 24 / 2f;\r\n }\r\n\r\n if (timeUnit <= max) {\r\n distance = timeUnit;\r\n } else {\r\n distance = max - (timeUnit - max);\r\n }\r\n\r\n dayOpacity = distance / max;\r\n }", "public void run() {\r\n\t\tboolean doorgaan = true;\r\n\t\twhile (doorgaan) {\r\n\t\t\tplay();\r\n\t\t\tdoorgaan = readBoolean(\"\\n> Play another time? (y/n)?\", \"y\", \"n\");\r\n\t\t}\r\n\t}", "public void resetForNextDay(){\n board.xml.set.generateSceneCards();\n int playerCount = board.getPlayerCount();\n Player[] players = board.getPlayers();\n for(int i = 0; i < playerCount; i++) {\n players[i].setPos(\"Trailer\");\n }\n\n board.incrementDay();\n board.resetTurn();\n if(board.getDay() > this.dayLimit){\n endGame(players);\n }\n }", "private RepeatWeekdays() {}", "public static void main(String[] args){\n Executor game = new Executor();\n\n System.out.println();\n System.out.println();\n game.introduction();\n\n while (! game.gameOver){\n game.day();\n\n if (! game.gameOver){\n wait(2000);\n game.endOfDay();\n }\n\n }\n\n }", "protected void runEachHour() {\n \n }", "@Override\n public void run() {\n if (plugin.getGm().getPlayersInGame().size() < plugin.getAm().getMinPlayers()) {\n plugin.getGm().setCheckStart(true);\n plugin.getServer().getOnlinePlayers().forEach(pl -> pl.setLevel(0));\n GameState.state = GameState.LOBBY;\n cancel();\n return;\n }\n \n plugin.getGm().getPlayersInGame().stream().forEach(players -> {\n plugin.getMsg().sendActionBar(players, \"&a&lEl juego empieza en: \" + count);\n });\n\n switch (count){\n case 30:\n plugin.getMsg().sendBroadcast(\"&7El juego empezará en &c30 &7segundos\");\n break;\n case 5:\n GameState.state = GameState.GAME;\n plugin.getGm().getPlayersInGame().forEach(p -> {\n plugin.getAm().teleport(p);\n TntWars.getPlayer(p).setCleanPlayer(GameMode.SURVIVAL);\n });\n break;\n case 4:\n case 3:\n case 2:\n case 1:\n plugin.getMsg().sendBroadcast(\"&7El juego empezará en &c\" + count + \" &7segundos\");\n plugin.getGm().getPlayersInGame().forEach(p -> p.playSound(p.getLocation(), Sound.NOTE_PLING, 1F, 1F));\n break;\n case 0:\n plugin.getGm().setDañoEnCaida(false);\n\n //Iniciar hilo de la fase de esconder (Ja, still nope)\n new GameTask(plugin).runTaskTimer(plugin, 20, 20);\n cancel();\n break;\n }\n --count; \n }", "private void nextDay() {\r\n tmp.setDay(tmp.getDay() + 1);\r\n int nd = tmp.getDayOfWeek();\r\n nd++;\r\n if (nd > daysInWeek) nd -= daysInWeek;\r\n tmp.setDayOfWeek(nd);\r\n upDMYcountDMYcount();\r\n }", "@Override\n\tpublic void play() {\n\t\tSystem.out.println(\"We played Snokker today\");\n\t\t\n\t\t\n\t}", "@Override\n public void run() {\n\n try {\n LocalDateTime now = LocalDateTime.now();\n voda bot = new voda();\n\n List<Integer> notifyTime = Arrays.asList(7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23);\n int currentHour = now.getHour();\n\n ArrayList<Integer> consulted = dbmodel.MysqlCon.getFollowers();\n\n for (Integer ntime : notifyTime) {\n if (ntime == currentHour) {\n for (Integer consultedUser : consulted) {\n bot.sendTextToIdMessage(consultedUser, dbmodel.MysqlCon.getEveryDayWaterUserWaterCountView(consultedUser));\n }\n }\n }\n\n\n } catch (Exception e) {\n System.out.println();\n }\n }", "public void run() {\n while (true) {\n Date d = new Date();\n //lbldate.setText(d.toString());\n String date = d.toString();\n String arr[] = date.split(\" \");\n String dd = arr[5] + \" / \" + arr[1] + \" / \" + arr[2];\n lbldate.setText(dd);\n\n lbltime.setText(arr[3]);\n }\n }", "public void run() {\n while (true) {\n Date d = new Date();\n //lbldate.setText(d.toString());\n String date = d.toString();\n String arr[] = date.split(\" \");\n String dd = arr[5] + \" / \" + arr[1] + \" / \" + arr[2];\n lbldate.setText(dd);\n\n lbltime.setText(arr[3]);\n }\n }", "public void run()\n\t\t{\n\t\t\ttimerRunning = true;\n\t\t\tdate = new Date();\n\t\t\tstartTime = date.getTime();\n\t\t\tendTime = startTime + planet.getTimeMS();\n\t\t\tbuttonPanel.getTimeLabel().setText(\"Time: \" + planet.getTimeMS()/1000 + \" s\");\n\n\t\t\twhile(timerRunning)\n\t\t\t{\n\t\t\t\tdate = new Date();\n\t\t\t\tnowTime = date.getTime();\n\n\t\t\t\t// If the countdown has reached 0 (or less)\n\t\t\t\t// Stop the timer and other threads and end the game\n\t\t\t\tif(nowTime >= endTime)\n\t\t\t\t{\n\t\t\t\t\tstopTimer();\n\t\t\t\t\tbuttonPanel.getTimeLabel().setText(\"Time: 0 s\");\n\t\t\t\t\tstopThreads();\n\t\t\t\t\tJOptionPane.showMessageDialog(lander,\"Sorry, you ran out of time.\\nGame Over!\", \"Ran Out Of Time\", JOptionPane.INFORMATION_MESSAGE);\n\t\t\t\t\tendGame();\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tbuttonPanel.getTimeLabel().setText(\"Time: \" + (endTime-nowTime)/1000 + \" s\");\n\t\t\t\t}\n\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\tThread.sleep(1000);\n\t\t\t\t}\n\t\t\t\tcatch (InterruptedException e) {}\n\t\t\t}\n\t\t}", "@Override\r\n public int playGameLoop() {\r\n return 0;\r\n }", "public void run()\n\t{\n\t\ttry \n\t\t{\n\t\t\twhile (lost != true)\n\t\t\t{\n\t\t\t\tSystem.out.print(\"\");\n\t\t\t\twhile (view.getInGamePanel().getGameStart() == true)\n\t\t\t\t{\n\t\t\t\t\tloop();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (Exception exception) \n\t\t{\n\t\t}\n\t}", "public void loop(){\n \n \n }", "@Override\r\n\tpublic void physics() {\n\t\tSystem.out.println(\"Every Thursday evening\");\r\n\t\t\r\n\t}", "public static void playerRun()\n {\n runSound.playLooped();\n }", "public void nextDay() {\r\n\t\tif (day >= daysPerMonth[month] && !(month == 2 && day == 28) && !(month == 12 && day == 31)) {\r\n\t\t\tthis.month++;\r\n\t\t\tthis.day = 1;\r\n\t\t\tSystem.out.println();\r\n\t\t}\r\n\r\n\t\telse if (month == 2 && day == 28 && !(year % 400 == 0 || (year % 4 == 0 && year % 100 != 0))) {\r\n\t\t\tthis.month++;\r\n\t\t\tthis.day = 1;\r\n\t\t\tSystem.out.println();\r\n\t\t}\r\n\r\n\t\telse if (month == 12 && day == 31) {\r\n\t\t\tthis.year++;\r\n\t\t\tthis.month = 1;\r\n\t\t\tthis.day = 1;\r\n\t\t\tSystem.out.println(\"\\nhappy new year!!!\\n\");\r\n\t\t}\r\n\r\n\t\telse\r\n\t\t\tthis.day++;\r\n\t}", "@Override\n\t\tpublic void run() {\n\t\t\twhile(true) {\n\t\t\t\tDate ti = new Date();\n\t\t\t\tSimpleDateFormat sdf = new SimpleDateFormat(\"yyyy-MM-dd HH:mm:ss\");\n//\t\t\t\tSystem.out.println(sdf.format(ti));\n\t\t\t\tt.setText(sdf.format(ti));\n\t\t\t\t}\n\t\t}", "private void runClock() {\n new Thread(() -> {\n while (true) {\n Date d = new Date();\n lblTime.setText(Application.TIME_FORMAT.format(d));\n lblDate.setText(Application.DATE_FORMAT.format(d));\n try {\n Thread.sleep(1000);\n } catch (InterruptedException ex) {\n // ignore\n }\n }\n }).start();\n }", "public void gameLoop() {\n while (!d_TournamentEnded) {\n d_CurrentPhase.run();\n }\n }", "@Override\n\tprotected void onPause() {\n\t\tsuper.onPause();\n\t\tday();\n\t}", "@Override\r\n\t\t public void run() {\r\n\t\t\tdayElimVoteTimeout(); // this might need a catch\r\n\r\n\t\t }", "private void checkDay(int origin) {\r\n\tserver.publicMessage(players.get(origin) + \" has voted for it to remain day\");\r\n\r\n\t// if (dayVote.size() > playerIDs.size() / 2) {\r\n\tif (dayVote.size() > players.size() / 2) {\r\n\t day();\r\n\t} else if (dayVote.size() == players.size() / 2 && players.size() % 2 == 0) {\r\n\t day();\r\n\t}\r\n }", "@Override public void loop() {\n }", "public void loop(){\n\t\t\n\t}", "public static void main(String[] args) {\n\n\t\tint time=8;\n\t\tif (time<12) {\n\t\t\tSystem.out.println(\"Good morning\"); // code executes\n\t\t\t\n\t\t}\n\t\twhile (time<12) {\n\t\t\t\n\t\t\tSystem.out.println(\"Good morning\");// if condition is ture\n\t\t\ttime++;\n\t\t\t\n\t\t\t// i want to print Good Morning 5 times\n\t\t\t\n\t\t\tint i=1;\n\t\t\t\n\t\t\twhile (i<5) {\n\t\t\t\tSystem.out.println(\" Good Afternoon\");\n\t\t\t\ti++;\n\t\t\t\t\n\t\t\t}\n\t}\n\t}", "@Override\r\n public void loop() {\r\n //CodeHere\r\n }", "public void run()\n\t{\n\t\twhile (true)\n\t\t{\n\t\t\t// Get a broadcast\n\t\t\tString str = sc.nextLine();\n\t\t\t\n\t\t\t// Split the data into its elements\n\t\t\tString[] parts = str.split(\"\\0\");\n\t\t\t\n\t\t\t// Determine whether something new is playing, or nothing is playing\n\t\t\t// If nothing is playing ...\n\t\t\tif (parts[0].equals(\"nothinghere\"))\n\t\t\t{\n\t\t\t\t// ... package that as a NowPlayingEvent\n\t\t\t\tNowPlayingEvent ev = new NowPlayingEvent(null, null, null, null, colorParse(parts[1]), str);\n\t\t\t\t\n\t\t\t\t// ... keep track of it\n\t\t\t\tlastEvent = ev;\n\t\t\t\tlastWasClearEvent = true;\n\t\t\t\t\n\t\t\t\t// ... and notify all registered 'NowPlayingListener's\n\t\t\t\tfor (NowPlayingListener listener : listeners)\n\t\t\t\t\tlistener.nowPlayingSongCleared(ev);\n\t\t\t}\n\t\t\t// Otherwise, something new is playing ...\n\t\t\telse\n\t\t\t{\n\t\t\t\t// ... package that as a NowPlayingEvent\n\t\t\t\tNowPlayingEvent ev = new NowPlayingEvent(parts[0], parts[1], parts[2], parts[3], colorParse(parts[4]), str);\n\t\t\t\t\n\t\t\t\t// ... keep track of it\n\t\t\t\tlastEvent = ev;\n\t\t\t\tlastWasClearEvent = false;\n\t\t\t\t\n\t\t\t\t// ... and notify all registered 'NowPlayingListener's\n\t\t\t\tfor (NowPlayingListener listener : listeners)\n\t\t\t\t\tlistener.nowPlayingSongSet(ev);\n\t\t\t}\n\t\t}\n\t}", "@Override\r\n\tpublic void gameLoopLogic(double time) {\n\r\n\t}", "@Override\n public void loop()\n {\n }", "public void run() {\n\t\tif(y<22)\n\t\t\tgetSoulEater().y+=1;\n\t\telse\n\t\t\tgetSoulEater().y=18;\n\t}", "@Override\n\t\t\tpublic void run() {\n\t\t\t\t\n\t\t\t\twhile(true){\n\t\t\t\t\t\n\t\t\t\t\tlong time = System.currentTimeMillis();\n\t\t\t\t\tgameLoop();\n\t\t\t\t\t\n\t\t\t\t\tlong waitTime = 100 - time;\n\t\t\t\t\t\n\t\t\t\t\tif(waitTime < 10){\n\t\t\t\t\t\t\n\t\t\t\t\t\twaitTime = 10;\n\t\t\t\t\t}\n\t\t\t\t\ttry {\n\t\t\t\t\t\tThread.sleep(waitTime);\n\t\t\t\t\t} catch (InterruptedException e) {\n\t\t\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}", "@Override public void loop () {\n }", "private void advanceTime(){\n\t minute++;\n\t while (minute > 59) {\n\t minute -= 60;\n\t hour++;\n\t }\n\t while (hour > 23) {\n\t hour -= 24;\n\t day++;\n\t }\n\t while (day > 6) {\n\t day -= 7;\n\t }\n\n\t }", "public void loop(){\n\t}", "public static void boarDay (Grid grid) {\n grid.weekday = dateArray[(int) (Math.random() * 7)];\n }", "void dailyLife() {\n\t\tString action = inputPrompt.dailyOptions(dailyTime).toLowerCase();\r\n\t\tswitch(action) {\r\n\t\tcase \"exercise\":\tthis.exercise();\r\n\t\t\t\t\t\t\tbreak;\r\n\t\tcase \"study\":\t\tthis.study();\r\n\t\t\t\t\t\t\tbreak;\r\n\t\tcase \"rocket\":\t\tthis.buildRocket();\r\n\t\t\t\t\t\t\tbreak;\r\n\t\tcase \"eat\":\t\t\tthis.eat();\r\n\t\t\t\t\t\t\tbreak;\r\n\t\tcase \"meds\":\t\tthis.getEnergised();\r\n\t\t\t\t\t\t\tbreak;\r\n\t\tcase \"fun\":\t\t\tthis.haveFun();\r\n\t\t\t\t\t\t\tbreak;\r\n\t\tdefault:\t\t\tdailyLife();\r\n\t\t}\t\r\n\t}", "public void run() {\n if (!this.DATA_STORE.isShutdown()) {\n switch(clockAction) {\n case \"plusHour\":\n do {\n DATA_STORE.setHourValue(DATA_STORE.getHourValue() + 1);\n defaultStatementsInCase();\n } while(DATA_STORE.isButtonPressed());\n break;\n case \"plusMinute\":\n do {\n DATA_STORE.setMinuteValue(DATA_STORE.getMinuteValue() + 1);\n defaultStatementsInCase();\n } while(DATA_STORE.isButtonPressed());\n break;\n case \"plusSecond\":\n do {\n DATA_STORE.setSecondValue(DATA_STORE.getSecondValue() + 1);\n defaultStatementsInCase();\n } while(DATA_STORE.isButtonPressed());\n break;\n case \"minusHour\":\n do {\n DATA_STORE.setHourValue(DATA_STORE.getHourValue() - 1);\n defaultStatementsInCase();\n } while(DATA_STORE.isButtonPressed());\n break;\n case \"minusMinute\":\n do {\n DATA_STORE.setMinuteValue(DATA_STORE.getMinuteValue() - 1);\n defaultStatementsInCase();\n } while(DATA_STORE.isButtonPressed());\n break;\n case \"minusSecond\":\n do {\n DATA_STORE.setSecondValue(DATA_STORE.getSecondValue() - 1);\n defaultStatementsInCase();\n } while(DATA_STORE.isButtonPressed());\n }\n }\n }", "public static void playerWalk()\n {\n walkSound.playLooped();\n }", "public void run() {\r\n\t\twhile (currentTime < endOfTime) {\r\n\t\t\tcurrentTime++;\r\n\t\t\tfor (TimeObserver t : observers) {\r\n\t\t\t\tt.timeChanged(currentTime);\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public static void main(String[] args) {\n // TODO code application logic here\n //Percipitation p = new Percipitation(\"cm(s)\", 10);\n //Random rand = new Random();\n //System.out.println(rand.nextInt(2));\n System.out.println(\"Welcome to Weather-Tron. Here's your report: \");\n for(int i = 1 ; i <= 10; i++){\n System.out.println(\"Day \" + i + \" :\");\n Day day = new Day(); \n }\n \n }", "@Override\n public void run() {\n\n secs++;\n if (secs == 10) {\n tens++;\n secs = 0;\n }\n if (tens == 6) {\n mins++;\n tens = 0;\n secs = 0;\n }\n time = mins + \":\" + tens + \"\" + secs;\n timePlayed.setText(\"Time: \" + time);\n }", "private void gameLoop() {\n\n looping = true;\n long lastTime = System.currentTimeMillis();\n while (looping) {\n long delta = System.currentTimeMillis() - lastTime;\n if (delta >= 1000/60d) {\n view.render();\n game.update(delta);\n lastTime = System.currentTimeMillis();\n }\n }\n }", "@Override\n public void loop() {\n\n }", "@Override\n public void loop() {\n\n }", "public void run() {\r\n\t\tGameArchive ga = GameArchive.getInstance();\r\n\t\tga.newGame();\r\n\t\t_game = ga.getCurrentGame();\r\n\t\tint startRound = 1;\r\n\t\tint endRound = (int)(1.0*cardFinder.getCardsInDeck() /_playerCollection.size());\r\n\t\tint dealer = -1;\r\n\t\tint lead = 0;\r\n\t\tint inc = 1;\r\n\t\tif(go.getGameSpeed().equals(GameSpeed.QUICK_PLAY)) {\r\n\t\t\tinc = 2;\r\n\t\t\tif(_playerCollection.size() != 4) {\r\n\t\t\t\tstartRound = 2;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\r\n\t\tList<Integer> playerIds = getPlayerId();\r\n\t\tList<String> playerNames = getPlayerNames();\r\n\t\tfor (int i = 0; i < playerIds.size(); i++) {\r\n\t\t\t_game.addPlayer(playerIds.get(i), playerNames.get(i));\r\n\t\t}\r\n\t\tgameEventNotifier.notify(new NewGameEvent(playerIds,playerNames));\r\n\t\tfor (int roundId = startRound; roundId < endRound + 1; roundId = roundId + inc) {\r\n\t\t\tdealer = (dealer + 1)% _playerCollection.size();\r\n\t\t\tlead = (dealer + 1)% _playerCollection.size();\r\n\t\t\tgameEventNotifier.notify(new NewRoundEvent(roundId));\r\n\t\t\t_game.newRound(roundId);\r\n\t\t\tRound round = _game.getCurrentRound();\r\n\t\t\tCard trump = dealCards(roundId, dealer, lead);\r\n\t\t\tgameEventNotifier.notify(new NewTrumpEvent(trump));\r\n\t\t\tround.setTrump(trump);\r\n\r\n\t\t\tif(trump != null && trump.getValue().equals(Value.WIZARD)) {\r\n\t\t\t\tPlayer trumpPicker = _playerCollection.get(dealer);\r\n\t\t\t\t//_logger.info(trumpPicker.getName() + \" gets to pick trump.\");\r\n\t\t\t\ttrump = new Card(null, trumpPicker.pickTrump(), -1);\r\n\t\t\t\tgameEventNotifier.notify(new NewTrumpEvent(trump));\r\n\t\t\t\tround.setTrump(trump);\r\n\t\t\t}\r\n\t\t\tint cardsDealt = roundId;\r\n\t\t\tBid bid = bid(trump, lead, cardsDealt, round);\r\n\t\t\tif(go.getBidType().equals(BidType.HIDDEN)) {\r\n\t\t\t\tfor(IndividualBid individualBid :bid.getBids()) {\r\n\t\t\t\t\tgameEventNotifier.notify(new PlayerBidEvent(individualBid.getPlayer().getId(), individualBid.getBid()));\r\n\t\t\t\t\tround.setBid(individualBid.getPlayer().getId(), individualBid.getBid());\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tRoundSummary roundSummary = new RoundSummary();\r\n\t\t\tfor (int i = 0; i < roundId; i++) {\r\n\t\t\t\tTrickTracker trickTracker = playTrick(trump, lead, round);\r\n\t\t\t\troundSummary.addTrickTracker(trickTracker);\r\n\t\t\t\tint playerIdWhoWon = trickTracker.winningPlay().getPlayerId();\r\n\t\t\t\tlead = findPlayerIndex(playerIdWhoWon);\r\n\t\t\t}\r\n\t\t\tif(go.getBidType().equals(BidType.SECRET)) {\r\n\t\t\t\tfor(IndividualBid individualBid :bid.getBids()) {\r\n\t\t\t\t\tgameEventNotifier.notify(new PlayerBidEvent(individualBid.getPlayer().getId(), individualBid.getBid()));\r\n\t\t\t\t\tround.setBid(individualBid.getPlayer().getId(), individualBid.getBid());\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tscoreRound(roundSummary, bid, _game);\r\n\t\t\tthis.overallScores.displayScore();\r\n\t\t}\r\n\t\tCollection<Integer> winningPlayerIds = calcWinningIds();\r\n\t\tCollection<String> winningPlayers = getPlayerNames(winningPlayerIds);\r\n\t\tfor(int winningIds:winningPlayerIds) {\r\n\t\t\t_game.addWinner(winningIds);\r\n\t\t}\r\n\t\tgameEventNotifier.notify(new GameOverEvent(winningPlayerIds, winningPlayers));\r\n\t}", "private void loop() {\n mStateTimeTextView.setText(\"\" + getStateTimeMs() / 1000);\n\n switch (mState) {\n case SEEKING_HOME:\n // Really this is the area to check your GPS and heading and drive the wheels.\n\n if (getStateTimeMs() > 6000) {\n setState(State.READY);\n }\n break;\n default:\n // Catch for all the states that you know do nothing\n break;\n }\n\n }", "public void advanceDay(long day) {\n clock = Clock.offset(clock, Duration.ofDays(day));\n }", "public void run() {\n\t\tprepareVariables(true);\n\t\t\n\t\t// Prepares Map Tables for Song and Key Info.\n\t\tprepareTables();\n\t\t\n\t\t// Selects a Random Song.\n\t\tchooseSong(rgen.nextInt(0, songlist.size()-1));\n\t\t\n\t\t// Generates layout.\n\t\tgenerateLabels();\n\t\tgenerateLines();\n\t\t\n\t\t// Listeners\n\t\taddMouseListeners();\n\t\taddKeyListeners();\n\t\t\n\t\t// Game Starts\n\t\tplayGame();\n\t}", "@Override\n\tpublic void run() {\n\t\t// TODO Auto-generated method stub\n\t\t\n\t\t//while runniing\n\t\t//store a value in the class representing the\n\t\t//current frame\n\t\t//calculated by the system clock\n\t\t//and frame_rate\n\t\tlong oldTime = date.getTime();\n\t\tlong newTime;\n\t\tlong time_cum = 0;\n\t\t\n\t\twhile(true)\n\t\t{\n\t\t\tnewTime = date.getTime();\n\t\t time = oldTime - newTime;\n\t\t\toldTime = newTime;\n\t\t\t\n\t\t\ttime_cum += time;\n\t\t\t\n\t\t\tif (time_cum > frame_rate)\n\t\t\t{\n\t\t\t\t//surpassed the frame rate\n\t\t\t\t//fire a frame event\n\t\t\t\tMessage message = new Message();\n\t\t\t\t//actions that occur at every frame\n\t\t\t\tmessage.mflag = EEventMachine.EM_FRAME_TICK;\n\t\t\t\t//MessageManager.EnqueueMessage(message);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t//actions that occur at every tick\n\t\t\t\tMessage message = new Message();\n\t\t\t\tmessage.mflag = EEventMachine.EM_CLOCK_TICK;\n\t\t\t\t//MessageManager.EnqueueMessage(message);\n\t\t\t}\n\t\t\t\n\t\t\tfor (int i=0;i<CScheduler.priorityTaskList.size(); i++)\n\t\t\t{\n\t\t\t\t//scheduled for messages for events that are\n\t\t\t\t//not top priority\n\t\t\t\tMessage temp_message =new Message();\n\t\t\t\ttemp_message.mflag = EEventMachine.EM_BOOTSTRAP;\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\tif (time_cum >= temp_message.frame_rate)\n\t\t\t\t{\n\t\t\t\t\t/*CMessagePool.EnqueueMessage(temp_message);*/\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t}", "public void generateTimes() {\n\n\t\tLocalTime currentTime = PropertiesConfig.getMorningSessionBegin();\n\t\tfor (Talk talk : morningSession.getTalks()) {\n\t\t\ttalk.setTime(currentTime);\n\t\t\tcurrentTime = currentTime.plusMinutes(talk.getLength());\n\t\t}\n\n\t\tTalk lunch = new Talk(PropertiesConfig.LUNCH_TITLE);\n\t\tlunch.setTime(PropertiesConfig.getLunchBegin());\n\t\tlunchSession.addTalk(lunch);\n\n\t\tcurrentTime = PropertiesConfig.getAfternoonSessionBegin();\n\t\tfor (Talk talk : afternoonSession.getTalks()) {\n\t\t\ttalk.setTime(currentTime);\n\t\t\tcurrentTime = currentTime.plusMinutes(talk.getLength());\n\t\t}\n\n\t\tTalk meetEvent = new Talk(PropertiesConfig.MEET_EVENT_TITLE);\n\t\tmeetEvent.setTime(currentTime);\n\t\tmeetSession.addTalk(meetEvent);\n\t}", "Loop createLoop();", "public void game(){\n gameMusic.loop(pitch, volume);\n }", "public void run() {\n \twhile(true) {\n \t \tsetupGame();\n \tplayGame();\n \t}\n }", "public void playGame() {\n\t\t\r\n\t\t\r\n\t\twhile (!theModel.isGameOver()) {\r\n\t\t\tplayRoundOne();\r\n\t\t}\r\n\t\t\r\n\t}", "@Override\n public void run() {\n createScheduleFile();\n createWinnerScheduleFile();\n }", "private void setDay() {\n Boolean result = false;\n for (int i = 0; i < 7; ++i) {\n if(mAlarmDetails.getRepeatingDay(i))\n result = true;\n mAlarmDetails.setRepeatingDay(i, mAlarmDetails.getRepeatingDay(i));\n }\n if(!result)\n mAlarmDetails.setRepeatingDay((Calendar.getInstance().get(Calendar.DAY_OF_WEEK) - 1), true);\n }", "public void run() {\n board = new Board();\n\n // Initialiseer de game board and\n // print this with empty content\n initGame();\n board.paint();\n\n //speel één maal (spelers spelen om de beurt)\n do {\n playerTurn(currentPlayer);\n board.paint();\n updateGame(currentPlayer);\n\n // game-over ? print een message\n if (currentState == GameState.CROSS_WON) {\n System.out.println(\"'X' won! thanks for playing!\");\n } else if (currentState == GameState.NOUGHT_WON) {\n System.out.println(\"'O' won! thanks for playing!\");\n } else if (currentState == GameState.DRAW) {\n System.out.println(\"It's Draw! thanks for playing!\");\n }\n // andere speler's beurt\n currentPlayer = (currentPlayer == Mark.CROSS) ? Mark.NOUGHT : Mark.CROSS;\n }\n // repeat tot game-over\n while (currentState == GameState.PLAYING);\n\n }", "@Override\n public void run() {\n Thread ct = Thread.currentThread();\n while (ct == h1) {\n calcula();\n lblHora.setText(hora + \":\" + minutos + \":\" + segundos + \":\" + ampm);\n try {\n Thread.sleep(1000);\n } catch (Exception e) {\n System.out.println(e);\n }\n }\n }", "public Player playGame() {\r\n\r\n\t\tfor(int season = 0; season < 4; season++) {\r\n\r\n\t\t\t//deal out cards\r\n\t\t\tfor(int i = 0; i < state.dealAmounts[season]; i++) {\r\n\t\t\t\tfor(Player p : players) {\r\n\t\t\t\t\tp.deal(state.drawCard());\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//debug\r\n\t\t\t//show money amounts\r\n\t\t\tfor(Player p : players) {\r\n\t\t\t\tif(debugPrinting)\r\n\t\t\t\tSystem.out.println(p.name + \" : \" + p.getMoney());\r\n\t\t\t}\r\n\r\n\t\t\tstate.resetSeason();\r\n\r\n\t\t\tfor(int turn = 0; true; turn = (turn+1)%players.length) {\r\n\t\t\t\t//have a player play a card\r\n\t\t\t\tCard card = players[turn].chooseCard();\r\n\t\t\t\tCard second = null;\r\n\t\t\t\t\r\n\t\t\t\t//TODO this should be fixed to include if no players have cards\r\n\t\t\t\tif(card == null) {\r\n\t\t\t\t\tint hasHands = 0;\r\n\t\t\t\t\tfor(Player p : players) {\r\n\t\t\t\t\t\tif(p.getHand().size() != 0) {\r\n\t\t\t\t\t\t\thasHands++;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t//if no players have anything in their hand\r\n\t\t\t\t\tif(hasHands == 0) {\r\n\t\t\t\t\t\tendSeason();\r\n\t\t\t\t\t\tbreak;//break out of the season\r\n\t\t\t\t\t}\r\n\t\t\t\t\tcontinue;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tint secondPlayer = -1;\r\n\r\n\t\t\t\tif(card.getAuctionType() == AuctionType.DOUBLE) {\r\n\t\t\t\t\tsecond = card;\r\n\t\t\t\t\tcard = players[turn].chooseSecondCard(second.getArtist());\r\n\r\n\t\t\t\t\tif(card == null) {\r\n\t\t\t\t\t\tfor(int i = 0; i < players.length-1 && card == null; i++) {\r\n\t\t\t\t\t\t\tcard = players[(turn+i)%players.length].chooseSecondCard(second.getArtist());\r\n\t\t\t\t\t\t\tsecondPlayer = (turn+i)%players.length;\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\tif(card == null) {\r\n\t\t\t\t\t\t\tcard = second;\r\n\t\t\t\t\t\t\tsecond = null;\r\n\t\t\t\t\t\t\tsecondPlayer = -1;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t//card(s) selected\r\n\r\n\t\t\t\t//let the GameState know\r\n\t\t\t\tstate.sell(card.getArtist(), second != null);\r\n\r\n\t\t\t\t//check to see if the season has ended\r\n\t\t\t\t//System.out.println(state.seasonEnded());\r\n\t\t\t\tif(state.seasonEnded()) {\r\n\t\t\t\t\tendSeason();\r\n\t\t\t\t\tbreak;//this break will break out of the season\r\n\t\t\t\t}\r\n\r\n\t\t\t\t//announce card(s)\r\n\t\t\t\tfor(Player p : players) {\r\n\t\t\t\t\tp.announceCard(card, !(second == null));\r\n\t\t\t\t}\r\n\t\t\t\tif(debugPrinting)\r\n\t\t\t\tSystem.out.println(\"Player : \" + players[turn].name + \" :: \" + card + \" :: \" + second);\r\n\r\n\t\t\t\t//card(s) are ready for auction\r\n\t\t\t\tBid winningBid = null;\r\n\t\t\t\tif(card.getAuctionType() == AuctionType.FIXED_PRICE) {\r\n\t\t\t\t\twinningBid = fixedPrice(turn, players[turn].getFixedPrice());\r\n\t\t\t\t} else if(card.getAuctionType() == AuctionType.ONCE_AROUND) {\r\n\t\t\t\t\twinningBid = onceAround(turn);\r\n\t\t\t\t} else if(card.getAuctionType() == AuctionType.SEALED) {\r\n\t\t\t\t\twinningBid = sealed(turn);\r\n\t\t\t\t} else {\r\n\t\t\t\t\twinningBid = standardBidding(turn);\r\n\t\t\t\t}\r\n\r\n\t\t\t\t//let everybody know who won the auction\r\n\t\t\t\tfor(Player p : players) {\r\n\t\t\t\t\tp.announceAuctionWinner(winningBid.index, players[winningBid.index].name, winningBid.price);\r\n\t\t\t\t}\r\n\t\t\t\tif(debugPrinting)\r\n\t\t\t\tSystem.out.println(\"Auction winner: \" + players[winningBid.index].name + \":: Price : \" + winningBid.price);\r\n\r\n\t\t\t\t//The auction has been won, time to execute the order (66)\r\n\t\t\t\tif(winningBid.index == turn) {\r\n\t\t\t\t\tplayers[turn].pay(winningBid.price);\r\n\t\t\t\t\tplayers[turn].givePainting(card);\r\n\t\t\t\t\tif(second != null) {\r\n\t\t\t\t\t\tplayers[turn].givePainting(second);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(secondPlayer != -1) {\r\n\t\t\t\t\t\tplayers[secondPlayer].recive(winningBid.price/2);\r\n\t\t\t\t\t}\r\n\t\t\t\t} else {\r\n\t\t\t\t\tplayers[winningBid.index].pay(winningBid.price);\r\n\t\t\t\t\tif(secondPlayer != -1) {\r\n\t\t\t\t\t\tif(secondPlayer != winningBid.index) {\r\n\t\t\t\t\t\t\tplayers[secondPlayer].recive(winningBid.price/2);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tplayers[turn].recive(winningBid.price/2);\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tplayers[turn].recive(winningBid.price);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tplayers[winningBid.index].givePainting(card);\r\n\t\t\t\t\tif(second != null) {\r\n\t\t\t\t\t\tplayers[winningBid.index].givePainting(second);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t//debug\r\n\t\t//show money amounts\r\n\t\tfor(Player p : players) {\r\n\t\t\tif(debugPrinting)\r\n\t\t\tSystem.out.println(p.name + \" : \" + p.getMoney());\r\n\t\t}\r\n\t\t\r\n\t\tPlayer winner = null;\r\n\t\tfor(Player p : players) {\r\n\t\t\tif(winner == null || winner.getMoney() < p.getMoney()) {\r\n\t\t\t\twinner = p;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\treturn winner;\r\n\t}", "public void inputDay () {\n\t\tSystem.out.print(\"Enter a day: \");\r\n\t\tday = input.nextInt();\r\n\r\n\t}", "@Override\r\n\tpublic void showDoTimeMessage(Player player) {\n\t}", "public void run() {\r\n this.createBallsOnTopOfPaddle();\r\n this.running = true;\r\n this.runner.run(new CountdownAnimation(2, 3, sprites));\r\n this.runner.run(this);\r\n }", "@Override\n\tpublic void run() {\n\t\ttry {\n\t\t\tlong diff = ConstantUtil.setThreadStartTimer(\"01\",\"30\",null);\n\t\t\t\n\t\t\tif(diff<0){//凌晨1点30分之前则等待\n\t\t\t\tThread.sleep(0-diff);\n\t\t\t\tupdateMonthKline();\n\t\t\t}else{//凌晨1点30分后则立即启动\n\t\t\t\tupdateMonthKline();\n\t\t\t}\n\t\t\n\t\t\twhile (true){\n\t\t\t\tlong diff11 = ConstantUtil.setThreadStartTimer(\"01\",\"30\",null);\n\t\t\t\tThread.sleep(1000l*60*60*24-diff11);\n\t\t\t\tupdateMonthKline();\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "@Override\n\t\tpublic WeekDay1 nextDay() {\n\t\t\treturn SUN;\n\t\t}", "public void loop() {\n\t\tloop(1.0f, 1.0f);\n\t}", "public static void countdown(Player player) {\n Bukkit.broadcastMessage(prefix + ChatColor.YELLOW + \"Game starting in \" + count + \" seconds..\");\n new BukkitRunnable() {\n @Override\n public void run() {\n if (count == 0) {\n Bukkit.broadcastMessage(prefix + ChatColor.YELLOW + \"Teleporting players to arena\");\n for(Player onlinePlayer : Bukkit.getOnlinePlayers()) {\n\n String name = onlinePlayer.getName();\n teleport(onlinePlayer);\n }\n gameStart(player);\n cancel();\n } else {\n RainbowText text = new RainbowText(\"Teleporting players in \");\n RainbowText text2 = new RainbowText(count + \" seconds..\");\n\n for(Player player : Bukkit.getOnlinePlayers()) {\n player.sendTitle(text.getText(), text2.getText(), 1, 20, 1);\n text.moveRainbow();\n player.playSound(player.getLocation(), Sound.ENTITY_EXPERIENCE_ORB_PICKUP, 2.0F, 1.0F);\n }\n Bukkit.broadcastMessage(prefix + ChatColor.YELLOW + \"Teleporting players in \" + count + \" seconds..\");\n count--;\n\n }\n }\n }.runTaskTimer(Bukkit.getServer().getPluginManager().getPlugin(\"Seawars\"), 20L, 20L);\n }", "public void setDay(int day) {\r\n this.day = day;\r\n }", "private void doGameCycle() {\n update();\n repaint();\n }", "public void advanceTime(){\n\t\tminute++;\r\n\t\twhile (minute > 59) {\r\n\t\t\tminute -= 60;\r\n\t\t\thour++;\r\n\t\t}\r\n\t\twhile (hour > 23) {\r\n\t\t\thour -= 24;\r\n\t\t\tday++;\r\n\t\t}\r\n\t\twhile (day > 6) {\r\n\t\t\tday -= 7;\r\n\t\t\tweek++;\r\n\t\t\ttotalMoney += abonnementen * 40;\r\n\t\t}\r\n\t\twhile(week > 51) {\r\n\t\t\tweek -= 52;\r\n\t\t}\r\n\t\t//System.out.println(\"advanceTime: \"+\"week: \"+ week + \" day: \"+ day +\" hour: \" + hour +\" minute: \"+ minute+ \" Money earned = \" + Math.round(totalMoney));\r\n\t}", "private void loop() {\r\n\t\tfloat elapsed;\r\n\t\tfloat accumulated = 0f;\r\n\t\tfloat interval = 1f / TARGET_UPS;\r\n\t\tdouble time;\r\n\t\tdouble lastCall = System.nanoTime();\r\n\t\t\r\n\t\trunning = true;\r\n\t\t//loop while running and the window hasn't received a close command\r\n\t\twhile (running) {\r\n\t\t\ttime = System.nanoTime();\r\n\t\t\t\r\n\t\t\telapsed = (float) ((time-lastCall) / 1e9);\r\n\t\t\tlastCall = time;\r\n\t\t\t\r\n\t\t\taccumulated += elapsed;\r\n\t\t\t\r\n\t\t\twhile (accumulated >= interval) {\r\n\t\t\t\tupdate();\r\n\t\t\t\taccumulated -= interval;\r\n\t\t\t}\r\n\t\t\t//render once per loop, then wait until the render time slot is over before restarting\r\n\t\t\tgame.render();\r\n\t\t\tsync(lastCall/1e9);\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t}", "public void run() {\n\t\t\t\t\t\t\tcal.set(year, month, day, hour, minute);\r\n\r\n\t\t\t\t\t\t\twhile (true) {\r\n\t\t\t\t\t\t\t\tsysTime.setText(String.format(\"%02d\", cal.get(Calendar.HOUR_OF_DAY)) + \":\"\r\n\t\t\t\t\t\t\t\t\t\t+ String.format(\"%02d\", cal.get(Calendar.MINUTE)));\r\n\t\t\t\t\t\t\t\tsysDate.setText(String.format(\"%02d\", cal.get(Calendar.DAY_OF_MONTH)) + \"/\"\r\n\t\t\t\t\t\t\t\t\t\t+ String.format(\"%02d\", (cal.get(Calendar.MONTH) + 1)) + \"/\"\r\n\t\t\t\t\t\t\t\t\t\t+ String.format(\"%02d\", cal.get(Calendar.YEAR)));\r\n\t\t\t\t\t\t\t\tsysWeekday.setText(\r\n\t\t\t\t\t\t\t\t\t\tcal.getDisplayName(Calendar.DAY_OF_WEEK, Calendar.LONG, Locale.ENGLISH));\r\n\t\t\t\t\t\t\t\t// in this for loop, every flight is checked whether it's their flight time or\r\n\t\t\t\t\t\t\t\t// not in every second\r\n\t\t\t\t\t\t\t\tfor (c = 0; c < DataFlight.sizeData; c++) {\r\n\t\t\t\t\t\t\t\t\t// timeDepartureDelayCheck and timeArrivalDelayCheck are the times of flight\r\n\t\t\t\t\t\t\t\t\t// with the addition of delay\r\n\r\n\t\t\t\t\t\t\t\t\ttimeDepartureDelayCheck = LocalTime.parse(DataFlight.data[c][6])\r\n\t\t\t\t\t\t\t\t\t\t\t.plusMinutes(Integer.parseInt(DataFlight.data[c][8]));\r\n\t\t\t\t\t\t\t\t\ttimeArrivalDelayCheck = LocalTime.parse(DataFlight.data[c][7])\r\n\t\t\t\t\t\t\t\t\t\t\t.plusMinutes(Integer.parseInt(DataFlight.data[c][8]));\r\n\r\n\t\t\t\t\t\t\t\t\t// if it's time for departure, new thread of flight is started directly with\r\n\t\t\t\t\t\t\t\t\t// creating FlightThread object, but without\r\n\t\t\t\t\t\t\t\t\t// saving to any object variable. Number of current flights (rowCurrent) is\r\n\t\t\t\t\t\t\t\t\t// increased by 1\r\n\t\t\t\t\t\t\t\t\tif (timeDepartureDelayCheck.equals(LocalTime.parse(sysTime.getText()))) {\r\n\r\n\t\t\t\t\t\t\t\t\t\t(new FlightThread(c, cal, timeDepartureDelayCheck, timeArrivalDelayCheck,\r\n\t\t\t\t\t\t\t\t\t\t\t\trowCurrent)).start();\r\n\t\t\t\t\t\t\t\t\t\trowCurrent++;\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\ttry { // thread waits for 1 second (1000 ms)\r\n\t\t\t\t\t\t\t\t\tThread.sleep(1000);\r\n\t\t\t\t\t\t\t\t} catch (InterruptedException e) {\r\n\t\t\t\t\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\tcal.add(Calendar.MINUTE, 1); // and in every turn, minute is added by 1\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}", "@Override\r\n\tpublic void run() {\n\t\twhile (running) {\r\n\t\t\ttry {\r\n\t\t\tThread.sleep(INTERVAL);\r\n\t\t\t} catch (InterruptedException e) {\r\n\t\t\tLog.e(\"Jogo\", \"GameLoop Finalizado!\");\r\n\t\t\t}\r\n\t\t\tupdate();\r\n\t\t\t}\r\n\t\t\r\n\t}", "protected void runClock() {\r\n // stop gameClock while game is iconified\r\n if( isRunning && (getState() == Frame.NORMAL) ) {\r\n seconds++;\r\n\r\n int hrs = seconds / 3600;\r\n int mins = seconds / 60 - hrs * 60;\r\n int secs = seconds - mins * 60 - hrs * 3600;\r\n\r\n String strHr = (hrs < 10 ? \"0\" : \"\") + Integer.toString( hrs );\r\n String strMin = (mins < 10 ? \"0\" : \"\") + Integer.toString( mins );\r\n String strSec = (secs < 10 ? \"0\" : \"\") + Integer.toString( secs );\r\n\r\n timeMesg.setText( strHr + \":\" + strMin + \":\" + strSec );\r\n }\r\n }", "public void playLoop() {\n char choice;\n\n // start the game\n printBoard();\n\n // continue until quit or game over\n do{\n // prompt player for choice\n System.out.print (\"Slide direction (W, S, Z, A), \" +\n \"[U]ndo or [Q]uit? \");\n choice = inp.next().trim().toUpperCase().charAt(0);\n\n // respond to choice\n switch (choice) {\n case 'W':\n game.slide(SlideDirection.UP);\n break;\n case 'S':\n game.slide(SlideDirection.RIGHT);\n break;\n case 'Z':\n game.slide(SlideDirection.DOWN);\n break;\n case 'A':\n game.slide(SlideDirection.LEFT);\n break;\n case 'U':\n try {\n game.undo();\n } catch (IllegalStateException exp) {\n System.err.println (\"Can't undo now.\");\n }\n }\n printBoard();\n }while (choice != 'Q' && game.getStatus() == GameStatus.IN_PROGRESS);\n\n // Let player no how she did\n switch (game.getStatus()) {\n case IN_PROGRESS:\n System.out.println (\"Thanks for playing!\");\n break;\n case USER_WON:\n System.out.println (\"Congratz\");\n break;\n case USER_LOST:\n System.out.println (\"Sorry....!\");\n break;\n\n }\n }", "@Override\n protected String doInBackground(Void... params) {\n\n //\n //final MediaPlayer mp = MediaPlayer.create(ctx, R.raw.music1);\n //\n\n //\n SharedPreferences pref = ctx.getSharedPreferences(MainActivity.whichDay + \"-am\", MODE_PRIVATE);\n //\n\n //\n for (int i = 1; i < 6; i++) {\n\n //\n Boolean med_alarm = false;\n med_alarm = pref.getBoolean(\"med\" + i + \"-alarm\", false);\n //\n\n //\n if (med_alarm) {\n\n //\n int hour = pref.getInt(\"med\" + i + \"-hour\", 0);\n int minute = pref.getInt(\"med\" + i + \"-minute\", 0);\n //\n\n //\n\n // NOW i need todayIs - very important\n if (hour == currentHour && ((currentMinute >= (minute - 14)) && (currentMinute <= (minute - 4))) && MainActivity.todayIs.equals(MainActivity.whichDay)) {\n\n //\n switch (i) {\n case 1:\n\n makeOrange_med1 = true;\n //\n //mp.start();\n play_alarm_orange_text(getActivity());\n //\n\n break;\n case 2:\n\n makeOrange_med2 = true;\n //\n //mp.start();\n play_alarm_orange_text(getActivity());\n //\n\n break;\n case 3:\n\n makeOrange_med3 = true;\n //\n //mp.start();\n play_alarm_orange_text(getActivity());\n //\n\n break;\n case 4:\n\n makeOrange_med4 = true;\n //\n //mp.start();\n play_alarm_orange_text(getActivity());\n //\n\n break;\n case 5:\n\n makeOrange_med5 = true;\n //\n //mp.start();\n play_alarm_orange_text(getActivity());\n //\n\n break;\n default:\n\n //\n\n break;\n }\n\n\n }\n }\n\n\n //end of for loop\n }\n\n //\n return \"inPostExecute\";\n //\n\n }", "public int determineDayRandomly() {\n\t\treturn 0;\r\n\t}", "@Override\n public int onLoop() throws InterruptedException\n {\n\n // Check if player is animating at all\n if (!myPlayer().isAnimating())\n {\n // Check if fishing cycle is done\n if (!fishingDone)\n {\n // Find the fishing net\n if (getInventory().contains(303))\n {\n log(\"The script found the fishing net.\\n\");\n\n // check if inventory is empty\n if (getInventory().getEmptySlotCount() > 0)\n {\n log(\"Finding Fishing spot.\\n\");\n NPC fishingSpot = getNpcs().closest(\"Fishing spot\");\n log(\"Has it found the fishing spot: \"+fishingSpot.isVisible());\n log(\"Does the fishing spot exist: \"+fishingSpot.exists());\n //myPosition().distance(fishingSpot);\n\n if (!fishingSpot.isVisible())\n {\n // Walk to the fishing spot\n log(\"Player is walking to fishing spot.\\n\");\n getWalking().walk(fishingSpot);\n }\n else if (fishingSpot.isVisible())\n {\n // Start fishing\n log(\"Player is now fishing.\\n\");\n fishingSpot.interact(\"Net\");\n }\n } else if (getInventory().isFull())\n {\n log(\"Inventory is full.\\n\");\n log(\"Dropping a shrimp\\n\");\n getInventory().drop(\"Raw shrimps\");\n fishingDone = true;\n }\n } else\n {\n log(\"The script didn't find the fishing net.\\n\");\n }\n\n } else\n {\n if (getInventory().contains(\"Logs\"))\n {\n // Start Fire\n log(\"Starting fire.\\n\");\n getInventory().interact(\"Use\", \"TinderBox\");\n getInventory().interact(\"Use\", \"Logs\");\n gotWood = true;\n }\n\n RS2Object tree = getObjects().closest(\"Dead tree\");\n\n if (!gotWood)\n {\n // if tree can't be found\n log(\"Finding dead tree.\\n\");\n if (!tree.isVisible())\n {\n // Walk to the tree\n log(\"Walking to dead tree.\\n\");\n getWalking().walk(tree);\n }\n else if (tree.isVisible())\n {\n // Start chopping tree\n log(\"Chopping dead tree.\\n\");\n tree.interact(\"Chop down\");\n }\n }\n else if (gotWood)\n {\n if (getInventory().getEmptySlotCount() > 0)\n {\n //getGroundItems().getAll().contains()\n\n// for (GroundItem item : getGroundItems().getAll())\n// {\n// if (item != null)\n// {\n// log(item.getName());\n// }\n// }\n\n// if (getGroundItems().closest(\"Fire\").isVisible())\n// {\n// gotWood = false;\n// }\n// else\n// {\n log(\"Attempting to cook shrimps.\\n\");\n getInventory().interact(\"Use\", \"Raw shrimps\");\n objects.closest(\"Fire\").interact(\"Use\");\n getKeyboard().pressKey(32);\n// }\n }\n }\n }\n }\n\n return 5000;\n }", "@Override\n\tpublic void onRun(PlatformPlayer player) {\n\t\t\n\t}", "public void run() {\n\t\tdice.turnos(turn, this);\n\t}", "public void loopPad(Pad pad){\r\n // Laat klant een pad lopen\r\n System.out.println(\"Standaard Klant loopt nu pad:\" + pad.getPadNaam() );\r\n }", "public void timer() {\r\n date.setTime(System.currentTimeMillis());\r\n calendarG.setTime(date);\r\n hours = calendarG.get(Calendar.HOUR_OF_DAY);\r\n minutes = calendarG.get(Calendar.MINUTE);\r\n seconds = calendarG.get(Calendar.SECOND);\r\n //Gdx.app.debug(\"Clock\", hours + \":\" + minutes + \":\" + seconds);\r\n\r\n buffTimer();\r\n dayNightCycle(false);\r\n }", "public void setDay(int day)\n {\n this.day = day;\n }", "@Override\n\t\t\t\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\t\t\t\tday1.setText(daily.get(0).getText_day());\n\t\t\t\t\t\t\t\t\ttemp1.setText(daily.get(0).getHigh()+\"° / \"+daily.get(0).getLow()+\"°\");\n\t\t\t\t\t\t\t\t\tday2.setText(daily.get(1).getText_day());\n\t\t\t\t\t\t\t\t\ttemp2.setText(daily.get(1).getHigh()+\"° / \"+daily.get(1).getLow()+\"°\");\n\t\t\t\t\t\t\t\t\tday3.setText(daily.get(2).getText_day());\n\t\t\t\t\t\t\t\t\ttemp3.setText(daily.get(2).getHigh()+\"° / \"+daily.get(2).getLow()+\"°\");\n\t\t\t\t\t\t\t\t}", "public void run() {\r\n\t\tboolean repeat = true;\r\n\t\tint count = 0;\r\n\t\twhile(repeat){\r\n\t\t\tcount ++;\r\n\t\t\t//updates currency rates every hour (count>60)\r\n\t\t\tif(count > 60){\r\n\t\t\t\tcurrencies.updateRates();\r\n\t\t\t\tcount = 1;\r\n\t\t\t}\r\n\t\t\tprintStatus();\r\n\t\t\ttry{\r\n\t\t\t\tThread.sleep(60000);\r\n\t\t\t}catch(InterruptedException ex){\r\n\t\t\t\trepeat = false;\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public void run() {\n\t\tif (timeToStart > 0 && timeToStart <= 3) {\n\t\t\tfor (Player online : PlayersUtil.getPlayers()) {\n\t\t\t\tonline.sendMessage(Main.prefix() + \"UHC is starting in §6\" + String.valueOf(timeToStart) + \"§7.\");\n\t\t\t\tonline.playSound(online.getLocation(), Sound.SUCCESSFUL_HIT, 1, 0);\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (timeToStart == 1) {\n\t\t\tMain.stopCountdown();\n\t\t\tBukkit.getServer().getScheduler().scheduleSyncDelayedTask(Main.plugin, new Runnable() {\n\t\t\t\tpublic void run() {\n\t\t\t\t\tfor (Player online : PlayersUtil.getPlayers()) {\n\t\t\t\t\t\tonline.playSound(online.getLocation(), Sound.SUCCESSFUL_HIT, 1, 1);\n\t\t\t\t\t\tif (ArrayUtil.spectating.contains(online.getName())) {\n\t\t\t\t\t\t\tSpectator.getManager().set(online, false);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tonline.setAllowFlight(false);\n\t\t\t\t\t\tonline.setFlying(false);\n\t\t\t\t\t\tonline.setHealth(20.0);\n\t\t\t\t\t\tonline.setFireTicks(0);\n\t\t\t\t\t\tonline.setSaturation(20);\n\t\t\t\t\t\tonline.setLevel(0);\n\t\t\t\t\t\tonline.setExp(0);\n\t\t\t\t\t\tif (!ArrayUtil.spectating.contains(online.getName())) {\n\t\t\t\t\t\t\tonline.showPlayer(online);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tonline.awardAchievement(Achievement.OPEN_INVENTORY);\n\t\t\t\t\t\tonline.setFoodLevel(20);\n\t\t\t\t\t\tonline.getInventory().clear();\n\t\t\t\t\t\tonline.getInventory().setArmorContents(null);\n\t\t\t\t\t\tonline.setItemOnCursor(new ItemStack (Material.AIR));\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (online.getGameMode() != GameMode.SURVIVAL) {\n\t\t\t\t\t\t\tonline.setGameMode(GameMode.SURVIVAL);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tfor (PotionEffect effect : online.getActivePotionEffects()) {\n\t\t\t\t\t\t\tonline.removePotionEffect(effect.getType());\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\tonline.addPotionEffect(new PotionEffect(PotionEffectType.DAMAGE_RESISTANCE, 250, 100));\n\t\t\t\t\t\tonline.addPotionEffect(new PotionEffect(PotionEffectType.SATURATION, 6000, 100));\n\t\t\t\t\t\tonline.sendMessage(Main.prefix() + \"UHC has now started, Good luck!\");\n\t\t\t\t\t\tonline.sendMessage(Main.prefix() + \"PvP will be enabled in §6\" + Settings.getInstance().getData().getInt(\"game.pvp\") + \" §7mins in.\");\n\t\t\t\t\t\tonline.sendMessage(Main.prefix() + \"Meetup at §6\" + Settings.getInstance().getData().getInt(\"game.meetup\") + \" §7mins in.\");\n\t\t\t\t\t\tonline.sendMessage(Main.prefix() + \"Remember to read the match post: \" + Settings.getInstance().getData().getString(\"match.post\"));\n\t\t\t\t\t\tonline.sendMessage(Main.prefix() + \"/helpop questions.\");\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tGameState.setState(GameState.INGAME);\n\t\t\t\t\tScoreboards.getManager().setScore(\"§a§lPvE\", 1);\n\t\t\t\t\tScoreboards.getManager().setScore(\"§a§lPvE\", 0);\n\t\t\t\t\tScoreboards.getManager().setScore(\"§b§lMeetup\", Integer.parseInt(\"-\" + Settings.getInstance().getData().getInt(\"game.meetup\")));\n\t\t\t\t\tScoreboards.getManager().setScore(\"§b§lPvP\", Integer.parseInt(\"-\" + Settings.getInstance().getData().getInt(\"game.pvp\")));\n\t\t\t\t\tScoreboards.getManager().setScore(\"§b§lFinal heal\", -1);\n\t\t\t\t\t\n\t\t\t\t\tfor (World world : Bukkit.getWorlds()) {\n\t\t\t\t\t\tworld.setTime(0);\n\t\t\t\t\t\tworld.setDifficulty(Difficulty.HARD);\n\t\t\t\t\t\tworld.setPVP(false);\n\t\t\t\t\t\tfor (Entity mobs : world.getEntities()) {\n\t\t\t\t\t\t\tif (mobs.getType() == EntityType.BLAZE ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.CAVE_SPIDER ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.CREEPER ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.ENDERMAN ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.ZOMBIE ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.WITCH ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.WITHER ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.DROPPED_ITEM ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.GHAST ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.GIANT ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.MAGMA_CUBE ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.DROPPED_ITEM ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.SKELETON ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.SPIDER ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.SLIME ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.SILVERFISH ||\n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.SKELETON || \n\t\t\t\t\t\t\t\t\tmobs.getType() == EntityType.EXPERIENCE_ORB) {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tmobs.remove();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}, 20);\n\t\t\t\n\t\t\tBukkit.getServer().getScheduler().scheduleSyncRepeatingTask(Main.plugin, new Runnable() {\n\t\t\t\tpublic void run() {\n\t\t\t\t\tif (Scoreboards.getManager().getScoreType(\"§b§lFinal heal\") != null) {\n\t\t\t\t\t\tif ((Scoreboards.getManager().getScore(\"§b§lFinal heal\") + 1) == 0) {\n\t\t\t\t\t\t\tScoreboards.getManager().resetScore(\"§b§lFinal heal\");\n\t\t\t\t\t\t\tfor (Player online : PlayersUtil.getPlayers()) {\n\t\t\t\t\t\t\t\tonline.sendMessage(Main.prefix() + \"§6§lFinal heal!\");\n\t\t\t\t\t\t\t\tonline.playSound(online.getLocation(), Sound.NOTE_PLING, 1, 0);\n\t\t\t\t\t\t\t\tonline.setHealth(20.0);\n\t\t\t\t\t\t\t\tonline.setFireTicks(0);\n\t\t\t\t\t\t\t\tonline.setFoodLevel(20);\n\t\t\t\t\t\t\t\tonline.setSaturation(20);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif ((Scoreboards.getManager().getScore(\"§b§lFinal heal\") + 1) < 0) {\n\t\t\t\t\t\t\t\tScoreboards.getManager().setScore(\"§b§lFinal heal\", Scoreboards.getManager().getScore(\"§b§lFinal heal\") + 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif (Scoreboards.getManager().getScoreType(\"§b§lPvP\") != null) {\n\t\t\t\t\t\tif ((Scoreboards.getManager().getScore(\"§b§lPvP\") + 1) == 0) {\n\t\t\t\t\t\t\tScoreboards.getManager().resetScore(\"§b§lPvP\");\n\t\t\t\t\t\t\tfor (Player online : PlayersUtil.getPlayers()) {\n\t\t\t\t\t\t\t\tonline.sendMessage(Main.prefix() + \"PvP is now enabled, Good luck everyone.\");\n\t\t\t\t\t\t\t\tonline.playSound(online.getLocation(), Sound.NOTE_PLING, 1, 0);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tfor (World world : Bukkit.getWorlds()) {\n\t\t\t\t\t\t\t\tworld.setPVP(true);\n\t\t\t\t\t\t\t\tworld.setPVP(true);\n\t\t\t\t\t\t\t\tworld.setPVP(true);\n\t\t\t\t\t\t\t\tworld.setPVP(true);\n\t\t\t\t\t\t\t\tworld.setPVP(true);\n\t\t\t\t\t\t\t\tworld.setPVP(true);\n\t\t\t\t\t\t\t\tworld.setPVP(true);\n\t\t\t\t\t\t\t\tworld.setPVP(true);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif ((Scoreboards.getManager().getScore(\"§b§lPvP\") + 1) < 0) {\n\t\t\t\t\t\t\t\tScoreboards.getManager().setScore(\"§b§lPvP\", Scoreboards.getManager().getScore(\"§b§lPvP\") + 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif (Scoreboards.getManager().getScore(\"§b§lPvP\") == -5) {\n\t\t\t\t\t\t\t\tBukkit.broadcastMessage(Main.prefix() + \"5 minutes to pvp, do §6/stalk §7if you think you're being stalked.\");\n\t\t\t\t\t\t\t\tfor (Player online : PlayersUtil.getPlayers()) {\n\t\t\t\t\t\t\t\t\tonline.playSound(online.getLocation(), Sound.NOTE_PLING, 1, 0);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif (Scoreboards.getManager().getScore(\"§b§lPvP\") == -1) {\n\t\t\t\t\t\t\t\tBukkit.broadcastMessage(Main.prefix() + \"1 minute to pvp, do §6/stalk §7if you think you're being stalked.\");\n\t\t\t\t\t\t\t\tfor (Player online : PlayersUtil.getPlayers()) {\n\t\t\t\t\t\t\t\t\tonline.playSound(online.getLocation(), Sound.NOTE_PLING, 1, 0);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tif (Scoreboards.getManager().getScoreType(\"§b§lMeetup\") != null) {\n\t\t\t\t\t\tif ((Scoreboards.getManager().getScore(\"§b§lMeetup\") + 1) == 0) {\n\t\t\t\t\t\t\tScoreboards.getManager().resetScore(\"§b§lMeetup\");\n\t\t\t\t\t\t\tfor (Player online : PlayersUtil.getPlayers()) {\n\t\t\t\t\t\t\t\tonline.sendMessage(ChatColor.DARK_GRAY + \"==============================================\");\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\tonline.sendMessage(ChatColor.GREEN + \" Meetup has started, start headding to 0,0.\");\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\tonline.sendMessage(ChatColor.GREEN + \" Only stop for a fight, nothing else.\");\n\t\t\t\t\t\t\t\tonline.sendMessage(ChatColor.DARK_GRAY + \"==============================================\");\n\t\t\t\t\t\t\t\tonline.playSound(online.getLocation(), Sound.WITHER_DEATH, 1, 0);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif ((Scoreboards.getManager().getScore(\"§b§lMeetup\") + 1) < 0) {\n\t\t\t\t\t\t\t\tScoreboards.getManager().setScore(\"§b§lMeetup\", Scoreboards.getManager().getScore(\"§b§lMeetup\") + 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif (Scoreboards.getManager().getScore(\"§b§lMeetup\") == -1) {\n\t\t\t\t\t\t\t\tBukkit.broadcastMessage(Main.prefix() + \"1 minute to meetup, Pack your stuff and get ready to head to 0,0.\");\n\t\t\t\t\t\t\t\tfor (Player online : PlayersUtil.getPlayers()) {\n\t\t\t\t\t\t\t\t\tonline.playSound(online.getLocation(), Sound.NOTE_PLING, 1, 0);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}, 1200, 1200);\n\t\t\t\n\t\t\tBukkit.getServer().getScheduler().runTaskLater(Main.plugin, new Runnable() {\n\t\t\t\tpublic void run() {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tBukkit.getPlayer(Settings.getInstance().getData().getString(\"game.host\")).chat(\"/gamerule doMobSpawning true\");\n\t\t\t\t\t} catch (Exception e) {}\n\t\t\t\t}\n\t\t\t}, 3600);\n\t\t}\n\t\ttimeToStart -=1;\n\t}", "public void gameLoop() {\r\n // make the whites of the eyes move from side to side\r\n if (whiteRight == 210){\r\n whiteRight += 20;\r\n }\r\n else if (whiteRight == 230){\r\n whiteRight -= 30;\r\n }\r\n else if (whiteRight == 200){\r\n whiteRight += 10;\r\n }\r\n if (whiteLeft == 350){\r\n whiteLeft += 20;\r\n }\r\n else if (whiteLeft == 370){\r\n whiteLeft -= 30;\r\n }\r\n else if (whiteLeft == 340){\r\n whiteLeft += 10;\r\n }\r\n // make the eyebrows move up and down\r\n if (eyebrowMove == 150){\r\n eyebrowMove -= 100;\r\n }\r\n else if (eyebrowMove == 50){\r\n eyebrowMove += 100;\r\n }\r\n // make the mustache move up and down\r\n if (mustache == 590){\r\n mustache +=20;\r\n }\r\n else if (mustache == 610){\r\n mustache -=40;\r\n }\r\n else if (mustache == 570){\r\n mustache +=20;\r\n }\r\n // make the tongue move up and down\r\n if (tongue == 700){\r\n tongue += 15;\r\n }\r\n else if (tongue == 715){\r\n tongue -= 15;\r\n }\r\n }", "public void loop() {\n\t\tnew Thread() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\ttry {\n\t\t\t\t\tplayer = new AdvancedPlayer(new BufferedInputStream(new FileInputStream(file)));\n\t\t\t\t\tplayer.setPlayBackListener(listener = new TanksPlaybackListener(true));\n\t\t\t\t\tplayer.play();\n\t\t\t\t} catch (JavaLayerException e) {\n\t\t\t\t\t--currentlyPlaying;\n\t\t\t\t} catch (FileNotFoundException e) {\n\t\t\t\t\t--currentlyPlaying;\n\t\t\t\t}\n\t\t\t}\n\t\t}.start();\n\t}", "public void teleopPeriodic() {\n Scheduler.getInstance().run();\n rumbleInYourPants();\n turnSpindleIfNeeded();\n turnWinchIfNeeded();\n if (arcadeDrive != null) \n arcadeDrive.start();\n }", "public void cycle(){\r\n \r\n \r\n if(collision()){\r\n endtime = 1;\r\n animator.stop();\r\n }else{\r\n if(max_h == false)\r\n ch.v--;\r\n if(ch.v == 150)\r\n max_h = true;\r\n\r\n if(max_h == true & ch.v <= 330){\r\n ch.v++;\r\n if(ch.v == 330){\r\n done = true;\r\n \r\n }\r\n }\r\n }\r\n }", "public void run() {\n\t\tfor(int Index=0;Index<pac.getPath().size();Index++) { //run on the path arraylist of every pacman\n\t\t\tfullGamePath(pac, pac.getPath().get(Index).getFruit(),Index); //call the function\n\t\t\tpac.getPath().get(Index).setTime();\n\t\t}\n\t\t\n\t}", "public void playOneTurn() {\n // set running to be true\n this.running = true;\n // create 2 balls and add them to the game using function.\n this.createBalls();\n //create the paddle and place it in the bottom of the screen, middle of line.\n Paddle pad = this.createPaddle();\n //add paddle to game.\n pad.addToGame(this);\n // countdown before turn starts\n this.runner.run(new CountdownAnimation(2, 3, this.sprites));\n // use our runner to run the current animation -- which is one turn of the game\n this.runner.run(this);\n //finally remove pad before the next turn.\n pad.removeFromGame(this);\n }", "@Override\r\n\tpublic void run() {\n\t\tboolean fin = false ;\r\n\t\tString lue ;\r\n\t\twhile (!fin) {\r\n\t\t\ttry {\r\n\t\t\t\t\r\n\t\t\t\tCalendar C = Calendar.getInstance();\r\n\t\t\t\t\r\n\t\t\t\tString heure = C.get(Calendar.HOUR) + \" h \"\r\n\t\t\t\t\t\t\t\t\t\t\t+ C.get(Calendar.MINUTE) + \" m \"\r\n\t\t\t\t\t\t\t\t\t\t\t+ C.get(Calendar.SECOND) + \" s \";\r\n\t\t\t\t\r\n\t\t\t\tlue = depuisclient.readLine();\r\n\t\t\t\tSystem.out.println(lue);\r\n\t\r\n\t\t\t\tswitch (lue) {\r\n\t\t\t\tcase \"h\":\r\n\t\t\t\t\tversclient.println(\"il est\");\r\n\t\t\t\t\tversclient.println(heure);\r\n\t\t\t\t\t\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase \"\" :\r\n\t\t\t\t\tfin =true;\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tdefault:\r\n\t\t\t\t\tlue = \"\";\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\t// TODO: handle exception\r\n\t\t\t\tSystem.out.println(e.toString());\r\n\t\t\t}\r\n\r\n\r\n\r\n\r\n\t\t}\r\n\t\tstop() ;\r\n\t}", "public void run() {\n if(mPlayerGamePiece == mGame.getmCurrentlyPlaying()){\n mPlayableTiles = mGame.getmBoard().getPlayableTiles(mPlayerGamePiece);\n showGuidelines();\n mIsAllowedToPlay = true;\n }\n // Otherwise, opponent begins:\n else{\n mIsAllowedToPlay = false;\n makeAIMove();\n }\n\n }" ]
[ "0.82210594", "0.75406104", "0.6437104", "0.63342774", "0.62432957", "0.623839", "0.62349594", "0.6210869", "0.612459", "0.6073002", "0.6055034", "0.60478276", "0.6036815", "0.60247153", "0.6021768", "0.6021768", "0.60155946", "0.5977583", "0.5975712", "0.59676564", "0.5962679", "0.5947714", "0.5945818", "0.59291756", "0.5922835", "0.5861035", "0.5857009", "0.58348083", "0.58172435", "0.5816437", "0.5814577", "0.5811088", "0.578129", "0.57615346", "0.5756059", "0.57393914", "0.573437", "0.57212216", "0.5720367", "0.57198066", "0.571615", "0.57085645", "0.5696544", "0.5685667", "0.56820476", "0.5677944", "0.5674252", "0.5670281", "0.56679255", "0.56655645", "0.56655645", "0.5660806", "0.565761", "0.56562465", "0.5649912", "0.56464106", "0.5644258", "0.5642182", "0.56370825", "0.5628553", "0.5627077", "0.56058913", "0.56008136", "0.5599855", "0.5596494", "0.5586579", "0.558509", "0.55824524", "0.55787283", "0.55782986", "0.5570537", "0.55656195", "0.5560078", "0.5555489", "0.5549112", "0.554543", "0.5543112", "0.5535366", "0.5532506", "0.5531827", "0.5528316", "0.5524333", "0.5524271", "0.5518353", "0.5505404", "0.5501794", "0.55015016", "0.5501286", "0.55002683", "0.5498801", "0.5495267", "0.5489867", "0.5489438", "0.54816145", "0.54734486", "0.5470818", "0.54510367", "0.544097", "0.5439844", "0.54395205" ]
0.7801222
1
Created by yasar on 26/3/18.
public interface IMainView extends BaseView { void inflateBottomViewParent(); void moveToHomeWorkActivity(); void moveToAttendanceActivity(); void moveToMoreFragment(); void logout(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "private stendhal() {\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "public final void mo51373a() {\n }", "@Override\n public void func_104112_b() {\n \n }", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n public void init() {\n\n }", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "protected boolean func_70814_o() { return true; }", "public void gored() {\n\t\t\n\t}", "public void mo38117a() {\n }", "private void poetries() {\n\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void jugar() {\n\t\t\n\t}", "@Override\n protected void initialize() {\n\n \n }", "private static void cajas() {\n\t\t\n\t}", "private void m50366E() {\n }", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n public void init() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "private void kk12() {\n\n\t}", "@Override\n void init() {\n }", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "public void mo4359a() {\n }", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "private void init() {\n\n\t}", "@Override\n public void init() {}", "@Override\n protected void initialize() \n {\n \n }", "@Override\n protected void init() {\n }", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\n public void init() {\n\n }", "@Override\n public void init() {\n\n }", "@Override\n\tpublic void one() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\r\n\tpublic void init() {}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "private void strin() {\n\n\t}", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\r\n\tprotected void doF4() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "public void method_4270() {}", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "@Override\n public void initialize() { \n }", "@Override\n\tpublic void init() {\n\t}", "@Override\n public int describeContents() { return 0; }", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "@Override\n\tpublic void init()\n\t{\n\n\t}", "private Rekenhulp()\n\t{\n\t}", "@Override\n\tprotected void initialize() {\n\t}", "@Override\n\tprotected void initialize() {\n\t}", "public void m23075a() {\n }", "@Override\r\n\tprotected void doF8() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void doF6() {\n\t\t\r\n\t}", "public void mo6081a() {\n }", "public void mo21877s() {\n }", "public abstract void mo70713b();", "@Override\n public void initialize() {}", "@Override\n public void initialize() {}" ]
[ "0.60580546", "0.5892197", "0.5892187", "0.5819224", "0.5773928", "0.5773928", "0.57555157", "0.5734598", "0.5697012", "0.56734246", "0.5662012", "0.5656957", "0.5641303", "0.5630644", "0.5615848", "0.56047875", "0.5582985", "0.55814636", "0.55808264", "0.55698776", "0.55692905", "0.55651104", "0.55651104", "0.55651104", "0.55651104", "0.55651104", "0.55614924", "0.55505204", "0.55469817", "0.5538791", "0.5520099", "0.5520099", "0.551696", "0.54983276", "0.54983276", "0.54983276", "0.54983276", "0.54983276", "0.54983276", "0.54966724", "0.54867035", "0.54848284", "0.5480897", "0.54787487", "0.54761446", "0.5466099", "0.5450442", "0.5443843", "0.5440668", "0.543398", "0.54335594", "0.5428758", "0.5428758", "0.54270655", "0.54227054", "0.5422654", "0.5422654", "0.54199296", "0.54150015", "0.54131234", "0.54131234", "0.54131234", "0.5411495", "0.5408446", "0.5407246", "0.5407246", "0.5407246", "0.5395785", "0.53949946", "0.53942585", "0.539406", "0.5378535", "0.5378535", "0.5378535", "0.5364853", "0.53526825", "0.5352036", "0.5350686", "0.534757", "0.5343147", "0.5338132", "0.53283036", "0.53272545", "0.53272545", "0.53272545", "0.53272545", "0.53272545", "0.53272545", "0.53272545", "0.5326792", "0.5322379", "0.5309352", "0.5309352", "0.53050125", "0.5289327", "0.52783036", "0.5277085", "0.5253624", "0.52437085", "0.5240335", "0.5240335" ]
0.0
-1
Interface for crawlglobal registry of CrawlServer (host:port) and CrawlHost (hostname) objects. TODO?: Turn this into an abstract superclass which subsumes the utility methods of ServerCacheUtil.
public interface ServerCache { CrawlHost getHostFor(String host); CrawlServer getServerFor(String serverKey); /** * Utility for performing an action on every CrawlHost. * * @param action 1-argument Closure to apply to each CrawlHost */ void forAllHostsDo(Closure action); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public interface Crawler {\n int size();\n boolean visited(String link);\n void addNewLinkToSitemap(String link);\n void addToChildSitemap(String parent, String child);\n void addVisited(String s, Integer depth);\n void startCrawling(String requestid, String link, int maxDepth);\n ForkJoinPool getMainPool();\n Map<String, Collection<String>> getSiteMap();\n}", "public ServerMap(int nameServerPort) {\n servers = new HashMap<String, Server>();\n this.nameServerPort = nameServerPort;\n nameServer = new Server(ComsFormat.nameserver_hostname\n , ComsFormat.nameserver_ip, nameServerPort);\n }", "ServerEntry getServer();", "public interface IRemoteCacheServerAttributes\n extends ICommonRemoteCacheAttributes\n{\n /**\n * Gets the localPort attribute of the IRemoteCacheAttributes object.\n * <p>\n * @return The localPort value\n */\n int getServicePort();\n\n /**\n * Sets the localPort attribute of the IRemoteCacheAttributes object.\n * <p>\n * @param p\n * The new localPort value\n */\n void setServicePort( int p );\n\n /**\n * Should we try to get remotely when the request does not come in from a\n * cluster. If local L1 asks remote server R1 for element A and R1 doesn't\n * have it, should R1 look remotely? The difference is between a local and a\n * remote update. The local update stays local. Normal updates, removes,\n * etc, stay local when they come from a client. If this is set to true,\n * then they can go remote.\n * <p>\n * @return The localClusterConsistency value\n */\n boolean isAllowClusterGet();\n\n /**\n * Should cluster updates be propagated to the locals.\n * <p>\n * @param r\n * The new localClusterConsistency value\n */\n void setAllowClusterGet( boolean r );\n\n /**\n * Gets the ConfigFileName attribute of the IRemoteCacheAttributes object.\n * <p>\n * @return The configuration file name\n */\n String getConfigFileName();\n\n /**\n * Sets the ConfigFileName attribute of the IRemoteCacheAttributes object.\n * <p>\n * @param s\n * The new configuration file name\n */\n void setConfigFileName( String s );\n\n /**\n * Should we try to keep the registry alive\n * <p>\n * @param useRegistryKeepAlive the useRegistryKeepAlive to set\n */\n void setUseRegistryKeepAlive( boolean useRegistryKeepAlive );\n\n /**\n * Should we try to keep the registry alive\n * <p>\n * @return the useRegistryKeepAlive\n */\n boolean isUseRegistryKeepAlive();\n\n /**\n * @param registryKeepAliveDelayMillis the registryKeepAliveDelayMillis to set\n */\n void setRegistryKeepAliveDelayMillis( long registryKeepAliveDelayMillis );\n\n /**\n * @return the registryKeepAliveDelayMillis\n */\n long getRegistryKeepAliveDelayMillis();\n}", "Host getHost();", "public String getHost();", "public String getHost();", "public ClusterManager() throws UnknownHostException {\n\t\t// We give each server a unique name because there can be several servers\n\t\t// started on the same machine. For example several Tomcats each with a war. In\n\t\t// this case the ip addresses will overlap. Ikube can also be started as stand alone\n\t\t// just in a Jvm(which is the same as a Tomcat essentially) also they will have the\n\t\t// same ip address\n\t\tthis.ip = InetAddress.getLocalHost().getHostAddress();\n\t\tthis.address = ip + \".\" + System.nanoTime();\n\t\tthis.servers = new HashMap<String, Server>();\n\t}", "public interface GlobalServerConfiguration {\n\n /**\n * Gets the location for the AdapterConfig for the specified namespace\n */\n public String getAdapterConfigLocation(String namespace);\n\n /**\n * Gets the location of the FeedConfig for the specified namespace\n */\n public String getFeedConfigLocation(String namespace);\n\n /**\n * Gets the Feed Configuration suffix\n */\n public String getFeedConfigSuffix();\n\n /**\n * Gets the namespace\n */\n public String getFeedNamespace(String namespace);\n\n /**\n * Gets the namespace prefix\n */\n public String getFeedNamespacePrefix(String namespace);\n\n /**\n * Gets the Server port\n */\n public int getPort();\n\n /**\n * Gets the URI for the feedserver with the specified namespace\n */\n public String getServerUri(String namespace);\n\n /**\n * Gets URI prefix for Feeds\n */\n public String getFeedPathPrefix();\n\n /**\n * Gets the {@link FeedConfiguration} for the specified feed in the namespace\n * \n * @param namespace The namespace the feed is in\n * @param feedId The feed to get the {@link FeedConfiguration} for\n * @param userId User email of per user feed requested; null if not per user feed\n */\n public FeedConfiguration getFeedConfiguration(String namespace, String feedId, String userId)\n throws FeedConfigStoreException;\n\n /**\n * Get the fully qualified class name for adapter wrapper manager.\n * \n * @return fully qualified class name for adapter wrapper manager.\n */\n public String getWrapperManagerClassName();\n\n /**\n * Gets the {@link FeedConfigStore} for the Server Configuration\n */\n public FeedConfigStore getFeedConfigStore();\n\n /**\n * Get the fully qualified class name of the provider that will be used for\n * this server.\n * \n * @return fully qualified class name of the Provider.\n */\n public String getProviderClassName();\n\n @SuppressWarnings(\"unchecked\")\n public AdapterBackendPool getAdapterBackendPool(String poolId);\n\n @SuppressWarnings(\"unchecked\")\n public void setAdapterBackendPool(String poolId, AdapterBackendPool pool);\n\n public AclValidator getAclValidator();\n\n public void setAclValidator(AclValidator aclValidator);\n\n}", "S getServer();", "public interface Server {\n void register(String serverName, Class impl) throws Exception;\n\n void start() throws IOException;\n\n\n}", "public String getServerName();", "public AllHostsInfo(final Browser browser) {\n super(Tools.getString(\"ClusterBrowser.AllHosts\"), browser);\n host = null;\n }", "public interface SiteGlobal {\n\t\tpublic final static String SITE_GLOBAL_CACHE = \"site.global.cache\";\n\t}", "public BasicServerMetricsListener() {\n myServerMetrics = new ConcurrentHashMap<String, BasicServerMetrics>();\n }", "java.lang.String getHost();", "java.lang.String getHost();", "public void setHost(String host);", "public String getHost() { return host; }", "public String getHostName();", "public interface IXoClientHost {\n\n public ScheduledExecutorService getBackgroundExecutor();\n public ScheduledExecutorService getIncomingBackgroundExecutor();\n public IXoClientDatabaseBackend getDatabaseBackend();\n public KeyStore getKeyStore();\n public Thread.UncaughtExceptionHandler getUncaughtExceptionHandler();\n public InputStream openInputStreamForUrl(String url) throws IOException;\n\n public String getClientName();\n public String getClientLanguage();\n public String getClientVersionName();\n public int getClientVersionCode();\n public String getClientBuildVariant();\n public Date getClientTime();\n\n public String getDeviceModel();\n\n public String getSystemName();\n public String getSystemLanguage();\n public String getSystemVersion();\n}", "String getHost();", "public interface NetworkRegistryMBean extends NotificationBroadcaster, MBeanRegistration\n{\n /**\n * return the servers on the network\n *\n * @return\n */\n public NetworkInstance[] getServers();\n\n /**\n * add a server for a given identity that is available on the network\n *\n * @param identity\n * @param invokers\n */\n public void addServer(Identity identity, ServerInvokerMetadata invokers[]);\n\n /**\n * remove a server no longer available on the network\n *\n * @param identity\n */\n public void removeServer(Identity identity);\n\n /**\n * update the invokers for a given server\n *\n * @param identity\n * @param invokers\n */\n public void updateServer(Identity identity, ServerInvokerMetadata invokers[]);\n\n /**\n * returns true if the server with the identity is available\n *\n * @param identity\n * @return\n */\n public boolean hasServer(Identity identity);\n\n /**\n * query the network registry for <tt>0..*</tt> of servers based on a\n * filter\n *\n * @param filter\n * @return\n */\n public NetworkInstance[] queryServers(NetworkFilter filter);\n\n /**\n * change the main domain of the local server\n *\n * @param newDomain\n */\n public void changeDomain(String newDomain);\n}", "void setHostname(String hostname);", "public static interface ServerCommon\n\t{\n\t\t/**\n\t\t * Return player list.\n\t\t * @return Set<Player> currently connected players.\n\t\t * @throws RpcException On connection error.\n\t\t * @throws StateMachineNotExpectedEventException If server is not in GameCreation state.\n\t\t */\n\t\tMap<String, IPlayerConfig> getPlayerList() throws RpcException, StateMachineNotExpectedEventException;\n\t\t\n\t\t/**\n\t\t * Return the current game config.\n\t\t * @return GameConfig current game config.\n\t\t * @throws RpcException On connection error.\n\t\t * @throws StateMachineNotExpectedEventException.\n\t\t */\n\t\tIGameConfig getGameConfig() throws RpcException, StateMachineNotExpectedEventException;\t\t\t\t\t\t\t\t\n\t}", "T setHostName(String hostName);", "VirtualHostRegistry getVirtualHostRegistry();", "VirtualHostRegistry getVirtualHostRegistry();", "HashMap getRequestingHosts()\n {\n return configfile.requesting_hosts;\n }", "List<HttpServletServer> getHttpServers();", "public Server() {\r\n this(0);\r\n hashtable = new Hashtable<String,String>();\r\n }", "public String getHostname();", "HostInfo getHostInfo();", "public DnsResolve(String hostName, InetAddress server) {\n this.mHostName = hostName;\n this.mServer = server;\n }", "void host(String host);", "void host(String host);", "Builder hostName(String hostName);", "IParser setServerBaseUrl(String theUrl);", "Map getConnectionManagerMap();", "public GalileoConnector(String serverHostName, int serverPort) throws IOException {\r\n\t\tsuper(serverHostName, serverPort);\r\n\t}", "public Server get_server(String host) {\n return servers.get(host);\n }", "default String getHost()\n {\n return getString( \"host\", \"localhost:80\");\n }", "String getHostname();", "String getHostname();", "@Override\n\t\tpublic String getServerName() {\n\t\t\treturn null;\n\t\t}", "private String getHostName()\n\t{\n\t\treturn hostName;\n\t}", "Collection<? extends Service> getHost();", "public interface ServerRegisterListener {\r\n \r\n /**\r\n * Register server listener.\r\n *\r\n * @param server the server\r\n */\r\n public void registerServerListener(Server server);\r\n \r\n}", "public interface IRegisteredDiscoveryServer extends IDiscoveryServer {\r\n\t\r\n \r\n\t\r\n\t/**\r\n\t * Get the local end point associated with this IRegisteredDiscoveryServer\r\n\t * @return an IEndPointData instance made from the registration information used to generate this IRegisteredDiscoveryServer.\r\n\t */\r\n\tpublic IEndPointData getLocalEndPoint();\r\n\t\r\n\t/**\r\n\t * In addition to disconnecting from the remote discovery server machine, \r\n\t * de-registers the associated end point (name/category/boundName) and\r\n\t * terminates the associated heart beat.\t \r\n\t * This method should be called when the system exists to properly de-register the end point.\r\n\t */\r\n\t@Override\r\n\tpublic void disconnect(); \t\r\n}", "@Override\n\tpublic int hashCode() {\n\t return this.getHostname().hashCode();\n\t}", "public interface IHost {\n String getHost();\n}", "public HttpServerConfiguration() {\n this.sessionsEnabled = true;\n this.connectors = new ArrayList<HttpConnectorConfiguration>();\n this.sslConnectors = new ArrayList<HttpSslConnectorConfiguration>();\n this.minThreads = 5;\n this.maxThreads = 50;\n }", "public String getHost(){\n\t\treturn this.host;\n\t}", "public InetAddress getHost();", "String getHostName();", "String getHostName();", "public interface ServerAdapter\nextends ClusterEventAdapter\n{\n\n\tpublic abstract ClusterMessageSender getClusterMessageSender();\n\n\t/**\n\t * @return the globalNamingServer\n\t */\n\tpublic abstract GlobalNamingServer getGlobalNamingServer();\n\tpublic abstract void setGlobalNamingServer(GlobalNamingServer globalNamingServer);\n\n\tpublic ServerAuthentication getServerAuthentication();\n\tpublic void setServerAuthentication(ServerAuthentication serverAuthentication);\n\t\n\t/**\n\t * @see gov.va.med.server.tomcat.ServerLifecycleListener#addLifecycleListener(gov.va.med.server.ServerLifecycleListener)\n\t */\n\tpublic abstract void addServerLifecycleListener(ServerLifecycleListener listener);\n\n\t/**\n\t * @see gov.va.med.server.tomcat.ServerLifecycleListener#removeLifecycleListener(gov.va.med.server.ServerLifecycleListener)\n\t */\n\tpublic abstract void removeServerLifecycleListener(ServerLifecycleListener listener);\n\n\t/**\n\t * \n\t * @param applicationEvent\n\t */\n\tpublic abstract void serverLifecycleEvent(ServerLifecycleEvent applicationEvent);\n\t\n}", "@Override\n\tpublic String getServerName() {\n\t\treturn null;\n\t}", "@Override\n\tpublic String getServerName() {\n\t\treturn null;\n\t}", "public interface Dns {\n Dns SYSTEM = new Dns() {\n @Override\n public List<InetAddress> lookup(String hostname) throws UnknownHostException {\n if (hostname == null) throw new UnknownHostException(\"hostname == null\");\n return Arrays.asList(InetAddress.getAllByName(hostname));\n }\n };\n\n List<InetAddress> lookup(String hostname) throws UnknownHostException;\n}", "default String getHost() {\n return \"localhost\";\n }", "public interface CrawlerService {\n\n void processUrl(String url) throws IOException;\n}", "public String getHostName (){\n return hostName;\n }", "public interface REPServer {\n\n /**\n * The port on which all {@code REPServer} classes should be listening for\n * requests.\n */\n public static final int PORT = 1309;\n\n /**\n * Starts this {@code REPServer} processing incoming processing requests.\n */\n public void start();\n\n /**\n * Stops this {@code REPServer} processing incoming processing requests.\n */\n public void stop();\n}", "public ServerMonitor(boolean publish) {\r\n\t\tthis.domain = JMX_DOMAIN_NAME;\r\n\t\tthis.type = JMX_TYPE_NAME;\r\n\t\t\r\n\t\tif(publish) {\r\n\t\t\tregister();\r\n\t\t}\r\n\t\t\r\n\t\tstartTime = System.currentTimeMillis();\r\n\t\tversion = getClass().getPackage().getImplementationVersion();\r\n\t\tallRequestsTracker = new RequestsTracker();\r\n\t\trecentRequestsTracker = new RequestsTracker();\r\n\t\texeService = Executors.newSingleThreadScheduledExecutor();\r\n\t\tmeter = MeterMetric.newMeter(exeService, \"requests\", TimeUnit.SECONDS);\r\n\t}", "public static server getServer(){\n return thisServer;\n }", "@Override\n\t\tpublic String getHost() {\n\t\t\treturn null;\n\t\t}", "String host();", "public String getHost() {\r\n return host;\r\n }", "public interface Constants {\n String ASTYANAX_HOSTS = \"127.0.0.1:9160\";\n String DATASTAX_HOSTS = \"127.0.0.1:9042\";\n String GRAPHITE_HOSTS = \"127.0.0.1\";\n int ASTYANAX_PORT = 9160;\n int GRAPHITE_PORT = 2003;\n int WRITE_BATCH_SIZE = 20;\n int READ_BATCH_SIZE = 200;\n int NUMBER_OF_WRITE_THREADS = 10;\n int NUMBER_OF_READ_THREADS = 10;\n}", "public ServerHostNameAndTimeFilter()\n\t{\n\t\tString hostId = null;\n\t\ttry\n\t\t{\n\t\t\thostId = System.getProperty(\"examples.hostname\");\n\t\t}\n\t\tcatch (SecurityException e)\n\t\t{\n\t\t}\n\t\tif (Strings.isEmpty(hostId))\n\t\t{\n\t\t\thostId = String.valueOf(System.currentTimeMillis());\n\t\t}\n\n\t\tsetHostName(hostId);\n\t}", "public void registerWithServer();", "public ServerDef() {}", "public void setServer(URL url) {\n\n\t}", "public String hostname() {\n return this.hostname;\n }", "public String getHost() {\n return m_host;\n }", "public Server(int clientNumber) {\r\n this.clientNumber = clientNumber;\r\n hashtable = new Hashtable<String,String>();\r\n }", "public String getHost( ) {\n\t\treturn host;\n\t}", "public void createHost( String hostname );", "public void setup_servers()\n {\n // get ServerInfo\n ServerInfo t = new ServerInfo();\n // all 3 servers\n for(int i=0;i<3;i++)\n {\n // get the server IP and port info\n String t_ip = t.hmap.get(i).ip;\n int t_port = Integer.valueOf(t.hmap.get(i).port);\n Thread x = new Thread()\n {\n public void run()\n {\n try\n {\n Socket s = new Socket(t_ip,t_port);\n // SockHandle instance with svr_hdl true and rx_hdl false as this is the socket initiator\n SockHandle t = new SockHandle(s,my_ip,my_port,my_c_id,c_list,s_list,false,true,cnode);\n }\n catch (UnknownHostException e) \n {\n \tSystem.out.println(\"Unknown host\");\n \tSystem.exit(1);\n } \n catch (IOException e) \n {\n \tSystem.out.println(\"No I/O\");\n e.printStackTrace(); \n \tSystem.exit(1);\n }\n }\n };\n \n x.setDaemon(true); \t// terminate when main ends\n x.setName(\"Client_\"+my_c_id+\"_SockHandle_to_Server\"+i);\n x.start(); \t\t\t// start the thread\n }\n }", "String getHost()\n {\n return host;\n }", "public void newHost(Host aHost);", "public ServerConnection()\n {\n //Initializing of the variables used in the constructor\n this.hostAddress = \"http://localhost\";\n this.port = 8882;\n }", "public interface UrlInterceptHandler\n{\n\n\tpublic abstract CacheManager.CacheResult service(String s, Map map);\n}", "public interface Server extends Endpoint, Resetable {\n\n /**\n * is bound.\n *\n * @return bound\n */\n boolean isBound();\n\n /**\n * get channels.\n *\n * @return channels\n */\n Collection<Channel> getChannels();\n\n /**\n * get channel.\n *\n * @param remoteAddress\n * @return channel\n */\n Channel getChannel(InetSocketAddress remoteAddress);\n\n}", "String getServerName() {\n return game.z.C;\n }", "public interface MapleServerHandler {\n\t/**\n\t * Sets the packet processor to be used by the server.\n\t * @param processor the <code>MaplePacketProcessor</code> to be used by the server\n\t */\n\tpublic void setPacketProcessor(MaplePacketProcessor processor);\n\t\n\t/**\n\t * Gets all of the connections to the server as a <code>ChannelGroup</code>.\n\t * @return a <code>ChannelGroup</code> of all the connections.\n\t */\n\tpublic ChannelGroup getConnections();\n}", "public ServerService(){\n\t\tlogger.info(\"Initilizing the ServerService\");\n\t\tservers.put(1001, new Server(1001, \"Test Server1\", 5, 30, 30, ServerStatus.RUNNING));\n\t\tservers.put(1002, new Server(1002, \"Test Server2\", 5, 30, 30, ServerStatus.RUNNING));\n\t\tservers.put(1003, new Server(1003, \"Test Server3\", 5, 30, 30, ServerStatus.RUNNING));\n\t\tservers.put(1004, new Server(1004, \"Test Server4\", 5, 30, 30, ServerStatus.RUNNING));\n\t\tlogger.info(\"Initilizing the ServerService Done\");\n\t}", "public String getHost() {\n \t\treturn host;\n \t}", "public URL getServer() {\n\t\treturn null;\n\t}", "public WebServer (String sHost, int port)\t\t\t\t\t\t\t\r\n\t{\r\n\t\tthis.shost = sHost; \t\t\t\t\t\t\t\t\t\t\r\n\t\tthis.sPort = port; \t\t\t\t\t\t\t\t\t\t\r\n\t}", "Seen.AToServer getSeenAToServer();", "protected void init(Iterable<String> servers) {}", "private static String[] getServerAddress(String p_78863_0_) {\n/* */ try {\n/* 87 */ String var1 = \"com.sun.jndi.dns.DnsContextFactory\";\n/* 88 */ Class.forName(\"com.sun.jndi.dns.DnsContextFactory\");\n/* 89 */ Hashtable<Object, Object> var2 = new Hashtable<>();\n/* 90 */ var2.put(\"java.naming.factory.initial\", \"com.sun.jndi.dns.DnsContextFactory\");\n/* 91 */ var2.put(\"java.naming.provider.url\", \"dns:\");\n/* 92 */ var2.put(\"com.sun.jndi.dns.timeout.retries\", \"1\");\n/* 93 */ InitialDirContext var3 = new InitialDirContext(var2);\n/* 94 */ Attributes var4 = var3.getAttributes(\"_minecraft._tcp.\" + p_78863_0_, new String[] { \"SRV\" });\n/* 95 */ String[] var5 = var4.get(\"srv\").get().toString().split(\" \", 4);\n/* 96 */ return new String[] { var5[3], var5[2] };\n/* */ }\n/* 98 */ catch (Throwable var6) {\n/* */ \n/* 100 */ return new String[] { p_78863_0_, Integer.toString(25565) };\n/* */ } \n/* */ }", "String getIntegHost();", "public String getHostName()\n\t{\n\t\treturn hostName;\n\t}", "public String getHostName() {\n return hostName;\n }", "public String getHostName() {\n return hostName;\n }", "public String getHost() {\n return host;\n }", "public String getHost() {\n return host;\n }" ]
[ "0.59359235", "0.56746507", "0.563631", "0.54254293", "0.5425361", "0.541626", "0.541626", "0.5382826", "0.5360224", "0.5359586", "0.53587997", "0.5342503", "0.5334861", "0.5257709", "0.5251223", "0.5227662", "0.5227662", "0.5219283", "0.5210149", "0.52096725", "0.520616", "0.520307", "0.5192987", "0.5181762", "0.51442176", "0.514292", "0.51412", "0.51412", "0.5123328", "0.5113041", "0.5098465", "0.5093332", "0.50925577", "0.50888324", "0.50310814", "0.50310814", "0.502866", "0.50161165", "0.5010936", "0.50090903", "0.4981359", "0.49550495", "0.4943021", "0.4943021", "0.49372706", "0.49237072", "0.49231166", "0.49180168", "0.49173254", "0.49152315", "0.49115822", "0.49107", "0.49102944", "0.4909232", "0.4908278", "0.4908278", "0.49074882", "0.4901617", "0.4901617", "0.4889573", "0.48870796", "0.48833373", "0.4878955", "0.48763004", "0.4871449", "0.48710385", "0.48566693", "0.484614", "0.48356852", "0.48309186", "0.4823743", "0.4804792", "0.48009238", "0.4797438", "0.47909176", "0.47873786", "0.4782404", "0.47821495", "0.47759", "0.4770339", "0.47593975", "0.47577447", "0.474818", "0.4746405", "0.47457552", "0.47394246", "0.47385332", "0.47354978", "0.47342873", "0.47332618", "0.4732124", "0.473137", "0.47243625", "0.47189483", "0.47165024", "0.47080526", "0.4702051", "0.4702051", "0.46995202", "0.46995202" ]
0.69052196
0
Utility for performing an action on every CrawlHost.
void forAllHostsDo(Closure action);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "List<AcHost> all() throws Throwable;", "public interface ServerCache {\n\n CrawlHost getHostFor(String host);\n \n CrawlServer getServerFor(String serverKey);\n\n\n /**\n * Utility for performing an action on every CrawlHost. \n * \n * @param action 1-argument Closure to apply to each CrawlHost\n */\n void forAllHostsDo(Closure action);\n}", "public static void Execute ()\n\t{\n\t\tReceiveCollection (SpawnCrawler (target));\n\t\t\n\t\tList<String> initialCollection = overCollection;\n\t\t\n\t\tif ( ! initialCollection.isEmpty ())\n\t\t{\n\t\t\n\t\t\tfor (String collected : initialCollection)\n\t\t\t{\n\t\t\t\t\n\t\t\t\tif (collected.contains (\"http\"))\n\t\t\t\t\tReceiveCollection (SpawnCrawler (collected));\n\t\t\t\telse\n\t\t\t\t\tReceiveCollection (SpawnCrawler (target + collected));\n\t\t\t\t\n\t\t\t}\n\t\t\n\t\t}\n\t\t\n\t\t/*\n\t\t * Several loops should commence here where the system reiteratively goes over all the newly acquired URLs\n\t\t * so it may extend itself beyond the first and second depth.\n\t\t * However this process should be halted once it reaches a certain configurable depth.\n\t\t */\n\t\tint depth = 0;\n\t\tint newFoundings = 0;\n\t\t\n\t\tdepthLoop: while (depth <= MAX_DEPTH)\n\t\t{\n\t\t\t\n\t\t\tfor (String collected : overCollection)\n\t\t\t{\n\t\t\t\t\n\t\t\t\tif (collected.contains (\"http\"))\n\t\t\t\t\tSpawnCrawler (collected);\n\t\t\t\telse\n\t\t\t\t\tSpawnCrawler (target + collected);\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\tif (newFoundings <= 0)\n\t\t\t\tbreak depthLoop;\n\t\t\t\n\t\t\tdepth++;\n\t\t\t\t\t\t\n\t\t}\n\t\t\n\t}", "public AllHostsInfo(final Browser browser) {\n super(Tools.getString(\"ClusterBrowser.AllHosts\"), browser);\n host = null;\n }", "void host(String host);", "void host(String host);", "public synchronized void updateHosts() throws Exception {\r\n getHelper().update();\r\n }", "default void forEach(BiConsumer<? super K, ? super V> action) {\n Objects.requireNonNull(action);\n for (Node<K, V> node : entrySet()) {\n action.accept(node.getKey(), node.getValue());\n }\n }", "public void byeHost(Host aHost);", "@Override\n public void forEach(Consumer<? super T> action) {\n items.forEach(action);\n }", "org.jacorb.imr.HostInfo[] list_hosts();", "void execute(String link) throws CrawlerWorkerException;", "public void setHosts(final List<String> hosts) {\n\t\tthis.hosts = hosts;\n\t}", "abstract protected QaIOReporter performAction(Node[] nodes);", "public List<HttpHost> sniffHosts() throws IOException {\n Response response = restClient.performRequest(\"get\", \"/_nodes/http\", sniffRequestParams);\n return readHosts(response.getEntity());\n }", "public void listHosts(yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.ListClusterHostsRequest request,\n io.grpc.stub.StreamObserver<yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.ListClusterHostsResponse> responseObserver) {\n io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getListHostsMethod(), responseObserver);\n }", "public void campaign() {\r\n for (int i = 0; i < this.parties.length; i++) {\r\n while (this.parties[i].makeAction(this.constituencies, this.acts)) {}\r\n }\r\n }", "public void trustAllHosts() {\n final String TAG = \"trustAllHosts\";\n // Create a trust manager that does not validate certificate chains\n TrustManager[] trustAllCerts = new TrustManager[] { new X509TrustManager() {\n public java.security.cert.X509Certificate[] getAcceptedIssuers() {\n return new java.security.cert.X509Certificate[] {};\n }\n public void checkClientTrusted(X509Certificate[] chain, String authType) throws CertificateException {\n// Log.i(TAG, \"checkClientTrusted\");\n }\n public void checkServerTrusted(X509Certificate[] chain, String authType) throws CertificateException {\n// Log.i(TAG, \"checkServerTrusted\");\n }\n } };\n // Install the all-trusting trust manager\n try {\n SSLContext sc = SSLContext.getInstance(\"TLS\");\n sc.init(null, trustAllCerts, new java.security.SecureRandom());\n HttpsURLConnection.setDefaultSSLSocketFactory(sc.getSocketFactory());\n } catch (Exception e) {\n e.printStackTrace();\n }\n }", "public yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.ListClusterHostsResponse listHosts(yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.ListClusterHostsRequest request) {\n return io.grpc.stub.ClientCalls.blockingUnaryCall(\n getChannel(), getListHostsMethod(), getCallOptions(), request);\n }", "public void crawlSite()\n {\n /** Init the logger */\n WorkLogger.log(\"WebCrawler start at site \" + this.urlStart.getFullUrl() + \" and maxDepth = \" + this.maxDepth);\n WorkLogger.log(\"====== START ======\");\n WorkLogger.log(\"\");\n /** Save the start time of crawling */\n long startTime = System.currentTimeMillis();\n /** Start our workers */\n this.taskHandler.startTask(this.urlStart, maxDepth);\n /** Check workers finished their work; in case then all workers wait, then no ones work, that leads no more tasks -> the program finished */\n while(this.taskHandler.isEnd() == false)\n {\n /** Default timeout for 1 sec cause the socket timeout I set to 1 sec */\n try{Thread.sleep(1000);}catch(Exception e){}\n }\n this.taskHandler.stopTasks();\n /** End the log file and add the time elapsed and total sites visited */\n WorkLogger.log(\"\\r\\n====== END ======\");\n WorkLogger.log(\"Time elapsed: \" + (System.currentTimeMillis() - startTime)/1000.);\n WorkLogger.log(\"Total visited sites: \" + this.pool.getVisitedSize());\n }", "default void forEachIndexed(@NotNull IndexedConsumer<? super E> action) {\n int idx = 0;\n for (E e : this) {\n action.accept(idx++, e); // implicit null check of action\n }\n }", "public void process(CrawlTask crawlTask) {\n\n if (level == 0) {\n try {\n String boardLink = crawlTask.getUrl();\n MongoDatabase db = crawlTask.getDb();\n MongoCollection threadsCollection = db.getCollection(\"threads\");\n ForumConfig forumConfig = crawlTask.getForumConfig();\n\n List<ForumThread> threadList = new ArrayList<>();\n processBoard(forumConfig, boardLink, threadList, threadsCollection);\n System.out.println(\"***********************************************************TOTAL THREADS TO CRAWL IS: \" + threadList.size());\n for (ForumThread thread :\n threadList) {\n try {\n String link = thread.getThreadUrl();\n CrawlTask newTask = new CrawlTask(link, db, forumConfig);\n queue.push(newTask, level + 1);\n } catch (Exception e) {\n e.printStackTrace();\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n // process of this object has failed, but we just ignore it here\n }\n } else if (level == 1) {\n try {\n String threadLink = crawlTask.getUrl();\n MongoDatabase db = crawlTask.getDb();\n ForumConfig forumConfig = crawlTask.getForumConfig();\n\n\t\t\t\t/*List<ForumPost> postList = new ArrayList<>();*/\n processThread(forumConfig, threadLink, db);\n\n } catch (Exception e) {\n e.printStackTrace();\n // process of this object has failed, but we just ignore it here\n }\n }\n\n\n }", "public void listHosts(yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.ListClusterHostsRequest request,\n io.grpc.stub.StreamObserver<yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.ListClusterHostsResponse> responseObserver) {\n io.grpc.stub.ClientCalls.asyncUnaryCall(\n getChannel().newCall(getListHostsMethod(), getCallOptions()), request, responseObserver);\n }", "Host getHost();", "public void setHost(HostAgent host){\n\tthis.host = host;\n }", "public Indexer crawl() \n\t{\n\t\t// This redirection may effect performance, but its OK !!\n\t\tSystem.out.println(\"Crawling: \"+u.toString());\n\t\treturn crawl(crawlLimitDefault);\n\t}", "private Future<String> processHosts(List<String> input) {\n\t List<Future<String>> futures =\n\t \tinput.stream()\n\t .map(str -> supplyAsync(() -> callApi(str)))\n\t .collect(toList());\n\n\t // Restructure as varargs because that's what CompletableFuture.allOf requires.\n\t CompletableFuture<?>[] futuresAsVarArgs = futures\n\t .toArray(new CompletableFuture[futures.size()]);\n\n\t // Create a new future that completes once once all of the previous futures complete.\n\t CompletableFuture<Void> jobsDone = CompletableFuture.allOf(futuresAsVarArgs);\n\n\t CompletableFuture<String> output = new CompletableFuture<>();\n\n\t // Once all of the futures have completed, build out the result string from results.\n\t jobsDone.thenAccept(ignored -> {\n\t StringBuilder stringBuilder = new StringBuilder();\n\t futures.forEach(f -> {\n\t try {\n\t stringBuilder.append(f.get());\n\t } catch (Exception e) {\n\t output.completeExceptionally(e);\n\t }\n\t });\n\t output.complete(stringBuilder.toString());\n\t });\n\n\t return output;\n\t}", "private static void trustAllHosts() {\n\t\tTrustManager[] trustAllCerts = new TrustManager[] { new X509TrustManager() {\n\t\t\tpublic java.security.cert.X509Certificate[] getAcceptedIssuers() {\n\t\t\t\treturn new java.security.cert.X509Certificate[] {};\n\t\t\t}\n\n\t\t\t@Override\n\t\t\tpublic void checkClientTrusted(\n\t\t\t\t\tjava.security.cert.X509Certificate[] chain,\n\t\t\t\t\tString authType)\n\t\t\t\t\t\t\tthrows java.security.cert.CertificateException {\n\t\t\t\t// TODO Auto-generated method stub\n\n\t\t\t}\n\n\t\t\t@Override\n\t\t\tpublic void checkServerTrusted(\n\t\t\t\t\tjava.security.cert.X509Certificate[] chain,\n\t\t\t\t\tString authType)\n\t\t\t\t\t\t\tthrows java.security.cert.CertificateException {\n\t\t\t\t// TODO Auto-generated method stub\n\n\t\t\t}\n\t\t} };\n\n\t\t// Install the all-trusting trust manager\n\t\ttry {\n\t\t\tSSLContext sc = SSLContext.getInstance(\"TLS\");\n\t\t\tsc.init(null, trustAllCerts, new java.security.SecureRandom());\n\t\t\tHttpsURLConnection\n\t\t\t.setDefaultSSLSocketFactory(sc.getSocketFactory());\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "public void updateHosts(yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.UpdateClusterHostsRequest request,\n io.grpc.stub.StreamObserver<yandex.cloud.api.operation.OperationOuterClass.Operation> responseObserver) {\n io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getUpdateHostsMethod(), responseObserver);\n }", "@Override\n\tpublic void communicateNeighborHostnames() throws InterruptedException {\n\t\tList<Thread> tList= new ArrayList<Thread>();\n\t\tfor (int i = 0; i < nProc-1; i++) {\n\t\t\tint clientPid = i + 2;\n\t\t\tThread t = new Thread(new Runnable() {\n\t\t\t\t@Override\n\t\t\t\tpublic void run() {\n\t\t\t\t\tConnection conn = pidToConnMap.get(clientPid);\n\t\t\t\t\tList<Integer> clientNeighborPids = neighborMap.get(clientPid);\n\t\t\t\t\tfor (int clientNeighborPid : clientNeighborPids) {\n\t\t\t\t\t\tString neighborHostname;\n\t\t\t\t\t\tif (clientNeighborPid == 1)\n\t\t\t\t\t\t\tneighborHostname = coordinatorHostname;\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\tneighborHostname = pidToHostnameMap.get(clientNeighborPid);\n\t\t\t\t\t\t\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tconn.send(neighborHostname);\n\t\t\t\t\t\t} catch (IOException e) {\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t});\n\t\t\ttList.add(t);\n\t\t\tt.start();\n\t\t}\n\t\tfor (Thread t : tList) {\n\t\t\tt.join();\n\t\t}\n\t}", "public static void trustAllHosts() {\n\t\tTrustManager[] trustAllCerts = new TrustManager[]{new X509TrustManager() {\n\t\t\tpublic java.security.cert.X509Certificate[] getAcceptedIssuers() {\n\t\t\t\treturn new java.security.cert.X509Certificate[]{};\n\t\t\t}\n\n\t\t\tpublic void checkClientTrusted(X509Certificate[] chain,\n\t\t\t\t\tString authType) throws CertificateException {\n\t\t\t}\n\n\t\t\tpublic void checkServerTrusted(X509Certificate[] chain,\n\t\t\t\t\tString authType) throws CertificateException {\n\t\t\t}\n\t\t}};\n\n\t\t// Install the all-trusting trust manager\n\t\ttry {\n\t\t\tSSLContext sc = SSLContext.getInstance(\"TLS\");\n\t\t\tsc.init(null, trustAllCerts, new java.security.SecureRandom());\n\t\t\tHttpsURLConnection\n\t\t\t.setDefaultSSLSocketFactory(sc.getSocketFactory());\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}", "List<String> getHosts();", "public void execute() {\n for (CoordAction<PCEData,PCEData> pce : this) {\n pce.setRequestData(this.getRequestData());\n // Aggregators trigger the execution of its children PCE's before they are\n // executed themselves.\n pce.process();\n }\n }", "public void crawl(String url);", "public void updateHosts(yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.UpdateClusterHostsRequest request,\n io.grpc.stub.StreamObserver<yandex.cloud.api.operation.OperationOuterClass.Operation> responseObserver) {\n io.grpc.stub.ClientCalls.asyncUnaryCall(\n getChannel().newCall(getUpdateHostsMethod(), getCallOptions()), request, responseObserver);\n }", "protected abstract void startPing(Set<String> urls);", "public static void main(String[] args) throws Exception {\n\t\tString crawlStorageFolder = \"/data/crawl\";\r\n\t\tint numberOfCrawlers = 1;\r\n\t\t\r\n\t\tCrawlConfig config = new CrawlConfig();\r\n\t\tconfig.setCrawlStorageFolder(crawlStorageFolder);\r\n\t\tconfig.setMaxPagesToFetch(5000);\r\n\t\tconfig.setMaxDepthOfCrawling(5);\r\n\t\tconfig.setPolitenessDelay(500);\r\n\t\t\r\n\t\tconfig.setIncludeBinaryContentInCrawling(true);\r\n\t\t//config.setUserAgentString(userAgentString);\r\n\t\t\r\n\t\tPageFetcher pageFetcher = new PageFetcher(config);\r\n\t\tRobotstxtConfig robotstxtConfig = new RobotstxtConfig();\r\n\t\tRobotstxtServer robotstxtServer = new RobotstxtServer(robotstxtConfig,pageFetcher );\r\n\t\tCrawlController controller = new CrawlController(config,pageFetcher,robotstxtServer);\r\n\t\t\r\n\t\tcontroller.addSeed(\"http://www.marshall.usc.edu/\");\r\n\t\tcontroller.start(MyCrawler.class, numberOfCrawlers);\r\n\t\tSystem.out.println(\"All urls processed:\"+MyCrawler.URL_Count);\r\n\t\tSystem.out.println(\"All unique urls processed:\"+MyCrawler.hs.size());\r\n\t\tSystem.out.println(\"unique School urls processed:\"+MyCrawler.hs_uniqueSchool.size());\r\n\t\tSystem.out.println(\"unique USC urls processed:\"+MyCrawler.hs_uniqueUSC.size());\r\n\t\tSystem.out.println(\"other unique urls processed:\"+MyCrawler.hs_unique.size());\r\n\t\tSet set = MyCrawler.HM_Status.entrySet();\r\n\t Iterator i = set.iterator();\r\n\t while(i.hasNext()) {\r\n\t Map.Entry me = (Map.Entry)i.next();\r\n\t System.out.print(me.getKey() + \": \");\r\n\t System.out.println(me.getValue());\r\n\t }\r\n\t set=MyCrawler.HM_CT.entrySet();\r\n\t i = set.iterator();\r\n\t while(i.hasNext()) {\r\n\t Map.Entry me = (Map.Entry)i.next();\r\n\t System.out.print(me.getKey() + \": \");\r\n\t System.out.println(me.getValue());\r\n\t }\r\n\t System.out.println(\"F1:\"+MyCrawler.F1);\r\n\t System.out.println(\"F2:\"+MyCrawler.F2);\r\n\t System.out.println(\"F3:\"+MyCrawler.F3);\r\n\t System.out.println(\"F4:\"+MyCrawler.F4);\r\n\t \r\n\t System.out.println(\"Size < 1kb:\"+MyCrawler.size1);\r\n\t System.out.println(\"Size 1kb~10kb:\"+MyCrawler.size2);\r\n\t System.out.println(\"Size 10kb~100kb:\"+MyCrawler.size3);\r\n\t System.out.println(\"Size 100kb~1mb:\"+MyCrawler.size4);\r\n\t System.out.println(\"Size > 1mb:\"+MyCrawler.size5);\r\n\t \r\n\t}", "public void run() {\n LOG.info(\"Starting Contentful crawling\");\n //Partition of ContentTypes: TRUE: vocabularies and FALSE: non-vocabularies/web content\n Map<Boolean, List<CMAContentType>> contentTypes = getContentTypes();\n List<CMAContentType> vocContentTypes = contentTypes.get(Boolean.TRUE);\n List<CMAContentType> webContentTypes = contentTypes.get(Boolean.FALSE);\n\n //Extract vocabularies meta data\n VocabularyTerms vocabularyTerms = getVocabularyTerms(vocContentTypes);\n\n //Mapping generator can be re-used for all content types\n MappingGenerator mappingGenerator = new MappingGenerator(vocContentTypes);\n\n //Gets the ContentType.resourceId for news and articles, which vary by space\n newsContentTypeId = getContentTypeId(webContentTypes, configuration.getNewsContentType());\n articleContentTypeId = getContentTypeId(webContentTypes, configuration.getArticleContentType());\n projectContentTypeId = getContentTypeId(webContentTypes, configuration.getProjectContentType());\n\n\n //Crawl all Content Types, except for vocabularies\n crawlContentTypes(webContentTypes, mappingGenerator, vocabularyTerms);\n LOG.info(\"Contentful crawling has finished\");\n }", "public static <T> void forEach(List<T> list, Consumer<T> c) {\n\t\tfor (T t : list) {\n\t\t\tc.accept(t);\n\t\t}\n\t}", "public void forEach(Consumer<GeometricalObject> action);", "Collection<? extends Service> getHost();", "public void setHostList(List<Host> hostLst){\r\n\t\tthis.hostList = hostLst;\r\n\t}", "Collection<PageLink> crawl(CrawlerArgs args);", "Target(String host) {\n try {\n address = new InetSocketAddress(InetAddress.getByName(host), 80);\n } catch (UnknownHostException e) {\n// e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates.\n failure = e;\n }\n }", "private Set<Host> getHosts(StaticPacketTrace trace) {\n IPCriterion ipv4Criterion = ((IPCriterion) trace.getInitialPacket()\n .getCriterion(Criterion.Type.IPV4_DST));\n IPCriterion ipv6Criterion = ((IPCriterion) trace.getInitialPacket()\n .getCriterion(Criterion.Type.IPV6_DST));\n Set<Host> hosts = new HashSet<>();\n if (ipv4Criterion != null) {\n hosts.addAll(hostNib.getHostsByIp(ipv4Criterion.ip().address()));\n }\n if (ipv6Criterion != null) {\n hosts.addAll(hostNib.getHostsByIp(ipv6Criterion.ip().address()));\n }\n EthCriterion ethCriterion = ((EthCriterion) trace.getInitialPacket()\n .getCriterion(Criterion.Type.ETH_DST));\n if (ethCriterion != null) {\n hosts.addAll(hostNib.getHostsByMac(ethCriterion.mac()));\n }\n return hosts;\n }", "public void run() {\n\t\t\tString html = \"\";\n\t\t\ttry {\n\t\t\t\thtml = HTTPFetcher.fetchHTML(this.url);\n\t\t\t} catch (UnknownHostException e) {\n\t\t\t\tSystem.out.println(\"Unknown host\");\n\t\t\t} catch (MalformedURLException e) {\n\t\t\t\tSystem.out.println(\"MalformedURL\");\n\t\t\t} catch (IOException e) {\n\t\t\t\tSystem.out.println(\"IOException\");\n\t\t\t}\n\t\t\ttry {\n\t\t\t\tif(html != null) {\n\t\t\t\t\tthis.newLinks = LinkParser.listLinks(new URL(this.url), html);\n\t\t\t\t}\n\t\t\t} catch (MalformedURLException e) {\n\t\t\t\tSystem.out.println(\"MalformedURL\");\n\t\t\t}\n\t\t\tif(newLinks != null) {\n\t\t\t\tfor(URL theURL : newLinks) {\n\t\t\t\t\tif(!(urls.contains(theURL))) {\n\t\t\t\t\t\tsynchronized(urls) {\n\t\t\t\t\t\t\turls.add(theURL);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tinnerCrawl(theURL, limit);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tInvertedIndex local = new InvertedIndex();\n\t\t\t\tString no_html = HTMLCleaner.stripHTML(html.toString());\n\t\t\t\tString[] the_words = WordParser.parseWords(no_html);\n\t\t\t\tlocal.addAll(the_words, this.url);\n\t\t\t\tindex.addAll(local);\n\t\t\t}\n\t\t}", "private static void trustAllHosts() {\n TrustManager[] trustAllCerts = new TrustManager[]{new X509TrustManager() {\n public java.security.cert.X509Certificate[] getAcceptedIssuers() {\n return new java.security.cert.X509Certificate[]{};\n }\n\n public void checkClientTrusted(X509Certificate[] chain, String authType) {\n }\n\n public void checkServerTrusted(X509Certificate[] chain, String authType) {\n }\n }};\n // Install the all-trusting trust manager\n try {\n SSLContext sc = SSLContext.getInstance(\"TLS\");\n sc.init(null, trustAllCerts, new java.security.SecureRandom());\n HttpsURLConnection.setDefaultSSLSocketFactory(sc.getSocketFactory());\n } catch (Exception e) {\n e.printStackTrace();\n }\n }", "public void execute(){\n\t\tfor(Instruction currentInstn:this.instns){\n\t\t\tcurrentInstn.execute();\n\t\t}\n\t}", "String runFoldL(THost host, String accClassname);", "public void crawl(final String url, final String target) throws IOException;", "public com.google.common.util.concurrent.ListenableFuture<yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.ListClusterHostsResponse> listHosts(\n yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.ListClusterHostsRequest request) {\n return io.grpc.stub.ClientCalls.futureUnaryCall(\n getChannel().newCall(getListHostsMethod(), getCallOptions()), request);\n }", "public void checkActions() {\n\t\tfor (BaseAction ba : this.actions) {\n\t\t\tba.checkAction();\n\t\t}\n\t}", "@Override\n\tpublic void execute() {\n\t\tfor(int i=0;i<coms.length;i++)\n\t\t\tcoms[i].execute();\n\t}", "public void setHosts(List<String> hosts) {\n setProperty(HOSTS, hosts);\n }", "Set<Host> getAllowedHosts();", "public com.google.common.util.concurrent.ListenableFuture<yandex.cloud.api.operation.OperationOuterClass.Operation> updateHosts(\n yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.UpdateClusterHostsRequest request) {\n return io.grpc.stub.ClientCalls.futureUnaryCall(\n getChannel().newCall(getUpdateHostsMethod(), getCallOptions()), request);\n }", "@Override\n\tpublic List<Facility_Host> findAll() throws SystemException {\n\t\treturn findAll(QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);\n\t}", "public void processAction(CIDAction action);", "default void dispatchConsumers() {\n\t\tthis.getItemListeners().forEach(Runnable::run);\n\t}", "public List<String> getHosts() {\n\t\treturn hosts;\n\t}", "@Override\n\tpublic void all() {\n\t\t\n\t}", "public interface Crawler {\n int size();\n boolean visited(String link);\n void addNewLinkToSitemap(String link);\n void addToChildSitemap(String parent, String child);\n void addVisited(String s, Integer depth);\n void startCrawling(String requestid, String link, int maxDepth);\n ForkJoinPool getMainPool();\n Map<String, Collection<String>> getSiteMap();\n}", "public void discoverTargets(IProgressMonitor monitor) throws CoreException {\n\r\n }", "public void forEach(Processor processor) {\n\n\t}", "public void addHosts(yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.AddClusterHostsRequest request,\n io.grpc.stub.StreamObserver<yandex.cloud.api.operation.OperationOuterClass.Operation> responseObserver) {\n io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getAddHostsMethod(), responseObserver);\n }", "public void executeCommandsForHost7Tier(String logName) throws Exception {\n\t\tSession session7 = this.host7;\n\t\tChannel channel7 = session7.openChannel(\"shell\");\n\n\t\t/* Output and Command list definition */\n\t\tops7 = channel7.getOutputStream();\n\t\tps7 = new PrintStream(ops7, true);\n\n\t\t/* Start to command burning */\n\t\tchannel7.connect();\n\n\t\tInputStream input7 = channel7.getInputStream();\n\n\t\t/** Host7 log collection side */\n\n\t\tThread.sleep(1000);\n\t\tps7.println(\"host7\");\n\t\t// command lists\n\t\tThread.sleep(1000);\n\n\t\tThread.sleep(500);\n\t\tps7.println(\"./logcap.sh -c \" + logName + \"_host7\"\n\t\t\t\t+ \" -z\"); /* run script for log collection */\n\n\t\tprintResult(input7, channel7);\n\n\t}", "@Override\r\n\tpublic void runInstincts() throws GameActionException {\n\t\t\r\n\t}", "@Override\n\t\t\t\t\tpublic void forEach(BiConsumer<Var, Node> action) {\n\t\t\t\t\t\tfor (Var v : bins.keySet()) {\n\t\t\t\t\t\t\tNode n = bins.get(v);\n\t\t\t\t\t\t\taction.accept(v, n);\n\t\t\t\t\t\t}\n\t\t\t\t\t}", "protected void onClick() {\n for(Runnable action : onClick) action.run();\n }", "@Override\n public String matchAndApply(String target, HttpServletRequest request, HttpServletResponse response) throws IOException {\n if (_virtualHosts != null && _virtualHosts.length > 0) {\n String requestHost = normalizeHostname(request.getServerName());\n for (String ruleHost : _virtualHosts) {\n if (ruleHost == null || ruleHost.equalsIgnoreCase(requestHost)\n || (ruleHost.startsWith(\"*.\") && ruleHost.regionMatches(true, 2, requestHost, requestHost.indexOf(\".\") + 1, ruleHost.length() - 2)))\n return apply(target, request, response);\n }\n } else {\n return apply(target, request, response);\n }\n return null;\n }", "String runFoldR(THost host, String accClassname);", "public void crawl() {\n retrieveDataByProductUrls();\n // Check if data is in range\n for (TrackedProduct product : AppConfig.getProducts()) {\n if (checkProductInRange(product)) {\n // Send Email\n MailSender.sendMail(product);\n }\n }\n }", "@Override\n public void forEach(Consumer<? super CardView> action) {\n cards.forEach(action);\n }", "public void addHosts(yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.AddClusterHostsRequest request,\n io.grpc.stub.StreamObserver<yandex.cloud.api.operation.OperationOuterClass.Operation> responseObserver) {\n io.grpc.stub.ClientCalls.asyncUnaryCall(\n getChannel().newCall(getAddHostsMethod(), getCallOptions()), request, responseObserver);\n }", "public void setRemoteHostNames(java.lang.String[] remoteHostNames) {\r\n this.remoteHostNames = remoteHostNames;\r\n }", "private int activeDownloadsbyHosts(final String host) {\r\n synchronized (activeDownloadsbyHost) {\r\n final java.util.List<SingleDownloadController> ret = activeDownloadsbyHost.get(host);\r\n if (ret != null) return ret.size();\r\n }\r\n return 0;\r\n }", "private Object loopOverTurtle(TurtleActionWithResult action) {\n\t\tObject result = null;\n\t\tfor (Turtle turtle : getActiveTurtles()) {\n\t\t\tresult = action.execute(turtle);\n\t\t}\n\t\treturn result;\n\t}", "public interface CrawlerService {\n\n void processUrl(String url) throws IOException;\n}", "public void testGetHost() {\n }", "public void crawl() {\n\t\tOOSpider.create(Site.me().setSleepTime(3000).setRetryTimes(3).setDomain(\"movie.douban.com\")//.setHttpProxy(httpProxy)\n .setUserAgent(\"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.67 Safari/537.36\"),\n filmInfoDaoPipeline, DoubanFilm.class)\n .addUrl(\"https://movie.douban.com/top250\")//entry url\n .thread(1)\n .run();\n }", "public yandex.cloud.api.operation.OperationOuterClass.Operation updateHosts(yandex.cloud.api.mdb.clickhouse.v1.ClusterServiceOuterClass.UpdateClusterHostsRequest request) {\n return io.grpc.stub.ClientCalls.blockingUnaryCall(\n getChannel(), getUpdateHostsMethod(), getCallOptions(), request);\n }", "public void dispatch();", "public void registerTargets(){\n synchronized(targets){\n while(targets.size()>0){\n Target target= (Target) targets.removeFirst();\n try {\n target.socketChannel.register(selector,SelectionKey.OP_CONNECT,target);\n } catch (ClosedChannelException e) {\n// e.printStackTrace(); //To change body of catch statement use File | Settings | File Templates.\n try {\n target.socketChannel.close();\n } catch (IOException e1) {\n e1.printStackTrace(); //To change body of catch statement use File | Settings | File Templates.\n }\n target.failure=e;\n addFinishedTarget(target);\n }\n }\n }\n }", "public DiscoveryActionsFunction() {\n\t\trf = new DiscoveryRewardFunction();\n\t\tfor ( DiscoveryDutyCycle dc : DiscoveryDutyCycle.values() ) {\n\t\t\tallActions.add( dc );\n\t\t}\n\t}", "private final void m41025a() {\n for (C10020a c : getActionItems()) {\n c.mo10691c();\n }\n }", "protected void init_actions()\n {\n action_obj = new CUP$XPathParser$actions(this);\n }", "public ContentHandler[] forAction(String action) {\n return impl.forAction(action);\n }", "public void newHost(Host aHost);", "void refreshNodeHostCount(int nodeHostCount);", "@Override\n public void doWork(Website site) {\n // TrungDQ: Comment these two lines to parse without crawl\n// CrawlerPipeline crawler = CrawlerPipeline.getInstance();\n// crawler.doWork(site);\n\n List<LinkDetail> linksList = (new LinkDetailDAL()).getLinksByWebsite(site);\n\n // move to Parser pipeline\n ParserPipeline parser = ParserPipeline.getInstance();\n List<ParsedHotel> parsedHotels = parser.doWork(linksList, site);\n\n // convert parsted hotel to normal hotel\n List<Hotel> hotels = new ArrayList<>();\n for (ParsedHotel parstedHotel : parsedHotels) {\n Hotel hotel = null;\n try {\n hotel = CommonObjConverter.toHotel(parstedHotel);\n } catch (Exception ex) {\n Logger.getLogger(Work.class.getName()).log(Level.SEVERE, null, ex);\n }\n hotels.add(hotel);\n }\n\n\n // normalization those hotel\n NormalizationPipeline engine = NormalizationPipeline.getInstance();\n hotels = engine.doWork(hotels);\n\n System.out.println(\"Hotels:::: \" + hotels);\n // save those hotel to database\n for (Hotel hotel : hotels) {\n try {\n if (!hotel.getHotelName().equals(\"0\")) {\n HotelDAL.addHotel(hotel);\n }\n } catch (Exception ex) {\n Logger.getLogger(Work.class.getName()).log(Level.SEVERE, null, ex);\n }\n }\n }", "interface ActionPostprocessing {\n void run(\n Environment env,\n Action action,\n ActionMetadataHandler metadataHandler,\n Map<String, String> clientEnv)\n throws InterruptedException, ActionExecutionException;\n }", "public String getHost();", "public String getHost();", "@Override\n public void execute() throws BuildException\n {\n try {\n preprocessAttributes();\n String webContextURL = Utils.URL(secure, hostName, agent);\n execute(webContextURL);\n }\n catch(Exception e) {\n e.printStackTrace();\n throw new BuildException(e);\n }\n }", "public interface Crawler {\n\t/**\n\t * Gets the location where crawled content is saved.\n\t * \n\t * @return location string of crawled content\n\t */\n\tpublic String getDumpLocation();\n\n\t/**\n\t * Starts the crawling from the root source of target.\n\t * \n\t * @throws IOException\n\t */\n\tpublic void disperse() throws IOException;\n\n\t/**\n\t * Crawls every <code>url</code> within the <code>target</code> url\n\t * \n\t * @param url\n\t * url which is either <code>target</code> or the one nested\n\t * inside\n\t * @param target\n\t * the target url declared to crawl\n\t * @throws IOException\n\t */\n\tpublic void crawl(final String url, final String target) throws IOException;\n\n\t/**\n\t * Picks up data from webpage.\n\t * \n\t * @param doc\n\t * <code>Document</code> retrieved from <code>url</code>\n\t * @param url\n\t * @return list of <code>Nugget</code> objects consisting of relevant data\n\t */\n\tpublic List<Nugget> scavenge(final Document doc, final String url);\n\n}", "protected Actions exec() {\n return actions;\n }", "public void testSetHost() {\n }", "public void groupHostObjects(int addr) {\n\t\tfor(List<String> pkt : pkts) {\n\t\t\tif(!hosts.contains(pkt.get(addr)) && (!webPages.contains(pkt.get(addr)))) {\n\t\t\t\thosts.add(pkt.get(addr));\n\t\t\t}\n\n\t\t}\n\t}", "@Deprecated\n private void applyExecuteOn(Iterable<? extends PostBuildItem> items) {\n for (PostBuildItem item : items) {\n item.setExecuteOn(translate(executeOn));\n }\n }", "@Override\n\tpublic void operation() {\n\t\tfor(Object object:list) {\n\t\t\t((Component)object).operation();\n\t\t}\n\t}" ]
[ "0.5669824", "0.5669228", "0.5533583", "0.52144384", "0.5200407", "0.5200407", "0.5043144", "0.50326204", "0.49446785", "0.49445847", "0.49368027", "0.48626432", "0.48240304", "0.4820779", "0.4812504", "0.4781543", "0.4780228", "0.47331402", "0.4721451", "0.4713348", "0.47095472", "0.47053063", "0.4699779", "0.4696022", "0.46883813", "0.46679905", "0.4662011", "0.46588993", "0.46534005", "0.46525234", "0.46360257", "0.4615486", "0.46091232", "0.4607567", "0.45892447", "0.45868227", "0.45827752", "0.45777205", "0.45705217", "0.45698735", "0.4564952", "0.45614064", "0.4553731", "0.45507005", "0.45414788", "0.4532932", "0.45043087", "0.44963822", "0.44883117", "0.4469265", "0.44686735", "0.44665223", "0.44635528", "0.44300973", "0.44220355", "0.4421099", "0.44038713", "0.43911353", "0.4377642", "0.43697098", "0.436218", "0.43613538", "0.43565238", "0.43564826", "0.43540862", "0.43250427", "0.4324559", "0.43164775", "0.43042478", "0.43028647", "0.42999804", "0.42944705", "0.42914444", "0.42913684", "0.4289744", "0.42877656", "0.42867234", "0.42775953", "0.4273712", "0.42698553", "0.4267555", "0.42652208", "0.42620322", "0.42620063", "0.42585257", "0.42566764", "0.42503303", "0.4247299", "0.4246208", "0.42378786", "0.42370817", "0.4231763", "0.4231763", "0.42293113", "0.42276788", "0.42230168", "0.4221229", "0.42166376", "0.4215506", "0.4209115" ]
0.6977488
0
Compares all single values.
public static int compare( Object o1, Object o2 ) { if (o1 == null) return o2 == null ? 0 : -1; if (o2 == null) return 1; Type type1 = getType( o1 ); Type type2 = getType( o2 ); if (type1 != type2) return type1.ordinal() - type2.ordinal(); switch (type1) { case BOOL: return ((Boolean)o1).compareTo((Boolean)o2); case LONG: return ((Long)o1).compareTo((Long)o2); case DOUBLE: return ((Double)o1).compareTo((Double)o2); case STRING: return ((String)o1).compareTo((String)o2); case DATE: return ((java.util.Date)o1).compareTo((java.util.Date)o2); case KEY: return ((Key)o1).compareTo((Key)o2); case GEOPT: return ((GeoPt)o1).compareTo((GeoPt)o2); case USER: return ((User)o1).compareTo((User)o2); default: return N_A; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Test\n void compareTo_Identical_AllParts()\n {\n runIsMatchTest(AnswerType.yes, AnswerType.yes, AnswerType.yes, AnswerType.yes, ContactMatchType.Identical);\n }", "public void testComparisons() {\n\tfinal double small = Math.pow(2.0, -42);\n\n\t// Input: a, b\n\tdouble[][] input = new double[][] { new double[] { 1, 1 },\n\t\tnew double[] { 1, 2 }, new double[] { 1, 1 - small / 10 },\n\t\tnew double[] { 1, 1 + small / 10 },\n\n\t\tnew double[] { 0, 1 }, new double[] { 0, 0 },\n\t\tnew double[] { 0, -1 }, new double[] { 0, small / 100 },\n\t\tnew double[] { 2100000001.0001, 2100000001.0003 }, };\n\n\t// Output: less, equals\n\tboolean[][] output = new boolean[][] { new boolean[] { false, true },\n\t\tnew boolean[] { true, false }, new boolean[] { false, true },\n\t\tnew boolean[] { false, true },\n\n\t\tnew boolean[] { true, false }, new boolean[] { false, true },\n\t\tnew boolean[] { false, false }, new boolean[] { false, true },\n\t\tnew boolean[] { false, true }, };\n\n\tfor (int i = 0; i < input.length; ++i) {\n\t boolean l = StandardFloatingPointComparator.getDouble().less(\n\t\t input[i][0], input[i][1]);\n\t boolean e = StandardFloatingPointComparator.getDouble().equals(\n\t\t input[i][0], input[i][1]);\n\n\t boolean ne = StandardFloatingPointComparator.getDouble().notEquals(\n\t\t input[i][0], input[i][1]);\n\t boolean le = StandardFloatingPointComparator.getDouble()\n\t\t .lessOrEquals(input[i][0], input[i][1]);\n\t boolean g = StandardFloatingPointComparator.getDouble().greater(\n\t\t input[i][0], input[i][1]);\n\t boolean ge = StandardFloatingPointComparator.getDouble()\n\t\t .greaterOrEquals(input[i][0], input[i][1]);\n\n\t boolean less = output[i][0];\n\t boolean equals = output[i][1];\n\n\t boolean notEquals = !equals;\n\t boolean lessOrEquals = less || equals;\n\t boolean greater = !lessOrEquals;\n\t boolean greaterOrEquals = !less;\n\n\t assertFalse(l != less);\n\t assertFalse(g != greater);\n\t assertFalse(e != equals);\n\t assertFalse(ne != notEquals);\n\t assertFalse(le != lessOrEquals);\n\t assertFalse(ge != greaterOrEquals);\n\t}\n }", "private boolean compare(ValueType first, ValueType second) {\r\n // TODO\r\n return false;\r\n }", "static void compare()\n {\n \tif(a < c)\n\t\t {\n\t\t\t comp_one = 1; //store this value , else zero default \n\t\t }\n\t\t if(c < b)\n\t\t {\n\t\t\t comp_two = 2; //store this value , else zero default\n\t\t }\n\t\t if(b < a)\n\t\t {\n\t\t\t comp_thr = 5; //store this value , else zero default\n\t\t }\n\t\t \n\t\t comp_val = comp_one + comp_two + comp_thr; //create a unique value by addition\n }", "public void testObjCompare()\n {\n assertEquals( Comparator.EQUAL, Util.objCompare(null,null) );\n assertEquals( Comparator.LESS, Util.objCompare(new Integer(10), new Integer(20)) );\n assertEquals( Comparator.GREATER, Util.objCompare(new Integer(25), new Integer(20)) );\n assertEquals( Comparator.UNDECIDABLE,Util.objCompare(null,new Integer(1)) );\n assertEquals( Comparator.UNDECIDABLE,Util.objCompare(new Integer(1),null) );\n }", "@Test\r\n public void testCompare() {\r\n\r\n double[] r1;\r\n double[] r2;\r\n Comparator<double[]> instance = new DoubleArrayComparator();\r\n \r\n r1 = new double[]{1,2,3};\r\n r2 = new double[]{1,2,3}; \r\n assertEquals(0, instance.compare(r1, r2));\r\n\r\n r1 = new double[]{1,2,3};\r\n r2 = new double[]{1,3,2}; \r\n assertEquals(-1, instance.compare(r1, r2));\r\n \r\n r1 = new double[]{1,3,3};\r\n r2 = new double[]{1,3,2}; \r\n assertEquals(1, instance.compare(r1, r2));\r\n \r\n }", "private static void compareForIdenticalKeys() {\n Integer[] identical = {1, 1, 1, 1, 1, 1, 1, 1, 1, 1};\n\n Insertion insertion = new Insertion();\n insertion.analyzeSort(identical);\n insertion.getStat().printReport();\n\n Selection selection = new Selection();\n selection.analyzeSort(identical);\n selection.getStat().printReport();\n }", "@Test \n public void compareFunctionalEquals() {\n HighScoreComparator comparator2 = new HighScoreComparator();\n int a;\n a = comparator2.compare(p1, p1);\n \n assertEquals(0, a);\n }", "private boolean checkComp() {\n\t\tfor (int i = 0; i < comp.length; i++) {\n\t\t\tfor (int j = 0; j < comp[i].length; j++) {\n\t\t\t\tif (comp[i][j] != answer[i][j]) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "public abstract void compare();", "private boolean isValuesEqual(BinaryMessage tocmp, BinaryMessage original) {\n\t\tif(tocmp.getValue().equals(original.getValue())) {\n\t\t\treturn true;\n\t\t}\n\t\telse {\n\t\t\treturn false;\n\t\t}\n\t}", "public static boolean checkValues (Iterable<Versioned<byte[]>> values, Versioned<byte[]> expected) {\n\t\tIterator<Versioned<byte[]>> itValue = values.iterator();\n\t\twhile (itValue.hasNext()) {\n\t\t\tVersioned<byte[]> curr = itValue.next();\n\t\t\tif ( ! Arrays.equals(expected.getValue(), curr.getValue()) ) {\n\t\t\t\tSystem.err.println(\"Expected value is different!!\");\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\treturn true;\n\t}", "@Test\n public void equality() {\n new EqualsTester()\n .addEqualityGroup(UnitConverters.identity())\n .addEqualityGroup(UnitConverters.shift(100))\n .addEqualityGroup(UnitConverters.multiply(2))\n .addEqualityGroup(UnitConverters.pow(10, 6))\n .addEqualityGroup(UnitConverters.pow(UnitConverters.multiply(5), 2))\n .addEqualityGroup(UnitConverters.root(UnitConverters.multiply(5), 2))\n .addEqualityGroup(UnitConverters.compose(UnitConverters.shift(100), UnitConverters.multiply(2)))\n .testEquals();\n }", "@Override\n\tpublic void visit(AllComparisonExpression arg0) {\n\t\t\n\t}", "@Test\n public void testEquality(){\n int ans = testing1.LessThanTen(testing1.getValue1(), testing1.getValue2());\n assertEquals(10, ans);\n }", "private Comparison compareValues(SimpleNode first, SimpleNode second) {\n return Objects.equals(first.jjtGetValue(), second.jjtGetValue()) ? Comparison.IS_EQUAL\n : Comparison.notEqual(\"Node values differ: \" + first.jjtGetValue() + \" vs \" + second.jjtGetValue());\n }", "@Test\n public void testEquals() throws ValueDoesNotMatchTypeException {\n TestEvaluationContext context = new TestEvaluationContext();\n \n DecisionVariableDeclaration decl = new DecisionVariableDeclaration(\"x\", IntegerType.TYPE, null);\n \n ConstantValue c0 = new ConstantValue(ValueFactory.createValue(IntegerType.TYPE, 0));\n ConstraintSyntaxTree cst1 = new OCLFeatureCall(\n new Variable(decl), IntegerType.LESS_EQUALS_INTEGER_INTEGER.getName(), c0);\n ConstraintSyntaxTree cst2 = new OCLFeatureCall(\n new Variable(decl), IntegerType.GREATER_EQUALS_INTEGER_INTEGER.getName(), c0);\n\n EvaluationAccessor val1 = Utils.createValue(ConstraintType.TYPE, context, cst1);\n EvaluationAccessor val2 = Utils.createValue(ConstraintType.TYPE, context, cst2);\n EvaluationAccessor nullV = Utils.createNullValue(context);\n \n // equals is useless and will be tested in the EvaluationVisitorTest\n \n Utils.testEquals(true, ConstraintType.EQUALS, ConstraintType.UNEQUALS, val1, val1);\n Utils.testEquals(true, ConstraintType.EQUALS, ConstraintType.UNEQUALS, val2, val2);\n Utils.testEquals(false, ConstraintType.EQUALS, ConstraintType.UNEQUALS, val1, val2);\n Utils.testEquals(false, ConstraintType.EQUALS, ConstraintType.UNEQUALS, val2, val1);\n Utils.testEquals(false, ConstraintType.EQUALS, ConstraintType.UNEQUALS, val1, nullV);\n Utils.testEquals(false, ConstraintType.EQUALS, ConstraintType.UNEQUALS, val2, nullV);\n\n val1.release();\n val2.release();\n nullV.release();\n }", "@Override\n\tpublic void visit(AllComparisonExpression arg0) {\n\n\t}", "@Override\n public VectorEquality compareTo(PredicateVector vectorCmp) {\n try {\n PredicateVector vectorLarge;\n PredicateVector vectorSmall;\n VectorEquality cmpResult;\n \n if (flagged || vectorCmp.flagged) {\n return VectorEquality.UNIQUE;\n }\n \n // TODO: add size check\n \n if (this.size() > vectorCmp.size() && !this.values().iterator().next().isEmpty()) {\n vectorLarge = this;\n vectorSmall = vectorCmp;\n cmpResult = VectorEquality.SUPERSET;\n } else {\n vectorLarge = vectorCmp;\n vectorSmall = this;\n cmpResult = VectorEquality.SUBSET;\n }\n \n int largeVectorIter = 0;\n int numEq = 0;\n \n List<Integer> vectorSmallKeys = new ArrayList<Integer>(vectorSmall.keySet());\n Collections.sort(vectorSmallKeys);\n \n List<Integer> vectorLargeKeys = new ArrayList<Integer>(vectorLarge.keySet());\n Collections.sort(vectorLargeKeys);\n\n int i = 0;\n\n for (Integer smallVectorKey: vectorSmallKeys) {\n StateVector smallVectorState = vectorSmall.get(smallVectorKey);\n // Check if we have not iterated over all large vector states\n if (largeVectorIter >= vectorLargeKeys.size() && !smallVectorState.isEmpty()) {\n cmpResult = VectorEquality.UNIQUE;\n break;\n }\n \n \n for (i = largeVectorIter; i < vectorLargeKeys.size(); i++) {\n StateVector largeVectorState = vectorLarge.get(vectorLargeKeys.get(i));\n VectorEquality cmpVectorResult = smallVectorState.compareTo(largeVectorState); \n if (cmpVectorResult == VectorEquality.EQUAL) {\n numEq += 1;\n break;\n }\n \n if (cmpVectorResult == VectorEquality.SUPERSET || cmpVectorResult == VectorEquality.SUBSET) {\n cmpResult = cmpVectorResult;\n numEq += 1;\n break;\n }\n }\n \n largeVectorIter = i + 1; // TODO: double check i+1\n }\n \n if (numEq < vectorSmall.size() && !vectorSmall.values().iterator().next().isEmpty())\n cmpResult = VectorEquality.UNIQUE;\n \n return cmpResult;\n } catch (ArrayIndexOutOfBoundsException e) {\n e.printStackTrace();\n }\n \n return VectorEquality.UNIQUE;\n }", "public void testCompare1() throws Exception {\r\n ComponentCompetitionSituation situation = new ComponentCompetitionSituation();\r\n ComponentCompetitionPredictor predictor = new ComponentCompetitionPredictor();\r\n ComponentCompetitionFulfillmentPrediction prediction1 = new ComponentCompetitionFulfillmentPrediction(1.0D,\r\n situation, predictor);\r\n ComponentCompetitionFulfillmentPrediction prediction2 = new ComponentCompetitionFulfillmentPrediction(1.5D,\r\n situation, predictor);\r\n\r\n begin();\r\n\r\n for (int i = 0; i < TIMES; i++) {\r\n // predictions in range < predictions above the range\r\n int result = comparator.compare(prediction1, prediction2);\r\n // result should be < 0\r\n assertTrue(\"result of compare\", result < 0);\r\n }\r\n\r\n print(\"ComponentCompetitionFulfillmentPredictionPrizeComparator#compare\");\r\n }", "public static boolean allSameValues(Example[] examples)\n {\n if (examples.length == 0)\n throw new RuntimeException(\"Empty examples set!\");\n double last_value;\n for(int val=0; val<examples[0].values.length;val++)\n {\n last_value = examples[0].values[val];\n for (int idx = 1; idx < examples.length; idx++)\n if( last_value != examples[idx].values[val])\n return false;\n }\n return true;\n }", "private int handleIncomparablePrimitives(Object x, Object y) {\n int xCost = getPrimitiveValueCost(x);\n int yCost = getPrimitiveValueCost(y);\n int res = Integer.compare(xCost, yCost);\n return ascending ? res : -res;\n }", "@Test//test equal\n public void testEqual() {\n MyVector vD1 = new MyVector(ORIGINALDOUBLEARRAY);\n MyVector vD2 = new MyVector(ORIGINALDOUBLEARRAY);\n double[] doubleArray = new double[]{3.0, 2.3, 1.0, 0.0, -1.1};\n MyVector diffVD3 = new MyVector(doubleArray);\n assertEquals(true, vD1.equal(vD2));\n assertEquals(false, vD1.equal(diffVD3));\n MyVector vI1 = new MyVector(ORIGINALINTARRAY);\n MyVector vI2 = new MyVector(ORIGINALINTARRAY);\n int[] intArray = new int[]{1, 2, 3, 4};\n MyVector vI3 = new MyVector(intArray);\n assertEquals(true, vI1.equal(vI2));\n assertEquals(false, vI1.equal(vI3));\n }", "@Test\n\tpublic void test() {\n\t\tTestUtil.testEquals(new Object[][]{\n\t\t\t\t{4, 2, 7, 1, 3},\n\t\t\t\t{3, 3, 5, 2, 1},\n\t\t\t\t{15, 2, 4, 8, 2}\n\t\t});\n\t}", "@Override\n public Boolean getValue(Object x)\n {\n if (m_falseCount > 0 && m_width <= 0)\n return false;\n\n allDifferent = true;\n\n // if duplicate entries were found in previous calls\n if (m_falseCount > 0)\n {\n m_falseCount--;\n allDifferent = false;\n }\n\n // compare this entry to every previous one\n for (int i = m_previousInputs.size() - 1; i >= 0; i--)\n {\n if (m_previousInputs.get(i).equals(x))\n {\n // this function will return false at least until this entry is removed\n m_falseCount = Math.max(m_falseCount, i + (m_width - m_previousInputs.size() - 1));\n allDifferent = false;\n break;\n }\n }\n\n // update previous entries\n m_previousInputs.add(x);\n if (m_width > 0 && m_previousInputs.size() >= m_width)\n {\n m_previousInputs.remove();\n }\n\n return allDifferent;\n }", "public static void main(String[] args) {\n\t\tInteger integer1;\n\t\tInteger integer2;\n\n\t\tinteger1 = new Integer(10);\n\t\tinteger2 = new Integer(10);\n\t\t//第一次比较\n\t\tSystem.out.println(\"第一次比较:\"+(integer1==integer2));\n\n\t\t//第二次比较\n\t\tSystem.out.println(\"第二次比较:\"+(integer1==10));\n\n\t\tinteger1 = 127;\n\t\tinteger2 = 127;\n\t\t//第三次比较\n\t\tSystem.out.println(\"第三次比较:\"+(integer1==integer2));\n\n\t\tinteger1 = 128;\n\t\tinteger2 = 128;\n\t\t//第四次比较\n\t\tSystem.out.println(\"第四次比较:\"+(integer1==integer2));\n\n\t}", "void compareDataStructures();", "public final boolean equal() {\n\t\tif (size > 1) {\n\t\t\tdouble topMostValue = pop();\n\t\t\tdouble secondTopMostValue = pop();\n\t\t\tif (topMostValue == secondTopMostValue) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "boolean test() {\n int comp = this._col1.value().compareTo(this._col2.value());\n if (comp < 0 && (this.compRep & LT) != 0\n || comp > 0 && (this.compRep & GT) != 0\n || comp == 0 && (this.compRep & EQ) != 0) {\n return true;\n }\n return false;\n }", "public void testCompare6() throws Exception {\r\n ComponentCompetitionSituation situation1 = new ComponentCompetitionSituation();\r\n situation1.setPostingDate(new Date());\r\n situation1.setEndDate(new Date(situation1.getPostingDate().getTime() + 100000));\r\n situation1.setPrize(200D);\r\n\r\n ComponentCompetitionSituation situation2 = new ComponentCompetitionSituation();\r\n situation2.setPostingDate(new Date());\r\n situation2.setEndDate(new Date(situation2.getPostingDate().getTime() + 100000));\r\n situation2.setPrize(200D);\r\n\r\n ComponentCompetitionPredictor predictor = new ComponentCompetitionPredictor();\r\n ComponentCompetitionFulfillmentPrediction prediction1 = new ComponentCompetitionFulfillmentPrediction(1.0D,\r\n situation1, predictor);\r\n ComponentCompetitionFulfillmentPrediction prediction2 = new ComponentCompetitionFulfillmentPrediction(1.0D,\r\n situation2, predictor);\r\n\r\n begin();\r\n\r\n for (int i = 0; i < TIMES; i++) {\r\n int result = comparator.compare(prediction1, prediction2);\r\n // result should be == 0\r\n assertTrue(\"result of compare\", result == 0);\r\n }\r\n\r\n print(\"ComponentCompetitionFulfillmentPredictionPrizeComparator#compare\");\r\n }", "@Test\n public void equals() {\n float[] a = new float[] {1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f}; \n float[] b = new float[] {2.0f, 1.0f, 6.0f, 3.0f, 4.0f, 5.0f, 6.0f}; \n assertTrue(Vec4f.equals(a, 2, b, 3));\n assertTrue(! Vec4f.equals(a, 0, b, 0));\n \n float[] a4 = new float[] {1.0f, 2.0f, 3.0f, 4.0f}; \n \n float[] b4 = new float[] {1.0f, 2.0f, 3.0f, 4.0f};\n float[] c4 = new float[] {2.0f, 2.0f, 3.0f, 4.0f};\n float[] d4 = new float[] {1.0f, 4.0f, 3.0f, 4.0f};\n float[] e4 = new float[] {1.0f, 2.0f, 6.0f, 4.0f};\n float[] f4 = new float[] {1.0f, 2.0f, 3.0f, 5.0f};\n assertTrue(Vec4f.equals(a4,b4));\n assertTrue(!Vec4f.equals(a4,c4));\n assertTrue(!Vec4f.equals(a4,d4));\n assertTrue(!Vec4f.equals(a4,e4));\n assertTrue(!Vec4f.equals(a4,f4)); \n }", "public static void main(String[] args) {\n\t\tList l=new ArrayList();\r\n\t\tl.add(12);\r\n\t\tl.add(45);\r\n\t\tl.add(15);\r\n\t\tl.add(78);\r\n\t\t\r\n\t\tList l2=new ArrayList();\r\n\t\tl2.add(12);\r\n\t\tl2.add(45);\r\n\t\tl2.add(10);\r\n\t\tl2.add(78);\r\n\t\t\r\n\t\tBoolean m=l.containsAll(l2);\r\n\t\t\r\n\t\tif(m)\r\n\t\t{\r\n\t\t\tSystem.out.println(\"Elements are same\");\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\tSystem.out.println(\"Not equal\");\r\n\t\t}\r\n\t\t\r\n\r\n\t}", "@Test\n public void compareFunctionalSmaller() {\n HighScoreComparator comparator2 = new HighScoreComparator();\n int a;\n a = comparator2.compare(p2, p1);\n \n assertEquals(1, a);\n }", "public static void main(String[] args) {\n int[] a = {4, 6, 3};\n int[] b = {6, 4, 3};\n System.out.println(areSimilar(a, b));\n\n }", "public void testCompare5() throws Exception {\r\n // smaller prizes\r\n ComponentCompetitionSituation situation1 = new ComponentCompetitionSituation();\r\n situation1.setPostingDate(new Date());\r\n situation1.setEndDate(new Date(situation1.getPostingDate().getTime() + 100000));\r\n situation1.setPrize(100D);\r\n\r\n // longer prizes\r\n ComponentCompetitionSituation situation2 = new ComponentCompetitionSituation();\r\n situation2.setPostingDate(new Date());\r\n situation2.setEndDate(new Date(situation2.getPostingDate().getTime() + 100000));\r\n situation2.setPrize(200D);\r\n\r\n ComponentCompetitionPredictor predictor = new ComponentCompetitionPredictor();\r\n ComponentCompetitionFulfillmentPrediction prediction1 = new ComponentCompetitionFulfillmentPrediction(1.0D,\r\n situation1, predictor);\r\n ComponentCompetitionFulfillmentPrediction prediction2 = new ComponentCompetitionFulfillmentPrediction(1.0D,\r\n situation2, predictor);\r\n\r\n begin();\r\n\r\n for (int i = 0; i < TIMES; i++) {\r\n // smaller prizes < longer prizes\r\n int result = comparator.compare(prediction1, prediction2);\r\n // result should be < 0\r\n assertTrue(\"result of compare\", result < 0);\r\n }\r\n\r\n print(\"ComponentCompetitionFulfillmentPredictionPrizeComparator#compare\");\r\n }", "public boolean check() {\n BigInteger t1 = y.modPow(int2, c.p);\n BigInteger t2 = x.modPow(int3, c.p);\n BigInteger t3 = ((t2.add(c.a.multiply(x))).add(c.b)).mod(c.p);\n return t1.compareTo(t3) == 0;\n }", "public static void main(String[] args) {\n int n1 = 0;\n int n2 = 0;\n int n3 = 0;\n if (n1 == n2 && n1 != n3) {\n System.out.println(\"n1 and n2 equal\");\n } else if (n2 == n3 && n2 != n1) {\n System.out.println(\"n2 and n3 equal\");\n } else if (n3 == n1 && n1 != n2) {\n System.out.println(\"n3 and n1 equal\");\n } else if (n1 == n2 && n1 == n3) {\n System.out.println(\"all equal\");\n }\n else {\n System.out.println(\"none equal\");\n }\n }", "Boolean same(MultiSet<X> s);", "public void testCompare3() throws Exception {\r\n ComponentCompetitionSituation situation = new ComponentCompetitionSituation();\r\n ComponentCompetitionPredictor predictor = new ComponentCompetitionPredictor();\r\n ComponentCompetitionFulfillmentPrediction prediction1 = new ComponentCompetitionFulfillmentPrediction(1.5D,\r\n situation, predictor);\r\n ComponentCompetitionFulfillmentPrediction prediction2 = new ComponentCompetitionFulfillmentPrediction(0.6D,\r\n situation, predictor);\r\n\r\n begin();\r\n\r\n for (int i = 0; i < TIMES; i++) {\r\n // predictions above the range < predictions below the range\r\n int result = comparator.compare(prediction1, prediction2);\r\n // result should be < 0\r\n assertTrue(\"result of compare\", result < 0);\r\n }\r\n\r\n print(\"ComponentCompetitionFulfillmentPredictionPrizeComparator#compare\");\r\n }", "public void testCompare2() throws Exception {\r\n ComponentCompetitionSituation situation = new ComponentCompetitionSituation();\r\n ComponentCompetitionPredictor predictor = new ComponentCompetitionPredictor();\r\n ComponentCompetitionFulfillmentPrediction prediction1 = new ComponentCompetitionFulfillmentPrediction(1.0D,\r\n situation, predictor);\r\n ComponentCompetitionFulfillmentPrediction prediction2 = new ComponentCompetitionFulfillmentPrediction(0.6D,\r\n situation, predictor);\r\n\r\n begin();\r\n\r\n for (int i = 0; i < TIMES; i++) {\r\n // predictions in range < predictions below the range\r\n int result = comparator.compare(prediction1, prediction2);\r\n // result should be < 0\r\n assertTrue(\"result of compare\", result < 0);\r\n }\r\n\r\n print(\"ComponentCompetitionFulfillmentPredictionPrizeComparator#compare\");\r\n }", "private Comparison checkEquality(SimpleNode node1, SimpleNode node2) {\n // Compare the classes.\n Comparison comparison = compareClasses(node1, node2);\n if (!comparison.isEqual()) {\n return comparison;\n }\n\n // Compare the values.\n comparison = compareValues(node1, node2);\n if (!comparison.isEqual()) {\n return comparison;\n }\n\n // Compare the images.\n comparison = compareImages(node1, node2);\n if (!comparison.isEqual()) {\n return comparison;\n }\n\n // Compare the children.\n return compareChildren(node1, node2);\n }", "boolean hasSameAs();", "@Test\n\tpublic void testEqualityCheck() {\n\t\tadd(\"f(x)=x^3\");\n\t\tadd(\"g(x)=-x^3\");\n\t\tt(\"f==g\", \"false\");\n\t\tt(\"f!=g\", \"true\");\n\t\tt(\"f==-g\", \"true\");\n\t\tt(\"f!=-g\", \"false\");\n\t}", "@Test\n public void testCompare() {\n AantalGastenComparator instance = new AantalGastenComparator();\n int expResult;\n int result;\n \n //test 1\n Accommodatie a1 = new Accommodatie(\"je moeder\", 30.00, 2, 1);\n Accommodatie a2 = new Accommodatie(\"je vader\", 40.00, 3, 1);\n expResult = -1;\n result = instance.compare(a1, a2);\n assertEquals(expResult, result);\n \n \n //test 2\n Accommodatie a3 = new Accommodatie(\"je moeder2\", 30.00, 2, 1);\n Accommodatie a4 = new Accommodatie(\"je vader2\", 40.00, 2, 1);\n expResult = 0;\n result = instance.compare(a3, a4);\n assertEquals(expResult, result);\n \n \n //test 3\n Accommodatie a5 = new Accommodatie(\"je moeder3\", 30.00, 3, 1);\n Accommodatie a6 = new Accommodatie(\"je vader3\", 40.00, 2, 1);\n expResult = 1;\n result = instance.compare(a5, a6);\n assertEquals(expResult, result);\n }", "private void verifyAllValues(AllValues allValues, int offset) {\n\t\tfor (int i = offset; i < allValues.size(); i++) {\n\t\t\tif (i % 2 == 0) {\n\t\t\t\tassertTrue(\"OneValue at index \" + i + \" should be of type OneResult\", allValues.get(i) instanceof OneResult);\n\t\t\t\tassertEquals(\"Value at index \" + i + \" should be equal to \" + i, i, allValues.get(i).getValue());\n\t\t\t} else {\n\t\t\t\tassertTrue(\"OneValue at index \" + i + \" should be of type OneReject\", allValues.get(i) instanceof OneReject);\n\t\t\t\tassertTrue(\"Value at index \" + i + \" should be of type IndexedRuntimeException\", allValues.get(i).getValue() instanceof IndexedRuntimeException);\n\t\t\t}\n\t\t}\n\t}", "protected abstract boolean isEqual(E entryA, E entryB);", "public void testCompareBoolean() {\n\t\tboolean one = true;\n\t\tboolean two = false;\n\t\t//false ist kleiner wie true\n\t\tassertTrue(comp.compareBoolean(two, one) == -1);\n\t\tassertTrue(comp.compareBoolean(one, one) == 0);\n\t\tassertTrue(comp.compareBoolean(two, two) == 0);\n\t\tassertTrue(comp.compareBoolean(one, two) == 1);\n\t}", "public boolean isSame(){\r\n\t\tHugeInt mod2 = new HugeInt(this.p);\r\n\t\tmod2.modByHugeInt(new HugeInt(\"2\"));\r\n\t\tmod2.printHugeInt();\r\n\t\t\r\n\t\tHugeInt mod3 = new HugeInt(this.p);\r\n\t\tmod3.modByHugeInt(new HugeInt(\"3\"));\r\n\t\t\r\n\t\tif(this.p.compareHugeInts(this.p, new HugeInt(\"1\")) != -1)\r\n\t\t\tSystem.out.println(\"less than or equal to 1\");\r\n\t\telse if(this.p.compareHugeInts(this.p, new HugeInt(\"3\")) != -1)\r\n\t\t\tSystem.out.println(\"greater than 1 but less than 3\");\r\n\t\telse if(mod2.areAllZeros() || mod3.areAllZeros())\r\n\t\t\tSystem.out.println(\"mod by 2 or 3\");\r\n\t\t\r\n\t\treturn true;\r\n\t}", "public static void main(String[] args) {\n // Reflexive\n System.out.println(o.equals(o));\n System.out.println(r.equals(r));\n\n // Symmetric\n System.out.println(o.equals(p) + \" = \" + p.equals(o));\n System.out.println(r.equals(s) + \" = \" + s.equals(r));\n\n // Transitive\n System.out.println(o.equals(p) + \" = \" + p.equals(q) + \" = \" + o.equals(q));\n System.out.println(r.equals(s) + \" = \" + s.equals(t) + \" = \" + r.equals(t));\n\n // Comparing Point to ColorPoint\n System.out.println(p.equals(s.asPoint()));\n System.out.println(s.asPoint().equals(p));\n }", "@org.testng.annotations.Test\n public void test_equals_Symmetric()\n throws Exception {\n CategorieClient categorieClient = new CategorieClient(\"denis\", 1000, 10.2, 1.1, 1.2, false);\n Client x = new Client(\"Denis\", \"Denise\", \"Paris\", categorieClient);\n Client y = new Client(\"Denis\", \"Denise\", \"Paris\", categorieClient);\n Assert.assertTrue(x.equals(y) && y.equals(x));\n Assert.assertTrue(x.hashCode() == y.hashCode());\n }", "@Test\n public void testGetValues(){\n assertTrue(vector.x == 1 && vector.z == 1);\n }", "public void testCompare() throws Exception {\n\n Object testData[][] = {\n { \"aaa\", \"bbb\", -1 },\n { \"aaa\", \"aaa\", 0 },\n { \"bbb\", \"aaa\", 1 },\n { \"aaa\", \"aaa_L1_bbb.lsm\", -1 },\n { \"aaa_L1_bbb.lsm\", \"aaa_L1_bbb.lsm\", 0 },\n { \"aaa_L1_bbb.lsm\", \"aaa\", 1 },\n { \"aaa_L1_bbb.lsm\", \"aaa_L10_bbb.lsm\", -1 },\n { \"aaa_L10_bbb.lsm\", \"aaa_L1_bbb.lsm\", 1 },\n { \"aaa_La_bbb.lsm\", \"aaa_L1_bbb.lsm\", 1 },\n { \"aaa_L2_bbb.lsm\", \"aaa_L10_bbb.lsm\", -1 }\n };\n\n LNumberComparator comparator = new LNumberComparator();\n\n for (Object[] testRow : testData) {\n String name1 = (String) testRow[0];\n String name2 = (String) testRow[1];\n File file1 = new File(name1);\n File file2 = new File(name2);\n int expectedResult = (Integer) testRow[2];\n int actualResult = comparator.compare(new FileTarget(file1),\n new FileTarget(file2));\n\n boolean isValid = ((expectedResult > 0) && (actualResult > 0)) ||\n ((expectedResult < 0) && (actualResult < 0)) ||\n ((expectedResult == 0) && (actualResult == 0));\n\n assertTrue(name1 + \" compared to \" + name2 +\n \" returned invalid result of \" + actualResult +\n \" (should have same sign as \" + expectedResult + \")\",\n isValid);\n }\n\n }", "protected abstract int doCompare(Object o1, Object o2);", "@Test\n public void equals_trulyEqual() {\n SiteInfo si1 = new SiteInfo(\n Amount.valueOf(12000, SiteInfo.CUBIC_FOOT),\n Amount.valueOf(76, NonSI.FAHRENHEIT),\n Amount.valueOf(92, NonSI.FAHRENHEIT),\n Amount.valueOf(100, NonSI.FAHRENHEIT),\n Amount.valueOf(100, NonSI.FAHRENHEIT),\n 56,\n Damage.CLASS2,\n Country.USA,\n \"Default Site\"\n );\n SiteInfo si2 = new SiteInfo(\n Amount.valueOf(12000, SiteInfo.CUBIC_FOOT),\n Amount.valueOf(76, NonSI.FAHRENHEIT),\n Amount.valueOf(92, NonSI.FAHRENHEIT),\n Amount.valueOf(100, NonSI.FAHRENHEIT),\n Amount.valueOf(100, NonSI.FAHRENHEIT),\n 56,\n Damage.CLASS2,\n Country.USA,\n \"Default Site\"\n );\n\n Assert.assertEquals(si1, si2);\n }", "@Test\n public void testIntersection1()\n {\n final int[] ints1 = {33, 100000};\n final int[] ints2 = {33, 100000};\n List<Integer> expected = Arrays.asList(33, 100000);\n\n ConciseSet set1 = new ConciseSet();\n for (int i : ints1) {\n set1.add(i);\n }\n ConciseSet set2 = new ConciseSet();\n for (int i : ints2) {\n set2.add(i);\n }\n\n verifyIntersection(expected, set1, set2);\n }", "@Test\r\n public void repeatedValuesTest() {\r\n int[] unsorted = new int[]{1,33,1,0,33,-23,1,-23,1,0,-23};\r\n int[] expResult = new int[]{-23,-23,-23,0,0,1,1,1,1,33,33};\r\n int[] result = arraySorter.sort(unsorted);\r\n assertArrayEquals(expResult, result);\r\n }", "public void testEquals() {\n XIntervalDataItem item1 = new XIntervalDataItem(1.0, 2.0, 3.0, 4.0);\n XIntervalDataItem item2 = new XIntervalDataItem(1.0, 2.0, 3.0, 4.0);\n item1 = new XIntervalDataItem(1.1, 2.0, 3.0, 4.0);\n item2 = new XIntervalDataItem(1.1, 2.0, 3.0, 4.0);\n item1 = new XIntervalDataItem(1.1, 2.2, 3.0, 4.0);\n item2 = new XIntervalDataItem(1.1, 2.2, 3.0, 4.0);\n item1 = new XIntervalDataItem(1.1, 2.2, 3.3, 4.0);\n item2 = new XIntervalDataItem(1.1, 2.2, 3.3, 4.0);\n item1 = new XIntervalDataItem(1.1, 2.2, 3.3, 4.4);\n item2 = new XIntervalDataItem(1.1, 2.2, 3.3, 4.4);\n }", "public boolean isEquals() {\n long len = -1L;\n\n //1. check the lengths of the words\n for(S left : slp.getAxioms()) {\n if(len == -1L) {\n len = slp.length(left);\n }\n else {\n if(len != slp.length(left)) {\n return false;\n }\n }\n }\n\n // all words are the empty word\n if(len == 0) {\n return true;\n }\n\n // 2. the length are all equals and not zero => execute the recompression\n execute();\n\n S otherSymbol = null;\n boolean first = true;\n\n // 3. chech now if for all axioms X : |val(X)| = 1 and all val(X) are equals.\n for(S left : slp.getAxioms()) {\n if(first) {\n slp.length(left, true);\n first = false;\n }\n\n if(slp.length(left) != 1) {\n return false;\n }\n else {\n S symbol = slp.get(left, 1);\n if(otherSymbol == null) {\n otherSymbol = symbol;\n }\n\n if(!symbol.equals(otherSymbol)) {\n return false;\n }\n }\n }\n\n return true;\n }", "private final boolean compareIntValues(final String data1, final String data2,\n\t\t\tfinal String colName, final String key){\n\t\tint tolerance = ContextComparatorConfigReferences.DEFAULT_TOLERANCE_PERCENTAGE;\n\t\ttry {\n\t\t\ttolerance = Integer.parseInt(\n\t\t\t\t\tconfig.get(\"tolerancePercent\").toString());\n\t\t} catch (NumberFormatException e) {\n\t\t\tLOGGER.warn(\"Unable to parse tolerance percentage, falling back to default.\", e);\n\t\t}\n\n\t\t// FIXME: What if values are decimals?\n\t\tint count1 = 0;\n\t\tint count2 = 0;\n\t\ttry {\n\t\t\tcount1 = Integer.parseInt(data1);\n\t\t\tcount2 = Integer.parseInt(data2);\n\t\t} catch (NumberFormatException e) {\n\t\t\tLOGGER.error(\"Unable to parse count in \" + colName + \" for key: \" + key, e);\n\t\t\tContextComparator.addResult(namespace,\n\t\t\t\t\tContextComparatorConfigReferences.TEST_CATEGORY_COUNT_VALUES,\n\t\t\t\t\tContextComparatorConfigReferences.TEST_STATUS_FAILED,\n\t\t\t\t\t\"Parse exception for \" + colName + \" and key \" + key);\n\t\t\treturn false;\n\t\t}\n\n\t\tif (count1 == count2) {\n\t\t\treturn true;\n\t\t}\n\n\t\tfinal int error = Math.abs(count1 - count2)/count1*100;\n\t\tif (error < tolerance) {\n\t\t\treturn true;\n\t\t}\n\n\t\tContextComparator.addResult(namespace,\n\t\t\t\tContextComparatorConfigReferences.TEST_CATEGORY_COUNT_VALUES,\n\t\t\t\tContextComparatorConfigReferences.TEST_STATUS_FAILED,\n\t\t\t\terror + \"% error for \" + colName + \" and key \" + key\n\t\t\t\t+ \". \" + ContextComparator.CONTEXT_1.getName()\n\t\t\t\t+ \": \" + count1 + \", \" + ContextComparator.CONTEXT_2.getName()\n\t\t\t\t+ \": \" + count2);\n\t\treturn false;\n\t}", "@Override\n\tpublic void visit(AnyComparisonExpression arg0) {\n\t\t\n\t}", "public static int compareSafetyComputations() {\n\t\tSystem.out.println(\"Distance,Duration,Exhalation,Derived,Inferred\");\n\t\tfinal boolean[] derived_results = new boolean[10];\n\t\tfinal boolean[] inferred_results = new boolean[10];\n\t\tint correctInferences = 0;\n\t\tfor(int i = 0; i < derived_results.length; i++) {\n\t\t\tfinal int randomDistance = (int) (Math.random() * (LARGE_DISTANCE * 3));\n\t\t\tfinal int randomDuration = (int) (Math.random() * (LARGE_DURATION * 3));\n\t\t\tfinal int randomExhalation = (int) (Math.random() * (LARGE_EXHALATION_LEVEL * 3));\n\t\t\tderived_results[i] = isDerivedSafe(randomDistance, randomDuration, randomExhalation);\n\t\t\tinferred_results[i] = isInferredSafe(randomDistance, randomDuration, randomExhalation);\n\t\t\tSystem.out.println(randomDistance + COMMA + randomDuration + COMMA \n\t\t\t\t\t\t\t\t+ randomExhalation + COMMA + derived_results[i] + COMMA\n\t\t\t\t\t\t\t\t+ inferred_results[i]);\n\t\t}\n\t\tfor(int j = 0; j < derived_results.length; j++) {\n\t\t\tif(derived_results[j] == inferred_results[j]) {\n\t\t\t\tcorrectInferences++;\n\t\t\t}\n\t\t}\n\t\treturn correctInferences;\n\t}", "@Override\n\tpublic void visit(AnyComparisonExpression arg0) {\n\n\t}", "public final boolean lessThanEquals() {\n\n\t\tif (size > 1) {\n\n\t\t\tdouble topMostValue = pop();\n\t\t\tdouble secondTopMostValue = pop();\n\t\t\tif (secondTopMostValue <= topMostValue) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "@Test\n\tpublic void testEquals6(){\n\t\tTemperature data1 = new Temperature (100, Temperature.Units.KELVIN);\n\t\tTemperature data2 = new Temperature (100, Temperature.Units.CELCIUS);\n\t\tassertEquals(data1.equals(data2), false);\t//Since '100 kelvin' and '100 celcius' are different, equals() function should return false \n\t\tassertTrue(data1.getValue() == 100);\t\t//equals() function should not affect return value of getValue() function and should return the original value\n\t\tassertTrue(data2.getValue() == 100);\t\t//equals() function should not affect return value of getValue() function and should return the original value\t\n\t}", "private boolean comps(int a, int b){\n\t\tthis.comparisons.add(new Integer[]{a, b});\n\t\treturn true;\n\t}", "public static void main(String[] args) {\n\n\t\tdouble [] num1 = {1.1, 3.9, 2.2};\n\t\tdouble [] num2 = {2.4, 2.88};\n\t\tdouble []target = combineArray(num1, num2);\n\t\tSystem.out.println(Arrays.toString(target));\n\t\tSystem.out.println(Arrays.toString(combineArray(num1, num2)));\n\t\t\n\t\tdouble [] expected = {1.1, 3.9, 2.2, 2.4, 2.88};\n\t\t\n\t\tif(Arrays.equals(expected, target)) {\n\t\t\tSystem.out.println(\"PASSED\");\n\t\t}else {\n\t\t\tSystem.out.println(\"FAILED\");\n\t\t}\n\t\t\t\n\t\t\n\t}", "public AlgoAreEqual(Construction cons, GeoElement inputElement1,\n\t\t\tGeoElement inputElement2) {\n\t\tsuper(cons);\n\t\tthis.inputElement1 = inputElement1;\n\t\tthis.inputElement2 = inputElement2;\n\n\t\toutputBoolean = new GeoBoolean(cons);\n\n\t\tsetInputOutput();\n\t\tcompute();\n\n\t}", "boolean compare(Object targetOne, Object targetTwo);", "@Test public void equalTest() {\n Dog d = new Dog(\"Owner 1\", \"Rex\", \"Boxer\", 90.0, 7);\n Dog d2 = new Dog(\"Owner 2\", \"Spot\", \"Pit Bull\", 90.0, 7);\n Assert.assertEquals(0, test.compare(d, d2));\n }", "private int compareUniqueness(double val1, double val2) {\n return Integer.compare((int) (val1 * 10000d), (int) (val2 * 10000d));\n }", "public static final boolean allTheSame(float... numbers) {\n\n for (int i = 1; i < numbers.length; i++) {\n if (numbers[i] != numbers[i - 1]) return false;\n }\n return true;\n }", "@Test\r\n public void testCompliment1() {\r\n int actual[] = set1.getComplement();\r\n Assert.assertArrayEquals(new int[] { 100, 200, 456, 234, 890, 990, 100,\r\n 210, 500, 700, 900 }, actual);\r\n }", "@Test\n public void testEquals() {\n Term t1 = structure(\"abc\", atom(\"a\"), atom(\"b\"), atom(\"c\"));\n Term t2 = structure(\"abc\", integerNumber(), decimalFraction(), variable());\n PredicateKey k1 = PredicateKey.createForTerm(t1);\n PredicateKey k2 = PredicateKey.createForTerm(t2);\n testEquals(k1, k2);\n }", "@RepeatedTest(20)\n void multTest(){\n assertEquals(f.mult(f), new Float(decimal*decimal));\n assertEquals(f.mult(g), new Float(decimal*random));\n assertEquals(f.mult(g), g.mult(f));\n assertEquals(f.mult(i), new Float(decimal*seed));\n assertEquals(f.mult(bi), new Float(decimal*bi.toInt(bi.getBinary())));\n assertEquals(i.mult(f), new Float(seed*decimal));\n assertEquals(i.mult(i), new Int(seed*seed));\n assertEquals(i.mult(j), new Int(seed*random));\n assertEquals(i.mult(j), j.mult(i));\n assertEquals(i.mult(bi), new Int(seed*bi.toInt(bi.getBinary())));\n\n //nulls\n //Bool * ITypes\n assertEquals(bot.mult(st),Null);\n assertEquals(bof.mult(st),Null);\n assertEquals(bot.mult(bot),Null);\n assertEquals(bof.mult(bot), Null);\n assertEquals(bot.mult(f), Null);\n assertEquals(bof.mult(i), Null);\n assertEquals(bot.mult(bi), Null);\n //Float * ITypes \\ {Numbers}\n assertEquals(f.mult(st), Null);\n assertEquals(f.mult(bot), Null);\n assertEquals(f.mult(bof), Null);\n //Int * ITypes \\ {Numbers}\n assertEquals(i.mult(st), Null);\n assertEquals(i.mult(bot),Null);\n assertEquals(i.mult(bof), Null);\n //Binary * ITypes \\ {Int, Binary}\n assertEquals(bi.mult(st), Null);\n assertEquals(bi.mult(bot), Null);\n assertEquals(bi.mult(f), Null);\n //NullType multiplications\n assertEquals(Null.mult(st), Null);\n assertEquals(Null.mult(bof), Null);\n assertEquals(Null.mult(f), Null);\n assertEquals(Null.mult(i), Null);\n assertEquals(Null.mult(bi), Null);\n assertEquals(Null.mult(Null), Null);\n assertEquals(st.mult(Null), Null);\n assertEquals(bot.mult(Null), Null);\n assertEquals(f.mult(Null), Null);\n assertEquals(i.mult(Null), Null);\n assertEquals(bi.mult(Null), Null);\n }", "@Test public void compareToTest3() throws NegativeValueException {\n PetBunny pb1 = new PetBunny(\"Floppy\", \"Holland Lop\", 3.5);\n ShowBunny sb1 = new ShowBunny(\"Bigun\", \"Flemish Giant\", 2.0, 22.0);\n \n Assert.assertTrue(pb1.compareTo(sb1) > 0);\n }", "@Test\n void compareTo_NoMatch_AllParts() {\n runIsMatchTest(AnswerType.no, AnswerType.no, AnswerType.no, AnswerType.no, ContactMatchType.NoMatch);\n }", "@Override\n public void execute(Frame frame) {\n DCMPBase.compare(frame, true);\n }", "static boolean bigint_eq(bigint a, bigint b)\n {\n if (a.bigint_sign != b.bigint_sign)\n return false;\n else if (a.bigint_len != b.bigint_len)\n return false;\n else\n {\n for (int i = 0; i < a.bigint_len; i++)\n if (a.bigint_chiffres[i] != b.bigint_chiffres[i])\n return false;\n return true;\n }\n }", "public static void compare () {\r\n for (int i = 0; i < dim; i++) {\r\n for (int j = 0; j < dim; j++) {\r\n if (d[i][j] != adjacencyMatrix[i][j])// here \r\n {\r\n System.out.println(\"Comparison failed\");\r\n \r\n return;\r\n }\r\n }\r\n }\r\n System.out.println(\"Comparison succeeded\");\r\n }", "public int compare(Dataset object1, Dataset object2){\n if(object1.getAttributeCount() != candidate.getAttributeCount() ||\n object2.getAttributeCount() != candidate.getAttributeCount()){\n return 0;\n }\n\n double dist1 = 0.0, dist2 = 0.0;\n double tmp1 = 0.0, tmp2 = 0.0;\n\n for(int i = 0; i < candidate.getAttributeCount(); i++){\n if(candidate.getOutputColumnCount() == (i+1)){\n continue;\n }\n\n Attribute ac = candidate.getAttribute(i);\n Attribute a1 = object1.getAttribute(i);\n Attribute a2 = object2.getAttribute(i);\n\n if(ac.getType() == AttributeTypes.TEXT){\n dist1 += DatasetEuklidianComparator.unlimitedCompare((String)ac.getValue(), (String)a1.getValue());\n dist2 += DatasetEuklidianComparator.unlimitedCompare((String)ac.getValue(), (String)a2.getValue());\n }else{\n /*\n double acDouble = 0.0;\n double a1Double = 0.0;\n double a2Double = 0.0;\n switch(ac.getType()){\n case INTEGER: acDouble = (double)((Integer)ac.getValue()).intValue(); break;\n case DECIMAL: acDouble = (double)ac.getValue();\n }\n switch(a1.getType()){\n case INTEGER: a1Double = (double)((Integer)a1.getValue()).intValue(); break;\n case DECIMAL: a1Double = (double)a1.getValue();\n }\n switch(a2.getType()){\n case INTEGER: a2Double = (double)((Integer)a2.getValue()).intValue(); break;\n case DECIMAL: a2Double = (double)a2.getValue();\n }*/\n double acDouble = (double)ac.getValue();\n double a1Double = (double)a1.getValue();\n double a2Double = (double)a2.getValue();\n\n tmp1 += Math.pow(a1Double-acDouble, 2);\n tmp2 += Math.pow(a2Double-acDouble, 2);\n }\n }\n\n dist1 += Math.sqrt(tmp1);\n dist2 += Math.sqrt(tmp2);\n\n if (dist1 > dist2) {\n return 1;\n }\n if (dist1 < dist2) {\n return -1;\n }\n return 0;\n }", "@Test\n public void testIntersection5()\n {\n final int[] ints1 = {33, 100000};\n final int[] ints2 = {34, 200000};\n List<Integer> expected = new ArrayList<>();\n\n ConciseSet set1 = new ConciseSet();\n for (int i : ints1) {\n set1.add(i);\n }\n ConciseSet set2 = new ConciseSet();\n for (int i : ints2) {\n set2.add(i);\n }\n\n verifyIntersection(expected, set1, set2);\n }", "public float compare(DataSample ds) {\n \treturn compare(center, ds);\n }", "private boolean valueEquals(Object val1, Object val2) {\n if (val1 == val2) {\n return true;\n }\n\n // One and only one of the value is null\n if (val1 == null || val2 == null) {\n return false;\n }\n\n return val1.equals(val2);\n }", "public boolean allDuplicatesEqual() {\n int[] input = {1, 2, 2, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 5};\n int dupA = findDuplicatesA(input);\n int dupB = findDuplicatesB(input);\n int dupC = findDuplicatesC(input);\n int dupD = findDuplicatesD(input);\n int dupE = findDuplicatesE(input);\n return dupA == dupB && dupA == dupC && dupA == dupD && dupA == dupE;\n }", "@Test\n\tpublic void testSampleEquals() {\n\n\t\tassertTrue(square.equals(squareRotate));\n\t\t\n\t\tassertTrue(pyr1.equals(pyr5));\n\t\t\n\t\tassertTrue(s.equals(sInitial));\n\t\tassertFalse(stick.equals(stickRotated));\n\t\tassertFalse(s.equals(sRotated));\n\n\n\t}", "public static void main(String[] args) {\n\t\tint[] arr1 = { 10, 12, 55, 32, 17 };\n\t\tint[] arr2 = { 10, 12, 55, 32, 17 };\n\t\t/*//Second set\n\t\tint[] arr1 = {10,12,55,32,17,99};\n\t\tint[] arr2 = {10,12,55,32,17}};*/\n\t\t/* //Third set\n\t\tint[] arr1 = {10,12,55,32,17};\n\t\tint[] arr2 = {10,12,99,32,17}};*/\n\n\t\tArraysIdentical arrayidentical = new ArraysIdentical();\n\t\tarrayidentical.identicalCheck(arr1, arr2);\n\n\t}", "@Override\n\tpublic Scores compare(File f1, File f2) {\n\t\treturn new Scores(1.0, \"AlwaysTrueComparisonStrategy:1\");\n\t}", "@Test\r\n public void testReflexiveForEqual() throws Exception {\n\r\n EmployeeImpl emp1 = new EmployeeImpl(\"7993389\", \"[email protected]\");\r\n EmployeeImpl emp2 = new EmployeeImpl(\"7993389\", \"[email protected]\");\r\n\r\n Assert.assertTrue(\"Comparable implementation is incorrect\", emp1.compareTo(emp2) == 0);\r\n Assert.assertTrue(\"Comparable implementation is incorrect\", emp1.compareTo(emp2) == emp2.compareTo(emp1));\r\n }", "@Test\n public void testSumUsingCommutativityProperty() {\n for (int i = 0; i < 100; i++) {\n int x = randomInt();\n int y = randomInt();\n assertThat(sum(x, y), equalTo(sum(y, x)));\n }\n }", "private boolean runMultiSampleCase() {\n\t\tArrayList<Candidate> candidates = collectTrioCandidates();\n\n\t\t// Then, check the candidates for all trios around affected individuals.\n\t\tfor (Candidate c : candidates)\n\t\t\tif (isCompatibleWithTriosAroundAffected(c))\n\t\t\t\treturn true;\n\t\treturn false;\n\t}", "public static boolean compareListElements(ArrayList<Double> a,ArrayList<Double> b){\n\t\t\n\t\tif(a==null && b==null)\n\t\t\treturn true;\n\t\t\n\t\tif(a.size()!=b.size())\n\t\t\treturn false;\n\t\t\n\t\tint i=0,j,k;\n\t\t\n\t\twhile(i<a.size())\n\t\t{\n\t\t\tj=(int) (100*a.get(i));\n\t\t\tk=(int) (100*b.get(i));\n\t\t\t\n\t\t\tif(j!=k)\n\t\t\t\treturn false;\n\t\t\telse\n\t\t\t\ti++;\n\t\t}\n\t\t\n\t\treturn true;\n\t}", "public static void main(String[] args) {\n\t\tint[] arr1 = {2,4,7,8,9,1};\n\t\tint[] arr2 = {7,4,8,9,1,2};\n\t\tSystem.out.println(checkEqual(arr1, arr2));\n\n\t}", "static boolean areSame(String expr1, String expr2)\n\t{\n\n\t\t// Create a vector for all operands and\n\t\t// initialize the vector as 0.\n\t\tint[] v = new int[MAX_CHAR];\n\n\t\t// Put signs of all operands in expr1\n\t\teval(expr1, v, true);\n\n\t\t// Subtract signs of operands in expr2\n\t\teval(expr2, v, false);\n\n\t\t// If expressions are same, vector must\n\t\t// be 0.\n\t\tfor (int i = 0; i < MAX_CHAR; i++)\n\t\t\tif (v[i] != 0)\n\t\t\t\treturn false;\n\n\t\treturn true;\n\t}", "@Test\n public void compareFunctionalBigger() {\n HighScoreComparator comparator2 = new HighScoreComparator();\n int a;\n a = comparator2.compare(p1, p2);\n \n assertEquals(-1, a);\n\n }", "Boolean same(MapComp<K, V> m);", "@Test\n public void compareTo() {\n Road road1 = new Road(cityA, cityB, 0);\n Road road2 = new Road(cityA, cityC, 1);\n Road road3 = new Road(cityB, cityA, 2);\n Road road4 = new Road(cityA, cityB, 3);\n /**Test of reflexivity x = x*/\n assertEquals(0,road1.compareTo(road1)); \n \n /**Test of transitivity of < a<b & b<c => a<c*/\n assertTrue(road1.compareTo(road2) < 0);\n assertTrue(road2.compareTo(road3) < 0);\n assertTrue(road1.compareTo(road3) < 0);\n \n /**Test of transitivity of > */\n assertTrue(road3.compareTo(road2) > 0);\n assertTrue(road2.compareTo(road1) > 0);\n assertTrue(road3.compareTo(road1) > 0);\n \n /**Test of antisymmetry a<=b & b<=a => a=b*/\n assertTrue(road1.compareTo(road4) >= 0);\n assertTrue(road1.compareTo(road4) <= 0);\n assertEquals(0,road1.compareTo(road4));\n \n /**Test of symmetry a=b <=> b=a*/\n assertEquals(0,road1.compareTo(road4));\n assertEquals(0,road4.compareTo(road1));\n assertTrue(road1.compareTo(road4) == road4.compareTo(road1));\n /**Both symmetry tests fail since the length of road1 and road4\n * are unequal. As a result we should compare lengths aswell,\n * however in the current iteration of the program we do not\n * need to compare lengths for the program to run as intended*/\n }", "@Test\n public void testCompareTo_1() {\n LOGGER.info(\"testCompareTo_1\");\n final AtomString atomString1 = new AtomString();\n final AtomString atomString2 = new AtomString();\n final int actual = atomString1.compareTo(atomString2);\n final int expected = 0;\n assertEquals(expected, actual);\n }", "private void usual() {\n try {\n //testing toString\n assertTrue(\"toString0\",\n f0.toString().equals(\"{...(0 elements)...}\"));\n assertTrue(\"toString1\",\n f1.toString().equals(\"{...(1 elements)...}\"));\n assertTrue(\"toString7\",\n f7.toString().equals(\"{...(2 elements)...}\"));\n\n //testing equals\n\n assertTrue(\"equals00\", f0.equals(f0));\n assertTrue(\"equals33\", f3.equals(f3));\n assertTrue(\"equals55\", f5.equals(f5));\n assertTrue(\"equals46\", f4.equals(f6));\n assertTrue(\"equals64\", f6.equals(f4));\n assertTrue(\"equals27\", f2.equals(f7));\n assertTrue(\"equals72\", f7.equals(f2));\n\n assertFalse(\"equals01\", f0.equals(f1));\n assertFalse(\"equals02\", f0.equals(f2));\n assertFalse(\"equals10\", f1.equals(f0));\n assertFalse(\"equals12\", f1.equals(f2));\n assertFalse(\"equals21\", f2.equals(f1));\n assertFalse(\"equals23\", f2.equals(f3));\n assertFalse(\"equals35\", f3.equals(f5));\n\n assertFalse(\"equals0string\", f0.equals(\"just a string\"));\n assertFalse(\"equals4string\", f4.equals(\"just a string\"));\n\n assertFalse(\"equals0null\", f0.equals(null));\n assertFalse(\"equals1null\", f1.equals(null));\n\n //testing hashCode\n assertTrue(\"hashCode00\", f0.hashCode() == f0.hashCode());\n assertTrue(\"hashCode44\", f4.hashCode() == f4.hashCode());\n assertTrue(\"hashCode46\", f4.hashCode() == f6.hashCode());\n assertTrue(\"hashCode27\", f2.hashCode() == f7.hashCode());\n }\n catch(Exception e) {\n System.out.println(\"Exception thrown during usual tests:\");\n System.out.println(e);\n assertTrue(\"usual\", false);\n }\n }", "@Test public void compareToTest1() throws NegativeValueException {\n PetBunny pb1 = new PetBunny(\"Floppy\", \"Holland Lop\", 3.5);\n ShowBunny sb1 = new ShowBunny(\"Bigun\", \"Flemish Giant\", 14.6, 22.0);\n \n Assert.assertTrue(pb1.compareTo(pb1) == 0);\n }", "public int compareWriteLockValues(Object value1, Object value2) {\r\n long longValue1 = ((Number)value1).longValue();\r\n long longValue2 = ((Number)value2).longValue();\r\n if ( longValue1 < longValue2 ) return -1;\r\n if ( longValue1 == longValue2 ) return 0;\r\n return 1;\r\n }", "public boolean hasSimilarValueCombination(IntList anotherColValues) {\r\n if (colValues.size() != anotherColValues.size())\r\n throw new RuntimeException(\"Some previous bug led to comparision of ValueCombination having diff number of colValues\");\r\n\r\n return colValues.equals(anotherColValues);\r\n }" ]
[ "0.6177228", "0.6048438", "0.6002315", "0.58520675", "0.5793062", "0.57484686", "0.57234144", "0.5629739", "0.5586594", "0.55786014", "0.55750245", "0.5549054", "0.5522518", "0.5502063", "0.54977936", "0.54945093", "0.5480731", "0.5479921", "0.5479867", "0.5469857", "0.54430664", "0.54261833", "0.54217285", "0.54049623", "0.53968024", "0.53705543", "0.5360182", "0.53432256", "0.5340929", "0.5337927", "0.53260446", "0.53129697", "0.5312472", "0.528229", "0.52617997", "0.5255038", "0.5249147", "0.5230611", "0.5225923", "0.52114636", "0.5205147", "0.5204191", "0.5203666", "0.52011716", "0.51999384", "0.5187095", "0.5180297", "0.51769036", "0.5175523", "0.51754767", "0.5172635", "0.5168248", "0.5163832", "0.5151805", "0.51447403", "0.5133026", "0.512901", "0.51282877", "0.51270187", "0.51253945", "0.51099306", "0.51088655", "0.5102755", "0.51024956", "0.5100659", "0.50956905", "0.5090184", "0.50896853", "0.50884765", "0.5086957", "0.5076266", "0.507368", "0.5072471", "0.50717604", "0.5068416", "0.5062804", "0.5061062", "0.50373477", "0.50352824", "0.5034918", "0.5034606", "0.5021335", "0.50203323", "0.5020199", "0.50100446", "0.5007212", "0.50053626", "0.4998724", "0.49950215", "0.49856463", "0.49809527", "0.49784672", "0.4973594", "0.49718922", "0.4960602", "0.49555504", "0.49535", "0.49520925", "0.49356085", "0.4930547", "0.49293965" ]
0.0
-1
Press the back button in mobile phone
@Override public void onBackPressed() { finish(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void onBackPressed() {\n backbutton();\n }", "@Override\n // Detect when the back button is pressed\n public void onBackPressed() {\n\n // Let the system handle the back button\n\n super.onBackPressed();\n\n }", "@Override\n\tpublic void onBackPressed()\n\t\t{\n\t\tbackPressed();\n\t\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tBack();\n\t}", "public void back()\n\t{\n\t\tdriver.findElementById(OR.getProperty(\"BackButton\")).click();\n\t}", "@Override\n public void onBackPressed() {\n backToHome();\n }", "void onGoBackButtonClick();", "@Override\n\tpublic void onBackPressed() {\n\t\texitApplication().onClick(null);\n\t\tsuper.onBackPressed();\n\t}", "@Override\n public void onBackPressed() {\n\n Intent homeIntent = new Intent(Intent.ACTION_MAIN);\n homeIntent.addCategory( Intent.CATEGORY_HOME );\n homeIntent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n startActivity(homeIntent);\n }", "@Override\r\n\tpublic void onBackPressed() {\n\t\tbackButtonHandler();\r\n\t\treturn;\r\n\t}", "@Override\r\n\tpublic boolean onKeyDown(int keyCode, KeyEvent event) {\r\n\t\t//handle click on back button\r\n\t if (keyCode == KeyEvent.KEYCODE_BACK) {\r\n\t \t//return to previous screen\r\n\t \treturnToPriviousActivityWithoutDevice();\r\n\t }\r\n\t return super.onKeyDown(keyCode, event);\r\n\t}", "public void back() {\n Views.goBack();\n }", "@Override\n\tpublic void onBackPressed() {\n\t\tIntent intent = new Intent(Intent.ACTION_MAIN);\n intent.addCategory(Intent.CATEGORY_HOME);\n intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n startActivity(intent);\n finish();\n System.exit(0);\n\t}", "public static void pressBack() {\n onView(isRoot()).perform(ViewActions.pressBack());\n }", "@Override\r\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\r\n\t\tdoBack();\r\n\t}", "@Override\r\n\tpublic void onBackPressed(){\r\n\t\tLog.d(TAG, \"Back Button Pushed\");\r\n\t\tIntent goHomeIntent = new Intent(Intent.ACTION_MAIN);\r\n\t\tgoHomeIntent.addCategory(Intent.CATEGORY_HOME);\r\n\t\tgoHomeIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\r\n\t\tstartActivity(goHomeIntent);\r\n\t}", "@Override\n public void onBackPressed() {\n if(web.canGoBack()){\n web.goBack();\n } else {\n super.onBackPressed();\n }\n }", "public void onBackPressed() {\r\n }", "@Override\n\tpublic void onBackPressed() {\n\t\t\n\t}", "public abstract boolean onBackPressed(boolean isSystemBackKey);", "@Override\n public void backPressed(){\n }", "@Override\n public void backButton() {\n\n\n }", "@Override\n public void onBackPressed() {}", "@Override\r\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed()\n {\n mIsBackButtonPressed = true;\n super.onBackPressed();\n \n }", "public void goBack() {\n goBackBtn();\n }", "@Override\r\n\tpublic void backButton() {\n\t\t\r\n\t}", "@Override\n public void onBackPressed() {\n Intent i = new Intent(StockAdjustmentList.this, ActivityHomeScreen.class);\n startActivity(i);\n i.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);\n startActivity(i);\n finish();\n }", "@Override\r\n\tpublic void onBackPressed() {\n\r\n\t}", "@Override\r\n\tpublic void onBackPressed() {\n\r\n\t}", "@Override\n \tpublic void onBackPressed() {\n \t}", "@Override\n\tpublic void onBackPressed() {\n\treturn;\n\t}", "@Override\n public void onBackPressed()\n {\n\n }", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\n\t\t\n\t}", "@Override\n\tpublic void onBackPressed() {\n\n\t}", "@Override\r\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\r\n\t}", "@Override\r\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\r\n\t}", "private void onBack() {\n\t\tIntent startMain = new Intent(Intent.ACTION_MAIN);\r\n\t\tstartMain.addCategory(Intent.CATEGORY_HOME);\r\n\t\tstartMain.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP); // //FLAG_ACTIVITY_NEW_TASK\r\n\t\tstartActivity(startMain);\r\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t}", "@Override\r\n\tpublic void onBackPressed() {\n\t\tfinish();\r\n\t}", "@Override\r\n\tpublic void onBackPressed() {\n\t\tfinish();\r\n\t}", "public void goBackToAppHome() {\n UiObject topNavigationBar = mDevice.findObject(new UiSelector().text(\"mytaxi demo\"));\n int backpressCounter = 0; //to avoid infinite loops\n while(!topNavigationBar.exists()) {\n mDevice.pressBack();\n backpressCounter++;\n if(backpressCounter>10)\n break;\n }\n }", "@Override\n public void onBackPressed() {\n Intent intent = new Intent(Intent.ACTION_MAIN);\n intent.addCategory(Intent.CATEGORY_HOME);\n intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n startActivity(intent);\n }", "@Override\n public void onBackPressed() {\n Intent intent = new Intent(Intent.ACTION_MAIN);\n intent.addCategory(Intent.CATEGORY_HOME);\n intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n startActivity(intent);\n }", "@Override\n public void onBackPressed() {\n if (backPressed >= 1) {\n finishAffinity();\n super.onBackPressed();\n\n\n } else {\n // clean up\n backPressed = backPressed + 1;\n Toast.makeText(this, getString(R.string.press_back_exit),\n Toast.LENGTH_SHORT).show();\n }\n }", "public void Back(View view) {\n\n onBackPressed();\n }", "@Override\n public void onBackPressed()\n {\n if(backButtonCount >= 1)\n {\n Intent intent = new Intent(Intent.ACTION_MAIN);\n intent.addCategory(Intent.CATEGORY_HOME);\n intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n startActivity(intent);\n }\n else\n {\n Toast.makeText(this, \"Press the back button once again to close the application.\", Toast.LENGTH_SHORT).show();\n backButtonCount++;\n }\n }", "@Override\n\tpublic void onBackPressed()\n\t{\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\treturn;\n\t}", "@Override\n public void onBackPressed() { }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n public void onBackPressed() {\n }", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\n\t\tnavigatetoAppointmentsListingScreen(\"false\");\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t\treturn;\n\t}", "@Override\n public void onBackPressed() {\n if (!mTouchAnyWhere) {\n super.onBackPressed();\n return;\n }\n\n goBackDialog();\n }", "@Override\n public void onBackPressed(){\n System.out.println(\"---------------- No debe hacer nada -------------------------------\");\n }", "public void onBackPressed()\n {\n }", "public void backButtonPressed(View view) {\n onBackPressed();\n }", "@Override\n public void onBackPressed() {\n\n\n super.onBackPressed();\n\n }", "public void onBackPressed(){\n super.onBackPressed();\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN) {\n finishAffinity();\n\n }else {\n finish();\n }\n }", "public void onBackPressed() {\n C0486WU wu = this.f2780c;\n if (wu != null) {\n wu.mo1418b();\n }\n finish();\n Share_IP.super.onBackPressed();\n setResult(0, new Intent());\n }", "@Override\n public void onBackPressed() {\n finishAffinity();\n }", "public void clickBackButton() {\n\t\tbackButton.click();\n\n\t}", "private void navBack() {\n Intent intent = new Intent(this, standard_home.class);\n startActivity(intent);\n }", "@Override\n public void onBackPressed() {\n super.onBackPressed();\n finishAffinity();\n\n }", "public void clickBack(View view){\r\n onBackPressed();\r\n }", "@Override\n public void onClick(View view) {\n onBackPressed(); }", "@Override\n public void onBackPressed(){\n }", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t\tfinish();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t\tfinish();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t\tfinish();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tsuper.onBackPressed();\n\t\tIntent homeIntent = new Intent(Intent.ACTION_MAIN);\n\t\thomeIntent.addCategory(Intent.CATEGORY_HOME);\n\t\thomeIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n\t\tstartActivity(homeIntent);\n\t}", "@Override\n public void onBackPressed() {\n confirmExit();\n }", "@Override\n\tpublic void onBackPressed() {\n\t\tfinish();\n\t\tsuper.onBackPressed();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tfinish();\n\t\tsuper.onBackPressed();\n\t}", "@Override\n\tpublic void onBackPressed() {\n\t\tmoveTaskToBack(false);\n\t}" ]
[ "0.8027102", "0.7927077", "0.79096097", "0.7872758", "0.7839554", "0.7822377", "0.78218776", "0.7805891", "0.7771318", "0.7749204", "0.77409464", "0.7725984", "0.7717523", "0.7714474", "0.7706449", "0.77046996", "0.7699043", "0.7697619", "0.76962906", "0.76910275", "0.7687056", "0.7679208", "0.76764256", "0.7663084", "0.76549166", "0.7653469", "0.76511526", "0.7650049", "0.7648368", "0.7648368", "0.7642311", "0.7625351", "0.76247483", "0.7622942", "0.76131344", "0.76119465", "0.76119465", "0.7610977", "0.76027215", "0.76027215", "0.76027215", "0.76027215", "0.76026285", "0.76026285", "0.76012343", "0.7588238", "0.7588238", "0.7587683", "0.7587413", "0.75865394", "0.75745463", "0.756789", "0.7563671", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7553908", "0.7542796", "0.7542796", "0.7542796", "0.7542796", "0.7542796", "0.7542796", "0.7542796", "0.7542796", "0.7531105", "0.7528171", "0.75246155", "0.75237596", "0.75227183", "0.7514137", "0.7510041", "0.7509729", "0.7507899", "0.7506621", "0.749813", "0.7493239", "0.74880326", "0.7484542", "0.7476135", "0.74738747", "0.747255", "0.747255", "0.747255", "0.74704087", "0.7470096", "0.7469624", "0.7469624", "0.74605143" ]
0.0
-1
interface that hosting activity has to implement
public interface SurveyVoteListener { void voteListener(int yes, int no); void editListener(String newQuestion, String newOptionOne, String newOptionTwo); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public interface ActivityInterface {\n public void initView();\n public void setUICallbacks();\n public int getLayout();\n public void updateUI();\n}", "public interface ActivityLauncher {\r\n\r\n\tpublic void launchActivity();\r\n\r\n\tpublic void finishCurrentActivity();\r\n\r\n}", "public interface ISEActivityAttatcher {\n void onCreate(Bundle savedInstanceState);\n void onStart();\n void onRestart();\n void onResume();\n void onPause();\n void onStop();\n void onDestroy();\n void onActivityResult(int requestCode, int resultCode, Intent data);\n boolean isRecyled();\n}", "public interface MeetingAddActivityView {\n\n void startMeetingsActivity();\n void successInfo(String msg);\n void errorInfo(String msg);\n void startGetCustomers();\n}", "public interface IActivity {\n void bindData();\n\n void bindListener();\n}", "public interface MeetingsActivityView {\n void startMainActivity();\n\n void startMeetingDetailsActivity();\n\n void startMeetingAddActivity();\n\n void errorInfo(String msg);\n\n void errorMeetingCompletedInfo(String msg);\n void successMeetingCompletedInfo(String msg);\n\n\n void startGetMeetings();\n}", "public interface MyBaseActivityImp {\n\n /**\n * 跳转Activity;\n *\n * @param paramClass Activity参数\n */\n void gotoActivity(Class<?> paramClass);\n\n /**\n * 跳转Activity,带有Bundle参数;\n *\n * @param paramClass Activity参数\n * @param bundle Bundle参数\n */\n void gotoActivity(Class<?> paramClass, Bundle bundle);\n\n /**\n * 跳转Activity,带有Bundle参数,并且该Activity不会压入栈中,返回后自动关闭;\n *\n * @param paramClass Activity参数\n * @param bundle Bundle参数\n */\n void gotoActivityNoHistory(Class<?> paramClass, Bundle bundle);\n\n /**\n * @param paramClass\n * @param bundle\n * @param paramInt\n */\n void gotoActivityForResult(Class<?> paramClass, Bundle bundle, int paramInt);\n\n /**\n * init View\n */\n void initView();\n\n /**\n *\n */\n void onEvent(Object o);\n}", "public interface ActivityAction {\r\n public void viewedActivity(String condition, String viewerFullName);\r\n}", "public interface IBaseView {\n\n void showToastMessage(String message);\n\n void setProgressBar(boolean show);\n\n void showNetworkFailureMessage(boolean show);\n\n Context getPermission();\n\n void startNewActivity();\n\n}", "public interface ActivityAware<E> {\r\n E getContextActivity();\r\n}", "public interface ActivityView extends AceView {\n void finish();\n}", "public interface MainView extends MvpView{\n void startAnekdotActivity(int type);\n}", "protected interface Activity {\r\n boolean isActive(File dir);\r\n }", "public interface Presenter {\n void onCreate();\n\n void onStart();\n\n void onStop();\n\n void pause();\n\n void attachView(View view);\n\n\n void attatchIncomingIntent(Intent intent);\n}", "public interface NotificationSenderActivity {\n\n public void update();\n\n}", "public interface ActivityInterface {\n\n int getLayout();\n\n void initView();\n}", "public interface IActivityBase {\n\n void showToast(String msg);\n void showAlert(String msg);\n\n}", "public interface OmnomActivity {\n\tpublic static final int REQUEST_CODE_ENABLE_BLUETOOTH = 100;\n\tpublic static final int REQUEST_CODE_SCAN_QR = 101;\n\n\tvoid start(Intent intent, int animIn, int animOut, boolean finish);\n\n\tvoid startForResult(Intent intent, int animIn, int animOut, int code);\n\n\tvoid start(Class<?> cls);\n\n\tvoid start(Class<?> cls, boolean finish);\n\n\tvoid start(Intent intent, boolean finish);\n\n\tActivity getActivity();\n\n\tint getLayoutResource();\n\n\tvoid initUi();\n\n\tPreferenceProvider getPreferences();\n\n\tSubscription subscribe(final Observable observable, final Action1<? extends Object> onNext, final Action1<Throwable> onError);\n\n\tvoid unsubscribe(final Subscription subscription);\n\n}", "public interface IViewListActivity {\n\n Context getBaseContext();\n\n View findViewById(final int id);\n\n void onResultList(final List<Filme> filmes);\n\n void setSupportActionBar(Toolbar toolbar);\n\n void startSearch();\n\n void onErrorSearch(final String errorMsg);\n\n void onSuccess(final Filme filme);\n\n}", "public interface IController {\n public void onActivityPause();\n\n public void onActivityResume(Activity activity);\n}", "public interface MainActivityView {\n\n}", "public interface IFirstActivityView {\n void setData(HotData hotData);\n void setFailMessage(String error);\n}", "public interface IRegisterActivityView extends IActivityView{\n void onRegisteredSuccessfully();\n void onError(String message);\n}", "void doActivity();", "interface LoginChamaPresenter {\n\n /**when activity is resumed*/\n void onResume();\n\n /** performs actions on user click, passes the position to implementer*/\n void onChamaItemClicked(int position);\n\n void onDestroy();\n}", "public interface IStartView {\n\n void showStartInfo(String url);\n void goMainActivity();\n}", "public interface IBaseFragmentActivity {\n void onFragmentExit(BaseFragment fragment);\n\n void onFragmentStartLoading(BaseFragment fragment);\n\n void onFragmentFinishLoad(BaseFragment fragment);\n}", "public interface LoadActivityView {\n public void LoadSuccess(String registerBean);\n public void LoadFailed(int code);\n}", "@Override\n\tprotected void onHandleIntent(Intent arg0) {\n\t\t\n\t}", "public interface MainActivityView {\n\n void showLoading();\n void hideLoading();\n void toMainActivity(String data);\n}", "public interface OnNewIntent {\n void onNewIntent(ZHIntent zHIntent);\n}", "@Override\n\tpublic void starctActivity(Context context) {\n\t\t\n\t}", "@Override\n public void onActivityCreated(Activity activity, Bundle bundle) {}", "public interface IBaseView {\n\n void toActivity(Class<?> clazz);\n\n void showProgressBar();\n\n void cancelProgressBar();\n\n void setTransBar();\n\n}", "public interface ZachetManager extends ActivityManager<Zachet> {\n}", "public interface IshowPersonalCommentActivityView extends IBaseActivityView{\n void showPersonalCommentSuccess(List<CommentEntity> commentList, boolean isHaveMore);\n void showPersonalCommentFail();\n}", "public interface IActivityDelegate {\n\n void onCreateBefore(Bundle savedInstanceState);\n\n void onCreate(Bundle savedInstanceState);\n\n void onSaveInstanceState(Bundle outState);\n\n void onResume();\n\n void onPause();\n\n void onDestroy();\n\n void onBackPressed();\n\n void finish();\n\n void overridePendingTransition(int enterAnim, int exitAnim);\n\n void onActivityResult(int requestCode, int resultCode, Intent data);\n}", "public interface IActivityCategoryView {\n void getMusicList(FileModel fileModel);\n void onStartLoadMusicList();\n void onCompletLoadMusicList();\n void onLoadMusicError(String er);\n}", "@Override\n\tpublic void setActivity(Activity pAcitivity) {\n\n\t}", "public abstract Activity getActivity(IBinder token);", "public interface PluginInterface {\n\n public void attach(Activity proxyActivity);\n\n public void onCreate(Bundle saveInstanceState);\n\n public void onStart();\n\n public void onResume();\n\n public void onPause();\n\n public void onStop();\n\n public void onDestroy();\n\n public void onSaveInstanceState(Bundle outSate);\n\n public boolean onTouchEvent(MotionEvent event);\n\n public void onBackPressed();\n\n\n}", "public interface IEditTripActivityPresenter {\n public void setData(Intent intent);\n public void editTrip();\n public void startSerivice();\n public void stopService();\n}", "@Override\n public void onActivityCreated(Activity activity, Bundle bundle) {\n }", "public interface Presenter {\n\n void onStart();\n\n void onStop();\n\n void onPause();\n\n void attachView(View v);\n\n void attachIncomingArg(Bundle intent);\n\n void onCreate();\n\n void onDestroy();\n}", "@Override\n\tprotected void onHandleIntent(Intent intent) {\n\n\t}", "@Override\n protected void onHandleIntent(Intent workIntent) {\n }", "@Override\n\tpublic void starctActivity(Context context) {\n\n\t}", "public interface PhotoGalleryActivityView extends BasicView {\n}", "public interface GameActivityInterface extends Serializable {\n\n /**\n * Called in ingamefragment when throwthread is done\n * @param dices send all the dices generate on a roll\n * */\n void onThrowPostPossibleScores(SparseArray<Dice> dices);\n /**\n * Set the player view\n *\n * @param v view of the application\n * */\n void setPlayerView(View v);\n /**\n * Set the score view\n *\n * @param v view of the application\n * */\n void setScoreView(View v);\n\n /**\n * Set the throws\n *\n * @param v view of the application\n * */\n void getThrows(View v);\n\n /**\n * Set rounds end\n *\n * @param player the current player\n * @param activity the game activity\n * */\n void roundsEnd(Player player,Activity activity);\n\n /**\n * Update view\n *\n * @param v view of the application\n * */\n void updateView(View v);\n\n /**\n * Update highscore\n *\n * @param v view of the application\n * */\n void updateHighScore(View v);\n\n}", "public interface PaymentActControl {\n void paymentCallback(int code, String message);\n Activity getActivity();\n}", "public interface VatomMetaPresenter {\n\n /**\n * Load vatom details on activity create and update VatomMetaScreen\n * @param intent\n */\n void onCreate(Intent intent);\n\n void onDestroy();\n\n void onOptionsItemSelected(MenuItem menuItem);\n\n}", "protected abstract Intent getIntent();", "public interface InstrumentationInternal {\n\n\tInstrumentation.ActivityResult execStartActivity(Context who, IBinder contextThread, IBinder token,\n\t\t\tActivity target, Intent intent, int requestCode, android.os.Bundle options);\n\n\tInstrumentation.ActivityResult execStartActivity(Context who, IBinder contextThread, IBinder token,\n\t\t\tActivity target, Intent intent, int requestCode);\n}", "private void openActivity() {\n }", "public interface MainActivityContract {\n interface View extends BaseView{\n\n\n void getLocationNow(android.view.View view);\n void onRequestPermissionsResult(int requestCode, String permissions[], int[] grantResults);\n void locationObtained(boolean isObtained);\n void locationEnabled(boolean isEnabled);\n void showerror(String s);\n\n\n }\n interface Presenter extends BasePresenter<View>{\n\n void attachView(MainActivityContract.View view);\n void checkLocationActive(Activity activity);\n void init(Activity activity);\n void getContext(Context context);\n void getLocation(String lattitude, String longitude);\n void getLocationByAddress(String a, String b, String c, String d, String e);\n void getLocationByGeo(String a, String b, String c, String d, String e);\n void DettachedView();\n }\n\n}", "public interface ViewSearchActivity {\n void clearQuery();\n void enableDeleteButton(boolean enable);\n\n void updateAdapter(List<SongMatch> results);\n\n void showEmptyView();\n void hideEmptyView();\n\n void showLimitBanner();\n\n void hideLimitBanner();\n}", "public interface CreateAccountBaseView {\n Activity getActivity();\n}", "public interface MainActivityUI\n{\n\t//Respond to MainActivityLogicInterface.init().\n\tvoid initCompleted();\n\t//Will be called, if bluetooth or beacons are not supported. \\p errorcode contains a human-readable description of the problem.\n\tvoid notSupported(String errorcode);\n\t//Will be called, if bluetooth is deactivated, but should be activated to detect beacons.\n\tvoid bluetoothDeactivated();\n\t//Will be called, if permissions for COARSE_LOCATION is not given, but should be to detect beacons.\n\tvoid askForPermissions();\n\n\t//Will be called, when no beacon and no local map was found.\n\tvoid switchToMapSelectActivity();\n\n\t//Respond to MainActivityLogicInterface.getMap(). \\p map is the data contained in the active map.\n\tvoid updateMap(MapData map);\n\n\t//Will be called, if a new 'nearest' beacon was found. \\p beaconID is the id of the new beacon in MapData.\n\tvoid updateBeaconPosition(int beaconID);\n\n\t//Respond to NavigationDrawerLogic.findSpecialBeacon() or NavigationDrawerLogik.findAllSpecialBeacons() to mark the results. \\p beaconIDs is a list of the beacons which should be marked.\n\tvoid markBeacons(List<Integer> beaconIDs);\n}", "public interface MyClassInterface {\n public void doSomething() ;\n public void adButton(LinearLayout linear, Activity activity) ;\n}", "@Override\n protected void onHandleIntent(Intent intent) {\n\n }", "public interface ListPersonaActivity {\n String TAG = \"listPersonaAct\";\n void showPersonas();\n}", "public interface HomeView {\n\n void OnProgress();\n void OnFinish();\n void OnError(String error);\n void OnSuccess(EntityFeed entityFeed);\n\n}", "interface Presenter {\n\n /*get data through intent*/\n void getBundleData(Intent intent);\n\n void callHistoryDetail(Bundle extra);\n int getStoreType();\n }", "public interface OnTaskClickedListener {\n\n void taskOpened(int taskId);\n}", "public interface C0869a {\n Intent getSupportParentActivityIntent();\n }", "protected ScllActivity iGetActivity() {\n\t\treturn (ScllActivity) getActivity();\n\t}", "@Override\r\n public void onAttach(Activity activity) {\n super.onAttach(activity);\r\n\r\n }", "public interface Activity<T extends Pane> extends Component, Haltable, Hookable {\n\n\tT getParent();\n\tActivityState getState();\n\n}", "public interface MeiziView extends IView {\n void finish();\n boolean isFavorite();\n void favoriteOrNot();\n Activity getActivity();\n void onPageSelected(int position);\n void onPageScrollStateChanged(int state);\n}", "public interface WorkersMvpView extends MvpView {\n void updateDataList();\n\n void showDataError(boolean show);\n\n void showProgress(boolean show);\n\n void showToast(String text);\n\n void navigateToWorkerInfoActivity(Worker worker);\n}", "public interface MainActivityConstrct {\n interface ViewActivity{\n\n }\n\n interface PresenterActivity{\n\n }\n}", "public interface IModuleContextTabletActivity extends IModuleContext {\n}", "protected Activity getActivity() {\n\t\treturn (Activity) getHost().getModel();\n\t}", "interface IDiscussionPostView {\n\n void startDiscussionPostActivity();\n void displayErrorToast();\n void showProgressDialog();\n void hideProgressDialog();\n\n}", "public interface IGaActivity {\n\n /**\n * Get the screen name of the activity\n * @return the name of the screen to be reported to GA for a screen view event\n * @throws UnsetScreenException if screen view is not set by overriding this method\n */\n String getScreenName() throws UnsetScreenException;\n\n /**\n * Get the TrackerManager. This should only be used if you need to send\n * explicitly defined custom GA events within your activity/fragment\n * @return TrackerManager - GA Manager object\n */\n TrackerManager getGaTracker();\n\n /**\n * Set a custom dimension for user events\n * @param customDimension1 first custom dimension\n */\n void setCustomDimension1(String customDimension1);\n\n /**\n * Set a custom dimension for user events\n * @param customDimension2 second custom dimension\n */\n void setCustomDimension2(String customDimension2);\n}", "public interface BroadCastManagerCallerInterface {\n /**\n * **\n * This method is called when an intent Has Been ReceivedT hrough The BroadCast\n * @param intent This is the intent that was received\n */\n void intentHasBeenReceivedThroughTheBroadCast(Intent intent);\n}", "public interface IFragmentView {\n public Activity getActivity();\n public void onItemClick(int position);\n}", "public interface ILoginView {\n /**\n * goto Net Activity\n *\n * @param context\n */\n void gotoNetActivity(Context context);\n\n /**\n * goto Main activity\n *\n * @param context\n */\n void gotoMainActivity(Context context);\n\n /**\n * goto Regist activity\n *\n * @param context\n */\n void gotRegistActivity(Context context);\n\n /**\n * login failed,show msg\n */\n void showLoginError(Context context);\n\n /**\n * show progeress\n *\n * @param b\n */\n void showProgress(boolean b);\n\n\n}", "public interface LocationHandler {\n public void onAddLocationButtonClicked(Activity activity);\n\n public void onLocationMessageViewClicked(Activity activity, AVIMLocationMessage locationMessage);\n}", "public interface SecondActivityComponent {\n}", "public interface IMainView extends BaseView {\n\n void inflateBottomViewParent();\n\n void moveToHomeWorkActivity();\n\n void moveToAttendanceActivity();\n\n void moveToMoreFragment();\n\n void logout();\n\n\n}", "public interface IBaseActivityListEvent {\n\n /**\n * Creates a new fragment with the listentries of the given ShoppingList item.\n *\n * @param _ShoppingList of the list that the content should be shown.\n */\n void selectList(ShoppingList _ShoppingList);\n}", "public interface ActivityWithDeepLinking {\n}", "@Override\r\n public void onAttach(Activity activity) {\n super.onAttach(activity);\r\n act = (BaseActivity) activity;\r\n\r\n }", "public interface IntentStarter {\n void startActivityForResult(ResultRequestor requestor, Intent intent);\n}", "public interface IPresenter {\n\n void onCreate();\n void onResume();\n void onPause();\n void onDestroy();\n}", "@Override\n public void needReloain(Activity activity) {\n }", "public interface ITodayModel {\n\n void getActivityData(ActivityDataResult result);\n}", "public interface AddTagActivityView {\n\n void viewUploadProgress(boolean state);\n\n void viewMessage(String msg);\n\n void updateTagsList(List<Tag> tagList);\n\n}", "public interface VuActivityMain extends Vu.ActivityVu {\n void showBtn(String st);\n\n void showBtn2(String st);\n}", "@Override\n\tpublic void onActivityCreated(Activity activity, Bundle savedInstanceState)\n\t{\n\t}", "public interface ComponetGraph {\n\n void inject(ManHuaApplication application);\n\n void inject(BaseActivity baseActivity);\n\n void inject(BaseFragment baseFragment);\n\n void inject(SettingActivity settingActivity);//设置\n\n void inject(BarrageSettingActivity barrageSettingActivity);//弹幕设置\n\n void inject(LookPhotoActivity lookPhotoActivity);//查看大图\n\n void inject(SplashActivity splashActivity);//启动页\n\n void inject(TestActivity testActivity);//启动页\n}", "public interface IMainView extends IBaseView{\n\n void onSuccess(List<Wallpaper> wallpapers);\n\n void onLoadMore(List<Wallpaper> wallpapers);\n\n void onCateChange(List<Wallpaper> wallpapers);\n\n void initBackground(List<Wallpaper> wallpapers);\n\n void onError(Throwable e);\n\n}", "public interface IHomePageActivityPresenterCallBack {\n void getRequestDataCallBack(List<Post> postList,int followerNum);\n void getCurUserPostListResult(List<Post> postList);\n void getCurUserImageResult(List<Post> postList);\n}", "protected abstract Activity getActivity(final T androidComponent);", "public interface IViewMainProfile {\n void onPreExecute();\n\n void onExecuteSuccess(SinhVien sinhVien);\n\n void onExecuteFailure(String fail);\n\n void onCancelExecuteSuccess(String success);\n\n void onCancelExecuteFailure(String fail);\n}", "public interface IBaseView {\n void toast(String msg);\n\n void toast(@StringRes int stringId);\n\n void showWaitDialog(String msg);\n\n void dismissWaitDialog();\n\n void activityFinish();\n\n void toActivity(Class className);\n\n void toActivity(Class className, String key, String value);\n\n void toActivity(Class className, String key, Serializable value);\n}", "public interface BaseView {\n void onError(String errCode);\n\n void checkPermission(String... permissions);\n\n void showProgressDialog();\n void dismissProgressDialog();\n\n void onAuthFailed();\n}", "public interface BaseView {\n void onNoNetworkAvailable();\n void onNetworkAvailable();\n void onShowProgress();\n void onHideProgress();\n\n//s\n\n}", "public interface BaseActivityCallback {\n enum Event {\n ACTIVITY_CLOSE\n }\n\n void onReceiveFragmentEvent(Event event);\n}", "Activity activity();" ]
[ "0.7401341", "0.7336463", "0.7200353", "0.719202", "0.71606004", "0.71566814", "0.71103644", "0.7086465", "0.7079492", "0.7060356", "0.69475925", "0.6942585", "0.6928236", "0.6886733", "0.6886345", "0.6875596", "0.68586355", "0.6852983", "0.6821943", "0.67767304", "0.677302", "0.67298186", "0.6719221", "0.6704602", "0.6680628", "0.6661032", "0.6657269", "0.66464126", "0.6642073", "0.6635754", "0.66355044", "0.6626969", "0.6625232", "0.661521", "0.6607415", "0.6595152", "0.658524", "0.6564245", "0.65543574", "0.65455025", "0.65323764", "0.653101", "0.6525231", "0.6521044", "0.6517682", "0.65157396", "0.6507251", "0.65047115", "0.6496987", "0.6493084", "0.6468347", "0.6462589", "0.64616436", "0.64528996", "0.6447048", "0.64430416", "0.6413049", "0.6405089", "0.6397823", "0.639337", "0.63861686", "0.6380913", "0.63792795", "0.63752574", "0.6372427", "0.63697827", "0.6353559", "0.6349148", "0.63417995", "0.6339274", "0.63377434", "0.6326886", "0.63201046", "0.6319133", "0.631721", "0.63154066", "0.630975", "0.6308007", "0.63042295", "0.6300264", "0.6295793", "0.6289099", "0.6285562", "0.62801576", "0.6278639", "0.627525", "0.62744015", "0.6274191", "0.62716675", "0.62651974", "0.62543166", "0.625361", "0.6244159", "0.62383574", "0.6233494", "0.6232228", "0.6224726", "0.6223577", "0.6219615", "0.62186575", "0.62164646" ]
0.0
-1
verify listener has implemented listener else, throws exceptions.
@Override public void onAttach(Context context) { super.onAttach(context); Log.d(TAG, "onAttach"); if(context instanceof SurveyVoteListener){ mVoteListener = (SurveyVoteListener) context; Log.d(TAG, "On attach survey vote listener set " + mVoteListener); } else { throw new RuntimeException(context.toString() + " must implement SurveyVoteListener"); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public interface Listener {}", "public interface Listener {\n}", "public interface Listener {\n}", "public interface IBaseListener {\n}", "public interface IBaseOnListener {\n\n void onFail(String msg);\n}", "public void verify(Object expListener)\n {\n assertEquals(\"Wrong number of invocations\", listenerTypeIndex,\n expectedListenerTypes.length);\n assertSame(\"Wrong listener\", expListener, listener);\n }", "public interface IEvenListener {\n}", "@Test\n\tpublic void testAddThenRemoveListener() throws SailException {\n\t\twrapper.addConnectionListener(listener);\n\t\tverify(delegate).addConnectionListener(listener);\n\t\twrapper.removeConnectionListener(listener);\n\t\tverify(delegate).removeConnectionListener(listener);\n\t}", "abstract public void addListener(Listener listener);", "Move listen(IListener ll);", "protected void registerListener() {\r\n\t\t// do nothing\r\n\t}", "protected Listener(){super();}", "@Test\n public void testIAEForAddListener() {\n try {\n final Registrar<Object> testSubject = onCreateTestSubject();\n testSubject.addListener(null);\n fail(\"IAE was not thrown\");\n } catch (IllegalArgumentException e) {\n // okay\n }\n }", "public interface ListenerSupport<T> {\n\n /**\n * register new listener\n */\n public void addListener(T listener);\n\n /**\n * removed already added listener\n */\n public void removeListener(T listener);\n\n}", "@Override\n\tpublic void getListener(){\n\t}", "protected static Listener testListenerClassValidity(Class<?> listenerClass) {\n Listener l = ReflectionUtil.getAnnotation(listenerClass, Listener.class);\n if (l == null)\n throw new IncorrectListenerException(String.format(\"Cache listener class %s must be annotated with org.infinispan.notifications.annotation.Listener\", listenerClass.getName()));\n return l;\n }", "public abstract void registerListeners();", "public interface OnEventAvailableListener {\n\tpublic void OnEventAvailable(Message msg);\n}", "public interface OnValidateResponseListener {\n\t\tOnValidateResponseListener STUB = new OnValidateResponseListener() {\n\t\t\t@Override\n\t\t\tpublic boolean isResponseExecuted(HttpUtils.HttpResult httpResult) {\n\t\t\t\treturn httpResult != null && httpResult.getCode() == HttpUtils.HttpResult.OK;\n\t\t\t}\n\t\t};\n\n\t\tboolean isResponseExecuted(HttpUtils.HttpResult httpResult);\n\t}", "public interface BaseReturnListener {\n void tokenFail();\n}", "public static interface Listener {\r\n\r\n void onCommitted(Transaction transaction);\r\n\r\n void onAborted(Transaction transaction);\r\n }", "public interface OnAuthListener\n{\n\n public abstract void onAuthFail(int i, String s);\n\n public abstract void onAuthPassed(String s, WeiboToken weibotoken);\n\n public abstract void onWeiBoNotInstalled();\n\n public abstract void onWeiboVersionMisMatch();\n}", "@Test\n public void testLogErrorListener()\n {\n assertEquals(\"No default error listener registered\", 1,\n new DefaultConfigurationBuilder().getErrorListeners().size());\n }", "void setListener(Listener listener);", "@Override\n\tpublic void setListener() {\n\n\t}", "@Override\r\n\tpublic void setListener() {\n\r\n\t}", "@Override\r\n\tpublic void setListener() {\n\r\n\t}", "public interface IListenerPresenter {\n void loadListen(Context context, boolean isFirst, String type, String page);\n\n void loadListen(Context context, boolean isFirst, String page);\n}", "public interface FireSignListener {\n\n\t\t/** Se ejecuta cuando se obtiene el resultado de la petici&oacute;n de firma a FIRe.\n\t\t * @param result Resultado de la operaci&oacute;n de firma. {@code true} si todas las\n\t\t * se firmaron correctamente, {@code false} si se produjeron errores. */\n\t\tvoid fireSignSuccess(boolean result);\n\n\t\t/** Se ejecuta cuando ocurre un error durante la petici&oacute;n de firma a FIRe.\n\t\t * @param cause Motivo del error. */\n\t\tvoid fireSignFailed(Throwable cause);\n\t}", "public boolean isListenerAvailable() {\n return mListener != null;\n }", "public boolean isListenerAvailable() {\n return mListener != null;\n }", "public interface UserIsFinanceRegisterListener extends OnBaseRequestListener{\n void onSuccess();\n}", "static void notifyListener0(Future future, GenericFutureListener l)\r\n/* 604: */ {\r\n/* 605: */ try\r\n/* 606: */ {\r\n/* 607:679 */ l.operationComplete(future);\r\n/* 608: */ }\r\n/* 609: */ catch (Throwable t)\r\n/* 610: */ {\r\n/* 611:681 */ if (logger.isWarnEnabled()) {\r\n/* 612:682 */ logger.warn(\"An exception was thrown by \" + l.getClass().getName() + \".operationComplete()\", t);\r\n/* 613: */ }\r\n/* 614: */ }\r\n/* 615: */ }", "public interface ServiceCallListener extends ServiceInstanceCallListener, RemoteServiceCallListener {\r\n\r\n}", "private void setListener() {\n\t}", "public interface GetPointsListener extends Listener {\n\n public void onGetPointsSucc(PointsInfo info);\n}", "private void checkGameListenerMethodsArguments(@Nullable Game game, @Nullable ValueEventListener listener) {\n if (game == null) {\n throw new IllegalArgumentException(\"game should not be null.\");\n }\n if (listener == null) {\n throw new IllegalArgumentException(\"event listener should not be null.\");\n }\n }", "private void assertStreamItemViewHasOnClickListener() {\n assertFalse(\"listener should have not been invoked yet\", mListener.clicked);\n mView.performClick();\n assertTrue(\"listener should have been invoked\", mListener.clicked);\n }", "@Test\r\n\tpublic void testAddListener() {\r\n\t\t// workspace listener\n\t\tMockWorkspaceListener listener = new MockWorkspaceListener();\r\n\t\tworkspace.addListener(listener);\r\n\t\tworkspace.addSubModule(eBuffer);\r\n\t\tcontent.addDefaultNode(node1);\r\n\r\n\t\tworkspace.receiveLocalAssociation(content);\r\n\r\n\t\tassertEquals(ModuleName.EpisodicBuffer, listener.originatingBuffer);\r\n\t\tassertTrue(listener.content.containsNode(node1));\r\n\r\n\t\t// cue listener\n\t\tMockCueListener cueListener = new MockCueListener();\r\n\t\tworkspace.addListener(cueListener);\r\n\t\tcontent.addDefaultNode(node2);\r\n\r\n\t\tworkspace.cueEpisodicMemories(content);\r\n\r\n\t\tNodeStructure ns = cueListener.ns;\r\n\t\tassertNotNull(ns);\r\n\t\tassertTrue(ns.containsNode(node1));\r\n\t\tassertTrue(ns.containsNode(node2));\r\n\t}", "public void doRequiredCheck() {\n\t\tthis.checkValue(listener);\n\t}", "public interface IFailureDetectionEventListener {\r\n\t/**\r\n\t * Convict the specified endpoint.\r\n\t * \r\n\t * @param ep\r\n\t * endpoint to be convicted\r\n\t */\r\n\tpublic void convict(InetAddress ep);\r\n\r\n}", "public interface Listener {\n void onCredentialUpdateRequired();\n\n void onOneDriveRefreshTokenUpdated(String str);\n }", "public void maybeAdd(Object listener) {\n if (type.isInstance(listener)) {\n add(type.cast(listener));\n }\n }", "public abstract boolean casListeners(AbstractFuture<?> abstractFuture, Listener listener, Listener listener2);", "@Test\n public void testListenerIsNotified () {\n DelayedPrompter.Listener mockListener = mock(DelayedPrompter.Listener.class);\n Message mockMessage = mock(Message.class);\n Bundle mockBundle = mock(Bundle.class);\n when(mockMessage.getData()).thenReturn(mockBundle);\n when(mockBundle.getInt(DelayedPrompter.NUM_OF_ROWS_IN_LIST)).thenReturn(13);\n\n DelayedPrompter promptHandler = new DelayedPrompter(mockListener);\n\n promptHandler.handleMessage(mockMessage);\n\n verify(mockListener).listUpdated(13);\n }", "@Override\r\n public void addValidListener(ValidListener l) {\n\r\n }", "public interface CommandManagerListener extends Listener, ICommandManagerListener {\n}", "public interface OnBaseUIListener {\n}", "protected abstract void startListener();", "@Override\n\tprotected void setListener() {\n\n\t}", "@Override\n\tprotected void setListener() {\n\n\t}", "public interface Listener {\n void onConnected(CallAppAbilityConnection callAppAbilityConnection);\n\n void onDisconnected(CallAppAbilityConnection callAppAbilityConnection);\n\n void onReleased(CallAppAbilityConnection callAppAbilityConnection);\n }", "public interface SelectEventFragmentEventsListener {\n void eventIdConfirmed(String eventId) throws IncompleteDataException;\n}", "public interface ValidationResponseListener {\n\n void isValid();\n}", "protected AbstractListenerProvider()\r\n\t{\r\n\t}", "protected boolean hasListeners()\n {\n // m_listenerSupport defaults to null, and it is reset to null when\n // the last listener unregisters\n return m_listenerSupport != null;\n }", "protected boolean hasListeners()\n {\n // m_listenerSupport defaults to null, and it is reset to null when\n // the last listener unregisters\n return m_listenerSupport != null;\n }", "public interface makemodelimpl {\n\n interface BaseListener<T>{\n void getSuccess(T t);\n void getFailure();\n }\n\n}", "public interface FPStatusListener {\n void fpAuthSuccess();\n\n /**\n * If there is any problem in authenticate using fingerprint scanner.\n * it'll be called\n * Like if you exceed more number of attempts.\n * @param error error message from the fingerprint auth.\n */\n void fpAuthFailed(@Nullable String error);\n}", "public interface EventListener {\n\n /**\n * Called when an event (function call) finishes successfully in MockRestRequest. Does *not* trigger if the event\n * (function) fails.\n * @param mockRestRequest the {@link MockRestRequest} where the event occurred.\n * @param event the {@link Event} that occurred.\n */\n public void onEventComplete(MockRestRequest mockRestRequest, Event event);\n }", "public interface IEventListener {\n\n /**\n * Handles an event\n * @param e event\n * @return true if the event should be consumed and not propagated, otherwise false\n */\n boolean onEvent(Event e);\n}", "public void testCustomEventListener() throws Exception\n {\n checkEventTypeRegistration(CUSTOM_EVENT_BUILDER, \"\");\n }", "public static void addListener(MetadataListListener listener) {\n if (DEBUG.Enabled) Log.debug(\"listeners no longer allowed, will not report to: \" + Util.tags(listener));\n // listeners.add(listener);\n }", "@Test public void shouldDoSomething() {\n manager.initialize();\n\n // validate that addListener was called\n verify(database).addListener(any(ArticleListener.class));\n }", "public interface ErrorListener {\n void unexpectedType(String description);\n\n interface DeletionTaskErrorListener {\n void deletingNonExistingTask();\n }\n\n interface DeletionActionErrorListener {\n void deletingUnavailableAction();\n }\n\n interface DeletionInputErrorListener {\n void deletingUnavailableInput();\n }\n\n interface AdditionErrorListener {\n void addingTaskWithUnavailableInput(String inputName);\n }\n}", "public void testWovenClassListenerExceptionDoesNotCauseClassLoadToFail() throws Exception {\n\t\tfinal AtomicInteger integer = new AtomicInteger(0);\n\t\tServiceRegistration<WovenClassListener> reg = getContext().registerService(\n\t\t\t\tWovenClassListener.class, \n\t\t\t\tnew WovenClassListener() {\n\t\t\t\t\tpublic void modified(WovenClass wovenClass) {\n\t\t\t\t\t\tinteger.set(1);\n\t\t\t\t\t\tthrow new RuntimeException();\n\t\t\t\t\t}\n\t\t\t\t}, \n\t\t\t\tnull);\n\t\ttry {\n\t\t\tregisterAll();\n\t\t\ttry {\n\t\t\t\tClass<?> clazz = weavingClasses.loadClass(TEST_CLASS_NAME);\n\t\t\t\tassertEquals(\"Listener not called\", 1, integer.get());\n\t\t\t\tassertDefinedClass(listenerWovenClass, clazz);\n\t\t\t\tassertStates(WovenClass.TRANSFORMED, WovenClass.DEFINED);\n\t\t\t}\n\t\t\tfinally {\n\t\t\t\tunregisterAll();\n\t\t\t}\n\t\t}\n\t\tfinally {\n\t\t\treg.unregister();\n\t\t}\n\t}", "public interface LoginFragmentListener {\n }", "private DefaultListener() {\n }", "public interface InvalidInputListener extends EventListener {\n /**\n * Fired when the status is updated.\n *\n * @param invalid if true we have some invalid input fields in the UI.\n */\n void statusUpdate(boolean invalid);\n}", "protected void installListeners() {\n }", "protected void installListeners() {\n }", "public abstract void addServiceListener(PhiDiscoverListener listener);", "public interface AuthenticationServiceListener {\n void onUserLoginFailed(Exception exception);\n void onRegistrationFailed(Exception exception);\n}", "public void addListener(EventListener listener);", "void registerListeners();", "ListenerMethod getListenerMethod();", "@Override\r\n\tprotected void listeners() {\n\t\t\r\n\t}", "@Override\n\t\t\t\tpublic void onAddFail() {\n\t\t\t\t\tif (addListener != null) {\n\t\t\t\t\t\taddListener.onAddFail();\n\t\t\t\t\t}\n\t\t\t\t}", "public interface OnSignUpFinishedListener {\n void userNameError();\n void passwordError();\n void mailError();\n void exitoOperacion(String preferencia, String sesion);\n}", "@Test\n public void testAddEventListener() {\n List<SimulatorEventListener> eventListeners = eventDispatcher.getSimulatorEventListeners();\n assertTrue(eventListeners.size() == 0);\n SimulatorEventListener listener = new SimulatorEventListener() {\n\n\n public void onNewMessage(Exchange exchange, Conversation conversation) {\n\n }\n\n public void onMatchingScenario(Exchange exchange, Conversation conversation) {\n\n }\n\n public void onResponseBuilt(Exchange exchange, Conversation conversation) {\n\n }\n\n public void onResponseSent(Exchange exchange, Conversation conversation) {\n\n }\n };\n eventDispatcher.addSimulatorEventListener(listener);\n assertTrue(eventListeners.size() == 1);\n }", "public interface OnLoginListener {\n public void success(Bean bean);\n public void failed();\n}", "public interface a\n{\n\n public abstract void addEventListener(String s, VPAIDEventListener vpaideventlistener);\n\n public abstract void dispatchEvent(VPAIDEvent vpaidevent);\n\n public abstract boolean hasEventListener(String s, VPAIDEventListener vpaideventlistener);\n\n public abstract void removeEventListener(String s, VPAIDEventListener vpaideventlistener);\n}", "public IllegalConnectionCheck() {\n listener = new LinkedHashSet<CheckListener>();\n active = true;\n }", "public interface HomeResponseListener\n extends ResponseListener\n{\n\n public abstract void completed(ServiceCall servicecall);\n\n public abstract void receivedCartItems(CartItems cartitems, ServiceCall servicecall);\n\n public abstract void receivedCompletedRemembersItemIds(List list, ServiceCall servicecall);\n\n public abstract void receivedLoginData(LoginData logindata, ServiceCall servicecall);\n\n public abstract void receivedNotification(Notification notification, ServiceCall servicecall);\n\n public abstract void receivedPromoSlot0(PromoSlot promoslot, ServiceCall servicecall);\n\n public abstract void receivedPromoSlot1(PromoSlot promoslot, ServiceCall servicecall);\n\n public abstract void receivedShoveler0(HomeShoveler homeshoveler, ServiceCall servicecall);\n\n public abstract void receivedShoveler1(HomeShoveler homeshoveler, ServiceCall servicecall);\n}", "public interface GamePanelListener {}", "@Override\n\tpublic void addGameEventListener(GameEventListener listener) throws RemoteException {\n\t\t\n\t}", "private Listener() {\r\n // unused\r\n }", "public interface TransactionListener {\n enum Error {\n INSUFFICIENT_FUNDS,\n INVALID_DEST,\n NETWORK_ERROR\n }\n\n void onFailed(Error error, TransactionType type);\n\n void onPending(Transaction transaction);\n\n void onValidated(Transaction transaction);\n}", "public interface IntroListener {\n /**\n * User is done with description fragment.\n */\n void descriptionComplete();\n\n /**\n * User has completed signing-in on sign-in fragment.\n */\n void signInComplete();\n\n /**\n * User has completed adding their device.\n * @param hasOtherDevices True if the user has devices registered other than this one.\n */\n void addDeviceComplete(boolean hasOtherDevices);\n}", "public boolean hasListeners() {\n return !listeners.isEmpty();\n }", "public boolean hasListeners() {\n return !listeners.isEmpty();\n }", "protected void installListeners() {\n\n\t}", "public interface OnLoginListener {\n void onSuccess();\n void onError();\n}", "public interface OnServiceConnectionListener {\n}", "public interface OnImpresionConfirmadaListener {\n\tpublic void onImpresionConfirmada();\n}", "public interface SendMessageListener {\n abstract void onSendOK(Message msg);\n\n abstract void onSendFailed(Message msg, String reason);\n}", "public interface NoStartReviewListener\n{\n public void onOkNoStars();\n}", "public interface OnLoginListener {\n void loginSuccess(User user);\n\n void loginFail(int code, String msg);\n}", "private void addEventListener(IEventListener<T> listener) {\n\t\t\tevent.addEventListener(listener);\n\t\t}", "public interface ConnectionListenerManager extends Serializable\n{\n /**\n * Add a connection listener.\n * \n * @param connectionListener [in] Supplies a reference to the new\n * listener.\n * \n * @throws ServerException if a listener with the same ID already exists.\n */\n public void add(ConnectionListener connectionListener) throws ServerException;\n \n /**\n * Remove a connection listener.\n * \n * @param listenerID [in] Supplies the unique ID of the connection\n * listener to be removed.\n * \n * @return A reference to the removed listener, or null if it didn't\n * exist.\n */\n public ConnectionListener remove(String listenerID);\n \n /**\n * Check to see if the manager is empty.\n * \n * @return True if the manager does not contain any listeners, false if it\n * contains at least one.\n */\n public boolean isEmpty();\n \n /**\n * Check to see if the listeners are active.\n * \n * @return True if the listeners are active, false if not.\n */\n public boolean isRunning();\n\n /**\n * Get a list of all connection listeners.\n * \n * @return A list of listeners.\n */\n public List<String> listeners();\n \n /**\n * Get a reference to a connection listener.\n * \n * @param listenerID [in] Supplies the unique ID of the listener.\n * \n * @return A reference to the listener, null if it does not exist.\n */\n public ConnectionListener getListener(String listenerID);\n \n /**\n * Start all listeners. One or more listener may fail to start due to an\n * IOException. If all listeners fail to start, this method throws a\n * ServerException. If one or more listeners failed to start, but at\n * least one started successfully, this method will return normally, but\n * with a return value of false, so that the caller knows that one or\n * more listener failed to start, and can check the individual listeners\n * to see which failed, and why. The way this would be done would be to\n * iterate over this object's collection of listeners, checking to see which\n * listeners failed to start. When a non-started listener is encountered,\n * the caller would then attempt to start that listener individually, and\n * then handle the resulting IOException individually. Finally, if all\n * listeners start successfully, this method returns true.\n *\n * @return True if all listeners were started successfully, or false if\n * one or more (but not all!) failed to start properly.\n *\n * @throws ServerException if no listeners were started successfully.\n */\n public boolean startAll() throws ServerException;\n \n /**\n * Stop all listeners.\n */\n public void stopAll();\n}", "public interface Listener {\n /**\n * Called when the user has performed a double tap and then held down\n * the second tap.\n *\n * @param event The most recent MotionEvent received.\n * @param policyFlags The policy flags of the most recent event.\n */\n void onDoubleTapAndHold(MotionEvent event, int policyFlags);\n\n /**\n * Called when the user lifts their finger on the second tap of a double\n * tap.\n *\n * @param event The most recent MotionEvent received.\n * @param policyFlags The policy flags of the most recent event.\n *\n * @return true if the event is consumed, else false\n */\n boolean onDoubleTap(MotionEvent event, int policyFlags);\n\n /**\n * Called when the system has decided the event stream is a gesture.\n *\n * @return true if the event is consumed, else false\n */\n boolean onGestureStarted();\n\n /**\n * Called when an event stream is recognized as a gesture.\n *\n * @param gestureId ID of the gesture that was recognized.\n *\n * @return true if the event is consumed, else false\n */\n boolean onGestureCompleted(int gestureId);\n\n /**\n * Called when the system has decided an event stream doesn't match any\n * known gesture.\n *\n * @param event The most recent MotionEvent received.\n * @param policyFlags The policy flags of the most recent event.\n *\n * @return true if the event is consumed, else false\n */\n public boolean onGestureCancelled(MotionEvent event, int policyFlags);\n }" ]
[ "0.69271874", "0.671769", "0.671769", "0.65481347", "0.6525226", "0.6499814", "0.63416374", "0.6291448", "0.6265235", "0.62433445", "0.61579126", "0.614679", "0.61387765", "0.6096553", "0.6073696", "0.60526574", "0.5982286", "0.59529144", "0.5918375", "0.58836263", "0.5862302", "0.5861224", "0.58514273", "0.5850075", "0.58428115", "0.58418924", "0.58418924", "0.583603", "0.58285135", "0.58256835", "0.58256835", "0.5821105", "0.581713", "0.5811479", "0.5790825", "0.5775603", "0.57749677", "0.57747996", "0.57569075", "0.57554966", "0.5750365", "0.57285035", "0.57237095", "0.57235515", "0.57218117", "0.57172555", "0.5711468", "0.57089365", "0.5702212", "0.56726664", "0.56726664", "0.56712127", "0.5670585", "0.5657867", "0.5656808", "0.5654155", "0.5654155", "0.5646111", "0.564094", "0.5636109", "0.5630795", "0.5613349", "0.5612242", "0.56116074", "0.56112486", "0.560259", "0.56006044", "0.5592188", "0.55893415", "0.558448", "0.558448", "0.55797535", "0.5569669", "0.5561299", "0.5557638", "0.55496955", "0.55465287", "0.5545167", "0.5541146", "0.5538368", "0.55380434", "0.55368793", "0.5528407", "0.5525386", "0.55127233", "0.55056155", "0.5501664", "0.54894257", "0.5483392", "0.5479272", "0.5479272", "0.5478014", "0.54724705", "0.546699", "0.5461373", "0.5460642", "0.54604816", "0.5457529", "0.54550344", "0.54537183", "0.54529643" ]
0.0
-1
hosting activity has to implement .editListener method in order to edit survey question
@Override public void onClick(View view) { mVoteListener.editListener("newQuestion", "newOptionOne", "newOptionTwo"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract void editQuestion();", "void onEditClicked();", "@Override\n public void edit(Question q) {\n delete(q);\n add(q);\n }", "public void marksEdit(View view) {\n Intent intent = new Intent(getApplicationContext(), InsertingAtten.class);\n intent.putExtra(\"STATUS\", \"edit\");\n intent.putExtra(\"SEMESTER\", semester);\n intent.putExtra(\"SECTION\", section);\n intent.putExtra(\"COURSEID\", courseId);\n intent.putExtra(\"DEPARTMENT\", department);\n intent.putExtra(\"SERIES\", series);\n startActivity(intent);\n }", "public void onClick(View view) {\n Log.d(\"Edit1\",\"EDITED1\");\n\n }", "private View.OnClickListener HandleEdit() {\n return v -> {\n //Change the application state to edit mode\n mMainActivityState.ChangeActivityMode(Mode.EDIT);\n //Close the current dialog\n mCurrentDialog.dismiss();\n };\n }", "void onEditItem(E itemElementView);", "private void edit() {\n\n\t}", "public void onClick(View view) {\n Log.d(\"Edit\",\"EDITED\");\n }", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tif(edit_add.getText().toString().length()>0){\n\t\t\t\t\taddQuestion(UrlUtils.USERQUESTIONADD, edit_add.getText().toString());\n\t\t\t\t}\n\t\t\t}", "public interface Listener{\n void onQuestionClicked(Question question);\n }", "private void editableEditTexts() {\n\t\tEditText etTitle = (EditText) findViewById(R.id.etRecipeTitle);\n\t\tEditText etDescription = (EditText) findViewById(R.id.etRecipeDescription);\n\t\tEditText etDirections = (EditText) findViewById(R.id.etDirectionsList);\n\n\t\tetTitle.setKeyListener(titleListener);\n\t\tetDescription.setKeyListener(descriptionListener);\n\t\tetDirections.setKeyListener(directionsListener);\n\n\t\tsetListViewOnClickListener();\n\n\t}", "@Override\n public void editDescription() {\n final String[] desc = new String[1];\n desc[0] = null;\n\n\n AlertDialog.Builder builder = new AlertDialog.Builder(Overview.this);\n //inflate the layout\n View mView = getLayoutInflater().inflate(R.layout.description_dialog, null);\n\n final EditText description = (EditText) mView.findViewById(R.id.write);\n Button save = (Button) mView.findViewById(R.id.save);\n Button cancel = (Button) mView.findViewById(R.id.cancel);\n\n\n builder.setView(mView);\n final AlertDialog dialog = builder.create();\n dialog.show();\n\n cancel.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n // desc = description.getText().toString();\n Toast.makeText(Overview.this, \"Description Canceled\", Toast.LENGTH_SHORT).show();\n\n dialog.dismiss();\n }\n });\n\n save.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n if (!description.getText().toString().isEmpty()) {\n // desc = description.getText().toString();\n Toast.makeText(Overview.this, \"Saved Description\", Toast.LENGTH_SHORT).show();\n ai_frag.setReturnedDescription(description.getText().toString());\n\n } else {\n Toast.makeText(Overview.this, \"No Description changed\", Toast.LENGTH_SHORT).show();\n }\n dialog.dismiss();\n\n }\n });\n\n\n }", "public void onPressEdit() {\r\n Intent intent = new Intent(this, CreateEventActivity.class);\r\n intent.putExtra(CreateEventActivity.EXTRA_EDIT_EVENT_UID, event.uid);\r\n startActivity(intent);\r\n }", "public interface QuestionListener {\n void putQuestion();\n}", "@Override\r\n\tpublic void edit() {\n\t\t\r\n\t}", "public void onEditItem(View view) {\n Intent data = new Intent(EditItemActivity.this, MainActivity.class);\n data.putExtra(\"position\", elementId);\n data.putExtra(\"text\", etText.getText().toString());\n setResult(RESULT_OK, data);\n finish();\n }", "private void updateQuestion(){\n\t\tint question = mQuestionBank[mCurrentIndex].getQuestion();\n\t\tmQuestionTextView.setText(question);\n\t}", "private void updateQuestion(){\n int question = mQuestionBank[mCurrentIndex].getmQuestion();\n mQuestionTextView.setText(question);\n }", "public void onEditParticipant() {\n Participant participant = outputParticipants.getSelectionModel().getSelectedItem();\n\n if (participant == null) {\n AlertHelper.showError(LanguageKey.ERROR_PARTICIPANT_NULL, null);\n return;\n }\n\n ParticipantDialog participantDialog = ParticipantDialog.getNewInstance(participant);\n if (participantDialog == null) {\n // Exception already handled\n return;\n }\n Optional<Participant> result = participantDialog.showAndWait();\n if (!result.isPresent()) {\n return;\n }\n\n if (controller.editParticipant(result.get())) {\n return;\n }\n\n AlertHelper.showError(LanguageKey.ERROR_PARTICIPANT_EDIT, null);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n final Bundle savedInstanceState) {\n View rootView7 = inflater.inflate(R.layout.fragment_question_edit_text, container, false);\n\n //setRetainInstance(true);\n\n // FINDING THE TEXT VIEW TO DISPLAY THE ASSIGNED QUESTION\n questionTextView7 = (TextView) rootView7.findViewById(R.id.question_text_view_7);\n questionTextView7.setText(getString(R.string.question_7_string));\n\n // USING PREFERENCE MANAGER TO WRITE TO THE FILE\n final SharedPreferences my_preferences = PreferenceManager.getDefaultSharedPreferences(getActivity());\n\n // CREATING AN EDITOR TO USE FOR STORING VALUES\n final SharedPreferences.Editor editorEditText = my_preferences.edit();\n\n // TO GET THE USER EDIT TEXT ANSWER AND TO STORE THE VALUE\n answerInput = (EditText) rootView7.findViewById(R.id.answer_edit_text);\n answerInput.setFilters(new InputFilter[] {new InputFilter.AllCaps()});\n answerInput.setOnEditorActionListener(new TextView.OnEditorActionListener() {\n @Override\n public boolean onEditorAction(TextView v, int actionId, KeyEvent event) {\n if (actionId == EditorInfo.IME_ACTION_DONE){\n correctAnswer = getString(R.string.frag7_answer);\n if (answerInput.getText().toString().equals(correctAnswer)) {\n editorEditText.putInt(\"text_answer_value\", 1);\n }\n editorEditText.apply();\n\n //QuestionEditText.this.startActivity(toScoreActivity);\n }\n return false;\n }\n });\n\n submitScore = (Button) rootView7.findViewById(R.id.submit_score_button);\n submitScore.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n Intent toScoreActivity = new Intent(getActivity(), ScoreActivity.class);\n startActivity(toScoreActivity);\n }\n });\n\n return rootView7;\n\n }", "@Override\n\t\t\tpublic void onClick(View arg0) {\n\t\t\t\tquestionTxt = (EditText)findViewById(R.id.question);\n\t\t\t finish();\n\t\t\t}", "@Override\n\t\t\t\t\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\t\t\t\t\teditRecipe(recipeString);\n\t\t\t\t\t\t\t\t\t\tsavedDialog();\n\t\t\t\t\t\t\t\t\t}", "public void onClick(View v) {\n\t\t\t\tIntent i = new Intent(InputView.this,QuestionView.class);\n\t\t\t\ti.putExtra(Constants.EXTRA_INPUT_STRING, mInputEditText.getText().toString());\n\t\t\t\ti.putExtra(Constants.EXTRA_INPUT_TYPE, State.getDestinationType(mInputEditText.getText().toString()));\n\t\t\t\tstartActivity(i);\n\t\t\t}", "private void showThatEditable() {\n\t\tTextView tv = new TextView(this);\n\t\ttv.setText(\"You may now edit this recipe!\");\n\t\tAlertDialog.Builder alert = new AlertDialog.Builder(this);\n\t\talert.setTitle(\"Edit Mode\");\n\t\talert.setView(tv);\n\t\talert.setNegativeButton(\"OK\", new DialogInterface.OnClickListener() {\n\t\t\tpublic void onClick(DialogInterface dialog, int whichButton) {\n\t\t\t}\n\t\t});\n\t\talert.show();\n\t}", "@Override\n public void onClick(View v) {\n getActivityDetails(view);\n\n String editDialogDistance = null;\n String editDialogAlt = null;\n String editDialogAvgHR = null;\n String editDialogMaxHR = null;\n\n long editDialogId = Long.parseLong(editId.getText().toString());\n String editDialogTime = editTime.getText().toString();\n String editDialogTotalTime = editTotalTime.getText().toString();\n String editDialogInfo = editInfo.getText().toString();\n String editDialogSport = editSport.getText().toString();\n try {\n editDialogDistance = editDistance.getText().toString();\n editDialogAlt = editAltitude.getText().toString();\n editDialogAvgHR = editAvgHR.getText().toString();\n editDialogMaxHR = editMaxHR.getText().toString();\n } catch (NullPointerException e) {\n\n }\n\n showEditDialog(editDialogId, editDialogTime, editDialogTotalTime, editDialogDistance,\n editDialogInfo, editDialogSport, editDialogAlt, editDialogAvgHR, editDialogMaxHR, _day, _month, _year);\n }", "@Override\n public void onClick(View v) {\n getActivityDetails(view);\n\n String editDialogDistance = null;\n String editDialogAlt = null;\n String editDialogAvgHR = null;\n String editDialogMaxHR = null;\n\n long editDialogId = Long.parseLong(editId.getText().toString());\n String editDialogTime = editTime.getText().toString();\n String editDialogTotalTime = editTotalTime.getText().toString();\n String editDialogInfo = editInfo.getText().toString();\n String editDialogSport = editSport.getText().toString();\n try {\n editDialogDistance = editDistance.getText().toString();\n editDialogAlt = editAltitude.getText().toString();\n editDialogAvgHR = editAvgHR.getText().toString();\n editDialogMaxHR = editMaxHR.getText().toString();\n } catch (NullPointerException e) {\n\n }\n\n showEditDialog(editDialogId, editDialogTime, editDialogTotalTime, editDialogDistance,\n editDialogInfo, editDialogSport, editDialogAlt, editDialogAvgHR, editDialogMaxHR, _day, _month, _year);\n }", "void onEditFragmentInteraction(Student student);", "public void afterClickedEdit(View view) {\n GlobalUtils.showOpdtionDialog(this, new OptionDialogCallback() {\n @Override\n public void onActionHistory() {\n Intent intent = new Intent(MainActivity.this, HistoryActivity.class);\n startActivity(intent);\n }\n\n @Override\n public void onActionChangeTime() {\n if (GlobalUtils.TARGET_TREATMENT_TIME.equals(\"0\")) {\n GlobalUtils.showInfoDialog(MainActivity.this, \"Error\", \"You have not entered your total treatment time yet\", \"OK\", new SCDialogCallback() {\n @Override\n public void onAction1() {\n\n }\n\n @Override\n public void onAction2() {\n\n }\n\n @Override\n public void onAction3() {\n\n }\n\n @Override\n public void onAction4() {\n\n }\n });\n } else {\n aftererClickTarget();\n }\n }\n\n @Override\n public void onActionClear() {\n //show confirmation dialog\n GlobalUtils.showConfirmDialog(MainActivity.this, \"Confirmation\", \"Are you sure you want to clear all data?\", \"Yes\", \"No\", new SCDialogCallback() {\n @Override\n public void onAction1() {\n db.deleteSchedule(GlobalUtils.getCurrentDate().getFormattedDate());\n mListScheduleData.clear();\n GlobalUtils.calculated_schedule = new Schedule();\n initScheduleList();\n reset_Views();\n GlobalUtils.no_counting = true;\n GlobalUtils.TARGET_TREATMENT_TIME = \"0\";\n }\n\n @Override\n public void onAction2() {\n\n }\n\n @Override\n public void onAction3() {\n\n }\n\n @Override\n public void onAction4() {\n\n }\n });\n }\n\n @Override\n public void onActionSave() {\n\n }\n\n @Override\n public void onActionCancel() {\n\n }\n\n @Override\n public void onActionHelp() {\n Intent intent = new Intent(MainActivity.this,HelpActivity.class);\n startActivity(intent);\n }\n });\n\n\n }", "@Override\n\tpublic void onQaQuestion(QaQuestion arg0, int arg1) {\n\t\t\n\t}", "public interface Editable {\n\n void createValidationPatterns();\n void setUpButtonListeners();\n}", "public abstract void edit();", "public interface EdittextListener {\n void onQuery(String s);\n\n void onClear();\n\n void onContentChange(String s);\n}", "public void contactEdit() {\n Intent editIntent = new Intent(viewContacts.this, editContact.class); //start the intent to go back to edit contact\n editIntent.putExtra(\"MyID\", edit_intent);\n\n startActivity(editIntent); //start the activity\n\n\n\n }", "public void setQuestion(){\n\n\n triggerReport(); //Check if max questions are displayed, if yes then show report\n\n MyDatabase db = new MyDatabase(QuizCorner.this);\n Cursor words = db.getQuizQuestion();\n TextView question_text = (TextView) findViewById(R.id.question_text);\n RadioButton rb;\n resetOptions();\n disableCheck();\n enableRadioButtons();\n hideAnswer();\n words.moveToFirst();\n word = words.getString(words.getColumnIndex(\"word\"));\n correct_answer = words.getString(words.getColumnIndex(\"meaning\"));\n question_text.setText(word + \" means:\");\n for (int i = 0; i < 4; i++){\n answers[i] = words.getString(words.getColumnIndex(\"meaning\"));\n words.moveToNext();\n }\n answers = randomizeArray(answers);\n for (int i = 0; i < 4; i++){\n rb = (RadioButton) findViewById(options[i]);\n rb.setText(answers[i]);\n }\n question_displayed_count++;\n }", "protected abstract void editItem();", "protected void editClicked(View view){\n FragmentManager fm = getSupportFragmentManager();\n ЕditDialog editDialogFragment = new ЕditDialog(2);\n Bundle args = new Bundle();\n args.putInt(\"position\", this.position);\n args.putString(\"itemName\", this.itm.getItem(this.position).getName());\n args.putString(\"itemUrl\", this.itm.getItem(this.position).getUrl());\n editDialogFragment.setArguments(args);\n editDialogFragment.show(fm, \"edit_item\");\n }", "private void editComic() {\n mainActivity.ISSUE_ID = comic.getComicID();\n\n //Load the edit fragment\n mainActivity.loadEditComicFragment();\n }", "public void onEdit(View view){\n\n Intent intent = new Intent(this,ACT_Edit_Course.class);\n intent.putExtra(\"refID\",selectedCategory);\n startActivity(intent);\n\n }", "public void setOkToEditQuestion(String string) {\r\n\t\t_okToEditQuestion = string;\r\n\t}", "@Override\r\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tmListener.onAddPress(editContent.getEditableText().toString());\r\n\t\t\t\tdialog.dismiss();\r\n\t\t\t}", "public void onEditAgendaItem() {\n AgendaItem agendaItem = outputAgendaItemsPreparation.getSelectionModel().getSelectedItem();\n\n if (agendaItem == null) {\n AlertHelper.showError(LanguageKey.ERROR_AGENDAITEM_NULL, null);\n return;\n }\n\n AgendaItemDialog agendaItemDialog = AgendaItemDialog.getNewInstance(agendaItem);\n if (agendaItemDialog == null) {\n // Exception already handled\n return;\n }\n Optional<AgendaItem> result = agendaItemDialog.showAndWait();\n if (!result.isPresent()) {\n return;\n }\n\n if (controller.editAgendaItem(result.get())) {\n return;\n }\n\n AlertHelper.showError(LanguageKey.ERROR_AGENDAITEM_EDIT, null);\n }", "@Override\n\tpublic void edit(HttpServletRequest request,HttpServletResponse response) {\n\t\tint id=Integer.parseInt(request.getParameter(\"id\"));\n\t\tQuestionVo qv=new QuestionVo().getInstance(id);\n\t\tcd.edit(qv);\n\t\ttry{\n\t\t\tresponse.sendRedirect(\"Admin/question.jsp\");\n\t\t\t}\n\t\t\tcatch(Exception e){}\n\t}", "private void updateQuestion(){\n mchoice1.setChecked(false);\n mchoice2.setChecked(false);\n mchoice3.setChecked(false);\n mchoice4.setChecked(false);\n\n if (mQuestonNumber < mQuizLibrary.getLength()){\n //menset setiap textview dan radiobutton untuk diubah jadi pertanyaan\n sQuestion.setText(mQuizLibrary.getQuestion(mQuestonNumber));\n //mengatur opsi sesuai pada optional A\n mchoice1.setText(mQuizLibrary.getChoice(mQuestonNumber, 1)); //Pilihan Ganda ke 1\n //mengatur opsi sesuai pada optional B\n mchoice2.setText(mQuizLibrary.getChoice(mQuestonNumber, 2)); //Pilihan Ganda ke 2\n //mengatur opsi sesuai pada optional C\n mchoice3.setText(mQuizLibrary.getChoice(mQuestonNumber, 3)); //Pilihan Ganda ke 3\n //mengatur opsi sesuai pada optional D\n mchoice4.setText(mQuizLibrary.getChoice(mQuestonNumber, 4)); //Pilihan Ganda ke 4\n\n manswer = mQuizLibrary.getCorrect(mQuestonNumber);\n //untuk mengkoreksi jawaban yang ada di class QuizBank sesuai nomor urut\n mQuestonNumber++; //update pertanyaan\n }else{\n Toast.makeText(Quiz.this, \"ini pertanyaan terakhir\", Toast.LENGTH_LONG).show();\n Intent i = new Intent (Quiz.this, HighestScore.class);\n i.putExtra(\"score\", mScore); //UNTUK MENGIRIM NILAI KE activity melalui intent\n startActivity(i);\n }\n }", "public void addQuestion(View view) {\n startActivity(new Intent(MainActivity.this, DicebreakerQuestions.class));\n\n }", "public void setQuestions(){\r\n question.setTestname(test.getText().toString());\r\n question.setQuestion(ques.getText().toString());\r\n question.setOption1(opt1.getText().toString());\r\n question.setOption2(opt2.getText().toString());\r\n question.setOption3(opt3.getText().toString());\r\n int num = Integer.parseInt(correct.getText().toString());\r\n question.setAnswerNumber(num);\r\n long check = db.addToDb(question);\r\n if(check == -1){\r\n Toast.makeText(getBaseContext(), \"Question already exists\", Toast.LENGTH_LONG).show();\r\n }else{\r\n Toast.makeText(getBaseContext(), \"Question added\", Toast.LENGTH_LONG).show();\r\n }\r\n }", "void onEditTaskComplete(String name, String notes, int position);", "@Override\n public void onClick(DialogInterface dialogInterface, int i) {\n try {\n HelpCenter.sendQuestion(\"\", URLEncoder.encode(questionEdit.getText().toString(), \"utf-8\"));\n } catch(Exception e){\n\n }\n }", "public void setEditButtonPresentListener(EditButtonPresentListener listener);", "public void editProfile(View v) {\n //Create map of all old info\n final Map tutorInfo = getTutorInfo();\n\n InputMethodManager imm = (InputMethodManager) this.getSystemService(Service.INPUT_METHOD_SERVICE);\n\n //Create animations\n final Animation animTranslate = AnimationUtils.loadAnimation(this, R.anim.translate);\n final Animation revTranslate = AnimationUtils.loadAnimation(this, R.anim.reverse_translate);\n\n //Enable Bio EditText, change color\n EditText bioField = (EditText) findViewById(R.id.BioField);\n bioField.clearFocus();\n bioField.setTextIsSelectable(true);\n bioField.setEnabled(true);\n bioField.setBackgroundResource(android.R.color.black);\n imm.showSoftInput(bioField, 0);\n\n //Hide edit button\n v.startAnimation(animTranslate);\n v.setVisibility(View.GONE);\n\n //Show add subject button\n Button addSubjButton = (Button) findViewById(R.id.addSubjButton);\n addSubjButton.setVisibility(View.VISIBLE);\n\n\n //Show save button\n Button saveButton = (Button) findViewById(R.id.save_button);\n saveButton.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n saveDialogue(tutorInfo);\n }\n });\n saveButton.startAnimation(revTranslate);\n saveButton.setVisibility(View.VISIBLE);\n\n enableSkillButtons();\n }", "@Override\n public void onClick(View v) {\n if (TextUtils.isEmpty(editText.getText().toString())){\n Toast.makeText(getContext(), \"Enter note!\", Toast.LENGTH_SHORT).show();\n return;\n } else {\n alertDialog.dismiss();\n }\n\n // check if user updating note\n\n if (shouldUpdate && note != null){\n // update note by it's id\n note.setNote(editText.getText().toString());\n updateNote(note, position);\n } else {\n // create new note\n //createNote(editText.getText().toString());\n }\n }", "public void survey()\n {\n }", "public void editAss() throws IOException {\r\n\t\tif (listview.getSelectionModel().getSelectedItem() != null) {\r\n\t\t\tassToChoose = listview.getSelectionModel().getSelectedItem();\r\n\t\t\tfor (int i = 0; i < b.size(); i++) {\r\n\t\t\t\tif (b.get(i).getAssname().equals(assToChoose)) {\r\n\t\t\t\t\tassId = b.get(i).getAssId();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tconnectionmain.showTeacherEditAssGUI();\r\n\t\t}\r\n\t}", "@Override\n\tpublic void onClick(View arg0) {\n\t\tswitch (arg0.getId()) {\n\t\tcase R.id.sureeditoptbtn:\n\t\t\tswitch (opt) {\n\t\t\tcase 0:\n //添加问题\n\t\t\t\tAlertDialog.Builder builder = new Builder(getActivity());\n\t\t\t\tbuilder.setTitle(\"请选择问题的类型\");\n\t\t\t\tbuilder.setIcon(R.drawable.icon_hint);\n\t\t\t\tbuilder.setSingleChoiceItems(items, 0,\n\t\t\t\t\t\tnew DialogInterface.OnClickListener() {\n\n\t\t\t\t\t\t\t@Override\n\t\t\t\t\t\t\tpublic void onClick(DialogInterface arg0, int arg1) {\n\t\t\t\t\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\t\t\t\t\tquestionType = arg1 + 1;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t});\n\t\t\t\tbuilder.setPositiveButton(\"确定\",\n\t\t\t\t\t\tnew DialogInterface.OnClickListener() {\n\n\t\t\t\t\t\t\t@Override\n\t\t\t\t\t\t\tpublic void onClick(DialogInterface arg0, int arg1) {\n\t\t\t\t\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\t\t\t\t\t// 第num题处添加一题\n\t\t\t\t\t\t\t\tQuestion question = new Question();\n\t\t\t\t\t\t\t\tquestion.setNum(num);\n\t\t\t\t\t\t\t\tquestion.setType(questionType);\n\t\t\t\t\t\t\t\tquestionList.add(num - 1, question);\n\t\t\t\t\t\t\t\tfor (int i = num; i < questionList.size(); i++) {\n\t\t\t\t\t\t\t\t\tquestionList.get(i).setNum(i + 1);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tquestionAapter.notifyDataSetChanged();\n\t\t\t\t\t\t\t\tnumList.add(String.valueOf(questionList.size() + 1));\n\t\t\t\t\t\t\t\tnumAdapter.notifyDataSetChanged();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\tbuilder.setNegativeButton(\"取消\",\n\t\t\t\t\t\tnew DialogInterface.OnClickListener() {\n\n\t\t\t\t\t\t\t@Override\n\t\t\t\t\t\t\tpublic void onClick(DialogInterface arg0, int arg1) {\n\t\t\t\t\t\t\t\t// TODO Auto-generated method stub\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\tbuilder.create().show();\n\n\t\t\t\tbreak;\n\n\t\t\tcase 1:\n\t\t\t\tquestionList.remove(num - 1);\n\t\t\t\tfor (int i = num - 1; i < questionList.size(); i++) {\n\t\t\t\t\tquestionList.get(i).setNum(i + 1);\n\t\t\t\t}\n\t\t\t\tquestionAapter.notifyDataSetChanged();\n\t\t\t\tnumList.removeLast();\n\t\t\t\tnumAdapter.notifyDataSetChanged();\n\t\t\t\tToast.makeText(getActivity(), \"第\" + num + \"题被成功删除\",\n\t\t\t\t\t\tToast.LENGTH_SHORT).show();\n\t\t\t\tbreak;\n\t\t\tcase 2:\n\t\t\t\tLinkedList<Answer> answerList = questionList.get(num - 1)\n\t\t\t\t\t\t.getAnswerList();\n\t\t\t\tif (answerList == null) {\n\t\t\t\t\tanswerList = new LinkedList<Answer>();\n\t\t\t\t}\n\t\t\t\t\tanswerList.add(new Answer(answerList.size(), num - 1, \"\"));\n\t\t\t\t\tquestionList.get(num - 1).setAnswerList(answerList);\n\t\t\t\t\n\t\t\t\tquestionAapter.notifyDataSetChanged();\n\t\t\t\tbreak;\n\t\t\tcase 3:\n\t\t\t\tquestionList.get(num - 1).getAnswerList().removeLast();\n\t\t\t\tquestionAapter.notifyDataSetChanged();\n\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tbreak;\n\n\t\tdefault:\n\t\t\tbreak;\n\t\t}\n\t}", "private View.OnClickListener createUpdateButtonListener() {\n return new View.OnClickListener() {\n @Override public void onClick(View v) {\n String newValue = eddystoneEditView.getText().toString();\n updateEddystone(newValue);\n }\n };\n }", "@Override\n public void onClick(View view) {\n Intent intent = new Intent(getApplicationContext(), EditAssessment.class);\n intent.putExtra(\"termID\", termID);\n intent.putExtra(\"courseID\", courseID);\n intent.putExtra(\"assessmentID\", assessmentID);\n startActivity(intent);\n }", "private void setQuestion(int resID){\n questionView.setText(resID);\n ecaFragment.sendToECAToSpeak(getResources().getString(resID));\n }", "private void helperAcceptButtonListener() {\n refresh();\n editDialog.dispose();\n }", "private void editElement(int position) {\n Intent intent = new Intent(this, NewNoteActivity.class);\n Task t = this.printedTasks.get(position);\n intent.putExtra(\"id\", t.getUid());\n intent.putExtra(\"intitule\", t.getIntitule());\n intent.putExtra(\"description\", t.getDescription());\n intent.putExtra(\"duree\", t.getDuree());\n intent.putExtra(\"date\", t.getDate());\n intent.putExtra(\"color\", t.getColor());\n intent.putExtra(\"url\", t.getUrl());\n intent.putExtra(\"position\", position);\n\n // Send boolean -> edit mode\n intent.putExtra(\"edit\", true);\n startActivityForResult(intent, SECOND_ACTIVITY_REQUEST);\n\n reloadWidget();\n }", "public void editTitle(View view) {\n Intent intent = new Intent(this, EditActivity.class);\n intent.putExtra(\"text\", title);\n startActivityForResult(intent, EDIT_TITLE);//CTRL+ALT+C per canviar de 0 a una variable\n }", "public interface SurveyVoteListener {\n void voteListener(int yes, int no);\n void editListener(String newQuestion, String newOptionOne, String newOptionTwo);\n }", "@Override\n public void updateView(Intent intent)\n {\n \n }", "@Override\r\n\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tcheckAnswer(2);\r\n\t\t\t\t\t currentQ=quesListSci.get(qidSci);\r\n\t\t\t\t\t if(qidSci==46){\r\n\t\t\t\t \t QuizActivitySci.this.showDialog(RUN_OUT);\r\n\t\t\t\t \t \r\n\t\t\t\t }\r\n\t\t\t\t\t if(qMon%2==0 & qMon%3==0){\r\n\t\t\t\t\t\t QuizActivitySci.this\r\n\t\t\t\t\t\t .showDialog(SCORE_DIALOG);\r\n\t\t\t\t\t\t qlvl++;\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t }else{\r\n\t\t\t\t\t\t setQuestionView();\r\n\t\t\t\t\t\t \r\n\t\t\t\t\t }\r\n\t\t\t\t\t \r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}", "@Override\r\n\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\tcheckAnswer(4);\r\n\t\t\t\t\t \tcurrentQ=quesListSci.get(qidSci);\r\n\t\t\t\t\t \tif(qidSci==46){\r\n\t\t\t\t\t \t QuizActivitySci.this.showDialog(RUN_OUT);\r\n\t\t\t\t\t \t \r\n\t\t\t\t\t }\r\n\t\t\t\t\t \t if(qMon%2==0 & qMon%3==0){\r\n\t\t\t\t\t\t\t QuizActivitySci.this\r\n\t\t\t\t\t\t\t .showDialog(SCORE_DIALOG);\r\n\t\t\t\t\t\t\t qlvl++;\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t }else{\r\n\t\t\t\t\t\t\t setQuestionView();\r\n\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t }\r\n\t\t\t\t\t\t \r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}", "@Override\n public void onCreate(Bundle savedInstanceState) {\n\tsuper.onCreate(savedInstanceState);\n\tsetContentView(R.layout.edit_course_screen);\n\n\tgetWindow().setSoftInputMode(\n\t\tWindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_HIDDEN);\n\tinitComponents();\n\n\tButton editButton = (Button) findViewById(R.id.edit_course_button);\n\teditButton.setOnClickListener(new OnClickListener() {\n\t public void onClick(View view) {\n\t\tdatabaseHelper = new DataHelper(EditCourseTeacherScreen.this);\n\t\tint id = extras.getInt(\"id\");\n\t\tString signature = extras.getString(\"signature\").trim();\n\t\tString name = nameEntry.getText().toString().trim();\n\t\tString type = extras.getString(\"type\").trim();\n\t\tString alarm = extras.getString(\"alarm\");\n\n\t\tdatabaseHelper.updateCourseOrTeacher(id, signature,\n\t\t\tname.toString(), pickedColor, type, alarm);\n\t\tdatabaseHelper.close();\n\t\tstartActivity(new Intent(EditCourseTeacherScreen.this,\n\t\t\tMain.class));\n\t\tfinish();\n\t }\n\t});\n\n\tButton cancelButton = (Button) findViewById(R.id.cancel_editing_course_button);\n\tcancelButton.setOnClickListener(new OnClickListener() {\n\t public void onClick(View arg0) {\n\t\tfinish();\n\t }\n\t});\n }", "@Override\n\tpublic boolean onEditorAction(TextView v, int actionId, KeyEvent event) {\n\t\tIEditProductDialogListener activity = (IEditProductDialogListener)getActivity();\n\t\tactivity.onFinishEditDescription(editDiscription.getText().toString());\n\t\tthis.dismiss();\n return true;\n\n\t}", "@Override\r\n\t\t\t\tpublic void onClick(View v) {\n\t \t checkAnswer(1);\r\n\t\t\t \r\n\t\t\t\t \tcurrentQ=quesListSci.get(qidSci);\r\n\t\t\t\t \tif(qidSci==46){\r\n\t\t\t\t \t QuizActivitySci.this.showDialog(RUN_OUT);\r\n\t\t\t\t \t \r\n\t\t\t\t }\r\n\t\t\t\t\t if(qMon%2==0 & qMon%3==0){\r\n\t\t\t\t\t\t QuizActivitySci.this\r\n\t\t\t\t\t\t .showDialog(SCORE_DIALOG);\r\n\t\t\t\t\t\t qlvl++;\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t }else{\r\n\t\t\t\t\t\t setQuestionView();\r\n\t\t\t\t\t\t \r\n\t\t\t\t\t }\r\n\t\t\t\t\t \r\n\t\t\t\t\t \r\n\t\t\t\t\t \r\n\t\t\t\t\t\r\n\t\t\t\t}", "public abstract void acceptEditing();", "@Override\n public void onClick(View v) {\n enableEditMode();\n }", "@Override\r\n\t\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\tcheckAnswer(3);\r\n\t\t\t\t\t \tcurrentQ=quesListSci.get(qidSci);\r\n\t\t\t\t\t \tif(qidSci==46){\r\n\t\t\t\t\t \t QuizActivitySci.this.showDialog(RUN_OUT);\r\n\t\t\t\t\t \t \r\n\t\t\t\t\t }\r\n\t\t\t\t\t \t if(qMon%2==0 & qMon%3==0){\r\n\t\t\t\t\t\t\t QuizActivitySci.this\r\n\t\t\t\t\t\t\t .showDialog(SCORE_DIALOG);\r\n\t\t\t\t\t\t\t qlvl++;\r\n\t\t\t\t\t\t }else{\r\n\t\t\t\t\t\t\t setQuestionView();\r\n\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t }\r\n\t\t\t\t\t\t \r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}", "@Override\n public void onClick(View v) {\n String question = newQuestion.getText().toString();\n String opt1 = option1.getText().toString();\n String opt2 = option2.getText().toString();\n\n // Checks that all fields are filled before continuing.\n if (question.equals(\"\") || opt1.equals(\"\") || opt2.equals(\"\")) {\n // Displays Toast if at least one field is empty.\n Toast.makeText(SurveyActivity.this, \"Please fill in all fields before submitting\", Toast.LENGTH_SHORT).show();\n } else {\n // Creates new Intent to return to MainActivity.\n Intent surveyIntent = new Intent();\n // Adds string values to Extra.\n surveyIntent.putExtra(EXTRA_FROM_SURVEY_QUESTION, question);\n surveyIntent.putExtra(EXTRA_FROM_SURVEY_OPT1, opt1);\n surveyIntent.putExtra(EXTRA_FROM_SURVEY_OPT2, opt2);\n setResult(RESULT_OK, surveyIntent);\n finish();\n }\n }", "private void editAlarm(Alarm affectedAlarm) {\n \t\t//TODO: Launch AddAlarmActivity with this alarm as base so the user can edit it.\n \t}", "public void clickEdit(View view) {\n if(editTime == true){\n bEdit.setText(\"Edit\");\n editTime = false;\n timePicker.setEnabled(false);\n if(switch1.isChecked())\n scheduleAlarm();\n }\n else {\n editTime = true;\n timePicker.setEnabled(true);\n bEdit.setText(\"Save\");\n hour = timePicker.getCurrentHour(); //get hour\n minute = timePicker.getCurrentMinute(); //get minutes\n }\n }", "public void modifyQuestion(String text) {\n // TODO implement here\n }", "@Override\n public void handleEditStart ()\n {\n\n }", "private void editar(){\n String codigo = getIntent().getStringExtra(\"codigo\");\n Intent otra = new Intent(this, MainActivity.class);\n otra.putExtra(\"codigo\", codigo);\n otra.putExtra(\"nombre\", nombre.getText().toString());\n otra.putExtra(\"raza\", raza.getText().toString());\n otra.putExtra(\"clase\", clase.getText().toString());\n otra.putExtra(\"nv\", nv.getText().toString());\n otra.putExtra(\"exp\", exp.getText().toString());\n otra.putExtra(\"pg\", String.valueOf(pgValue));\n otra.putExtra(\"pgMax\", String.valueOf(pgMaxValue));\n otra.putExtra(\"ca\", ca.getText().toString());\n otra.putExtra(\"vel\", vel.getText().toString());\n\n String[] statsValue = new String[stats.length];\n for(int i = 0; i < statsValue.length; i++){\n statsValue[i] = stats[i].getText().toString();\n }\n otra.putExtra(\"stats\", statsValue);\n\n otra.putExtra(\"salvBonus\", String.valueOf(salvBonus));\n\n otra.putExtra(\"statsSalv\", salvacionCb);\n\n otra.putExtra(\"habBonus\", String.valueOf(habBonus));\n\n otra.putExtra(\"habilidadesCb\", habilidadesCb);\n\n startActivity(otra);\n }", "@FXML\n\tpublic void editClicked(ActionEvent e) {\n\t\tMain.getInstance().navigateToDialog(\n\t\t\t\tConstants.EditableCourseDataViewPath, course);\n\t}", "public void clickedSpeakerEdit() {\n\t\tif(mainWindow.getSelectedRowSpeaker().length <= 0) ApplicationOutput.printLog(\"YOU DID NOT SELECT ANY PRESENTATION\");\n\t\telse if(mainWindow.getSelectedRowSpeaker().length > 1) ApplicationOutput.printLog(\"Please select only one presentation to edit\");\n\t\telse {\n\t\t\tshowSpeakeerDetails(mainWindow.getSelectedRowSpeaker()[0]);\n\t\t}\t\n\t}", "public void updateQ4scoreAndGoToNext(View view){\r\n EditText q1Correct;\r\n q1Correct = (EditText) findViewById(R.id.q1Answer);\r\n String inputText = q1Correct.getText().toString();\r\n String rightAnswer = \"TextView\";\r\n\r\n if (inputText.equals(rightAnswer)) {\r\n q1Score = q1Score + 1;\r\n Toast toast = Toast.makeText(this, \"Great Job! 1 point added.\", Toast.LENGTH_SHORT);\r\n toast.show();\r\n } else {\r\n q1Score = 0;\r\n Toast toast = Toast.makeText(this, \"Better luck next time, 0 points added.\", Toast.LENGTH_SHORT);\r\n toast.show();\r\n }\r\n\r\n Intent i = new Intent(this, Question2Activity.class);\r\n startActivity(i);\r\n }", "@Override\n public void onClick(View v) {\n String note = edit_note.getText().toString().trim();\n noteDialog.dismiss();\n setNote(note);\n }", "private void editOtherDetails() {\n addLanguageTv.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n showEditTextDialogue(\"language\");\n }\n });\n\n // Edit Skills click listener\n addSkillsTv.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n showEditTextDialogue(\"skills\");\n }\n });\n\n // Edit Links click Listener\n\n addLinksTv.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n showEditTextDialogue(\"links\");\n }\n });\n\n //Edit Description\n addDescTv.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n descriptionTv.setVisibility(View.GONE);\n descriptionET.setVisibility(View.VISIBLE);\n descriptionET.setText(description);\n }\n });\n\n saveBtnCv.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(final View v) {\n final String value = descriptionET.getText().toString().trim();\n progressDialog.setTitle(\"Saving Information...\");\n progressDialog.show();\n HashMap<String, Object> result = new HashMap<>();\n result.put(\"description\", value);\n\n dbReference.child(user.getUid()).updateChildren(result)\n .addOnSuccessListener(new OnSuccessListener<Void>() {\n @SuppressLint(\"RestrictedApi\")\n @Override\n public void onSuccess(Void aVoid) {\n\n descriptionTv.setText(value);\n descriptionET.setVisibility(View.GONE);\n descriptionTv.setVisibility(View.VISIBLE);\n\n editProfFab.setVisibility(View.VISIBLE);\n savBtnRL.setVisibility(View.GONE);\n addLanguageTv.setVisibility(View.GONE);\n addSkillsTv.setVisibility(View.GONE);\n addLinksTv.setVisibility(View.GONE);\n addDescTv.setVisibility(View.GONE);\n\n progressDialog.dismiss();\n Toast.makeText(UserProfile.this, \"Saved Successfully..\", Toast.LENGTH_SHORT).show();\n }\n })\n .addOnFailureListener(new OnFailureListener() {\n @Override\n public void onFailure(@NonNull Exception e) {\n progressDialog.dismiss();\n Toast.makeText(UserProfile.this, e.getMessage(), Toast.LENGTH_SHORT).show();\n }\n });\n\n }\n });\n }", "void acceptQueAnswersClicked();", "@Override\n public void onEdit(int position, String old_content) {\n FragmentTransaction ft = getFragmentManager().beginTransaction();\n EditVoteFragment fr = EditVoteFragment.newInstance(position, old_content);\n fr.show(ft, \"dialog\");\n }", "void onExamAnswerClick(int index);", "void onStartEditTask(String taskId) {\n mNavigationProvider.startActivityForResultWithExtra(AddEditTaskActivity.class,\n TaskDetailActivity.REQUEST_EDIT_TASK, AddEditTaskFragment.ARGUMENT_EDIT_TASK_ID,\n taskId);\n }", "private void updateQuestion() {\n\n if (attempts < 10) { //To ensure only 10 questions are shown.\n Question.setText(quizQuestions.getQuestion(questionNumber));\n Answer1.setText(quizQuestions.getChoice1(questionNumber));\n Answer2.setText(quizQuestions.getChoice2(questionNumber));\n Answer3.setText(quizQuestions.getChoice3(questionNumber));\n Answer4.setText(quizQuestions.getChoice4(questionNumber));\n QuestionNo.setText(quizQuestions.getQuestionNo(questionNumber));\n }\n\n button.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View view) {\n// String s = quizQuestions.getHint(questionNumber - 1);\n showFlashcardDialog(QuizActivity.this, quizQuestions.getHint(questionNumber - 1), true);\n\n }\n });\n\n //Checks with QuizQuestions class to see if answer was correct\n correctAnswer = quizQuestions.getCorrectAnswer(questionNumber);\n\n //Finishes the quiz once 10 questions have been answered\n if (attempts == 10) {\n finish();\n updateScore(mScore);\n Intent results = new Intent(getApplicationContext(), QuizComplete.class); //Starts QuizComplete activity\n results.putExtra(TRANSFER_SCORE, mScore); //Transfers score to show at QuizComplete activity\n startActivity(results);\n\n } else {\n questionNumber++;\n }\n\n if (mScore > highScore) {\n updateHighScore(mScore);\n }\n }", "public interface EditCallbacks {\n\n public void onSaveItem(final Bundle data);\n public void onEditCanceled();\n public void onValidationError(String msg);\n}", "@Override\n public void onClick(View view) {\n Intent addEvent = new Intent(getApplicationContext(), EditActivity.class);\n startActivity(addEvent);\n }", "private void storeInLocal(){\n\t\t\t question = questionTxt.getText().toString();\n\t\t\t \n\t\t\t if (question.length() == 0) {\n\t\t\t\t\tif (TextUtils.isEmpty(question)) {\n\t\t\t\t\t\tquestionTxt.setError(getString(R.string.error_field_required));\n\t\t\t\t\t\tfocusView = questionTxt;\n\t\t\t\t\t\tcancel = true;\n\t\t\t\t\t}\n\t\t }\n\t\t\t else{\n\t\t\t ContentValues values = new ContentValues();\n\t\t values.put(QuestionsTable.QUESTION, question);\n\t\t\t values.put(QuestionsTable.NURSE_ID, NurseLogin.mUsername);\n\t\t\t \n\t\t todoUri = getContentResolver().insert(QuestionsContentProvider.CONTENT_URI, values);\n\t\t\t }\n\t\t }", "public static void editAlert() {\n\n }", "@Override\n public void onClick(View v) {\n Intent intent = PostEditActivity.newIntent(contex);\n intent.putExtra(\"PostKey\", postKey);\n contex.startActivity(intent);\n }", "private void updateHelpText(){\n\t\tif(propertiesObj == null)\n\t\t\treturn;\n\n\t\t((QuestionDef)propertiesObj).setHelpText(txtHelpText.getText());\n\t\tformChangeListener.onFormItemChanged(propertiesObj);\n\t}", "@Override\n\tpublic void onClick(View v) {\n\t\tint id = v.getId();\n\t\tswitch (id) {\n\t\tcase R.id.et1:\n\t\t\tedit(et1, 1);\n\t\t\tbreak;\n\t\tcase R.id.et2:\n\t\t\tedit(et2, 2);\n\t\t\tbreak;\n\t\tcase R.id.et3:\n\t\t\tedit(et3, 3);\n\t\t\tbreak;\n\t\tcase R.id.et4:\n\t\t\tedit(et4, 4);\n\t\t\tbreak;\n\t\tcase R.id.et5:\n\t\t\tedit(et5, 5);\n\t\t\tbreak;\n\t\tcase R.id.et6:\n\t\t\tedit(et6, 6);\n\t\t\tbreak;\n\t\tcase R.id.et7:\n\t\t\tedit(et7, 7);\n\t\t\tbreak;\n\t\tcase R.id.et8:\n\t\t\tedit(et8, 8);\n\t\t\tbreak;\n\t\tcase R.id.et9:\n\t\t\tedit(et9, 9);\n\t\t\tbreak;\n\t\tcase R.id.et10:\n\t\t\tedit(et10, 10);\n\t\t\tbreak;\n\t\tcase R.id.et11:\n\t\t\tedit(et11, 11);\n\t\t\tbreak;\n\t\tcase R.id.et12:\n\t\t\tedit(et12, 12);\n\t\t\tbreak;\n\t\tcase R.id.et13:\n\t\t\tedit(et13, 13);\n\t\t\tbreak;\n\t\tcase R.id.et14:\n\t\t\tedit(et14, 14);\n\t\t\tbreak;\n\t\t}\n\t}", "public void editHandler(View v) {\n LinearLayout vwParentRow = (LinearLayout)v.getParent();\n TextView id =(TextView) vwParentRow.findViewById(R.id._id);\n Intent intent = new Intent(Hates.this, Formulario.class);\n\n intent.putExtra(C_MODO, C_EDITAR);\n intent.putExtra(C_TIPO, love_hate);\n intent.putExtra(mDbHelper.ID, Long.valueOf((String)id.getText()));\n\n\n this.startActivityForResult(intent, C_EDITAR);\n }", "public void setQuestion(){\n String welcomeTextString = \"Welcome \" + getIntent().getStringExtra(\"name\") + \"!\";\n welcomeText.setText(welcomeTextString);\n\n //Setting Question title, description, and answers\n questionTitle.setText(questions[currentQuestion-1][0]);\n questionDescription.setText(questions[currentQuestion-1][1]);\n ans1.setText(questions[currentQuestion-1][2]);\n ans2.setText(questions[currentQuestion-1][3]);\n ans3.setText(questions[currentQuestion-1][4]);\n\n //Save correct answer\n correctAnswer = questions[currentQuestion-1][5];\n\n //Set progress bar and progress text\n progressBar.setProgress(currentQuestion);\n progressText.setText(currentQuestion.toString() + \"/5\");\n\n //Clear selection of buttons if any are already selected\n ans1.setBackgroundColor(getResources().getColor(R.color.ans_btn));\n ans2.setBackgroundColor(getResources().getColor(R.color.ans_btn));\n ans3.setBackgroundColor(getResources().getColor(R.color.ans_btn));\n }", "@OnClick(R.id.textView_edit_data)\n public void textView_edit_data_onClick(){\n CalendarDatePickerDialogFragment cdp = new CalendarDatePickerDialogFragment()\n .setOnDateSetListener(this);\n cdp.show(getSupportFragmentManager(), \"选择日期\");\n }", "@Override\n\tpublic void onClick(View v) {\n\t\tIntent intent;\n\t\tswitch (v.getId()) {\n\t\tcase R.id.btn_myresume_edit_back:\n\t\t\tfinish();\n\t\t\tbreak;\n\t\tcase R.id.layout_myresume_edit_project_experience:\n\t\t\tintent = new Intent(MyresumeEditActivity.this, ProjectExperienceListActivity.class);\n\t\t\tintent.putExtra(\"uid\", \"\"+uid);\n\t\t\tintent.putExtra(\"writeable\", \"\"+0);\n\t\t\tstartActivity(intent);\n\t\t\tbreak;\n\t\tcase R.id.tv_myresume_edit_save:\n\t\tcase R.id.btn_myresume_edit_save:\n\t\t\tcomStr = etMyresumeEditCompany.getText().toString();\n\t\t\tcontactStr = myresumeEditContact.getText().toString();\n\t\t\tmobileStr = myresumeEditMobile.getText().toString();\n\t\t\tqqStr = myresumeEditQQ.getText().toString();\n\t\t\temailStr = myresumeEditEmail.getText().toString();\n//\t\t\tjobStr = myresumeEditJob.getText().toString();\n//\t\t\texperienceStr = myresumeEditExperience.getText().toString();\n\t\t\taddressStr = myresumeEditAddress.getText().toString();\n\t\t\tidnumberStr = myresumeEditIdnumber.getText().toString();\n\t\t\tintroduceStr = myresumeEditIntroduce.getText().toString();\n\t\t\tif (resumeType == 2) {\n\t\t\t\tif (\"\".equals(comStr)) {\n\t\t\t\t\tToast.makeText(MyresumeEditActivity.this, \"请输入企业名称\",\n\t\t\t\t\t\t\tToast.LENGTH_LONG).show();\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (\"\".equals(contactStr)) {\n\t\t\t\tToast.makeText(MyresumeEditActivity.this, \"请输入联系人姓名\",\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\n\t\t\t\tbreak;\n\t\t\t} else if (\"\".equals(mobileStr)) {\n\t\t\t\tToast.makeText(MyresumeEditActivity.this, \"请输入手机号码\",\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\n\t\t\t\tbreak;\n\t\t\t} else if (\"\".equals(qqStr)) {\n\t\t\t\tToast.makeText(MyresumeEditActivity.this, \"请输入联系QQ\",\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\n\t\t\t\tbreak;\n\t\t\t} else if (\"\".equals(emailStr)) {\n\t\t\t\tToast.makeText(MyresumeEditActivity.this, \"请输入联系E-mail\",\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\n\t\t\t\tbreak;\n\t\t\t}\n//\t\t\telse if (\"\".equals(jobStr)) {\n//\t\t\t\tToast.makeText(MyresumeEditActivity.this, \"请输入职业状态\",\n//\t\t\t\t\t\tToast.LENGTH_LONG).show();\n//\t\t\t\tbreak;\n//\t\t\t}\n\t\t\telse if (\"\".equals(experienceStr)) {\n\t\t\t\tToast.makeText(MyresumeEditActivity.this, \"请输入行业经验\",\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\n\t\t\t\tbreak;\n\t\t\t} else if (\"\".equals(addressStr)) {\n\t\t\t\tToast.makeText(MyresumeEditActivity.this, \"请输入通讯地址\",\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\n\t\t\t\tbreak;\n\t\t\t} else if (\"\".equals(idnumberStr)) {\n\t\t\t\tToast.makeText(MyresumeEditActivity.this, \"请输入证件号码\",\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\n\t\t\t\tbreak;\n\t\t\t} else if (resumeType == 1 && idnumberStr.length() != 18) {\n\t\t\t\tToast.makeText(MyresumeEditActivity.this, \"身份证号位数不正确,请重新输入\",\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\n\t\t\t\tbreak;\n\t\t\t} else if (resumeType == 2 && idnumberStr.length() != 15) {\n\t\t\t\tToast.makeText(MyresumeEditActivity.this, \"营业执照号位数不正确,请重新输入\",\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\n\t\t\t\tbreak;\n\t\t\t} else if (\"\".equals(introduceStr)) {\n\t\t\t\tToast.makeText(MyresumeEditActivity.this, \"请输入自我介绍\",\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tpd = new ProgressDialog(MyresumeEditActivity.this);\n\t\t\tpd.setMessage(\"请稍后…\");\n\t\t\tpd.show();\n\t\t\tList<BasicNameValuePair> params = new ArrayList<BasicNameValuePair>();\n\t\t\t\n\t\t\tparams.add(new BasicNameValuePair(\"uid\", \"\"+uid));\n\t\t\tparams.add(new BasicNameValuePair(\"type\", \"\"+resumeType));\n\t\t\tparams.add(new BasicNameValuePair(\"comname\", comStr));\n\t\t\tparams.add(new BasicNameValuePair(\"linkname\", contactStr));\n\t\t\tparams.add(new BasicNameValuePair(\"mobile\", mobileStr));\n\t\t\tparams.add(new BasicNameValuePair(\"qq\", qqStr));\n\t\t\tparams.add(new BasicNameValuePair(\"email\", emailStr));\n\t\t\tparams.add(new BasicNameValuePair(\"status\", \"\"+status));\n\t\t\tparams.add(new BasicNameValuePair(\"workinglife\", experienceStr));\n\t\t\tparams.add(new BasicNameValuePair(\"address\", addressStr));\n\t\t\tparams.add(new BasicNameValuePair(\"idcardno\", idnumberStr));\n\t\t\tparams.add(new BasicNameValuePair(\"description\", introduceStr));\n\t\t\tparams.add(new BasicNameValuePair(\"goodin_item_num\", \"\"+(mArray.size() - 1)));\n\t\t\n\t\t\tfor(int i = 0; i < (mArray.size() - 1); i++){\n\t\t\t\tparams.add(new BasicNameValuePair(\"goodin_item\"+(i+1), \"\"+mArray.get(i).get(\"id\")));\n\t\t\t}\n\t\t\tnew Thread(new ConnectPHPToGetJSON(URL_ADDRESUME, handler, params))\n\t\t\t\t\t.start();\n\t\t\tbreak;\n\t\t}\n\t}", "public interface EditEntryView extends View{\n void onEditEntrySuccess();\n void onEditEntryFailure();\n void showError();\n}", "public void OnIngredients (View View)\n {\n \tIntent intent = new Intent(this, EditIngredients.class);\n \t\tstartActivity(intent);\n }", "@Override\n public boolean onContextItemSelected(MenuItem item) {\n if (item.getTitle() == \"Edit Activity\") {\n\n String editDialogDistance = null;\n String editDialogAlt = null;\n String editDialogAvgHR = null;\n String editDialogMaxHR = null;\n\n long editDialogId = Long.parseLong(editId.getText().toString());\n String editDialogTime = editTime.getText().toString();\n String editDialogTotalTime = editTotalTime.getText().toString();\n String editDialogInfo = editInfo.getText().toString();\n String editDialogSport = editSport.getText().toString();\n try {\n editDialogDistance = editDistance.getText().toString();\n editDialogAlt = editAltitude.getText().toString();\n editDialogAvgHR = editAvgHR.getText().toString();\n editDialogMaxHR = editMaxHR.getText().toString();\n } catch (NullPointerException e) {\n\n }\n\n showEditDialog(editDialogId, editDialogTime, editDialogTotalTime, editDialogDistance,\n editDialogInfo, editDialogSport, editDialogAlt, editDialogAvgHR, editDialogMaxHR, _day, _month, _year);\n } else if (item.getTitle() == \"Delete Activity\") {\n showDialog(DIALOG_DELETE);\n } else {\n return false;\n }\n return super.onContextItemSelected(item);\n }" ]
[ "0.7091634", "0.6804523", "0.6365691", "0.63410836", "0.61942273", "0.6188909", "0.6187675", "0.6185932", "0.6178929", "0.61771786", "0.61517495", "0.6133813", "0.6115472", "0.61110604", "0.61038435", "0.6089463", "0.60883963", "0.6016613", "0.60042834", "0.59974355", "0.59663576", "0.59512526", "0.59355986", "0.59313834", "0.59016305", "0.589956", "0.589956", "0.587691", "0.58485526", "0.5841128", "0.58364075", "0.58314127", "0.58274114", "0.5825141", "0.58126354", "0.58126134", "0.5806356", "0.5803085", "0.5801581", "0.5800037", "0.5787637", "0.5769818", "0.5757294", "0.57351416", "0.5729842", "0.57269806", "0.5724942", "0.5721586", "0.57201093", "0.57162255", "0.57130754", "0.57084626", "0.57071376", "0.5700359", "0.5695386", "0.56766325", "0.5671773", "0.56582505", "0.5654552", "0.56502205", "0.5640231", "0.56390065", "0.56387395", "0.5634011", "0.5603596", "0.5599915", "0.5598402", "0.5598207", "0.559662", "0.55942774", "0.55884254", "0.5582897", "0.558098", "0.55754894", "0.5571222", "0.5568564", "0.55646783", "0.5558869", "0.55547905", "0.554534", "0.5543364", "0.55413854", "0.5535303", "0.55211425", "0.55155313", "0.5514109", "0.5510687", "0.55072033", "0.5507121", "0.55036443", "0.5503237", "0.5502581", "0.5501654", "0.5500258", "0.54955083", "0.5483661", "0.5481942", "0.5479202", "0.5479094", "0.54673773" ]
0.6795162
2
method invoked from hosting activity to reset votes
public void resetVotes(int resetYes, int resetNo) { mYesCount = resetYes; mNoCount = resetNo; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setVotes(int votes) {\n this.votes = votes;\n }", "public static void doVote() {\n }", "private void postVote() {\n if ( unvotedParties() == 0 )\n TransactionManager.getTransactionManager().resolveTransaction(txId);\n }", "public void setNumVotes(int value) {\n this.numVotes = value;\n }", "public void setVotes(Set<Vote> arg0) {\n \n }", "public void upVote(Post p) {\n p.upvote();\n }", "@OnClick(R.id.upvote)\n public void onUpvoteClicked() {\n upvoted.setEnabled(false);\n downvoted.setEnabled(true);\n dataItem.setUpvoted();\n points++;\n upvoted.setBackgroundColor(Color.parseColor(\"#666bff\"));\n downvoted.setBackgroundColor(Color.parseColor(\"#ffffff\"));\n a.setText(points + \" points\");\n }", "public void downVote(Post p) {\n p.downvote();\n }", "public void removeKickVote()\n\t{\n\t\tnumberOfKickVotes--;\n\t}", "private void vote(Vote whichVoteButton, MenuItem item, PostData p) {\n if (!RedditLoginInformation.isLoggedIn()) {\n Toast.makeText(this, R.string.you_must_be_logged_in_to_vote, Toast.LENGTH_SHORT).show();\n return;\n }\n\n Intent intent = new Intent(Consts.BROADCAST_UPDATE_SCORE);\n intent.putExtra(Consts.EXTRA_PERMALINK, p.getPermalink());\n\n switch (whichVoteButton) {\n case DOWN:\n switch (p.getVote()) {\n case DOWN:\n RedditService.vote(this, p.getName(), Vote.NEUTRAL);\n item.setIcon(R.drawable.ic_action_downvote);\n p.setVote(Vote.NEUTRAL);\n p.setScore(p.getScore() + 1);\n break;\n\n case NEUTRAL:\n case UP:\n RedditService.vote(this, p.getName(), Vote.DOWN);\n item.setIcon(R.drawable.ic_action_downvote_highlighted);\n p.setVote(Vote.DOWN);\n mUpvoteMenuItem.setIcon(R.drawable.ic_action_upvote);\n p.setScore(p.getScore() - 1);\n break;\n }\n break;\n\n case UP:\n switch (p.getVote()) {\n case NEUTRAL:\n case DOWN:\n RedditService.vote(this, p.getName(), Vote.UP);\n item.setIcon(R.drawable.ic_action_upvote_highlighted);\n p.setVote(Vote.UP);\n p.setScore(p.getScore() + 1);\n mDownvoteMenuItem.setIcon(R.drawable.ic_action_downvote);\n break;\n\n case UP:\n RedditService.vote(this, p.getName(), Vote.NEUTRAL);\n item.setIcon(R.drawable.ic_action_upvote);\n p.setVote(Vote.NEUTRAL);\n p.setScore(p.getScore() - 1);\n break;\n }\n\n break;\n\n default:\n break;\n }\n\n // Broadcast the intent to update the score in the ImageDetailFragment\n intent.putExtra(Consts.EXTRA_SCORE, p.getScore());\n LocalBroadcastManager.getInstance(this).sendBroadcast(intent);\n }", "public DemographicVote()\n\t{\n\t\t//initialize the votes to zero\n\t\tliberal=0;\n\t\tndp=0;\n\t\tgreen=0;\n\t}", "public void countVotes() {\n int[] voteResponses = RaftResponses.getVotes(mConfig.getCurrentTerm());\n int numVotes = 0;\n if(voteResponses == null) {\n //System.out.println(mID + \" voteResponses null\");\n //System.out.println(\"cur \" + mConfig.getCurrentTerm() + \" RR: \" + RaftResponses.getTerm());\n }\n else {\n for(int i = 1; i <= mConfig.getNumServers(); i++) {\n //If vote has not been received yet, resend request\n //if(voteResponses[i] == -1)\n //this.remoteRequestVote(i, mConfig.getCurrentTerm(), mID, mLog.getLastIndex(), mLog.getLastTerm());\n if(voteResponses[i] == 0)\n numVotes++;\n }\n }\n //If election is won, change to leader\n if(numVotes >= (mConfig.getNumServers()/2.0)) {\n electionTimer.cancel();\n voteCountTimer.cancel();\n RaftServerImpl.setMode(new LeaderMode());\n }\n else {\n voteCountTimer = scheduleTimer((long) 5, 2);\n }\n }", "public void addVote() {\n this.votes++;\n }", "void votedOnPoll(String pollId);", "public synchronized void beginVoting() {\n\t\tvotingThread = new Thread(new Runnable() {\n\t\t\t@Override\n\t\t\tpublic void run() {\n\t\t\t\t// votes should be filled with [each delegate] -> `null`\n\t\t\t\tfor (int i = 0; i < 2 /* rounds */; i++) {\n\t\t\t\t\tfor (Delegate delegate : votes.keySet()) {\n\t\t\t\t\t\tif (votes.get(delegate) != null) {\n\t\t\t\t\t\t\t// Already voted.\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcurrentlyVoting = delegate;\n\t\t\t\t\t\tlblCurrentVoter.setText(delegate.getName());\n\t\t\t\t\t\tlblCurrentVoter.setIcon(delegate.getSmallIcon());\n\n\t\t\t\t\t\t@SuppressWarnings(\"unchecked\")\n\t\t\t\t\t\tfinal List<Map<Vote, JButton>> maplist = Arrays.asList(\n\t\t\t\t\t\t\t\tbuttons_roundOne, buttons_roundTwo);\n\t\t\t\t\t\tfor (Map<Vote, JButton> map : maplist) {\n\t\t\t\t\t\t\tfor (Vote vote : map.keySet()) {\n\t\t\t\t\t\t\t\tmap.get(vote)\n\t\t\t\t\t\t\t\t\t\t.setText(\n\t\t\t\t\t\t\t\t\t\t\t\tdelegate.getStatus().hasVetoPower ? vote.vetoText\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t: vote.normalText);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tsynchronized (votingThread) {\n\t\t\t\t\t\t\t\tvotingThread.wait();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} catch (InterruptedException e) {\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t\tfinal Vote cast = votes.get(delegate);\n\t\t\t\t\t\tif (cast == Vote.PASS) {\n\t\t\t\t\t\t\tvotes.put(delegate, null);\n\t\t\t\t\t\t\t// So he goes again.\n\t\t\t\t\t\t}\n\t\t\t\t\t\tfor (JButton button : votingButtons) {\n\t\t\t\t\t\t\tbutton.setEnabled(true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tlayout.show(pnlVoting, pnlSecondRound.getName());\n\t\t\t\t}\n\t\t\t\t// When done, disable again.\n\t\t\t\tfor (JButton button : votingButtons) {\n\t\t\t\t\tbutton.setEnabled(false);\n\t\t\t\t}\n\t\t\t\tcurrentlyVoting = null;\n\t\t\t\tlblCurrentVoter.setText(null);\n\t\t\t\tlblCurrentVoter.setIcon(null);\n\t\t\t\tpnlVoting.setVisible(false);\n\t\t\t}\n\t\t});\n\t\tvotingThread.start();\n\t}", "public void resetBidCount() {\r\n bidCount = 0;\r\n }", "@Override\n\t\t\tpublic void run() {\n\t\t\t\tfor (int i = 0; i < 2 /* rounds */; i++) {\n\t\t\t\t\tfor (Delegate delegate : votes.keySet()) {\n\t\t\t\t\t\tif (votes.get(delegate) != null) {\n\t\t\t\t\t\t\t// Already voted.\n\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcurrentlyVoting = delegate;\n\t\t\t\t\t\tlblCurrentVoter.setText(delegate.getName());\n\t\t\t\t\t\tlblCurrentVoter.setIcon(delegate.getSmallIcon());\n\n\t\t\t\t\t\t@SuppressWarnings(\"unchecked\")\n\t\t\t\t\t\tfinal List<Map<Vote, JButton>> maplist = Arrays.asList(\n\t\t\t\t\t\t\t\tbuttons_roundOne, buttons_roundTwo);\n\t\t\t\t\t\tfor (Map<Vote, JButton> map : maplist) {\n\t\t\t\t\t\t\tfor (Vote vote : map.keySet()) {\n\t\t\t\t\t\t\t\tmap.get(vote)\n\t\t\t\t\t\t\t\t\t\t.setText(\n\t\t\t\t\t\t\t\t\t\t\t\tdelegate.getStatus().hasVetoPower ? vote.vetoText\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t: vote.normalText);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tsynchronized (votingThread) {\n\t\t\t\t\t\t\t\tvotingThread.wait();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} catch (InterruptedException e) {\n\t\t\t\t\t\t\te.printStackTrace();\n\t\t\t\t\t\t}\n\t\t\t\t\t\tfinal Vote cast = votes.get(delegate);\n\t\t\t\t\t\tif (cast == Vote.PASS) {\n\t\t\t\t\t\t\tvotes.put(delegate, null);\n\t\t\t\t\t\t\t// So he goes again.\n\t\t\t\t\t\t}\n\t\t\t\t\t\tfor (JButton button : votingButtons) {\n\t\t\t\t\t\t\tbutton.setEnabled(true);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tlayout.show(pnlVoting, pnlSecondRound.getName());\n\t\t\t\t}\n\t\t\t\t// When done, disable again.\n\t\t\t\tfor (JButton button : votingButtons) {\n\t\t\t\t\tbutton.setEnabled(false);\n\t\t\t\t}\n\t\t\t\tcurrentlyVoting = null;\n\t\t\t\tlblCurrentVoter.setText(null);\n\t\t\t\tlblCurrentVoter.setIcon(null);\n\t\t\t\tpnlVoting.setVisible(false);\n\t\t\t}", "public VotingSystem() {\n votingList=new ArrayList<>();\n }", "public void sendPostDownVote(){\n Intent intent = getIntent();\n final int heritageId = intent.getIntExtra(\"heritageId\", -1);\n Retrofit retrofit = ApiClient.getApiClient();\n final SharedPreferences sharedPref = getSharedPreferences(\"TOKENSHARED\", Context.MODE_PRIVATE);\n final String token = sharedPref.getString(\"TOKEN\", null);\n ApiInterface apiInterface = retrofit.create(ApiInterface.class);\n Call<JsonResponseVote> call = apiInterface.vote(new VoteBody(false, heritageId),\"Token \" + token);\n call.enqueue(new Callback<JsonResponseVote>() {\n @Override\n public void onResponse(Call<JsonResponseVote> call, Response<JsonResponseVote> response) {\n\n if (response.isSuccessful()) {\n Toast.makeText(getApplicationContext(), \"SUCCESSFUL DOWNVOTE\", Toast.LENGTH_SHORT).show();\n voteCount.setText(Integer.toString(response.body().getUpvote_count()-response.body().getDownvote_count()));\n deleteVote.setEnabled(true);\n downVote.setEnabled(false);\n upVote.setEnabled(true);\n\n } else {\n Toast.makeText(getApplicationContext(), \"Sorry for inconvince server is down\" + response.code(), Toast.LENGTH_SHORT).show();\n Log.d(\"response\", response.raw().body().toString());\n }\n\n }\n\n @Override\n public void onFailure(Call<JsonResponseVote> call, Throwable t) {\n Toast.makeText(getApplicationContext(), \"ERROR while posting\", Toast.LENGTH_SHORT).show();\n }\n });\n }", "public void sendPostUpVote(){\n Intent intent = getIntent();\n final int heritageId = intent.getIntExtra(\"heritageId\", -1);\n Retrofit retrofit = ApiClient.getApiClient();\n final SharedPreferences sharedPref = getSharedPreferences(\"TOKENSHARED\", Context.MODE_PRIVATE);\n final String token = sharedPref.getString(\"TOKEN\", null);\n ApiInterface apiInterface = retrofit.create(ApiInterface.class);\n Call<JsonResponseVote> call = apiInterface.vote(new VoteBody(true, heritageId),\"Token \" + token);\n call.enqueue(new Callback<JsonResponseVote>() {\n @Override\n public void onResponse(Call<JsonResponseVote> call, Response<JsonResponseVote> response) {\n\n if (response.isSuccessful()) {\n Toast.makeText(getApplicationContext(), \"SUCCESSFUL UPVOTE\", Toast.LENGTH_SHORT).show();\n voteCount.setText(Integer.toString(response.body().getUpvote_count()-response.body().getDownvote_count()));\n deleteVote.setEnabled(true);\n upVote.setEnabled(false);\n downVote.setEnabled(true);\n\n } else {\n Toast.makeText(getApplicationContext(), \"Sorry for inconvince server is down\" + response.code(), Toast.LENGTH_SHORT).show();\n Log.d(\"response\", response.raw().body().toString());\n }\n\n }\n\n @Override\n public void onFailure(Call<JsonResponseVote> call, Throwable t) {\n Toast.makeText(getApplicationContext(), \"ERROR while posting\", Toast.LENGTH_SHORT).show();\n }\n });\n\n }", "public void reset() {\n\t\tacceptAnswers = false;\n\t\tcurrentQuestion = null;\n\t\tsubmissions = null;\n\t}", "@Override\n public void reset() {\n updateDice(1, 1);\n playerCurrentScore = 0;\n playerScore = 0;\n updateScore();\n notifyPlayer(\"\");\n game.init();\n }", "public void resetScore();", "public int getVotes() {\n return votes;\n }", "public int getVotes() {\n return votes;\n }", "public static void doVoteAndComment() {\n }", "public int calculateVotes() {\n return 1;\n }", "public void resetTally() {\n won_stayed = 0;\n won_switched = 0;\n total_stayed = 0;\n total_switched = 0;\n }", "@Override\n\t\t\t\tpublic void onClick(View v) {\n\t\t\t\t\t\n\t\t\t\t\tdoVote(getIntent().getStringExtra(\"aid\"), getIntent().getStringExtra(\"id\"));\n\t\t\t\t\t\n\t\t\t\t}", "public int getVotes() {\n return this.votes;\n }", "private synchronized void delegateVoted(Vote voteType) {\n\t\tvotes.put(currentlyVoting, voteType);\n\t\tif (currentlyVoting.getStatus().hasVetoPower && voteType.isVoteAgainst) {\n\t\t\t// A delegate with veto power voted against.\n\t\t\tvetoed = true;\n\t\t}\n\t\tsynchronized (votingThread) {\n\t\t\tvotingThread.notify();\n\t\t}\n\t}", "public void reset(View view) {\r\n homeScore = 0;\r\n visitorScore = 0;\r\n displayHomeScore(homeScore);\r\n displayVisitorScore(visitorScore);\r\n }", "public void runOff(int round) {\n\t\tfor (int i = 0; i < voteOrder.size(); i++) {\n\n\t\t\t// Depending on the round, get the number voted\n\t\t\tint count = voteOrder.elementAt(i).elementAt(round) - 1;\n\n\t\t\tCandidat candidat = Candidats.elementAt(count);\n\n\t\t\tif (candidat.getId() == count && !candidat.isEliminated) {\n\t\t\t\tint vow = candidat.getVows() + 1;\n\t\t\t\tcandidat.setVows(vow);\n\n\t\t\t\t// candidat.calculatePercentage(voteOrder.size());\n\t\t\t}\n\n\t\t}\n\n\t}", "public void reset() {\n\tthis.pinguins = new ArrayList<>();\n\tthis.pinguinCourant = null;\n\tthis.pret = false;\n\tthis.scoreGlacons = 0;\n\tthis.scorePoissons = 0;\n }", "public VotingSystem(){\n votingList = new ArrayList<Voting>();\n }", "public void unblock(){ \n blocked = false;\n blockedMssg = \"\";\n\n // update todos los votos como colectivo\n for (Collective c: memberCollectives) c.updateFamilyVotes();\n\n // update todos los votos como usuario\n for (Project p: getVotedProjects()) p.updateVotes();\n }", "public void resetScore (View v) {\n vScore = 0;\n kScore = 0;\n displayForTeamK(kScore);\n displayForTeamV(vScore);\n }", "public void voteRollback() {\n synchronized ( this ) {\n rbVotes++; \n votedCommit = false;\n }\n preVote();\n postVote();\n }", "public void reset()\n {\n currentScore = 0;\n }", "public void resetScoreA(View v) {\n scoreTeamA = 0;\n\n displayForTeamA(scoreTeamA);\n\n\n }", "public void setVotes(int[] topIdeas) {\n\t\tif (voted)\n\t\t\tthrow new IllegalArgumentException(\"Can't set votes twice\");\n\t\tif (topIdeas == null)\n\t\t\treturn;\n\t\tif (topIdeas.length > NUM_RANKED)\n\t\t\tthrow new IllegalArgumentException(\"length of topIdeas must \"\n\t\t\t\t\t+ \"be <= \" + NUM_RANKED);\n\t\n\t\tfor (int i = 0; i < topIdeas.length; ++i)\n\t\t\tthis.topIdeas[i] = topIdeas[i];\n\t\t// Figure out if the student voted at all\n\t\tfor (int i = 0; i < this.topIdeas.length; ++i) {\n\t\t\tif (this.topIdeas[i] != 0) {\n\t\t\t\tvoted = true;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t}", "@Override\r\n\tpublic int reset() throws NotesApiException {\n\t\treturn 0;\r\n\t}", "void setVoteFinalizeDelaySeconds(long voteFinalizeDelaySeconds);", "private void resetCount(){\r\n\t\t\tactiveAgent = 0;\r\n\t\t\tjailedAgent = 0;\r\n\t\t\tquietAgent = 0;\r\n\t\t}", "@Test\n public void downVotingQuestionsGetNoPoints() throws Exception {\n\n bob.upVote(question);\n charlie.downVote(question);\n\n assertEquals(5,alice.getReputation());\n }", "public void addKickVote()\n\t{\n\t\tthis.numberOfKickVotes++;\n\t}", "public final void reset() {\n\t\tscore = 0;\n\t\tlives = 10;\n\t\tshields = 3;\n\t}", "void castVote(Peer candidate) {\n votedFor = candidate;\n }", "public void clearMoteList()\n {\n swapMotes.removeAllElements();\n }", "public void reset() {\n\t\tscore = 0;\n\t}", "public void setNoVoteCount(Integer noVoteCount) {\n this.noVoteCount = noVoteCount;\n }", "public void resetScore(View v) {\n scoreTeamA = 0;\n scoreTeamB = 0;\n displayForTeamA(scoreTeamA);\n displayForTeamB(scoreTeamB);\n }", "public void resetScore(View v) {\n scoreTeamA = 0;\n scoreTeamB = 0;\n displayForTeamA(scoreTeamA);\n displayForTeamB(scoreTeamB);\n }", "public void sendPostDeleteVote(){\n Intent intent = getIntent();\n final int heritageId = intent.getIntExtra(\"heritageId\", -1);\n Retrofit retrofit = ApiClient.getApiClient();\n final SharedPreferences sharedPref = getSharedPreferences(\"TOKENSHARED\", Context.MODE_PRIVATE);\n final String token = sharedPref.getString(\"TOKEN\", null);\n ApiInterface apiInterface = retrofit.create(ApiInterface.class);\n Call<JsonResponseDeleteVote> call = apiInterface.deleteVote(new DeleteVoteBody(heritageId),\"Token \" + token);\n call.enqueue(new Callback<JsonResponseDeleteVote>() {\n @Override\n public void onResponse(Call<JsonResponseDeleteVote> call, Response<JsonResponseDeleteVote> response) {\n\n if (response.isSuccessful()) {\n Toast.makeText(getApplicationContext(), \"SUCCESSFUL DELETE VOTE\", Toast.LENGTH_SHORT).show();\n voteCount.setText(Integer.toString(response.body().getUpvote_count()-response.body().getDownvote_count()));\n upVote.setEnabled(true);\n downVote.setEnabled(true);\n\n }else if(response.code() == 404){\n Toast.makeText(getApplicationContext(), \"Firstly, please vote !!\" , Toast.LENGTH_SHORT).show();\n }\n else {\n Toast.makeText(getApplicationContext(), \"Sorry for inconvince server is down\" + response.code(), Toast.LENGTH_SHORT).show();\n Log.d(\"response\", response.raw().body().toString());\n }\n\n }\n\n @Override\n public void onFailure(Call<JsonResponseDeleteVote> call, Throwable t) {\n Toast.makeText(getApplicationContext(), \"ERROR while posting\", Toast.LENGTH_SHORT).show();\n }\n });\n\n }", "@Override\n public void onThirdVote(String arg0) {\n\n }", "public void resetScore() {\n\t\tthis.score = 0;\n\t}", "public void reset(View v) {\n scoreTeamB = 0;\n displayForTeamB(scoreTeamB);\n scoreTeamA = 0;\n displayForTeamA(scoreTeamA);\n questionNumber = 0;\n displayQuestionNumber(questionNumber);\n }", "public void onReset (View view) {\n //deleting the radiogroups choosen buttons\n RadioGroup radioGroup1 = findViewById(R.id.radio_group1);\n radioGroup1.clearCheck();\n RadioGroup radioGroup2 = findViewById(R.id.radio_group2);\n radioGroup2.clearCheck();\n RadioGroup radioGroup3 = findViewById(R.id.radio_group3);\n radioGroup3.clearCheck();\n\n //deleting the answer if it's wrong or right\n TextView hint1 = findViewById(R.id.response_1);\n hint1.setText(\"\");\n TextView hint2 = findViewById(R.id.response_2);\n hint2.setText(\"\");\n TextView hint3 = findViewById(R.id.response_3);\n hint3.setText(\"\");\n TextView hint4 = findViewById(R.id.response_4);\n hint4.setText(\"\");\n TextView hint5 = findViewById(R.id.response_5);\n hint5.setText(\"\");\n\n //delete 2. answer\n EditText numberOfCountries = findViewById(R.id.members);\n numberOfCountries.setText(\"\");\n\n //delete 3. answer\n CheckBox norway = findViewById(R.id.norway);\n norway.setChecked(false);\n CheckBox poland = findViewById(R.id.poland);\n poland.setChecked(false);\n CheckBox turkey = findViewById(R.id.turkey);\n turkey.setChecked(false);\n CheckBox slovakia = findViewById(R.id.slovakia);\n slovakia.setChecked(false);\n CheckBox switzerland = findViewById(R.id.switzerland);\n switzerland.setChecked(false);\n CheckBox greece = findViewById(R.id.greece);\n greece.setChecked(false);\n\n //delete the final score message\n TextView finalScore = findViewById(R.id.score_text);\n finalScore.setText(R.string.number_of_points);\n points = 0;\n }", "private void botVoting(){\n int stockPos;\n int myStockPos = getMostShares(playerList.lastIndexOf(player));\n Collections.sort(playerList);\n if(playerList.get(0) == player){ //if i am the leader\n stockPos = getMostShares(1); //get the second players info\n }else{\n stockPos = getMostShares(0); //else get the first players info\n }\n\n //if my most shares are the same as other players most shares, don't vote.\n if(game.getStockByIndex(stockPos) != game.getStockByIndex(myStockPos)){\n //offensive play against leader\n if(game.isCardPositive(game.getStockByIndex(stockPos))){\n game.getStockByIndex(stockPos).vote(0);\n player.getVotedStocks().append(game.getStockByIndex(stockPos).getName().charAt(0));\n player.deductVotesLeft();\n System.out.println(\"bot voted NO for \" + game.getStockByIndex(stockPos).getName() );\n }else{\n game.getStockByIndex(stockPos).vote(1);\n player.getVotedStocks().append(game.getStockByIndex(stockPos).getName().charAt(0));\n player.deductVotesLeft();\n System.out.println(\"bot voted YES for \" + game.getStockByIndex(stockPos).getName());\n }\n //defensive play, votes that will benefit me\n if(game.isCardPositive(game.getStockByIndex(myStockPos))){\n game.getStockByIndex(myStockPos).vote(1);\n player.getVotedStocks().append(game.getStockByIndex(myStockPos).getName().charAt(0));\n player.deductVotesLeft();\n System.out.println(\"bot voted YES for \" + game.getStockByIndex(myStockPos).getName());\n }else{\n game.getStockByIndex(myStockPos).vote(0);\n player.getVotedStocks().append(game.getStockByIndex(myStockPos).getName().charAt(0));\n player.deductVotesLeft();\n System.out.println(\"bot voted NO for \" + game.getStockByIndex(myStockPos).getName());\n }\n }\n }", "public void countReset(View view){\n //get the textView and then set count to zero\n TextView showCountTextView = (TextView) findViewById(R.id.numberBox);\n showCountTextView.setText(\"0\");\n }", "public void resetAllScores(View view) {\n teamA_score = 0;\n teamB_score = 0;\n ADVANTAGE = 0;\n enableScoreView();\n unSetWinnerImage();\n displayTeamA_score(teamA_score);\n displayTeamB_score(teamB_score);\n\n }", "@Override\n public void resetQuestion() {\n super.resetQuestion();\n hadSecondChance = false;\n currentTeam = null;\n originalTeam = null;\n teamHasAnswered.clear();\n //reset teamHasAnswered map so all teams get a chance to anaswer again\n for (int i = 0; i < numTeams; i++) teamHasAnswered.put(i, false);\n }", "private void setVoteOrder() {\n\t\tfor (int i = 1; i < temp.size(); i++) {\n\t\t\t// deleting the comma from the name\n\t\t\tString s = temp.elementAt(i).replaceAll(\",\", \"\");\n\t\t\t// creating a vector \"tempVoteOrder\" to store the preferences of\n\t\t\t// each voter\n=======\n\t\t\tCandidats.add(candidat);\n\t\t\ttempCandidats = tempCandidats.replaceFirst(\n\t\t\t\t\ttempCandidats.substring(0, tempCandidats.indexOf(\",\") + 1),\n\t\t\t\t\t\"\");// delete the first candidat in the String\n\t\t}\n\t\tfor (int j = 0; j < Candidats.size(); j++)\n\t\t\tCandidats.elementAt(j).setVowsPerRound(Candidats.size());// fill the\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// vector\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// of\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// size\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// \"candidats\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// by\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// 0's\n\t}", "private void reset(){\n getPrefs().setEasyHighScore(new HighScore(\"Player\", 99 * 60 + 59));\n getPrefs().setMediumHighScore(new HighScore(\"Player\", 99 * 60 + 59));\n getPrefs().setHardHighScore(new HighScore(\"Player\", 99 * 60 + 59));\n easyData.setText(formatHighScore(getPrefs().getEasyHighScore()));\n mediumData.setText(formatHighScore(getPrefs().getMediumHighScore()));\n hardData.setText(formatHighScore(getPrefs().getHardHighScore()));\n }", "public Ratio getVotes() {\n return votes;\n }", "public void resetScore(View view) {\n scoreTeamA = 0;\n scoreTeamB = 0;\n displayForTeamA(0);\n displayForTeamB(0);\n }", "public void sendVoteRequests() {\n for(int i = 1; i <= mConfig.getNumServers(); i++) {\n this.remoteRequestVote(i, mConfig.getCurrentTerm(), mID, mLog.getLastIndex(), mLog.getLastTerm());\n }\n //Initiate count vote timer\n voteCountTimer = scheduleTimer((long) 5, 2);\n }", "public void reset() {\nsuper.reset();\nsetIncrease_( \"no\" );\nsetSwap_( \"tbr\" );\nsetMultrees_( \"no\" );\nsetRatchetreps_(\"200\");\nsetRatchetprop_(\"0.2\");\nsetRatchetseed_(\"0\");\n}", "private void clearLikesCount() {\n \n likesCount_ = 0;\n }", "void rateLimitReset();", "public void reset() {\r\n\t\tplayAgain = false;\r\n\t\tmainMenu = false;\r\n\t\tachievement = 0;\r\n\t}", "public void removeVote(String token);", "public void resetAllScores(View v) {\n scorePlayerB = 0;\n scorePlayerA = 0;\n triesPlayerA = 0;\n triesPlayerB = 0;\n displayForPlayerA(scorePlayerA);\n displayForPlayerB(scorePlayerB);\n displayTriesForPlayerA(triesPlayerA);\n displayTriesForPlayerB(triesPlayerB);\n }", "public void resetUserSurvey(long surveyId, long userId);", "@Override\n\tpublic void reset() {\n\t\tthis.result = 0;\n\t\tthis.operande = \"0\";\n\t\tthis.operateur = \"\";\n\t\tnotifyObserver(String.valueOf(this.result));\n\t}", "void redoExpenseTracker() throws NoUserSelectedException;", "public void reset(View view) {\r\n scoreA = 0;\r\n scoreB = 0;\r\n foulsA = 0;\r\n foulsB = 0;\r\n displayScoreForTeamA(scoreA);\r\n displayFoulsForTeamA(foulsA);\r\n displayScoreForTeamB(scoreB);\r\n displayFoulsForTeamB(foulsB);\r\n }", "public void resetAttackAttempts() {\r\n\t\tattackAttempts = 0;\r\n\t}", "@Override\n public Boolean then(@NonNull Task task) throws Exception {\n upvotingPost = false;\n return true;\n }", "public void resetForBothTeams(View view) {\n scoreForR_madrid = 0;\n scoreForL_pool = 0;\n\n foulCountRmadrid = 0;\n y_cardCountRmadrid = 0;\n r_cardCountRmadrid = 0;\n\n foulCountLpool = 0;\n y_cardCountLpool = 0;\n r_cardCountLpool = 0;\n\n displayForRmadrid(scoreForR_madrid);\n displayForLpool(scoreForL_pool);\n\n displayFoulForRmadrid(foulCountRmadrid);\n displayY_CardForRmadrid(y_cardCountRmadrid);\n displayR_CardForRmadrid(r_cardCountRmadrid);\n\n displayFoulForLpool(foulCountLpool);\n displayYcardForLpool(y_cardCountLpool);\n displayRcardForLpool(r_cardCountLpool);\n\n }", "public static void resetSaveCounter5(Context context) {\n prefs = context.getSharedPreferences(\"com.mobile.counterappmobile\", context.MODE_PRIVATE);\n SaveCounter5 = prefs.getInt(saveCounter5, 0);\n SaveCounter5=0;\n prefs.edit().putInt(saveCounter5, SaveCounter5).commit();\n\n }", "public void vote(View v) {\n Intent goToSecond = new Intent();\n goToSecond.setClass(this, SecondActivity.class);\n goToSecond.putExtra(\"vote\", (int)ratingBar.getRating());\n startActivity(goToSecond);\n //Toast.makeText(getApplicationContext(), \"Before finish!\", Toast.LENGTH_SHORT).show();\n finish();\n //Toast.makeText(getApplicationContext(), \"After finish!\", Toast.LENGTH_SHORT).show();\n }", "public void resetHealth(){\n curHp = healthPoint;\n }", "public void resetPingCount() {\n\t\tpingCount = 0;\n\t}", "public void resetScoreB(View v) {\n scoreTeamB = 0;\n\n displayForTeamB(scoreTeamB);\n\n\n }", "@Override\n public void onClick(View view) {\n resetEverything();\n }", "public void reset() {\n cooldowns.clear();\n }", "public Integer getVotes();", "public void upvote(String articleId) {\n Vote vote;\n if (currentlyUpvoted(articleId)) {\n vote = new Vote(articleId, 1, 0);\n } else if (currentlyDownvoted(articleId)) {\n vote = new Vote(articleId, -1, 1);\n } else {\n vote = new Vote(articleId, 0, 1);\n }\n\n postVoteAndPersistLocally(vote);\n }", "@Test\n public void vote() {\n System.out.println(client.makeVotes(client.companyName(0), \"NO\"));\n }", "public int getNumVotes() {\n return numVotes;\n }", "public void setVotingThreshold(double votingThreshold) {\n this.votingThreshold = votingThreshold;\n }", "public void resetCount() {\n count = 0;\n }", "private void check4voteAndClean()\n\t{\n\t\tif( noBeepersPresent())\n\t\t{\tturnLeft();\n\t\t\tmove();\n\t\t\tpickAll();\n\t\t\tturnAround();\n\t\t\tmove();\n\t\t\tmove();\n\t\t\tpickAll();\n\t\t\tturnAround();\n\t\t\tmove();\n\t\t\tturnRight();\n\t\t}\n\t}", "public static void resetSaveCounter6(Context context) {\n prefs = context.getSharedPreferences(\"com.mobile.counterappmobile\", context.MODE_PRIVATE);\n SaveCounter6 = prefs.getInt(saveCounter6, 0);\n SaveCounter6=0;\n prefs.edit().putInt(saveCounter6, SaveCounter6).commit();\n\n }", "public void resetZealotCounter() {\n persistentValues.summoningEyeCount = 0;\n persistentValues.totalKills = 0;\n persistentValues.kills = 0;\n saveValues();\n }", "public VoteModel mo66737c(Answer answer) {\n VoteModel voteModel = new VoteModel();\n voteModel.voteCount = answer.voteUpCount;\n boolean z = true;\n if (answer.relationship.voting != 1) {\n z = false;\n }\n voteModel.isVoted = z;\n return voteModel;\n }", "public void resetAmountBought() {\n //System.out.println(\"Resetting amount bought for \" + clientName + \"...\");\n amountBought = 0;\n }", "public void resetCount(View view) {\n\t\tcounterModel.resetCounter();\n\t\tcurrentCountTextView.setText(Integer.toString(counterModel.getCount()));\n\t}", "public void resetHP(){\r\n this.currHP = this.maxHP;\r\n }" ]
[ "0.68881065", "0.67347294", "0.6553621", "0.6448625", "0.6413105", "0.6387524", "0.63436985", "0.62860423", "0.6244751", "0.62084836", "0.62023175", "0.6194082", "0.61202884", "0.6077145", "0.6047324", "0.6013619", "0.59704447", "0.59695727", "0.5953164", "0.5913947", "0.591079", "0.5896004", "0.5885979", "0.58697", "0.58697", "0.58643955", "0.5838327", "0.5792788", "0.57901204", "0.57687724", "0.5768148", "0.5758895", "0.5741624", "0.57372236", "0.5725154", "0.5715773", "0.5700176", "0.56495875", "0.56418616", "0.5641014", "0.562607", "0.5622495", "0.56079555", "0.56047374", "0.5602867", "0.5599628", "0.5597605", "0.55799234", "0.5579844", "0.55706483", "0.552233", "0.5520888", "0.5520888", "0.5520491", "0.54979116", "0.54966724", "0.54881334", "0.54867387", "0.5479618", "0.5475538", "0.5470163", "0.54628265", "0.5444041", "0.54418576", "0.5427964", "0.5425659", "0.54240537", "0.5418352", "0.5397396", "0.5389326", "0.53877133", "0.53875434", "0.53768915", "0.53639656", "0.53581846", "0.53472936", "0.53434885", "0.5340905", "0.5337898", "0.5336477", "0.53362095", "0.5332128", "0.5330516", "0.5327713", "0.5321187", "0.532016", "0.53136367", "0.5311152", "0.5307278", "0.5292708", "0.5291074", "0.5287166", "0.5276741", "0.5274139", "0.5272887", "0.5270308", "0.5270054", "0.5268555", "0.5268405", "0.5263468" ]
0.6343667
7
Created by Pan on 2016/12/20.
public interface IRecommendService { long add(Recommend recommendVo); long edit(Recommend recommendVo); boolean remove(long id); PageInfoResult<Recommend> list(PageConfig pageConfig, Recommend recommend); boolean hits(Long id); Recommend get(long id); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "private stendhal() {\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "public final void mo51373a() {\n }", "public void gored() {\n\t\t\n\t}", "@Override\n public void init() {\n\n }", "@Override\n\tprotected void interr() {\n\t}", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "private static void cajas() {\n\t\t\n\t}", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n protected void initialize() {\n\n \n }", "public void mo38117a() {\n }", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "private void poetries() {\n\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "public void mo4359a() {\n }", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n\tpublic void one() {\n\t\t\n\t}", "@Override\n public void init() {\n }", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n void init() {\n }", "private void init() {\n\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "private void kk12() {\n\n\t}", "@Override\n\tpublic void jugar() {\n\t\t\n\t}", "@Override\n protected void initialize() \n {\n \n }", "@Override\n public void init() {\n\n }", "@Override\n public void init() {\n\n }", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n public void init() {}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "protected boolean func_70814_o() { return true; }", "@Override\r\n\tpublic void init() {}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "@Override\n protected void init() {\n }", "@Override\n public void memoria() {\n \n }", "private void m50366E() {\n }", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n\tpublic void init() {\n\t}", "@Override\n\tpublic void init()\n\t{\n\n\t}", "private Rekenhulp()\n\t{\n\t}", "@Override\n public int describeContents() { return 0; }", "@Override\n\tpublic void einkaufen() {\n\t}", "@Override\r\n\tprotected void doF4() {\n\t\t\r\n\t}", "Petunia() {\r\n\t\t}", "@Override\n public void initialize() { \n }", "@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\n protected void getExras() {\n }", "public void mo6081a() {\n }", "public void mo55254a() {\n }", "private void strin() {\n\n\t}", "@Override\n\tpublic void afterInit() {\n\t\t\n\t}", "@Override\n\tpublic void afterInit() {\n\t\t\n\t}", "public void mo21877s() {\n }" ]
[ "0.6112025", "0.598368", "0.59411824", "0.5939467", "0.58690566", "0.5833437", "0.582706", "0.582706", "0.5740283", "0.57009125", "0.56886643", "0.56835824", "0.56703585", "0.5668659", "0.5660734", "0.5655428", "0.56489444", "0.5646463", "0.562938", "0.5627961", "0.5626465", "0.5626465", "0.5626465", "0.5626465", "0.5626465", "0.56193644", "0.56102544", "0.5594898", "0.5594898", "0.5592013", "0.5590407", "0.55782664", "0.55766326", "0.5574261", "0.55547553", "0.5543103", "0.5534445", "0.5532995", "0.5532995", "0.55304843", "0.5527534", "0.55262935", "0.55226994", "0.55133003", "0.55114144", "0.54999816", "0.54999816", "0.54999816", "0.5495792", "0.548665", "0.54860103", "0.54841274", "0.54841274", "0.54836464", "0.54836464", "0.54836464", "0.54789644", "0.54761225", "0.5470509", "0.5470509", "0.5470509", "0.5465938", "0.5465938", "0.5465938", "0.5465938", "0.5465938", "0.5465938", "0.54616636", "0.54533577", "0.54533577", "0.54533577", "0.54533577", "0.54533577", "0.54533577", "0.54533577", "0.54513544", "0.5445328", "0.5442457", "0.5435049", "0.5414532", "0.5410794", "0.53998625", "0.53973836", "0.5391114", "0.53882784", "0.5386272", "0.53843725", "0.5380272", "0.53750825", "0.53709745", "0.53708154", "0.5368149", "0.536596", "0.53633565", "0.5361475", "0.5353367", "0.5348746", "0.53313553", "0.5328097", "0.5328097", "0.5325576" ]
0.0
-1
replace the element in the collection by itself to trigger a model update
public void refreshRowTemplate(LanguageContributionStatus lcs) { contributionStatuses.set(contributionStatuses.indexOf(lcs), lcs); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n\tpublic boolean update(Eleve o) {\n\t\tmap.replace(o.getId(), o);\n\t\treturn true;\n\t}", "private static CompletionStage<Void> update(ReactiveMongoCollection collection, Object entity) {\n BsonDocument document = getBsonDocument(collection, entity);\n\n //then we get its id field and create a new Document with only this one that will be our replace query\n BsonValue id = document.get(ID);\n BsonDocument query = new BsonDocument().append(ID, id);\n return collection.replaceOne(query, entity).thenApply(u -> null);\n }", "@Override\n public T update(T element) {\n return manager.merge(element);\n }", "@Override\r\n\tpublic void updateElement() {\n\r\n\t}", "@Override\n\tpublic void update(Epreuve element) throws DaoException {\n\t\t\n\t}", "public void updateByObject()\r\n\t{\n\t}", "E update(E entiry);", "@Override\r\n\tpublic void uniqueUpdate() {\n\r\n\t}", "@Override\n public void update(EntityModel model) {\n super.update(model);\n\n }", "@Override\n public void Update(Model model) {\n\n }", "public void update(E model) {\n\t\tgetHibernateTemplate().update(model);\r\n\t}", "Item update(Item item);", "@Override\r\n\tpublic void update(Interest model, InterestEntity entity) {\n\r\n\t}", "@Override\n public boolean update(Revue objet) {\n return false;\n }", "@Override\n\tpublic void modifyItem(Object toUpdated) {}", "@Override\r\n\tpublic Integer updateByPrimaryKeySelective(Wt_collection record) {\n\t\treturn 0;\r\n\t}", "private void reafficher() {\n\t\tthis.setChanged();\n\t\tthis.notifyObservers();\n\t}", "@Override\n\tpublic boolean update(Document obj) {\n\t\treturn false;\n\t}", "@Override\r\n\tprotected void setValue(Object element, Object value) {\r\n\t\t// update the whole table\r\n\t\tgetViewer().refresh();\r\n\t}", "@Override\r\n\tpublic Integer updateByPrimaryKey(Wt_collection record) {\n\t\treturn 0;\r\n\t}", "@Override\n\tpublic int update(Object model) {\n\t\treturn 0;\n\t}", "private void recreateModel() {\n items = null;\n didItCountAlready = false;\n }", "E update(E entity);", "E update(E entity);", "void updateModel() {\n updateModel(false);\n }", "void updateItem(E itemElementView);", "@Override\n\tpublic void update(Object o) {\n\n\t}", "@Override\n\tpublic void update(Object o) {\n\n\t}", "@Override\n\tpublic void update() {\n\t\tobj.update();\n\t}", "@SuppressWarnings(\"serial\")\n\t@Test\n\tpublic void updateCollection() {\n\t\tdb.close();\n\t\tEmbeddedConfiguration config = Db4oEmbedded.newConfiguration();\n\t\tconfig.common().objectClass(Car.class).cascadeOnUpdate(true);\n\t\tdb = Db4oEmbedded.openFile(config, DB4OFILENAME);\n\t\tObjectSet<Car> results = db.query(new Predicate<Car>() {\n\t\t\tpublic boolean match(Car candidate) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t});\n\n\t\tAssert.assertTrue(results.hasNext());\n\n\t\tCar car = results.next();\n\n\t\tcar.getHistory().remove(0);\n\t\tdb.store(car.getHistory());\n\t\tresults = db.query(new Predicate<Car>() {\n\t\t\tpublic boolean match(Car candidate) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t});\n\n\t\twhile (results.hasNext()) {\n\t\t\tcar = results.next();\n\t\t\tfor (int idx = 0; idx < car.getHistory().size(); idx++) {\n\t\t\t\tSystem.out.println(car.getHistory().get(idx));\n\t\t\t}\n\t\t}\n\n\t}", "@Override\r\n\tpublic boolean update(LabelArticle model) {\n\t\treturn false;\r\n\t}", "@Test\r\n\tpublic void testUpdate() {\r\n\t\tList<E> entities = dao.findAll();\r\n\t\tE updated = supplyUpdated(entities.get(0));\r\n\t\tdao.update(entities.get(0));\r\n\t\tentities = dao.findAll();\r\n\t\tassertEquals(updated, entities.get(0));\r\n\t}", "public void updateModel() {\n\t\tIterator<Cell> itr = iterator();\n\t\twhile(itr.hasNext()) itr.next().update();\n\t\titr = iterator();\n\t\twhile(itr.hasNext()) {\n\t\t\t(itr.next()).nextGeneration();\n\t\t}\n\t\tupdateGraph();\n\t}", "public void willbeUpdated() {\n\t\t\n\t}", "public void notifyModelUpdated()\n {}", "@Override\r\n\tpublic boolean update(Moteur obj) {\n\t\treturn false;\r\n\t}", "public void update(E entity);", "@Override\n\tpublic void update(Object entidade) {\n\t\t\n\t}", "void updateModelFromView();", "@Override\r\n\tpublic void update(Notification notification, EObject element) {\n\t\tsuper.update(notification, element);\r\n\t}", "void updateViewFromModel();", "@Override\n\t\tpublic void update() {\n\n\t\t}", "@Override\n\t\tpublic void update() {\n\n\t\t}", "@Override\n\t\tpublic void update() {\n\n\t\t}", "@Override\r\n\tpublic void update(GroupBeds bean) {\n\r\n\t}", "void update ( priorizedListObject v ) throws DAOException;", "public void update(){}", "public void update(){}", "void refresh(Collection<? extends BaseModel> objects);", "@Override\r\n public void update(Answer entity) {\n\r\n }", "public void updateCurrentValues(AnyUriModel model) {\r\n this.model = model;\r\n resetValuesFromModel();\r\n }", "protected void refreshFromRepository() {\n\t\t\r\n\t\tObject[] elements = new Object[]{};\r\n\t\tmodelObject.eContainer();\r\n\t\t\r\n\t\tif (fFilteredList != null) {\r\n\t\t\t\r\n\t\t\tfFilteredList.setAllowDuplicates(showDuplicates);\r\n\t\t\tfFilteredList.setElements(elements);\r\n\t\t\tfFilteredList.setEnabled(true);\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\tif (fTreeViewer != null) {\r\n\t\t\tfTreeViewer.setInput(null);\r\n\t\t}\t\t\r\n\t}", "@Override\n\tpublic void updateProcuctModel(CollectionOfModel collectionOfModel) {\n\t\t// TODO Auto-generated method stub\n\t\t\n\t\tProductModel entity = procuctModelDAO.findById(Integer.parseInt(collectionOfModel.getProductId()));\n\t\t\n\t\tif(entity != null) {\n\t\t\tentity.setCompanyId(Integer.parseInt(collectionOfModel.getCompany_id()));\n\t\t\tentity.setScreenSizeId(Integer.parseInt(collectionOfModel.getModell_size_id()));\n\t\t\tentity.setProcuctInfo(collectionOfModel.getModell_info());\n\t\t\tentity.setModellTypeId(Integer.parseInt(collectionOfModel.getModell_type_id()));\n\t\t\tentity.setProcuctName(collectionOfModel.getModellName());\n\t\t\tentity.setProductPris(Integer.parseInt(collectionOfModel.getModellPris()));\n\t\t\tentity.setIsViseble(Integer.parseInt(collectionOfModel.getIsVisible()));\n\t\t\t\n\t\t}\n\t}", "@Override\n\tpublic void update() {}", "@Override\n\tpublic void update() {}", "@Override\r\n\tpublic void update(Object object) {\n\t\t\r\n\t}", "private void setModelToChanged() {\n\t\tsetChanged();\r\n\t\tnotifyObservers();\r\n\t}", "@Override\r\n protected void updateObject(SimpleBody object, Entity e) {\n }", "@Override\r\n protected void updateObject(SimpleBody object, Entity e) {\n }", "public void updateEntity();", "@Override\r\n\tpublic void update(Person person) {\n\r\n\t}", "private void refreshItem() {\n\t\tboundSwagForm.getField(\"isFetchOnly\").setValue(true);\r\n\t\tboundSwagForm.saveData(new DSCallback() {\r\n\t\t\t//reselect selected tile (call to saveData de-selects it)\r\n\t\t\tpublic void execute(DSResponse response,\r\n\t\t\t\t\tObject rawData, DSRequest request) {\r\n\t\t\t\t//get updated record\r\n\t\t\t\tfinal TileRecord rec = new TileRecord(request.getData());\r\n\t\t\t\t//Note: selectRecord seems to only work on the tile index\r\n\t\t\t\titemsTileGrid.selectRecord(itemsTileGrid.getRecordIndex(rec));\r\n\t\t\t\t//saveData adds tileRecord to the end.\r\n\t\t\t\t//make sure sort order is preserved\r\n\t\t\t\tdoSort();\r\n\t\t\t}});\r\n\t}", "@Override\r\n\t\tpublic void update() {\n\t\t\t\r\n\t\t}", "@Override\r\n\t\tpublic void update() {\n\t\t\t\r\n\t\t}", "@Override\n\t\t\t\tpublic void insertUpdate(DocumentEvent e) {\n\t\t\t\t\tchange();\n\t\t\t\t}", "@Override\n public void updateItem(P_CK t) {\n \n }", "@Override\n\tpublic void update(Unidade obj) {\n\n\t}", "public boolean update(New object);", "@Override\r\n\tpublic void update(Person p) \r\n\t{\n\t\t\r\n\t}", "public void resetModification()\n {\n _modifiedSinceSave = false;\n }", "@Override\r\n\tpublic Ngo update(Ngo obj) {\n\t\treturn null;\r\n\t}", "public void updateList() \n { \n model.clear();\n for(int i = ScholarshipTask.repository.data.size() - 1; i >= 0; i--) \n {\n model.addElement(ScholarshipTask.repository.data.get(i));\n }\n }", "public boolean update(ModelObject obj);", "@Override\n\tpublic Book update(Book dto) {\n\t\treturn null;\n\t}", "@Override\n\tpublic Product update(Product entity) {\n\t\treturn null;\n\t}", "@Override\r\n\tpublic Product updateProduct(Product s) {\n\t\treturn null;\r\n\t}", "@Override\n\tpublic Fournisseur update(Fournisseur entity) {\n\t\treturn null;\n\t}", "@Override\r\n\tpublic Book update(Book book) {\r\n\t\treturn null;\r\n\t}", "@Override\n\tpublic Boolean updateDocument(Document document) {\n\t\treturn null;\n\t}", "@Override\n\tpublic void update(ConScore it) {\n\t\tthis.getHibernateTemplate().update(it);\n\t}", "int updateByPrimaryKeySelective(Collect record);", "@Override\n\tpublic Employee update(Employee emp) {\n\t\treturn null;\n\t}", "public void updateModel() {\n\t\t// Set the mode to validation\n\t\tmode = UPDATE;\n\t\t// Traverses the source and updates the model when UML elements are\n\t\t// missing\n\t\tinspect();\n\t}", "@Writer\n int updateByPrimaryKeySelective(LuckyBag record);", "public void UpdateItem(View view) {\n /*update a friend record given the id*/\n updateFriend(friendsDatabaseReference);\n /*the alternative*/\n// updateFriend_updateChildren(friendsDatabaseReference);\n }", "@Override\n\tpublic boolean update(Order bean) {\n\t\treturn false;\n\t}", "public synchronized void edit(E object) {\n Node<E> temp = first;\n while (temp.next != null) {\n if (temp.object.equals(object)) {\n temp.object = object;\n }\n temp = temp.next;\n }\n }", "public void saveAndClear(E instance);", "@Override\n\t\tpublic void refreshBeanElement() {\n\n\t\t}", "@Override\r\n\tpublic Ressource update(Ressource obj) {\n\t\treturn null;\r\n\t}", "public void putDocumentAfterEdit() {\r\n\t\tif(pointer < strategy.getEntireHistory().size()-1) {\r\n\t\t\tstrategy.putVersion(currentDocument);\r\n\t\t}\r\n\t}", "void updateIfNeeded()\n throws Exception;", "public void update( final T model )\n\t{\n\t\tthis.dao.save( model );\n\t}", "@Override\n public void update(Restriction object) throws Exception {\n throw new UnsupportedOperationException(\"Not supported yet.\"); //To change body of generated methods, choose Tools | Templates.\n }", "public void setEditedItem(Object item) {editedItem = item;}", "@Override\n public void setChanged() {\n set(getItem());\n }", "@Override\n\tpublic void update(Recipe entity) {\n\t\t\n\t}", "public void updateAnimalList(){\r\n // if (animals != null && animals.size() > 0)\r\n // {\r\n // \r\n // }\r\n // else\r\n // {\r\n animals.clear();\r\n \r\n for (fit5042.assign.repository.entity.Animal animal : animalManagedBean.getAllAnimals())//for each animal entry in the Entity Class Animal, get all animals\r\n {\r\n animals.add(animal); //add Animal data to the ArrayList<Animal> animals\r\n }\r\n \r\n setAnimal(animals); //set the global ArrayList attribute with the local ArrayList attribute\r\n // }\r\n }", "private void actualizeazaModel() {\n model.clear();\n listaContacte.forEach((o) -> {\n model.addElement(o);\n });\n }", "public abstract void refreshItem();", "@Override\r\n\tpublic void update() {\n\t\t\r\n\t}" ]
[ "0.62621534", "0.6187503", "0.616152", "0.61045504", "0.6081199", "0.59914124", "0.594727", "0.5854143", "0.5836796", "0.5815042", "0.581126", "0.58035207", "0.5791376", "0.5786933", "0.5766283", "0.5764728", "0.5755756", "0.57506365", "0.57450336", "0.57362896", "0.57082266", "0.5691056", "0.56617165", "0.56617165", "0.5652198", "0.5644511", "0.5632468", "0.5632468", "0.560768", "0.5590203", "0.55827695", "0.5568056", "0.55659455", "0.5556416", "0.5551092", "0.5550461", "0.5527048", "0.55227095", "0.5512609", "0.5502646", "0.54921293", "0.5485508", "0.5485508", "0.5485508", "0.5474307", "0.5471207", "0.54678917", "0.54678917", "0.5461241", "0.54600036", "0.54491884", "0.5448472", "0.5433301", "0.54252446", "0.54252446", "0.5419879", "0.5414091", "0.5412503", "0.5412503", "0.54008436", "0.53999525", "0.5396655", "0.5395931", "0.5395931", "0.5384639", "0.5384035", "0.5365489", "0.5356032", "0.53543454", "0.53530335", "0.5349241", "0.5340464", "0.5334877", "0.53344315", "0.5332862", "0.53246236", "0.53245074", "0.5323168", "0.5320112", "0.5310059", "0.5309032", "0.5307572", "0.53065366", "0.53012806", "0.5299472", "0.5296497", "0.52857465", "0.5281282", "0.5261656", "0.5259938", "0.52567244", "0.5252514", "0.52524745", "0.5244689", "0.5240158", "0.5239636", "0.52393717", "0.5237655", "0.52375585", "0.5234875", "0.5234832" ]
0.0
-1
Creates a new ButtonInfoMessage with the given state.
public ButtonInfoMessage(int state) { super(AbstractMessage.ButtonInfo); this.state = state; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public InfoMessage createInfoMessage();", "Button createButton();", "Button new_button (String title, ActionListener action, String tooltip) {\n Button b = new Button(title);\n b.setBackground(Color.white);\n b.setForeground(Color.blue);\n if (action != null)\n b.addActionListener(action);\n if (tooltip != null)\n b.setToolTipText(tooltip);\n return b;\n }", "private JLabel createButtonDescription() {\r\n JLabel buttonDescription = new JLabel(\"Result\");\r\n buttonDescription.setAlignmentX(Component.CENTER_ALIGNMENT);\r\n buttonDescription.setBorder(new EmptyBorder(5, 5, 5, 5));\r\n buttonDescription.setText(\"Play again?\");\r\n buttonDescription.setFont(new Font(null, Font.PLAIN, 20));\r\n return buttonDescription;\r\n }", "void create( State state );", "private Button constructCreationLinkButton(UUID creationID){\n\n CreationControllable cc = (CreationControllable) builder.getControllers()[1];\n if (!cc.containsCreation(creationID)){\n return null;\n }\n\n String[] creationInfo = cc.viewCreationSummary(creationID, viewer);\n Button b = new Button(creationInfo[0] + \" ( \" + creationInfo[1] + \" ) By: \"+ creationInfo[2]);\n\n b.setOnAction(new EventHandler<ActionEvent>() {\n @Override\n public void handle(ActionEvent event) {\n stage.close();\n CreationViewController controller = getCreationBrowserController();\n if (controller == null){\n return;\n }\n controller.linkCreationCallback(creationID);\n stage.show();\n }\n });\n\n return b;\n }", "private JButton messageButton() {\n JButton messageButton = new JButton(\"Error message\");\n messageButton.addActionListener(new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n JOptionPane.showMessageDialog(null,message);\n\n }\n\n });\n return messageButton;\n }", "public StateInfo createStateInfo() {\n return new JJStateInfo();\n }", "private Button createNewGameButton() {\n Button newGameButton = new Button(Config.NEW_GAME_BUTTON);\n newGameButton.setTranslateY(10);\n newGameButton.setTranslateX(10);\n\n // TODO: move stuff like this to the CSS resources.\n DropShadow effect = new DropShadow();\n effect.setColor(Color.BLUE);\n newGameButton.setEffect(effect);\n\n return newGameButton;\n }", "private void createButton() {\n\t\tbtnAddTask = new JButton(\"Add Task\");\n\t\tbtnSave = new JButton(\"Save\");\n\t\tbtnCancel = new JButton(\"Cancel\");\n\n\t\tbtnAddTask.addActionListener(new ToDoAction());\n\t\tbtnSave.addActionListener(new ToDoAction());\n\t\tbtnCancel.addActionListener(new ToDoAction());\n\t}", "public MessageInfo() { }", "void createButton(Button main){\n\t\tActions handler = new Actions();\r\n\t\tmain.setOnAction(handler);\r\n\t\tmain.setFont(font);\r\n\t\t//sets button preference dimensions and label \r\n\t\tmain.setPrefWidth(100);\r\n\t\tmain.setPrefHeight(60);\r\n\t\tmain.setText(\"Close\");\r\n\t}", "public void createFinishedButton() {\n\t\tJButton finished = new JButton(\"Click here when finished inputting selected champions\");\n\t\tfinished.setName(\"finished\");\n\t\tfinished.setBackground(Color.GRAY);\n\t\tfinished.setForeground(Color.WHITE);\n\t\tfinished.setBorderPainted(false);\n\t\tfinished.addActionListener(this);\n\t\tfinished.setBounds(400, 50, 400, 100);\n\t\tbottomPanel.add(finished, new Integer(4));\n\t}", "private ImageTextButton createImageTextButton(TextureRegionDrawable drawable, BitmapFont font, int number){ ;\r\n\t\tImageTextButton.ImageTextButtonStyle btnStyle1 = new ImageTextButton.ImageTextButtonStyle();\r\n\t\tbtnStyle1.up = drawable;\r\n\t\tbtnStyle1.font = font;\r\n\t\tImageTextButton btn = new ImageTextButton(\"\"+number, btnStyle1);\r\n\t\treturn btn;\r\n\t}", "private void buildInfoPanel() {\r\n infoPanel = new JPanel( new GridLayout( 1, 1 ) );\r\n infoBox = Box.createHorizontalBox();\r\n\r\n // setBackground() does NOT work with a Box\r\n infoPanel.setBackground( COLOR_INFO_BKGRND );\r\n\r\n soundBtn = new JButton( Msgs.str( \"Snd.go\" ) );\r\n soundBtn.addActionListener( listener );\r\n infoBox.add( Box.createGlue() );\r\n infoBox.add( soundBtn );\r\n\r\n resetBtn = new JButton( Msgs.str( \"Reset\" ) );\r\n resetBtn.addActionListener( listener );\r\n infoBox.add( Box.createGlue() );\r\n infoBox.add( resetBtn );\r\n\r\n infoMesg = new JLabel( Msgs.str( \"Ready\" ), SwingConstants.CENTER );\r\n infoMesg.setFont( fontLARGE );\r\n infoMesg.setForeground( COLOR_INFO_FRGRND );\r\n infoBox.add( Box.createGlue() );\r\n infoBox.add( infoMesg );\r\n infoBox.add( Box.createGlue() );\r\n\r\n infoPanel.add( infoBox );\r\n }", "private void initCreateDeckBtn() {\n createBtn = new Button((editWidth - 310) / 2, 400, \"CREATE NEW DECK\", MasterGUI.green, titleField.getWidth(), titleField.getHeight());\n createBtn.setFont(MasterGUI.poppinsFont);\n createBtn.setForeground(MasterGUI.white);\n createBtn.setContentAreaFilled(true);\n createBtn.setFocusPainted(false);\n ActionListener createAction = new ActionListener() {\n @Override\n public void actionPerformed(ActionEvent e) {\n createDeckFromInput();\n user.updateDeckList();\n repaintDeckCards();\n HomeView.repaintHomeView();\n }\n };\n createBtn.addActionListener(e -> {\n MainGUI.confirmDialog(createAction, \"Create new Deck?\");\n });\n editPanel.add(createBtn);\n }", "public InformationBox(String s, boolean hasButton) {\n initRoot();\n // create two labels\n Label info = new Label(s);\n info.setAlignment(Pos.CENTER);\n root.getChildren().addAll(info);\n if (hasButton) {\n initButtons();\n } else {\n yes = new Button(\"OK\");\n yes.setOnAction(event -> {\n stage.close();\n });\n root.getChildren().addAll(yes);\n }\n\n initStage();\n }", "public Button(){\n id=1+nbrButton++;\n setBounds(((id-1)*getDimX())/(Data.getNbrLevelAviable()+1),((id-1)*getDimY())/(Data.getNbrLevelAviable()+1),getDimX()/(2*Data.getNbrLevelAviable()),getDimY()/(2*Data.getNbrLevelAviable()));\n setText(id+\"\");\n setFont(Data.getFont());\n addMouseListener(this);\n setVisible(true);\n }", "public void makeReceiveButton() {\r\n JButton receive = new JButton(\"Receive a new champion recommendation\");\r\n new Button(receive, main);\r\n// receive.setAlignmentX(Component.LEFT_ALIGNMENT);\r\n// receive.setPreferredSize(new Dimension(2500, 100));\r\n// receive.setFont(new Font(\"Arial\", Font.PLAIN, 40));\r\n receive.addActionListener(new ActionListener() {\r\n @Override\r\n public void actionPerformed(ActionEvent e) {\r\n receiveChampionRecommendation();\r\n }\r\n });\r\n// main.add(receive);\r\n }", "public JComponent createBottomPanel() {\n\t\tJButton[] buttons = new JButton[0];\n\t/*\tbuttons[0] = new JButton(\"Save\");\n\t\tbuttons[0].setActionCommand(\"0\");\n\t\tbuttons[1] = new JButton(\"Cancel\");\n\t\tbuttons[1].setActionCommand(\"1\");*/\n\t\tActionHandler actHand = new ActionHandler();\n\t//\tfields[PRODUCT_NAME].addActionListener(actHand);\n\t\treturn new ButtonAndMessagePanel(buttons, messageLabel, actHand);\n\t}", "private JButton addOKButtonTopic(){\n\t\tJButton okButton = new JButton(\"OK\");\n\n\t\tokButton.addActionListener(arg0 -> {\n\t\t\tSystem.out.println(\"hello\"+ passwordT.getText()+\"hello\");\n\t\t\tinfo = new ChannelInfo(nameT.getText(), passwordT.getText(), topicT\n\t\t\t\t\t.getText());\n\t\t\tsetVisible(false);\n\t\t});\n\t\treturn okButton;\n\t}", "private JButton makeButton(String action, String label, int x, int y, int width, int height,\r\n float alignment, String soundName) {\r\n JButton button = new JButton(label);\r\n button.setBounds(x, y, width, height);\r\n button.setAlignmentX(alignment);\r\n button.setBackground(Color.ORANGE);\r\n clickActionListener(button, action, soundName);\r\n return button;\r\n }", "public static JButton createButton(String text) {\n return new JButton(text);\n }", "public ButtonRecord(\n int characterId, int placeDepth, Matrix placeMatrix, boolean upState,\n boolean overState, boolean downState, boolean hitState) {\n if (!(upState || overState || downState || hitState)) {\n throw new IllegalArgumentException(\n \"At least one of the button state flags must be set!\");\n }\n this.characterId = characterId;\n this.placeDepth = placeDepth;\n this.placeMatrix = placeMatrix;\n this.upState = upState;\n this.overState = overState;\n this.downState = downState;\n this.hitState = hitState;\n }", "public void createNoBanButton() {\n\t\tnoban = new JButton(\"Click here if the current team missed a ban\");\n\t\tnoban.setName(\"noban\");\n\t\tnoban.setBackground(Color.GRAY);\n\t\tnoban.setForeground(Color.WHITE);\n\t\tnoban.setBorderPainted(false);\n\t\tnoban.addActionListener(this);\n\t\tnoban.setBounds(400, 50, 400, 100);\n\t\tbottomPanel.add(noban, new Integer(1));\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString() + \" -Button pressed! \" + state;\n\t}", "private JButton createBookButton() {\n\t\tfinal JButton bookButton = new JButton(\"Create Booking\");\n\n\t\tbookButton.addActionListener(new ActionListener() {\n\n\t\t\t@Override\n\t\t\tpublic void actionPerformed(final ActionEvent e) {\n\t\t\t\thandleBooking();\n\t\t\t}\n\t\t});\n\n\t\treturn bookButton;\n\t}", "public Info(String text, boolean warning)\n {\n super(text, warning, 250, 500);\n \n try {\n File path;\n if(warning){\n path = new File(\"warning.png\");\n }else{\n path = new File(\"info.png\");\n }\n java.awt.Image icon = ImageIO.read(path);\n f.setIconImage(icon);\n } catch (Exception e) {}\n \n ok = new IFButton(100,40,200,125,\"Ok\");\n ok.setFont(new Font(\"Dosis\", Font.BOLD, 18));\n ok.setCornerRadius(1);\n \n ok.addMouseListener(new MouseListener()\n { \n public void mouseClicked(MouseEvent e){}\n \n public void mouseExited(MouseEvent e){\n ok.setColor(new Color(10,30,100));\n }\n \n public void mousePressed(MouseEvent e){\n ok.animCR(3, 0.2);\n }\n \n public void mouseEntered(MouseEvent e){\n ok.setColor(new Color(40,50,140));\n }\n \n public void mouseReleased(MouseEvent e){\n ok.animCR(1, -0.2);\n }\n });\n \n setButtons(new IFButton[]{ok});\n \n if(warning){\n f.setTitle(\"Warnung!\");\n }else{\n f.setTitle(\"Info\"); \n }\n }", "public String getMessageButton() {\n return messageButton;\n }", "private JButton getJButton() {\n\t\tif (new_button == null) {\n\t\t\tnew_button = new JButton();\n\t\t\tnew_button.setText(Locale.getString(\"NEW\"));\n\t\t\tnew_button.setMnemonic(java.awt.event.KeyEvent.VK_N);\n\t\t\tnew_button.addActionListener(new java.awt.event.ActionListener() { \n\t\t\t\tpublic void actionPerformed(java.awt.event.ActionEvent e) { \n\t\t\t\t\tSystem.out.println(\"actionPerformed()\"); // TODO Auto-generated Event stub actionPerformed()\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\t\treturn new_button;\n\t}", "private JButton addOKButton(){\n\t\tJButton okButton = new JButton(\"OK\");\n\t\tokButton.addActionListener(arg0 -> {\n\t\t\tinfo = new ChannelInfo(nameT.getText(), passwordT.getText(), null);\n\t\t\tsetVisible(false);\n\t\t});\n\t\treturn okButton;\n\t}", "private JPanel initButtonPanel() {\n JPanel buttonPanel = new JPanel();\n buttonPanel.setLayout(new FlowLayout(SwingUtilities.HORIZONTAL));\n\n completeButton = new JButton(new AbstractAction(\"Complete\") {\n\n @Override\n public void actionPerformed(ActionEvent e) {\n task.setStatus(TaskStatus.COMPLETED);\n dialog.setVisible(false);\n }\n });\n buttonPanel.add(completeButton);\n\n closeButton = new JButton(new AbstractAction(\"Close\") {\n\n @Override\n public void actionPerformed(ActionEvent e) {\n dialog.setVisible(false);\n }\n });\n buttonPanel.add(closeButton);\n\n return buttonPanel;\n }", "private PopupActionButton createActionButton(String buttonTitle, ViewGroup buttonLayout) {\n Timber.d(\"Creating Popup button with title: \" + buttonTitle);\n PopupActionButton actionButton = new PopupActionButton(mActivity);\n actionButton.setTitle(buttonTitle);\n buttonLayout.addView(actionButton, actionButton.getLayoutParams());\n return actionButton;\n }", "public Button createButton(String text, Color color) {\n final String texthere = text;\n Button.ButtonStyle style = new Button.ButtonStyle();\n style.up = skin.getDrawable(text);\n style.down = skin.getDrawable(text);\n\n Button button = new Button(style);\n// button.s(1000,1000);\n button.pad(50);\n button.addListener(new InputListener() {\n public boolean touchDown(InputEvent event, float x, float y,\n int pointer, int button) {\n\n return true;\n }\n\n public void touchUp(InputEvent event, float x, float y,\n int pointer, int button) {\n if (texthere.equals(\"play\"))\n game.setScreen(new Person_Comp(game));\n else if (texthere.equals(\"multi\"))\n game.setScreen(new Multiplayer(game));\n else {\n }\n// game.setScreen(new Settings(game));\n }\n\n });\n return button;\n }", "@Override\n public Button createButton() {\n return new WindowsButton();\n }", "private void createButton() {\n this.setIcon(images.getImageIcon(fileName + \"-button\"));\n this.setActionCommand(command);\n this.setPreferredSize(new Dimension(width, height));\n this.setMaximumSize(new Dimension(width, height));\n }", "public static MenuBox createLabelledButton(float btX, float btY, float btW, float btH, String text, OnClick btAction, TextureRegion pressed, TextureRegion unpressed, Array<BitmapFontCache> fontCaches, int pickedFont){\n MenuBox out = new MenuBox(btX,btY,btW,btH,fontCaches);\n Button actionButton = new Button(0,0,btW,btH);\n actionButton.setCallback(btAction);\n actionButton.setPressedTexture(pressed);\n actionButton.setUnpressedTexture(unpressed);\n out.addButton(actionButton);\n QueueText textLabel = new QueueText((btW/2)-(textWidth(fontCaches.get(pickedFont).getFont(),text)/2),(btH/2)+(textHeight(fontCaches.get(pickedFont).getFont(),text)/2),0,0);\n textLabel.setText(text,fontCaches);\n out.addQueueText(textLabel);\n return out;\n }", "@Override\n\tpublic Button createButton() {\n\t\treturn new HtmlButton();\n\t}", "private void createButton() throws SlickException {\n int width = 25*getGameContainer().getWidth()/100;\n int height = 10*getGameContainer().getHeight()/100;\n\n Image login = new Image(getReaderXmlFile().read(\"buttonLogin\")).getScaledCopy(width, height);\n Coordinate posLogin = new Coordinate((getGameContainer().getWidth() - login.getWidth())/2,55*getGameContainer().getHeight()/100);\n loginButton = new Button(getGameContainer(), login, posLogin, IDStates.MENU_STATE, this);\n\n Image account = new Image(getReaderXmlFile().read(\"buttonAccount\")).getScaledCopy(width, height);\n Coordinate posAccount = new Coordinate((getGameContainer().getWidth() - account.getWidth())/2,70*getGameContainer().getHeight()/100);\n accountButton = new Button(getGameContainer(), account, posAccount, IDStates.MENU_STATE, this);\n }", "public ActionState createActionState();", "private void initButton(Button button, String tekst, String styleClass, int columnIndex,\n int rowIndex, float sizeX, float sizeY) {\n button.setText(tekst);\n button.getStyleClass().add(styleClass);\n button.setMinWidth(sizeX);\n button.setMinHeight(sizeY);\n this.buttonGrid.add(button, columnIndex, rowIndex);\n }", "public void createInstructionButton() {\n \tEventHandler<MouseEvent> eventHandler = new EventHandler<MouseEvent>() {\n\t @Override public void handle(MouseEvent e) {\n\t \tshowInstructions();}\n };\n \tcreateGenericButton(2, 0, myResources.getString(\"guide\"), eventHandler);\n }", "JButton createTranslateButton(ParagraphTranslateGUI app) {\n ImageIcon translateIcon = new ImageIcon(\"resources/TranslateButton.png\");\n translateButton = new JButton(resizeIcon(translateIcon, this.width, this.height));\n translateButton.setBounds(this.posX, this.posY, this.width, this.height);\n\n addMouseListener(app);\n\n return translateButton;\n }", "private void createButton(){\n addButton();\n addStartButton();\n }", "@Override\n\tprotected Button createPushButton(Composite parent, String label, Image image) {\n\t\treturn super.createPushButton(parent, label, image);\n\t}", "public DialogHolder(String text, int state) {\n\t\tthis.text = text;\n\t\tthis.state = state;\n\t}", "private void createJButtonActionPerformed( ActionEvent event )\r\n {\r\n \r\n }", "Button(int x, int y, int w, int h, String label, int c){\n this.x = x;\n this.y = y;\n this.w = w;\n this.h = h;\n this.label = label;\n this.col = c;\n }", "private void updateButtonStateEpson(boolean state) {\n }", "public static Button createButton(String btnValue) {\n\t\tButton btn = new Button(btnValue);\n\t\tbtn.setFont(Font.font(\"Arial\", 20));\n\t\treturn btn;\n\t}", "private JButton makeNewMazeButton()\n {\n JButton newMaze = new JButton(\"New Maze\");\n newMaze.setToolTipText(\"Create a new maze\");\n newMaze.addActionListener(new ActionListener()\n {\n @Override\n public void actionPerformed(ActionEvent e)\n {\n newMaze();\n }\n });\n return newMaze;\n }", "@Override\n\tprotected void buildButton() {\n\t\t\n\t}", "public void setNewButtonText(String text) {\n/*Generated! Do not modify!*/ replyDTO.getVariablesToSet().add(\"overviewSmall_newButton_propertyText\");\n/*Generated! Do not modify!*/ if (text == null) {\n/*Generated! Do not modify!*/ replyDTO.getVariableValues().remove(\"overviewSmall_newButton_propertyText\");\n/*Generated! Do not modify!*/ } else {\n/*Generated! Do not modify!*/ replyDTO.getVariableValues().put(\"overviewSmall_newButton_propertyText\", text);\n/*Generated! Do not modify!*/ }\n/*Generated! Do not modify!*/ if (recordMode){\n/*Generated! Do not modify!*/ addRecordedAction(\"setNewButtonText(\" + escapeString(text) + \");\");\n/*Generated! Do not modify!*/ }\n/*Generated! Do not modify!*/ }", "private Button createButton(String name, int fontSize, int cornerSize) {\n Button button = new Button(name);\n button.setFont(Font.font(fontSize));\n button.setMinWidth(BUTTON_WIDTH);\n button.setMaxWidth(Double.MAX_VALUE);\n button.setBackground(new Background(new BackgroundFill(\n Color.SEASHELL, new CornerRadii(cornerSize), null)));\n return button;\n }", "private void setMsgButton(final String extId, final String nickname){\n\t\tButton newMessage = (Button) findViewById(R.id.logout);\n\t BeButton b = new BeButton(context);\n\t newMessage.setShadowLayer(0.1f, 0, -2.0f, Color.BLACK);\n\t newMessage.setVisibility(LinearLayout.VISIBLE);\n\t newMessage.setText(context.getString(R.string.messagesend));\n\t newMessage.setBackgroundDrawable(\n\t \t\tb.setPressedBackg(\n\t\t\t \t\tnew BDrawableGradient(0,(int) (ratio*50),BDrawableGradient.BLU_BUTTON_GRADIENT),\n\t\t\t\t\t\tnew BDrawableGradient(0,(int) (ratio*50),BDrawableGradient.BLU_ROLL_BUTTON_GRADIENT),\n\t\t\t\t\t\tnew BDrawableGradient(0,(int) (ratio*50),BDrawableGradient.BLU_ROLL_BUTTON_GRADIENT)));\t\t\t \t \n\t newMessage.setOnClickListener(new Button.OnClickListener(){\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tMessagesWrite mw = new MessagesWrite(context);\n\t\t\t\tmw.setToExtId(extId);\n\t\t\t\tmw.setToNickname(nickname);\n\t\t\t\tmw.show();\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t}\n\t\t});\n\t}", "DynamicMessage createDynamicMessage();", "public JButton makeNavigationButton(String actionCommand, String toolTipText,String altText) \r\n {\n JButton button = new JButton();\r\n button.setActionCommand(actionCommand);\r\n button.setToolTipText(toolTipText);\r\n button.addActionListener(this);\r\n\r\n //no image found\r\n button.setText(altText);\r\n return button;\r\n }", "public static Button help(String texturePrefix) {\n return new Button(\n new Vector2(0, 0),\n texturePrefix + activeSuffix,\n texturePrefix + inactiveSuffix\n );\n }", "private static JButton buttonMaker(String s){\n final JButton button;\n button = new JButton(new ImageIcon(iconMaker(s)));\n button.setFocusPainted(false);\n return button;\n }", "protected AbstractButton createToolBarButton(String iconName, String toolTipText) {\r\n JButton button = new JButton(readImageIcon(iconName));\r\n button.setToolTipText(toolTipText);\r\n button.setFocusable(false);\r\n return button;\r\n }", "public JButton createJButton(String name) throws MissingResourceException, ResourceFormatException, MissingListenerException {\n/* 111 */ return this.buttonFactory.createJToolbarButton(name);\n/* */ }", "public Tile(String num, int boardSize)\n {\n this.num = num;\n this.color = \"GREEN\";\n button.setText(\"_\");\n button.addActionListener(new ActionListener() {\n\n @Override\n public void actionPerformed(ActionEvent arg) {\n if(occupied != true) {\n System.out.println(num);//print which button was clicked\n occupied = true; //make the button register itself as clicked so the game can see it has happened\n //close();//closing the button makes it unable to have text... not sure why\n //button.setBackground(Color.RED); coloring the buttons also seems to not work for ome reason...\n //button.setOpaque(true); ^\n //button.setBorderPainted(false); ^\n button.setText(\"♘⦻♞_\"); //sets the text of the button to a default of all possible text values\n //if the tile has already been occupied then it will do nothing when clicked\n }\n }\n });\n\n //this.button.addActionListener(this);\n }", "public ButtonComponentSwing(final Button button)\n {\n super(new GridLayout(2, 1));\n\n this.button = button;\n this.button.getJoystick().registerJoystickListener(this);\n\n this.nameEditText = new JTextField(16);\n this.nameEditText.setFont(JHelpConstantsSmooth.FONT_DISPLAY_1.getFont());\n this.nameEditText.setForeground(Color.BLACK);\n this.nameEditText.setBackground(Color.WHITE);\n this.nameEditText.setCaretColor(Color.RED);\n this.nameEditText.addInputMethodListener(this);\n\n this.stateText = new JLabel(\"UP\", SwingConstants.CENTER);\n this.stateText.setFont(JHelpConstantsSmooth.FONT_DISPLAY_1.getFont());\n\n this.add(this.nameEditText);\n this.add(this.stateText);\n\n this.update();\n }", "public Button addButton(ButtonID buttonId) {\n\t\tfinal Button b = new Button();\n\t\tb.setText(buttonId.title);\n\t\tif (buttonId.icon != null)\n\t\t\tb.setGraphic(new ImageView(buttonId.icon));\n\t\tswitch (buttonId) {\n\t\tcase OK:\n\t\t\tb.setOnAction(new EventHandler<ActionEvent>() {\n\t\t\t\t@Override\n\t\t\t\tpublic void handle(final ActionEvent event) {\n\t\t\t\t\thandleOk(event);\n\t\t\t\t}\n\t\t\t});\n\t\t\t// TODO fix problematic NPE on VK_ENTER press\n\t\t\t// b.setDefaultButton(true);\n\t\t\tbreak;\n\t\tcase CANCEL:\n\t\t\tb.setOnAction(new EventHandler<ActionEvent>() {\n\t\t\t\t@Override\n\t\t\t\tpublic void handle(final ActionEvent event) {\n\t\t\t\t\thandleCancel(event);\n\t\t\t\t}\n\t\t\t});\n\t\t\tbreak;\n\t\tcase NEXT:\n\t\t\tb.setOnAction(new EventHandler<ActionEvent>() {\n\t\t\t\t@Override\n\t\t\t\tpublic void handle(final ActionEvent event) {\n\t\t\t\t\thandleNext(event);\n\t\t\t\t}\n\t\t\t});\n\t\t\tbreak;\n\t\tcase BACK:\n\t\t\tb.setOnAction(new EventHandler<ActionEvent>() {\n\t\t\t\t@Override\n\t\t\t\tpublic void handle(final ActionEvent event) {\n\t\t\t\t\thandleBack(event);\n\t\t\t\t}\n\t\t\t});\n\t\t\tbreak;\n\t\tcase HELP:\n\t\t\tb.setOnAction(new EventHandler<ActionEvent>() {\n\t\t\t\t@Override\n\t\t\t\tpublic void handle(final ActionEvent event) {\n\t\t\t\t\thandleHelp(event);\n\t\t\t\t}\n\t\t\t});\n\t\t\tbreak;\n\t\t}\n\t\torderedButtonList.add(b);\n\t\tbuttons.put(buttonId, b);\n\t\treturn b;\n\t}", "public TranslateButton() {\n this.posX = 0;\n this.posY = 0;\n this.width = 0;\n this.height = 0;\n translateButton = new JButton();\n }", "public JButton createButton(String name, String toolTip) {\r\n\r\n // load the image\r\n String imagePath = \"./resources/\" + name + \".png\";\r\n ImageIcon iconRollover = new ImageIcon(imagePath);\r\n int w = iconRollover.getIconWidth();\r\n int h = iconRollover.getIconHeight();\r\n\r\n // get the cursor for this button\r\n Cursor cursor =\r\n Cursor.getPredefinedCursor(Cursor.HAND_CURSOR);\r\n\r\n // make translucent default image\r\n Image image = createCompatibleImage(w, h,\r\n Transparency.TRANSLUCENT);\r\n Graphics2D g = (Graphics2D)image.getGraphics();\r\n Composite alpha = AlphaComposite.getInstance(\r\n AlphaComposite.SRC_OVER, .5f);\r\n g.setComposite(alpha);\r\n g.drawImage(iconRollover.getImage(), 0, 0, null);\r\n g.dispose();\r\n ImageIcon iconDefault = new ImageIcon(image);\r\n\r\n // make a pressed image\r\n image = createCompatibleImage(w, h,\r\n Transparency.TRANSLUCENT);\r\n g = (Graphics2D)image.getGraphics();\r\n g.drawImage(iconRollover.getImage(), 2, 2, null);\r\n g.dispose();\r\n ImageIcon iconPressed = new ImageIcon(image);\r\n\r\n // create the button\r\n JButton button = new JButton();\r\n button.addActionListener(this);\r\n button.setIgnoreRepaint(true);\r\n button.setFocusable(false);\r\n button.setToolTipText(toolTip);\r\n button.setBorder(null);\r\n button.setContentAreaFilled(false);\r\n button.setCursor(cursor);\r\n button.setIcon(iconDefault);\r\n button.setRolloverIcon(iconRollover);\r\n button.setPressedIcon(iconPressed);\r\n\r\n return button;\r\n }", "protected GuiTestObject okbutton(TestObject anchor, long flags) \n\t{\n\t\treturn new GuiTestObject(\n getMappedTestObject(\"okbutton\"), anchor, flags);\n\t}", "public GeneralMessage(Frame owner, String title, String message, String... buttonLabels) {\n super(owner, title, true);\n buttons = new JButton[buttonLabels.length];\n setLayout(new BorderLayout());\n \n JTextArea messageArea = new JTextArea(message);\n messageArea.setEditable(false);\n add(messageArea, BorderLayout.CENTER);\n \n JPanel buttonPanel = new JPanel();\n for (int i = 0; i < buttonLabels.length; i++) {\n buttons[i] = new JButton(buttonLabels[i]);\n buttons[i].addActionListener(this);\n buttonPanel.add(buttons[i], buttonPanel);\n }\n add(buttonPanel, BorderLayout.SOUTH);\n\n add(new JLabel(\" \"), BorderLayout.WEST);\n add(new JLabel(\" \"), BorderLayout.EAST);\n pack();\n setVisible(true);\n }", "public static Button new_button(String text, int x, int y, int width, int height, String color){\n Button button = new Button(text);\n button.setLayoutX(x);\n button.setLayoutY(y);\n button.setPrefWidth(width);\n button.setPrefHeight(height);\n button.setStyle(color);\n return button;\n }", "protected MessageInfo buildMessageInfo(NotificationContext ctx) {\n AbstractTemplateBuilder templateBuilder = getTemplateBuilder();\n if (templateBuilder == null) {\n templateBuilder = getTemplateBuilder(ctx);\n }\n MessageInfo massage = templateBuilder.buildMessage(ctx);\n assertNotNull(massage);\n return massage;\n }", "private Button buttonFormat(String label, int color) {\n Button newButton = new Button(label);\n newButton.setFont(new Font(\"Arial\", 15));\n String styles = \"-fx-padding: 5;\" + \"-fx-border-width: 3px;\";\n\n if (color == 1)\n styles = styles + \"-fx-background-color: #DFB951; \"; // yellow\n else if (color == 2)\n styles = styles + \"-fx-background-color: #00ff00; \"; // green\n\n newButton.setStyle(styles);\n return newButton;\n }", "protected abstract Message createMessage(Object object, MessageProperties messageProperties);", "private ImageButton generateItemButton(Texture image) {\n\t\tTextureRegion imgRegion = new TextureRegion(image);\n\t\tTextureRegionDrawable imgDraw = new TextureRegionDrawable(imgRegion);\n\t\treturn new ImageButton(imgDraw);\n\t}", "public DialogInfo(Activity activity) {\n super(activity);\n\n // Hide all elements on load.\n mInfoText .setVisibility(View.GONE);\n mInfoLButton.setVisibility(View.GONE);\n mInfoRButton.setVisibility(View.GONE);\n\n // Get pixel values of button dimensions.\n int buttonHeight = ReflectionHelper.densityPixelsToPixels(mActivity, 60);\n int buttonWidth = ReflectionHelper.densityPixelsToPixels(mActivity, 295);\n int buttonWidthSmall = ReflectionHelper.densityPixelsToPixels(mActivity, 145);\n\n // Create supported button sizes.\n mButtonLp = new LinearLayout.LayoutParams(buttonWidth, buttonHeight);\n mButtonLpSmall = new LinearLayout.LayoutParams(buttonWidthSmall, buttonHeight);\n\n // Can touch and dismiss.\n setTouchable(true);\n setDismissible(true);\n }", "protected Button createCustomButton(Composite parent, String label) {\n\t\t((GridLayout) parent.getLayout()).numColumns++;\r\n\t\tButton button = new Button(parent, SWT.PUSH);\r\n\t\tbutton.setText(label);\r\n\t\tbutton.setFont(JFaceResources.getDialogFont());\r\n\r\n\t\tbutton.addSelectionListener(new SelectionAdapter() {\r\n\t\t\tpublic void widgetSelected(SelectionEvent event) {\r\n\t\t\t\t//buttonPressed(((Integer) event.widget.getData()).intValue());\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\tsetButtonLayoutData(button);\r\n\t\treturn button;\r\n\t}", "public void clickOnCreateButton() {\n\t\twaitForElement(createButton);\n\t\tclickOn(createButton);\n\t}", "public String build() {\n this.message_string = \"{\";\n\n if (this.recipient_id != null) {\n this.message_string += \"\\\"recipient\\\": {\\\"id\\\": \\\"\" + this.recipient_id + \"\\\"},\";\n }\n\n if ((this.message_text != null)\n && !(this.message_text.equals(\"\"))\n && !(this.buttons.isEmpty())) {\n this.message_string += \"\\\"message\\\": {\";\n this.message_string += \"\\\"attachment\\\": {\";\n this.message_string += \"\\\"type\\\": \\\"template\\\",\";\n this.message_string += \"\\\"payload\\\": {\";\n this.message_string += \"\\\"template_type\\\": \\\"button\\\",\";\n this.message_string += \"\\\"text\\\": \\\"\" + this.message_text + \"\\\",\";\n this.message_string += \"\\\"buttons\\\":[\";\n for (int j = 0; j < this.buttons.size(); j++) {\n HashMap<String, String> button = this.buttons.get(j);\n this.message_string += \"{\";\n if (!button.get(\"type\").equals(\"\")) {\n this.message_string += \"\\\"type\\\":\\\"\" + button.get(\"type\") + \"\\\",\";\n }\n if (!button.get(\"title\").equals(\"\")) {\n this.message_string += \"\\\"title\\\":\\\"\" + button.get(\"title\") + \"\\\",\";\n }\n if (!button.get(\"url\").equals(\"\")) {\n this.message_string += \"\\\"url\\\":\\\"\" + button.get(\"url\") + \"\\\",\";\n }\n if (!button.get(\"payload\").equals(\"\")) {\n this.message_string += \"\\\"payload\\\":\\\"\" + button.get(\"payload\") + \"\\\",\";\n }\n if (!button.get(\"webview_height_ratio\").equals(\"\")) {\n this.message_string +=\n \"\\\"webview_height_ratio\\\":\\\"\"\n + button.get(\"webview_height_ratio\")\n + \"\\\",\";\n }\n this.message_string = this.message_string.replaceAll(\",$\", \"\");\n this.message_string += \"},\";\n }\n this.message_string = this.message_string.replaceAll(\",$\", \"\");\n this.message_string += \"]\";\n this.message_string += \"}\";\n this.message_string += \"}\";\n this.message_string += \"}\";\n }\n\n this.message_string = this.message_string.replaceAll(\",$\", \"\");\n\n this.message_string += \"}\";\n\n return this.message_string;\n }", "private BButton getBtnOK() {\r\n\t\tif (btnOK == null) {\r\n\t\t\tbtnOK = new BButton();\r\n\t\t\tbtnOK.setText(\"OK\");\r\n\t\t\tbtnOK.setPreferredSize(new Dimension(100, 29));\r\n\t\t}\r\n\t\treturn btnOK;\r\n\t}", "public void buildAndShow(String p_Message, String p_Title, String p_PositiveButton, String p_NegativeButton){\r\n AlertDialog.Builder builder = new AlertDialog.Builder(getParameter());\r\n builder.setMessage(p_Message)\r\n .setTitle(p_Title);\r\n builder.setPositiveButton(p_PositiveButton, new DialogInterface.OnClickListener() {\r\n public void onClick(DialogInterface dialog, int id) {\r\n onClickPositive();\r\n }\r\n });\r\n builder.setNegativeButton(p_NegativeButton, new DialogInterface.OnClickListener() {\r\n public void onClick(DialogInterface dialog, int id) {\r\n onClickNegative();\r\n }\r\n });\r\n AlertDialog dialog = builder.create();\r\n dialog.show();\r\n }", "public void makeObtainButton() {\r\n JButton obtain = new JButton(\"Obtain a new champion using Riot Points\");\r\n new Button(obtain, main);\r\n// obtain.setAlignmentX(Component.LEFT_ALIGNMENT);\r\n// obtain.setPreferredSize(new Dimension(2500, 100));\r\n// obtain.setFont(new Font(\"Arial\", Font.PLAIN, 40));\r\n obtain.addActionListener(new ActionListener() {\r\n @Override\r\n public void actionPerformed(ActionEvent e) {\r\n obtainChampionUsingRiotPoints();\r\n }\r\n });\r\n// main.add(obtain);\r\n }", "public final com.francetelecom.admindm.model.Parameter createState()\n\t\t\tthrows Fault {\n\t\tcom.francetelecom.admindm.model.Parameter param;\n\t\tparam = data.createOrRetrieveParameter(basePath + \"State\");\n\t\tparam.setNotification(0);\n\t\tparam.setStorageMode(StorageMode.DM_ONLY);\n\t\tparam.setActiveNotificationDenied(true);\n\t\tparam.setType(ParameterType.STRING);\n\t\tparam.setValue(\"\");\n\t\tString[] values = { \"Running\", \"Sleeping\", \"Stopped\", \"Idle\",\n\t\t\t\t\"Uninterruptible\", \"Zombie\", };\n\t\tparam.addCheck(new CheckEnum(values));\n\t\tparam.setWritable(false);\n\t\treturn param;\n\t}", "private JToggleButton createJToggleButton(String name, ImageIcon image) {\n\t\t// Create new JToggleButton.\n\t\tJToggleButton button = new JToggleButton();\n\t\tbutton.setName(name);\n\n\t\t// Set action command of the new JToggleButton to be name.\n\t\tbutton.setActionCommand(name);\n\t\tbutton.setToolTipText(name);\n\n\t\t// Set icon of the action.\n\t\tbutton.setIcon(image);\n\t\tif (image != null) {\n\t\t\tDimension preferredSize = new Dimension(image.getIconWidth() + 4,\n\t\t\t\t\timage.getIconHeight() + 4);\n\t\t\tbutton.setPreferredSize(preferredSize);\n\t\t}\n\n\t\t// Add listener into the button.\n\t\tbutton.addActionListener(listener);\n\n\t\t// Put the name and button pair into the member buttonsMap;\n\t\tbuttonsMap.put(name, button);\n\n\t\t// Return the button.\n\t\treturn button;\n\t}", "public static Message createInfoMessage(String msg, long timestamp,\n\t\t\tint line, String scriptName) {\n\t\treturn new Message(INFO_MSG, msg, timestamp, line, scriptName);\n\t}", "public abstract S createWindowState();", "private JButton initializeSendButton() {\r\n\t\tJButton sendButton = new JButton(\"Send\");\r\n\t\tsendButton.addActionListener(new ActionListener() {\r\n\t\t\tpublic void actionPerformed(ActionEvent e) {\r\n\t\t\t\t// send message which taken from text field.\r\n\t\t\t\ttry {\r\n\t\t\t\t\tnotifyMessageFromUI();\r\n\t\t\t\t\tchatArea.append(messageField.getText() + \"\\n\");\r\n\t\t\t\t\tmessageField.setText(\"\");\r\n\t\t\t\t} catch (IOException e1) {\r\n\t\t\t\t\te1.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t});\r\n\t\treturn sendButton;\r\n\t}", "private Button buildCommandLinkButton(DialogAction commandLink, final int longMessageMinHeight, double maxHeight) \n {\n final Button button = new Button();\n button.getStyleClass().addAll(\"command-link-button\");\n button.setMaxHeight(maxHeight);\n button.setMaxWidth(Double.MAX_VALUE);\n button.setAlignment(Pos.CENTER_LEFT);\n \n final Label titleLabel = new Label(commandLink.getText() );\n titleLabel.minWidthProperty().bind(new DoubleBinding() {\n {\n bind(titleLabel.prefWidthProperty());\n }\n \n @Override protected double computeValue() {\n return titleLabel.getPrefWidth() + 400;\n }\n });\n titleLabel.getStyleClass().addAll(\"line-1\");\n titleLabel.setWrapText(true);\n titleLabel.setAlignment(Pos.TOP_LEFT);\n GridPane.setVgrow(titleLabel, Priority.NEVER);\n\n Label messageLabel = new Label(commandLink.getLongText() );\n messageLabel.setMinHeight(longMessageMinHeight);\n messageLabel.setPrefHeight(longMessageMinHeight + 10);\n //messageLabel.setMaxHeight(longMessageMaxHeight);\n messageLabel.getStyleClass().addAll(\"line-2\");\n messageLabel.setWrapText(true);\n messageLabel.setAlignment(Pos.TOP_LEFT);\n messageLabel.setMaxHeight(Double.MAX_VALUE);\n // GridPane.setVgrow(messageLabel, Priority.SOMETIMES);\n GridPane.setVgrow(messageLabel, Priority.ALWAYS);\n \n Node graphic = commandLink.getGraphic();\n Node view = graphic == null? new ImageView( DialogResources.getImage(\"command.link.icon\")) : graphic;\n Pane graphicContainer = new Pane(view);\n graphicContainer.getStyleClass().add(\"graphic-container\");\n GridPane.setValignment(graphicContainer, VPos.TOP);\n GridPane.setMargin(graphicContainer, new Insets(0,10,0,0));\n \n GridPane grid = new GridPane();\n grid.minWidthProperty().bind(titleLabel.prefWidthProperty());\n grid.setMaxHeight(Double.MAX_VALUE);\n grid.setMaxWidth(Double.MAX_VALUE);\n grid.getStyleClass().add(\"container\");\n grid.add(graphicContainer, 0, 0, 1, 2);\n grid.add(titleLabel, 1, 0);\n grid.add(messageLabel, 1, 1);\n\n button.setGraphic(grid);\n button.minWidthProperty().bind(titleLabel.prefWidthProperty());\n \n return button;\n }", "public Component createNewToolItem() {\r\n Button button = new Button();\r\n gwtToolbarItem.addClasses(button);\r\n button.addStyleName(\"action-bar-tool-item\");\r\n return button;\r\n }", "public InfoDialog() {\r\n\t\tcreateContents();\r\n\t}", "private ButtonPane()\r\n\t\t\t{ super(new String[]{\"OK\",\"Cancel\"},1,2); }", "public static ProductTypeChangeLabelActionBuilder of(final ProductTypeChangeLabelAction template) {\n ProductTypeChangeLabelActionBuilder builder = new ProductTypeChangeLabelActionBuilder();\n builder.attributeName = template.getAttributeName();\n builder.label = template.getLabel();\n return builder;\n }", "public void actionPerformed( ActionEvent event )\r\n {\r\n createJButtonActionPerformed( event );\r\n }", "public com.google.cloud.recommender.v1.RecommendationStateInfo.Builder getStateInfoBuilder() {\n bitField0_ |= 0x00000100;\n onChanged();\n return getStateInfoFieldBuilder().getBuilder();\n }", "public void setMessageInfo(String messageInfo);", "public Message build() {\n Objects.requireNonNull(transactionIdBytes);\n\n byte[] messageBytes = new byte[MESSAGE_LEN_HEADER + length];\n\n byte[] messageTypeBytes = createMessageType();\n System.arraycopy(messageTypeBytes, 0, messageBytes, MESSAGE_POS_TYPE, MESSAGE_LEN_TYPE);\n\n byte[] lengthBytes = Bytes.intToBytes(length);\n System.arraycopy(lengthBytes, 2, messageBytes, MESSAGE_POS_LENGTH, MESSAGE_LEN_LENGTH);\n\n byte[] magicCookieBytes = Bytes.intToBytes(MAGIC_COOKIE_FIXED_VALUE);\n System.arraycopy(\n magicCookieBytes, 0, messageBytes, MESSAGE_POS_MAGIC_COOKIE, MESSAGE_LEN_MAGIC_COOKIE);\n\n System.arraycopy(\n transactionIdBytes, 0, messageBytes, MESSAGE_POS_TRANSACTION_ID,\n MESSAGE_LEN_TRANSACTION_ID);\n transactionIdBytes = null;\n\n if (attributeBytes != null && attributeBytes.length > 0) {\n System.arraycopy(\n attributeBytes, 0, messageBytes, MESSAGE_LEN_HEADER, attributeBytes.length);\n attributeBytes = null;\n }\n\n return new Message(messageBytes);\n }", "public Builder setMessageInfoIDBytes(\n com.google.protobuf.ByteString value) {\n if (value == null) {\n throw new NullPointerException();\n }\n bitField0_ |= 0x00000002;\n messageInfoID_ = value;\n onChanged();\n return this;\n }", "public CustomDialog button(String buttonText, Object object, String style, String name) {\n TextButton button = new TextButton(buttonText, getSkin(), style);\n button.setName(name);\n super.button(button, object);\n return this;\n }", "@Override\r\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tif (PrintActivity.pl.getState() != PrinterClass.STATE_CONNECTED) {\r\n\t\t\t\t\tToast.makeText(\r\n\t\t\t\t\t\t\tPrintBarCodeActivity.this,\r\n\t\t\t\t\t\t\tPrintBarCodeActivity.this.getResources().getString(\r\n\t\t\t\t\t\t\t\t\tR.string.str_unconnected), 2000).show();\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\t\t\t\tString message = et_input.getText().toString();\r\n\r\n\t\t\t\tif (message.getBytes().length > message.length()) {\r\n\t\t\t\t\tToast.makeText(\r\n\t\t\t\t\t\t\tPrintBarCodeActivity.this,\r\n\t\t\t\t\t\t\tPrintBarCodeActivity.this.getResources().getString(\r\n\t\t\t\t\t\t\t\t\tR.string.str_cannotcreatebar), 2000).show();\r\n\t\t\t\t\treturn;\r\n\t\t\t\t}\r\n\t\t\t\tif (message.length() > 0) {\r\n\r\n\t\t\t\t\tbtMap = BarcodeCreater.creatBarcode(PrintBarCodeActivity.this,\r\n\t\t\t\t\t\t\tmessage, PrintService.imageWidth*8, 100, true, 1);\r\n\t\t\t\t\tiv.setImageBitmap(btMap);\r\n\t\t\t\t}\r\n\r\n\t\t\t}", "private void createSnack() {\n }", "public void makeCheckBEButton() {\r\n JButton checkBE = new JButton(\"Check if a champion can be purchased with Blue Essence\");\r\n new Button(checkBE, main);\r\n// checkBE.setAlignmentX(Component.LEFT_ALIGNMENT);\r\n// checkBE.setPreferredSize(new Dimension(2500, 100));\r\n// checkBE.setFont(new Font(\"Arial\", Font.PLAIN, 40));\r\n checkBE.addActionListener(new ActionListener() {\r\n @Override\r\n public void actionPerformed(ActionEvent e) {\r\n checkBlueEssenceBalanceDifference();\r\n }\r\n });\r\n// main.add(checkBE);\r\n }", "private Button createBigButton(String name, int fontSize, int cornerSize) {\n Button button = createButton(name, fontSize, cornerSize);\n button.setMaxHeight(Double.MAX_VALUE);\n button.wrapTextProperty().setValue(true);\n button.setTextAlignment(CENTER);\n return button;\n }" ]
[ "0.5904718", "0.5686476", "0.538725", "0.5265508", "0.52380913", "0.5201576", "0.5145923", "0.5104515", "0.5096923", "0.50783515", "0.5077101", "0.50606644", "0.50344807", "0.5018448", "0.5003571", "0.49811822", "0.4980759", "0.49518678", "0.49424046", "0.49245113", "0.4922825", "0.4922063", "0.49195483", "0.49127927", "0.49088112", "0.49076384", "0.4902812", "0.48896608", "0.48753375", "0.48586124", "0.4856649", "0.48406678", "0.48369294", "0.48364055", "0.48271036", "0.4806129", "0.47972518", "0.47959328", "0.4791231", "0.47849852", "0.47749397", "0.47437468", "0.47303328", "0.4723511", "0.47217187", "0.47089845", "0.47014654", "0.4692676", "0.46786645", "0.4676813", "0.46577358", "0.4656705", "0.46469027", "0.46407467", "0.4635374", "0.4635016", "0.46286723", "0.46242014", "0.462407", "0.4622676", "0.46180058", "0.46160766", "0.46072927", "0.46010315", "0.46009943", "0.4598202", "0.459451", "0.4588666", "0.4586918", "0.4581602", "0.45687005", "0.45637804", "0.4561397", "0.4550502", "0.4536538", "0.4532982", "0.4529545", "0.4524576", "0.45216748", "0.45199645", "0.451979", "0.4510953", "0.45030656", "0.45005497", "0.44977388", "0.4474722", "0.44744328", "0.4474097", "0.44674715", "0.44545528", "0.44538212", "0.44465762", "0.44457582", "0.44313693", "0.44249666", "0.44223946", "0.44191226", "0.441904", "0.44143993", "0.44065416" ]
0.8289038
0
Returns the state of the button.
public int getState(){ return state; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public int getButton() {\n\t\t//Check what button it is then return the value\n\t\tif (this.isLeftButton)\n\t\t\treturn 0;\n\t\telse if (this.isRightButton)\n\t\t\treturn 1;\n\t\telse if (this.isMiddleButton)\n\t\t\treturn 2;\n\t\telse\n\t\t\treturn -1;\n\t}", "public boolean getBButton() {\n\t\treturn getRawButton(B_Button);\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString() + \" -Button pressed! \" + state;\n\t}", "public boolean getBButton() {\n\t\treturn getRawButton(B_BUTTON);\n\t}", "State getState();", "State getState();", "State getState();", "State getState();", "public boolean getAButton() {\n\t\treturn getRawButton(A_Button);\n\t}", "public int getState(final Configuration configuration) {\n\t\treturn configurationToButtonMap.get(configuration).state;\n\t}", "public byte getState() {\n return myState;\n }", "public Button getButton() {\n\t\treturn button;\n\t}", "public boolean getAButton() {\n\t\treturn getRawButton(A_BUTTON);\n\t}", "public Byte getState() {\n return state;\n }", "public Byte getState() {\n return state;\n }", "public String state() {\n return this.state;\n }", "public String state() {\n return this.state;\n }", "public MouseButton getButton() {\n return GdkMouseButtonOverride.enumFor(GdkEventButton.getButton(this));\n }", "public final MouseButton getButton() {\n return button;\n }", "int getState();", "int getState();", "int getState();", "int getState();", "int getState();", "int getState();", "public State getState();", "public State getState();", "public char getState() {\n\t\treturn this.conMenu.getMenuState();\n\t}", "@Override\r\n\tpublic int buttonPressed() {\n\t\tif ( state == 0)\r\n\t\t{\r\n\t\t\tSystem.out.println(\"Total Button Pressed\");\r\n\t\t\treturn 0;\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\treturn 1;\r\n\t\t}\r\n\t}", "public Color getButtonColor(){\n\t\treturn buttonColor;\n\t}", "public String getKey() {\r\n return this.buttonKey;\r\n }", "public int getState();", "public int getState();", "public int getState();", "public int getState();", "public boolean pressed() {\n return pressed;\n }", "public synchronized EventState state() {\n return this.currentState;\n }", "public Boolean getState() {\n return state;\n }", "public boolean isPressed() {\n\t\treturn get();\n\t}", "public JoystickButton getButtonStart() {\n\t\treturn button[7];\n\t}", "public int getState() {\n return state;\n }", "public int getState() {\n return state;\n }", "public int getState() {\n return state;\n }", "public int getState() {return state;}", "public int getState() {return state;}", "public boolean getState( ) { return state; }", "public MashControlStateE GetState() {\n\n\t\tif (state == stateE.MASHING)\n\t\t{\n\t\t\treturn msc.GetState();\n\t\t}\n\n\t\tif (state == stateE.BOILING)\n\t\t{\n\t\t\treturn bc.GetState();\n\t\t}\n\t\telse\n\t\t\treturn MashControlStateE.DONE;\n\n\t}", "public Integer getState() {\r\n return state;\r\n }", "public Integer getState() {\r\n return state;\r\n }", "public boolean getButtonPressed(Button button) {\n return getButtonPressed(button.getNumber());\n }", "public int getState() {\n return state_;\n }", "public int getState() {\n return state_;\n }", "public int getState() {\n return state_;\n }", "public int getState() {\n return state_;\n }", "public int getState() {\n return state_;\n }", "public int getState(){\n return state;\n }", "public int getState() {\n return state_;\n }", "public int getState() {\n return state_;\n }", "public int getState() {\n return state_;\n }", "public int getState() {\n return state_;\n }", "public int getState() {\n return state_;\n }", "public Integer getState() {\n return state;\n }", "public Integer getState() {\n return state;\n }", "public Integer getState() {\n return state;\n }", "public Integer getState() {\n return state;\n }", "public Integer getState() {\n return state;\n }", "public Integer getState() {\n return state;\n }", "public int getState() {\n return state.getValue();\n }", "public int getState() {\n return m_state;\n }", "public int getState() {\n\t\treturn state;\n\t}", "Object getState();", "public final char getState() {\n\t\treturn _state;\n\t}", "@java.lang.Override public int getStateValue() {\n return state_;\n }", "public State getState()\r\n\t{\r\n\t\treturn this.state;\r\n\t}", "public JoystickButton getButtonB() {\n\t\treturn button[1];\n\t}", "public int getState() {\n return this.mState;\n }", "public S getCurrentState();", "public int getState() {\n \t\treturn state;\n \t}", "private State getState() {\n if (isSelected() && !isArmed()) {\n // normal black tick\n return State.SELECTED;\n } else if (isSelected() && isArmed()) {\n // don't care grey tick\n return State.OTHER;\n } else {\n // normal deselected\n return State.NOT_SELECTED;\n }\n }", "public boolean getState() {\n\t\treturn state;\n\t}", "@java.lang.Override public int getStateValue() {\n return state_;\n }", "public int getState() {\n return this.state.ordinal();\n }", "public STATE getState() {\n\t\n\t\treturn state;\n\t}", "public boolean getClicked(){\n return this.isPressed;\n }", "public boolean getButton(Button button) {\n return getButton(button.getNumber());\n }", "PowerState getState();", "public String getState() {\n return this.state;\n }", "public String getState() {\n return this.state;\n }", "public String getState() {\n return this.state;\n }", "public String getState() {\n return this.state;\n }", "public String getState() {\r\n\t\treturn state;\r\n\t}", "public String getState() {\r\n\t\treturn state;\r\n\t}", "public String getState() {\r\n\t\treturn state;\r\n\t}", "public String getState()\r\n\t{\r\n\t\treturn state;\r\n\t}", "public String getState()\r\n\t{\r\n\t\treturn state;\r\n\t}", "@Override\n\tpublic String getState() {\n\t\treturn this.state;\n\t}", "public int getState()\n {\n return m_state.getState();\n }", "public S getState() {\r\n\t\treturn state;\r\n\t}", "public T getState() {\r\n\t\treturn state;\r\n\t}", "public int getCurrentState() {\n return myState;\n }" ]
[ "0.7187315", "0.69887465", "0.6986312", "0.69289005", "0.6733343", "0.6733343", "0.6733343", "0.6733343", "0.6716379", "0.6705122", "0.66908705", "0.6667367", "0.66658473", "0.66244763", "0.66244763", "0.6583509", "0.6583509", "0.65755874", "0.65610427", "0.65534276", "0.65534276", "0.65534276", "0.65534276", "0.65534276", "0.65534276", "0.6546855", "0.6546855", "0.65345037", "0.6494067", "0.6493554", "0.6493421", "0.64818794", "0.64818794", "0.64818794", "0.64818794", "0.64778376", "0.6474542", "0.64633214", "0.6453969", "0.645258", "0.64486504", "0.64486504", "0.6448142", "0.6446549", "0.6446549", "0.64455694", "0.6440399", "0.6431855", "0.6431855", "0.6423575", "0.6422843", "0.6422671", "0.6422671", "0.6422671", "0.6422671", "0.6403008", "0.63996047", "0.63996047", "0.63996047", "0.63996047", "0.63996047", "0.6394709", "0.6394709", "0.6394709", "0.6394709", "0.6394709", "0.6394709", "0.6390765", "0.63898903", "0.63875693", "0.63873434", "0.6387083", "0.6377582", "0.6371441", "0.6363251", "0.63531417", "0.6352503", "0.63481575", "0.6346813", "0.63461864", "0.6345887", "0.63407487", "0.63374525", "0.63319594", "0.6326582", "0.632401", "0.63222307", "0.63222307", "0.63222307", "0.63222307", "0.6315964", "0.6315964", "0.6315964", "0.6314843", "0.6314843", "0.6311704", "0.6308437", "0.6300954", "0.62999004", "0.629791" ]
0.64110637
55
Calls super.toString() and adds the state of the button.
@Override public String toString() { return super.toString() + " -Button pressed! " + state; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public String toString()\n {\n return state.toString();\n }", "@Override\r\n\tpublic String toString()\r\n\t{\r\n\t\treturn state.toString();\r\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString() + \": \\\"\" + getLabel() + \"\\\"\";\n\t}", "@Override\n\tprotected void buildButton() {\n\t\t\n\t}", "@Override\r\n public String toString() {\r\n return com.butterfill.opb.util.OpbToStringHelper.toString(this);\r\n }", "@Override // com.android.settingslib.SignalIcon$State\n public void toString(StringBuilder sb) {\n super.toString(sb);\n sb.append(\",ssid=\");\n sb.append(this.ssid);\n sb.append(\",isTransient=\");\n sb.append(this.isTransient);\n sb.append(\",isDefault=\");\n sb.append(this.isDefault);\n sb.append(\",statusLabel=\");\n sb.append(this.statusLabel);\n sb.append(\",isCarrierMerged=\");\n sb.append(this.isCarrierMerged);\n sb.append(\",subId=\");\n sb.append(this.subId);\n }", "@Override\n public synchronized String toString() {\n return super.toString();\n }", "@Override\r\n public String toString() {\r\n return super.toString();\r\n }", "@Override\r\n public String toString() {\r\n return super.toString();\r\n }", "public String toString() {\r\n\treturn \"batch image builder for:\\n\\tnew state: \"/*nonNLS*/ + getNewState();\r\n}", "@Override\r\n public String toString() {\n return super.toString();\r\n }", "@Override\n public String toString() {\n return super.toString();\n }", "@Override\n public String toString() {\n return super.toString();\n }", "@Override\n public String toString() {\n return super.toString();\n }", "@Override\n public String toString() {\n return super.toString();\n }", "@Override\n public String toString() {\n return this.symbol + super.toString();\n }", "@Override\r\n\tpublic String toString() {\n\t\treturn super.toString();\r\n\t}", "@Override\r\n\tpublic String toString() {\n\t\treturn super.toString();\r\n\t}", "@Override\r\n\tpublic String toString() {\n\t\treturn super.toString();\r\n\t}", "@Override\r\n\tpublic String toString() {\n\t\treturn super.toString();\r\n\t}", "@Override\r\n\tpublic String toString() {\n\t\treturn super.toString();\r\n\t}", "@Override\r\n\tpublic String toString() {\n\t\treturn super.toString();\r\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn super.toString();\n\t}", "@Override\r\n public String toString() {\n return super.toString();\r\n }", "@Override\r\n\tpublic String toString() {\r\n\t\treturn \"State: \" + state + \" Action: \" + action + \" Path Cost: \" + pathCost + \"Parent:\\n\" + parent;\r\n\t}", "@Override\n public String toString () {\n return super.toString();\n }", "@Override\n\tpublic String toString() {\n\t\treturn (\"\"+label);\n\t}", "@Override\n\tpublic String toString() {\n\t\treturn \"New Game State\";\n\t}", "@Override\r\n\t\tpublic String toString() {\n\t\t\treturn super.toString();\r\n\t\t}", "@Override\n\tpublic String toString() {\n\t\tfinal StringBuffer buffer = new StringBuffer();\n\t\tbuffer.append(super.toString());\n\t\tbuffer.append('\\n');\n\t\tfor (final State state : getStates()) {\n\t\t\tif (initialState == state) {\n\t\t\t\tbuffer.append(\"--> \");\n\t\t\t}\n\t\t\tbuffer.append(state);\n\t\t\tif (isFinalState(state)) {\n\t\t\t\tbuffer.append(\" **FINAL**\");\n\t\t\t}\n\t\t\tbuffer.append('\\n');\n\t\t\tfor (final Transition transition : getTransitionsFromState(state)) {\n\t\t\t\tbuffer.append('\\t');\n\t\t\t\tbuffer.append(transition);\n\t\t\t\tbuffer.append('\\n');\n\t\t\t}\n\t\t}\n\n\t\treturn buffer.toString();\n\t}", "public String toString() {\r\n\t\treturn (\"State: \" + this.key + \", Value: \" + this.val);\r\n\t}", "@Override String toString();", "@Override\n\t\tpublic String toString() {\n\t\t\treturn super.toString();\n\t\t}", "public String toString() {\n return super.toString();\n }", "public String toString() {\r\n\t\t\r\n\t\treturn super.toString();\r\n\t\t\r\n\t}", "public String toString() {\n \t\treturn super.toString();\n \t}", "@Override public String toString();", "public String toString(){\n \tif(state){\n\t\treturn (\"1\");\n\t }\n\t else{\n\t\t return(\"0\");\n\t }\n }", "public String toString() {\t\t\t\t\t\r\n\t\treturn super.toString();\r\n\t}", "@Override\n\tpublic String toString()\n\t{\n\t\tStringBuilder stringBuilder = new StringBuilder();\n\t\tfor (int i = 0; i < 2 * size + 1; i++)\n\t\t{\n\t\t\tstringBuilder.append(\"-\");\n\t\t}\n\t\tstringBuilder.append(\"\\n|\");\n\t\tfor (int i = 0; i < state.size(); i++)\n\t\t{\n\t\t\tstringBuilder.append(state.get(i)).append(\"|\");\n\t\t\tif (i % size == size - 1 && i < state.size() - 1)\n\t\t\t{\n\t\t\t\tstringBuilder.append(\"\\n|\");\n\t\t\t}\n\t\t}\n\t\tstringBuilder.append(\"\\n\");\n\t\tfor (int i = 0; i < 2 * size + 1; i++)\n\t\t{\n\t\t\tstringBuilder.append(\"-\");\n\t\t}\n\t\treturn stringBuilder.toString();\n\t}", "@Override\n public String toString() {\n return (super.toString());\n\n }", "public Button(){\n id=1+nbrButton++;\n setBounds(((id-1)*getDimX())/(Data.getNbrLevelAviable()+1),((id-1)*getDimY())/(Data.getNbrLevelAviable()+1),getDimX()/(2*Data.getNbrLevelAviable()),getDimY()/(2*Data.getNbrLevelAviable()));\n setText(id+\"\");\n setFont(Data.getFont());\n addMouseListener(this);\n setVisible(true);\n }", "@Override\npublic String toString() {\n\treturn super.toString();\n}", "public String toString()\n {\n return super.toString();\n }", "public String toString()\n {\n return super.toString();\n }", "@Override\n public String toString() {\n return new Gson().toJson(this);\n }", "@Override\n public String toString() {\n return (this.str);\n }", "public String toString() {\r\n return \"name: \" + name + \"\\n\" +\r\n \"updateMode: \" + updateMode + \"\\n\" +\r\n super.toString();\r\n }", "public String toString() {\n\t\treturn super.toString();\n\t}", "public String toString() {\n\t\treturn super.toString();\n\t}", "@Override\n\tpublic String toString() {\n\t\tString str = labelTemplate.toString();\n\t\tswitch (type) {\n\t\tcase SET: str += \":=\"; break;\n\t\tcase DISCARD: str += \"!=\"; break;\n\t\tcase ADD: str += \"+=\"; break;\n\t\t}\n\t\tstr += valueTemplate.toString();\n\t\treturn str;\n\t}", "@Override\n public String toString() {\n return ToStringBuilder.reflectionToString(this, ToStringStyle.SHORT_PREFIX_STYLE);\n }", "@Override\n public String toString() {\n return super.toString(); //To change body of generated methods, choose Tools | Templates.\n }", "public String toString() {\n\treturn state.toString() + \" \" + context.toString();\n }", "public abstract String getManipulatorButtonLabel();", "@Override\n public String toString() {\n return string;\n }", "@Override\r\n String toString();", "@Override\n\tpublic String toString() {\n\t\treturn label;\n\t}", "@Override\n public String toString ()\n {\n StringBuffer buffer = new StringBuffer();\n for (State value : stateMap.values()) {\n buffer.append(value.toString());\n buffer.append(\"\\n\");\n }\n return buffer.toString();\n }", "public ButtonInfoMessage(int state) {\n\t\tsuper(AbstractMessage.ButtonInfo);\n\t\tthis.state = state;\n\t}", "public String toString() {\n\t\t\n\t\treturn this.getColor() + \"B\";\n\t}", "public String toString(){\r\n\t\tString s = \"Campus Tour: On Foot selected.\\n\";\r\n\t\ts = s + super.toString();\r\n\t\treturn s;\r\n\t}", "public OperatorButton(String name){\n\t\tsuper(name);\n\t}", "@Override\n\tpublic String toString() {\n\t\t\n\t\treturn this.getText();\n\t}", "@Override\n String toString();", "@Override\n String toString();", "@Override\r\n public String toString() {\r\n return String.valueOf(this.m_current);\r\n }", "@Override\n public String toString() {\n return new JSONSerializer().serialize(this);\n }", "@Override\n public String toString() {\n return super.toString() + \" '\" + mContentView.getText() + \"'\";\n }", "@Override\n\tpublic String toString() {\n\t\treturn toText();\n\t}", "public String toString()\r\n\t{\r\n\t\tString output = \"Color = \" + this.color + \", \";\r\n\t\toutput += super.toString();\r\n\t\treturn output;\r\n\t}", "@Override\r\npublic String toString() {\n\treturn super.toString();\r\n}", "@Override\n public String toString() {\n return \"\" + this.value;\n }", "@Override\r\n\tpublic String toString() {\r\n\t\treturn name + \": \" + super.toString();\r\n\t}", "@Override\n public String toString() {\n // TODO: Using Serializer\n return Serializer.toByteArray(this).toString();\n }", "@Override\n public String toString() {\n StringBuilder sb = new StringBuilder();\n sb.append(\"{\");\n if (getState() != null)\n sb.append(\"State: \").append(getState()).append(\",\");\n if (getStateReason() != null)\n sb.append(\"StateReason: \").append(getStateReason()).append(\",\");\n if (getStateReasonCode() != null)\n sb.append(\"StateReasonCode: \").append(getStateReasonCode());\n sb.append(\"}\");\n return sb.toString();\n }", "@Override\r\n public String toString();", "public String toString()\r\n\t{\r\n\t\tString asString = \"radiobuttons:\";\r\n\t\t\r\n\t\tasString += getOptionsString();\r\n\t\t\r\n\t\treturn asString;\r\n\t}", "@Override\r\n public String toString() {\r\n return JAXBToStringBuilder.valueOf(this, JAXBToStringStyle.SIMPLE_STYLE);\r\n }", "@Override\n\tpublic String toString() {\n\t\treturn toStringBuilder(new StringBuilder()).toString();\n\t}", "public String toString()\r\n {\r\n if(_switchedOn)\r\n return _color + \" On\";\r\n else\r\n return _color + \" Off\";\r\n }", "@Override\n public String toString() {\n return toString(false, true, true, null);\n }" ]
[ "0.67986536", "0.675454", "0.662376", "0.6440827", "0.64330536", "0.621708", "0.6216468", "0.62057066", "0.62057066", "0.6189537", "0.6188723", "0.6163911", "0.6163911", "0.6163911", "0.6163911", "0.61553913", "0.61526483", "0.61526483", "0.61526483", "0.61526483", "0.61526483", "0.61526483", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.61485267", "0.6143941", "0.6142183", "0.61408997", "0.6136152", "0.61344147", "0.6131557", "0.6124788", "0.61199695", "0.6075084", "0.60600513", "0.6046339", "0.60262805", "0.60183", "0.600381", "0.599213", "0.59901017", "0.5989692", "0.597155", "0.5962901", "0.59590465", "0.5949545", "0.5949545", "0.594754", "0.59452635", "0.59447116", "0.5941887", "0.5941887", "0.5941025", "0.593923", "0.593724", "0.59248585", "0.59147424", "0.59091353", "0.5891285", "0.58906776", "0.5884695", "0.5878361", "0.5863813", "0.58613306", "0.58599895", "0.58595854", "0.5851921", "0.5851921", "0.5849673", "0.5846636", "0.5841694", "0.583526", "0.5834263", "0.5826715", "0.5813966", "0.5811365", "0.58087516", "0.58087325", "0.58072925", "0.58060354", "0.5798561", "0.57984465", "0.5795703", "0.5781858" ]
0.84212995
0
Calls the super method and also writes the state into the stream.
@Override public void serialize(DataOutputStream stream) throws IOException { super.serialize(stream); stream.writeInt(getState()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void write() {\n\t\t\r\n\t}", "@Override\n public void write() {\n\n }", "@Override\n protected void doWriteTo(StreamOutput out) throws IOException {\n }", "public void beginOutput() {\n this.currentState = states.OUTPUT;\n this.buildOutStack();\n this.setOutputMode(0);\n }", "private void storeState() throws IOException {\n for (File outputFile : processedOutputs.keySet()) {\n if (state.outputs.get(outputFile) == null) {\n state.outputs.put(outputFile, new FileState(outputFile));\n }\n }\n\n File parent = stateFile.getParentFile();\n if (!parent.isDirectory() && !parent.mkdirs()) {\n throw new IOException(\"Could not create direcotyr \" + parent);\n }\n\n ObjectOutputStream os =\n new ObjectOutputStream(new GZIPOutputStream(new BufferedOutputStream(new FileOutputStream(\n stateFile))));\n try {\n os.writeObject(state);\n } finally {\n try {\n os.close();\n } catch (IOException e) {\n // ignore secondary exception\n }\n }\n }", "public void save(DataOutput stream)\n throws IOException\n {\n stream.write(getBytes());\n }", "@Override\n public void flush() throws IOException {\n checkStreamState();\n flushIOBuffers();\n }", "void serialize(PackageState state, OutputStream out);", "private void writeObject(final java.io.ObjectOutputStream out) throws java.io.IOException {\n\t\t/*\n\t\t * out.writeInt(0); // Version of the stream. // Version 0 outstuff...\n\t\t * out.writeObject(states); out.writeObject(initialState);\n\t\t * out.writeObject(finalStates); out.writeObject(transitions); if (this\n\t\t * instanceof TuringMachine) { out.writeInt(((TuringMachine)\n\t\t * this).tapes); } out.writeObject(\"SENT\"); // The sentinel object.\n\t\t */\n\t}", "@Override\n protected void writeStreamHeader() throws IOException {\n reset();\n }", "public void doWrite() throws IOException {\n\t\tbbout.flip();\n\t\tsc.write(bbout);\n\t\tbbout.compact();\n\t\tprocessOut();\n\t\tupdateInterestOps();\n\t}", "public void saveState() throws IOException {\n\t\tFile f = new File(workingDirectory() + File.separator + id() + FILE_EXTENSION);\n\t\t\n\t\t// create new file if it doesnt exist\n\t\tf.createNewFile();\n\t\t\n\t\t// dump client state into file\n\t\tObjectOutputStream os = new ObjectOutputStream(new FileOutputStream(f));\n\t\tos.writeObject(this);\n\t\tos.close();\n\t}", "public void saveState() {\n\t\tsuper.saveState();\n\t}", "@Override\n\t\tpublic void getState(OutputStream output) throws Exception {\n\t\t\tsynchronized(taskListState) {\n\t Util.objectToStream(taskListState, new DataOutputStream(output));\n\t }\n\t }", "public void saveState() \n\t{\n\t\tsuper.saveState();\n\t}", "public void doWrite() throws IOException {\n bbout.flip();\n sc.write(bbout);\n bbout.compact();\n processOut();\n updateInterestOps();\n }", "public void doWrite() throws IOException {\n bbout.flip();\n sc.write(bbout);\n bbout.compact();\n processOut();\n updateInterestOps();\n }", "@Override\n protected void serialize(OutputStream os) throws IOException {\n writeInt(os,_gateCounter);\n }", "private void doWrite() throws IOException {\n\t\t\tbb.flip();\n\t\t\tsc.write(bb);\n\t\t\tbb.compact();\n\n\t\t\tupdateInterestOps();\n\t\t}", "@Override\n\tpublic void write(OutStream outStream) {\n\t}", "@Override\n public void saveState(Bundle outBundle) {\n }", "void save() {\n File file = new File(main.myPath + \"state.xml\");\n Framework.backup(main.myPath + \"state.xml\");\n Framework.transform(stateDoc, new StreamResult(file), null);\n setDirty(false);\n }", "public void write() {\n/* 1062 */ this.cbSize = size();\n/* 1063 */ super.write();\n/* */ }", "@Override\n\t\tprotected void writeStreamHeader() throws IOException {\n\t\t}", "@Override\n\tpublic void writeTo(OutputStream outstream) throws IOException {\n\t\tsuper.writeTo(new WrapperOutputStream(outstream, this.listener));\n\t}", "private void sendCurrentState() {\n\ttry {\n\t channel.sendObject(getState());\n\t} catch (IOException e) {\n\t Log.e(\"423-client\", e.toString());\n\t}\n }", "@Override\n public void flush() throws IOException {\n byteBufferStreamOutput.flush();\n }", "@Override\n protected void writeStreamHeader() throws IOException {\n // metodo honek ez du ezer egiten\n }", "@Override\r\n public void flush ()\r\n {\r\n }", "@Override\n public void flush()\n throws XMLStreamException\n {\n try {\n mWriter.flush();\n } catch (IOException ie) {\n throw new WstxIOException(ie);\n }\n }", "public void writeState() {\n Throwable th;\n String str;\n String str2;\n IOException e;\n IOException e2;\n List<AppOpsManager.PackageOps> allOps;\n Throwable th2;\n String lastPkg;\n List<AppOpsManager.PackageOps> allOps2;\n String lastPkg2;\n List<AppOpsManager.PackageOps> allOps3;\n String proxyPkg;\n synchronized (this.mFile) {\n try {\n FileOutputStream stream = this.mFile.startWrite();\n String str3 = null;\n List<AppOpsManager.PackageOps> allOps4 = getPackagesForOps(null);\n try {\n XmlSerializer out = new FastXmlSerializer();\n out.setOutput(stream, StandardCharsets.UTF_8.name());\n out.startDocument(null, true);\n out.startTag(null, \"app-ops\");\n out.attribute(null, \"v\", String.valueOf(1));\n synchronized (this) {\n try {\n int uidStateCount = this.mUidStates.size();\n for (int i = 0; i < uidStateCount; i++) {\n try {\n UidState uidState = this.mUidStates.valueAt(i);\n if (uidState.opModes != null && uidState.opModes.size() > 0) {\n out.startTag(null, WatchlistLoggingHandler.WatchlistEventKeys.UID);\n out.attribute(null, \"n\", Integer.toString(uidState.uid));\n SparseIntArray uidOpModes = uidState.opModes;\n int opCount = uidOpModes.size();\n for (int j = 0; j < opCount; j++) {\n int op = uidOpModes.keyAt(j);\n int mode = uidOpModes.valueAt(j);\n out.startTag(null, \"op\");\n out.attribute(null, \"n\", Integer.toString(op));\n out.attribute(null, \"m\", Integer.toString(mode));\n out.endTag(null, \"op\");\n }\n out.endTag(null, WatchlistLoggingHandler.WatchlistEventKeys.UID);\n }\n } catch (Throwable th3) {\n e2 = th3;\n while (true) {\n try {\n break;\n } catch (Throwable th4) {\n e2 = th4;\n }\n }\n throw e2;\n }\n }\n } catch (Throwable th5) {\n e2 = th5;\n while (true) {\n break;\n }\n throw e2;\n }\n }\n if (allOps4 != null) {\n String lastPkg3 = null;\n boolean z = false;\n int i2 = 0;\n while (i2 < allOps4.size()) {\n AppOpsManager.PackageOps pkg = allOps4.get(i2);\n if (pkg.getPackageName() == null) {\n allOps = allOps4;\n } else {\n if (!pkg.getPackageName().equals(lastPkg3)) {\n if (lastPkg3 != null) {\n try {\n out.endTag(str3, \"pkg\");\n } catch (IOException e3) {\n e = e3;\n try {\n Slog.w(TAG, \"Failed to write state, restoring backup.\", e);\n this.mFile.failWrite(stream);\n if (stream != null) {\n }\n } catch (Throwable th6) {\n th = th6;\n if (stream != null) {\n try {\n stream.close();\n } catch (IOException e4) {\n Slog.w(TAG, \"Failed to close stream: \" + e4.getMessage());\n }\n }\n throw th;\n }\n } catch (Throwable th7) {\n th = th7;\n if (stream != null) {\n }\n throw th;\n }\n }\n lastPkg3 = pkg.getPackageName();\n out.startTag(str3, \"pkg\");\n out.attribute(str3, \"n\", lastPkg3);\n }\n out.startTag(str3, WatchlistLoggingHandler.WatchlistEventKeys.UID);\n out.attribute(str3, \"n\", Integer.toString(pkg.getUid()));\n synchronized (this) {\n try {\n Ops ops = getOpsRawLocked(pkg.getUid(), pkg.getPackageName(), z, z);\n if (ops != null) {\n try {\n out.attribute(str3, \"p\", Boolean.toString(ops.isPrivileged));\n } catch (Throwable th8) {\n th2 = th8;\n }\n } else {\n out.attribute(str3, \"p\", Boolean.toString(z));\n }\n } catch (Throwable th9) {\n th2 = th9;\n while (true) {\n try {\n break;\n } catch (Throwable th10) {\n th2 = th10;\n }\n }\n throw th2;\n }\n }\n List<AppOpsManager.OpEntry> ops2 = pkg.getOps();\n int j2 = z;\n while (j2 < ops2.size()) {\n AppOpsManager.OpEntry op2 = ops2.get(j2 == true ? 1 : 0);\n out.startTag(str3, \"op\");\n out.attribute(str3, \"n\", Integer.toString(op2.getOp()));\n if (op2.getMode() != AppOpsManager.opToDefaultMode(op2.getOp())) {\n out.attribute(str3, \"m\", Integer.toString(op2.getMode()));\n }\n LongSparseArray keys = op2.collectKeys();\n if (keys == null) {\n allOps2 = allOps4;\n lastPkg = lastPkg3;\n } else if (keys.size() <= 0) {\n allOps2 = allOps4;\n lastPkg = lastPkg3;\n } else {\n int keyCount = keys.size();\n int k = 0;\n while (k < keyCount) {\n long key = keys.keyAt(k);\n int uidState2 = AppOpsManager.extractUidStateFromKey(key);\n int flags = AppOpsManager.extractFlagsFromKey(key);\n long accessTime = op2.getLastAccessTime(uidState2, uidState2, flags);\n long rejectTime = op2.getLastRejectTime(uidState2, uidState2, flags);\n long accessDuration = op2.getLastDuration(uidState2, uidState2, flags);\n String proxyPkg2 = op2.getProxyPackageName(uidState2, flags);\n int proxyUid = op2.getProxyUid(uidState2, flags);\n if (accessTime > 0 || rejectTime > 0 || accessDuration > 0) {\n proxyPkg = proxyPkg2;\n } else {\n proxyPkg = proxyPkg2;\n if (proxyPkg == null && proxyUid < 0) {\n allOps3 = allOps4;\n lastPkg2 = lastPkg3;\n k++;\n allOps4 = allOps3;\n lastPkg3 = lastPkg2;\n }\n }\n allOps3 = allOps4;\n lastPkg2 = lastPkg3;\n try {\n out.startTag(null, \"st\");\n out.attribute(null, \"n\", Long.toString(key));\n if (accessTime > 0) {\n out.attribute(null, \"t\", Long.toString(accessTime));\n }\n if (rejectTime > 0) {\n out.attribute(null, \"r\", Long.toString(rejectTime));\n }\n if (accessDuration > 0) {\n out.attribute(null, \"d\", Long.toString(accessDuration));\n }\n if (proxyPkg != null) {\n out.attribute(null, \"pp\", proxyPkg);\n }\n if (proxyUid >= 0) {\n out.attribute(null, \"pu\", Integer.toString(proxyUid));\n }\n out.endTag(null, \"st\");\n k++;\n allOps4 = allOps3;\n lastPkg3 = lastPkg2;\n } catch (IOException e5) {\n e = e5;\n Slog.w(TAG, \"Failed to write state, restoring backup.\", e);\n this.mFile.failWrite(stream);\n if (stream != null) {\n }\n }\n }\n allOps2 = allOps4;\n lastPkg = lastPkg3;\n out.endTag(null, \"op\");\n allOps4 = allOps2;\n lastPkg3 = lastPkg;\n str3 = null;\n j2++;\n }\n out.endTag(null, \"op\");\n allOps4 = allOps2;\n lastPkg3 = lastPkg;\n str3 = null;\n j2++;\n }\n allOps = allOps4;\n out.endTag(null, WatchlistLoggingHandler.WatchlistEventKeys.UID);\n lastPkg3 = lastPkg3;\n }\n i2++;\n allOps4 = allOps;\n str3 = null;\n z = false;\n }\n if (lastPkg3 != null) {\n out.endTag(null, \"pkg\");\n }\n }\n out.endTag(null, \"app-ops\");\n out.endDocument();\n this.mFile.finishWrite(stream);\n out.flush();\n if (stream != null) {\n try {\n stream.close();\n } catch (IOException e6) {\n str2 = TAG;\n str = \"Failed to close stream: \" + e6.getMessage();\n }\n }\n } catch (IOException e7) {\n e = e7;\n Slog.w(TAG, \"Failed to write state, restoring backup.\", e);\n this.mFile.failWrite(stream);\n if (stream != null) {\n try {\n stream.close();\n } catch (IOException e8) {\n str2 = TAG;\n str = \"Failed to close stream: \" + e8.getMessage();\n }\n }\n } catch (Throwable th11) {\n th = th11;\n if (stream != null) {\n }\n throw th;\n }\n } catch (IOException e9) {\n Slog.w(TAG, \"Failed to write state: \" + e9);\n return;\n }\n }\n Slog.w(str2, str);\n }", "@Override\n\t\tpublic void flush() throws IOException {\n\t\t\twriteBlock(true);\n\t\t\tout.flush();\n\n\t\t\t// it's a bit nasty if an exception is thrown from the log,\n\t\t\t// but ignoring it can be nasty as well, so it is decided to\n\t\t\t// let it go so there is feedback about something going wrong\n\t\t\t// it's a bit nasty if an exception is thrown from the log,\n\t\t\t// but ignoring it can be nasty as well, so it is decided to\n\t\t\t// let it go so there is feedback about something going wrong\n\t\t\tif (debug) {\n\t\t\t\tlog.flush();\n\t\t\t}\n\t\t}", "public void writeTo(OutputStream arg0) throws IOException {\n\t\t\r\n\t}", "protected abstract void _write(DataOutput output) throws IOException;", "public void save() {\r\n try {\r\n FileOutputStream fos = new FileOutputStream(REPO_STATE_FILE_NAME);\r\n fos.write(CodecUtils.toJson(this).getBytes());\r\n fos.close();\r\n } catch (Exception e) {\r\n Logging.logError(e);\r\n }\r\n }", "public void saveState(ObjectOutput out) throws IOException {\n\t\t// save deikto values\n\t\tdk.saveState(out);\n\t\t// save interpreter values\n\t\tout.writeFloat(interpreter.globalActorBox);\n\t\tout.writeFloat(interpreter.globalPropBox);\n\t\tout.writeFloat(interpreter.globalStageBox);\n\t\tout.writeFloat(interpreter.globalEventBox);\n\t\tout.writeFloat(interpreter.globalVerbBox);\n\t\tout.writeFloat(interpreter.globalBNumberBox);\n\n\t\t// save ticks\n\t\tout.writeInt(cMoments);\n\t\t// save inactivity counter\n\t\tout.writeInt(cInactivity);\n\t\t// save player inactivity\n\t\tout.writeInt(playerInactivity);\n\t\t// save storyIsOver\n\t\tout.writeBoolean(storyIsOver);\n\t\tout.writeBoolean(isEpilogueNow);\n\t\tout.writeBoolean(isHappilyDone);\n\t\tout.writeBoolean(isPenultimateDone);\n\n\t\t// save historyBook\n\t\tout.writeInt(historyBook.size());\n\t\tfor(Sentence s:historyBook)\n\t\t\tout.writeObject(s);\n\t\t// save random seeds\n\t\tout.writeObject(random);\n\t\tout.writeLong(interpreter.scriptRandom.getSeed());\n\t\t// save alarms\n\t\tout.writeInt(alarms.size());\n\t\tfor(Alarm a:alarms)\n\t\t\tout.writeObject(a);\n\t\tout.writeInt(storybook.size());\n\t\tfor(String s:storybook)\n\t\t\tout.writeUTF(s);\n\t}", "public void saveState() { }", "@Override\r\n public void enableStreamFlow() {\r\n SwitchStates.setEmitOrgEND(true);\r\n }", "public abstract void write(DataOutput out) throws IOException;", "@Override\n\tprotected void write(ObjectOutput out) throws IOException {\n\t\t\n\t}", "public void printState() throws IOException, FileNotFoundException {\n\t\tprintState(new PrintWriter(new BufferedWriter(new FileWriter(modelname))));\n\t}", "public abstract <T> SerializationStream writeObject(T t);", "public abstract void writeToStream(DataOutputStream dataOutputStream);", "@Override\n\tpublic void savePlayerData(OutputStream arg0)\n\t{\n\n\t}", "public void serialize() {\n FileOutputStream fileOutput = null;\n ObjectOutputStream outStream = null;\n // attempts to write the object to a file\n try {\n clearFile();\n fileOutput = new FileOutputStream(data);\n outStream = new ObjectOutputStream(fileOutput);\n outStream.writeObject(this);\n } catch (Exception e) {\n } finally {\n try {\n if (outStream != null)\n outStream.close();\n } catch (Exception e) {\n }\n }\n }", "@Override\n\tpublic void send(OutputStream stream) throws IOException {\n\t\tstream.write(this.data);\n\t}", "@Override\n public void flush() {\n }", "@Override\n public void flush() {\n }", "@Override\n public void flush() {\n }", "void printstate()\n\t{\n\t\toperation.printstate();\n\t}", "public abstract void writeToStream(java.io.DataOutputStream output) throws java.io.IOException;", "@Override\r\n public void enableStreamFlow() {\r\n SwitchStates.setEmitTrgEND(true);\r\n }", "public static String saveState() {\n \n // 1) Encode the state to XML\n ByteArrayOutputStream bout = new ByteArrayOutputStream();\n StaticsXMLEncoder encoder = new StaticsXMLEncoder(bout);\n encoder.writeObject(Exercise.getExercise().getState());\n encoder.close();\n byte[] xmlData = bout.toByteArray();\n \n // 2) Zip it\n Deflater deflater = new Deflater();\n deflater.setInput(xmlData);\n deflater.finish();\n \n ByteArrayOutputStream zout = new ByteArrayOutputStream();\n byte[] partialData = new byte[1024];\n int dataCompressed;\n while ((dataCompressed = deflater.deflate(partialData)) != 0) {\n zout.write(partialData, 0, dataCompressed);\n }\n \n byte[] compressedData = zout.toByteArray();\n deflater.deflate(compressedData);\n \n // 3) Encode it with Base64 for convenience\n String encodedData = Base64.encodeBytes(compressedData);\n return encodedData;\n }", "@Override\n\tpublic void savePlayerData(OutputStream arg0) {\n\n\t}", "@Override\n public void emitOutput() {\n }", "@Override\n\tpublic void flush() {\n\t\t\n\t}", "@Override\n\tpublic void flush() {\n\t\t\n\t}", "@Override\n\tpublic void flush() {\n\t\t\n\t}", "@Override\n\tpublic void flush() {\n\t\t\n\t}", "@Override\n public void writeToParcel(Parcel dest, int flags) {\n if (DBG) log(\"writeToParcel(Parcel, int): \" + toString());\n dest.writeInt(mSignalStrength);\n dest.writeInt(mBitErrorRate);\n }", "@Override\n public void flush()\n {\n }", "private void serializeBeforeOpen() {\r\n sr.save(this.path);\r\n }", "@Override\n public void flush() throws IOException {\n }", "@Override\r\n\tpublic void flush() {\n\t\t\r\n\t}", "void write(StreamOption streamOpt);", "public void storeState(StateInfo stateInfo) {\n \n// Thread.dumpStack();\n super.storeState(stateInfo); \n \n JJStateInfo info = (JJStateInfo) stateInfo;\n info.setSubStates(lexan.getStateInfo());\n \n if (DEBUG) debug.println(\"Storing state [\"+ offset + \",\" + tokenOffset + \"]: \" + info + \"@\" + stopOffset); // NOI18N\n \n }", "public abstract void flush();", "@Override\r\n\tpublic void flush() {\n\t}", "@Override\n\tpublic void savePlayerData(OutputStream os) {\n\t\t\n\t}", "@Override\r\n\tpublic void transmit() {\n\t\tcurrentState.transmit();\r\n\t}", "private void writeObject(ObjectOutputStream _stream)\n/* 428: */ throws IOException\n/* 429: */ {\n/* 430:503 */ _stream.defaultWriteObject();\n/* 431:504 */ writeCustomData(_stream);\n/* 432: */ }", "@Override\n\tpublic void onSaveInstanceState(Bundle savedInstanceState) {\n\n\t\tsuper.onSaveInstanceState(savedInstanceState);\n\n\t\t/* save variables */\n\t\tsavedInstanceState.putLong(\"NumberOfSignalStrengthUpdates\",\n\t\t\t\tNumberOfSignalStrengthUpdates);\n\n\t\tsavedInstanceState.putLong(\"LastCellId\", LastCellId);\n\t\tsavedInstanceState.putLong(\"NumberOfCellChanges\", NumberOfCellChanges);\n\n\t\tsavedInstanceState.putLong(\"LastLacId\", LastLacId);\n\t\tsavedInstanceState.putLong(\"NumberOfLacChanges\", NumberOfLacChanges);\n\n\t\tsavedInstanceState.putLongArray(\"PreviousCells\", PreviousCells);\n\t\tsavedInstanceState.putInt(\"PreviousCellsIndex\", PreviousCellsIndex);\n\t\tsavedInstanceState.putLong(\"NumberOfUniqueCellChanges\",\n\t\t\t\tNumberOfUniqueCellChanges);\n\n\t\tsavedInstanceState.putBoolean(\"outputDebugInfo\", outputDebugInfo);\n\n\t\t/* save the trace data still in the write buffer into a file */\n\t\tsaveDataToFile(FileWriteBufferStr, \"---in save instance, \"\n\t\t\t\t+ DateFormat.getTimeInstance().format(new Date()) + \"\\r\\n\",\n\t\t\t\tcellLogFilename);\n\t\tFileWriteBufferStr = \"\";\n\n\t}", "@Override\n\tpublic void savePlayerData(OutputStream os) {\n\n\t}", "@Override\n\tpublic void flush() {\n\t}", "void write();", "@Override()\n protected void onSaveInstanceState(final Bundle state)\n {\n logEnter(LOG_TAG, \"onSaveInstanceState\", state);\n\n saveState(state);\n }", "public void onEncodeSerialData(StreamWriter streamWriter) {\n }", "OutputStream getOutputStream()\n {\n return outputStream;\n }", "OutputStream getOutputStream();", "void writeCurrentBuffer();", "@Override\n public void close() throws IOException {\n flush();\n }", "private void saveStateSnapshot(State state){\n\t\ttry{\n\t\t\tif(saveStateSnapshot){\n\t\t\t\t//System.out.println(Utils.treeDesc(state, 2, Tags.Role, Tags.Desc, Tags.Shape, Tags.Blocked));\n\t\t\t\tTaggable taggable = new TaggableBase();\n\t\t\t\ttaggable.set(SystemState, state);\n\t\t\t\tLogSerialiser.log(\"Saving state snapshot...\\n\", LogSerialiser.LogLevel.Debug);\n\t\t\t\tFile file = Util.generateUniqueFile(settings.get(ConfigTags.OutputDir), \"state_snapshot\");\n\t\t\t\tObjectOutputStream oos = new ObjectOutputStream(new BufferedOutputStream(new FileOutputStream(file)));\n\t\t\t\toos.writeObject(taggable);\n\t\t\t\toos.close();\n\t\t\t\tsaveStateSnapshot = false;\n\t\t\t\tLogSerialiser.log(\"Saved state snapshot to \" + file.getAbsolutePath() + \"\\n\", LogSerialiser.LogLevel.Info);\n\t\t\t}\n\t\t}catch(IOException ioe){\n\t\t\tthrow new RuntimeException(ioe);\n\t\t}\n\t}", "public void save(OutputStream out) throws IOException {\n\t\ttry (GZIPOutputStream zipOut = new GZIPOutputStream(out)) {\n\t\t\ttry (ObjectOutputStream objOut = new ObjectOutputStream(zipOut)) {\n\t\t\t\tobjOut.writeObject(this);\n\t\t\t}\n\t\t}\n\t}", "@Override\n public void flushBuffer() throws IOException {\n\n }", "public abstract void write(EmitterSystemState data)\n\t\t\tthrows FailedToWriteToDatastoreException;", "public void writeTo(OutputStream op) throws IOException {\r\n if(gzipOp != null) {\r\n throw new IllegalStateException(\"Cannot writeTo with compression on\");\r\n }\r\n bop.writeTo(op);\r\n }", "@Override\r\n\tpublic void writeRents() {\n\t\t\r\n\t}", "@Override\r\n\t\t\tpublic void write(int b) throws IOException {\n\t\t\t}", "@Override\n\tprotected void onSaveInstanceState(Bundle outState) {\n\t\tsuper.onSaveInstanceState(outState);\n\t\tLog.v(\"save\", \"here I come :) \");\n\t}", "@Override\r\n public void enableStreamFlow() {\r\n SwitchStates.setEmitOrgPRE(true);\r\n \r\n }", "public void sendUpdatedState() {\n \t\tObjectOutputStream out = null;\n \t\ttry {\n \t\t\tfor (Socket socket : sockets) {\n \t\t\t\tout = new ObjectOutputStream(socket.getOutputStream());\n \t\t\t\tout.writeObject(gs);\n \t\t\t\tLog.d(\"network GaC\", \"State written into socket\");\n \t\t\t\tout.flush();\n \t\t\t}\n \t\t} catch (IOException e) {\n \t\t\te.printStackTrace();\n \t\t}\n \t}", "public void writeLeft(PrintWriter out, RequestProperties reqState) \n throws IOException\n {\n // ignore\n }", "private void saveState(final Bundle state)\n {\n logEnter(LOG_TAG, \"saveState\", state);\n\n state.putSerializable(BUNDLE_FIELD_INSTANCE, instance);\n state.putSerializable(BUNDLE_FIELD_ENTRIES, entries);\n }", "@Override\r\n\tpublic int write() throws Exception {\n\t\treturn 0;\r\n\t}", "@Override\n public String toString()\n {\n return state.toString();\n }", "private void outRestore() throws IOException {\n if (lastWriteOffset > 0) {\n outSeek(lastWriteOffset);\n lastWriteOffset = -1;\n }\n }", "@Override\r\n public void write(byte[] buffer) throws IOException {\r\n inWrite1 = true;\r\n try {\r\n super.write(buffer);\r\n if (!inWrite3) {\r\n /*if (!Helper.NEW_IO_HANDLING \r\n && null != IoNotifier.fileNotifier) {\r\n IoNotifier.fileNotifier.notifyWrite(recId, buffer.length);\r\n } else {*/\r\n if (null != RecorderFrontend.instance) {\r\n RecorderFrontend.instance.writeIo(recId, \r\n null, buffer.length, StreamType.FILE);\r\n }\r\n //}\r\n }\r\n inWrite1 = false;\r\n } catch (IOException e) {\r\n inWrite1 = false;\r\n throw e;\r\n }\r\n }", "public synchronized void log(String state, Transaction t) {\n\n String logContent = state + \" \" + t.toJSON() + \"\\n\"; \n \n try (FileWriter fw = new FileWriter(path, true)) {\n fw.write(logContent);\n } catch (IOException e) {\n e.printStackTrace();\n }\n \n System.out.print(\"Logger::log Content: \" + logContent);\n }", "protected void serializeState() {\n\t\tint ii = 0;\n\t\t\n\t\tfor(GEditorPanel gep : editorPanels) {\n\t\t\tif(gep.getFilePath() != null && gep.getFilePath().length() > 0) {\n\t\t\t\tPreference.PREFERENCES_NODE.put(\"editSession\" + ++ii, gep.getFilePath());\n\t\t\t}\n\t\t}\n\t\t\n\t\tAccessors.INT_ACCESSOR.put(\"numberOfFiles\", ii);\n\t}", "@Override\r\n\tpublic void onSave(Bundle outState) {\n\t}" ]
[ "0.6464089", "0.63919467", "0.63182825", "0.626601", "0.6231442", "0.6185879", "0.615726", "0.6125767", "0.6118535", "0.6117909", "0.610702", "0.609502", "0.60902184", "0.60891306", "0.60850185", "0.6076465", "0.6076465", "0.60712874", "0.6000825", "0.59905154", "0.59488344", "0.59278756", "0.5917261", "0.59149563", "0.588364", "0.58404666", "0.5800361", "0.5775355", "0.57483673", "0.5743082", "0.57380956", "0.5724369", "0.5696517", "0.56962085", "0.5691687", "0.568057", "0.5672361", "0.5670266", "0.5665756", "0.5663938", "0.56506217", "0.5637382", "0.56209236", "0.5619722", "0.5616901", "0.56093174", "0.56081915", "0.56081915", "0.56081915", "0.56002134", "0.5575703", "0.557191", "0.55665416", "0.55539215", "0.554743", "0.5543591", "0.5543591", "0.5543591", "0.5543591", "0.5526258", "0.5526021", "0.5510913", "0.5499678", "0.5497539", "0.5470754", "0.5465079", "0.5458038", "0.54449046", "0.54421055", "0.5441084", "0.5433961", "0.54336345", "0.54251784", "0.54159", "0.5413179", "0.54052836", "0.54036343", "0.5401209", "0.539385", "0.53840715", "0.53835636", "0.53798413", "0.5376784", "0.5372465", "0.5372198", "0.5366842", "0.53665006", "0.5362712", "0.53574646", "0.53574187", "0.53536785", "0.5352153", "0.5347014", "0.5344741", "0.5337266", "0.5335956", "0.53307045", "0.53273016", "0.5326038", "0.5313569" ]
0.7540465
0
Create Item (Material + Amount)
public ItemBuilder(Material material, int amount) { itemstack = new ItemStack(material, amount); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void createItem (String name, String description, double price);", "void createMaterial(Material material) throws CreateException;", "public ItemStack generateItem(){\n\t\tItemStack item = new ItemStack(material);\n\t\tif(damage >= 0) item.setDurability(damage);\n\t\t\n\t\tif(itemName.isEmpty() && loreLine.isEmpty()) return item;\n\t\t\n\t\tItemMeta meta = item.getItemMeta();\n\t\tif(meta == null) return item;\n\t\t\n\t\tmeta.setDisplayName(itemName);\n\t\tmeta.setLore(Arrays.asList(loreLine));\n\t\titem.setItemMeta(meta);\n\t\t\n\t\treturn item;\n\t}", "Quantity createQuantity();", "@Override\n\tpublic Item create() {\n\t\tLOGGER.info(\"Shoe Name\");\n\t\tString item_name = util.getString();\n\t\tLOGGER.info(\"Shoe Size\");\n\t\tdouble size = util.getDouble();\n\t\tLOGGER.info(\"Set Price\");\n\t\tdouble price = util.getDouble();\n\t\tLOGGER.info(\"Number in Stock\");\n\t\tlong stock = util.getLong();\n\t\tItem newItem = itemDAO.create(new Item(item_name, size, price, stock));\n\t\tLOGGER.info(\"\\n\");\n\t\treturn newItem;\n\t}", "public ItemStack createItem(ItemType type, int damage,List<Text> lore);", "@Override\n public Item createItem(int itemNum, Item item) throws VendingMachinePersistenceException {\n loadItemFile();\n Item newItem = itemMap.put(itemNum, item);\n writeItemFile();\n return newItem;\n }", "public void insertItemDetails(String itemName, Integer quantityOfItem, Double rateOfItem);", "protected abstract void makeItem();", "public Material create();", "public InventoryItem(){\r\n this.itemName = \"TBD\";\r\n this.sku = 0;\r\n this.price = 0.0;\r\n this.quantity = 0;\r\n nItems++;\r\n }", "public void addItemElementsFromBillOfMaterials(Item item) throws CdbException {\n List<InventoryBillOfMaterialItem> bomItems = item.getInventoryDomainBillOfMaterialList();\n\n if (bomItems != null) {\n for (InventoryBillOfMaterialItem bomItem : bomItems) {\n if (bomItem.getState().equals(InventoryBillOfMaterialItemStates.unspecifiedOptional.getValue())) {\n continue;\n }\n\n // Check if current catalog item element already has an item element defined. \n ItemElement catalogItemElement = bomItem.getCatalogItemElement();\n ItemElement currentInventoryItemElement = null;\n for (ItemElement inventoryItemElement : item.getFullItemElementList()) {\n if (inventoryItemElement.getDerivedFromItemElement() == catalogItemElement) {\n currentInventoryItemElement = inventoryItemElement;\n logger.debug(\"Updating element \" + currentInventoryItemElement + \" to item \" + item);\n break;\n }\n }\n\n if (currentInventoryItemElement == null) {\n currentInventoryItemElement = new ItemElement();\n currentInventoryItemElement.init(item, bomItem.getCatalogItemElement());\n item.getFullItemElementList().add(currentInventoryItemElement);\n logger.debug(\"Creating instance adding element \" + currentInventoryItemElement + \" to item \" + item);\n }\n\n // User has specified to create a new item for this bill of materials item. \n String currentBomState = bomItem.getState();\n if (currentBomState.equals(InventoryBillOfMaterialItemStates.newItem.getValue())\n || currentBomState.equals(InventoryBillOfMaterialItemStates.existingItem.getValue())) {\n if (bomItem.getInventoryItem() == null) {\n\n String actionWord = \"defined\";\n if (currentBomState.equals(InventoryBillOfMaterialItemStates.existingItem.getValue())) {\n actionWord = \"selected\";\n }\n\n throw new CdbException(\"An item for: \" + bomItem.getCatalogItemElement().getName() + \" is not \" + actionWord + \".\");\n }\n\n Item inventoryItem = bomItem.getInventoryItem();\n\n // No need to do that for existing items. \n if (currentBomState.equals(InventoryBillOfMaterialItemStates.newItem.getValue())) {\n addItemElementsFromBillOfMaterials(inventoryItem);\n currentInventoryItemElement.setContainedItem(inventoryItem);\n\n } else if (currentBomState.equals(InventoryBillOfMaterialItemStates.existingItem.getValue())) {\n if (currentInventoryItemElement.getContainedItem() == inventoryItem == false) {\n currentInventoryItemElement.setContainedItem(itemFacade.find(inventoryItem.getId()));\n }\n }\n } else if (currentBomState.equals(InventoryBillOfMaterialItemStates.placeholder.getValue())) {\n currentInventoryItemElement.setContainedItem(null);\n }\n\n // Use permissions defined in parent of the item for the item element. \n updateItemElementPermissionsToItem(currentInventoryItemElement, bomItem.getParentItemInstance());\n }\n }\n\n }", "public void addItem() {\n\t\tScanner scanner = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter Item Name: \");\n\t\tString itemName = scanner.nextLine();\n\t\tSystem.out.print(\"Enter Item Description: \");\n\t\tString itemDescription = scanner.nextLine();\n\t\tSystem.out.print(\"Enter minimum bid price for item: $\");\n\t\tdouble basePrice = scanner.nextDouble();\n\t\tLocalDate createDate = LocalDate.now();\n\t\tItem item = new Item(itemName, itemDescription, basePrice, createDate);\n\t\taddItem(item);\n\t}", "ShipmentItem createShipmentItem();", "public static ItemStack createItem(String customName, Material material, String ID) {\r\n ItemStack is = new ItemStack(material);\r\n ItemMeta isMeta = is.getItemMeta();\r\n isMeta.setDisplayName(customName); //you can even set color\r\n ArrayList<String> lore = new ArrayList<>();\r\n lore.add(ID);\r\n isMeta.setLore(lore);\r\n is.setItemMeta(isMeta);\r\n return is;\r\n }", "public void doCreateItem() {\r\n\t\tlogger.info(\"Se procede a crear el book \" + newItem.getDescription());\r\n\t\tBook entity = newItem.getEntity();\r\n\t\tentity.setUser(Global.activeUser());\r\n\t\tentity.setBookBalance(BigDecimal.ZERO);\r\n\t\tentity.setTotalBudget(BigDecimal.ZERO);\r\n\t\tentity.setTotalIncome(BigDecimal.ZERO);\r\n\t\tentity.setTotalExpenses(BigDecimal.ZERO);\r\n\t\tentity = bookService.create(entity);\r\n\r\n\t\t// Actualizar el mapa de books\r\n\t\tGlobalBook.instance().put(new BookData(entity));\r\n\r\n\t\tlogger.info(\"Se ha creado el book \" + newItem.getDescription());\r\n\t\tnewItem = new BookData(new Book());\r\n\t\tFacesContext.getCurrentInstance().addMessage(null,\r\n\t\t\t\tnew FacesMessage(FacesMessage.SEVERITY_INFO, \"Libro creado\", \"Libro creado correctamente\"));\r\n\t}", "public void createItemInInventory(Item newItem) {\n\t\tinventory.createItem(newItem);\n\t}", "org.hl7.fhir.Quantity addNewValueQuantity();", "public ItemBuilder(Material material, int amount, byte SubID) {\n\t\titemstack = new ItemStack(material, amount, SubID);\n\t}", "@Test\n\tpublic void testAddItem() throws IOException{\n\t\tModel.addItem(item, amount + \"\");\n\t\tassertEquals(amount + \"\", Model.hash.get(item));\n\t\t\n\t}", "public void create_crystal() {\n\t\tcrystalQuantity[1] += (1+create_modifier);\n\t\tautomerge();\n\t\tcollection();\n\t}", "Items(double cost){\n\tthis.cost=cost;\n\titemId++;\n\tcurrentID=itemId;\n}", "public int addItem(Item i);", "private void makeObject() {\n\t\t\n\t\tItem I1= new Item(1,\"Cap\",10.0f,\"to protect from sun\");\n\t\tItemMap.put(1, I1);\n\t\t\n\t\tItem I2= new Item(2,\"phone\",100.0f,\"Conversation\");\n\t\tItemMap.put(2, I2);\n\t\t\n\t\tSystem.out.println(\"Objects Inserted\");\n\t}", "public void addFuel(int quantity) throws Exception;", "public Item(){\n description = \"No description avaible for this item\";\n weight = 0;\n }", "private void createItems()\n {\n Item belt, nappies, phone, money, cigarretes, \n jacket, cereal, shoes, keys, comics, bra, \n bread, bowl, computer;\n\n belt = new Item(2,\"Keeps something from falling\",\"Belt\");\n nappies = new Item(7,\"Holds the unspeakable\",\"Nappies\");\n phone = new Item(4, \"A electronic device that holds every answer\",\"Iphone 10\");\n money = new Item(1, \"A form of currency\",\"Money\");\n cigarretes = new Item(2,\"It's bad for health\",\"Cigarretes\");\n jacket = new Item(3,\"Keeps you warm and cozy\", \"Jacket\");\n cereal = new Item(3, \"What you eat for breakfast\",\"Kellog's Rice Kripsies\");\n shoes = new Item(5,\"Used for walking\", \"Sneakers\");\n keys = new Item(2, \"Unlock stuff\", \"Keys\");\n comics = new Item(2, \"A popular comic\",\"Batman Chronicles\");\n bra = new Item(3,\"What is this thing?, Eeeewww\", \"Bra\");\n bread = new Item(6,\"Your best source of carbohydrates\",\"Bread\");\n bowl = new Item(4,\"where food is placed\",\"Plate\");\n computer = new Item(10,\"A computational machine\",\"Computer\");\n\n items.add(belt);\n items.add(nappies);\n items.add(phone);\n items.add(money);\n items.add(cigarretes);\n items.add(jacket);\n items.add(cereal);\n items.add(shoes);\n items.add(keys);\n items.add(comics);\n items.add(bra);\n items.add(bread);\n items.add(bowl);\n items.add(computer);\n }", "public void createOrderItem() {\r\n\t\tScanner sc = new Scanner(System.in);\r\n\t\tRestaurantApp.globalMenuManager.printMenu(); //create a globalmenuManager so that other classes can access the menu\r\n\t\ttry {\r\n\t\t\tSystem.out.println(\"Which item would you like to order?\");\r\n\t\t\tint menuIndex = sc.nextInt();\r\n\t\t\tsc.nextLine();\r\n\t\t\tif (menuIndex <= 0 || menuIndex > RestaurantApp.globalMenuManager.getSizeOfMenu()){\r\n\t\t\t\tthrow new ArrayIndexOutOfBoundsException(\"Please input a valid index from 1 to \"+RestaurantApp.globalMenuManager.getSizeOfMenu());\r\n\t\t\t}\r\n\t\t\tthis.menuItem = RestaurantApp.globalMenuManager.getMenuItem(menuIndex-1);\r\n\t\t\tSystem.out.println(\"How many of this are you ordering?\");\r\n\t\t\tthis.quantity = sc.nextInt();\r\n\t\t\tsc.nextLine();\r\n\t\t\tSystem.out.println(\"Order item added. printing details...\");\r\n\t\t\tthis.printOrderItem();\r\n\t\t} catch (ArrayIndexOutOfBoundsException e) {\r\n\t\t\tSystem.out.println(e.getMessage()); \r\n\t\t\tSystem.out.println(\"program exiting ...\");\r\n\t\t\tSystem.exit(0);\r\n\t\t}\r\n\t}", "public void createItem()\n {\n \n necklace_red = new Item (\"Red Necklace\",\"This is a strange red necklace\");\n poolroom.addItem(necklace_red);\n \n // items in dancing room // \n gramophone = new Item (\"Gramophone\",\"This is a nice gramophone but without disk\");\n candelar = new Item(\"Candelar\",\"This candelar gives light and is really beautiful\");\n dancingroom.addItem(gramophone);\n dancingroom.addItem(candelar);\n \n //items in hall //\n potion2HP = new Potion(\"Potion 2 HP\",\"This potion gives 2 HP to the player\",2);\n hall.addItem(potion2HP);\n \n //items in corridor //\n halberd = new Weapon(\"Halberd\",\"This the statut halberd. It was not a really good idea to take it\",4,60);\n corridor.addItem(halberd);\n \n // items in bathroom //\n potion6HP = new Potion(\"Potion6HP\",\"This potions gives 6 HP to the player\",6);\n bathroom.addItem(potion6HP);\n \n // items in guestbedroom //\n Exit exit_from_corridor_to_bedroom = new Exit(\"south\",corridor,false, null);\n bedroomkey = new Keys(\"Bedroom key\",\"This key opens the master bedroom door\",exit_from_corridor_to_bedroom);\n guestbedroom.addItem(bedroomkey);\n \n // items in kitchen // \n set_of_forks_and_knives = new Weapon(\"Set of forks and knives\",\"This weapon is a set of silver forks and silver knives\",2,40);\n kitchen.addItem(set_of_forks_and_knives);\n \n // items in bedroom //\n Item disk = new Item(\"Disk\",\"This disk can be used with the gramophone\");\n bedroom.addItem(disk);\n \n Potion potion3HP = new Potion (\"Potion3HP\",\"This potions gives 3 HP to the player\",3);\n bedroom.addItem(potion3HP);\n \n Item money = new Item(\"Money\",\"You find 60 pounds\");\n bedroom.addItem(money);\n \n // items in the library //\n Item book = new Item(\"Book\",\"The title book is 'The best human friend : the cat'\");\n library.addItem(book);\n \n // items in laboratory //\n Exit exit_from_corridor_to_attic = new Exit(\"up\",corridor,false, null);\n Keys attickey = new Keys(\"Attic key\",\"This key is a shaped bone from a squeletor\", exit_from_corridor_to_attic); \n laboratory.addItem(attickey);\n \n Item construction_drawing = new Item(\"Construction drawing\",\"You find construction drawings. Mr Taylor planed to dig really deeply to the east of the gardener hut\");\n laboratory.addItem(construction_drawing);\n \n //items in garden //\n Weapon fork = new Weapon(\"Fork\",\"This fork is green and brown\",3,50);\n garden.addItem(fork);\n \n Potion apple = new Potion(\"Apple\",\"This apples gives you 2 HP\",2);\n garden.addItem(apple);\n \n // items in gardenerhut //\n \n Item pliers = new Item(\"Pliers\",\"You can cut a chain with this object\");\n gardenerhut.addItem(pliers);\n \n Item ritual_cape = new Item(\"Ritual cape\",\"You find a black ritual cape. It is very strange !\");\n gardenerhut.addItem(ritual_cape);\n \n Item necklace_black_1 = new Item(\"Necklace\",\"You find a very strange necklace ! It is a black rond necklace with the same symbol than in the ritual cape\");\n gardenerhut.addItem(necklace_black_1);\n \n //items in anteroom //\n \n Potion potion4HP = new Potion(\"Potion4HP\",\"This potion gives 4 HP to the player\",4);\n anteroom.addItem(potion4HP);\n \n Weapon sword = new Weapon(\"Sword\",\"A really sharp sword\",6,70);\n anteroom.addItem(sword);\n // items in ritual room //\n \n Item red_ritual_cape = new Item(\"Red ritual cape\", \"This is a ritual cape such as in the gardener hut but this one is red. There are some blond curly hairs\");\n ritualroom.addItem(red_ritual_cape);\n \n Item black_ritual_cape_1 = new Item(\"Black ritual cape\",\"This is a black ritual cape\");\n ritualroom.addItem(black_ritual_cape_1);\n \n Item black_ritual_cape_2 = new Item (\"Black ritual cape\",\"Another black ritual cape\");\n ritualroom.addItem(black_ritual_cape_2);\n \n }", "public void addItem() {\r\n\t\tFacesContext fc = FacesContext.getCurrentInstance();\r\n\t\tif (itemInvoice.getQuantidade() <= itemPO.getQuantidadeSaldo()) {\r\n\t\t\tBigDecimal total = itemInvoice.getPrecoUnit().multiply(\r\n\t\t\t\t\tnew BigDecimal(itemInvoice.getQuantidade()));\r\n\t\t\titemInvoice.setTotal(total);\r\n\t\t\tif (!editarItem) {\r\n\r\n\t\t\t\tif (itemInvoice.getPrecoUnit() == null) {\r\n\t\t\t\t\titemInvoice.setPrecoUnit(new BigDecimal(0.0));\r\n\t\t\t\t}\r\n\t\t\t\tif (itemInvoice.getQuantidade() == null) {\r\n\t\t\t\t\titemInvoice.setQuantidade(0);\r\n\t\t\t\t}\r\n\t\t\t\titemInvoice.setInvoice(invoice);\r\n\r\n\t\t\t\tinvoice.getItensInvoice().add(itemInvoice);\r\n\r\n\t\t\t} else {\r\n\t\t\t\tinvoice.getItensInvoice().set(\r\n\t\t\t\t\t\tinvoice.getItensInvoice().indexOf(itemInvoice),\r\n\t\t\t\t\t\titemInvoice);\r\n\t\t\t}\r\n\t\t\tcarregarTotais();\r\n\t\t\tinicializarItemInvoice();\r\n\t\t\trequired = false;\r\n\t\t} else {\r\n\r\n\t\t\tMessages.adicionaMensagemDeInfo(TemplateMessageHelper.getMessage(\r\n\t\t\t\t\tMensagensSistema.INVOICE, \"lblQtdMaioSaldo\", fc\r\n\t\t\t\t\t\t\t.getViewRoot().getLocale()));\r\n\t\t}\r\n\t}", "private Item initItem() {\n String name = inputName.getText().toString();\n int quantityToBuy = -1;\n if (!inputQuantityToBuy.getText().toString().equals(\"\"))\n quantityToBuy = Integer.parseInt(inputQuantityToBuy.getText().toString());\n String units = inputUnits.getText().toString();\n double price = 0;\n if (!inputPrice.getText().toString().equals(\"\"))\n price = Double.parseDouble(inputPrice.getText().toString());\n int calories = 0;\n if (!inputCalories.getText().toString().equals(\"\"))\n calories = Integer.parseInt(inputCalories.getText().toString());\n ArrayList<String> allergies = allergyActions.getAllergies();\n return new Item(name, 0, units, quantityToBuy, 0, allergies, calories, price);\n }", "public void addItem(Product p, int qty){\n //store info as an InventoryItem and add to items array\n this.items.add(new InventoryItem(p, qty));\n }", "protected abstract void addMaterialStats();", "public static TMaterial createEntity(EntityManager em) {\n TMaterial tMaterial = new TMaterial()\n .qty(DEFAULT_QTY)\n .hargaBeli(DEFAULT_HARGA_BELI)\n .hargaTotal(DEFAULT_HARGA_TOTAL)\n .inout(DEFAULT_INOUT);\n return tMaterial;\n }", "public void prepareBillOfMaterialsForCurrentItem() {\n newItemsToAdd = new ArrayList<>();\n InventoryBillOfMaterialItem iBom = new InventoryBillOfMaterialItem(getCurrent());\n InventoryBillOfMaterialItem.setBillOfMaterialsListForItem(getCurrent(), iBom);\n }", "public static void createItem(String inputCommand) {\r\n\t\tString[] value = inputCommand.split(\" \");\r\n\t\tif(value.length == 4 && \"create\".equalsIgnoreCase(value[0])) {\r\n\t\t\tInventory inventory = new Inventory();\r\n\t\t\tinventory.setItemName(value[1]);\r\n\t\t\tinventory.setItemCostPrice(Double.parseDouble(value[2]));\r\n\t\t\tinventory.setItemSellPrice(Double.parseDouble(value[3]));\r\n\t\t\tinventoryList.put(value[1], inventory);\r\n\t\t} else {\r\n\t\t\tSystem.out.println(\"Entered wrong input command\");\r\n\t\t}\r\n\t}", "public void addCostItem(CostItem item) throws CostManagerException;", "Item(){\r\n\t\tthis(0, new Weight(5), new DukatAmount(0));\r\n\t}", "protected void addInventoryItemType() {\n\t\tProperties props = new Properties();\n\n\t\t/* DEBUG\n\t\t\n\t\tSystem.out.println(typeNameTF.getText());\n\t\tSystem.out.println(unitsTF.getText());\n\t\tSystem.out.println(unitMeasureTF.getText());\n\t\tSystem.out.println(validityDaysTF.getText());\n\t\tSystem.out.println(reorderPointTF.getText());\n\t\tSystem.out.println(notesTF.getText());\n\t\tSystem.out.println(statusCB.getValue());\n\t\n\t\t*/ \n\n\t\t// Set the values.\n\t\tprops.setProperty(\"ItemTypeName\", typeNameTF.getText());\n\t\tprops.setProperty(\"Units\", unitsTF.getText());\n\t\tprops.setProperty(\"UnitMeasure\", unitMeasureTF.getText());\n\t\tprops.setProperty(\"ValidityDays\", validityDaysTF.getText());\n\t\tprops.setProperty(\"ReorderPoint\", reorderPointTF.getText());\n\t\tprops.setProperty(\"Notes\", notesTF.getText());\n\t\tprops.setProperty(\"Status\", (String) statusCB.getValue());\n\n\t\t// Create the inventory item type.\n\t\tInventoryItemType iit = new InventoryItemType(props);\n\n\t\t// Save it into the database.\n\t\tiit.update();\n\n\t\tpopulateFields();\n\t\t\n\t\t// Display message on GUI.\n\t\t//submitBTN.setVisible(false);\n\t\tcancelBTN.setText(\"Back\");\n\t\tmessageLBL.setText(\"Inventory Item Type added.\");\n\t}", "ExpMaterial createExpMaterial(Container container, Lsid lsid);", "public void makeTransaction(Item item, String type) {\n\t\tthis.item = item;\n\t\ttransactionType = type;\n\t}", "private void addRoomItems(int itemsToAdd)\n {\n\n // Adds up to 3 random items to a random room .\n if (!(itemsToAdd == 0)){\n\n for(int j = 0; j < itemsToAdd; j++){\n Item chooseItem = chooseValidItem(); \n Room chooseRoom = rooms.get(random.nextInt(rooms.size()));\n\n chooseRoom.getInventory().getItems().add(chooseItem);\n System.out.println(chooseRoom.getName()+\": \"+chooseItem.getName());\n\n }\n }\n }", "private Item mergeItem(Item newItem, List<Item> items) throws ItemException{\r\n \t\tfor (Item item2 : items) {\r\n \t\t\tif (!item2.isBought() && item2.getName().equals(newItem.getName())) {\r\n\t\t\t\t// sum price\r\n\t\t\t\titem2.setPrice(newItem.getPrice().add(item2.getPrice()));\r\n \t\t\t\tif (newItem.getUnit() == null && item2.getUnit() == null) {\r\n \t\t\t\t\t// Both have no unit --> item has now 2 pieces.\r\n \t\t\t\t\titem2.setQuantity(BigDecimal.valueOf(2), ItemUnit.PIECE);\r\n \t\t\t\t\treturn item2;\r\n \t\t\t\t} else if (newItem.getUnit() == null && item2.getUnit() == ItemUnit.PIECE) {\r\n \t\t\t\t\t// new Item has no unit, existing item has PIECE as unit. add one piece to the existing item.\r\n \t\t\t\t\titem2.setQuantity(item2.getQuantity().add(BigDecimal.ONE), ItemUnit.PIECE);\r\n \t\t\t\t\treturn item2;\r\n \t\t\t\t} else if (newItem.getUnit() != null && newItem.getUnit() == item2.getUnit()) {\r\n \t\t\t\t\t// Both have same unit --> add them together\r\n \t\t\t\t\tBigDecimal newQuantity = newItem.getQuantity().add(item2.getQuantity());\r\n \t\t\t\t\titem2.setQuantity(newQuantity, item2.getUnit());\r\n \t\t\t\t\treturn item2; // we want to save only one item.\r\n \t\t\t\t} else if (ItemUnit.MASSES.contains(newItem.getUnit()) && ItemUnit.MASSES.contains(item2.getUnit())) {\r\n \t\t\t\t\t// Both units are masses. Convert it first to grams and then add them.\r\n \t\t\t\t\tBigDecimal mass1 = newItem.getUnit()==ItemUnit.GRAM ? newItem.getQuantity():newItem.getQuantity().multiply(THOUSAND);\r\n \t\t\t\t\tBigDecimal mass2 = item2.getUnit()==ItemUnit.GRAM ? item2.getQuantity():item2.getQuantity().multiply(THOUSAND);\r\n \t\t\t\t\tBigDecimal finalMass = mass1.add(mass2);\r\n \t\t\t\t\tItemUnit unit = ItemUnit.GRAM;\r\n \t\t\t\t\tif (finalMass.compareTo(THOUSAND) > 0){\r\n \t\t\t\t\t\tfinalMass = finalMass.divide(THOUSAND);\r\n \t\t\t\t\t\tunit = ItemUnit.KILO_GRAM;\r\n \t\t\t\t\t}\r\n \t\t\t\t\titem2.setQuantity(finalMass, unit);\r\n \t\t\t\t\treturn item2;\r\n \t\t\t\t} else {\r\n \t\t\t\t\tthrow new ItemException();\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t}\r\n \t\treturn newItem;\r\n \t}", "public void add() {\n\t\tcart.add(item.createCopy());\n\t}", "private MerchantRecipe createMerchantRecipe(ItemStack item, ItemStack sellingItem, ItemStack item2) {\r\n MerchantRecipe recipe = new MerchantRecipe(sellingItem, 10000);\r\n recipe.setExperienceReward(false);\r\n recipe.addIngredient(item);\r\n recipe.addIngredient(item2);\r\n return recipe;\r\n }", "public Item createItem() {\n if(pickUpImplementation == null)\n {\n pickUpImplementation = new DefaultPickUp();\n }\n\n if(lookImplementation == null)\n {\n lookImplementation = new DefaultLook(R.string.default_look);\n }\n\n if(defaultItemInteraction == null)\n {\n throw new IllegalArgumentException(\"No default interaction specified!\");\n }\n\n\n return new Item(\n id,\n name,\n pickUpImplementation,\n lookImplementation,\n useImplementation,\n defaultItemInteraction\n );\n }", "public int addItem(Item item, int n) {\r\n if(isContradicting(item)){\r\n System.out.println(CONTRADICTING_MSG1+ item.getType()+CONTRADICTING_MSG2);\r\n return CONTRADICTING;\r\n }\r\n if (super.addItem(item, n) == ZERO) {\r\n if (unitMap.containsKey(item.getType())) {\r\n if ((n+ unitMap.get(item.getType()))* item.getVolume() > capacity * FIFTY_PERCENT) {\r\n return checkNewN(item,n, true);\r\n }\r\n //if less then 50%\r\n else {\r\n unitMap.put(item.getType(),unitMap.get(item.getType()) + n);\r\n availableCapacity -= item.getVolume() * n;\r\n return ZERO;\r\n }\r\n }\r\n //item not in map:\r\n else{\r\n if ((item.getVolume() * n) > capacity * 0.5){\r\n return checkNewN(item,n, false);\r\n }\r\n //if less then 50\r\n else {\r\n unitMap.put(item.getType(), n);\r\n availableCapacity -= item.getVolume() * n;\r\n return ZERO;\r\n }\r\n }\r\n }\r\n //no place in locker:\r\n else return NO_ITEMS_ADDED;\r\n }", "public static Item generate(){\n\n //this method lists a collection of new items. it then uses a random number generator\n //to pick one of the objects, and then returns the object so that the main method\n //can add it to the inventory.\n\n ItemType weapon = ItemType.weapon;\n Item IronSword = new Item(weapon, \"Iron Sword\", 8, 50, 10);\n Item GoldenSword = new Item(weapon, \"Golden Sword\", 10, 75, 15);\n Item AllumSword = new Item(weapon, \"Alluminum Sword\", 6, 35, 8);\n Item BowandQuiver = new Item(weapon, \"Bow & Quiver\", 4, 45, 7);\n Item BattleAxe = new Item(weapon, \"Battle Axe\", 12, 55, 13);\n\n ItemType armor = ItemType.armor;\n Item ChainChest = new Item(armor, \"Chain Mail Chestplate\", 8, 40, 30);\n Item IronChest = new Item(armor, \"Iron Chestplate\", 10, 50, 40);\n Item GoldenChest = new Item(armor, \"Golden Chestplate\", 12, 65, 50);\n Item ChainPants = new Item(armor, \"Chain Mail Pants\", 7, 40, 30);\n Item IronPants = new Item(armor, \"Iron Pants\", 9, 50, 40);\n Item GoldenPants = new Item(armor, \"Golden Pants\", 11, 65, 50);\n Item Helmet = new Item(armor, \"Helmet\", 5, 40, 20);\n\n ItemType other = ItemType.other;\n Item Bandage = new Item(other, \"Bandage\", 1, 2, 0);\n Item Wrench = new Item(other, \"Wrench\", 3, 10, 5);\n Item Bread = new Item(other, \"Bread Loaf\", 2, 4, 0);\n Item Water = new Item(other, \"Water Flask\", 3, 2, 0);\n\n Item Initializer = new Item(other, \"init\", 0, 0, 0);\n\t\tint ItemPick = RandomNum();\n Item chosen = Initializer;\n\n switch (ItemPick){\n case 1:\n chosen = IronSword;\n break;\n case 2:\n chosen = GoldenSword;\n break;\n case 3:\n chosen = AllumSword;\n break;\n case 4:\n chosen = BowandQuiver;\n break;\n case 5:\n chosen = BattleAxe;\n break;\n case 6:\n chosen = ChainChest;\n break;\n case 7:\n chosen = IronChest;\n break;\n case 8:\n chosen = GoldenChest;\n break;\n case 9:\n chosen = ChainPants;\n break;\n\t\t\t case 10:\n chosen = IronPants ;\n break;\n case 11:\n chosen = GoldenPants;\n break;\n case 12:\n chosen = Helmet;\n break;\n case 13:\n chosen = Bandage;\n break;\n case 14:\n chosen = Wrench;\n break;\n case 15:\n chosen = Bread;\n break;\n case 16:\n chosen = Water;\n break;\n }\n\n return chosen;\n }", "public ItemQuantity(Item item, int quantity) {\n this.item = item;\n this.quantity = quantity;\n }", "public void addMaterial(PlayerMaterialSql materialSql) {\n\t}", "private static void addItem( String name, Integer number ) {\n\t\tItem item = container.addItem( itemId );\n\t\tsetValues( name, number, item );\n\t}", "@Test\n void testAdding100Items() {\n Inventory inventory = new Inventory();\n int itemsToAdd = 100;\n\n assertEquals(0, inventory.getItems(\"\").size());\n\n for (int i = 0; i < itemsToAdd; i++) {\n inventory.addItem(\"XXXXXXXX\" + String.format(\"%02d\", i), \"Name\", 20.00, i);\n }\n\n assertEquals(100, inventory.getItems(\"\").size());\n }", "public Item(int id, String name, int quantity, double price, Supplier supplier){\r\n toolId = id;\r\n toolName = name;\r\n toolQuantity = quantity;\r\n toolPrice = price;\r\n toolSupplier = supplier;\r\n }", "public static void addItem(Inventory inv, String itemName, Material materialName, Integer index) {\r\n ItemStack is = new ItemStack(materialName);\r\n ItemMeta meta = is.getItemMeta();\r\n meta.setDisplayName(itemName);\r\n is.setItemMeta(meta);\r\n inv.setItem(index, is);\r\n }", "public FinalMysteryItem() {\n int randomIndex = new Random().nextInt(7);\n item = new Item(listOfPossibleNames[randomIndex], PRICE_TO_BUY);\n }", "void createSportItem (String name, String description, double price, String sportType);", "@POST\n @Path(\"{id : \\\\d+}/add_material\")\n @Consumes(\"application/json\")\n @Produces(\"application/json\")\n public AddWarehouseMaterialResponse addWarehouseMaterial(AddWarehouseMaterialRequest content,\n @QueryParam(\"token\") String token,\n @PathParam(\"id\") String id) {\n AddWarehouseMaterialRequest request = new AddWarehouseMaterialRequest();\n request.setToken(token);\n request.setWarehouseId(BigInteger.valueOf(Integer.parseInt(id)));\n request.setMaterialId(content.getMaterialId());\n request.setQuantity(content.getQuantity());\n request.setUnitPrice(content.getUnitPrice());\n return ws.addWarehouseMaterial(request);\n }", "public Material() {}", "QuoteItem createQuoteItem();", "protected abstract Item createTestItem3();", "public void addWarehouseStock(String name, int amount);", "void add(Item item);", "public void addProduct(Product item){\n inventory.add(item);\n }", "private void addProduct() {\n String type = console.readString(\"type (\\\"Shirt\\\", \\\"Pant\\\" or \\\"Shoes\\\"): \");\n String size = console.readString(\"\\nsize: \");\n int qty = console.readInt(\"\\nQty: \");\n int sku = console.readInt(\"\\nSKU: \");\n Double price = console.readDouble(\"\\nPrice: \");\n int reorderLevel = console.readInt(\"\\nReorder Level: \");\n daoLayer.addProduct(type, size, qty, sku, price, reorderLevel);\n\n }", "public abstract Quantity<Q> create(Number value, Unit<Q> unit);", "ItemStack make();", "public boolean addInventory(Inventory material) {\n boolean done = false;\n\n String sql = \"INSERT INTO inventory(model, comment) VALUES (?,?)\";\n\n try ( Connection con = connect(); PreparedStatement pstmt = con.prepareStatement(sql)) {\n pstmt.setString(1, material.getModel());\n pstmt.setString(2, material.getComment());\n pstmt.executeUpdate();\n done = true;\n } catch (SQLException e) {\n System.out.println(\"Error adding item on inventory\");\n System.out.println(e.getMessage());\n }\n\n return done;\n }", "public void addToInventory() {\r\n\t\tdo {\r\n\t\t\tint quantity = 0;\r\n\t\t\tString brand = getToken(\"Enter washer brand: \");\r\n\t\t\tString model = getToken(\"Enter washer model: \");\r\n\t\t\tWasher washer = store.searchWashers(brand + model);\r\n\t\t\tif (washer == null) {\r\n\t\t\t\tSystem.out.println(\"No such washer exists.\");\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\tquantity = getInteger(\"Enter quantity to add: \");\r\n\t\t\tboolean result = store.addWasherToInventory(brand, model, quantity);\r\n\t\t\tif(result) {\r\n\t\t\t\tSystem.out.println(\"Added \" + quantity + \" of \" + washer);\r\n\t\t\t}else {\r\n\t\t\t\tSystem.out.println(\"Washer could not be added to inventory.\");\r\n\t\t\t}\r\n\t\t\t\r\n\t\t} while (yesOrNo(\"Add more washers to the inventory?\"));\r\n\t}", "public TransactionItem addTransactionItem(int transactionId, int productId, int quantity)\n\t{\n\t\tConnect con=Connect.getConnection();\n\t\tcon.executeQuery(\"USE sudutmeong\");\n\t\tTransactionItem x=new TransactionItem();\n\t\tx.setTransactionId(transactionId);\n\t\tx.setProductId(productId);\n\t\tx.setQuantity(quantity);\n\t\tString query = \"INSERT INTO transactionitem VALUES (\"+transactionId+\",\" + productId + \",\"+ quantity +\")\";\n\t\tcon.executeUpdate(query);\n\t\treturn x;\n\t}", "IEquipableItem create(int power, int min, int max);", "public Item()\r\n\t{\r\n\t\tserialNum = 00000;\r\n\t\tweight = 0.0;\r\n\t}", "public int addItem(Itemset i);", "public void addToSale(ItemDTO item, int quantity){\n this.saleInfo.addItem(item, quantity);\n }", "public void createItem(View view) {\n \t\n String[] temp = getCurrentItemTypes();\n \n Intent intent = new Intent(this, CreateItem.class);\n intent.putExtra(EDIT, \"no\");\n intent.putExtra(TYPES, temp);\n startActivityForResult(intent, 1);\n }", "public void create(RecognizedItem item, SketchBook model) {\n }", "void addUses(Equipment newUses);", "Item(int i, String n, String c, double p) {\n this.id = i;\n this.name = n;\n this.category = c;\n this.price = p;\n }", "InvoiceItem addInvoiceItem(InvoiceItem invoiceItem);", "public void addItem(Item itemToAdd){\n\t\tif(!isFull()){\n\t\t\tint index = findFreeSlot();\n\t\t\tinventoryItems[index] = itemToAdd;\n\t\t}\n\t\telse{\n\t\t\tSystem.out.println(\"Inventory full.\");\n\t\t}\n\t\t\n\t}", "public void buy(RawMaterial m, double amount)\r\n throws NoMoneyException, DoesntExistException, NotEnoughException {\r\n if (!Main.materialMarket.getMaterials().contains(m)) \r\n throw new DoesntExistException(\"Can't find \" + m.getName());\r\n \r\n double tempPrice = amount*m.getValue()*(1+Main.materialMarket.markup);\r\n double price = tempPrice*m.getCurrency().getBasicRate();\r\n \r\n if (this.budget<price) throw new NoMoneyException(m);\r\n\r\n synchronized (this) {\r\n try {\r\n m.sell(amount);\r\n this.capital.put(m, amount);\r\n this.materials.put(m, amount);\r\n this.budget-=price;\r\n }\r\n catch (NotEnoughException e) {\r\n throw e;\r\n }\r\n\r\n }\r\n \r\n }", "void createBOM(BillOfMaterials BOM) throws DataException {\n try {\n con = Connector.connection(dbURL);\n String SQL = \"INSERT INTO `bills_of_materials` (`order_id`,`component_id`,`amount`) VALUES (?,?,?);\";\n ps = con.prepareStatement(SQL);\n int orderId = BOM.getOrderId();\n\n for (Map.Entry<Integer, Integer> entry : BOM.getComponents().entrySet()) {\n ps.setInt(1, orderId);\n ps.setInt(2, entry.getKey());\n ps.setInt(3, entry.getValue());\n ps.executeUpdate();\n }\n } catch (NullPointerException | SQLException e) {\n throw new DataException(e.getMessage());\n } finally {\n Connector.CloseConnection(ps, con);\n }\n }", "private static void createRecipe(int code, String name, int quantity ) {\n\t\tString sqlTotalkcal=\"select sum(kcal) from ingredient where code in (select code_ingredient from ingredientxrecipe where code_recipe=\"+code+\")\";\r\n\t\tString sqlTotalcarb=\"select sum(carbohidrates) from ingredient where code in (select code_ingredient from ingredientxrecipe where code_recipe=\"+code+\")\";\r\n\t\tString sqlTotalProt=\"select sum(Proteines) from ingredient where code in (select code_ingredient from ingredientxrecipe where code_recipe=\"+code+\")\";\r\n\t\tString sqlTotalFat=\"select sum(Fat) from ingredient where code in (select code_ingredient from ingredientxrecipe where code_recipe=\"+code+\")\";\r\n\t\tString sqlTotalSalt=\"select sum(Salt) from ingredient where code in (select code_ingredient from ingredientxrecipe where code_recipe=\"+code+\")\";\r\n\t\tString sqltotalAllergen=\"select codeAllergen from allergenxingredients where codeIngredient in (select code_ingredient from ingredientxrecipe where code_recipe=\"+code+\")\";\r\n\t\t\r\n\t\t//recuperar datos\r\n\t\t\r\n\t\ttry {\r\n\t\t\tdouble kcal = dataRecovery(sqlTotalkcal);\r\n\t\t\tdouble carb = dataRecovery(sqlTotalcarb);\r\n\t\t\tdouble prot = dataRecovery(sqlTotalProt);\r\n\t\t\tdouble fat = dataRecovery(sqlTotalFat);\r\n\t\t\tdouble salt = dataRecovery(sqlTotalSalt);\r\n\t\t\tString aler = dataRecoveryAllergenList(sqltotalAllergen);\r\n\t\t\tcreateRecipeData(code, name, quantity, kcal, carb, prot, fat, salt, aler);\r\n\t\t} catch (Exception e) {\r\n\t\t\tSystem.out.println(\"Hubo un error al crear la receta\");\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "@PostMapping(\"/materials\")\n public ResponseEntity<MaterialsDTO> createMaterials(@Valid @RequestBody MaterialsDTO materialsDTO) throws URISyntaxException {\n log.debug(\"REST request to save Materials : {}\", materialsDTO);\n if (materialsDTO.getId() != null) {\n throw new BadRequestAlertException(\"A new materials cannot already have an ID\", ENTITY_NAME, \"idexists\");\n }\n MaterialsDTO result = materialsService.save(materialsDTO);\n return ResponseEntity.created(new URI(\"/api/materials/\" + result.getId()))\n .headers(HeaderUtil.createEntityCreationAlert(ENTITY_NAME, result.getId().toString()))\n .body(result);\n }", "@Test\n public void testAddMaterialOneMaterial() {\n String material = \"material\";\n planned.addMaterials(material);\n\n assertEquals(planned.getMaterials().size(), 1);\n\n assertTrue(planned.getMaterials().contains(material));\n\n }", "@attribute(value = \"\", required = false)\r\n\tpublic void addItem(Item i) {\r\n\t}", "public Item(String des, double w){\n description = des;\n weight = w;\n }", "public long createntry(String date, String quantity, String capacity,String inout,String desci) {\n\t\tContentValues cv=new ContentValues();\n\t\tcv.put(Drum_date, date);\n\t\tcv.put(Drum_Capacity, capacity);\n\t\t\n\t\tcv.put(Drum_Quantity, Integer.parseInt(quantity));\n\t\tcv.put(Drum_inout, inout);\n\t\tcv.put(Drum_desci, desci);\n\t\treturn ourDatabase.insert(DATABASE_TABLE, null, cv);\n\t}", "@Override\n public void onCreate(SQLiteDatabase db) {\n db.execSQL(\n \"create table itemstable \" +\n \"(id integer primary key, itemcost text,itemkg text, itemQuantity text)\"\n );\n\n }", "Product addOneProduct(String name, String imgNameBarcode, String imgName, String barcode) throws Exception;", "OurIfcMaterial createOurIfcMaterial();", "public void addItem(Item item){\r\n items.add(item);\r\n total = items.getTotal();\r\n }", "public ItemBuilder setMaterial(Material material) {\r\n\t\tthis.material = material;\r\n\t\treturn this;\r\n\t}", "public OrderItem(MenuItem item, int qty){\r\n\t\tthis.menuItem = item;\r\n\t\tthis.quantity = qty;\r\n\t}", "public void createInventoryReward() {\n if (inventoryEntityToRetrieve == null) {\n try {\n inventoryEntityToRetrieve = RandomBenefitModel.getInventoryRewards(application, encounter, characterVM.getDistance());\n } catch (JSONException e) {\n e.printStackTrace();\n }\n }\n }", "Item(String name, String description, String userRequirements, int amount, Condition condition, boolean reservable, int locationID) {\n this.name = name;\n this.description = description;\n this.userRequirements = userRequirements;\n this.ID = nextID;\n nextID++;\n this.amount = amount;\n this.condition = condition;\n this.reservable = reservable;\n this.locationID = locationID;\n }", "@Override\r\n\t\tpublic boolean createItem() {\n\t\t\treturn false;\r\n\t\t}", "@Test\n\tpublic void testAddInventory() throws InventoryException {\n\t\tcoffeeMaker.addInventory(\"4\",\"7\",\"0\",\"9\");\n\t}", "public Item createNew(int xpos, int ypos) {\r\n Item i = new Item(name, id);\r\n i.setPosition(xpos, ypos);\r\n return i;\r\n }", "public void add(Material m) {\r\n\t\tthis.materials.add(m);\r\n\t}", "public static ItemStack createGuiItem(final Material material, final String name, final String... lore) {\n\t\tfinal org.bukkit.inventory.ItemStack item = new ItemStack(material, 1);\n\t\tfinal ItemMeta meta = item.getItemMeta();\n\n\t\t// Set the name of the item\n\t\tmeta.setDisplayName(name);\n\n\t\t// Set the lore of the item\n\t\tmeta.setLore(Arrays.asList(lore));\n\n\n\t\titem.setItemMeta(meta);\n\n\t\treturn item;\n\t}" ]
[ "0.7132935", "0.68513393", "0.6772633", "0.67303467", "0.65429723", "0.6507921", "0.63748723", "0.6362045", "0.63072616", "0.62647796", "0.6197794", "0.61237645", "0.6089749", "0.6082919", "0.6080662", "0.6075107", "0.6068314", "0.5997931", "0.5996719", "0.5996128", "0.5967453", "0.5880745", "0.58498967", "0.5849143", "0.5841145", "0.5839103", "0.58288014", "0.5826105", "0.57916486", "0.5785697", "0.5780839", "0.57782274", "0.57616925", "0.57605565", "0.57480353", "0.57461816", "0.5745167", "0.57347417", "0.5730208", "0.56981486", "0.5697515", "0.56864893", "0.5680186", "0.567129", "0.56668276", "0.5650815", "0.5644231", "0.5639255", "0.5637389", "0.56266856", "0.5619767", "0.5616229", "0.56146365", "0.5613684", "0.55904245", "0.558786", "0.5576399", "0.55712384", "0.55699533", "0.55641705", "0.55596054", "0.5549292", "0.554223", "0.5538364", "0.55377877", "0.5536844", "0.55353236", "0.5533234", "0.5522409", "0.551981", "0.55140746", "0.5489194", "0.5487684", "0.5486149", "0.5485455", "0.5485439", "0.54815716", "0.5472922", "0.54722613", "0.5472011", "0.54657334", "0.5456394", "0.545437", "0.544644", "0.5445058", "0.54265726", "0.5415426", "0.5412521", "0.54120743", "0.5399858", "0.5395373", "0.538826", "0.5388221", "0.53850144", "0.5382776", "0.5382698", "0.5382336", "0.5377274", "0.5371856", "0.53678167" ]
0.61341804
11
Create Item (Material + Amount + SubID)
public ItemBuilder(Material material, int amount, byte SubID) { itemstack = new ItemStack(material, amount, SubID); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void createItem (String name, String description, double price);", "Quantity createQuantity();", "void createMaterial(Material material) throws CreateException;", "public ItemStack generateItem(){\n\t\tItemStack item = new ItemStack(material);\n\t\tif(damage >= 0) item.setDurability(damage);\n\t\t\n\t\tif(itemName.isEmpty() && loreLine.isEmpty()) return item;\n\t\t\n\t\tItemMeta meta = item.getItemMeta();\n\t\tif(meta == null) return item;\n\t\t\n\t\tmeta.setDisplayName(itemName);\n\t\tmeta.setLore(Arrays.asList(loreLine));\n\t\titem.setItemMeta(meta);\n\t\t\n\t\treturn item;\n\t}", "public void insertItemDetails(String itemName, Integer quantityOfItem, Double rateOfItem);", "protected abstract void makeItem();", "@Override\n public Item createItem(int itemNum, Item item) throws VendingMachinePersistenceException {\n loadItemFile();\n Item newItem = itemMap.put(itemNum, item);\n writeItemFile();\n return newItem;\n }", "@Override\n\tpublic Item create() {\n\t\tLOGGER.info(\"Shoe Name\");\n\t\tString item_name = util.getString();\n\t\tLOGGER.info(\"Shoe Size\");\n\t\tdouble size = util.getDouble();\n\t\tLOGGER.info(\"Set Price\");\n\t\tdouble price = util.getDouble();\n\t\tLOGGER.info(\"Number in Stock\");\n\t\tlong stock = util.getLong();\n\t\tItem newItem = itemDAO.create(new Item(item_name, size, price, stock));\n\t\tLOGGER.info(\"\\n\");\n\t\treturn newItem;\n\t}", "public void addItemElementsFromBillOfMaterials(Item item) throws CdbException {\n List<InventoryBillOfMaterialItem> bomItems = item.getInventoryDomainBillOfMaterialList();\n\n if (bomItems != null) {\n for (InventoryBillOfMaterialItem bomItem : bomItems) {\n if (bomItem.getState().equals(InventoryBillOfMaterialItemStates.unspecifiedOptional.getValue())) {\n continue;\n }\n\n // Check if current catalog item element already has an item element defined. \n ItemElement catalogItemElement = bomItem.getCatalogItemElement();\n ItemElement currentInventoryItemElement = null;\n for (ItemElement inventoryItemElement : item.getFullItemElementList()) {\n if (inventoryItemElement.getDerivedFromItemElement() == catalogItemElement) {\n currentInventoryItemElement = inventoryItemElement;\n logger.debug(\"Updating element \" + currentInventoryItemElement + \" to item \" + item);\n break;\n }\n }\n\n if (currentInventoryItemElement == null) {\n currentInventoryItemElement = new ItemElement();\n currentInventoryItemElement.init(item, bomItem.getCatalogItemElement());\n item.getFullItemElementList().add(currentInventoryItemElement);\n logger.debug(\"Creating instance adding element \" + currentInventoryItemElement + \" to item \" + item);\n }\n\n // User has specified to create a new item for this bill of materials item. \n String currentBomState = bomItem.getState();\n if (currentBomState.equals(InventoryBillOfMaterialItemStates.newItem.getValue())\n || currentBomState.equals(InventoryBillOfMaterialItemStates.existingItem.getValue())) {\n if (bomItem.getInventoryItem() == null) {\n\n String actionWord = \"defined\";\n if (currentBomState.equals(InventoryBillOfMaterialItemStates.existingItem.getValue())) {\n actionWord = \"selected\";\n }\n\n throw new CdbException(\"An item for: \" + bomItem.getCatalogItemElement().getName() + \" is not \" + actionWord + \".\");\n }\n\n Item inventoryItem = bomItem.getInventoryItem();\n\n // No need to do that for existing items. \n if (currentBomState.equals(InventoryBillOfMaterialItemStates.newItem.getValue())) {\n addItemElementsFromBillOfMaterials(inventoryItem);\n currentInventoryItemElement.setContainedItem(inventoryItem);\n\n } else if (currentBomState.equals(InventoryBillOfMaterialItemStates.existingItem.getValue())) {\n if (currentInventoryItemElement.getContainedItem() == inventoryItem == false) {\n currentInventoryItemElement.setContainedItem(itemFacade.find(inventoryItem.getId()));\n }\n }\n } else if (currentBomState.equals(InventoryBillOfMaterialItemStates.placeholder.getValue())) {\n currentInventoryItemElement.setContainedItem(null);\n }\n\n // Use permissions defined in parent of the item for the item element. \n updateItemElementPermissionsToItem(currentInventoryItemElement, bomItem.getParentItemInstance());\n }\n }\n\n }", "Items(double cost){\n\tthis.cost=cost;\n\titemId++;\n\tcurrentID=itemId;\n}", "public static ItemStack createItem(String customName, Material material, String ID) {\r\n ItemStack is = new ItemStack(material);\r\n ItemMeta isMeta = is.getItemMeta();\r\n isMeta.setDisplayName(customName); //you can even set color\r\n ArrayList<String> lore = new ArrayList<>();\r\n lore.add(ID);\r\n isMeta.setLore(lore);\r\n is.setItemMeta(isMeta);\r\n return is;\r\n }", "public ItemStack createItem(ItemType type, int damage,List<Text> lore);", "public void create_crystal() {\n\t\tcrystalQuantity[1] += (1+create_modifier);\n\t\tautomerge();\n\t\tcollection();\n\t}", "int insertGenDetail(Integer uid, Integer merid, Double paymoney, Double sendmoney, Double tomoney, Double balance, Double topupbalance, Double givebalance, String ordernum, Date createTime, Integer paysource, String remark);", "ShipmentItem createShipmentItem();", "org.hl7.fhir.Quantity addNewValueQuantity();", "public InventoryItem(){\r\n this.itemName = \"TBD\";\r\n this.sku = 0;\r\n this.price = 0.0;\r\n this.quantity = 0;\r\n nItems++;\r\n }", "public void buildItems() {\n try (PreparedStatement prep = Database.getConnection()\n .prepareStatement(\"CREATE TABLE IF NOT\"\n + \" EXISTS items (order_id TEXT, item TEXT, FOREIGN KEY (order_id)\"\n + \" REFERENCES orders(id) ON DELETE CASCADE ON UPDATE CASCADE);\")) {\n prep.executeUpdate();\n } catch (final SQLException exc) {\n exc.printStackTrace();\n }\n }", "InvoiceItem addInvoiceItem(InvoiceItem invoiceItem);", "private void makeObject() {\n\t\t\n\t\tItem I1= new Item(1,\"Cap\",10.0f,\"to protect from sun\");\n\t\tItemMap.put(1, I1);\n\t\t\n\t\tItem I2= new Item(2,\"phone\",100.0f,\"Conversation\");\n\t\tItemMap.put(2, I2);\n\t\t\n\t\tSystem.out.println(\"Objects Inserted\");\n\t}", "public static Medicine add(int id, int rackNo, int cabinetNo, String Name, int unitCost, int sales){\n // save all information from text iputs to medicine object\n Medicine med = new Medicine();\n med.setMedicineId(id);\n med.setRackNo(rackNo);\n med.setCabinetNo(cabinetNo);\n med.setSupplierName(Name);\n med.setUnitCost(unitCost);\n med.setSalesPrice(sales); \n return med;\n }", "public int addItem(Item i);", "@Override\n public ID createItem(@NotNull String uid) {\n final long startNs = myStats != null ? System.nanoTime() : 0;\n final ID result = createItemImpl(uid);\n if (myStats != null) {\n myStats.incrementCounter(StatsCounters.itemsCreationDurationNs, System.nanoTime() - startNs);\n }\n return result;\n }", "QuoteItem createQuoteItem();", "public void createItemInInventory(Item newItem) {\n\t\tinventory.createItem(newItem);\n\t}", "protected abstract Item createTestItem3();", "private Item mergeItem(Item newItem, List<Item> items) throws ItemException{\r\n \t\tfor (Item item2 : items) {\r\n \t\t\tif (!item2.isBought() && item2.getName().equals(newItem.getName())) {\r\n\t\t\t\t// sum price\r\n\t\t\t\titem2.setPrice(newItem.getPrice().add(item2.getPrice()));\r\n \t\t\t\tif (newItem.getUnit() == null && item2.getUnit() == null) {\r\n \t\t\t\t\t// Both have no unit --> item has now 2 pieces.\r\n \t\t\t\t\titem2.setQuantity(BigDecimal.valueOf(2), ItemUnit.PIECE);\r\n \t\t\t\t\treturn item2;\r\n \t\t\t\t} else if (newItem.getUnit() == null && item2.getUnit() == ItemUnit.PIECE) {\r\n \t\t\t\t\t// new Item has no unit, existing item has PIECE as unit. add one piece to the existing item.\r\n \t\t\t\t\titem2.setQuantity(item2.getQuantity().add(BigDecimal.ONE), ItemUnit.PIECE);\r\n \t\t\t\t\treturn item2;\r\n \t\t\t\t} else if (newItem.getUnit() != null && newItem.getUnit() == item2.getUnit()) {\r\n \t\t\t\t\t// Both have same unit --> add them together\r\n \t\t\t\t\tBigDecimal newQuantity = newItem.getQuantity().add(item2.getQuantity());\r\n \t\t\t\t\titem2.setQuantity(newQuantity, item2.getUnit());\r\n \t\t\t\t\treturn item2; // we want to save only one item.\r\n \t\t\t\t} else if (ItemUnit.MASSES.contains(newItem.getUnit()) && ItemUnit.MASSES.contains(item2.getUnit())) {\r\n \t\t\t\t\t// Both units are masses. Convert it first to grams and then add them.\r\n \t\t\t\t\tBigDecimal mass1 = newItem.getUnit()==ItemUnit.GRAM ? newItem.getQuantity():newItem.getQuantity().multiply(THOUSAND);\r\n \t\t\t\t\tBigDecimal mass2 = item2.getUnit()==ItemUnit.GRAM ? item2.getQuantity():item2.getQuantity().multiply(THOUSAND);\r\n \t\t\t\t\tBigDecimal finalMass = mass1.add(mass2);\r\n \t\t\t\t\tItemUnit unit = ItemUnit.GRAM;\r\n \t\t\t\t\tif (finalMass.compareTo(THOUSAND) > 0){\r\n \t\t\t\t\t\tfinalMass = finalMass.divide(THOUSAND);\r\n \t\t\t\t\t\tunit = ItemUnit.KILO_GRAM;\r\n \t\t\t\t\t}\r\n \t\t\t\t\titem2.setQuantity(finalMass, unit);\r\n \t\t\t\t\treturn item2;\r\n \t\t\t\t} else {\r\n \t\t\t\t\tthrow new ItemException();\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t}\r\n \t\treturn newItem;\r\n \t}", "ExpMaterial createExpMaterial(Container container, Lsid lsid);", "public int addItem(Itemset i);", "@POST\n @Path(\"{id : \\\\d+}/add_material\")\n @Consumes(\"application/json\")\n @Produces(\"application/json\")\n public AddWarehouseMaterialResponse addWarehouseMaterial(AddWarehouseMaterialRequest content,\n @QueryParam(\"token\") String token,\n @PathParam(\"id\") String id) {\n AddWarehouseMaterialRequest request = new AddWarehouseMaterialRequest();\n request.setToken(token);\n request.setWarehouseId(BigInteger.valueOf(Integer.parseInt(id)));\n request.setMaterialId(content.getMaterialId());\n request.setQuantity(content.getQuantity());\n request.setUnitPrice(content.getUnitPrice());\n return ws.addWarehouseMaterial(request);\n }", "public Material create();", "public long createntry(String date, String quantity, String capacity,String inout,String desci) {\n\t\tContentValues cv=new ContentValues();\n\t\tcv.put(Drum_date, date);\n\t\tcv.put(Drum_Capacity, capacity);\n\t\t\n\t\tcv.put(Drum_Quantity, Integer.parseInt(quantity));\n\t\tcv.put(Drum_inout, inout);\n\t\tcv.put(Drum_desci, desci);\n\t\treturn ourDatabase.insert(DATABASE_TABLE, null, cv);\n\t}", "public static void createItem(String inputCommand) {\r\n\t\tString[] value = inputCommand.split(\" \");\r\n\t\tif(value.length == 4 && \"create\".equalsIgnoreCase(value[0])) {\r\n\t\t\tInventory inventory = new Inventory();\r\n\t\t\tinventory.setItemName(value[1]);\r\n\t\t\tinventory.setItemCostPrice(Double.parseDouble(value[2]));\r\n\t\t\tinventory.setItemSellPrice(Double.parseDouble(value[3]));\r\n\t\t\tinventoryList.put(value[1], inventory);\r\n\t\t} else {\r\n\t\t\tSystem.out.println(\"Entered wrong input command\");\r\n\t\t}\r\n\t}", "void createBOM(BillOfMaterials BOM) throws DataException {\n try {\n con = Connector.connection(dbURL);\n String SQL = \"INSERT INTO `bills_of_materials` (`order_id`,`component_id`,`amount`) VALUES (?,?,?);\";\n ps = con.prepareStatement(SQL);\n int orderId = BOM.getOrderId();\n\n for (Map.Entry<Integer, Integer> entry : BOM.getComponents().entrySet()) {\n ps.setInt(1, orderId);\n ps.setInt(2, entry.getKey());\n ps.setInt(3, entry.getValue());\n ps.executeUpdate();\n }\n } catch (NullPointerException | SQLException e) {\n throw new DataException(e.getMessage());\n } finally {\n Connector.CloseConnection(ps, con);\n }\n }", "public void doCreateItem() {\r\n\t\tlogger.info(\"Se procede a crear el book \" + newItem.getDescription());\r\n\t\tBook entity = newItem.getEntity();\r\n\t\tentity.setUser(Global.activeUser());\r\n\t\tentity.setBookBalance(BigDecimal.ZERO);\r\n\t\tentity.setTotalBudget(BigDecimal.ZERO);\r\n\t\tentity.setTotalIncome(BigDecimal.ZERO);\r\n\t\tentity.setTotalExpenses(BigDecimal.ZERO);\r\n\t\tentity = bookService.create(entity);\r\n\r\n\t\t// Actualizar el mapa de books\r\n\t\tGlobalBook.instance().put(new BookData(entity));\r\n\r\n\t\tlogger.info(\"Se ha creado el book \" + newItem.getDescription());\r\n\t\tnewItem = new BookData(new Book());\r\n\t\tFacesContext.getCurrentInstance().addMessage(null,\r\n\t\t\t\tnew FacesMessage(FacesMessage.SEVERITY_INFO, \"Libro creado\", \"Libro creado correctamente\"));\r\n\t}", "protected abstract Item createTestItem1();", "public void makeTransaction(Item item, String type) {\n\t\tthis.item = item;\n\t\ttransactionType = type;\n\t}", "int insert(SrmFundItem record);", "@Override\n\tpublic int create(Subordination entity) throws DBOperationException {\n\t\tPreparedStatement statement = null;\n\t\tint update = 0;\n\t\ttry {\n\t\t\tstatement = connection.prepareStatement(SUBORDINATION_ADD);\n\t\t\tstatement.setInt(1, entity.getSender().getEmployeeID());\n\t\t\tstatement.setInt(2, entity.getDocType().getDocTypeID());\n\t\t\tstatement.setInt(3, entity.getReceiver().getEmployeeID());\n\t\t\tupdate = statement.executeUpdate();\n\t\t\tstatement.close();\n\t\t} catch (SQLException e) {\n\t\t\tthrow new DBOperationException(\"Subordination not created. DB error.\", e);\n\t\t} \n\t\treturn update;\n\t}", "public void addItem() {\n\t\tScanner scanner = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter Item Name: \");\n\t\tString itemName = scanner.nextLine();\n\t\tSystem.out.print(\"Enter Item Description: \");\n\t\tString itemDescription = scanner.nextLine();\n\t\tSystem.out.print(\"Enter minimum bid price for item: $\");\n\t\tdouble basePrice = scanner.nextDouble();\n\t\tLocalDate createDate = LocalDate.now();\n\t\tItem item = new Item(itemName, itemDescription, basePrice, createDate);\n\t\taddItem(item);\n\t}", "public void prepareBillOfMaterialsForCurrentItem() {\n newItemsToAdd = new ArrayList<>();\n InventoryBillOfMaterialItem iBom = new InventoryBillOfMaterialItem(getCurrent());\n InventoryBillOfMaterialItem.setBillOfMaterialsListForItem(getCurrent(), iBom);\n }", "public ItemBuilder(Material material, int amount) {\n\t\titemstack = new ItemStack(material, amount);\n\t}", "Item(){\r\n\t\tthis(0, new Weight(5), new DukatAmount(0));\r\n\t}", "private void createItems()\n {\n Item belt, nappies, phone, money, cigarretes, \n jacket, cereal, shoes, keys, comics, bra, \n bread, bowl, computer;\n\n belt = new Item(2,\"Keeps something from falling\",\"Belt\");\n nappies = new Item(7,\"Holds the unspeakable\",\"Nappies\");\n phone = new Item(4, \"A electronic device that holds every answer\",\"Iphone 10\");\n money = new Item(1, \"A form of currency\",\"Money\");\n cigarretes = new Item(2,\"It's bad for health\",\"Cigarretes\");\n jacket = new Item(3,\"Keeps you warm and cozy\", \"Jacket\");\n cereal = new Item(3, \"What you eat for breakfast\",\"Kellog's Rice Kripsies\");\n shoes = new Item(5,\"Used for walking\", \"Sneakers\");\n keys = new Item(2, \"Unlock stuff\", \"Keys\");\n comics = new Item(2, \"A popular comic\",\"Batman Chronicles\");\n bra = new Item(3,\"What is this thing?, Eeeewww\", \"Bra\");\n bread = new Item(6,\"Your best source of carbohydrates\",\"Bread\");\n bowl = new Item(4,\"where food is placed\",\"Plate\");\n computer = new Item(10,\"A computational machine\",\"Computer\");\n\n items.add(belt);\n items.add(nappies);\n items.add(phone);\n items.add(money);\n items.add(cigarretes);\n items.add(jacket);\n items.add(cereal);\n items.add(shoes);\n items.add(keys);\n items.add(comics);\n items.add(bra);\n items.add(bread);\n items.add(bowl);\n items.add(computer);\n }", "protected abstract Item createTestItem2();", "Item(long ID, DukatAmount price){\r\n\t\tthis(ID, new Weight(5), price);\r\n\t}", "public int addItem(Item item, int n) {\r\n if(isContradicting(item)){\r\n System.out.println(CONTRADICTING_MSG1+ item.getType()+CONTRADICTING_MSG2);\r\n return CONTRADICTING;\r\n }\r\n if (super.addItem(item, n) == ZERO) {\r\n if (unitMap.containsKey(item.getType())) {\r\n if ((n+ unitMap.get(item.getType()))* item.getVolume() > capacity * FIFTY_PERCENT) {\r\n return checkNewN(item,n, true);\r\n }\r\n //if less then 50%\r\n else {\r\n unitMap.put(item.getType(),unitMap.get(item.getType()) + n);\r\n availableCapacity -= item.getVolume() * n;\r\n return ZERO;\r\n }\r\n }\r\n //item not in map:\r\n else{\r\n if ((item.getVolume() * n) > capacity * 0.5){\r\n return checkNewN(item,n, false);\r\n }\r\n //if less then 50\r\n else {\r\n unitMap.put(item.getType(), n);\r\n availableCapacity -= item.getVolume() * n;\r\n return ZERO;\r\n }\r\n }\r\n }\r\n //no place in locker:\r\n else return NO_ITEMS_ADDED;\r\n }", "public Item()\r\n\t{\r\n\t\tserialNum = 00000;\r\n\t\tweight = 0.0;\r\n\t}", "int insert(ItemStockDO record);", "int insert(ItemStockDO record);", "private MerchantRecipe createMerchantRecipe(ItemStack item, ItemStack sellingItem, ItemStack item2) {\r\n MerchantRecipe recipe = new MerchantRecipe(sellingItem, 10000);\r\n recipe.setExperienceReward(false);\r\n recipe.addIngredient(item);\r\n recipe.addIngredient(item2);\r\n return recipe;\r\n }", "public static void createItems(){\n Registry.register(Registry.ITEM, new Identifier(nameSpace, \"breadly\"), BREADLY);\n Registry.register(Registry.ITEM, new Identifier(nameSpace, \"hard_boiled_egg\"), HARD_BOILED_EGG);\n\n\n Registry.register(Registry.ITEM, new Identifier(nameSpace, \"ender_dragon_spawn_egg\"), ENDER_DRAGON_SPAWN_EGG);\n Registry.register(Registry.ITEM, new Identifier(nameSpace, \"wither_spawn_egg\"), WITHER_SPAWN_EGG);\n Registry.register(Registry.ITEM, new Identifier(nameSpace, \"illusioner_spawn_egg\"), ILLUSIONER_SPAWN_EGG);\n Registry.register(Registry.ITEM, new Identifier(nameSpace, \"giant_spawn_egg\"), GIANT_SPAWN_EGG);\n Registry.register(Registry.ITEM, new Identifier(nameSpace, \"spawn_spawn_egg\"), SPAWN_SPAWN_EGG);\n }", "public void addItem() {\r\n\t\tFacesContext fc = FacesContext.getCurrentInstance();\r\n\t\tif (itemInvoice.getQuantidade() <= itemPO.getQuantidadeSaldo()) {\r\n\t\t\tBigDecimal total = itemInvoice.getPrecoUnit().multiply(\r\n\t\t\t\t\tnew BigDecimal(itemInvoice.getQuantidade()));\r\n\t\t\titemInvoice.setTotal(total);\r\n\t\t\tif (!editarItem) {\r\n\r\n\t\t\t\tif (itemInvoice.getPrecoUnit() == null) {\r\n\t\t\t\t\titemInvoice.setPrecoUnit(new BigDecimal(0.0));\r\n\t\t\t\t}\r\n\t\t\t\tif (itemInvoice.getQuantidade() == null) {\r\n\t\t\t\t\titemInvoice.setQuantidade(0);\r\n\t\t\t\t}\r\n\t\t\t\titemInvoice.setInvoice(invoice);\r\n\r\n\t\t\t\tinvoice.getItensInvoice().add(itemInvoice);\r\n\r\n\t\t\t} else {\r\n\t\t\t\tinvoice.getItensInvoice().set(\r\n\t\t\t\t\t\tinvoice.getItensInvoice().indexOf(itemInvoice),\r\n\t\t\t\t\t\titemInvoice);\r\n\t\t\t}\r\n\t\t\tcarregarTotais();\r\n\t\t\tinicializarItemInvoice();\r\n\t\t\trequired = false;\r\n\t\t} else {\r\n\r\n\t\t\tMessages.adicionaMensagemDeInfo(TemplateMessageHelper.getMessage(\r\n\t\t\t\t\tMensagensSistema.INVOICE, \"lblQtdMaioSaldo\", fc\r\n\t\t\t\t\t\t\t.getViewRoot().getLocale()));\r\n\t\t}\r\n\t}", "@Test\n void testAdding100Items() {\n Inventory inventory = new Inventory();\n int itemsToAdd = 100;\n\n assertEquals(0, inventory.getItems(\"\").size());\n\n for (int i = 0; i < itemsToAdd; i++) {\n inventory.addItem(\"XXXXXXXX\" + String.format(\"%02d\", i), \"Name\", 20.00, i);\n }\n\n assertEquals(100, inventory.getItems(\"\").size());\n }", "public InventoryNew(String server, String username, String password, float itemCostFromSup, float itemCostToCust, String itemDesc, int itemInsCovg, int itemPrescription, int supNum){\n\t\tcreateConnection(server,username,password,pharmacyName);\n\t\tinsert(itemCostFromSup,itemCostToCust,itemDesc,itemInsCovg,itemPrescription, supNum,false);\n\t}", "IEquipableItem create(int power, int min, int max);", "@Test\n\tpublic void testAddItem() throws IOException{\n\t\tModel.addItem(item, amount + \"\");\n\t\tassertEquals(amount + \"\", Model.hash.get(item));\n\t\t\n\t}", "public Item(int id, String name, int quantity, double price, Supplier supplier){\r\n toolId = id;\r\n toolName = name;\r\n toolQuantity = quantity;\r\n toolPrice = price;\r\n toolSupplier = supplier;\r\n }", "void create(MenuTO menuTO, List<Integer> itemsIDList) throws DAOException;", "public GIPIQuoteItemMC( \tfinal Integer quoteId, \t\tfinal Integer itemNo, \t\tfinal String plateNo,\n \t\t\t \t\t\t\t\tfinal String motorNo, \t\tfinal String serialNo, \t\tfinal String sublineTypeCd,\n \t\t\t \t\t\t\t\tfinal Integer motType, \t\tfinal Integer carCompanyCd, final Integer cocYy,\n \t\t\t \t\t\t\t\tfinal Integer cocSeqNo, \tfinal Integer cocSerialNo, \tfinal String cocType,\n \t\t\t \t\t\t\t\tfinal BigDecimal repairLim, final String color, \t\tfinal String modelYear, \n \t\t\t \t\t\t\t\tfinal String make,\t\t\tfinal BigDecimal estValue, \tfinal BigDecimal towing, \t\n \t\t\t \t\t\t\t\tfinal String assignee,\t\tfinal Integer noOfPass, \tfinal String tariffZone, \t\n\t\t\t\t\t \t\t\tfinal Date cocIssueDate,\tfinal String mvFileNo, \t\tfinal String acquiredFrom, \t\n\t\t\t\t\t \t\t\tfinal String ctvTag,\t\tfinal Integer typeOfBodyCd, final String unladenWt, \t\n\t\t\t\t\t \t\t\tfinal Integer makeCd,\t\tfinal Integer seriesCd,\t \tfinal String basicColorCd,\t\n\t\t\t\t\t \t\t\tfinal Integer colorCd,\t\tfinal String origin, \t\tfinal String destination, \t\n\t\t\t\t\t \t\t\tfinal String cocAtcn,\t\tfinal String userId, \t\tfinal Date lastUpdate, \t\t\n\t\t\t\t\t \t\t\tfinal String sublineCd)\t{\n \t\t\n \t\tthis.quoteId = quoteId;\n \t\tthis.itemNo = itemNo;\n \t\tthis.plateNo = plateNo;\n \t\tthis.motorNo = motorNo;\n \t\tthis.serialNo = serialNo;\n \t\tthis.sublineTypeCd = sublineTypeCd;\n \t\tthis.motType = motType;\n \t\tthis.carCompanyCd = carCompanyCd;\n \t\tthis.cocYy = cocYy;\n \t\tthis.cocSeqNo = cocSeqNo;\n \t\tthis.cocSerialNo = cocSerialNo;\n \t\tthis.cocType = cocType;\n \t\tthis.repairLim = repairLim;\n \t\tthis.color = color;\n \t\tthis.modelYear = modelYear;\n \t\tthis.make = make;\n \t\tthis.estValue = estValue;\n \t\tthis.towing = towing;\n \t\tthis.assignee = assignee;\n \t\tthis.noOfPass = noOfPass;\n \t\tthis.tariffZone = tariffZone;\n \t\tthis.cocIssueDate = cocIssueDate;\n \t\tthis.mvFileNo = mvFileNo;\n \t\tthis.acquiredFrom = acquiredFrom;\n \t\tthis.ctvTag = ctvTag;\n \t\tthis.typeOfBodyCd = typeOfBodyCd;\n \t\tthis.unladenWt = unladenWt;\n \t\tthis.makeCd = makeCd;\n \t\tthis.seriesCd = seriesCd;\n \t\tthis.basicColorCd = basicColorCd;\n \t\tthis.colorCd = colorCd;\n \t\tthis.origin = origin;\n \t\tthis.destination = destination;\n \t\tthis.cocAtcn = cocAtcn;\n \t\tsuper.setUserId(userId);\n \t\tsuper.setLastUpdate(lastUpdate);\n \t\tthis.sublineCd = sublineCd;\n \t\t\n \t}", "private void addRoomItems(int itemsToAdd)\n {\n\n // Adds up to 3 random items to a random room .\n if (!(itemsToAdd == 0)){\n\n for(int j = 0; j < itemsToAdd; j++){\n Item chooseItem = chooseValidItem(); \n Room chooseRoom = rooms.get(random.nextInt(rooms.size()));\n\n chooseRoom.getInventory().getItems().add(chooseItem);\n System.out.println(chooseRoom.getName()+\": \"+chooseItem.getName());\n\n }\n }\n }", "public String addItem(Item item){\n EntityManager em = emf.createEntityManager();\n try{\n utx.begin();\n em.joinTransaction();\n for(Tag tag : item.getTags()) {\n tag.incrementRefCount();\n tag.getItems().add(item);\n em.merge(tag);\n }\n em.persist(item);\n utx.commit();\n // index item\n if(bDebug) System.out.println(\"\\n***Item id of new item is : \" + item.getItemID());\n indexItem(new IndexDocument(item));\n \n } catch(Exception exe){\n try {\n utx.rollback();\n } catch (Exception e) {}\n throw new RuntimeException(\"Error persisting item\", exe);\n } finally {\n em.close();\n }\n return item.getItemID();\n }", "void addItem(DataRecord record);", "public void createItem()\n {\n \n necklace_red = new Item (\"Red Necklace\",\"This is a strange red necklace\");\n poolroom.addItem(necklace_red);\n \n // items in dancing room // \n gramophone = new Item (\"Gramophone\",\"This is a nice gramophone but without disk\");\n candelar = new Item(\"Candelar\",\"This candelar gives light and is really beautiful\");\n dancingroom.addItem(gramophone);\n dancingroom.addItem(candelar);\n \n //items in hall //\n potion2HP = new Potion(\"Potion 2 HP\",\"This potion gives 2 HP to the player\",2);\n hall.addItem(potion2HP);\n \n //items in corridor //\n halberd = new Weapon(\"Halberd\",\"This the statut halberd. It was not a really good idea to take it\",4,60);\n corridor.addItem(halberd);\n \n // items in bathroom //\n potion6HP = new Potion(\"Potion6HP\",\"This potions gives 6 HP to the player\",6);\n bathroom.addItem(potion6HP);\n \n // items in guestbedroom //\n Exit exit_from_corridor_to_bedroom = new Exit(\"south\",corridor,false, null);\n bedroomkey = new Keys(\"Bedroom key\",\"This key opens the master bedroom door\",exit_from_corridor_to_bedroom);\n guestbedroom.addItem(bedroomkey);\n \n // items in kitchen // \n set_of_forks_and_knives = new Weapon(\"Set of forks and knives\",\"This weapon is a set of silver forks and silver knives\",2,40);\n kitchen.addItem(set_of_forks_and_knives);\n \n // items in bedroom //\n Item disk = new Item(\"Disk\",\"This disk can be used with the gramophone\");\n bedroom.addItem(disk);\n \n Potion potion3HP = new Potion (\"Potion3HP\",\"This potions gives 3 HP to the player\",3);\n bedroom.addItem(potion3HP);\n \n Item money = new Item(\"Money\",\"You find 60 pounds\");\n bedroom.addItem(money);\n \n // items in the library //\n Item book = new Item(\"Book\",\"The title book is 'The best human friend : the cat'\");\n library.addItem(book);\n \n // items in laboratory //\n Exit exit_from_corridor_to_attic = new Exit(\"up\",corridor,false, null);\n Keys attickey = new Keys(\"Attic key\",\"This key is a shaped bone from a squeletor\", exit_from_corridor_to_attic); \n laboratory.addItem(attickey);\n \n Item construction_drawing = new Item(\"Construction drawing\",\"You find construction drawings. Mr Taylor planed to dig really deeply to the east of the gardener hut\");\n laboratory.addItem(construction_drawing);\n \n //items in garden //\n Weapon fork = new Weapon(\"Fork\",\"This fork is green and brown\",3,50);\n garden.addItem(fork);\n \n Potion apple = new Potion(\"Apple\",\"This apples gives you 2 HP\",2);\n garden.addItem(apple);\n \n // items in gardenerhut //\n \n Item pliers = new Item(\"Pliers\",\"You can cut a chain with this object\");\n gardenerhut.addItem(pliers);\n \n Item ritual_cape = new Item(\"Ritual cape\",\"You find a black ritual cape. It is very strange !\");\n gardenerhut.addItem(ritual_cape);\n \n Item necklace_black_1 = new Item(\"Necklace\",\"You find a very strange necklace ! It is a black rond necklace with the same symbol than in the ritual cape\");\n gardenerhut.addItem(necklace_black_1);\n \n //items in anteroom //\n \n Potion potion4HP = new Potion(\"Potion4HP\",\"This potion gives 4 HP to the player\",4);\n anteroom.addItem(potion4HP);\n \n Weapon sword = new Weapon(\"Sword\",\"A really sharp sword\",6,70);\n anteroom.addItem(sword);\n // items in ritual room //\n \n Item red_ritual_cape = new Item(\"Red ritual cape\", \"This is a ritual cape such as in the gardener hut but this one is red. There are some blond curly hairs\");\n ritualroom.addItem(red_ritual_cape);\n \n Item black_ritual_cape_1 = new Item(\"Black ritual cape\",\"This is a black ritual cape\");\n ritualroom.addItem(black_ritual_cape_1);\n \n Item black_ritual_cape_2 = new Item (\"Black ritual cape\",\"Another black ritual cape\");\n ritualroom.addItem(black_ritual_cape_2);\n \n }", "@Override\r\n\tpublic OrderItem createOrderItem(OrderItem newOrderItem) {\n\t\tSession session = SessionFactorySingleton.getSessionFactory().getFactorySession();\r\n\t\tsession.save(newOrderItem);\r\n\t\treturn newOrderItem;\r\n\r\n\t}", "public void createOrderItem() {\r\n\t\tScanner sc = new Scanner(System.in);\r\n\t\tRestaurantApp.globalMenuManager.printMenu(); //create a globalmenuManager so that other classes can access the menu\r\n\t\ttry {\r\n\t\t\tSystem.out.println(\"Which item would you like to order?\");\r\n\t\t\tint menuIndex = sc.nextInt();\r\n\t\t\tsc.nextLine();\r\n\t\t\tif (menuIndex <= 0 || menuIndex > RestaurantApp.globalMenuManager.getSizeOfMenu()){\r\n\t\t\t\tthrow new ArrayIndexOutOfBoundsException(\"Please input a valid index from 1 to \"+RestaurantApp.globalMenuManager.getSizeOfMenu());\r\n\t\t\t}\r\n\t\t\tthis.menuItem = RestaurantApp.globalMenuManager.getMenuItem(menuIndex-1);\r\n\t\t\tSystem.out.println(\"How many of this are you ordering?\");\r\n\t\t\tthis.quantity = sc.nextInt();\r\n\t\t\tsc.nextLine();\r\n\t\t\tSystem.out.println(\"Order item added. printing details...\");\r\n\t\t\tthis.printOrderItem();\r\n\t\t} catch (ArrayIndexOutOfBoundsException e) {\r\n\t\t\tSystem.out.println(e.getMessage()); \r\n\t\t\tSystem.out.println(\"program exiting ...\");\r\n\t\t\tSystem.exit(0);\r\n\t\t}\r\n\t}", "private static void createRecipe(int code, String name, int quantity ) {\n\t\tString sqlTotalkcal=\"select sum(kcal) from ingredient where code in (select code_ingredient from ingredientxrecipe where code_recipe=\"+code+\")\";\r\n\t\tString sqlTotalcarb=\"select sum(carbohidrates) from ingredient where code in (select code_ingredient from ingredientxrecipe where code_recipe=\"+code+\")\";\r\n\t\tString sqlTotalProt=\"select sum(Proteines) from ingredient where code in (select code_ingredient from ingredientxrecipe where code_recipe=\"+code+\")\";\r\n\t\tString sqlTotalFat=\"select sum(Fat) from ingredient where code in (select code_ingredient from ingredientxrecipe where code_recipe=\"+code+\")\";\r\n\t\tString sqlTotalSalt=\"select sum(Salt) from ingredient where code in (select code_ingredient from ingredientxrecipe where code_recipe=\"+code+\")\";\r\n\t\tString sqltotalAllergen=\"select codeAllergen from allergenxingredients where codeIngredient in (select code_ingredient from ingredientxrecipe where code_recipe=\"+code+\")\";\r\n\t\t\r\n\t\t//recuperar datos\r\n\t\t\r\n\t\ttry {\r\n\t\t\tdouble kcal = dataRecovery(sqlTotalkcal);\r\n\t\t\tdouble carb = dataRecovery(sqlTotalcarb);\r\n\t\t\tdouble prot = dataRecovery(sqlTotalProt);\r\n\t\t\tdouble fat = dataRecovery(sqlTotalFat);\r\n\t\t\tdouble salt = dataRecovery(sqlTotalSalt);\r\n\t\t\tString aler = dataRecoveryAllergenList(sqltotalAllergen);\r\n\t\t\tcreateRecipeData(code, name, quantity, kcal, carb, prot, fat, salt, aler);\r\n\t\t} catch (Exception e) {\r\n\t\t\tSystem.out.println(\"Hubo un error al crear la receta\");\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "public void addPart() {\n\n if(isValidPart()) {\n double price = Double.parseDouble(partPrice.getText());\n String name = partName.getText();\n int stock = Integer.parseInt(inventoryCount.getText());\n int id = Integer.parseInt(partId.getText());\n int minimum = Integer.parseInt(minimumInventory.getText());\n int maximum = Integer.parseInt(maximumInventory.getText());\n String variableText = variableTextField.getText();\n\n if (inHouse.isSelected()) {\n InHouse newPart = new InHouse(id,name,price,stock,minimum,maximum,Integer.parseInt(variableText));\n if (PassableData.isModifyPart()) {\n Controller.getInventory().updatePart(PassableData.getPartIdIndex(), newPart);\n } else {\n Controller.getInventory().addPart(newPart);\n }\n\n } else if (outsourced.isSelected()) {\n Outsourced newPart = new Outsourced(id,name,price,stock,minimum,maximum,variableText);\n if (PassableData.isModifyPart()) {\n Controller.getInventory().updatePart(PassableData.getPartIdIndex(), newPart);\n } else {\n Controller.getInventory().addPart(newPart);\n }\n }\n try {\n InventoryData.getInstance().storePartInventory();\n InventoryData.getInstance().storePartIdIndex();\n } catch (IOException e) {\n e.printStackTrace();\n }\n exit();\n\n }\n }", "private Item initItem() {\n String name = inputName.getText().toString();\n int quantityToBuy = -1;\n if (!inputQuantityToBuy.getText().toString().equals(\"\"))\n quantityToBuy = Integer.parseInt(inputQuantityToBuy.getText().toString());\n String units = inputUnits.getText().toString();\n double price = 0;\n if (!inputPrice.getText().toString().equals(\"\"))\n price = Double.parseDouble(inputPrice.getText().toString());\n int calories = 0;\n if (!inputCalories.getText().toString().equals(\"\"))\n calories = Integer.parseInt(inputCalories.getText().toString());\n ArrayList<String> allergies = allergyActions.getAllergies();\n return new Item(name, 0, units, quantityToBuy, 0, allergies, calories, price);\n }", "public abstract Quantity<Q> create(Number value, Unit<Q> unit);", "public Item() {\r\n this.name = \"\";\r\n this.description = \"\";\r\n this.price = 0F;\r\n this.type = \"\";\r\n this.available = 0;\r\n this.wholesaler = new Wholesaler();\r\n this.wholesalerId = 0;\r\n this.category = new Category();\r\n this.categoryId = 0; \r\n }", "static public ApplicationFormItem createNew(int id, String shortname, boolean required, ApplicationFormItemType type,\n\t\t\t\t\t\t\t\t\t\t\t\tString federationAttribute, String perunSourceAttribute, String perunDestinationAttribute, String regex,\n\t\t\t\t\t\t\t\t\t\t\t\tList<Application.ApplicationType> applicationTypes, Integer ordnum, boolean forDelete)\t{\n\t\tApplicationFormItem afi = new JSONObject().getJavaScriptObject().cast();\n\t\tafi.setId(id);\n\t\tafi.setShortname(shortname);\n\t\tafi.setRequired(required);\n\t\tafi.setType(type);\n\t\tafi.setFederationAttribute(federationAttribute);\n\t\tafi.setPerunSourceAttribute(perunSourceAttribute);\n\t\tafi.setPerunDestinationAttribute(perunDestinationAttribute);\n\t\tafi.setRegex(regex);\n\t\tafi.setApplicationTypes(applicationTypes);\n\t\tafi.setOrdnum(ordnum);\n\t\tafi.setForDelete(forDelete);\n\t\treturn afi;}", "public TransactionItem addTransactionItem(int transactionId, int productId, int quantity)\n\t{\n\t\tConnect con=Connect.getConnection();\n\t\tcon.executeQuery(\"USE sudutmeong\");\n\t\tTransactionItem x=new TransactionItem();\n\t\tx.setTransactionId(transactionId);\n\t\tx.setProductId(productId);\n\t\tx.setQuantity(quantity);\n\t\tString query = \"INSERT INTO transactionitem VALUES (\"+transactionId+\",\" + productId + \",\"+ quantity +\")\";\n\t\tcon.executeUpdate(query);\n\t\treturn x;\n\t}", "Item(long ID, Weight weight, DukatAmount price){\r\n\t\tthis.ID = getNextID(ID);\r\n\t\tthis.setHolder(World.world);\r\n\t\tWorld.world.addItem(this);\r\n\t\tif(isValidWeight(weight))\r\n\t\t\tthis.weight = weight;\r\n\t\telse this.weight = new Weight(5);\r\n\t\tsetPrice(price);\r\n\t}", "public static Item generate(){\n\n //this method lists a collection of new items. it then uses a random number generator\n //to pick one of the objects, and then returns the object so that the main method\n //can add it to the inventory.\n\n ItemType weapon = ItemType.weapon;\n Item IronSword = new Item(weapon, \"Iron Sword\", 8, 50, 10);\n Item GoldenSword = new Item(weapon, \"Golden Sword\", 10, 75, 15);\n Item AllumSword = new Item(weapon, \"Alluminum Sword\", 6, 35, 8);\n Item BowandQuiver = new Item(weapon, \"Bow & Quiver\", 4, 45, 7);\n Item BattleAxe = new Item(weapon, \"Battle Axe\", 12, 55, 13);\n\n ItemType armor = ItemType.armor;\n Item ChainChest = new Item(armor, \"Chain Mail Chestplate\", 8, 40, 30);\n Item IronChest = new Item(armor, \"Iron Chestplate\", 10, 50, 40);\n Item GoldenChest = new Item(armor, \"Golden Chestplate\", 12, 65, 50);\n Item ChainPants = new Item(armor, \"Chain Mail Pants\", 7, 40, 30);\n Item IronPants = new Item(armor, \"Iron Pants\", 9, 50, 40);\n Item GoldenPants = new Item(armor, \"Golden Pants\", 11, 65, 50);\n Item Helmet = new Item(armor, \"Helmet\", 5, 40, 20);\n\n ItemType other = ItemType.other;\n Item Bandage = new Item(other, \"Bandage\", 1, 2, 0);\n Item Wrench = new Item(other, \"Wrench\", 3, 10, 5);\n Item Bread = new Item(other, \"Bread Loaf\", 2, 4, 0);\n Item Water = new Item(other, \"Water Flask\", 3, 2, 0);\n\n Item Initializer = new Item(other, \"init\", 0, 0, 0);\n\t\tint ItemPick = RandomNum();\n Item chosen = Initializer;\n\n switch (ItemPick){\n case 1:\n chosen = IronSword;\n break;\n case 2:\n chosen = GoldenSword;\n break;\n case 3:\n chosen = AllumSword;\n break;\n case 4:\n chosen = BowandQuiver;\n break;\n case 5:\n chosen = BattleAxe;\n break;\n case 6:\n chosen = ChainChest;\n break;\n case 7:\n chosen = IronChest;\n break;\n case 8:\n chosen = GoldenChest;\n break;\n case 9:\n chosen = ChainPants;\n break;\n\t\t\t case 10:\n chosen = IronPants ;\n break;\n case 11:\n chosen = GoldenPants;\n break;\n case 12:\n chosen = Helmet;\n break;\n case 13:\n chosen = Bandage;\n break;\n case 14:\n chosen = Wrench;\n break;\n case 15:\n chosen = Bread;\n break;\n case 16:\n chosen = Water;\n break;\n }\n\n return chosen;\n }", "int insertSelective(ItemStockDO record);", "public static void createItemTable() {\n\n\t\ttry {\n\t\t\tconnection = DBConnectionUtil.getDBConnection();\n\t\t\tstatement = connection.createStatement();\n\t\t\t// Drop table if already exists and as per SQL query available in\n\t\t\t// Query.xml\n\t\t\tstatement.executeUpdate(QueryUtil.queryByID(CommonConstants.QUERY_ID_DROP_ITEM_TABLE));\n\t\t\t// Create new items table as per SQL query available in\n\t\t\t// Query.xml\n\t\t\tstatement.executeUpdate(QueryUtil.queryByID(CommonConstants.QUERY_ID_CREATE_ITEM_TABLE));\n\t\t\t// Insert records into item table in the beginning as per SQL query available in\n\t\t\t// Query.xml\t\t\t\n\t\t\tstatement.executeUpdate(QueryUtil.queryByID(CommonConstants.QUERY_ID_INSERT_BEGIN_ITEM_TABLE));\n\t\t\t\n\t\t} catch (SQLException | SAXException | IOException | ParserConfigurationException | ClassNotFoundException e) {\n\t\t\tlog.log(Level.SEVERE, e.getMessage());\n\t\t}\n\t}", "public static void createItemTable() {\n\n\t\ttry {\n\t\t\tconnection = DBConnectionUtil.getDBConnection();\n\t\t\tstatement = connection.createStatement();\n\t\t\t// Drop table if already exists and as per SQL query available in\n\t\t\t// Query.xml\n\t\t\tstatement.executeUpdate(QueryUtil.queryByID(CommonConstants.QUERY_ID_DROP_ITEM_TABLE));\n\t\t\t// Create new items table as per SQL query available in\n\t\t\t// Query.xml\n\t\t\tstatement.executeUpdate(QueryUtil.queryByID(CommonConstants.QUERY_ID_CREATE_ITEM_TABLE));\n\t\t\t// Insert records into item table in the beginning as per SQL query available in\n\t\t\t// Query.xml\t\t\t\n\t\t\tstatement.executeUpdate(QueryUtil.queryByID(CommonConstants.QUERY_ID_INSERT_BEGIN_ITEM_TABLE));\n\t\t\t\n\t\t} catch (SQLException | SAXException | IOException | ParserConfigurationException | ClassNotFoundException e) {\n\t\t\tlog.log(Level.SEVERE, e.getMessage());\n\t\t}\n\t}", "@Test(groups = \"Transactions Tests\", description = \"Create new transaction\")\n\tpublic void createNewTransaction() {\n\t\tMainScreen.clickAccountItem(\"Income\");\n\t\tSubAccountScreen.clickSubAccountItem(\"Salary\");\n\t\tTransactionsScreen.clickAddTransactionBtn();\n\t\tTransactionsScreen.typeTransactionDescription(\"Extra income\");\n\t\tTransactionsScreen.typeTransactionAmount(\"300\");\n\t\tTransactionsScreen.clickTransactionType();\n\t\tTransactionsScreen.typeTransactionNote(\"Extra income from this month\");\n\t\tTransactionsScreen.clickSaveBtn();\n\t\tTransactionsScreen.transactionItem(\"Extra income\").shouldBe(visible);\n\t\tTransactionsScreen.transactionAmout().shouldHave(text(\"$300\"));\n\t\ttest.log(Status.PASS, \"Sub-account created successfully and the value is correct\");\n\n\t\t//Testing if the transaction was created in the 'Double Entry' account, if the value is correct and logging the result to the report\n\t\treturnToHomeScreen();\n\t\tMainScreen.clickAccountItem(\"Assets\");\n\t\tSubAccountScreen.clickSubAccountItem(\"Current Assets\");\n\t\tSubAccountScreen.clickSubAccountItem(\"Cash in Wallet\");\n\t\tTransactionsScreen.transactionItem(\"Extra income\").shouldBe(visible);\n\t\tTransactionsScreen.transactionAmout().shouldHave(text(\"$300\"));\n\t\ttest.log(Status.PASS, \"'Double Entry' account also have the transaction and the value is correct\");\n\n\t}", "void createSportItem (String name, String description, double price, String sportType);", "public static Item create(long itemId) {\n\t\treturn getPersistence().create(itemId);\n\t}", "public static void createTransaction() throws IOException {\n\t\t\n\t\tDate date = new Date((long) random(100000000));\n\t\tString date2 = \"'19\" + date.getYear() + \"-\" + (random(12)+1) + \"-\" + (random(28)+1) + \"'\";\n\t\tint amount = random(10000);\n\t\tint cid = random(SSNmap.size()) + 1;\n\t\tint vid = random(venders.size()) + 1;\n\t\t\n\t\twhile(ownership.get(cid) == null)\n\t\t\tcid = random(SSNmap.size()) + 1;\n\t\tString cc = ownership.get(cid).get(random(ownership.get(cid).size()));\n\t\t\n\t\twriter.write(\"INSERT INTO Transaction (Id, Date, vid, cid, CCNum, amount) Values (\" + tid++ +\", \" \n\t\t\t\t+ date2 + \", \" + vid + \", \" + cid + \", '\" + cc + \"', \" + amount + line);\n\t\twriter.flush();\n\t}", "Long addAmount(Integer id, Long value) throws Exception;", "Item(int i, String n, String c, double p) {\n this.id = i;\n this.name = n;\n this.category = c;\n this.price = p;\n }", "@Override\n public void onCreate(SQLiteDatabase db) {\n db.execSQL(\n \"create table itemstable \" +\n \"(id integer primary key, itemcost text,itemkg text, itemQuantity text)\"\n );\n\n }", "public Item(int sn, double w)\r\n\t/*\r\n\t * \t\tsn - serial number\r\n\t * \t\tw - weight\r\n\t */\r\n\t{\r\n\t\tserialNum = sn;\r\n\t\tweight = w;\r\n\t}", "private Object makeObj(final String item, final int ID) {\n return new Object() {\n\n @Override\n public String toString() {\n return item;\n }\n\n @Override\n public int hashCode() {\n return ID;\n }\n };\n }", "public void addCostItem(CostItem item) throws CostManagerException;", "public ItemQuantity(Item item, int quantity) {\n this.item = item;\n this.quantity = quantity;\n }", "public int addNewAmendment(Amendment amendment);", "@Override\n public Item create(Context context, WorkspaceItem workspaceItem) throws SQLException, AuthorizeException\n {\n if(workspaceItem.getItem() != null)\n {\n throw new IllegalArgumentException(\"Attempting to create an item for a workspace item that already contains an item\");\n }\n\n Item item = createItem(context);\n workspaceItem.setItem(item);\n return item;\n }", "public Item createNew(int count) {\r\n Item i = new Item(name, id);\r\n i.setPickedUp(true);\r\n i.setCount(count);\r\n return i;\r\n }", "public ManpowerEntity createNewManpower(String mrole, Integer mintnumber, Boolean standard, Long propertyId) {\n return manpowerBeanLocal.addManpower(mrole, mintnumber, standard, propertyId);\r\n }", "protected abstract void addMaterialStats();", "int insertSelective(SrmFundItem record);", "public void addAlimento(int refID, int alimID, int qty) {\n Refeicao ref = searchRefeicao(refID);\n Alimento alim = searchAlim(alimID);\n\n Alimento alimento = new Alimento(alim,qty);\n\n ref.addAlimento(alimento);\n }", "@Override\n\t\tpublic void addRawitem(Rawitem Rawitem) {\n\t\t\tString sql=\"INSERT INTO rawitem(suppliedby,rquantity,riprice,rstock)\"\n\t\t\t\t\t+ \" values (:suppliedby,:rquantity,:riprice,:rstock)\";\n\t\t\tnamedParameterJdbcTemplate.update(sql,getSqlParameterByModel(Rawitem));\n\t\t}", "public OreStack(String mat, int qty)\r\n/* 9: */ {\r\n/* 10: 8 */ this.material = mat;\r\n/* 11: 9 */ this.quantity = qty;\r\n/* 12: */ }", "void add(Item item);", "double addStock(String identifier, double amount, String date, double commission)\n throws IllegalArgumentException;" ]
[ "0.63068485", "0.61061", "0.595796", "0.5839801", "0.58280826", "0.58078355", "0.5789437", "0.57505023", "0.56708056", "0.56420314", "0.56038034", "0.55939585", "0.55304575", "0.549162", "0.54763037", "0.54704183", "0.54404277", "0.5429413", "0.54129016", "0.54119843", "0.53491586", "0.53232354", "0.5313066", "0.5284669", "0.52753204", "0.52714163", "0.5266952", "0.5200767", "0.51974976", "0.51932615", "0.51929426", "0.5185822", "0.51807624", "0.5178504", "0.5176986", "0.51764405", "0.514442", "0.514179", "0.51396084", "0.5127549", "0.51273483", "0.5122725", "0.5108033", "0.5102079", "0.51012945", "0.5083674", "0.5063827", "0.5061155", "0.5050902", "0.5050902", "0.50418764", "0.5039144", "0.5037793", "0.50342214", "0.5027385", "0.5025269", "0.50163245", "0.50161386", "0.5016025", "0.5015079", "0.5009524", "0.5006458", "0.50036496", "0.500293", "0.50027174", "0.5002434", "0.4999189", "0.49928382", "0.49883193", "0.49841416", "0.49838808", "0.4982857", "0.49804884", "0.49654874", "0.4956773", "0.49498224", "0.49468407", "0.49468407", "0.49441764", "0.49436948", "0.4943552", "0.494348", "0.49433744", "0.4934471", "0.49336308", "0.49333248", "0.49211088", "0.49075446", "0.49028534", "0.49018008", "0.49009228", "0.48908916", "0.4890878", "0.48873377", "0.48820415", "0.4879714", "0.48736256", "0.4863721", "0.48606846", "0.48584044" ]
0.63721436
0
Set the operation values.
Builder values(Map<Path<?>, TypedExpression<?>> values);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void setFieldValues(String op, List values)\n {\n if (op == null || op.trim().length() == 0)\n throw new IllegalArgumentException(\n \"operator must not be null or empty\");\n\n if (!isValidOperator(op))\n throw new IllegalArgumentException(\n \"Invalid operator specified for search field\");\n\n if (setValues(op, null, values))\n setDirty();\n }", "public void setOperation (String Operation);", "@Override\n public void setValue(Value[] values) throws ValueFormatException,\n VersionException, LockException, ConstraintViolationException,\n RepositoryException {\n \n }", "public final CQLParser.setOperation_return setOperation() throws RecognitionException {\n CQLParser.setOperation_return retval = new CQLParser.setOperation_return();\n retval.start = input.LT(1);\n\n Object root_0 = null;\n\n Token UNION69=null;\n Token INTERSECTION71=null;\n Token DIFFERENCE73=null;\n CQLParser.setOperationParameters_return setOperationParameters70 = null;\n\n CQLParser.setOperationParameters_return setOperationParameters72 = null;\n\n CQLParser.setOperationParameters_return setOperationParameters74 = null;\n\n\n Object UNION69_tree=null;\n Object INTERSECTION71_tree=null;\n Object DIFFERENCE73_tree=null;\n\n errorMessageStack.push(\"RESULT set operation\"); \n try {\n // /home/chinaski/programming/agile_workspace/ExplorerCat/src/main/antlr3/net/explorercat/cql/parser/CQL.g:320:2: ( UNION setOperationParameters | INTERSECTION setOperationParameters | DIFFERENCE setOperationParameters )\n int alt17=3;\n switch ( input.LA(1) ) {\n case UNION:\n {\n alt17=1;\n }\n break;\n case INTERSECTION:\n {\n alt17=2;\n }\n break;\n case DIFFERENCE:\n {\n alt17=3;\n }\n break;\n default:\n NoViableAltException nvae =\n new NoViableAltException(\"\", 17, 0, input);\n\n throw nvae;\n }\n\n switch (alt17) {\n case 1 :\n // /home/chinaski/programming/agile_workspace/ExplorerCat/src/main/antlr3/net/explorercat/cql/parser/CQL.g:320:4: UNION setOperationParameters\n {\n root_0 = (Object)adaptor.nil();\n\n UNION69=(Token)match(input,UNION,FOLLOW_UNION_in_setOperation1442); \n UNION69_tree = (Object)adaptor.create(UNION69);\n root_0 = (Object)adaptor.becomeRoot(UNION69_tree, root_0);\n\n pushFollow(FOLLOW_setOperationParameters_in_setOperation1445);\n setOperationParameters70=setOperationParameters();\n\n state._fsp--;\n\n adaptor.addChild(root_0, setOperationParameters70.getTree());\n\n }\n break;\n case 2 :\n // /home/chinaski/programming/agile_workspace/ExplorerCat/src/main/antlr3/net/explorercat/cql/parser/CQL.g:321:4: INTERSECTION setOperationParameters\n {\n root_0 = (Object)adaptor.nil();\n\n INTERSECTION71=(Token)match(input,INTERSECTION,FOLLOW_INTERSECTION_in_setOperation1450); \n INTERSECTION71_tree = (Object)adaptor.create(INTERSECTION71);\n root_0 = (Object)adaptor.becomeRoot(INTERSECTION71_tree, root_0);\n\n pushFollow(FOLLOW_setOperationParameters_in_setOperation1453);\n setOperationParameters72=setOperationParameters();\n\n state._fsp--;\n\n adaptor.addChild(root_0, setOperationParameters72.getTree());\n\n }\n break;\n case 3 :\n // /home/chinaski/programming/agile_workspace/ExplorerCat/src/main/antlr3/net/explorercat/cql/parser/CQL.g:322:4: DIFFERENCE setOperationParameters\n {\n root_0 = (Object)adaptor.nil();\n\n DIFFERENCE73=(Token)match(input,DIFFERENCE,FOLLOW_DIFFERENCE_in_setOperation1458); \n DIFFERENCE73_tree = (Object)adaptor.create(DIFFERENCE73);\n root_0 = (Object)adaptor.becomeRoot(DIFFERENCE73_tree, root_0);\n\n pushFollow(FOLLOW_setOperationParameters_in_setOperation1461);\n setOperationParameters74=setOperationParameters();\n\n state._fsp--;\n\n adaptor.addChild(root_0, setOperationParameters74.getTree());\n\n }\n break;\n\n }\n retval.stop = input.LT(-1);\n\n retval.tree = (Object)adaptor.rulePostProcessing(root_0);\n adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop);\n\n errorMessageStack.pop(); \n }\n \t\n \tcatch(RecognitionException re)\n \t{\t\n \t\treportError(re);\n \t\tthrow re;\n \t}\n finally {\n }\n return retval;\n }", "void setElementValue(SetElementValue cmd);", "protected abstract void setValues(double[] values);", "public com.autodesk.ws.avro.Call.Builder setOperation(java.lang.CharSequence value) {\n validate(fields()[3], value);\n this.operation = value;\n fieldSetFlags()[3] = true;\n return this; \n }", "public void setExternalFieldValues(String extOp, List values)\n {\n if (extOp == null || extOp.trim().length() == 0)\n throw new IllegalArgumentException(\n \"operator must not be null or empty\");\n\n if (setValues(null, extOp, values))\n setDirty();\n }", "public void setParamValues(Object[] values);", "public void setOperation(String op) {this.operation = op;}", "public void setOp ( boolean value ) {\n\t\texecute ( handle -> handle.setOp ( value ) );\n\t}", "public void setValues(){\r\n int k=0;\r\n String[] var;\r\n String evar;\r\n \r\n //Set Values \r\n for (int i=0; i<linkVector.size(); i++){\r\n var= (String[]) linkVector.elementAt(i);\r\n evar=var[1];\r\n try { \r\n varContextField= varContextFields[linkIndex[k]]; \r\n switch (linkType[k++]){\r\n case DOUBLE: setValue(evar,varContextField.getDouble(varContextObject)); break;\r\n case ARRAYDOUBLE: setValue(evar,(double[])varContextField.get(varContextObject)); break;\r\n case ARRAYDOUBLE2D: setValue(evar,(double[][])varContextField.get(varContextObject)); break;\r\n case STRING: setValue(evar,(String)varContextField.get(varContextObject)); break; \r\n }\r\n \r\n } catch (java.lang.IllegalAccessException e) {\r\n System.out.println(\"Error Step: setting a value \" + e);\r\n } \r\n } \r\n }", "@Override\n\tpublic void setOperands(int first, int second, int third) {\n\t\tthis.first = first;\n\t\tthis.second = second;\n\t\tthis.third = third;\n\t}", "@Override\n public void setInMatlab(MatlabOperations ops, String name) throws MatlabInvocationException\n {\n \n if(_real instanceof Byte)\n {\n ops.eval(name + \"=int8(\" + _real.byteValue() + \"+\" + _imag.byteValue() + \"i);\");\n }\n else if(_real instanceof Short)\n {\n ops.eval(name + \"=int16(\" + _real.shortValue() + \"+\" + _imag.shortValue() + \"i);\");\n }\n else if(_real instanceof Integer)\n {\n ops.eval(name + \"=int32(\" + _real.intValue() + \"+\" + _imag.intValue() + \"i);\");\n }\n else if(_real instanceof Long)\n {\n ops.eval(name + \"=int64(\" + _real.longValue() + \"+\" + _imag.longValue() + \"i);\");\n }\n \n // Set value through an array to avoid values being converted to MATLAB double\n \n else if(_real instanceof Float)\n {\n ops.setVariable(name, new float[] { _real.floatValue(), _imag.floatValue() });\n ops.eval(name + \"=\" + name + \"(1)+\" + name + \"(2)*i;\");\n }\n else if(_real instanceof Double)\n {\n ops.setVariable(name, new double[] { _real.doubleValue(), _imag.doubleValue() });\n ops.eval(name + \"=\" + name + \"(1)+\" + name + \"(2)*i;\");\n }\n }", "@Override\n\tprotected void setParameterValues() {\n\t}", "public void setValue(String... values) throws DeviceOptionException;", "public void setOperations(List<OperationImplementation> operations) {\n List<Map<String, Serializable>> operationsSerializable = new ArrayList<Map<String, Serializable>>();\n for (OperationImplementation operation : operations) {\n Map<String, Serializable> operationSerializable = new HashMap<String, Serializable>();\n operationSerializable.put(OPERATION_NAME, operation.getName());\n operationSerializable.put(OPERATION_DOCUMENTATION, operation.getDocumentation());\n operationSerializable.put(OPERATION_PARAMETERS, operation.getParameters());\n operationsSerializable.add(operationSerializable);\n }\n properties.put(XPATH_OPERATIONS, (Serializable) operationsSerializable);\n }", "private void set_values(ArrayList<Integer> values)\r\n\t{\r\n\t\tthis.poss_values = values;\r\n\t}", "void setValues(final int[] values) {\n this.values = values;\n }", "public void setValues(List values) {\n/* 115 */ super.setValues(values);\n/* 116 */ for (Iterator<ConfigurableEffect.Value> iter = values.iterator(); iter.hasNext(); ) {\n/* 117 */ ConfigurableEffect.Value value = iter.next();\n/* 118 */ if (value.getName().equals(\"Wavelength\")) {\n/* 119 */ this.wavelength = ((Float)value.getObject()).floatValue(); continue;\n/* 120 */ } if (value.getName().equals(\"Amplitude\")) {\n/* 121 */ this.amplitude = ((Float)value.getObject()).floatValue();\n/* */ }\n/* */ } \n/* */ }", "public void setOperation(Operation operation) {\n this.operation = operation;\n }", "@Override\r\n public void setAllServoValues(float[] values) {\r\n if(values==null || values.length!=getNumServos()) throw new IllegalArgumentException(\"wrong number of servo values, need \"+getNumServos());\r\n checkServoCommandThread();\r\n ServoCommand cmd=new ServoCommand();\r\n cmd.bytes=new byte[1+getNumServos()*2];\r\n cmd.bytes[0]=CMD_SET_ALL_SERVOS;\r\n int index=1;\r\n for(int i=0;i<getNumServos();i++){\r\n byte[] b=pwmValue(values[getServo(i)]); // must correct here for flipped labeling on PCB\r\n cmd.bytes[index++]=b[0];\r\n cmd.bytes[index++]=b[1];\r\n lastServoValues[getServo(i)]=values[i];\r\n }\r\n submitCommand(cmd);\r\n }", "public void setValues(List<Object> values);", "public void set(VectorFloat values) {\n for (int i = 0; i < values.storage.length; i++) {\n storage[i] = values.storage[i];\n }\n }", "public final CQLParser.setOperationParameters_return setOperationParameters() throws RecognitionException {\n CQLParser.setOperationParameters_return retval = new CQLParser.setOperationParameters_return();\n retval.start = input.LT(1);\n\n Object root_0 = null;\n\n Token char_literal75=null;\n Token char_literal76=null;\n Token char_literal77=null;\n CQLParser.setOperationAttribute_return a = null;\n\n CQLParser.setOperationAttribute_return b = null;\n\n\n Object char_literal75_tree=null;\n Object char_literal76_tree=null;\n Object char_literal77_tree=null;\n RewriteRuleTokenStream stream_116=new RewriteRuleTokenStream(adaptor,\"token 116\");\n RewriteRuleTokenStream stream_114=new RewriteRuleTokenStream(adaptor,\"token 114\");\n RewriteRuleTokenStream stream_115=new RewriteRuleTokenStream(adaptor,\"token 115\");\n RewriteRuleSubtreeStream stream_setOperationAttribute=new RewriteRuleSubtreeStream(adaptor,\"rule setOperationAttribute\");\n try {\n // /home/chinaski/programming/agile_workspace/ExplorerCat/src/main/antlr3/net/explorercat/cql/parser/CQL.g:326:2: ( '(' a= setOperationAttribute ',' b= setOperationAttribute ')' -> $a $b)\n // /home/chinaski/programming/agile_workspace/ExplorerCat/src/main/antlr3/net/explorercat/cql/parser/CQL.g:326:4: '(' a= setOperationAttribute ',' b= setOperationAttribute ')'\n {\n char_literal75=(Token)match(input,114,FOLLOW_114_in_setOperationParameters1475); \n stream_114.add(char_literal75);\n\n pushFollow(FOLLOW_setOperationAttribute_in_setOperationParameters1479);\n a=setOperationAttribute();\n\n state._fsp--;\n\n stream_setOperationAttribute.add(a.getTree());\n char_literal76=(Token)match(input,115,FOLLOW_115_in_setOperationParameters1481); \n stream_115.add(char_literal76);\n\n pushFollow(FOLLOW_setOperationAttribute_in_setOperationParameters1485);\n b=setOperationAttribute();\n\n state._fsp--;\n\n stream_setOperationAttribute.add(b.getTree());\n char_literal77=(Token)match(input,116,FOLLOW_116_in_setOperationParameters1487); \n stream_116.add(char_literal77);\n\n\n\n // AST REWRITE\n // elements: a, b\n // token labels: \n // rule labels: retval, b, a\n // token list labels: \n // rule list labels: \n // wildcard labels: \n retval.tree = root_0;\n RewriteRuleSubtreeStream stream_retval=new RewriteRuleSubtreeStream(adaptor,\"rule retval\",retval!=null?retval.tree:null);\n RewriteRuleSubtreeStream stream_b=new RewriteRuleSubtreeStream(adaptor,\"rule b\",b!=null?b.tree:null);\n RewriteRuleSubtreeStream stream_a=new RewriteRuleSubtreeStream(adaptor,\"rule a\",a!=null?a.tree:null);\n\n root_0 = (Object)adaptor.nil();\n // 327:3: -> $a $b\n {\n adaptor.addChild(root_0, stream_a.nextTree());\n adaptor.addChild(root_0, stream_b.nextTree());\n\n }\n\n retval.tree = root_0;\n }\n\n retval.stop = input.LT(-1);\n\n retval.tree = (Object)adaptor.rulePostProcessing(root_0);\n adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop);\n\n }\n \t\n \tcatch(RecognitionException re)\n \t{\t\n \t\treportError(re);\n \t\tthrow re;\n \t}\n finally {\n }\n return retval;\n }", "public void operationSet() {\r\n\r\n\t\t// Pane aktivieren\r\n\t\tdisableContentPanes();\r\n\t\tpaneOperation.setVisible(true);\r\n\r\n\t\t// Neue Operation anlegen\r\n\t\tif (listOperation.getSelectionModel().getSelectedItem()\r\n\t\t\t\t.equals(\"hinzufügen...\")) {\r\n\t\t\tstatusFeldText.setText(\"Neue Operationen hinzufügen...\");\r\n\t\t}\r\n\r\n\t\t// Operation bearbeiten\r\n\t\telse {\r\n\t\t\tstatusFeldText.setText(listOperation.getSelectionModel()\r\n\t\t\t\t\t.getSelectedItems() + \" bearbeiten...\");\r\n\t\t}\r\n\r\n\t}", "@Override\n public void setValue(String[] values) throws ValueFormatException,\n VersionException, LockException, ConstraintViolationException,\n RepositoryException {\n \n }", "public void setValues(Parameter[] values) {\n if (values == null || values.length < 4) {\n throw new IllegalArgumentException(\"Invalid values:\" + values);\n }\n if (this.values == null) {\n this.values = new Parameter[values.length];\n }\n int index = 0;\n for (Parameter p : values) {\n this.values[index++] = p;\n }\n validateValues();\n }", "public abstract void setValues(String[] pValues);", "public void setValues(boolean[] values) {\n\t\tthis.values = Arrays.copyOf(values, values.length);\n\t\tstart();\n\t}", "@Test\n\tpublic final void testSetValues() throws MPIException {\n\t\tdouble[] newValues = new double[totalSize];\n\t\tfor (int i=0; i<totalSize; i++) {\n\t\t\tnewValues[i] = 7.8*i;\n\t\t}\n\t\tblock.setValues(newValues);\n\t\tblock.startCommunication();\n\t\tverifyInnerValues(block, newValues);\n\t\tverifyGhostRegionValues(block);\n\t\tblock.finishCommunication();\n\t}", "public void setControlVars(java.util.List<Object> controlValues);", "public void setOp(boolean value) {}", "public void setOperation(java.lang.CharSequence value) {\n this.Operation = value;\n }", "public void setOp(int op) {\n\t\tthis.op = op;\n\t}", "public final void setArgs(ExprOrOpArgNode[] args) { this.operands = args; }", "void setPosiblesValores(int[] valores);", "public void set(float[] values) {\n for (int i = 0; i < values.length; i++) {\n storage[i] = values[i];\n }\n }", "private void initValues() {\n \n }", "public Var_Act_Data(Action_Type type, Variable v1, Variable v2, int set_value) {\r\n super(type);\r\n var1 = v1;\r\n var2 = v2;\r\n set_val = set_value;\r\n }", "protected ContainerValueOperationEvaluator(ContainerValueOperation op) {\r\n this.op = op;\r\n }", "public UpdateOperation(){ key = value = null;}", "public void setValues(Parameter min, Parameter mag, Parameter wrapS, Parameter wrapT) {\n if (values == null) {\n values = new Parameter[4];\n }\n values[MIN_FILTER_INDEX] = min;\n values[MAG_FILTER_INDEX] = mag;\n values[WRAP_S_INDEX] = wrapS;\n values[WRAP_T_INDEX] = wrapT;\n validateValues();\n }", "public void setOp(Operator op) {\n this.op = op;\n }", "@Keep\n void setDops(double gdop, double pdop, double hdop, double vdop) {\n mDops[0] = gdop;\n mDops[1] = pdop;\n mDops[2] = hdop;\n mDops[3] = vdop;\n }", "public void setNewValues(){\n questionT = qMean.getText();\n phoneT = pMean.getText();\n doorT = dMean.getText();\n time = simTime.getText();\n simulation.setTime(time);\n simulation.setD(doorT);\n simulation.setP(phoneT);\n simulation.setQ(questionT);\n }", "public abstract void setValueAction(Object value);", "public void setOperation(java.lang.CharSequence value) {\n this.operation = value;\n }", "public void setValue(int value)\n {\n // we have assumed value 1 for X and 10 for O\n this.value = value;\n }", "protected void setOperations(java.util.Collection<OperationDescriptor> operations) {\n List<OperationDescriptor> ops = new ArrayList<OperationDescriptor>();\n ops.addAll(operations);\n Constructor<?>[] cons = getTypeClass().getConstructors();\n for (int c = 0; c < cons.length; c++) {\n Constructor<?> constructor = cons[c];\n if (Modifier.isPublic(constructor.getModifiers()) \n && (null == typeAnalyzer || typeAnalyzer.isVisible(constructor))) {\n ops.add(new RtReflectionConstructorDescriptor(this, constructor));\n canBeInstantiated = true;\n }\n }\n try {\n Method equals = getTypeClass().getMethod(\"equals\", Object.class);\n ops.add(new RtComparisonOperationDescriptor(this, equals, \n net.ssehub.easy.instantiation.core.model.vilTypes.Constants.EQUALITY, false));\n ops.add(new RtComparisonOperationDescriptor(this, equals, \n net.ssehub.easy.instantiation.core.model.vilTypes.Constants.UNEQUALITY, true));\n ops.add(new RtComparisonOperationDescriptor(this, equals, \n net.ssehub.easy.instantiation.core.model.vilTypes.Constants.UNEQUALITY_ALIAS, true));\n } catch (NoSuchMethodException e) {\n // shall not occur\n }\n super.setOperations(ops);\n }", "protected void updateValues(){\n double total = 0;\n for(int i = 0; i < values.length; i++){\n values[i] = \n operation(minimum + i * (double)(maximum - minimum) / (double)numSteps);\n \n total += values[i];\n }\n for(int i = 0; i < values.length; i++){\n values[i] /= total;\n }\n }", "public static void setAllFactors(double lessFactorIOValue,\n double moreFactorIOValue, double lessFactorExecValue,\n double moreFactorExecValue)\n {\n lessFactorIO_ = lessFactorIOValue;\n moreFactorIO_ = moreFactorIOValue;\n lessFactorExec_ = lessFactorExecValue;\n moreFactorExec_ = moreFactorExecValue;\n }", "public abstract void set(DataType x, DataType y, DataType z);", "void setValues(final T value, final T min, final T max)\n {\n setValue(value, valueLabel);\n setValue(min, minValueLabel);\n setValue(max, maxValueLabel);\n }", "@Override\n public QuadHolder setValues(final Map<Var, Node> values) {\n this.values = values;\n return this;\n }", "public void setValues(Object[] vals)\n\t{\n\t\tvalues.clear();\n\n\t\tfor (int ctr=0; ctr<vals.length; ctr++)\n\t\t{\n\t\t\tvalues.add(vals[ctr] + \"\");\n\t\t}\n\t}", "public void setOperandA(int val);", "public void setControls() {\r\n System.out.println(\"wire data is \" + this.controllerWire.getData());\r\n String operation = this.controlMemory.get(this.controllerWire.getData());\r\n System.out.println(\"Setting the controls for \" + operation);\r\n if (operation.equalsIgnoreCase(\"add\")) {\r\n //alu.setControl(1);\r\n this.ALUControl.setData(1);\r\n this.ALU_MUXControl.setData(0);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n //aluMUX.setSelect(0);\r\n //regMUX.setSelect(0);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"addi\")) {\r\n //alu.setControl(1);\r\n this.ALUControl.setData(1);\r\n this.ALU_MUXControl.setData(1);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"sub\")) {\r\n //alu.setControl(2);\r\n this.ALUControl.setData(2);\r\n this.ALU_MUXControl.setData(0);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"lw\")) {\r\n// alu.setControl(8); // TODO \r\n this.ALUControl.setData(8);\r\n this.REG_MUXControl.setData(1);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.readWire.setData(1);\r\n memory.setReadWire(this.readWire);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"sw\")) {\r\n //alu.setControl(9); // TODO\r\n this.ALUControl.setData(9);\r\n //regMUX.setSelect(1);\r\n this.writeWire.setData(1);\r\n memory.setWriteWire(writeWire);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(0);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"sll\")) {\r\n //alu.setControl(6);\r\n this.ALUControl.setData(6);\r\n this.ALU_MUXControl.setData(1);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"srl\")) {\r\n //alu.setControl(5);\r\n this.ALUControl.setData(5);\r\n this.ALU_MUXControl.setData(1);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"and\")) {\r\n //alu.setControl(4);\r\n this.ALUControl.setData(4);\r\n this.ALU_MUXControl.setData(0);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"andi\")) {\r\n //alu.setControl(4);\r\n this.ALUControl.setData(4);\r\n this.ALU_MUXControl.setData(1);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"or\")) {\r\n //alu.setControl(3);\r\n this.ALUControl.setData(3);\r\n this.ALU_MUXControl.setData(0);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"ori\")) {\r\n //alu.setControl(3);\r\n this.ALUControl.setData(3);\r\n this.ALU_MUXControl.setData(1);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"nor\")) {\r\n //alu.setControl(7);\r\n this.ALUControl.setData(7);\r\n this.ALU_MUXControl.setData(0);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"beq\")) {\r\n this.PC_MUXControl.setData(0);\r\n this.ALUControl.setData(10);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.ALU_MUXControl.setData(0);\r\n this.registerWrite.setData(0);\r\n registers.setRegWriteControl(this.registerWrite);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n } else if (operation.equalsIgnoreCase(\"bne\")) {\r\n this.PC_MUXControl.setData(0);\r\n this.ALUControl.setData(11);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.ALU_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n this.registerWrite.setData(0);\r\n registers.setRegWriteControl(this.registerWrite);\r\n\r\n } else if (operation.equalsIgnoreCase(\"jr\")) {\r\n this.PC_MUXControl.setData(1);\r\n this.ALUControl.setData(12);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.ALU_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n this.registerWrite.setData(0);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"j\")) {\r\n this.PC_MUXControl.setData(1);\r\n this.ALUControl.setData(12);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.ALU_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n this.registerWrite.setData(0);\r\n registers.setRegWriteControl(this.registerWrite);\r\n\r\n } else if (operation.equalsIgnoreCase(\"jal\")) {\r\n this.PC_MUXControl.setData(1);\r\n this.ALUControl.setData(16);\r\n this.PC_MUXControl.setData(1);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.ALU_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n this.REG_MUXControl.setData(0);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n\r\n } else if (operation.equalsIgnoreCase(\"slt\")) {\r\n this.ALUControl.setData(13);\r\n this.ALU_MUXControl.setData(0);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n } else if (operation.equalsIgnoreCase(\"slti\")) {\r\n this.ALUControl.setData(13);\r\n this.ALU_MUXControl.setData(1);\r\n this.REG_MUXControl.setData(0);\r\n this.PC_MUXControl.setData(0);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n } else if (operation.equalsIgnoreCase(\"sltu\")) {\r\n this.ALUControl.setData(14);\r\n this.ALU_MUXControl.setData(0);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n } else if (operation.equalsIgnoreCase(\"sltui\")) {\r\n this.ALUControl.setData(14);\r\n this.ALU_MUXControl.setData(1);\r\n this.registerWrite.setData(1);\r\n registers.setRegWriteControl(this.registerWrite);\r\n this.REG_MUXControl.setData(0);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n regMUX.setSelect(this.REG_MUXControl);\r\n this.PC_MUXControl.setData(0);\r\n this.pcMUX.setSelect(this.PC_MUXControl);\r\n } else if (operation.equalsIgnoreCase(\"beq\")) {\r\n this.ALUControl.setData(14);\r\n this.ALU_MUXControl.setData(1);\r\n aluMUX.setSelect(this.ALU_MUXControl);\r\n this.registerWrite.setData(0);\r\n registers.setRegWriteControl(this.registerWrite);\r\n }\r\n instructionMemory.wiresLog.get(instructionMemory.COMMANDS_COUNTER).get(1).add(\"ALU CONTROL: \" + this.ALUControl.toString());\r\n instructionMemory.wiresLog.get(instructionMemory.COMMANDS_COUNTER).get(1).add(\"ALU MUX CONTROL: \" + this.ALU_MUXControl.toString());\r\n instructionMemory.wiresLog.get(instructionMemory.COMMANDS_COUNTER).get(1).add(\"PC MUX CONTROL: \" + this.PC_MUXControl.toString());\r\n instructionMemory.wiresLog.get(instructionMemory.COMMANDS_COUNTER).get(1).add(\"REG MUX CONTROL: \" + this.REG_MUXControl.toString());\r\n instructionMemory.wiresLog.get(instructionMemory.COMMANDS_COUNTER).get(1).add(\"MEMORY READ: \" + this.readWire.toString());\r\n instructionMemory.wiresLog.get(instructionMemory.COMMANDS_COUNTER).get(1).add(\"MEMORY WRITE: \" + this.writeWire.toString());\r\n instructionMemory.wiresLog.get(instructionMemory.COMMANDS_COUNTER).get(1).add(\"REGISTER WRITE: \" + this.registerWrite.toString());\r\n this.setRegisterWriteControl();\r\n }", "public void set(){\n if (getRhs().isResolved() && getRhs().isSimpleValue()){\n getParameter().setExpression((ArchSimpleExpressionSymbol) getRhs());\n }\n else {\n throw new IllegalStateException(\"The value of the parameter is set to a sequence or the expression is not resolved. This should never happen.\");\n }\n }", "public void setValue(Object val);", "public void setValues (String values)\n {\n List<Character> valueList = values.chars().mapToObj(c -> (char)c).collect(Collectors.toList());\n for (State state : this.stateMap.values()) {\n state.values(valueList);\n }\n }", "void assignOperators(Object rgID, List<Object> operIDs);", "void setValue(V value);", "@ConfigOperation\n @Order(50)\n protected void execChangedValue() throws ProcessingException {\n }", "public sparqles.avro.discovery.DGETInfo.Builder setOperation(java.lang.CharSequence value) {\n validate(fields()[1], value);\n this.Operation = value;\n fieldSetFlags()[1] = true;\n return this; \n }", "public V setValue(V value);", "@objid (\"f604cc17-9920-4a0a-a7d0-2659ddf966f4\")\n void setOBase(Operation value);", "protected abstract void setValue(V value);", "@Override\n public void setValues(int arg0, List<? extends Value> arg1, int arg2, int arg3) throws InvalidTypeException, ClassNotLoadedException {\n throw new UnsupportedOperationException();\n }", "public void setValorCalculo(ValoresCalculo valorCalculo)\r\n/* 93: */ {\r\n/* 94:111 */ this.valorCalculo = valorCalculo;\r\n/* 95: */ }", "public void setData(T val) {\r\n\t\tthis.val = val;\r\n\t}", "@Override\n\tprotected void setOriginalOperators(Set<Operator> ops)\n\t{\n\t\tMap<String, Operator> original = new HashMap<String, Operator>(\n\t\t\t\t(int) (operators.size() * 0.75) + 1);\n\t\tint index = 0; // Each operator should get a unique name. Append a index\n\t\t\t\t\t\t// if it has a duplicate name.\n\t\tfor (Operator op : operators)\n\t\t{\n\t\t\tif (original.containsKey(op.getName()))\n\t\t\t{\n\t\t\t\toriginal.put(op.getName() + index, op.copy());\n\t\t\t\top.setName(op.getName() + index);\n\t\t\t\t++index;\n\t\t\t} else\n\t\t\t{\n\t\t\t\toriginal.put(op.getName(), op.copy());\n\t\t\t}\n\t\t}\n\t\toriginalOperators = Collections.unmodifiableMap(original);\n\t}", "void doSet() throws NotConnectedException\n\t{\n\t\ttry\n\t\t{\n\t\t\tValueExp exp = null;\n\n\t\t\tif (!hasMoreTokens())\n\t\t\t\terr(getLocalizationManager().getLocalizedTextString(\"setCommand\")); //$NON-NLS-1$\n\t\t\telse\n\t\t\t{\n\t\t\t\t// pull the expression\n\t\t\t\tString s = restOfLine();\n\n\t\t\t\t// parse and eval which causes the assignment to occur...\n\t\t\t\tif ( (exp = parseExpression(s)) == null )\n\t\t\t\t\t; // failed parse\n\n\t\t\t\t// make sure contains assignment\n\n\t\t\t\telse if ( !exp.containsAssignment() )\n\t\t\t\t\tthrow new IllegalAccessException(\"=\"); //$NON-NLS-1$\n\n\t\t\t\telse\n\t\t\t\t\tevalExpression(exp);\n\t\t\t}\n\t\t}\n\t\tcatch(IllegalAccessException iae)\n\t\t{\n\t\t\tMap<String, Object> args = new HashMap<String, Object>();\n\t\t\targs.put(\"operator\", iae.getMessage()); //$NON-NLS-1$\n\t\t\terr(getLocalizationManager().getLocalizedTextString(\"missingOperator\", args)); //$NON-NLS-1$\n\t\t}\n\t\tcatch(NullPointerException npe)\n\t\t{\n\t\t\terr(getLocalizationManager().getLocalizedTextString(\"couldNotEvaluate\")); //$NON-NLS-1$\n\t\t}\n\t}", "public void setOperation(OperationType operation) {\r\n this.operation = operation;\r\n }", "public void setOperation(OperationType operation) {\r\n this.operation = operation;\r\n }", "public void setAxisOperation(org.apache.axis2.description.xsd.AxisOperation param){\n localAxisOperationTracker = true;\n \n this.localAxisOperation=param;\n \n\n }", "public void setOperators(List<Operator> operators){\n _operators = operators;\n }", "private void saveValues() {\r\n this.pl_expert.setParam(\"displayNodeDegree\", (String) this.nodeDegreeSpinner.getValue());\r\n this.pl_expert.setParam(\"displayEdges\", (String) this.displayEdgesSpinner.getValue());\r\n this.pl_expert.setParam(\"scale\", (String) this.scaleSpinner.getValue());\r\n this.pl_expert.setParam(\"minWeight\", (String) this.minweightSpinner.getValue());\r\n this.pl_expert.setParam(\"iterations\", (String) this.iterationsSpinner.getValue());\r\n this.pl_expert.setParam(\"mutationParameter\", this.mutationParameter.getSelection().getActionCommand());\r\n this.pl_expert.setParam(\"Update_param\", this.Update_param.getSelection().getActionCommand());\r\n this.pl_expert.setParam(\"vote_value\", (String) this.vote_value.getValue());\r\n this.pl_expert.setParam(\"keep_value\", (String) this.keep_value.getValue());\r\n this.pl_expert.setParam(\"mut_value\", (String) this.mut_value.getValue());\r\n this.pl_expert.setParam(\"only_sub\", new Boolean(this.only_sub.isSelected()).toString());\r\n\r\n this.is_alg_started = false;\r\n }", "public void setValue(Object o){\n \tthis.value = o;\n }", "public void setOperandB(int val);", "public void setOperation(String aOperation) {\n operation = aOperation;\n }", "public void setOperation(String aOperation) {\n operation = aOperation;\n }", "public void setValues(ArrayList<Double> allValues)\n {\n this.minimumValue = getMinNumber(allValues);\n this.maximumValue = getMaxNumber(allValues);\n this.allValues = allValues;\n }", "public static void setCostPerOp(){\n\t\tcostPerOp.put(\"~\",1.0);\n\t\tcostPerOp.put(\"&\",1.0);\n\t\tcostPerOp.put(\"@\",1.0);\n\t\tcostPerOp.put(\"+\",1.0);\n\t\tcostPerOp.put(\"^\",1.0);\n\t\tcostPerOp.put(\".\",1.0);\n\t\tcostPerOp.put(\"=\",1.0);\n\t}", "public void setOperation (String operation) {\n this.operation = operation;\n }", "public void setOperation (String operation) {\n this.operation = operation;\n }", "public void setValue(Object value);", "void setParameter(String name, String[] values);", "public void setCvpOperationLength(long value)\n {\n if(__cvpOperationLength != value)\n {\n _isDirty = true;\n }\n __cvpOperationLength = value;\n }", "public Builder setOperation(com.clarifai.grpc.api.Operation value) {\n if (operationBuilder_ == null) {\n if (value == null) {\n throw new NullPointerException();\n }\n operation_ = value;\n onChanged();\n } else {\n operationBuilder_.setMessage(value);\n }\n\n return this;\n }", "public void setValue(Object value) { this.value = value; }", "void setValue(Object value);", "public void setSystemOperationData(byte[] sysOpdata) {\n\t\tthis.systemOperationData=sysOpdata;\n\t}", "public void setOperations(java.util.Collection<OperationSummary> operations) {\n if (operations == null) {\n this.operations = null;\n return;\n }\n\n this.operations = new com.amazonaws.internal.SdkInternalList<OperationSummary>(operations);\n }", "public int setValue (int val);", "public void setOperation(String operation) {\n this.operation = operation;\n }", "public void setOperation(String operation) {\n this.operation = operation;\n }", "public SCControlPoint(@NonNull byte[] values) {\n mOpCode = (values[0] & 0xff);\n if (isOpCodeSetCumulativeValue(mOpCode)) {\n mCumulativeValue = BLEUtils.createUInt32(values, 1);\n mSensorLocationValue = 0;\n mRequestOpCode = 0;\n mResponseValue = 0;\n mResponseParameter = new byte[0];\n } else if (isOpCodeStartSensorCalibration(mOpCode)) {\n mCumulativeValue = 0;\n mSensorLocationValue = 0;\n mRequestOpCode = 0;\n mResponseValue = 0;\n mResponseParameter = new byte[0];\n } else if (isOpCodeUpdateSensorLocation(mOpCode)) {\n mCumulativeValue = 0;\n mSensorLocationValue = (values[1] & 0xff);\n mRequestOpCode = 0;\n mResponseValue = 0;\n mResponseParameter = new byte[0];\n } else if (isOpCodeRequestSupportedSensorLocations(mOpCode)) {\n mCumulativeValue = 0;\n mSensorLocationValue = 0;\n mRequestOpCode = 0;\n mResponseValue = 0;\n mResponseParameter = new byte[0];\n } else if (isOpCodeResponseCode(mOpCode)) {\n mCumulativeValue = 0;\n mSensorLocationValue = 0;\n mRequestOpCode = (values[1] & 0xff);\n mResponseValue = (values[2] & 0xff);\n if (isOpCodeSetCumulativeValue(mRequestOpCode)) {\n mResponseParameter = new byte[0];\n } else if (isOpCodeStartSensorCalibration(mRequestOpCode)) {\n mResponseParameter = new byte[0];\n } else if (isOpCodeUpdateSensorLocation(mRequestOpCode)) {\n mResponseParameter = new byte[0];\n } else if (isOpCodeRequestSupportedSensorLocations(mRequestOpCode)) {\n if (isResponseValueSuccess()) {\n mResponseParameter = Arrays.copyOfRange(values, 3, values.length);\n } else {\n mResponseParameter = new byte[0];\n }\n } else {\n mResponseParameter = new byte[0];\n }\n } else {\n mCumulativeValue = 0;\n mSensorLocationValue = 0;\n mRequestOpCode = 0;\n mResponseValue = 0;\n mResponseParameter = new byte[0];\n }\n }", "private void setAllAttributesFromController() {\n obsoData.setSupplier(supplier);\n \n obsoData.setEndOfOrderDate(endOfOrderDate);\n obsoData.setObsolescenceDate(obsolescenceDate);\n \n obsoData.setEndOfSupportDate(endOfSupportDate);\n obsoData.setEndOfProductionDate(endOfProductionDate);\n \n obsoData.setCurrentAction(avlBean.findAttributeValueListById(\n ActionObso.class, actionId));\n obsoData.setMtbf(mtbf);\n \n obsoData.setStrategyKept(avlBean.findAttributeValueListById(\n Strategy.class,\n strategyId));\n obsoData.setContinuityDate(continuityDate);\n \n obsoData.setManufacturerStatus(avlBean.findAttributeValueListById(\n ManufacturerStatus.class, manufacturerStatusId));\n obsoData.setAirbusStatus(avlBean.findAttributeValueListById(\n AirbusStatus.class, airbusStatusId));\n \n obsoData.setLastObsolescenceUpdate(lastObsolescenceUpdate);\n obsoData.setConsultPeriod(avlBean.findAttributeValueListById(\n ConsultPeriod.class, consultPeriodId));\n \n obsoData.setPersonInCharge(personInCharge);\n obsoData.setCommentOnStrategy(comments);\n }", "void setBits(int... values);", "public abstract void setValue(int value);" ]
[ "0.64342886", "0.61374587", "0.6086065", "0.60711694", "0.5968921", "0.59523237", "0.5936272", "0.5928691", "0.59243006", "0.59000444", "0.589557", "0.5853003", "0.5831332", "0.5825049", "0.5774156", "0.57675767", "0.57512283", "0.57436067", "0.5701845", "0.5682495", "0.56696224", "0.5664241", "0.56537586", "0.5636131", "0.56352997", "0.5634059", "0.56035393", "0.5602666", "0.5595969", "0.5594173", "0.5593194", "0.55839515", "0.5558794", "0.55587476", "0.5551879", "0.5549335", "0.5547504", "0.5538751", "0.5522363", "0.5513601", "0.5513228", "0.5506611", "0.5498658", "0.5491735", "0.5487903", "0.54877806", "0.5487678", "0.5486723", "0.54658306", "0.54651195", "0.54518044", "0.5439435", "0.5432992", "0.5432257", "0.5430839", "0.54071283", "0.54045445", "0.5400663", "0.53919595", "0.53903323", "0.5367029", "0.53667563", "0.53649706", "0.5352178", "0.5347224", "0.5341319", "0.5336999", "0.53348273", "0.5289045", "0.5288855", "0.5278834", "0.5275589", "0.52658635", "0.52631706", "0.52631706", "0.5260842", "0.5258418", "0.5248931", "0.52446485", "0.52318966", "0.5223007", "0.5223007", "0.5222806", "0.5219145", "0.52186424", "0.52186424", "0.5216153", "0.5215437", "0.52105874", "0.52098596", "0.5202975", "0.51972544", "0.51835155", "0.5181607", "0.51807344", "0.51731354", "0.51731354", "0.51695055", "0.51628333", "0.51606053", "0.5153628" ]
0.0
-1
Build the configuration instance.
UpdateOperationConfiguration build();
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public abstract CONFIG build();", "@NonNull\n\t\tConfig build();", "public ClusterConfig build() {\n return new ClusterConfig(_id, _resourceMap, _participantMap, _constraintMap, _stateModelMap,\n _stats, _alerts, _userConfig, _isPaused, _autoJoin);\n }", "public IotdmSimpleConfig build() {\n return new IotdmSimpleConfig(this.builder.build());\n }", "public SSLConfig build()\n {\n return new SSLConfig(\n isClient, verifyMode, this.caPath, this.certPath, this.keyPath);\n }", "@Nonnull\n public ShipConfiguration build() {\n return new ShipConfiguration(\n radius, movementSpeed, acceleration, traverseSpeed, hitPoints, engines, thrusters, sensors,\n defenses, weapons, energy);\n }", "public com.google.protobuf.Any.Builder getConfigurationBuilder() {\n \n onChanged();\n return getConfigurationFieldBuilder().getBuilder();\n }", "public C build() {\n if (configs.isEmpty()) {\n throw new RuntimeException(\"There should be at least one configuration provided\");\n }\n\n // Handling config files\n ConfigSource firstConfigSource = configs.get(0);\n Config firstConfigOrig = getConfigSupplier(firstConfigSource).getConfig();\n if (!(supportedConfig.isInstance(firstConfigOrig))) {\n throw new RuntimeException(\n String.format(\n \"Config is not of parameterized type %s, got instead %s\",\n supportedConfig.getName(), firstConfigOrig.getClass().getName()));\n }\n C firstConfig = (C) firstConfigOrig;\n for (int i = 1; i < configs.size(); ++i) {\n ConfigSource nextConfigSource = configs.get(i);\n Config nextConfig = getConfigSupplier(nextConfigSource).getConfig();\n try {\n firstConfig = copyProperties(firstConfig, nextConfig);\n } catch (Exception ex) {\n throw new RuntimeException(\n String.format(\"Failed to merge config %s into main config\", nextConfigSource), ex);\n }\n }\n\n // Handling string pathValue pairs config overrides\n for (Pair<String, Object> pathValue : pathValueOverrides) {\n try {\n PropertyUtils.setNestedProperty(firstConfig, pathValue.getValue0(), pathValue.getValue1());\n } catch (Exception e) {\n throw new RuntimeException(\n String.format(\n \"Cannot override property %s with value %s\",\n pathValue.getValue0(), pathValue.getValue1()),\n e);\n }\n }\n\n return firstConfig;\n }", "public StandardTransactionConfig build() {\n Preconditions.checkArgument(null != timestamp || null != timestampProvider);\n\n return new StandardTransactionConfig(metricsPrefix,\n timestampProvider, timestamp, customOptions);\n }", "Pair<T, U> build() throws IOException, ConfigurationException;", "public abstract Configuration configuration();", "public void buildTwitterBaseConfiguration() {\n ConfigurationBuilder configurationBuilder = new ConfigurationBuilder();\n configurationBuilder\n .setOAuthConsumerKey(getBaseContext().getString(R.string.consumer_key))\n .setOAuthConsumerSecret(getBaseContext().getString(R.string.consumer_secret))\n .setOAuthAccessToken(getBaseContext().getString(R.string.access_token))\n .setOAuthAccessTokenSecret(getBaseContext().getString(R.string.access_token_secret));\n\n Configuration configuration = configurationBuilder.build();\n\n twitterStreamFactory = new TwitterStreamFactory(configuration);\n }", "public RgwAdmin build() {\n if (Stream.of(accessKey, secretKey, endpoint).anyMatch(Strings::isNullOrEmpty)) {\n throw new IllegalArgumentException(\"Missing required parameter to build the instance.\");\n }\n return new RgwAdminImpl(accessKey, secretKey, endpoint);\n }", "public KafkaOffsetManager build() {\n\n String err = \"All required parameters were not set: \";\n if (instance.kc == null) {\n throw new IllegalStateException(err + \"failed to setup kafkacluster instance, invalid brokerlist?\");\n }\n if (StringUtils.isBlank(instance.groupid)) {\n throw new IllegalStateException(err + \"Groupid cannot be null or blank.\");\n }\n if (instance.topicList.isEmpty()) {\n throw new IllegalStateException(err + \"Topic needs to be set.\");\n }\n if (instance.dao == null) {\n throw new IllegalStateException(err + \"OffsetManagerDAO not set.\");\n }\n if (!instance.startFrom.equals(\"earliest\") && !instance.startFrom.equals(\"latest\")) {\n throw new IllegalStateException(err + \"StarFrom needs to be either 'earliest' or 'latest'.\");\n }\n\n return instance;\n }", "public static NodeConfigBuilder builder() {\n\t\treturn new NodeConfigBuilder();\n\t}", "public CrawlerConfiguration() {\n\t\tinitConfiguration();\n\t}", "public DerivedFeatureConfig.Builder getConfigBuilder() {\n \n onChanged();\n return getConfigFieldBuilder().getBuilder();\n }", "private Config() {\n }", "protected Configuration() {\r\n }", "protected Configuration createConfiguration()\r\n/* 76: */ {\r\n/* 77:119 */ this.configuration_d.setNumOfIterations(Integer.parseInt(this.jTextField1.getText()));\r\n/* 78:120 */ this.configuration_d.setPopulationSize(Integer.parseInt(this.popSize_d.getText()));\r\n/* 79:121 */ ((GAConfiguration)this.configuration_d).setCrossoverThreshold(Double.valueOf(this.jTextField2.getText()).doubleValue());\r\n/* 80:122 */ ((GAConfiguration)this.configuration_d).setMutationThreshold(Double.valueOf(this.jTextField3.getText()).doubleValue());\r\n/* 81:123 */ ((GAConfiguration)this.configuration_d).setMethod((String)this.methodList_d.getSelectedItem());\r\n/* 82:124 */ return this.configuration_d;\r\n/* 83: */ }", "private com.google.protobuf.SingleFieldBuilderV3<\n com.google.protobuf.Any, com.google.protobuf.Any.Builder, com.google.protobuf.AnyOrBuilder> \n getConfigurationFieldBuilder() {\n if (configurationBuilder_ == null) {\n configurationBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<\n com.google.protobuf.Any, com.google.protobuf.Any.Builder, com.google.protobuf.AnyOrBuilder>(\n getConfiguration(),\n getParentForChildren(),\n isClean());\n configuration_ = null;\n }\n return configurationBuilder_;\n }", "Configuration getConfiguration();", "Configuration getConfiguration();", "Configuration getConfiguration();", "Configuration getConfiguration();", "public AtRule build() {\n return new AtRule(this);\n }", "private Configuration getConfig() {\n final Configuration config = new Configuration();\n for (final Field field : getClass().getDeclaredFields()) {\n try {\n final Field configField = Configuration.class.getDeclaredField(field.getName());\n field.setAccessible(true);\n configField.setAccessible(true);\n\n final Object value = field.get(this);\n if (value != null) {\n configField.set(config, value);\n getLog().debug(\"using \" + field.getName() + \" = \" + value);\n }\n } catch (final NoSuchFieldException nsfe) {\n // ignored\n } catch (final Exception e) {\n getLog().warn(\"can't initialize attribute \" + field.getName());\n }\n\n }\n if (containerProperties != null) {\n final Properties props = new Properties();\n props.putAll(containerProperties);\n config.setProperties(props);\n }\n if (forceJspDevelopment) {\n if (config.getProperties() == null) {\n config.setProperties(new Properties());\n }\n config.getProperties().put(\"tomee.jsp-development\", \"true\");\n }\n return config;\n }", "public Config() {\n this(System.getProperties());\n\n }", "public Config() {\n\t\t// TODO Auto-generated constructor stub\n\t\t\n\t}", "public Function<Config, ConfigFilter> build() {\n return (c) -> new ValueResolvingFilter(failOnMissingReference);\n }", "private ReducedCFGBuilder() {\n\t}", "private OptimoveConfig() {\n }", "Pair<T, U> build(ConfigurationSourceProvider provider, String path) throws IOException, ConfigurationException;", "public com.google.privacy.dlp.v2.StoredInfoTypeConfig.Builder getConfigBuilder() {\n bitField0_ |= 0x00000001;\n onChanged();\n return getConfigFieldBuilder().getBuilder();\n }", "public JobLogParserConfiguration() {\r\n\r\n produceRegularExpressions();\r\n compilePattern();\r\n }", "public com.google.api.servicemanagement.v1.ConfigSource.Builder getConfigSourceBuilder() {\n \n onChanged();\n return getConfigSourceFieldBuilder().getBuilder();\n }", "public QueryOptions build() {\n return new QueryOptions(this.columns, this.excludeColumns, this.excludeAttributes, this.shards);\n }", "public Builder() {\r\n // setting default values\r\n configurationBuilder.httpStatusCodesToRetry(Stream.of(408, 413, 429, 500, 502, 503, 504,\r\n 521, 522, 524).collect(Collectors.toSet()));\r\n configurationBuilder.httpMethodsToRetry(Stream.of(Method.GET,\r\n Method.PUT).collect(Collectors.toSet()));\r\n }", "default Pair<T, U> build(File file) throws IOException, ConfigurationException {\n return build(new FileConfigurationSourceProvider(), file.toString());\n }", "private CustomClassBuilder(Configuration configuration) {\n\t\tsuper(configuration);\n\t}", "public IProjectConfiguration getConfiguration()\n {\n return new ProjectConfiguration(mProject, mCheckConfigs, mFileSets, mFilters,\n mUseSimpleConfig);\n }", "@SuppressWarnings(\"unused\")\n @Provides\n @Singleton\n private ExpressiveObjectsConfigurationBuilder providesConfigurationBuilder() {\n return expressiveObjectsConfigurationBuilder;\n }", "public io.dstore.values.BooleanValue.Builder getImportConfigurationBuilder() {\n \n onChanged();\n return getImportConfigurationFieldBuilder().getBuilder();\n }", "public com.google.cloud.datafusion.v1beta1.CryptoKeyConfig.Builder getCryptoKeyConfigBuilder() {\n bitField0_ |= 0x04000000;\n onChanged();\n return getCryptoKeyConfigFieldBuilder().getBuilder();\n }", "public SimpleXMLPipelineConfiguration() {\n configurations = new HashMap();\n }", "public void build() {\r\n // TODO\r\n }", "public Configuration() {\r\n\t\t\tmaxEffectiveWorker = (Runtime.getRuntime().availableProcessors()*3/2) + 2;\r\n\t\t\tmaxPhysicalWorker = Math.max(32, (maxEffectiveWorker * 2) + 2);\r\n\t\t}", "private ENFAutomaton build() {\n final Set<State> states = new HashSet<State>(this.states.values());\n final Set<State> acceptStates = new HashSet<State>(this.acceptStates.values());\n\n final Set<Input> alphabet = alphabetBuilder.build();\n\n final ENFAutomatonTransferFunction transferFunction = transferFunctionBuilder.build(this.states);\n\n return new ENFAutomaton(states, acceptStates, alphabet, transferFunction, initial);\n }", "private static void initConfig() {\n /*\n * Human IO\n */\n {\n /*\n * Constants\n */\n {\n /*\n * Joysticks\n */\n {\n addToConstants(\"joysticks.left\", 0);\n addToConstants(\"joysticks.right\", 1);\n addToConstants(\"joysticks.operator\", 2);\n }\n\n /*\n * Buttons and axis\n */\n {\n }\n }\n }\n\n /*\n * RobotIO\n */\n {\n /*\n * Constants\n */\n {\n /*\n * Kicker\n */\n addToConstantsA(\"kicker.encoder.distPerPulse\", 360.0 / 1024.0);\n }\n }\n\n /*\n * Chassis\n */\n {\n /*\n * Constants\n */\n {\n }\n\n /*\n * Variables\n */\n {\n }\n }\n\n /*\n * Kicker\n */\n {\n /*\n * Constants\n */\n {\n addToConstants(\"kicker.kick.normal\", 1.75);\n addToConstants(\"kicker.kick.timeout\", 0.75);\n\n addToConstants(\"kicker.shaken.voltage\", -0.3316);\n addToConstants(\"kicker.shaken.tolerance\", 3.0);\n\n addToConstants(\"kicker.zero.voltage\", 0.8);\n addToConstants(\"kicker.zero.duration\", 0.75);\n }\n\n /*\n * Variables\n */\n {\n }\n }\n\n /*\n * Gripper\n */\n {\n /*\n * Constants\n */\n {\n addToConstants(\"gripper.collection.voltage\", 0.82);\n addToConstants(\"gripper.ejection.voltage\", -0.45);\n }\n }\n }", "@Override\r\n\t\t\tpublic Object construct() {\n\t\t\t\tXMLUtils xml = new XMLUtils();\r\n\t\t\t\tConfigBean cfg = xml.getconfigXML();\r\n\t\t\t\tFile f = new File(cfg.getFilepath());\r\n\t\t\t\tFile fs[];\r\n\t\t\t\tif (f.exists() && f.isFile()) {\r\n\t\t\t\t\tfs = f.getParentFile().listFiles();\r\n\t\t\t\t} else {\r\n\t\t\t\t\tfs = f.listFiles();\r\n\t\t\t\t}\r\n\t\t\t\tif (fs != null) {\r\n\t\t\t\t\tfor (File of : fs) {\r\n\t\t\t\t\t\tif(MainFrame.getInstance().getManual().isSelected()){\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tif (of.isFile()) {\r\n\t\t\t\t\t\t\tMainFrame.getInstance().getProcess().start(of);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\treturn null;\r\n\t\t\t}", "protected AsyncHttpClientConfig buildAHCConfig(CONFIG config,\n AsyncHttpClientConfig.Builder ahcConfigBuilder)\n {\n return ahcConfigBuilder.build();\n }", "private ConfigDescribe(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {\n super(builder);\n }", "protected T getConfigurationByCascading() {\n\t\t\n\t\tList<T> configurationObjectList = new ArrayList<T>();\n\t\t\n\t\t// Add the configuration objects in the order they should override \n\t\t// each other. Command line options override property file information\n\t\t// which in turn override any default configuration objects that may\n\t\t// have been given.\n\t\t//\n\t\tconfigurationObjectList.add (getConfigurationByCommandline());\n\t\tconfigurationObjectList.addAll (getConfigurationByProperties(this.propertyFile));\n\t\tconfigurationObjectList.addAll (configurationObjects);\n\t\t\n\t\tInvocationHandler handler = new ConfigurationByCascading<T>(configurationObjectList);\n\n\t\t@SuppressWarnings(\"unchecked\")\t\t\n\t\tT configuration = (T)\n\t\t\tjava.lang.reflect.Proxy.newProxyInstance(\n\t\t\t\tthis.configurationInterface.getClassLoader(),\n\t\t\t\tnew Class[] { this.configurationInterface },\n\t\t\t\thandler\n\t\t);\n\n\t\treturn configuration;\n\t}", "public T configure() {\n if (validationProviderClass == null) {\n throw new ValidationException(\n \"builder is mandatory. Use Validation.byDefaultProvider() to use the generic provider discovery mechanism\");\n }\n // used mostly as a BootstrapState\n GenericBootstrapImpl state = new GenericBootstrapImpl();\n if (resolver == null) {\n resolver = state.getDefaultValidationProviderResolver();\n } else {\n // stay null if no resolver is defined\n state.providerResolver(resolver);\n }\n\n List<ValidationProvider<?>> resolvers;\n try {\n resolvers = resolver.getValidationProviders();\n } catch (RuntimeException re) {\n throw new ValidationException(\n \"Unable to get available provider resolvers.\", re);\n }\n\n for (ValidationProvider<?> provider : resolvers) {\n // GWT validation only support exact matches.\n if (validationProviderClass.equals(provider.getClass())) {\n @SuppressWarnings(\"unchecked\")\n ValidationProvider<T> specificProvider = (ValidationProvider<T>) provider;\n return specificProvider.createSpecializedConfiguration(state);\n }\n }\n throw new ValidationException(\"Unable to find provider: \"\n + validationProviderClass);\n }", "private Configuration getAuth() {\r\n final ConfigurationBuilder cb = new ConfigurationBuilder();\r\n cb.setOAuthConsumerKey(\"n2g9XOjAr9p44yJwFjXUbeUa2\");\r\n cb.setOAuthConsumerSecret(\"57FHkBBptp17yBGl1v853lldZO9Kh4osJnDQqQEcXd4d9C3xFA\");\r\n cb.setOAuthAccessToken(\"113906448-2fx9njfJgzQrGdnRaGchI9GlZTzLMXrayEzFk2ju\");\r\n cb.setOAuthAccessTokenSecret(\"FJOqMt7dtBp1yuW2VnQDfzksa7IS5h3IxxsJ1ixBGI1ny\");\r\n \r\n return cb.build();\r\n }", "private Config()\n {\n // Load from properties file:\n loadLocalConfig();\n // load the system property overrides:\n getExternalConfig();\n }", "@Override\r\n public RuleDefinition build() {\r\n return new RuleDefinition(this);\r\n }", "public Device build() {\n return new Device(name, active);\n }", "private static Configuration getConfig() {\n Configuration vgConfig = new Configuration();\n vgConfig.addBrowser(1200, 800, BrowserType.CHROME);\n vgConfig.addBrowser(1200, 800, BrowserType.FIREFOX);\n vgConfig.addBrowser(1200, 800, BrowserType.EDGE);\n vgConfig.addBrowser(1200, 800, BrowserType.SAFARI);\n vgConfig.addDeviceEmulation(DeviceName.iPhone_X, ScreenOrientation.PORTRAIT);\n return vgConfig;\n }", "public com.google.assistant.embedded.v1alpha1.ConverseConfig.Builder getConfigBuilder() {\n return getConfigFieldBuilder().getBuilder();\n }", "public Builder(OzoneConfiguration conf) {\n super(conf);\n }", "protected Configuration getConfiguration(){\n return configuration;\n }", "public BaseConfig() {\n\t\tlong current = System.currentTimeMillis();\n\t\tCalendar cal = Calendar.getInstance();\n\t\tcal.setTimeInMillis(current);\n\t\tthis.start_hours = cal.get(Calendar.HOUR_OF_DAY);\n\t\tthis.start_minutes = cal.get(Calendar.MINUTE);\n\t\tthis.stop_hours = this.start_hours;\n\t\tthis.stop_minutes = this.start_minutes;\n\t\tthis.force_on = false;\n\t\tthis.force_off = false;\n\t\tthis.sensor_type = SensorType.LIGHT;\n\t\tthis.sensing_threshold = .5f;\n\t\tthis.sensorInterval = 3000;\n\t\t/*String address;\n\t\ttry {\n\t\t\taddress = InetAddress.getLocalHost().toString();\n\t\t\taddress = address.substring(address.indexOf('/') + 1);\n\t\t\tserverIP = address;\n\t\t\tserverPort = 9999;\n\t\t} catch (UnknownHostException e) {\n\t\t\t// Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}*/\n\t\t\n\t}", "CdapInternalApplicationConfiguration createCdapInternalApplicationConfiguration();", "public Builder() {\n\t\t}", "public Configuration.Builder getAccessTokenBuilder() {\n String accessToken = getString(R.string.access_token);\n return new Configuration.Builder(accessToken);\n }", "public EventBus build() {\n return new EventBus(this);\n }", "public MicroConfiguration() {\n this(\n System.getProperty(\"piranha.version\", MicroConfiguration.class.getPackage().getImplementationVersion()),\n System.getProperty(\"piranha.extensions\", \"micro-core,micro\"),\n System.getProperty(\"piranha.dependencies\", \"\"),\n System.getProperty(\"piranha.repositories\", \"https://repo1.maven.org/maven2\"),\n Boolean.valueOf(System.getProperty(\"piranha.offline\", \"false\")),\n Integer.valueOf(System.getProperty(\"piranha.port\", \"8080\")),\n System.getProperty(\"piranha.root\"),\n System.getProperty(\"piranha.http.server\", \"impl\"),\n\n\n null,\n null,\n null);\n }", "public AntConfiguration(){\n this.channelID1 = new ChannelID(); //initially set all parameters of Channel ID to 0\n this.channelID2 = new ChannelID(); //initially set all parameters of Channel ID to 0\n\n this.channelAssigned1 = new Channel(); //initially do not assign any cha\n this.channelAssigned2 = new Channel(); //initially do not assign any channel\n\n this.channelPeriod = 4; //set to 4Hz by default\n this.level = PowerLevel.NEGTWENTY; //set to -20dB as default\n this.state1 = ChannelState.UNASSIGNED;\n this.state2 = ChannelState.UNASSIGNED;\n\n }", "public LogInfluxClient build() {\n LogInfluxClient logStatsdClient = new LogInfluxClient();\n logStatsdClient.setSendSink(sendSink);\n logStatsdClient.setCommonTags(commonTags);\n return logStatsdClient;\n }", "@NotNull\n public Server.Builder build() {\n return builder.compression(compressionSetting);\n }", "private CommonConfigBean(){\n\t\tsuper();\n\t\t\n\t\t\n\t\ttry {\n\n\t\t\tFile fXmlFile = new File(PathTool.getAbsolute(RELATIVE_FILE_PATH));\n\t\t\tDocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance();\n\t\t\tDocumentBuilder dBuilder = dbFactory.newDocumentBuilder();\n\t\t\tDocument doc = dBuilder.parse(fXmlFile);\n\t\t\t\t\t\n\t\t\t//optional, but recommended\n\t\t\t//read this - http://stackoverflow.com/questions/13786607/normalization-in-dom-parsing-with-java-how-does-it-work\n\t\t\tdoc.getDocumentElement().normalize();\n\n\t\t\tSystem.out.println(\"Root element :\" + doc.getDocumentElement().getNodeName());\n\t NodeList nList = doc.getElementsByTagName(\"param\");\n\t params = new HashMap<>();\n\t for (int temp = 0; temp < nList.getLength(); temp++) {\n\t Node nodo = nList.item(temp);\n\t System.out.println(\"Elemento:\" + nodo.getNodeName());\n\t if (nodo.getNodeType() == Node.ELEMENT_NODE) {\n\t Element element = (Element) nodo;\n\t params.put(element.getAttribute(\"name\"), element.getAttribute(\"value\"));\n\t }\n\t }\n\t\t\t\n\t\t\t\n\t\t } catch (Exception e) {\n\t\t \te.printStackTrace();\n\t\t }\n\t}", "@Override\n\tpublic void configure() throws CoreException {\n\t\t// associate this builder with the project\n\t\tPTJavaFileBuilder.addBuilderToProject(fProject);\n\t\t\n\t\t// issue order to rebuild project\n\t\tnew Job(\"PTJava File Build\") {\n\t\t\tprotected IStatus run(IProgressMonitor monitor) {\n\t\t\t\ttry {\n\t\t\t\t\t// invoke a full build\n\t\t\t\t\tfProject.build(\n\t\t\t\t\t\t\tPTJavaFileBuilder.FULL_BUILD,\n\t\t\t\t\t\t\tPTJavaFileBuilder.BUILDER_ID,\n\t\t\t\t\t\t\tnull, monitor);\n\t\t\t\t}\n\t\t\t\tcatch (CoreException exception) {\n\t\t\t\t\tPTJavaLog.logError(exception);\n\t\t\t\t}\n\t\t\t\treturn Status.OK_STATUS;\n\t\t\t}\n\t\t}.schedule();\n\t}", "public static Configuration getConfiguration() {\r\n\t\treturn config;\r\n\t}", "public ArcadeDrivetrain build() {\n verify();\n return new ArcadeDrivetrain(this);\n }", "private Config()\n {\n try\n {\n // Load settings from file\n load();\n }\n catch(IOException e)\n {\n e.printStackTrace();\n }\n }", "public ValidateConfiguration() {\n super();\n }", "C getConfiguration();", "private DevConfig(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {\n super(builder);\n }", "public ManagedConfiguration createConfiguration() throws SmartFrogException, RemoteException {\n return ManagedConfiguration.createConfiguration(this, true, isClusterRequired(), false);\n }", "public ConfigProfile buildProfileOne() {\n this.topics = \"kafka-data\";\n this.token = \"mytoken\";\n this.uri = \"https://dummy:8088\";\n this.raw = true;\n this.ack = false;\n this.indexes = \"index-1\";\n this.sourcetypes = \"kafka-data\";\n this.sources = \"kafka-connect\";\n this.httpKeepAlive = true;\n this.validateCertificates = true;\n this.hasTrustStorePath = true;\n this.trustStorePath = \"./src/test/resources/keystoretest.p12\";\n this.trustStoreType = \"PKCS12\";\n this.trustStorePassword = \"Notchangeme\";\n this.eventBatchTimeout = 1;\n this.ackPollInterval = 1;\n this.ackPollThreads = 1;\n this.maxHttpConnPerChannel = 1;\n this.totalHecChannels = 1;\n this.socketTimeout = 1;\n this.enrichements = \"hello=world\";\n this.enrichementMap = new HashMap<>();\n this.trackData = false;\n this.maxBatchSize = 1;\n this.numOfThreads = 1;\n return this;\n }", "public static Config createJeruslaemConfig() {\n\t\tConfig config = ConfigUtils.createConfig();\n\n\t\tconfig.network().setInputFile(INPUT_NETWORK);\n\t\tconfig.plans().setInputFile(INPUT_POPULATION);\n\t\tconfig.facilities().setInputFile(INPUT_FACILITES);\n\t\tconfig.households().setInputFile(INPUT_HOUSEHOLDS);\n\n\t\t// modify controler\n\t\tconfig.controler().setWriteEventsInterval(25);\n\t\tconfig.controler().setWritePlansInterval(25);\n\t\tconfig.controler().setEventsFileFormats(EnumSet.of(EventsFileFormat.xml));\n\t\tconfig.controler().setOutputDirectory(OUTPUT_FOLDER + RUN_ID + \"/\");\n\t\tconfig.controler().setOverwriteFileSetting(OverwriteFileSetting.overwriteExistingFiles);\n\t\tconfig.controler().setFirstIteration(0);\n\t\tconfig.controler().setLastIteration(300);\n\t\tconfig.controler().setMobsim(\"qsim\");\n\t\tconfig.controler().setRoutingAlgorithmType(RoutingAlgorithmType.FastAStarLandmarks);\n\t\tconfig.controler().setRunId(RUN_ID);\n\t\t\n\t\t// modify Qsim\n\t\tconfig.qsim().setStartTime(0.0);\n\t\tconfig.qsim().setEndTime(30 * 3600);\n\t\tconfig.qsim().setFlowCapFactor(0.3);\n\t\tconfig.qsim().setStorageCapFactor(Math.pow(0.3, 0.75));\n\t\tconfig.qsim().setNumberOfThreads(12);\n\t\tconfig.qsim().setSnapshotPeriod(1);\n\t\tconfig.qsim().setStuckTime(10);//30,60 or multiply by 60\n\t\tconfig.qsim().setRemoveStuckVehicles(false);\n\t\tconfig.qsim().setTimeStepSize(1);\n\t\tconfig.qsim().setTrafficDynamics(TrafficDynamics.kinematicWaves);// kinematic waves\n\t\tconfig.qsim().setMainModes(Arrays.asList(TransportMode.car));\n\t\tconfig.qsim().setInsertingWaitingVehiclesBeforeDrivingVehicles(true);\n\n\t\t// modify global\n\t\tconfig.global().setCoordinateSystem(\"EPSG:2039\");\n\t\tconfig.global().setNumberOfThreads(16);\n\t\t// ?? random seed?<param name=\"randomSeed\" value=\"4711\" />\n\t\t\n\t\t// Add transit\n\t\tconfig.transit().setUseTransit(true);\n\t\tconfig.transit().setTransitScheduleFile(INPUT_TRANSIT_SCHEDULE);\n\t\tconfig.transit().setVehiclesFile(INPUT_TRANSIT_VEHICLES);\n\t\t\n\n\n//\t\t// Add sub-tour mode choice\n//\t\tconfig.subtourModeChoice()\n//\t\t\t\t.setModes(new String[] { TransportMode.car, TransportMode.pt, TransportMode.walk, TransportMode.bike });\n//\t\t// TODO check that bike is biycle\n//\t\tconfig.subtourModeChoice().setChainBasedModes(new String[] { TransportMode.car });\n//\n\t\t// Add sub-tour mode choice\n\t\tconfig.timeAllocationMutator().setMutationRange(3600);\n\n\t\t// Add strategy\n\t\tconfig.strategy().setMaxAgentPlanMemorySize(5);\n\t\tconfig.strategy().setFractionOfIterationsToDisableInnovation(0.8);\n\n\t\t// Add strategy - plan selector\n\t\tStrategySettings changeExpStrategy = new StrategySettings();\n\t\tchangeExpStrategy.setDisableAfter(-1);\n\t\tchangeExpStrategy.setStrategyName(DefaultPlanStrategiesModule.DefaultSelector.ChangeExpBeta.toString());\n\t\tchangeExpStrategy.setWeight(0.8);\n\t\tconfig.strategy().addStrategySettings(changeExpStrategy);\n\n//\t\t Add strategy - time-mutation\n\t\tStrategySettings timeMutatorStrategy = new StrategySettings();\n\t\ttimeMutatorStrategy\n\t\t\t\t.setStrategyName(DefaultPlanStrategiesModule.DefaultStrategy.TimeAllocationMutator.toString());\n\t\ttimeMutatorStrategy.setWeight(0.1);\n\t\tconfig.strategy().addStrategySettings(timeMutatorStrategy);\n\n\t\t// Add strategy - re-route\n\t\tStrategySettings reRouteStrategy = new StrategySettings();\n\t\treRouteStrategy.setStrategyName(DefaultPlanStrategiesModule.DefaultStrategy.ReRoute.toString());\n\t\treRouteStrategy.setWeight(0.1);\n\t\tconfig.strategy().addStrategySettings(reRouteStrategy);\n\n//\t\t Add strategy - Sub-tour strategy\n\t\tStrategySettings subTourModeChoiceStrategy = new StrategySettings();\n\t\tsubTourModeChoiceStrategy\n\t\t\t\t.setStrategyName(DefaultPlanStrategiesModule.DefaultStrategy.SubtourModeChoice.toString());\n\t\tsubTourModeChoiceStrategy.setWeight(0.1);\n\t\tconfig.strategy().addStrategySettings(subTourModeChoiceStrategy);\n\n\t\t// add car Availability after adding attributes to popualtion\n\t\t config.subtourModeChoice().setConsiderCarAvailability(true);\n\n\t\t// add network modes which are simulated on network in future add more modes\n\t\t// config.plansCalcRoute().setNetworkModes(Arrays.asList(TransportMode.car));\n\t\t// config.plansCalcRoute().setInsertingAccessEgressWalk(true);\n\n\t\t// // just a place hodler\n\t\t// ModeRoutingParams taxiModeRoute = new ModeRoutingParams();\n\t\t// taxiModeRoute.setMode(TransportMode.taxi);\n\t\t// taxiModeRoute.setTeleportedModeSpeed(100.0);\n\t\t// config.plansCalcRoute().addModeRoutingParams(taxiModeRoute);\n\n\t\t// global scoring values taken from TLVM model = SF 14\n\t\tconfig.planCalcScore().setEarlyDeparture_utils_hr(0.0);\n\t\tconfig.planCalcScore().setLateArrival_utils_hr(0);\n\t\tconfig.planCalcScore().setMarginalUtilityOfMoney(0.062);\n\t\tconfig.planCalcScore().setPerforming_utils_hr(0.96);\n\t\tconfig.planCalcScore().setUtilityOfLineSwitch(0);\n\t\tconfig.planCalcScore().setMarginalUtlOfWaitingPt_utils_hr(-0.18);\n\n\t\t// car scoring functions from TLVM model = SF 14\n\t\tPlanCalcScoreConfigGroup.ModeParams carCalcScoreParams = new PlanCalcScoreConfigGroup.ModeParams(\n\t\t\t\tTransportMode.car);\n\t\tcarCalcScoreParams.setConstant(-0.562);\n\t\tcarCalcScoreParams.setMode(\"car\");\n\t\tcarCalcScoreParams.setMonetaryDistanceRate(-0.0004);\n\t\tconfig.planCalcScore().addModeParams(carCalcScoreParams);\n\n\t\t// PT scoring functions from TLVM model = SF 14\n\t\tPlanCalcScoreConfigGroup.ModeParams ptCalcScoreParams = new PlanCalcScoreConfigGroup.ModeParams(\n\t\t\t\tTransportMode.pt);\n\t\tptCalcScoreParams.setConstant(-0.124);\n\t\tptCalcScoreParams.setMode(\"pt\");\n\t\tptCalcScoreParams.setMarginalUtilityOfTraveling(-0.18);\n\t\tconfig.planCalcScore().addModeParams(ptCalcScoreParams);\n\n\t\t// Walk scoring functions from TLVM model = SF 14\n\t\tPlanCalcScoreConfigGroup.ModeParams walkCalcScoreParams = new PlanCalcScoreConfigGroup.ModeParams(\n\t\t\t\tTransportMode.walk);\n\t\twalkCalcScoreParams.setMode(\"walk\");\n\t\twalkCalcScoreParams.setMarginalUtilityOfTraveling(-1.14);\n\t\tconfig.planCalcScore().addModeParams(walkCalcScoreParams);\n\n\t\t// TODO get values for Taxi scoring\n\t\t// Taxi scoring functions place holder (taken from car)\n\t\t// PlanCalcScoreConfigGroup.ModeParams TaxiCalcScoreParams = new\n\t\t// PlanCalcScoreConfigGroup.ModeParams(TransportMode.taxi);\n\t\t// TaxiCalcScoreParams.setConstant(-0.562);\n\t\t// TaxiCalcScoreParams.setMode(\"taxi\");\n\t\t// TaxiCalcScoreParams.setMonetaryDistanceRate(-0.0004);\n\t\t// config.planCalcScore().addModeParams(walkCalcScoreParams);\n\n\t\t// TODO add ride as network mode remove from modechoice\n\t\t// Ride scoring functions place holder taken from Berlin MATSim model -\n\t\t// monetaryDistanceRate same as car -0.0004\n\t\tPlanCalcScoreConfigGroup.ModeParams rideCalcScoreParams = new PlanCalcScoreConfigGroup.ModeParams(\n\t\t\t\tTransportMode.ride);\n\t\trideCalcScoreParams.setMode(\"ride\");\n\t\trideCalcScoreParams.setMonetaryDistanceRate(-0.0004);\n\t\tconfig.planCalcScore().addModeParams(rideCalcScoreParams);\n\n\t\t// TODO check with JLM bike - bicyle\n\t\t// bike scoring functions place holder taken from Berlin MATSim model of bicyke\n\t\tPlanCalcScoreConfigGroup.ModeParams bikeCalcScoreParams = new PlanCalcScoreConfigGroup.ModeParams(\n\t\t\t\tTransportMode.bike);\n\t\tbikeCalcScoreParams.setConstant(-1.9);\n\t\tbikeCalcScoreParams.setMode(\"bike\");\n\t\tconfig.planCalcScore().addModeParams(bikeCalcScoreParams);\n\n\t\t// TODO get activities open hours\n\t\tActivityParams home = new ActivityParams(\"home\");\n\t\thome.setTypicalDuration(16 * 60 * 60);\n\t\tconfig.planCalcScore().addActivityParams(home);\n\n\t\tActivityParams work = new ActivityParams(\"work\");\n\t\twork.setOpeningTime(6 * 3600);\n\t\twork.setClosingTime(20 * 3600);\n\t\twork.setTypicalDuration(8 * 60 * 60);\n\t\tconfig.planCalcScore().addActivityParams(work);\n\n\t\tActivityParams school = new ActivityParams(\"school\");\n\t\tschool.setOpeningTime(8 * 3600);\n\t\tschool.setClosingTime(14 * 3600);\n\t\tschool.setTypicalDuration(8 * 60 * 60);\n\t\tconfig.planCalcScore().addActivityParams(school);\n\n\t\tActivityParams leisure = new ActivityParams(\"leisure\");\n\t\tleisure.setOpeningTime(9 * 3600);\n\t\tleisure.setClosingTime(24 * 3600);\n\t\tleisure.setTypicalDuration(8 * 60 * 60);\n\t\tconfig.planCalcScore().addActivityParams(leisure);\n\n\t\tActivityParams other = new ActivityParams(\"other\");\n\t\tother.setTypicalDuration(8 * 60 * 60);\n\t\tconfig.planCalcScore().addActivityParams(other);\n\n\t\treturn config;\n\n\t}", "@Override\n\t\tpublic Track build() {\n\t\t\treturn of(\n\t\t\t\t_name,\n\t\t\t\t_comment,\n\t\t\t\t_description,\n\t\t\t\t_source,\n\t\t\t\t_links,\n\t\t\t\t_number,\n\t\t\t\t_type,\n\t\t\t\t_extensions,\n\t\t\t\t_segments\n\t\t\t);\n\t\t}", "static Http1ClientConfig.Builder builder() {\n return Http1ClientConfig.builder();\n }", "private static SessionFactory buildSessionFactory() {\n\t\t// Creating Configuration Instance & Passing Hibernate Configuration File\n\t\tConfiguration configObj = new Configuration();\n\t\tconfigObj.configure(\"hibernate.cfg.xml\");\n\n\t\t// Since Hibernate Version 4.x, ServiceRegistry Is Being Used\n\t\tServiceRegistry serviceRegistryObj = new StandardServiceRegistryBuilder()\n\t\t\t\t.applySettings(configObj.getProperties()).build();\n\n\t\t// Creating Hibernate SessionFactory Instance\n\t\tsessionFactoryObj = configObj.buildSessionFactory(serviceRegistryObj);\n\t\treturn sessionFactoryObj;\n\t}", "public DimensionType build() {\n return new DimensionType(fixedTime, hasSkylight, hasCeiling, ultraWarm, natural, coordinateScale, bedWorks,\n respawnAnchorWorks, minY, height, logicalHeight, infiniburn, effectsLocation, ambientLight,\n new DimensionType.MonsterSettings(piglinSafe, hasRaids, UniformInt.of(0, 7), 0));\n }", "public de.uni_koblenz.jgralabtest.schemas.gretl.pddsl.Configuration createConfiguration();", "public Configuration c() {\n return configuration;\n }", "public ConfigProfile buildProfileDefault() {\n this.topics = \"mytopic\";\n this.token = \"mytoken\";\n this.uri = \"https://dummy:8088\";\n this.raw = false;\n this.ack = true;\n this.indexes = \"\";\n this.sourcetypes = \"\";\n this.sources = \"\";\n this.httpKeepAlive = true;\n this.validateCertificates = true;\n this.hasTrustStorePath = true;\n this.trustStorePath = \"./src/test/resources/keystoretest.jks\";\n this.trustStoreType = \"JKS\";\n this.trustStorePassword = \"Notchangeme\";\n this.eventBatchTimeout = 1;\n this.ackPollInterval = 1;\n this.ackPollThreads = 1;\n this.maxHttpConnPerChannel = 1;\n this.totalHecChannels = 1;\n this.socketTimeout = 1;\n this.enrichements = \"ni=hao,hello=world\";\n this.enrichementMap = new HashMap<>();\n this.trackData = true;\n this.maxBatchSize = 1;\n this.numOfThreads = 1;\n this.lineBreaker = \"\\n\";\n return this;\n }", "@java.lang.Override\n public com.google.protobuf.AnyOrBuilder getConfigurationOrBuilder() {\n return getConfiguration();\n }", "public OlcDistProcConfig()\n {\n super();\n }", "public WuicFacadeBuilder() {\n contextPath = \"\";\n warmUpStrategy = WuicFacade.WarmupStrategy.NONE;\n multipleConfigInTagSupport = Boolean.TRUE;\n wuicXmlPath = getClass().getResource(\"/wuic.xml\");\n useDefaultContextBuilderConfigurator = Boolean.TRUE;\n objectBuilderInspector = null;\n configurators = new ArrayList<ContextBuilderConfigurator>();\n }", "private static SessionFactory buildSessionFactory() {\n\n try {\n Configuration configuration = new Configuration();\n\n Properties properties = new Properties();\n properties.load(AuthDao.class.getResourceAsStream(\"/db.properties\"));\n configuration.setProperties(properties);\n\n// configuration.addAnnotatedClass(Driver.class);\n// configuration.addAnnotatedClass(DriverStatusChange.class);\n// configuration.addAnnotatedClass(Freight.class);\n// configuration.addAnnotatedClass(Location.class);\n configuration.addAnnotatedClass(Manager.class);\n// configuration.addAnnotatedClass(Order.class);\n// configuration.addAnnotatedClass(OrderDriver.class);\n// configuration.addAnnotatedClass(OrderWaypoint.class);\n// configuration.addAnnotatedClass(Truck.class);\n// configuration.addAnnotatedClass(Waypoint.class);\n\n ServiceRegistry serviceRegistry =\n new StandardServiceRegistryBuilder().applySettings(configuration.getProperties()).build();\n\n return configuration.buildSessionFactory(serviceRegistry);\n\n } catch (IOException e) {\n e.printStackTrace();\n throw new ExceptionInInitializerError(e);\n }\n }", "public PackageBuilderConfiguration(Properties properties) {\r\n init( null,\r\n properties );\r\n }", "public static StateConductorDriverConfig newConfig(Map<String, String>... properties) {\n Map<String, String> props = getMergedProperties(properties);\n logger.debug(\"Configuration Properties: {}\", props);\n // build the configuration\n StateConductorDriverConfig config = new StateConductorDriverConfig();\n config.host = getPropertyValue(props, \"mlHost\", \"localhost\");\n config.port = Integer.parseInt(getPropertyValue(props, \"mlPort\", \"8000\"));\n config.username = getPropertyValue(props, \"username\", null);\n config.password = getPropertyValue(props, \"password\", null);\n config.jobsDatabase = getPropertyValue(props, \"jobsDatabase\", \"state-conductor-jobs\");\n config.securityContextType = SecurityContextType.valueOf(getPropertyValue(props, \"securityContextType\", \"basic\").toUpperCase());\n config.simpleSsl = Boolean.parseBoolean(getPropertyValue(props, \"simpleSsl\", \"false\"));\n config.externalName = getPropertyValue(props, \"externalName\", null);\n config.certFile = getPropertyValue(props, \"certFile\", null);\n config.certPassword = getPropertyValue(props, \"certPassword\", null);\n config.connectionType = DatabaseClient.ConnectionType.valueOf(getPropertyValue(props, \"connectionType\", \"direct\").toUpperCase());\n config.threadCount = Integer.parseInt(getPropertyValue(props, \"threadCount\", \"10\"));\n config.pollSize = Integer.parseInt(getPropertyValue(props, \"pollSize\", \"1000\"));\n config.batchSize = Integer.parseInt(getPropertyValue(props, \"batchSize\", \"5\"));\n config.queueThreshold = Integer.parseInt(getPropertyValue(props, \"queueThreshold\", \"20000\"));\n config.cooldownMillis = Long.parseLong(getPropertyValue(props, \"cooldownMillis\", \"5000\"));\n config.pollInterval = Long.parseLong(getPropertyValue(props, \"pollInterval\", \"1000\"));\n config.metricsInterval = Long.parseLong(getPropertyValue(props, \"metricsInterval\", \"5000\"));\n config.flowNames = getPropertyValue(props, \"flowNames\", null);\n config.flowStatus = getPropertyValue(props, \"flowStatus\", null);\n return config;\n }", "private CalibrationConfig(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {\n super(builder);\n }", "public interface ApplicationRuntimeConfigurationBuilder\n{\n Repository createRepositoryFromModel( Configuration configuration, CRepository repoConf )\n throws ConfigurationException;\n\n void releaseRepository( Repository repository, Configuration configuration, CRepository repoConf )\n throws ConfigurationException;\n}", "private ConfigurationModel() {\r\n\tloadConfiguration();\r\n }", "public OServerConfiguration() {}", "public Configuration.Builder getClientIdAndClientSecretBuilder() {\n String clientId = \"0993a005480472a69fab10c2f9b8ad0d6bee7acf\";//getString(R.string.client_id);\n String clientSecret=\"oVsWjoQ2RHeHvZ8xK3yrtdHrG7YiN+rnHh4qqBfmscDbCwplTFzytAoVIVrXMnAQShuBYuA6fZftYL+AIvX5zRP8JXOs06dQcej1yeL/ACJSGuiKoQJbqdC6CELuP+Pl\";\n\n String codeGrantRedirectUri = \"deva://robokart\";\n Configuration.Builder configBuilder =\n new Configuration.Builder(clientId, clientSecret, SCOPE, null,\n null);\n configBuilder.setCacheDirectory(this.getCacheDir())\n .setUserAgentString(getUserAgentString(this))\n // Used for oauth flow\n .setCodeGrantRedirectUri(codeGrantRedirectUri);\n\n return configBuilder;\n }" ]
[ "0.80689305", "0.7462919", "0.7160691", "0.69269645", "0.6882138", "0.6745451", "0.6600019", "0.65059114", "0.6503747", "0.64568484", "0.63536197", "0.6159232", "0.60232186", "0.6015281", "0.6005278", "0.60028684", "0.5978227", "0.59725916", "0.595056", "0.5934544", "0.58881944", "0.58570075", "0.58570075", "0.58570075", "0.58570075", "0.5844954", "0.58444005", "0.5764336", "0.5757846", "0.57503325", "0.5728086", "0.56958294", "0.5683105", "0.5675952", "0.56712615", "0.5648416", "0.56358844", "0.5603443", "0.5601778", "0.5600457", "0.55973923", "0.5593636", "0.5590848", "0.55758363", "0.5571855", "0.5565089", "0.5550178", "0.55264425", "0.5506345", "0.5498503", "0.5497187", "0.54761666", "0.54590577", "0.54586774", "0.54522204", "0.54507595", "0.5439841", "0.543165", "0.543053", "0.54281044", "0.5421932", "0.5410661", "0.53986764", "0.5398517", "0.53935844", "0.5384049", "0.538151", "0.5380127", "0.5377421", "0.53756106", "0.53746235", "0.53639454", "0.5363244", "0.5354918", "0.5354685", "0.5354547", "0.53540033", "0.5350358", "0.5348607", "0.53385055", "0.5336138", "0.533462", "0.53279567", "0.53247994", "0.53221375", "0.5310258", "0.5305263", "0.5303071", "0.52884954", "0.5283395", "0.52824503", "0.5281257", "0.52770203", "0.5274181", "0.5273763", "0.5269861", "0.526459", "0.52629626", "0.5257594", "0.5250304" ]
0.5973001
17
Created by echowang on 16/5/6.
public interface IPurchaseView { Context getContext(); void showLoading(String msg); void dismissLoading(); Purchase getPurchase(); void closeActivity(); void showToast(String msg); int getCoins(); void setCoins(int coins); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "private stendhal() {\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\n\tpublic void anular() {\n\n\t}", "private static void cajas() {\n\t\t\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "public void gored() {\n\t\t\n\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\n public void init() {\n\n }", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "public final void mo51373a() {\n }", "private void poetries() {\n\n\t}", "@Override\n protected void initialize() {\n\n \n }", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "public void mo38117a() {\n }", "@Override\n\tprotected void getExras() {\n\n\t}", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "private void kk12() {\n\n\t}", "public void mo4359a() {\n }", "@Override\n\tpublic void jugar() {\n\t\t\n\t}", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n public void init() {\n }", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "private void strin() {\n\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "private void init() {\n\n\t}", "@Override\n void init() {\n }", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "private void m50366E() {\n }", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "@Override\n public void init() {\n\n }", "@Override\n public void init() {\n\n }", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "private Rekenhulp()\n\t{\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n protected void initialize() \n {\n \n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n\tpublic void one() {\n\t\t\n\t}", "@Override\n\tpublic void einkaufen() {\n\t}", "protected boolean func_70814_o() { return true; }", "@Override\n public void init() {}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\n protected void init() {\n }", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\r\n\tpublic void init() {}", "@Override\n\tpublic void debite() {\n\t\t\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "@Override\n\tpublic void init()\n\t{\n\n\t}", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n\tpublic void init() {\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "@Override\n public void initialize() { \n }", "public void mo6081a() {\n }", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "private void init() {\n\n\n\n }", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n public void memoria() {\n \n }", "@Override\r\n\tprotected void doF4() {\n\t\t\r\n\t}", "@Override\n protected void getExras() {\n }", "public void mo12628c() {\n }", "@Override\n\tprotected void initialize() {\n\t}", "@Override\n\tprotected void initialize() {\n\t}", "public void mo55254a() {\n }", "public void mo21877s() {\n }", "@Override\n\tpublic int mettreAJour() {\n\t\treturn 0;\n\t}" ]
[ "0.6220098", "0.61390287", "0.6018169", "0.59942853", "0.5900681", "0.5900681", "0.5856164", "0.57907104", "0.57872826", "0.57786816", "0.57771415", "0.5775106", "0.5773784", "0.5764981", "0.576422", "0.57588637", "0.5734495", "0.5725019", "0.5718383", "0.57149416", "0.57149416", "0.57149416", "0.57149416", "0.57149416", "0.5704816", "0.56990796", "0.56950885", "0.5688214", "0.5687476", "0.5675807", "0.5656877", "0.56478655", "0.5634797", "0.5634472", "0.56334484", "0.56297666", "0.56288517", "0.5618943", "0.5613516", "0.5613516", "0.56111413", "0.56111413", "0.56100476", "0.56068", "0.5603317", "0.5588496", "0.55820864", "0.5579692", "0.5579692", "0.5569811", "0.5569811", "0.5569811", "0.55678916", "0.5565905", "0.5565905", "0.5565905", "0.5564136", "0.5549893", "0.5549893", "0.5549893", "0.5549893", "0.5549893", "0.5549893", "0.55453205", "0.5545153", "0.5536661", "0.55339366", "0.5523645", "0.55174536", "0.55174536", "0.55174536", "0.5516944", "0.55140984", "0.54956084", "0.54836047", "0.54824203", "0.54824203", "0.54824203", "0.54824203", "0.54824203", "0.54824203", "0.54824203", "0.54823405", "0.5478924", "0.5475898", "0.5467109", "0.54606605", "0.5454206", "0.54422545", "0.5431377", "0.54306775", "0.5429399", "0.54154533", "0.54094124", "0.54040545", "0.53857976", "0.5382093", "0.5382093", "0.53820926", "0.5379668", "0.5372957" ]
0.0
-1
/ Creating a String "I liked Java, did you like it" 1)Split by Using "d" 2)Split by Using " " Print the arrays on the console
public static void main(String[] args) { String str= "I liked Java, did you like it"; String arr[]=str.split("d"); System.out.println(Arrays.toString(arr)); String str1[]=str.split(" "); System.out.println(Arrays.toString(str1)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static void main(String[] D_Stark) {String[] y ={\n\n\"\",\"\",\"​​​​​​\",\"​\",\"​​​​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​\",\"​​​​​​​​​​​\",\"\",\n\"​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​​\",\"​​​​​​​​​​​\",\n\"​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​​\",\"​​​​​​​​​​​\",\"​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​\",\"​​​​​​​​​​​\",\"\",\n\"​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​\",\"​​​​​​​​​​​\",\n\"\",\"\",\"​​​​​​​​\",\"​​​​​\",\"​​​​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​\",\"​​​​​​​​​​​\",\"\",\n\"\",\"\",\"\",\"\",\"​​​​​​\",\n\"​​​​\",\"​​​​​​\",\"​​​​​​​​​​​\",\"\",\"\",\n\"\",\"​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​​​​\",\"​​​​​​\",\"​​​​​​​​​​​\",\"\",\"​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​\",\"​​​​​​\",\"​​​​​​​​​​​\",\n\"​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​\",\"​​​​​​​​​​​\",\"​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​\",\"​​​​​​​​​​​\",\"\",\n\"​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​\",\n\"​​​​​​​​​​​\",\"\",\"\",\"​​​​​​​​\",\"​​​​​​\",\n\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​​​​​​​​​\",\"​\",\n\"​​​​​​​​\",\"​​​​​​​​​​​\",\"\",\"\",\"\",\n\"\",\"\",\"​​​​​​\",\"​\",\"​​​​​​​​\",\n\"​​​​​​​​​​​\"};\n\nfor( int i =0;i<2;++i){\n\nfor(String h:y){c(h);}}}", "public static void main(String[] args) {\n String words = \"coding:java:selenium:python\";\n String[] splitWords = words.split(\":\");\n System.out.println(Arrays.toString(splitWords));\n System.out.println(\"Length of Array - \" +splitWords.length);\n\n for (String each:splitWords) {\n System.out.println(each);\n\n }\n // How many words in your sentence\n // Most popular interview questions\n // 0 1 2 3 4 5\n String sentence = \"Productive study is makes you motivated\";\n String[] wordsInSentence = sentence.split(\" \");\n System.out.println(\"First words: \" +wordsInSentence[0]);\n System.out.println(\"First words: \" +sentence.split(\" \")[5]);\n System.out.println(\"Number of words in sentence: \" + wordsInSentence.length);\n\n // print all words in separate line\n for (String each:wordsInSentence) {\n System.out.println(each);\n }\n\n\n\n }", "public static void main(String[] args) {\n\n char[] animal = {'k', 'u', 't', 'y', 'a'};\n Arrays.stream(new String(animal).split(\" \")).forEach(System.out::print);\n\n }", "public static void main(String args[]) {\n\n // aacd(1,1,3,4) amd(1,13,4) kcd(11,3,4)\n // Note : 1,1,34 is not valid as we don't have values corresponding\n // to 34 in alphabet\n int[] arr = {1, 1, 3, 4};\n printAllInterpretations(arr);\n\n // aaa(1,1,1) ak(1,11) ka(11,1)\n int[] arr2 = {1, 1, 1};\n printAllInterpretations(arr2);\n\n // bf(2,6) z(26)\n int[] arr3 = {2, 6};\n printAllInterpretations(arr3);\n\n // ab(1,2), l(12)\n int[] arr4 = {1, 2};\n printAllInterpretations(arr4);\n\n // a(1,0} j(10)\n int[] arr5 = {1, 0};\n printAllInterpretations(arr5);\n\n // \"\" empty string output as array is empty\n int[] arr6 = {};\n printAllInterpretations(arr6);\n\n // abba abu ava lba lu\n int[] arr7 = {1, 2, 2, 1};\n printAllInterpretations(arr7);\n }", "public static void main(String[] args) {\n\n\t\tint[]nums=new int[4];\n\t\t\n\t\tnums[0]=12;\n\t\tnums[1]=13;\n\t\tnums[2]=14;\n\t\tnums[3]=15;\n\t\t//to find # of elements we use .length\n\t\tSystem.out.println(nums.length);\n\t\t\n\t\t// 0 1 2 3\n\t\tString[] array= {\"Winter\",\"Fall\",\"Summer\",\"Spring\"};\n\t\t//Print i was born in Summer\n\t\tSystem.out.println(\"I was born in \"+ array[2]);\n\t\t//array.lenght will return an integer\n\t\tint arraySize=array.length;\n\t\tSystem.out.println(array.length);\n\t\t\n\t\t\n\t\t\n\t\tint[]score= {80,90,70,100,99};\n\t\t\n\t\t\n\t\t//Create an array of chars and store grades into it: A,B,C,D,E,F. \n\t\t//Then print a grade B (use 2 different ways of creating an array).\n\n\t\tchar[] grades= {'A','B','C','D','E','F'};\n\t\tSystem.out.println(grades[0]);\n\t\t\n\t\t\n\t\t\n\n\t\t//Create an array of names and store all names of your group.\n\t\t//Then print your name from that array. (use 2 different ways of creating an array).\n\t\t\n\t\tString[]names= {\"Fabi\",\"Shubha\",\"Gunay\",\"Shugoufa\",\"Emily\",\"Seda\"};\n\t\tSystem.out.println(names[0]);\n\t\t\n\t\t\n\t\t\n\n\t\t//Create an array of words: Java, Saturday, day, coding, is. \n\t\t//Print the following sentence using element of array: “Saturday is Java coding Day”. \n\n\t\tString[]words= {\"Java\",\"Saturday\",\"day\",\"coding\",\"is\"};\n\t\tSystem.out.println(words[1]+words[4]+words[0]+words[3]+words[2]);\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t}", "public static void printArray(String[] array){\n int noOfElement=array.length; // Number of element is the length of this array\n for(int i=0;i<array.length;i++){ // print out the each element in array with \" \"(space) splitting\n System.out.print(array[i]+\" \");}}", "public static void main(String[] args) {\n\n String[] split = \"hjhk***jklj,j\\nkl\".split(quote(\"***\") + \"|,\");\n for (String every : split)\n System.out.println(\"test slpit: \" + every);\n// Pattern p = Pattern.compile(\"\\\\[([^\\\\]]+)\\\\]\");\n// Matcher m = p.matcher(\"[***]\");\n// while(m.find()) {\n// System.out.println(m.group(0));\n// }\n }", "public static void main(String[] args) {\n\t\t\r\n\t\tString text = \"We learn java basics as part of java sessions in java week1\";\r\n\t\tint count =0;\r\n\t\tString[] arraySplit = text.split(\"\");\r\n\t\t//for(int i=0;i<arraySplit.length;i++) \r\n\t\t//{ \r\n\t\t//\tSystem.out.println(arraySplit[i]); \r\n\t\t//\t}\r\n\t\t\r\n\t\t \r\n\r\n\t\tfor(int i=0;i<arraySplit.length;i++) {\r\n\t\t\t\r\n\t\t\tcount=1;\r\n\t\t\t\r\n\t\t\tfor(int j=i+1;j<arraySplit.length;j++)\r\n\t\t\t{\r\n\t\t\t\tif(arraySplit[i].equals(arraySplit[j])) {\r\n\t\t\t\t\tcount++;\r\n\t\t\t\t\t//arraySplit[j] = \"o\";\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif(count>1)\r\n\t\t\t{\r\n\t\t\t\tarraySplit[i] = arraySplit[i].replace(arraySplit[i],\"\");\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\t/*\r\n\t\t\t * else { System.out.println(arraySplit[i]); }\r\n\t\t\t */\r\n\t\t\tSystem.out.println(arraySplit[i]);\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t}", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n String str = null;\n System.out.println(\"请输入您想输入的字符串:\");\n str = sc.nextLine();\n int nStr = str.length();\n char[] elevenTwo = new char[nStr];\n elevenTwo = str.toCharArray();\n char[][] array = new char[4][nStr];\n\n array[0][0] = '3';\n for (int i = 1; i < 4; i++){\n for (int j = 0, k = i - 1; j <nStr && k < nStr ; j++, k+=3){\n array[i][j] = elevenTwo[k];\n }\n }\n for (int i = 0; i < 4; i++){\n for (int j = 0; j < nStr; j++){\n System.out.print(array[i][j]);\n }\n System.out.println();\n }\n\n for (int i = 0; i < 4; i++){\n for (int j = 0; j < nStr; j++){\n System.out.print(array[i][j]);\n }\n }\n char[] bStr = new char[nStr];\n int k = 0;\n for (int m = 0; m < nStr; m++){\n for (int n = 1; n < 4 && k < nStr; n++){\n bStr[k++] = array[n][m];\n }\n }\n System.out.println();\n for (int i = 0; i < nStr; i++){\n System.out.print(bStr[i]);\n }\n }", "public static void main(String[] args) {\n\t\tint[] arry1= {10086,10000,10001,12306,12315,12345};//0-5\n\t\tStringBuffer sbf=new StringBuffer();//临时存储区\n\t\tfor(int i:arry1) {\n\t\t\tsbf.append(i+\",\");\n\t\t}\n\t\tSystem.out.println(\"sbf的输出:\"+sbf);//不断追加字符串,注意.appengd()方法和+的区别,生成对象的数目\n\t\t//去掉最后一个逗号,substring 截取方法\n\t\tSystem.out.println(\"截取最后一个逗号:\"+sbf.substring(0, sbf.length()-1));\n\t\tSystem.out.println(\"****************字符串分割后使用数组接收****************\");\n\t\tString[] arry2=sbf.substring(0, sbf.length()-1).split(\",\");\n\t\tfor(String j:arry2) {\n\t\t\tSystem.out.println(j+\"\\b\");\n\t\t}\n\t}", "public void readArray(String s){\r\n\t\tString[] s1=s.split(\"\");\r\n\t\tSystem.out.println(\"reading string array:-\");\r\n\t\tfor(int i=0;i<s1.length;i++){\r\n\t\t\tSystem.out.print(s1[i]);\r\n\t\t}System.out.println();\r\n\t}", "public void splitString() {\n\t\t\tString sentence = \"I am studying\";\n\t\t\tString[] strings = sentence.split(\" \");\n\t\t\tSystem.out.println(\"Length is \" + strings.length);\n\n\n\t\t\tfor (int index = 0; index < strings.length; index++)\n\t\t\t\tSystem.out.println(strings[index]);\n\t\t}", "private void mostrarArrayDNI(String[] arrayDNI) {\r\n System.out.println(\"\\nDNI Introduïts\");\r\n System.out.println(\"--------------\");\r\n for (int x = 0; x < arrayDNI.length; x++) {\r\n System.out.println(arrayDNI[x]);\r\n }\r\n System.out.println(\"\\n\");\r\n }", "public static void main(String[] args) {\n\t\tString[] arrStr = new String[4];\r\n\t\t\r\n\t\tfor(int i = 0;i<arrStr.length;i++) {//string이여야만 가능\r\n\t\t\tarrStr[i] = \"test\"+i;\r\n\t\t}\r\n\t\t\r\n\t\tfor(String str:arrStr) {\r\n\t\tSystem.out.println(str);\r\n\t\t}\r\n\t\t\r\n\t\tString[] arr = {\"보검\",\"정국\",\"은우\"};//방번호와 초기화 동시\r\n\t\tSystem.out.println(arr[1]);\r\n\t\t\r\n\t\tString[][] multiArr = {{\"1\",\"2\",\"3\"},{\"4\"},{\"5\",\"6\",\"7\"}};\r\n\t\tSystem.out.println(multiArr[0][2]);\r\n\t\t\r\n\t\t\tfor(String[] strs: multiArr) {\r\n\t\t\tfor(String str : strs) {\r\n\t\t\t\tSystem.out.println(str);\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\tArrayList<String> strList = new ArrayList<String>();\r\n\t\t\r\n\t\tfor(int i = 0;i<arrStr.length;i++) {\r\n\t\t\tstrList.add( \"test\"+i);\r\n\t\t}\r\n\t\t\r\n\t\tfor(String str:arrStr) {\r\n\t\t\tSystem.out.println(str);\r\n\t\t\t}\r\n\t}", "public static void main(String[] args) {\n\n\t\tScanner my = new Scanner(System.in);\n\t\tString []s = new String[5];\n\t\t\n\t\tSystem.out.println(\"\");\n\t\t \n\t\t String str =\"\";\n\t\t System.out.print(\"\");\n\t\t str = my.nextLine();\n\t\t String d = \"\";\n\t\t for(int i = 0; i<str.length(); i++) {\n\t\t\t if( str.charAt(i) != ' ') \n\t\t\t\t d += str.charAt(i);\n\t\t\t\t\n\t\t }\n\t\t d.toCharArray();\n\t\t for(int i = 0; i<d.length(); i++) {\n\t\t\t if(d.charAt(i) == d.charAt(i+1)) {\n\t\t\t\t d.charAt(i) = '.' ; \n\t\t\t \n\t\t\t }\n\t\t\t \n\t\t }\n\t\t \n\n\t\t \n\t\t}", "public static void main(String[] args) {\n\t\t\n\t\t\n\t\tchar arr1[] = new char[4];\n\t\t\n\t\tarr1[0]= 'A';\n\t\tarr1[1]= 'D';\n\t\tarr1[2]='E';\n\t\tarr1[3]= 'M';\n\t\t\n\t\tfor(int i=0; i<4; i++) {\n\t\t\tSystem.out.println(arr1[i]);\n\t\t}\n\t\t\n\t\tSystem.out.println(arr1[3]);\n\t\t\n\t\t// Arrayin lenghti bulmak icin arrayin ismi arr1.lenght yazmak yeterlidir\n\t\t// stringlerde de lenhgt metodu kullanilir ama stringlerde kulanilan lenght methodu parantezlidir . yani stringlerde \n\t\t//==> lenght() Arraylarde ==> lenght var \n\t\tSystem.out.println(arr1.length);//4\n\t\t\n\t\t\n\t\t\n\t\t// Arraydeki son elemani bulmak icin lenght kullaniniz\n\t\tSystem.out.println(arr1[arr1.length-1]);//M\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\n\t}", "public static void main(String[] args) {\n\n\t\tScanner sc = new Scanner(System.in);\n\t\tString a = sc.nextLine();\n\t\tString[] b = a.split(\" \");\n\t\tint max = 0;\n\t\tfor (int i = 0; i < b.length; i++) {\n\t\t\tint j = 0;\n\t\t\tfor (j = 0; j < b[i].length(); j++) {\n\t\t\t}\n\t\t\tif (j > max)\n\t\t\t\tmax = j;\n\t\t}\n\t\tfor (int i = 0; i < b.length + 2; i++) {\n\t\t\tfor (int k = 0; k < max + 2; k++) {\n\t\t\t\tif (i == 0 || i == b.length + 1 || k == 0 || k == max + 1) {\n\t\t\t\t\tSystem.out.print(\"*\");\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\tif (k > b[i - 1].length()) {\n\t\t\t\t\tSystem.out.print(\" \");\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\tSystem.out.print(b[i - 1].charAt(k - 1));\n\t\t\t\t}\n\n\t\t\t}\n\t\t\tSystem.out.println();\n\n\t\t}\n\t\tsc.close();\n\n\t}", "public static void main(String[] args) {\n\t\tint i[] = new int[10];\n\t\t//i[-1]=45;\n\t\ti[0]=10;\n\t\ti[1]=20;\n\t\ti[2]=30;\n\t\ti[3]=40;\n\t\ti[6]=80;\n\t\tSystem.out.println(\"+++++++++++++++++++++++++++++++++\");\n\t\tSystem.out.println(i[6]);\n\t\tSystem.out.println(\"+++++++++++++++++++++++++++++++++\");\n//\t\tSystem.out.println(i[0]);//10\n//\t\tSystem.out.println(i[4]);//ArrayIndexOutOfBoundsException\n//\t\tSystem.out.println(i[-1]);//ArrayIndexOutOfBoundsException\n\t\t\n for(int k=0;k<i.length;k++) {\n \t System.out.println(i[k]);\n }\n\t//2.double array\n double d[]= new double[2];\n d[0]=12.33;\n d[1]=13.55;\n \n \n //3.char array\n char c[]= new char[3];\n c[0]='s';\n c[1]='o';\n c[2]='w';\n \n //4.String array\n String names[]=new String[3];\n names[0]=\"divaya\";\n names[1]=\"ravi\";\n names[2]= \"kavitha\";\n \n System.out.println(names[0]);\n for(int f=0;f<names.length; f++) {\n \t System.out.println(names[f]);\n }\n System.out.println(\"======================\");\n //for each loop\n for(String e : names) {\n \t System.out.println(e);\n \t \n }\n \n \n\t}", "public static void main(String[] args) {\n\t\tScanner console = new Scanner(System.in);\n\t\tSystem.out.print(\"Enter a sentence: \");\n\t\tsentence = console.nextLine();\n\n\t\tSystem.out.println(getBlankPositions());\n\t\tSystem.out.println(countWords());\n\t\tString[] wordArr = getWords();\n\n\t\t// print wordArr in the proper format\n\t\tSystem.out.print(\"{\");\n\t\tfor (int i =0 ; i < wordArr.length; i++) {\n\t\t\tSystem.out.print(wordArr[i]);\n\t\t\tif (i < wordArr.length - 1)\tSystem.out.print(\",\");\n\t\t}\n\t\tSystem.out.println(\"}\");\n\t}", "public static void main(String[] args) {\n\t\tString[][] strArray1 = new String [][] { {\"H\", \"e\", \"l\", \"l\", \"o\"}, {\"W\", \"o\", \"r\", \"l\", \"d\"} };\r\n\t\tString printString = \"\";\r\n\t\t\r\n\t\tString[][] strArray2 = new String[][] { {\"H\", \"W\"}, {\"e\", \"o\"}, {\"l\", \"r\"}, {\"l\", \"l\"}, {\"o\", \"d\"} };\r\n\t\tString printString2 = \"\";\r\n\t\t\r\n\t\tString[][] strArray3 = new String[][] { {\"o\", \"l\", \"l\", \"e\", \"H\"}, {\"d\", \"l\", \"r\", \"o\", \"W\"} };\r\n\t\tString printString3 = \"\";\r\n\t\t\r\n\t\tString[][] strArray4 = new String[][] { {\"W\", \"H\"}, {\"o\", \"e\"}, {\"r\", \"l\"}, {\"l\", \"l\"}, {\"d\", \"o\"} };\r\n\t\tString printString4 = \"\";\r\n\t\t\r\n\t\t\r\n\t\t//printString = arrManip1(strArray1);\r\n\t\t//System.out.println(printString);\r\n\t\t\r\n\t\t//printString2 = arrManip2(strArray2);\r\n\t\t//System.out.println(printString2);\r\n\t\t\r\n\t\t//printString3 = arrManip3(strArray3);\r\n\t\t//System.out.println(printString3);\r\n\t\t\r\n\t\tprintString4 = arrManip4(strArray4);\r\n\t\tSystem.out.println(printString4);\r\n\t\t\r\n\t}", "public static void main(String[] args) {\nString str=\"This is Batch \";\nString Arr[]=str.split(\"i\");\nSystem.out.println(Arr.length);\nSystem.out.println(Arr[0]);\nSystem.out.println(Arr[1]);\nSystem.out.println(Arr[2]);\n\t}", "public static void main(String[] args) {\n\t\tString str = \"Lets go fishing!\";\n\t\tString str1 = str.replaceAll(\"[ ]\", \"\");\n\t\tSystem.out.println(str1);\n\n\t\tString str2 = \"HVDV 786bh f73%7jf hj^&^hdjhd%\";\n\t\tString str3 = str2.replaceAll(\"[a-z A-Z0-9]\", \"\");\n\t\tSystem.out.println(str3 + \" \" + str3.length());\n\n\t\tString a = \"Is it saturday! Is it raining! Do we have a Java Class today?\";\n\n\t\tString[] b = a.split(\"[!]\");\n\t\tfor(String c:b) {\n\t\t\tSystem.out.println(c);\n\t\t}\n\t\tSystem.out.println(\" b length is \" + b.length+\" sentences\");\n\t}", "public static void main(String[] args) {\n\t\t\n\t\tString str = \"Sunday Perfect Day to start coding\";\n\t\t\n\t\tString [] reverseStr = str.split(\" \");\n\t\t\n\t\t//1ST WAY\n\t\tSystem.out.println(Arrays.toString(reverseStr));\n\t\tString store [] = new String[reverseStr.length];\n\t\tfor (int i = 0; i < reverseStr.length; i++) {\n\t\t\tstore[i]=reverseStr[reverseStr.length-1-i];\n\t\t}\n\t\tSystem.out.print(Arrays.toString(store));\n\t\t//--------------------------------------\n\t\t//This one would only print words without Array type\n//\t\tfor (int i = 0; i < reverseStr.length; i++) {\n//\t\t\tSystem.out.print(reverseStr[reverseStr.length-1-i] + \" \");\n//\t\t}\n\t\t//--------------------------------------\n\t\tSystem.out.println();\n\t\t\n\t\t\n\t\t//2ND WAY\n\t\tfor (int i = 0; i < reverseStr.length/2; i++) {\n\t\t\tString temp = reverseStr[i];\n\t\t\treverseStr[i]=reverseStr[reverseStr.length-1-i];\n\t\t\treverseStr[reverseStr.length-1-i]=temp;\n\t\t}\n\t\tSystem.out.println(Arrays.toString(reverseStr));\n\t\t\n\t\t//--------------------------------------\n\t\tString str1 = \"Sunday Perfect Day to start coding\";\n\t\t\n\t\tString [] reverseStr1 = str.split(\" \");\n\t\tString store1 = \"\";\n\t\tfor (int i = 0; i < reverseStr1.length; i++) {\n\t\t\tchar []c1 = reverseStr1[i].toCharArray();\n\t\t\tfor (int j = 0; j < c1.length/2; j++) {\n\t\t\t\tchar temp = c1[j];\n\t\t\t\tc1[j]=c1[c1.length-1-j];\n\t\t\t\tc1[c1.length-1-j]=temp;\n\t\t\t\t\n\t\t\t}\n\t\t\tSystem.out.println(Arrays.toString(c1));\n\t\t\tString reverse = new String(c1);\n\t\t\tstore1+=reverse+\" \";\n\t\t}\n\t\t\n\t\tSystem.out.println(store1);\n\t\tString [] splt2 = store1.split(\" \");\n\t\tSystem.out.println(Arrays.toString(splt2));\n\t\t\n\t\t\n\t\t\n\t\t//--------------------------------------\n\t\t//REVERSE\n//\t\tString []fruit = {\"Apple\"};\n//\t\tString fruit2 = \"\";\n//\t\tfor (int i = 1; i <= fruit[0].length(); i++) {\n//\t\t\tfruit2+=\"\"+fruit[0].charAt(fruit[0].length()-i);\n//\t\t\t\n//\t\t}\n//\t\tSystem.out.print(fruit2);\n//\t\tString []fruit3 = {fruit2};\n//\t\t\n//\t\tSystem.out.println();\n//\t\t\n//\t\tSystem.out.println(Arrays.toString(fruit3));\n//\t\t\n\t\t//--------------------------------------\n\t\t\n\n\t\t\n\t\t\n\t}", "public static void main(String[] args) {\n\t\t\r\n\t\tint a [] = {1,0,0,1,1,0,0,1,0,1,0,0,0,1};\r\n\t\t\r\n\t\tboolean start = false;\r\n\t\t//boolean end = false;\r\n\t\tString s = \"\";\r\n\t\tString k = Arrays.toString(a);\r\n\t\tString[] strings = (k.replace(\"[\", \"\").replace(\"]\", \"\").split(\", \"));\r\n\t\tString s1 = (k.replace(\"[\", \"\").replace(\"]\", \"\"));\r\n\t\tString s2 = (s1.replace(\",\", \"\"));\r\n\t\tString s3 = s2.replaceAll(\"\\\\s\", \"\");\r\n\t\t//String stringss = strings.toString();\r\n\t\t//String[] stringss = strings.replaceAll(\"\\\\s\", \"\").split(\"\");\r\n\t\t\r\n\t\tint Startindex = 0;\r\n\t\tint Endindex = 0;\r\n\t\tArrayList<String> ai = new ArrayList<String>();\r\n\t\tfor (int i =0;i<=strings.length-1;i++) {\r\n\t\t\tint result = Integer.parseInt(strings[i]);\r\n\t\t\t\r\n\t\t\tif (result==1 && !start) {\r\n\t\t\t\t\r\n\t\t\t\tstart = true;\r\n\t\t\t\tStartindex = i;\r\n\t\t\t\t\r\n\t\t\t}else if (result==1 && start) {\r\n\t\t\t\tstart = false;\r\n\t\t\t\tEndindex = i;\r\n\t\t\t\ts = s3.substring(Startindex, Endindex+1);\r\n\t\t\t\tai.add(s);\r\n\t\t\t\ti =i-1;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\nSystem.out.println(ai);\r\n\t}", "public void printStringArr(String[] s) {\r\n\t\tfor(int i=0;i<s.length;i++){\r\n\t\t\tSystem.out.print(s[i]+\" \");\r\n\t }System.out.println();\r\n\t}", "public static void main(String[] args) {\n\t\tint[] x = { 10, 20, 30, 40 };\n\t\tSystem.out.println(x);\n\t\tSystem.out.println(x[0]);\n\t\tSystem.out.println(x[1]);\n\t\tSystem.out.println(x[2]);\n\t\tSystem.out.println(x[3]);\n\n\t\t// array declaration.initialization and creation in a single line.(char array)\n\t\tchar[] ch = { 'a', 'e', 'i', 'o', 'u' };\n\t\tSystem.out.println(ch);\n\t\tSystem.out.println(ch.toString());\n\t\tSystem.out.println(ch[0]);\n\t\tSystem.out.println(ch[1]);\n\t\tSystem.out.println(ch[2]);\n\t\tSystem.out.println(ch[3]);\n\t\tSystem.out.println(ch[4]);\n\n\t\t// array declaration.initialization and creation in a single line.(String Array)\n\t\tString[] s = { \"Babu\", \"Rahul\", \"Riju\", \"Buni\", \"Shaan\" };\n\t\tSystem.out.println(s);\n\t\tSystem.out.println(s.length);\n\t\tSystem.out.println(s.toString());\n\t\tSystem.out.println(s[0]);\n\t\tSystem.out.println(s[1]);\n\t\tSystem.out.println(s[2]);\n\t\tSystem.out.println(s[3]);\n\t\tSystem.out.println(s[4]);\n\t\t\n\n\t}", "public static void main(String[] args) {\n\t\t\n\t\tScanner sc = new Scanner(System.in);\n\n\t\tint total = sc.nextInt();\n\t\tString text[] = new String[total]; //total要大於1\n\t\tfor(int i=0;i<total;i++) {\n\t\t\t//每列輸入一組字串\n\t\t\ttext[i] = sc.nextLine();; //輸入到字串中切勿使用nextLine\t\t\n\t\t}\n\n//\t\tSystem.out.println(text.length); //total = 5 輸出5\n\t\t\n\t\t//5列 把text陣列長度找出\n\t\t//幾列 做幾次\n\t\tfor(int i=1;i<text.length;i++)\n\t\t{\n\t\t\t//分割字串 空白字元\n\t\t\tString[] textSplit = text[i].split(\" \"); //空白分隔\n\t\t\tSystem.out.print(\"\\n\");\n\t\t\tfor(int j=0;j<textSplit.length;j++) {\n\n//\t\t\t\tSystem.out.println(\"textSplit\"+textSplit[j]);\n\t\t\t\tswitch(textSplit[j]){\n\t\t\t\t\tcase \".-\":System.out.print(\"A\");break;\n\t\t\t\t\tcase \"-...\":System.out.print(\"B\");break;\n\t\t\t\t\tcase \"-.-.\":System.out.print(\"C\");break;\n\t\t\t\t\tcase \"-..\":System.out.print(\"D\");break;\n\t\t\t\t\tcase \".\":System.out.print(\"E\");break;\n\t\t\t\t\tcase \"..-.\":System.out.print(\"F\");break;\n\t\t\t\t\tcase \"--.\":System.out.print(\"G\");break;\n\t\t\t\t\tcase \"....\":System.out.print(\"H\");break;\n\t\t\t\t\tcase \"..\":System.out.print(\"I\");break;\n\t\t\t\t\tcase \".---\":System.out.print(\"J\");break;\n\t\t\t\t\tcase \"-.-\":System.out.print(\"K\");break;\n\t\t\t\t\tcase \".-..\":System.out.print(\"L\");break;\n\t\t\t\t\tcase \"--\":System.out.print(\"M\");break;\n\t\t\t\t\tcase \"-.\":System.out.print(\"N\");break;\n\t\t\t\t\tcase \"---\":System.out.print(\"O\");break;\n\t\t\t\t\tcase \".--.\":System.out.print(\"P\");break;\n\t\t\t\t\tcase \"--.-\":System.out.print(\"Q\");break;\n\t\t\t\t\tcase \".-.\":System.out.print(\"R\");break;\n\t\t\t\t\tcase \"...\":System.out.print(\"S\");break;\n\t\t\t\t\tcase \"-\":System.out.print(\"T\");break;\n\t\t\t\t\tcase \"..-\":System.out.print(\"U\");break;\n\t\t\t\t\tcase \"...-\":System.out.print(\"V\");break;\n\t\t\t\t\tcase \".--\":System.out.print(\"W\");break;\n\t\t\t\t\tcase \"-..-\":System.out.print(\"X\");break;\n\t\t\t\t\tcase \"-.--\":System.out.print(\"Y\");break;\n\t\t\t\t\tcase \"--..\":System.out.print(\"Z\");break;\n\t\t\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t}", "public static void main(String[] args)\r\n\t{\r\n\t\tString s = \"abc xy prjjj\";\r\n\t\tchar c []= s.toCharArray();\r\n\t\tint count =0;\r\n\t\tfor (int i = 0; i < c.length; i++) \r\n\t\t{\r\n\t\t\tif(c[i]==' ')\r\n\t\t\t{\r\n\t\t\t\tcount++;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\tString s1[]= new String[count+1];\r\n\t\tint si=0;\r\n\t\tint ei=0;\r\n\t\tint co=0;\r\n\t\t\r\n\t\tfor (int i = 0; i < c.length; i++)\r\n\t\t{\r\n\t\t\tif(c[i]==' ' || i==c.length-1)\r\n\t\t\t{\r\n\t\t\t\tei=i-1;\r\n\t\t\t\tif(i==c.length-1)\r\n\t\t\t\t{\r\n\t\t\t\t\tei=i;\r\n\t\t\t\t}\r\n\t\t\t\tint f=0;\r\n\t\t\t\tchar d[]= new char[(ei-si)+1];\r\n\t\t\t\tfor (int j = si; j <=ei; j++)\r\n\t\t\t\t{\r\n\t\t\t\t\td[f++]= c[j];\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t\tString r1= new String(d);\r\n\t\t\t\ts1[co++] = r1;\t\r\n\t\t\t\t\r\n\t\t\t\tsi=i+1;\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t}\r\n\t\tfor (int j = 0; j < s1.length; j++)\r\n\t\t{\r\n\t\t\tSystem.out.println(s1[j]);\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t}", "public static void main(String[] args) {\n\t\t\n\t\tint a[] = new int[4];//[0,0,0,0]\n\t\ta[0]=14;\n\t\ta[1]=12;\n\t\ta[2]=13;\n\t\ta[3]=11;\n\t\tSystem.out.println(Arrays.toString(a));\n\t\t\n\t\t//How to put elements in ascending order\n\t\tArrays.sort(a);\n\t\tSystem.out.println(Arrays.toString(a));\n\t\t\n\t\t//Type a program to add all elements in the array \"a\"\n\t\tint sum =0;\n\t\tfor(int i =0;i<a.length;i++) {\n\t\t\tsum = sum + a[i];\n\t\t\n\t\t}\n\t\tSystem.out.println(\"Sum : \" + sum);\n\t\t// Create a char array which has 6 elements with second way\n\t\t\n\t\tchar b[] = {'a','d','A','b','c','D'};\n\t\tSystem.out.println(Arrays.toString(b));\n\t\tArrays.sort(b);\n\t\tSystem.out.println(Arrays.toString(b));\n\t\t\n\t\t//Type a program to concatenate the elements in the array \"b\"\n String concat = \"\";\n for(int i = 0;i<b.length;i++) {\n \tconcat = concat + b[i];\n }\n System.out.println(\"Concatenated: \" + concat);//Concatenated: ADabcd\n \n String c[] = {\"Ali\", \"John\", \"ALI\", \"Brad\", \"Mary\", \"Angie\"};//These are stored in heap memory, but inside\n //the array only the references of these elements is stored. When you print the elements,\n //Java take the Strings from the heap memory an then print them on the console.\n //So do not forget that arrays cannot store non-primitive things. But can store only the addresses(references) of them.\n System.out.println(Arrays.toString(c));//[Ali, John, ALI, Brad, Mary, Angie]\n \n Arrays.sort(c);\n System.out.println(Arrays.toString(c));//[ALI, Ali, Angie, Brad, John, Mary]\n \n //Print the elements whose indexes are even on the console.\n for(int i =0;i<c.length;i++) {\n \tif(i%2==0) {\n \t\tSystem.out.print(c[i] + \" \");//ALI Angie John (index 0,2,6)\n \t}}\n //How to check if a specific element exists in the array or not\n \t\t\n //To check if an element exists in an array or not we use \"binarySearch()\"\n //Be Careful!!! ==> Before using \"binarySearch()\" method you HAVE TO use sort()\n //If you use \"binarySearch()\" without using sort(), you will get a result but\n //it will not be meaningful\n \t\t\n int d[] = {3,5,2,12,4,3,6};\n //Check if 12 exists in array \"d\"\n \t\tArrays.sort(d);\n \t\tSystem.out.println(Arrays.toString(d));//[2, 3, 3, 4, 5, 6, 12]\n \t\t//binarySearch() returns NON NEGATIVE values if the element exists.\n \t\t//If the element exists you will get the index of the element from binarySearch() method.\n \t\tSystem.out.println(Arrays.binarySearch(d, 12));//6 (6 is the index of the element which after sorted=>12)\n \t\t\n \t\tSystem.out.println(Arrays.binarySearch(d, 9));//-7 \"-\" means it doesn't exists in the array. 7 means if the number(9) \n \t\t//exists, it would be in the 7th order(not index just number) according to the sorted array.\n \t\t//If the element does not exist, you will get NEGATIVE number. Negative sign displays\n \t\t//non-existance, the number displays the order number IF the element exists\n \t\tSystem.out.println(Arrays.binarySearch(d, 15));//-8\n \t\t//binarySearch() method cannot be used for repeated elements, you can get output but \n \t\t//it is not meaningful.\n \t\tSystem.out.println(Arrays.binarySearch(d, 3));\n \t\t\n \t\t\n \t}", "public static void main(String[] args) {\n\t\tString s1=\"abc def ghi\";\n\t\tString s3=\"rupomroy\";\n\t\tString s7 =s3.substring(0, 4);\n\t\tSystem.out.println(s7);\n\t\t\n\t\t String[] s5 =s3.split(\"roy\");\n\t\t System.out.println(s5[0]);\n String s2 = s1.substring(4);\t\n System.out.println(s2);\n\t\t\n\t\t String[] s = s1.split(\" \");\n\t\t System.out.println(s[0]);\n\t\t System.out.println(s[1]);\n\t\t System.out.println(s[2]);\n\t\t\n\t\tSystem.out.println(s1);\n\t\t\n\t\t\n\n\t}", "public static void main(int[] string){\n int[] numbers = new int[]{2, 3, 1, 6, 7};\n\n System.out.println();\n\n }", "public static void main(String[] args) \r\n\t{\n\t\tDate date = new Date();\r\n\t\tSystem.out.println(date);\r\n\t\t\r\n\t\t//Convert date to string\r\n\t\tString stringdate = date.toString();\r\n\t\tSystem.out.println(stringdate);\r\n\t\t\r\n\t\t//Split sting\r\n\t\tString[] datearray = stringdate.split(\" \");\r\n\t\t\r\n\t\t\r\n\t\tSystem.out.println(datearray[0]);\r\n\t\tSystem.out.println(datearray[1]);\r\n\t\tSystem.out.println(datearray[2]);\r\n\t\tSystem.out.println(datearray[3]);\r\n\t\tSystem.out.println(datearray[4]);\r\n\t}", "public static void main(String[] args) {\n\t\tString str1 = \"Humpty Dumpty Sat On The Wall.\";\n\t\tchar array1[] = new char[30];\n\t\t\n\t\tstr1.getChars(0, 30, array1, 0);;\n\t\tSystem.out.println(array1);\n\t\t\n\t\tfor(int i = 29; i >= 0; i--) {\n\t\t\tSystem.out.print(array1[i]);\n\t\t}\n\t}", "public static void main(String[] args) {\n\t\tString[] PrviNiz = {\"Vasa\", \"vana plurimum\", \"sonant\"};\r\n\t\tString[] DrugiNiz = new String[4];\r\n\t\t\r\n\t\tScanner sc = new Scanner(System.in);\r\n\t\t\r\n\t\tfor (int i = 0; i < DrugiNiz.length; i++) {\r\n\r\n\t\t\tSystem.out.println(\"Unesite string za \"+ i +\" element niza: \");\r\n\t\t\tDrugiNiz[i] = sc.nextLine();\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\tSystem.out.println(PrviNiz[0] + \" \" + PrviNiz[1] + \" \" + PrviNiz[2]);\r\n\t\tfor (int i = 0; i < DrugiNiz.length; i++) {\r\n\t\t\t\r\n\t\t\tSystem.out.println(DrugiNiz[i]);\r\n\r\n\t\t}\r\n\t}", "public static void main3(String[] args) {\n String str = \"192*168*1*1\";\n\n //String [] strings = str.split(\"\\\\.\");\n String [] strings = str.split(\"\\\\*\");\n //为什么需要两个斜杠 在本来的情况下 \\ +要转义的字符就可以了\n //但是此时在在\"\"里面不知道\\是干什么的 需要两个斜杠\n for(String s : strings) {\n System.out.println(s);\n }\n }", "public static void Main()\n\t{\n\t char del = char a[15];\n\t int n;\n\t int i;\n\t char[][] s = new char[50][15];\n\t String tempVar = ConsoleInput.scanfRead();\n\t if (tempVar != null)\n\t {\n\t\t n = Integer.parseInt(tempVar);\n\t }\n\t for (i = 0;i < n;i++)\n\t {\n\t String tempVar2 = ConsoleInput.scanfRead();\n\t if (tempVar2 != null)\n\t {\n\t\t s[i] = tempVar2.charAt(0);\n\t }\n\n\t }\n\t for (i = 0;i < n;i++)\n\t {\n\t del(s[i]);\n\t System.out.printf(\"%s\\n\", s[i]);\n\n\t }\n\n\n\n\t}", "public static void main(String[] args) {\n\n Scanner scanner = new Scanner(System.in);\n System.out.print(\"Enter the number of strings: \");\n int count = Integer.parseInt(scanner.nextLine());\n String[] strings = new String[count];\n StringBuilder str = new StringBuilder();\n for (int i = 0; i < strings.length; i++){\n System.out.print(\"String \" + (i+1) + \": \");\n strings[i] = scanner.nextLine();\n }\n System.out.print(\"Enter the delimiter: \");\n String delimiter = scanner.nextLine();\n for (int i = 0; i < strings.length; i++){\n if (i == strings.length-1){\n str.append(strings[i]);\n break;\n }\n str.append(strings[i]).append(delimiter);\n }\n System.out.println(str.toString());\n }", "public static void main(String[] args) {\n\t\t\r\n\t\tString[][] str=new String[2][3];\r\n\t\tstr[0][0]=\"1-one\";\r\n\t\tstr[0][1]=\"2-two\";\r\n\t\tstr[0][2]=\"3-three\";\r\n\t\tstr[1][0]=\"4-four\";\r\n\t\tstr[1][1]=\"5-five\";\r\n\t\tstr[1][2]=\"6-six\";\r\n\t\tSystem.out.println(\"Displaying String values without using loops:\");\r\n\t\tSystem.out.println(str[0][0]+\" \"+str[0][1]+\" \"+str[0][2]);\r\n\t\tSystem.out.println(str[1][0]+\" \"+str[1][1]+\" \"+str[1][2]);\r\n\t\tSystem.out.println(\"Displaying String values without using nested loops:\");\r\n\t\tfor(int i=0;i<2;i++) {\r\n\t\t\tfor(int j=0;j<3;j++) {\r\n\t\t\t\tSystem.out.print(str[i][j]+\" \");\r\n\t\t\t}\r\n\t\t\tSystem.out.println();\r\n\t\t}\r\n\t\t\r\n\t\r\n\r\n\t}", "public static void main(String[] args) {\n\t\tScanner input = new Scanner(System.in);\r\n\t\t\r\n\t\tString a = input.nextLine();//=> untuk mengambil inputan dari user\r\n\t\t\r\n\t\t/*\r\n\t\t *trim() , digunakan untuk menghapus Whitespace sebelum atau sesudah suatu string\r\n\t\t *split, untuk men-split atau membagi string dari suatu karakter tertentu\r\n\t\t *String[]arr => akan menampung hasil dari trim dan split yang telah dilakukan program \r\n\t\t * */\r\n String[]arr = a.trim().split(\"[ !,?._'@]+\");\r\n \r\n /*\r\n * ArrayList<String> berbeda dengan array biasa\r\n * Perbedaannya adalah:\r\n * array biasa apabila kita menghapus/menambah elemen maka tidak akan mengubah ukurannya\r\n * ArrayList , akan berubah ukuran ketika kita menambah atau mengurangi isi dari array\r\n */\r\n ArrayList<String>listOfStrings = new ArrayList<String>(Arrays.asList(arr));\r\n \r\n //untuk mengetahui berapa banyak elemen dari array \r\n System.out.println(listOfStrings.size());\r\n \r\n for(String str:listOfStrings){\r\n System.out.println(str);\r\n }\r\n\r\n\t}", "public static void main(String[] args) {\r\n\r\n\t\tScanner scanner =new Scanner(System.in);\r\n\t\tSystem.out.println(\"enter the string :\");\r\n\t\tString input = scanner.nextLine();\r\n\t\tString output = \" \" ;\r\n\t\t\r\n\t\tString[] split = input.split(\" \");\r\n//\t\tfor (String a : split) {\r\n//\t\t\tSystem.out.println(split.length);\r\n//\t\t\tSystem.out.println(a.toString());\r\n//\r\n//\t\t}\r\n\t\tfor (int a=split.length-1; a>=0; a--) {\r\n\t\t\toutput = output + split[a] ;\r\n\t\t\toutput = output +\" \";\r\n\t\t}\r\n\t\tSystem.out.println(output.toString());\r\n\t\t\r\n\t}", "public static void main(String[] args) {\n\t\t\n\t\tint[] arr1D = {1,2,3};\n\t\t\n\t//\t2 dimensional array: array that contains multiple 1 dimensional arrays\n\t\t\n\t\tint[][] arr2D = { {1,2,3} , {4,5,6} };\n\t\t\n\t\t\n\t\tString[] arr = {\"A\" ,\"B\"};\n\t\t\n\t\t//\t\t\t\t\t\t 0 1 0 1 2\n\t\tString[][] str2D = { {\"A\" ,\"B\"} , {\"C\" ,\"D\",\"E\"} };\n\t\t//\t\t\t\t\t\t\t 0 1\n\t\t\n// [represents the index number of 1 dimensional arrays ][ represents the index number of the values]\n\t\t\n\t\t\t\t// print A:\n\t\t\t\tSystem.out.println( str2D[0][0] );\n\t\t\t\t\n\t\t\t\t// print D:\n\t\t\t\tSystem.out.println( str2D[1][1] );\n\t\t\t\t\n\t\t\t\t//print E:\n\t\t\t\tSystem.out.println(str2D[1][2]);\n\t\t\n\t\t\t\t// print [A ,B]:\n\t\t\t\tSystem.out.println( str2D[0] );\n\t\t\t\tSystem.out.println( Arrays.toString( str2D[0] ) );\n\t\t\t\t\n\t\t\t\t// print [C, D, E]:\n\t\t\t\tSystem.out.println( str2D[1] );\n\t\t\t\tSystem.out.println( Arrays.toString( str2D[1] ));\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t//print [[A,B], [C, D, E]]\n\t\t\t\tSystem.out.println( Arrays.toString(str2D) );\n\t\t\t\tSystem.out.println( Arrays.deepToString( str2D ) );\n\t\n\t\t\t// Arrays.deepToString(variableName ): converts multi-Dimensional Arrays to STring value\n\t\t\t\n\t\t\t\t\n\t\t\t// \t 0 1 0 1 0 1 \n\t\t\tint[][] Numbers2D = {\t{1,2} , {3, 4} , {5, 6, 7, 8, 9 , 10} };\n\t\t\t//\t\t\t\t\t 0 1 2\n\t\t\t\t\n\t\t\t\t// print 6:\n\t\t\tSystem.out.println( Numbers2D[2][1] );\n\t\t\t\n\t\t\t\t// print 10:\n\t\t\tSystem.out.println( Numbers2D[2][5] );\n\t\t\t\n\t\t\t\t// print {5, 6, 7, 8, 9 , 10}:\n\t\t\tSystem.out.println( Numbers2D[2] );\n\t\t\tSystem.out.println( Arrays.toString( Numbers2D[2] ) );\n\t\t\t\n\t\t\t\t// print the entire 2D array:\n\t\t\tSystem.out.println(Arrays.deepToString( Numbers2D ));\n\t\t\t\t\n\t\t\t\t\n\t\t// 3 dimensional array contains multiple 2 dimensional arrays\n\t\tint[][] Array2D = { {1,2}, {3,4} };\n\t\t//\t\t\t\t\t\t\t 0 1 0 1\n\t\tint[][][] Array3D = { { {1,2}, {3,4} } , { {5, 6}, {7, 8} } };\n// 0 1\t\n//[index numbers of 2D array][ index number of 1D array] [ index number of value]\n\n\t\t\t//print 8:\n\t\tSystem.out.println(Array3D[1][1][1]);\n\t\t\n\t\t// print {5, 6}:\n\t\tSystem.out.println( Array3D[1][0] );\n\t\tSystem.out.println( Arrays.toString( Array3D[1][0] ) );\n\t\t\n\t\t// print { {5, 6}, {7, 8} }:\n\t\tSystem.out.println( Array3D[1] );\n\t\tSystem.out.println( Arrays.toString( Array3D[1] ) );\n\t\tSystem.out.println( Arrays.deepToString( Array3D[1] ));\n\t\t\n\t\t\n\t\t// print the entire 3d array:\n\t\t\tSystem.out.println(Arrays.deepToString( Array3D ));\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\tint[][][] numbers3D = { { {1,2} } , { {3,4} } };\t\n\t\t\n\t\t\n\t\t\n\t//\t4 dimensional array contains multiple 3 dimensional arrays\n\tint[][][][] numbers4D = { { { {1,2} } , { {3,4} } } , { { {1,2} } , { {3,4} } } };\t\n\t\n\t\n\t\n\t\n\t\t\n\t}", "public static void main(String[] args) {\n\r\n\t\tint a[] = new int [5];\t\t\r\n\t\ta[0]=10;\r\n\t\ta[1]=20;\r\n\t\ta[2]=30;\r\n//\t\ta[3]=40;\r\n\t\ta[4]=50;\r\n\t\t\t\t\r\n\t\tSystem.out.println(a[0]);\r\n\t\tSystem.out.println(a[1]);\r\n\t\tSystem.out.println(a[2]);\r\n\t\tSystem.out.println(a[3]);\r\n\t\tSystem.out.println(a[4]);\r\n\t\t\r\n\t\t\r\n\t\tString b[] = new String [5];\t\t\r\n\t\tb[0]=\"Selenium\";\r\n\t\tb[1]=\"QTP\";\r\n\t\tb[2]=\"Testing sfsf\";\r\n\t\t\r\n\t\tSystem.out.println(b[0]);\r\n\t\tSystem.out.println(b[1]);\r\n\t\tSystem.out.println(b[2]);\r\n\t\tSystem.out.println(b[3]);\r\n\t\t\r\n\t}", "public static void main(String[] args) {\n\t\tString var1=\"Today is Wednesday\";\n\t\t//System.out.println(var1.length());\n\t\tString[] strArr=var1.split(\" \");\n\t\tfor(String word:strArr) {\n\t\t\tSystem.out.println(word);\n\t\t}\n\t\t\n\t\tString var2=\"Syntax is best. batch 9 is great.\";\n\t\tString[] strArr2=var2.split(\"[.]\");\n\t\t\n\t\tfor(int i=0;i<strArr2.length;i++) {\n\t\t\tSystem.out.println(strArr2[i]);\t}\n\t\t//method chaining\n\t\tString var3=\" SYNTAX \";\n\t\tSystem.out.println(var3.trim().toLowerCase());\n\t\t\n\t\tString var4=\"hi what are you doining\";\n\tSystem.out.println(convert(var4));\n\t}", "public static void main(String[] args) {\n\t\t\r\n\t\tString s=\"My name is Ismat Jahan\";\r\n\t\t\r\n\t\tString[] arr=s.split(\" \");\r\n\t\t\r\n\t\tfor(int i=0; i<=(arr.length-1); i++) {\r\n\t\t\tSystem.out.println(arr[i]);\r\n\t\t}\r\n\r\n\t}", "public static void main(String[] args) {\n\t\t\n\t\tString [][] array = new String [2] [3];\n\t\t\n\t\tarray [0] [0] = \"Shugofa\";\n\t\tarray [0] [1] = \"Shubha\";\n\t\tarray [0] [2] = \"Fabi\";\n\t\t\n\t\tarray [1] [0] = \"Lisa\";\n\t\tarray [1] [1] = \"Omed\";\n\t\tarray [1] [2] = \"Rahul\";\n\t\t\n\t\tSystem.out.println(array [1][2]);\n\t\t\n\t\t//to print them all\n\t\t\n\t\tfor (int i=0; i<2; i++) { //row\n\t\t\tfor (int j=0; j<3; j++) { //column\n\t\t\t\tSystem.out.println(array[i][j]);\t\t\t\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t\t\n\t\t//another way\n\t\t\n\t\tint [][] numbers = {\n\t\t\t\t{3, 4, 5, 6, 7, 9, 8, 7},\n\t\t\t\t{4, 5, 6, 7, 8, 9, 9},\n\t\t\t\t{5, 6, 7, 8, 9, 9, 9},\n\t\t\t\t{6, 7, 8, 9, 10, 8, 9}\t\n\t\t};\n\t\tSystem.out.println(\"The value in index 1 and 4 is= \" + numbers[1][4]); //\n\n\t\tSystem.out.println(\"The number of rows are:= \" + numbers.length);// to identify the number of Rows\n\n\t\tSystem.out.println(\"The number of columns are:= \" + numbers[3].length);// to identify the number of Columns\n\n\t\tfor (int s = 0; s < numbers.length; s++) {\n\t\t\tfor (int p = 0; p < numbers[s].length; p++) {\n\t\t\t\tSystem.out.print(numbers[s][p] + \" \");\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t}", "public static void main(String[] args) {\n Scanner scan = new Scanner(System.in);\n String s = scan.nextLine();\n // System.out.println(s);\n s = s.replace(\"!\", \" \");\n s = s.replace(\".\", \" \");\n s = s.replace(\"'\", \" \");\n s = s.replace(\"_\", \" \");\n s = s.replace(\"@\", \" \");\n s = s.replace(\"?\", \" \");\n s = s.replace(\",\", \" \");\n s = s.replace(\" \", \" \");\n s = s.replace(\" \", \" \");\n while(s.contains(\" \")) {\n \ts = s.replace(\" \", \" \");\n }\n \n \n while(s.charAt(0)==' '&&s.length()>1) {\n \tif(s.charAt(0)!=' ') {\n \t//\tSystem.out.println(s.length() +\"s \"+s);\n \t\tbreak;\n \t}else {\n \t\t//System.out.println(s.length() +\"s (\"+s+\")\");\n \t\ts = s.trim();\n \t}\n }\n \n if(!s.equals(\" \")) {\n s = s.trim();\n String [] allToken = s.split(\" \");\n System.out.println(allToken.length);\n for(int y=0;y<allToken.length;y++) {\n System.out.println(allToken[y]);\t\n }\n // System.out.println(allToken.length);\n }else {\n \t System.out.println(0);\n }\n scan.close();\n }", "public static void main(String[] args) {\n \tString s = \"[94,93,95,92,94,96,94,93,93,93,95,97,97,95,95,92,94,94,94,92,94,94,96,98,98,96,98,96,94,94,96,91,91,93,95,93,95,95,95,91,93,93,95,95,93,97,97,97,97,97,99,95,97,97,99,95,97,93,95,null,95,95,95,90,92,90,92,92,94,94,96,94,null,96,94,94,94,96,null,90,92,null,null,94,null,94,96,null,null,null,null,96,null,null,null,96,98,96,96,96,96,100,100,94,94,98,96,96,96,98,100,94,96,98,98,94,94,94,96,null,null,94,96,94,94,89,91,null,93,91,91,91,91,null,91,null,null,null,null,null,null,93,95,95,95,93,95,null,null,95,93,null,null,null,null,null,93,null,95,93,95,null,97,95,97,95,95,97,99,97,97,null,97,95,null,95,97,101,101,99,99,95,null,93,null,97,99,95,97,97,97,95,95,99,97,101,99,93,93,95,97,97,99,99,null,null,null,null,95,95,95,97,95,null,null,95,null,null,95,null,null,88,88,92,null,null,94,90,92,92,92,90,90,90,92,90,92,null,null,null,94,94,96,null,null,null,94,null,null,null,null,94,null,null,null,94,null,null,null,96,null,96,96,94,94,null,null,null,96,96,94,96,96,100,100,96,98,96,96,null,96,94,null,94,96,null,null,100,102,100,null,null,100,98,98,94,96,92,94,96,98,98,98,94,94,96,98,96,98,96,98,null,96,96,94,98,98,96,98,100,102,98,null,92,94,92,94,96,null,null,null,96,98,98,100,100,100,94,96,94,null,null,96,96,98,null,null,null,null,96,94,null,null,87,89,91,null,null,null,89,89,null,91,93,93,null,93,89,91,89,91,91,89,93,null,91,null,null,null,null,93,null,null,null,null,null,null,null,null,null,null,null,null,null,95,97,null,95,null,null,95,95,97,95,97,95,null,95,95,97,97,101,101,101,101,95,95,97,99,95,null,95,97,97,null,95,null,93,95,null,null,null,null,101,103,99,null,null,101,null,null,null,null,null,93,97,97,null,91,null,95,97,97,97,null,97,null,97,99,95,95,93,null,null,97,97,null,95,null,null,99,95,97,97,99,95,97,95,97,93,95,99,97,97,99,95,97,97,99,99,99,101,101,null,99,91,null,null,null,null,null,null,93,null,97,95,95,97,null,97,97,101,99,null,99,99,null,null,null,97,97,null,null,null,null,97,97,null,null,null,95,null,null,null,null,null,null,null,null,null,null,null,null,92,null,null,null,null,null,null,94,88,null,null,null,90,90,null,null,null,null,88,88,null,null,null,90,null,null,null,null,null,null,null,null,96,96,96,96,96,96,96,94,null,null,96,96,94,null,94,96,96,null,98,96,100,102,null,null,102,102,null,100,94,96,94,null,96,98,98,null,94,96,96,null,98,null,null,null,96,94,null,null,null,94,null,null,null,104,null,100,null,102,null,null,96,96,96,96,null,92,null,96,null,96,null,null,96,null,null,null,null,null,98,null,null,null,94,94,null,null,null,98,null,96,null,null,100,null,96,96,96,98,96,98,98,100,94,null,null,null,null,null,null,98,94,92,96,96,null,100,96,null,98,null,98,100,94,94,96,98,null,96,98,100,98,98,100,100,102,100,100,null,null,null,null,92,92,null,null,null,96,94,null,96,98,98,96,98,96,null,102,null,98,null,null,null,100,100,null,null,null,null,96,98,96,98,null,94,null,null,95,null,87,null,null,91,91,91,87,null,null,89,91,null,null,null,null,null,null,null,null,null,97,95,95,97,null,null,null,null,97,95,null,null,93,null,95,93,null,null,95,null,97,99,95,95,99,null,null,103,101,null,null,103,null,99,95,95,null,95,95,93,null,97,null,null,null,null,93,95,95,97,null,null,null,null,97,null,null,null,null,null,null,null,101,null,101,103,97,97,95,null,null,null,null,97,null,null,95,null,null,null,null,97,null,null,93,93,null,null,97,null,null,null,99,null,95,95,null,null,97,95,null,null,95,null,97,null,97,99,99,null,null,null,null,99,93,95,91,93,97,97,95,95,101,99,null,null,null,null,99,null,null,null,93,null,93,95,97,95,97,99,95,95,97,99,99,101,97,null,null,99,99,99,null,null,103,103,101,101,null,101,null,93,null,91,null,95,null,95,null,97,99,99,97,99,97,97,97,null,95,95,null,null,null,97,101,99,99,101,null,null,null,null,95,null,null,null,93,null,null,null,null,88,null,null,null,null,null,null,null,null,88,null,90,92,null,null,94,96,null,null,96,96,98,null,96,96,null,null,94,96,92,null,94,null,96,98,100,100,null,96,94,null,null,null,102,null,null,null,null,102,null,null,94,94,94,96,null,96,null,null,92,94,96,null,94,null,94,94,null,96,null,98,null,null,null,100,100,102,null,null,98,null,96,98,null,null,null,null,null,null,null,null,94,94,null,94,null,null,null,null,94,96,96,96,96,96,null,96,null,null,96,96,98,98,null,100,98,100,null,null,null,94,94,96,92,92,92,94,null,98,null,98,94,96,94,96,null,null,null,100,null,null,92,null,92,94,null,96,98,96,96,null,98,98,98,null,96,null,96,96,null,null,null,100,98,null,null,100,96,98,null,null,98,98,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,96,96,98,null,null,100,100,96,98,100,98,null,null,96,98,98,98,96,null,94,null,null,null,null,100,98,null,100,null,null,102,null,null,null,null,null,null,87,null,null,null,null,null,95,95,null,97,null,null,null,97,97,null,95,97,95,97,95,null,null,null,null,null,null,null,95,null,null,null,null,null,null,101,97,null,93,null,null,null,null,103,null,null,95,null,95,93,95,95,95,null,null,93,null,93,null,null,null,null,95,95,null,null,95,97,97,99,null,null,null,null,103,null,null,null,95,95,99,null,93,null,null,null,null,null,93,95,97,95,95,97,null,97,97,null,95,null,null,null,null,null,95,97,99,97,97,99,null,null,99,97,101,null,95,null,null,93,97,97,91,93,91,93,93,91,93,93,null,null,99,97,93,93,95,97,93,null,null,95,null,null,null,93,91,93,95,95,95,97,null,null,null,null,null,null,99,null,null,null,null,null,97,null,95,null,null,null,null,null,99,null,null,null,95,95,null,97,97,null,99,99,95,null,null,null,null,null,null,101,99,null,95,95,null,null,null,null,97,99,null,95,99,null,97,null,null,null,97,null,null,null,101,null,99,null,null,null,103,null,null,null,null,null,94,94,null,null,null,null,null,98,94,94,null,null,null,null,96,null,96,null,null,96,null,102,null,98,null,null,null,null,null,null,null,null,94,94,null,94,96,94,null,null,null,null,null,null,null,94,94,null,null,null,null,null,null,null,null,100,null,null,96,94,null,96,null,null,null,null,94,null,null,null,null,96,null,null,94,null,null,96,null,null,96,null,null,null,null,null,96,null,null,null,96,96,null,98,null,null,98,null,null,null,null,102,null,null,92,94,96,null,96,96,null,90,null,null,92,92,null,92,92,null,null,92,null,92,94,92,null,100,96,null,94,null,null,94,96,null,98,null,92,94,94,96,null,null,92,90,null,null,94,null,94,96,94,96,98,96,null,null,null,null,94,96,null,null,94,null,94,94,null,null,null,98,98,null,null,100,null,null,null,102,null,null,96,null,null,96,null,null,null,null,96,null,100,null,null,null,null,null,null,102,null,null,104,104,null,null,null,null,null,97,null,95,95,null,95,97,null,null,95,null,null,103,null,97,95,95,null,null,93,93,null,null,null,95,null,null,null,93,null,null,97,null,93,null,null,null,null,null,95,null,null,null,null,null,null,null,95,97,95,null,95,null,97,99,null,null,null,null,91,93,null,95,null,null,null,97,95,null,89,null,null,91,null,null,null,null,null,null,null,null,91,null,93,95,93,91,null,null,95,null,93,null,95,null,null,null,null,null,null,93,null,null,null,95,null,null,null,null,89,null,null,95,null,null,95,null,95,93,null,null,null,97,95,null,null,null,95,null,null,null,null,95,null,95,99,null,97,null,null,null,null,103,95,null,95,null,null,97,null,null,null,null,null,null,null,null,null,null,null,96,94,null,null,null,98,null,null,null,104,null,null,null,null,null,null,null,null,null,94,94,null,null,null,94,null,98,94,null,null,96,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,94,null,null,null,null,null,null,null,null,null,92,null,null,null,null,94,null,94,null,92,null,94,92,94,94,96,94,92,null,null,null,null,94,94,null,null,96,null,92,null,96,null,null,null,null,null,null,null,94,null,null,null,96,null,null,102,null,null,null,null,null,null,null,null,null,null,null,null,null,null,93,null,93,null,null,null,99,null,null,null,null,null,null,null,null,null,null,null,null,null,null,91,null,null,null,91,null,null,null,null,null,97,null,null,null,91,null,95,null,null,null,null,null,null,null,97,null,null,null,null,101,null,94,null,null,null,null,null,null,92,null,null,null,96,null,null,94,null,null,96,null,null,93,null,null,null,null,null,null,null,97]\";\r\n\t\tTreeNode one = TreeNode.str2tree(s);\r\n \tFindDuplicateSubtrees3 findDuplicateSubtrees = new FindDuplicateSubtrees3();\r\n\t\tList<TreeNode> result = findDuplicateSubtrees.findDuplicateSubtrees(one);\r\n\t\tfor (TreeNode treeNode : result) {\r\n\t\t\tSystem.out.println(treeNode);\r\n\t\t}\r\n\t}", "public static void main(String[] args) {\n System.out.println(EXAMPLE_TEST.matches(\"\\\\W.*\"));\n String[] splitString = (EXAMPLE_TEST.split(\"\\\\s+\"));\n System.out.println(splitString.length);\n for (String string : splitString) {\n System.out.println(string);\n }\n // replace all whitespace with tabs\n System.out.println(EXAMPLE_TEST.replaceAll(\"\\\\s+\", \"\\t\"));\n }", "public static void main(String[] args) {\n\t\tString helloWorld = \"Hello World\";\n\t\t\n\t\t// Creating string from Character array\n\t\tchar [] helloArray = {'h', 'e', 'l','l','o'};\n\t\tString helloString = new String(helloArray);\n\t\tSystem.out.println( helloString );\n\t\t\n\t\t// Printing Length of String\n\t\tString p= \"Dot saw I was Tod\";\n\t int len = p.length();\n\t System.out.println( \"Length is\" + len );\n\t \n\t String middle = \"middle\";\n\t System.out.println(\"first\" + middle + \"third\");\n\t \n\t // Format Strings\n\t float floatV = 4F;\n\t int intV = 5;\n\t char charV = 'd';\n\t System.out.printf(\"Value of Float is\" + \"%f, Value of int is\" + \"%d Value of char is\" + \"%c\",floatV, intV, charV );\n\n\t}", "public static void main(String[] args) {\n\t\tString Str[]=new String[100];\n\t\tint dig[]=new int[100];\n\t\tint choice;\n\t\tint n = 0,m = 0;\n\t\t\n\t\tSystem.out.println(\"Press 1 for String Array or Press 2 for Integer Array\\n\");\n\t\tScanner input1=new Scanner(System.in);\n\t\tScanner input2=new Scanner(System.in);\n\t\tScanner input3=new Scanner(System.in);\n\t\tScanner input4=new Scanner(System.in);\n\t\tScanner input5=new Scanner(System.in);\n\t\t\n\t\tchoice=input3.nextInt();\n\t\t\n\t\tswitch(choice) {\n\t\tcase 1:\n\t\t\tSystem.out.println(\"Enter the length of string array\\n\");\n\t\t\tn=input4.nextInt();\n\t\t\tSystem.out.println(\"Enter the string array\\n\");\n\t\t\tfor(int i=0;i<n;i++) {\n\t\t\t\tStr[i]=input1.nextLine();\n\t\t\t}\n\t\t\tbreak;\n\t\tcase 2:\n\t\t\tSystem.out.println(\"Enter the length of integer array\\n\");\n\t\t\tm=input5.nextInt();\n\t\t\tSystem.out.println(\"Enter the integer array\\n\");\n\t\t\tfor(int i=0;i<m;i++)\n\t\t\t{\n\t\t\t\tdig[i]=input2.nextInt();\n\t\t\t}\n\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tSystem.out.println(\"Invalid Input\");\n\t\t}\n\t\t\n\t\tif(choice==1)\n\t\t{\n\t\t\tfor(int i=n-1;i>=0;i--)\n\t\t\t{\n\t\t\t\tSystem.out.println(Str[i]);\n\t\t\t}\n\t\t}\n\t\t\n\t\telse if(choice==2)\n\t\t{\n\t\t\tfor(int i=m-1;i>=0;i--)\n\t\t\t{\n\t\t\t\tSystem.out.println(dig[i]);\n\t\t\t}\n\t\t}\n\t}", "public static void main(String[] args) {\r\n\t\t\r\n\t\tString str = \"!This is Yogesh\";\r\n\t\tString s =\"\";\r\n\t\tStringBuffer sb = new StringBuffer();\r\n\t\t\r\n\t\tString arr[] = str.split(\" \");\r\n\t\t\r\n\t\tfor(int i=arr.length-1;i>=0;i--){\r\n\t\t\t//s = s + arr[i];\r\n\t\t\tsb = sb.append(arr[i]);\r\n\t\t\t\r\n\t\t\tif((arr.length) != 0){\r\n\t\t\t\tsb = sb.append(\" \");\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\tSystem.out.println(sb.toString());\r\n\t\t\r\n\r\n\t\t\r\n\t}", "public static void main(String[] args) {\n\n\t\tString str=\"This is Batch 11 Batch 11 is great\";\n\t\t\n\t\tString [] arr=str.split(\" \");\n\t\t\n\t\tfor (String word:arr) {\n\t\t\tSystem.out.println(word);\n\t\t}\n\t}", "public static void main(String args[]) {\n Scanner in = new Scanner(System.in);\n int as = in.nextInt();\n int arr[] = new int[as];\n for (int i = 0; i< as ; i++)\n {\n arr[i] = in.nextInt();\n }\n separate(as, arr);\n for (int i = 0; i< as ; i++)\n {\n System.out.print(arr[i] + \" \");\n }\n }", "public static void jkPrintArrOneStr(String[] inputArr) {\n\n int printArrLen = inputArr.length;\n\n for (int printCount = 0; printCount < printArrLen; printCount++) {\n System.out.print(inputArr[printCount]);\n if (printCount != printArrLen - 1) System.out.print(\", \");\n }\n System.out.println();\n //---------------------------- /print elements of array\n\n }", "public static void main(String[] args) {\n\t\tint []i = new int[4];\n\t\ti[0]=10;\n\t\ti[1]=20;\n\t\ti[2]=30;\n\t\ti[3]=40;\n\t\t//i[4]=50;//ArrayIndexOutOfBoundsException\n\t\t\n\t\tSystem.out.println(i[0]);\n\t\tSystem.out.println(i[0]+i[1]);\n\t\tSystem.out.println(i[3]);\n\t\t//System.out.println(i[4]);//ArrayIndexOutOfBoundsException\n\t\t//System.out.println(i[-1]);//ArrayIndexOutOfBoundsException\n\n\t\tint len = i.length;\n\t\tSystem.out.println(\"length of array: \"+ len);\n\t\tSystem.out.println(\"LI=>\"+ 0);\n\t\tSystem.out.println(\"HI=>\" + (len-1));\n\t\t\n\t\t//print all the values of array: use for loop:\n\t\tfor(int k=0; k<=len-1; k++){\n\t\t\tSystem.out.println(i[k]);//10 20 30 40 \n\t\t}\n\t\t\n\t\t//2. double array:\n\t\tdouble []d = new double[2];\n\t\td[0]=12.33;\n\t\td[1]=23;\n\t\t\n\t\tSystem.out.println(d[0]+d[1]);\n\t\t\n\t\t//char array:\n\t\tchar c[] = new char[3];\n\t\tc[0]='a';\n\t\tc[1]='b';\n\t\tc[2]='1';\n\t\tSystem.out.println(c[0]+c[1]);\n\t\t\n\t\t\n\t\t//String array:\n\t\tString s[] = new String[3];\n\t\ts[0]=\"Java\";\n\t\ts[1]=\"Python\";\n\t\ts[2]=\"Ruby\";\n\t\t\n\t\tfor(int p=0; p<s.length; p++){\n\t\t\tSystem.out.println(s[p]);\n\t\t}\n\t\t\n\t\t\n\t\tString studentNames[] = new String[4];\n\t\t\n\t\tstudentNames[0]=\"Radha\";\n\t\tstudentNames[1]=\"Puja\";\n\t\tstudentNames[2]=\"Soorya\";\n\t\tstudentNames[3]=\"Imad\";\n\n\t\tfor(int h=0; h<studentNames.length; h++){\n\t\t\tif(studentNames[h].equals(\"Puja\")){\n\t\t\t\tSystem.out.println(\"marks : \" + 100);\n\t\t\t}\n\t\t\telse if(studentNames[h].equals(\"Radha\")){\n\t\t\t\tSystem.out.println(\"marks : \" + 99);\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\t//Emp details : \n\t\t//Object Array:\n\t\tObject ob[] = new Object[5];\n\t\tob[0] = \"Deepak\";\n\t\tob[1] = 25;\n\t\tob[2] = 12.33;\n\t\tob[3] = 'M';\n\t\tob[4] = true;\n\t\t\n\t\tfor(int v=0; v<ob.length; v++){\n\t\t\tSystem.out.println(ob[v]);\n\t\t}\n\t\t\n\t\t\n\t\t\n\t\t\n\t}", "public static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\t\n\t\tSystem.out.println(\"Hello World\");\n\t\t\n\t\tdouble d = Math.random();\n\t\t\n\t\tSystem.out.println(\"The random no is :\" + d);\n\t\t\n\t\t// int i = 0; // yellow lines are warnings, things you should think about\n\t\tint j = 100; // int is a basic type\n\t\tdouble f = 1.0;\n\t\tdouble d2 = 3.14159; // naming variables, letters , numbers , can use underscore but not dashes, first character must be a letter\n\t\tint my_int = 100;\n\t\t\n\t\tint aLowerCamelCaseVariable = 100; // variable naming convention, don't use underscores, first letter lowercase, subsequent letters in capitals\n\t\t\n\t\t\n\t\t// int answer = i + 100;\n\t\t\n\t\tboolean b = true; // boolean has key words associated with it - true and false in Java\n\t\tboolean c = false;\n\t\t\n\t\tString s = \"This is a string\"; // string is a complex type\n\t\t\n\t System.out.println(s.toUpperCase()); // functions associated with string types\n\t\t\n\t\t// control and space is a shortcut for intelesense\n\t \n\t System.out.println(s.length());\n\t \n\t int[] iArray = new int[10] ;\n\t int[] iArray2 = {1, 2, 3, 4, 5}; //can declare and populate array in one go\n\t \n\t String[] months = {\"Jan\", \"Feb\", \"Mar\",\n\t \t\t\t\t\t\"Apr\", \"May\", \"Jun\",\n\t \t\t\t\t\t\"Jul\", \"Aug\", \"Sep\",\n\t \t\t\t\t\t\"Oct\", \"Nov\", \"Dec\"}; // Java ignores all white space\n\t \n\t for (int i = 0; i< months.length; i++); {\n\t \t\n\t \n\t\t\tSystem.out.println(months[i]);\n\t }\n\t\t\n\t int i=0;\n\t while (i < months.length);{\n\t \t\n\t \tSystem.out.print(months[i] + \" \");\n\t \ti++;\n\t }\n\t \n\t i = 0;\n\t do {\n\t \tSystem.out.println(months[i] + \" \");\n\t \ti++;\n\t \t} while (i < months.length);\n\t \n\t // now creating the same thing backwards\n\t \n\t i = 11;\n\t do {\n\t\t System.out.print(months[i] + \" \");\n\t\t i--;\n\t\t if (i == 2 || i ==5 || i == 8 || i == 11) {\n\t\t\t System.out.println();\n\t\t }\n\t\t \n\t\t boolean answer = true;\n\t\t if (i == 2 && answer == false) {\n\t\t \n\t\t } \n\t\t \n\t\t if (i != 4) {\n\t\t\t // i is not equal to 4\n\t\t }\n\t\t \n\t\t \n\t\t \n\t \n\t \n\t }\n\t while (i >= 0);\n\t}", "public static void main(String[] args) {\n\n char[] chars;\n chars = new char[]{};\n\n char[] cc = {};\n\n // Second Approach\n String[] str = {};\n\n String[][] name = {\n {\"id\", \"first_name\", \"last_name\"},\n {\"2303\", \"joel\", \"brown\"}\n };\n // System.out.println(name[1][2]);\n\n for (String[] row : name) {\n for (String col : row) {\n if (col.equalsIgnoreCase(\"joel\"))\n System.out.println(col);\n }\n }\n }", "public static void main(String[] args) {\n\t\tint[] ages = { 3, 9, 23, 64, 2, 8, 28, 93 };\n\t\t\n\t\t// a.) Subtract the value of the first element in the array from the value in the last element of the array.\n\t\tint firstElement = ages[0];\n\t\tint lastElement = ages[ages.length - 1]; \n\t\tint ageSubtracted = lastElement - firstElement; \n\t\tSystem.out.println(\"1a.) The first element in the array, substracted by the last element is: \"+ ageSubtracted);\n\t\t\n\t\t// b.) Add a new age to your array and repeat the step above to ensure it is dynamic. \n\t\tint[] moreAges = { 3, 9, 23, 64, 2, 8, 28, 93, 45};\n\t\t\n\t\tfirstElement = moreAges[0];\n\t\tlastElement = moreAges[moreAges.length - 1]; \n\t\tageSubtracted = lastElement - firstElement; \n\t\tSystem.out.println(\"1b.) The first element in the second longer array, substracted by the last element is: \"+ ageSubtracted + \" . . . neat!\");\n\t\n\t\t// c.) Use a loop to iterate through the array and calculate the average age. \n\t\tint sum = 0; \n\t\tint count = 0; \n\t\tfor ( int age : ages ) {\n\t\t\tsum += age; \n\t\t\tcount ++; \n\t\t}\n\t\tint average = sum / count; \n\t\tSystem.out.println(\"1c.) The average of the array is around ~\" +average + \"\\n\");\n\t\t\n\t\t// ==============================================================================================================================\n\t\t// 2.) Create an array of String called names that contains the following values: “Sam”, “Tommy”, “Tim”, “Sally”, “Buck”, “Bob”.\n\t\tString[] names = { \"Sam\" , \"Tommy\", \"Tim\", \"Sally\", \"Buck\", \"Bob\" };\n\t\n\t\t// a.) Use a loop to iterate through the array and calculate the average number of letters per name. Print the result to the console.\n\t\tint totalCharacters = 0; \n \tint nameCount = 0; \n\t\tfor ( String name : names ) {\n\t\t\t// Create an char array of given String \n\t char[] ch = name.toCharArray(); \n\t int wordLength = ch.length;\n\t float averageChars = 0.0f; \n\t \n\t // average number of characters = total characters / quantity of names\n totalCharacters += wordLength;\n nameCount++; \n averageChars = totalCharacters / nameCount; \n System.out.println(\"2a.) After processing \" + name + \" the average number of characters per name is now about ~\" + averageChars);\n\t\t}\n\t\t\n\t\t\n\t\t// b.) Use a loop to iterate through the array again and concatenate all the names together, separated by spaces, and print the result to the console.\n\t\tString largeName = \"\"; \n\t\tfor (String name : names ) {\n\t\t\tlargeName += (name + \" \"); \n\t\t}\n\t\tSystem.out.println(\"2b.) \" + largeName);\n\t\t\n\t\t\n\t\t//=====================================================\n\t\t// 3.) How do you access the last element of any array? \n\t\tSystem.out.println(\"\\n3.) One accesses the last element in an array by calling the element within the array that's \\n found at the .length - 1 position, \\n for example: arrayName[arrayName.length - 1] would access the final element in arrayName. \\n\");\n\t\t\n\t\t// 4.) How do you access the first element of any array?\n\t\tSystem.out.println(\"4.) Because arrays begin at 0, one accesses the first element in an array by calling the element within the array that's \\n found at the 0 position , \\n for example: arrayName[0] would access the final element in arrayName. \");\n\t\n\t\t// 5.) Create a new array of int called nameLengths. Write a loop to iterate over the previously created names array \n\t\t// \t and add the length of each name to the nameLengths array.\n\t\t\n\t\t\n\t\tint[] nameLengths = new int[names.length];\n\t\t//String strArray[] = new String[nameLengths.length];\t\n\t\tint arrayPosition = 0; \n\t\tSystem.out.println(\"\\n5.) The following name lengths have been added to the 'namesLength' array:\" );\n\t\tfor ( String name : names ) {\n\t\t\t char[] ch = name.toCharArray(); \n\t\t int wordLength = ch.length;\n\t\t nameLengths[arrayPosition] = wordLength;\n\t\t System.out.println(names[arrayPosition] + \" - name length: \" + nameLengths[arrayPosition]);\n\t\t arrayPosition += 1; \n\t\t}\n\t\t\n\t\t// 6.) Write a loop to iterate over the nameLengths array and calculate the sum of all the elements in the array. Print the result to the console.\n\t\tint nameLengthSum = 0; \n\t\tfor (int nameLength : nameLengths) { \n\t\t\tnameLengthSum += nameLength;\n\t\t}\n\t\tSystem.out.println(\"\\n6.) The sum of all nameLengths would be \" + nameLengthSum + \".\");\n\t\n\t\t// 7.) Write a method that takes a String, word, and an int, n, as arguments and returns the word concatenated to\n\t\t// itself n number of times.\n\t\tSystem.out.println(\"\\n7.) \" + stringMultiplier(\"word\", 3));\n\t\t\n\t\t// 8.) Write a method that takes two Strings, firstName and lastName, and returns a full name.\n\t\tSystem.out.println(\"\\n8.) \"+ concatName(\"Tylor\" , \"Davis\"));\n\t\t\n\t\t// 9.) Write a method that takes an array of int and returns true if the sum of all the ints in the array is greater than 100.\n\t\tSystem.out.println(\"\\n9.) The answer for this particular int array is: \" + sumChecker(nameLengths));\n\t\t\n\t\t// 10.) Write a method that takes an array of double and returns the average of all the elements in the array.\n\t\tdouble[] testArray = {34.5, 98.60, 9.33, 9.90, 42.00} ; \n\t\tSystem.out.println(\"\\n10.) The average of all elements within this array of double is: \" + averageDoubleArray(testArray));\n\t\t\n\t\t// 11.) Write a method that takes two arrays of double and returns true if the average of the elements in the first array \n\t\t// is greater than the average of the elements in the second array.\n\t\tdouble[] testArrayOne = {73.55, 67.60, 9.33, 876.98, 42.00} ; \n\t\tdouble[] testArrayTwo = {34.50, 87.83, 0.00, 9.90, 2.00} ; \n\t\tSystem.out.println(\"\\n11.) Is the average of the elements in the first double array greater than the second?: \" + compareArrays(testArrayOne,testArrayTwo ));\n\t\n\t\t// 12.) Write a method called willBuyDrink that takes a boolean isHotOutside, and a double moneyInPocket, \n\t\t// and returns true if it is hot outside and if moneyInPocket is greater than 10.50.\n\t\t System.out.println(\"\\n12.) It's a good idea to get milk?: \" + willBuyDrink( true, 11.20)); \n\t\t \n\t\t // 13.) Create a method of your own that solves a problem. In comments, write what the method does and why you created it.\n\t\t System.out.println(\"\\n13.) the input string backwards is: \" + stringReverser( \"I love Teresa\"));\n\t}", "public static void main(String[] args) {\n\t\tSystem.out.println(\"1: ------------------------\");\n\t\tint a = 10, b = 25;\n\t\tString c = \"Saturday\", d = \"Java\";\n\t\tSystem.out.println(\"A: \" + a + \" & B: \" + b + \" & C =\" + c + \" & D = \" + d);\n\t\tint[] ab = { a, b };\n\t\tb = ab[0];\n\t\ta = ab[1];\n\t\tc = c + \" \" + d;\n\t\tString[] array = c.split(\" \");\n\t\td = array[0];\n\t\tc = array[1];\n\t\tSystem.out.println(\"After manipulations A = \" + a + \" and B = \" + b + \" C = \" + c + \" & D = \" + d);\n\t\tSystem.out.println(\"2: ------------------------\");\n\t\t// 2.Write a java program to find the second largest number in the array?\n\t\t// Maximum and minimum number in the array?\n\t\tint[] arr = { 2, 3, 4, 5, 6, 7, 8, 9, 1 };\n\t\tint max = arr[0], min = arr[0], secondLargest = arr[0];\n\t\tfor (int i : arr) {\n\t\t\tif (i > max) {\n\t\t\t\tsecondLargest = max;\n\t\t\t\tmax = i;\n\t\t\t} else if (i > secondLargest) {\n\t\t\t\tsecondLargest = i;\n\t\t\t} else if (i > max)\n\t\t\t\tmax = i;\n\t\t\telse if (i <= min)\n\t\t\t\tmin = i;\n\t\t}\n\t\tSystem.out.println(\n\t\t\t\t\"Second largest number is: \" + secondLargest + \" and largest is: \" + max + \" and smallest is: \" + min);\n\t\tSystem.out.println(\"3: ------------------------\");\n\t\t// 3. Find out how many alpha characters present in a string?\n\t\tString aa = \"SfN3n f3@nj Rd. 12@%k hn&n. njJbhK^$ %@33 4%*^))3\";\n\t\taa = aa.replaceAll(\"[A-Za-z 0-9]\", \"\");\n\t\tSystem.out.println(\"The number of alpha characters is: \" + aa.length());\n\t\tSystem.out.println(\"4: ------------------------\");\n\t\t// 4.How to find out the part of the string from a string? What is substring?\n\t\t// Find number of words in string?\n\t\tString aaa = \"I like to learn Java\";\n\t\tString[] aaaa = aaa.split(\" \");\n\t\tSystem.out.println(\"The number of words is: \" + aaaa.length);\n\t\tSystem.out.println(\"5: ------------------------\");\n\t\t// 5. Write a java program to reverse String? Reverse a string word by word?\n\t\tString original = \"Today is Saturday and we are learning java\";\n\t\tString reverse = \"\";\n\t\tString[] array1 = original.split(\" \");\n\t\tfor (int i = array1.length - 1; i >= 0; i--) {\n\t\t\treverse += array1[i] + \" \";\n\t\t}\n\t\tSystem.out.println(\"Reversed sentence is: \" + reverse);\n\t\tSystem.out.println(\"6: ------------------------\");\n\t\t// 6. Write a Java Program to find whether a String is palindrome or not?\n\t\tString str = \"Hannah\", str1 = \"\";\n\t\tfor (int j = str.length() - 1; j >= 0; j--) {\n\t\t\tstr1 += str.charAt(j);\n\t\t}\n\t\tif (str.equalsIgnoreCase(str1)) {\n\t\t\tSystem.out.println(\"This is palindrome\");\n\t\t} else {\n\t\t\tSystem.out.println(\"This is not palindrome\");\n\t\t}\n\t\tSystem.out.println(\"7: ------------------------\");\n\t\t//7. Write a java program to check whether a given number is prime or not?\n\t\tint p = 4;\n\t\tboolean prime=true;\n\t\tfor (int v=2;v<200;v++) {\n\t\t\tif (p%v!=0) {\n\t\t\t\tcontinue;}\n\t\t\telse if (p==v) {\n\t\t\t\tcontinue;\n\t\t\t}else {\n\t\t\t\tprime=false;}\n\t\t\t}\n\t\t\tSystem.out.println(\"Prime number? \"+prime);\n\t\tSystem.out.println(\"8: ------------------------\");\n\t\t//8. Write a Java Program to print first 10 numbers of Fibonacci series.\n\t\tint num1=0,num2=1;\n\t\tSystem.out.println(\"Fibonacci series of first 10 numbers:\");\n\t\tfor (int i=1;i<=10;++i) {\n\t\t\tSystem.out.print(num1+\" \");\n\t\t\tint sum=num1+num2;\n\t\t\tnum1=num2;\n\t\t\tnum2=sum;\n\t\t}\n\t}", "public static void showStringArray(String[] arr)\n {\n System.out.println(\"...........................................\");\n\n for (int i = 0; i < arr.length; i++) {\n System.out.print(arr[i] + \" \");\n }\n System.out.println();\n\n }", "public static void main(String[] args) {\r\n Scanner obj = new Scanner(System.in);\r\n int t=obj.nextInt();\r\n for(int k=0;k<t;k++)\r\n {\r\n String s=obj.next();\r\n int l=s.length();\r\n for(int i=0;i<l;i=i+2)\r\n {\r\n System.out.print(s.charAt(i));\r\n }\r\n System.out.print(\" \");\r\n for(int i=1;i<l;i=i+2)\r\n {\r\n System.out.print(s.charAt(i));\r\n } \r\n System.out.println();\r\n }\r\n }", "public static void main(String[] args) {\n\n String [] arr = {\"milk\",\"pot\",\"pot\",\"bread\",\"bread\",\"iskem\"};\n //String s = \"\";\n\n\n for(int i =0 ; i <= arr.length-1 ; i++) {\n String s = arr[i];\n int count = 0;\n for (int j = 0; j <= arr.length-1; j++) {\n String each = arr[j];\n if(s.equals(each)) {\n count+=1;\n }\n }\n if (count == 1) {\n System.out.println(s);\n }\n\n }\n System.out.println(\"==================================\");\n\n String str = \"islem ouiddir\";\n String [] arr2 = str.split(\" \");\n System.out.println(Arrays.toString(arr2));\n\n char [] ch = str.toCharArray();\n System.out.println(Arrays.toString(ch));\n\n }", "public static void main(String[] args)\r\n\t\t\r\n\t\t{\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tint j=0;\r\n\t\t\tString str=\"saurabh\";\r\n\t\t\tchar[] chars = str.toCharArray();\r\n\t\t\tchar arr[]=new char[chars.length];\r\n\t\t\tfor(char a1:chars) {\r\n\t\t\tint k= a1;\r\n\t\t\t//System.out.print(k+\" \");\r\n\t\t\tint k1=k+3;\r\n\t\t\tarr[j++]= (char) k1;\r\n\t\t\t}\r\n\t\t\tString s= new String(arr);\r\n\t\t\tSystem.out.println(s);\r\n\t\t\t\r\n\r\n\t\t\t\r\n\t\t\t\r\n\t\t}", "public static void main(String[] args){\n final Object[][] table = new String[6][];\n //each line has 5 items\n table[0] = new String[] { \"Kilograms\", \"Pounds\", \"|\", \"Pounds\", \"Kilograms\" };\n table[1] = new String[] { \"1\", \"2.2 \", \"|\", \"20\", \"9.09\" };\n table[2] = new String[] { \"3\", \"6.6 \", \"|\", \"25\", \"11.36\" };\n table[3] = new String[] { \"...\", \" \", \" \", \" \", \" \" };\n table[4] = new String[] { \"197\", \"433.4 \", \"|\", \"510\", \"231.82\" };\n table[5] = new String[] { \"199\", \"437.8 \", \"|\", \"515\", \"234.09\" };\n \n for (final Object[] row : table) {\n //print out each row with proper spacing\n System.out.format(\"%15s%15s%15s%15s%15s\\n\", row);\n }\n }", "public static void main(String[] args) {\n try (Scanner sc = new Scanner(System.in)) {\n int num = sc.nextInt();\n String[] str = new String[num];\n for (int i = 0; i < num; i++) {\n str[i] = sc.next();\n }\n for (int i = 0; i < num; i++) {\n for (int j = str[i].length() - 1; j >= 0; --j) {\n System.out.print(str[i].charAt(j));\n }\n System.out.println();\n }\n }\n }", "public static void main(String args[]) {\n String abc = \"40404040404040404040404061616124\";\n // System.out.print(\"\"+getAsciiFromString(abc));\n// System.out.print(\"\"+ CoderUtils.getStringFromAscii(abc));\n//\t\tint[] arrayData = {1,2,4,5,6,7,5,6,7,3,8,9,10,12,11,20,30,40};\n//\t\tArrays.sort(arrayData);\n//\t\tfor (int a : arrayData){\n//\t\t\tSystem.out.print(\"\" + a + \";\");\n//\t\t}\n\n\n }", "public static void main(String[] args) {\n\t String name = \"hi how\";\n\t String[] split = name.split(\" \");\n\t for(int i=0; i<split.length; i++)\n\t {\n\t \t int len = split[i].length();\n\t \t for(int a=len-1; a>=0; a--)\n\t \t {\n\t \t\t System.out.print(split[i].charAt(a));\n\t \t }\n\t \t System.out.print(\" \");\n\t \n\t }\n\t}", "public static void main(String [] args) throws IOException{\n\t\tBufferedReader br = new BufferedReader(new InputStreamReader(System.in));\n\t\tPrintWriter pr = new PrintWriter(new BufferedWriter(\n\t\t\t\tnew OutputStreamWriter(System.out)));\n\t\tString ln;\n\t\tint n,q,a,b,l,r;\n\t\tint le [],der[];\n\t\twhile((ln=br.readLine())!=null) {\n\t\t\tif(ln.charAt(0)=='0') break;;\n\t\t\tString res []= ln.split(\" \");\n\t\t\tn = Integer.parseInt(res[0]);\n\t\t\tq = Integer.parseInt(res[1]);\n\t\t\tle = new int[n+2];\n\t\t\tder = new int [n+2];\n\t\t\tfor(int i=0;i<=n;i++) {\n\t\t\t\tle[i+1]=i;\n\t\t\t\tder[i]=i+1;\n\t\t\t}\n\t\t\tder[n]=-1;\n\t\t\tle[1] =-1;\n\n\t\t\twhile(q-->0) {\n\t\t\t\tString nums []= br.readLine().split(\" \");\n\t\t\t\ta = Integer.parseInt(nums[0]); \n\t\t\t\tb = Integer.parseInt(nums[1]);\n\t\t\t\tl = le[a];\n\t\t\t\tr = der[b];\n\t\t\t\tStringBuilder sb = new StringBuilder();\n\t\t\t\t\n\t\t\t\tif (l ==-1)\n\t\t\t\t\tsb.append(\"*\");\n\t\t\t\telse {\n\t\t\t\t\tsb.append(l);\n\t\t\t\t\tder[l]=r;\n\t\t\t\t}\n\t\t\t\tsb.append(\" \");\n\t\t\t\tif (r ==-1) {\n\t\t\t\t\tsb.append(\"*\");\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tsb.append(r);\n\t\t\t\t\tle[r]=l;\n\t\t\t\t}\n\t\t\t\tpr.println(sb);\n\t\t\t}\n\t\t\tpr.println(\"-\");\n\t\t}\n\t\tpr.close();\n\t}", "public static void main(String[] args) {\n\n\t\t\n\t\tString a = \"9B768C\";\n\t\tString c = \"\";\n\t\tint leng = a.length();\n\t\tString array[] = new String[leng];\n\t\t\n\t\tfor(int i = 0 ; i<leng; i++) {\n\t\t\tarray[i]= a.substring(i,i+1);\n\t\t\tSystem.out.println(c += array[i]);\n\t\t}\n\t\n\t\t\n\t}", "public static void main(String[] args) {\n\t\t//test arrays\n\t\tInteger[] arr = {1, 4, 3, 2, 64, 3, 2, 4, 5, 5, 2, 12, 14, 5, 3, 0, -1};\n\t\tString[] strarr = {\"hope you find this helpful!\", \"wef\", \"rg\", \"q2rq2r\", \"avs\", \"erhijer0g\", \"ewofij\", \"gwe\", \"q\", \"random\"};\n\t\tarr = insertionsort(arr);\n\t\tstrarr = insertionsort(strarr);\n\t\tSystem.out.println(Arrays.toString(arr));\n\t\tSystem.out.println(Arrays.toString(strarr));\n\n\t}", "public static void main(String[] args) {\n\t\t\n\t\tString myString = \"Python 3.0\";\n\t\tString[] mySplitStrings = myString.split(\" \");\n\t\t\n\t\tSystem.out.println(String.join(\" Tutorial \", mySplitStrings));\n\t}", "public static void main(String[] args) {\n String str = \"dadasd34d3212323sddasda\";\n String[] longestNumbers = getLongestNumbers(str);\n System.out.println(longestNumbers[0]+\",\"+longestNumbers[1]);\n }", "static void printArray(char [] a) {\n\t\tfor (int i=0; i< a.length; i++) System.out.print(a[i]); \n\t\tSystem.out.println();\n\t}", "static void writearray(String[]array) {\n\t\t for (int i = 0; i < array.length; i++) {\n\t\t\tSystem.out.println(array[i]);\n\t\t}\n\t}", "public static void main(String[] args) {\n\t\t\n\t\tScanner scan=new Scanner(System.in);\n\t\tString a=\"Margarita loves Java\";\n\t\t\n\t\tfor(int b=a.length()-1; b>=0; b--) {\n\t\t\tSystem.out.print(a.charAt(b));\n\t\t}\n\t\tString[] c=a.split(\" \");\n\t\tfor(int d=c.length; d>=0; d++) {\n\t\t\tSystem.out.println(c[d]);\n\t\t}\n\t}", "public void Dname() {\n\t\t\tScanner sc = new Scanner(System.in);\r\n\t\t\tint n = 0;\r\n\t\t\tint k = max;\r\n\t\t\tString yname;\r\n\t\t\t\r\n\t\t\tString[] name2 = new String[k];\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tfor(n = 0 ; n < name2.length ; n++) {\r\n\t\t\t\t\r\n\t\t\t\tSystem.out.println(\"Enter words:\");\r\n\t\t\t\tyname = sc.nextLine();\r\n\t\t\t\t\t\t\tname2[n] = yname;\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t\t\tfor(int j = 0 ; j < k ; j++) {\r\n\t\t\t\t\t\tSystem.out.println(\"\\n\"+ name2[j]);\r\n\t\t\t\t\t}\r\n\t\t\t\t}", "public static void print(String[][][] god){\n for(int i = 0; i < god.length; i++){\n for(int j = 0; j < god[i].length; j++){\n for(int k = 0; k < god[i][j].length; k++){\n if(k == 0){\n System.out.print(\"[\" + god[i][j][k] + \",\");\n }\n if(k == (god[i][j].length - 1)){\n System.out.print(god[i][j][k] +\"]|\");\n }\n else{\n System.out.print(god[i][j][k] + \",\");\n }\n }\n }\n System.out.print(\"---\");\n }\n \n }", "public static void main(String[] args) {\n\t\n\t\t\n\t\t\n\t\tArrayList<Person> array = new ArrayList<Person>();\n\t\tarray.add(new Person(\"01100000­A\"));\n\t\tarray.add(new Person(\"01100000­B\"));\n\t\tarray.add(new Staff(\"01100000­C\", 55));\n\t\tarray.add(new Staff(\"01100000­D\", 55));\n\t\tarray.add(new Professor(\"01100000­E\", 100 , \"mathematics\"));\n\t\tarray.add(new Professor(\"01100000­F\", 200 , \"geography\"));\n\t\tarray.add(new Student(\"01100000­G\", \"777777\"));\n\t\tarray.add(new Student(\"01100000H\", \"888888\"));\n\t\tarray.add(new Intern(\"01100000­J\", \"999999\" , 300));\n\t\tarray.add(new Intern(\"01100000K\", \"101010\", 400));\n\t\tarray.add(new Tenured(\"01100000L\", \"physics\"));\n\t\tarray.add(new Tenured(\"01100000M\", \"computer_science\"));\n\t\t\n\t\tif (args.length == 0 )\n\t\t{\n\t\t\tfor(int j=0; j<array.size(); ++j)\n\t\t\t{\n\t\t\t\tSystem.out.println(array.get(j));\n\t\t\t}\n\t\t}\n\t\t\n\t\t\n\t\tfor (int i = 0; i < args.length ; ++i)\n\t\t{\n\t\t\tif (args[0].equals(\"-s\"))\n\t\t\t{\n\t\t\t\tfor(int g=0; g<array.size(); ++g)\n\t\t\t\t{\n\t\t\t\t\t\n\t\t\t\t\tSystem.out.println(array.get(g).toStringDni());\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public static void main(String[] args) {\n\t\tString s=\"Prasad\";\r\n\t\tchar c[]=s.toCharArray();\r\n\t\tchar d[]=new char[s.length()];\r\n\t\tint x[]=new int[20];\r\n\t\tfor(int i=0;i<c.length;i++)\r\n\t\t{\r\n\t\t\tint count=0;\r\n\t\t\tfor(int j=i+1;j<c.length;j++)\r\n\t\t\t{\r\n\t\t\t\tif(c[i]==c[j]&&c[i]!='@')\r\n\t\t\t\t{\r\n\t\t\t\t\tcount++;\r\n\t\t\t\t\ts.replace(c[j], '@');\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tx[i]=count;\r\n\r\n\t\t\t\tSystem.out.println(c[i]+\" \"+x[i]);\r\n\t\t}\r\n\t\t\r\n\r\n\t}", "public static void main(String[] args) {\n\n\t\tString [][] array= {\n\t\t\t\t{\"Mr\", \"Mrs\", \"Ms\", \"Miss\"},\n\t\t\t\t{\"Smith\", \"Jordan\", \"Jackson\", \"Obama\"}\n\t\t };\n\t\tSystem.out.println(array[0][1]+\" \"+array[1][0]);\n\t\tSystem.out.println(array[0][0]+\" \"+array[1][3]);\n\t\tSystem.out.println(array[0][2]+\" \"+array[1][2]);\n\t\tSystem.out.println(array[0][3]+\" \"+array[1][1]);\n\t\t\n\t\tSystem.out.println(\"-----------------------------------------------------------\");\n\t\t\n\t\t//TASK2;\n\t\t//Create an array of cars : american, german, korean, italian. \n\t\t//And print all values from a 2D array\n\t\t\n\t\tString[][] cars ={\n\t\t\t\t {\"Jeep\",\"Ford\",\"Dodge\"},\n\t\t\t\t {\"Audi\",\"Porsche\",\"BMW\"},\n\t\t\t\t {\"Kia\",\"Hyundai\",\"Genesis\"},\n\t\t\t\t {\"Ferrari\",\"Maserati\",\"Lamborghini\"}\n\t\t\t\t };\n\t\t\n\t\tfor(int i=0; i<cars.length; i++) {\n\t\t\t\n\t\t\tfor(int j=0; j<cars[i].length; j++) {\n\t\t\t\t//System.out.println(cars[i][j]);// veya\n\t\t\t\t\n\t\t\t\tString car=cars[i][j];\n\t\t\t\tSystem.out.print(car+\" \");\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t\t\n\t\tSystem.out.println(\"----------------------------------------------------------------------\");\n\t\t\n\t\t//ENHANCED \"FOR\"\n\t\t\n\t\tfor(String[] carArray:cars) {\n\t\t\t\n\t\t\tfor(String car:carArray) {\n\t\t\t\t\n\t\t\t\tSystem.out.print(car+\" \");\n\t\t\t}\n\t\t\t\n\t\t\tSystem.out.println();\n\t\t}\n\t}", "static void separarString(String s){\n\t\tString[] palabras = s.split(\"[ ]\");\n\t\tfor(int i = 0; i < palabras.length; i++){\n\t\t\tpalabras[i] = limpia(palabras[i]);\n\t\t\tSystem.out.println(palabras[i]);\n\t\t}\n\t}", "public static void Print02(){\n Scanner input = new Scanner(System.in);\n\n System.out.println(\"2. MASUKKAN KALIMAT/KATA : \");\n String inputString = input.nextLine();\n\n String[] inputArray = inputString.split( \" \");\n for(String text : inputArray)\n {\n char[] charArray = text.toCharArray();\n\n for (int i = 0; i < charArray.length; i++) {\n if(i == 0 || i == text.length() - 1 ) {\n System.out.print(charArray[i]);\n }\n else if (i == text.length() / 2) {\n System.out.print(\"***\");\n }\n else {\n System.out.print(\"\");\n }\n }\n System.out.print(\" \");\n }\n System.out.println();\n }", "private String[] toStringArray(String doc, char split) {\n\t\t// count words\n\t\tint wordCount = 0;\n\t\tfor (int i = 0; i < doc.length(); i++) {\n\t\t\tif (doc.charAt(i) == split) {\n\t\t\t\twordCount++;\n\t\t\t}\n\t\t}\n\t\t// split the String\n\t\tString[] words = new String[wordCount];\n\t\tint lastWord = 0;\n\t\tint index = 0;\n\t\tfor (int i = 0; i < doc.length(); i++) {\n\t\t\tif (doc.charAt(i) == split) {\n\t\t\t\twords[index++] = doc.substring(lastWord, i + 1).trim();\n\t\t\t\tlastWord = i + 1;\n\t\t\t}\n\t\t}\n\t\treturn words;\n\t}", "public static void main(String[] args) {\r\n //Letter J composed of \"J\",\"A\",\"V\",\"A\"\r\n System.out.println(\"JAVAJAVAJAVA\");\r\n System.out.println(\"JAVAJAVAJAVA\");\r\n System.out.println(\" JAVA\");\r\n System.out.println(\" JAVA\");\r\n System.out.println(\" JAVA\");\r\n System.out.println(\" JAVA\");\r\n System.out.println(\"J JAVA\");\r\n System.out.println(\"JA JAVA\");\r\n System.out.println(\" JAVAJAVA\");\r\n System.out.println(\" JAVAJA\");\r\n }", "public static void main(String[] args) {\n\t\tMatcher m = Pattern.compile(\"(?m)(\\\\S+)\\\\s+((\\\\S+)\\\\s+(\\\\S+))$\").matcher(PESMA);\r\n\t\twhile(m.find()){\r\n\t\t\tfor(int j = 0; j<=m.groupCount();j++)\r\n\t\t\t\tSystem.out.print(\"[\"+m.group(j)+\"]\");\r\n\t\t\tSystem.out.println();\r\n\t\t\t\r\n\t\t}\r\n\t}", "public static void main(String[] args) {\n String j=\"\";\n int i=1;\n while(i<=5)\n {\t \n \t j+=\"\"+i;\n System.out.println(j);\n i++;\n }\n while(i>=1)\n { \n \t System.out.println(j.substring(0,i-1));\n \t i--;\n }\n\t}", "public static void main(String[] args) {\n\t\t\n\t\tString str = \"one two three\";\n\t\tString[] splitStrings = str.split(\" \");\n\n\t\tSystem.out.println(\"Original String: \\n\" + str);\n\n\t\tSystem.out.println();\n\n\t\tSystem.out.println(\"Output String\");\n\t\tfor (int i = splitStrings.length - 1; i >= 0; i--) {\n\t\t\tSystem.out.print(splitStrings[i] + \" \");\n\t\t}\n\n\t}", "public static void main(String[] args) {\n\t\tStringJoiner joiner=new StringJoiner(\" and \",\"{\",\"}\");\n\t\tjoiner.add(\"python\");\n\t\tjoiner.add(\"java\");\n\t\tjoiner.add(\"c\");\n\t\tjoiner.add(\"c++\").add(\"html\").add(\"css\").add(\"js\");\n\t\tString s=joiner.toString();\n\t\tSystem.out.println(s);\n\t\tString s1=\"asd ad ad vxczvz\";\n\t\tSystem.out.println(s1.lastIndexOf(\" \"));\n\t\tSystem.out.println(s1.substring(s1.lastIndexOf(\" \")));\n\t\t\n\t\tStringJoiner joiner1=new StringJoiner(\" and \",\"[\",\"]\");\n\t\tjoiner1.add(\"asdsa\").add(\"rgrg\").add(\"grger\");\n\t\tSystem.out.println(joiner1);\n\t\tjoiner.merge(joiner1);\n\t\tSystem.out.println(joiner);\n\t}", "public static void main(String[] args) {\n\t String str = \"esto es un ejemplo de como funciona split\";\n\t Integer var=null;\n\t String regex;\n\t regex=Leer.pedirCadena(\"Expresión regular\", null);\n\t if(regex.equals(\"\")){\n\t \t regex=null;\n\t }\n\t var=Leer.pedirEntero(\"Pedir un entero\", regex);\n\t Leer.mostrarEnPantalla(\"El dato \"+var);\n\n\t}", "public void displayData(String[] str);", "public static void showD(ArrayList<ArrayList<String>> data){\n\t\tfor(int i = 0; i<data.get(0).size(); i++){\r\n\t\t\tfor(int j = 0; j<data.size(); j++){\r\n\t\t\t\tSystem.out.print(data.get(j).get(i));\r\n\t\t\t\tSystem.out.print(\"\\t\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"\\n\");\r\n\t\t}\r\n\t\treturn;\r\n\t}", "public static void main(String[] args) {\n\t\tRandom random = new Random();\n\t\tScanner scan = new Scanner(System.in);\n\t\tint n = scan.nextInt();\n//\t\tSystem.out.print(n);\n\t\tint[] lotto = new int[6];\n\t\tString str = \"[\";\n\t\t\n\t\tfor(int i=0; i<n; i++) {\n\t\t\tfor(int j=0; j<6; j++) {\n\t\t\t\tlotto[i] = random.nextInt(45)+1;\n\t\t\t\tif (j == 5) {\n\t\t\t\t\tstr += String.valueOf(lotto[i])+\"\";\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tstr += String.valueOf(lotto[i])+\", \";\n\t\t\t\t}\n\t\t\t}\n\t\t\tstr += \"]\";\n\t\t\t\n\t\t\tSystem.out.println((i+1) + \"번째 : \" + str);\n\t\t\tstr = \"[\";\n\t\t}\n\t}", "public void print(String s, int[] array) {\r\n int size = array.length;\r\n \r\n System.out.println(s);\r\n for (int i = 0; i < size ; i++) {\r\n System.out.print( array[i] +\" \");\r\n }\r\n System.out.println();\r\n }", "public static void main(String[] args) {\n\t\tUtil.isGeom(\"(1 1,2 2,2 1,1 1)\", \"5\");\r\n//\t\tString aString = \"(a)_(b)\";\r\n//\t\taString.split(\")\");\r\n\t}", "public static void main(String[] args) {\n Scanner sc = new Scanner(System.in);\n String[] str = new String[3];\n for (int i = 0; i < 3; i++) {\n str[i] = sc.nextLine();\n }\n for (int j = 2; j >= 0; j--) {\n System.out.println(str[j]);\n }\n }", "public static void printResult(Integer[] lines, String[] input){\n int word = 0;\n for(int line = 1; line < lines.length && lines[line]!=null; line++){\n int words = lines[line];\n for(int i = word; i<=word+words; i++){\n System.out.print(input[i]+\" \");\n }\n word = word+words+1;\n System.out.println();\n }\n }", "public static void main(String[] args) {\n\t\tSystem.out.println(\"Enter the no of string to insert\");\n\t\t\n\t\tScanner scanner = new Scanner(System.in);\n\t\tint no = Integer.parseInt(scanner.nextLine());\n\t\tSystem.out.println(\"No >>\"+no);\n\t\tString[] str = new String [no];\n\t\tSystem.out.println(\"Enter \"+ no + \" string \");\t\t\n\t\tfor (int i = 0; i < no; i++) {\n\n\t\t\tstr[i] = scanner.nextLine();\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Input strings are >>>>>>>\");\n\t\tfor ( int i = 0; i < no; i++) {\n\t\tSystem.out.print( str[i] + \" \" );\n\t\t}\n\t\tSystem.out.println();\n\t\tStringArray stringArray = new StringArray();\n\t\tArrayList<String> output = stringArray.validateString(str);\n\t\tSystem.out.println(\"output strings are >>>>>>>\");\n\t\t\n\t\t\n\t\tfor ( int i = 0; i < output.size(); i++) {\n\t\tSystem.out.print( output.get(i) + \" \" );\n\t}\n\t\t\n\t\t}", "public static void main(String[] args) {\n Scanner cin=new Scanner(System.in);\n // s=cin.next();//只能读取一个不含有空格的单词\n String s=cin.nextLine();//读取一整行 包括空格\n char [] chars=s.toCharArray();//String->char[]\n int digit=0,upper=0,lower=0,space=0,other=0;\n for(int i=0;i<chars.length;i++){\n if(Character.isDigit(chars[i]))++digit;\n else if(Character.isUpperCase(chars[i]))++upper;\n else if(Character.isLowerCase(chars[i]))++lower;\n else if(Character.isSpace(chars[i]))++space;\n else other++;\n\n }\n System.out.println(String.format(\"%d %d %d %d %d\",digit,upper,lower,space,other));\n }", "public static void main(String[] args) {\n\t\tString[][] str= new String[4][2];\r\n\t\t\r\n\t\t//Row 1\r\n\t\tstr[0][0]=\"Username\";\r\n\t\tstr[0][1]=\"Password\";\r\n\t\t//Row 2\r\n\t\tstr[1][0]=\"U1\";\r\n\t\tstr[1][1]=\"P1\";\r\n\t\t\r\n\t\tstr[2][0]=\"U2\";\r\n\t\tstr[2][1]=\"P2\";\r\n\t\t\r\n\t\tstr[3][0]=\"U3\";\r\n\t\tstr[3][1]=\"P3\";\r\n\t\t\t\t\r\n\t\t\t\t//System.out.println(str[1][1]);\r\n\t\tfor(int r=0; r<4; r++)\r\n\t\t{\r\n\t\t\tfor(int c=0; c<2; c++)\r\n\t\t\t{\r\n\t\t\tSystem.out.print(str[r][c]+\" \");\t\r\n\t\t\t}\r\n\t\t\tSystem.out.println();\r\n\t\t}\r\n\t}", "public static void main(String[] args) {\n\t\t\n\t\tReader.init(System.in); \n\t try{ \n\t \tint n=Reader.nextInt();\n\t\t\tint m=Reader.nextInt();\n\t\t\tchar[][] arr = new char[n][m];\n\t\t\tfor(int i=0;i<n;i++) {\n\t\t\t\tString q=Reader.next();\n\t\t\t\tif(q.length() == m) {\n\t\t\t\tfor(int j=0;j<m;j++) {\n\t\t\t\t\tarr[i][j] = q.charAt(j);\n\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t//int diff = m - q.length();\n\t\t\t\t\tfor(int e=q.length();e<m;e++) {\n\t\t\t\t\t\tarr[i][e] = ' ';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\tboolean flag = true;\n\t\t\tfor(int k=0;k<n;k++) {\n\t\t\t\tfor(int l=0;l<m;l++) {\n\t\t\t\t\tif(Character.isDigit(arr[k][l])) {\n\t\t\t\t\tint count = 0;\n\t\t\t\t\t\n\t\t\t\t\tif(k-1 >= 0) {\n\t\t\t\t\t\tif(l-1 >= 0) {\n\t\t\t\t\t\tif(arr[k-1][l-1] == '*') {\n\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(arr[k-1][l] == '*') {\n\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(l+1 < m) {\n\t\t\t\t\t\t\tif(arr[k-1][l+1] == '*') {\n\t\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif(k+1 < n) {\n\t\t\t\t\t\tif(l-1 >= 0) {\n\t\t\t\t\t\t\tif(arr[k+1][l-1] == '*') {\n\t\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif(arr[k+1][l] == '*') {\n\t\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif(l+1 < m) {\n\t\t\t\t\t\t\t\tif(arr[k+1][l+1] == '*') {\n\t\t\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(l-1 >= 0) {\n\t\t\t\t\t\tif(arr[k][l-1] == '*') {\n\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(l+1<m) {\n\t\t\t\t\t\tif(arr[k][l+1] == '*') {\n\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tint ty = Character.getNumericValue(arr[k][l]);\n\t\t\t\t\tif(count != ty) {\n\t\t\t\t\t\t//System.out.println(k+\" \"+l+\" \"+count+\" \"+arr[k][l]);\n\t\t\t\t\t\tflag = false;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telse if(arr[k][l] == '.') {\n\t\t\t\t\t\tint count=0;\n\t\t\t\t\t\tif(k-1 >= 0) {\n\t\t\t\t\t\t\tif(l-1 >= 0) {\n\t\t\t\t\t\t\tif(arr[k-1][l-1] != '*') {\n\t\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif(arr[k-1][l] != '*') {\n\t\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif(l+1 < m) {\n\t\t\t\t\t\t\t\tif(arr[k-1][l+1] != '*') {\n\t\t\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tif(k+1 < n) {\n\t\t\t\t\t\t\tif(l-1 >= 0) {\n\t\t\t\t\t\t\t\tif(arr[k+1][l-1] != '*') {\n\t\t\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif(arr[k+1][l] != '*') {\n\t\t\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif(l+1 < m) {\n\t\t\t\t\t\t\t\t\tif(arr[k+1][l+1] != '*') {\n\t\t\t\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(l-1 >= 0) {\n\t\t\t\t\t\t\tif(arr[k][l-1] != '*') {\n\t\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(l+1<m) {\n\t\t\t\t\t\t\tif(arr[k][l+1] != '*') {\n\t\t\t\t\t\t\t\tcount+=1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(count != 8) {\n\t\t\t\t\t\t\tflag = false;\n\t\t\t\t\t\t\t//System.out.println(k+\" \"+l);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\tif(flag == false) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif(flag == true) {\n\t\t\tSystem.out.println(\"YES\");\n\t\t\t}\n\t\t\telse {\n\t\t\t\tSystem.out.println(\"NO\");\n\t\t\t}\n\t } catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t}" ]
[ "0.6480422", "0.63041985", "0.6302708", "0.60031295", "0.599089", "0.59890974", "0.59741986", "0.5956947", "0.58881295", "0.588335", "0.58785474", "0.5866559", "0.58119863", "0.57885206", "0.5778362", "0.5750711", "0.57390755", "0.57273597", "0.57083094", "0.5705183", "0.5695629", "0.5693122", "0.5680197", "0.5667309", "0.5664021", "0.56540966", "0.5650476", "0.5641448", "0.56404483", "0.5633458", "0.5629013", "0.5629011", "0.5622742", "0.5614836", "0.5612641", "0.5603956", "0.5598272", "0.5579839", "0.5570994", "0.5570329", "0.55635303", "0.55458605", "0.55421484", "0.55349547", "0.55283755", "0.5510715", "0.5498911", "0.5483439", "0.54817677", "0.5469629", "0.54666966", "0.54533243", "0.5450658", "0.54454076", "0.54375696", "0.5435149", "0.5427738", "0.54254746", "0.54199487", "0.5419", "0.5407181", "0.54030865", "0.5391756", "0.53899586", "0.5389927", "0.53857756", "0.53793645", "0.5373567", "0.5369939", "0.5367462", "0.53590107", "0.5357545", "0.5347105", "0.5345919", "0.53414065", "0.5339587", "0.5334962", "0.53260946", "0.530772", "0.53022873", "0.53009623", "0.53009003", "0.52870154", "0.52833754", "0.52828544", "0.5278806", "0.5278754", "0.5270771", "0.52680963", "0.5267801", "0.52676004", "0.52589697", "0.52557737", "0.525386", "0.52484906", "0.5246211", "0.52443475", "0.5243737", "0.524058", "0.52384156" ]
0.71553993
0
Create a new SecurityImpl.
public CommonSecurityImpl(String securityDomainManaged, String securityDomainAndApplicationManaged, boolean applicationManaged) throws ValidateException { super(); this.securityDomainManaged = securityDomainManaged; this.securityDomainAndApplicationManaged = securityDomainAndApplicationManaged; this.applicationManaged = applicationManaged; this.validate(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static Security_I create()\r\n\t\t{\r\n\t\treturn new Security();\r\n\t\t}", "private Security() { }", "static SecurityHandler create() {\n return DEFAULT_INSTANCE;\n }", "public SecurityUser() {\n\t\tsuper();\n\t}", "Implementation createImplementation();", "SecurityScope createSecurityScope();", "public static synchronized void configureSecurity()\n {\n // import Component.Application.Console.Coherence;\n // import Component.Net.Security.Standard;\n // import com.tangosol.internal.net.security.DefaultStandardDependencies;\n // import com.tangosol.internal.net.security.LegacyXmlStandardHelper;\n // import com.tangosol.run.xml.XmlElement;\n \n if (isConfigured())\n {\n return;\n }\n \n DefaultStandardDependencies deps = null;\n Security security = null;\n \n try\n {\n // create security dependencies including default values\n deps = new DefaultStandardDependencies();\n \n // internal call equivalent to \"CacheFactory.getSecurityConfig();\"\n XmlElement xmlConfig = Coherence.getServiceConfig(\"$Security\");\n if (xmlConfig != null)\n {\n // load the security dependencies given the xml config \n deps = LegacyXmlStandardHelper.fromXml(xmlConfig, deps);\n \n if (deps.isEnabled())\n {\n // \"model\" element is not documented for now\n security = (Standard) _newInstance(\"Component.Net.Security.\" + deps.getModel()); \n }\n }\n }\n finally\n {\n // if Security is not instantiated, we still neeed to process\n // the dependencies to pickup the IdentityAsserter and IdentityTransformer\n // objects for the Security component (see onDeps()).\n if (security == null)\n {\n processDependencies(deps.validate());\n }\n else\n {\n // load the standard dependencies (currently only support Standard)\n if (deps.getModel().equals(\"Standard\"))\n {\n ((Standard) security).setDependencies(deps);\n }\n setInstance(security);\n }\n \n setConfigured(true);\n }\n }", "public SocialIdentity create() {\r\n SocialIdentity res = new SocialIdentity();\r\n return res;\r\n }", "WithCreate withSecurityProfile(SecurityProfile securityProfile);", "SecurityScheme createSecurityScheme();", "static Service create(String hostIp, String user, String password) {\n return new ServiceImpl(hostIp, user, password);\n }", "public IAuthorizationPrincipal newPrincipal(String key, Class type);", "TrustedIdProvider create();", "public static Security getInstance()\n {\n // import java.security.AccessController;\n \n if (!isConfigured())\n {\n AccessController.doPrivileged(new Security.ConfigAction());\n }\n return __s_Instance;\n }", "public interface SecurityContext {\n\n}", "Provider createProvider();", "SecuritySchemeLibrary createSecuritySchemeLibrary();", "public SecurityObject(String name) {\n\t\tthis.name = name;\n\n\t\tLOGGER.debug(\"SecurityObject#co [name=\" + name + \"]\");\n\t}", "public interface SecurityService {\n\n /**\n * Try to authenticate an user\n *\n * @param credentials to authenticate.\n * @return LoggedUser instance associated with credentials\n * @throws IOException if error generating token\n */\n LoggedUser authenticate(@Valid AccountCredentials credentials) throws IOException;\n\n /**\n * Creates a new LoggedUser instance with the requested role\n *\n * @param roleId requested role id.\n * @return new LoggedUser instance\n * @throws IOException if error generating token\n */\n LoggedUser changeRole(String roleId) throws IOException;\n\n /**\n * Gets info from logged user (LoggedUser instance)\n *\n * @return LoggedUser instance\n */\n LoggedUser getLoggedUser();\n\n /**\n * Hashes a value\n *\n * @param value value to be hashed.\n * @return hashed value\n */\n String hashValue(String value);\n}", "public interface Securable\r\n{\r\n\t// public SecurityCheck addSecurityCheck( String checkType, String checkName\r\n\t// );\r\n\t//\r\n\t// public void addSecurityChecksListener( SecurityTestListener listener );\r\n\t//\r\n\t// public int getSecurityCheckCount();\r\n\t//\r\n\t// public SecurityCheck getSecurityCheckAt( int c );\r\n\t//\r\n\t// public void removeSecurityChecksListener( SecurityTestListener listener );\r\n\t//\r\n\t// public void removeSecurityCheck( SecurityCheck securityCheck );\r\n\t//\r\n\t// // public AssertionStatus getAssertionStatus();\r\n\t// //\r\n\t// // public enum AssertionStatus\r\n\t// // {\r\n\t// // UNKNOWN, VALID, FAILED\r\n\t// // }\r\n\t//\r\n\t// // public String getAssertableContent();\r\n\t//\r\n\t// // public String getDefaultAssertableContent();\r\n\t//\r\n\t// // public AssertableType getAssertableType();\r\n\t//\r\n\t// public List<SecurityCheck> getSecurityCheckList();\r\n\t//\r\n\t// public SecurityCheck getSecurityCheckByName( String name );\r\n\t//\r\n\t// public ModelItem getModelItem();\r\n\t//\r\n\t// public Interface getInterface();\r\n\t//\r\n\t// public SecurityCheck cloneSecurityCheck( SecurityCheck source, String name\r\n\t// );\r\n\t//\r\n\t// public Map<String, SecurityCheck> getSecurityChecks();\r\n\t//\r\n\t// public SecurityCheck moveSecurityCheck( int ix, int offset );\r\n}", "public SecurityMB() {\n }", "public IUser CreateUser() {\n\t\tIUser iUser = null;\n\t\tswitch (db) {\n\t\tcase \"Mysql\":\n\t\t\tiUser = new MysqlUserImpl();\n\t\t\tbreak;\n\t\tcase \"Access\":\n\t\t\tiUser = new AccessUserImpl();\n\t\t\tbreak;\n\t\tdefault:\n\t\t\tbreak;\n\t\t}\n\t\treturn iUser;\n\t}", "public Object createComponent( final String implementationKey )\n throws Exception\n {\n final Class clazz = getClassLoader().loadClass( implementationKey );\n return clazz.newInstance();\n }", "public Implementor(){}", "protected SecurityContext doCreateSecurityContext(final Principal p, final Subject subject) {\n return new DefaultSecurityContext(p, subject);\n }", "Instance createInstance();", "private SecurityConsts()\r\n\t{\r\n\r\n\t}", "public OrderServiceSecurityException() {\n\t}", "protected SecurityObject() {\n\t\t// Used by JPA provider.\n\n\t\tLOGGER.debug(\"SecurityObject#co\");\n\t}", "SUP createSUP();", "public CertificationFactoryImpl() {\n\t\tsuper();\n\t}", "public WebloungeWebConsoleSecurityProvider(SecurityService securityService) {\n this.securityService = securityService;\n }", "protected CryptoProvider() {\n\n super(\"Crypto\", 1.0, \"HARMONY (SHA1 digest; SecureRandom; SHA1withDSA signature)\");\n put(\"SecureRandom.SHA1PRNG\",\"org.apache.harmony.security.provider.crypto.SHA1PRNG_SecureRandomImpl\");\n put(\"SecureRandom.SHA1PRNG ImplementedIn\", \"Software\");\n }", "WithCreate withSecurityToken(SourceControlSecurityTokenProperties securityToken);", "public interface InstanceSecurable extends Securable\n{\n\t/**\n\t * Return an identifying string. This string is used to determine\n\t * which instance of the Securable class we're dealing with when\n\t * looking up authorizations.\n\t */\n\tpublic String getInstanceIdentifier();\n}", "public ESPDevice createESPDevice(ESPConstants.TransportType transportType, ESPConstants.SecurityType securityType) {\n\n espDevice = new ESPDevice(context, transportType, securityType);\n return espDevice;\n }", "private Decryptor createDecryptor(String decryptorClass) {\n\t\tif(decryptor != null) {\n\t\t\treturn decryptor;\n\t\t}\n\n\t\tif (logger.isTraceEnabled()) {\n\t\t\tlogger.trace(\"creating decryptor {}\", decryptorClass);\n\t\t}\n\t\t\n\t\ttry {\n\t\t\tClass<?> typeClass = Class.forName(decryptorClass);\n\t\t\t\n\t\t\tif (!typeClass.isInterface()) {\n\t\t\t\treturn (Decryptor) typeClass.getConstructor().newInstance();\n\t\t\t}else {\n\t\t\t\tlogger.error(\"Please specify an implementing class of com.networknt.decrypt.Decryptor.\");\n\t\t\t}\n\t\t} catch (Exception e) {\n\t\t\tlogger.error(e.getMessage());\n\t\t\tthrow new RuntimeException(\"Unable to construct the decryptor due to lack of decryption password.\", e);\n\t\t}\n\t\t\n\t\treturn null;\n\t}", "SecureRandomImpl(OpenEngineSpi spi) {\r\n super((SecureRandomSpi) spi, SecureRandomProvider.PROVIDER);\r\n engineSpi = spi;\r\n threadSafe = spi instanceof MultiplexSpi;\r\n }", "public Secure() {\n\t\tsuper();\n\t}", "protected static void setInstance(Security security)\n {\n __s_Instance = security;\n }", "public CryptoProvider() {\n super(\"Crypto\", 1.0, \"HARMONY (SHA1 digest; SecureRandom; SHA1withDSA signature)\");\n put(\"SecureRandom.SHA1PRNG\",\n \"org.apache.harmony.security.provider.crypto.SHA1PRNG_SecureRandomImpl\");\n put(\"SecureRandom.SHA1PRNG ImplementedIn\", \"Software\");\n }", "public CryptoProvider() {\n super(\"Crypto\", 1.0, \"HARMONY (SHA1 digest; SecureRandom; SHA1withDSA signature)\");\n put(\"SecureRandom.SHA1PRNG\",\n \"org.apache.harmony.security.provider.crypto.SHA1PRNG_SecureRandomImpl\");\n put(\"SecureRandom.SHA1PRNG ImplementedIn\", \"Software\");\n }", "public CryptoProvider() {\n super(\"Crypto\", 1.0, \"HARMONY (SHA1 digest; SecureRandom; SHA1withDSA signature)\");\n put(\"SecureRandom.SHA1PRNG\",\n \"org.apache.harmony.security.provider.crypto.SHA1PRNG_SecureRandomImpl\");\n put(\"SecureRandom.SHA1PRNG ImplementedIn\", \"Software\");\n }", "void enableSecurity();", "public void create(){}", "static Algorithm createSystem(String sys, Config cfg) {\n switch (sys.toLowerCase()) {\n case \"shift\":\n return new CaesarCipher(cfg.getKey());\n case \"unicode\":\n return new UnicodeCipher(cfg.getKey());\n default:\n throw new IllegalArgumentException(String.format(\"Invalid algorithm %s\\n\", sys));\n }\n }", "public InboundSecurityRules() {\n }", "private static FXForwardSecurity createFxForwardSecurity() {\n\n Currency payCurrency = Currency.GBP;\n Currency recCurrency = Currency.USD;\n\n double payAmount = 1_000_000;\n double recAmount = 1_600_000;\n\n ZonedDateTime forwardDate = DateUtils.getUTCDate(2019, 2, 4);\n\n ExternalId region = ExternalSchemes.currencyRegionId(Currency.GBP);\n\n FXForwardSecurity fxForwardSecurity = new FXForwardSecurity(payCurrency, payAmount, recCurrency, recAmount, forwardDate, region);\n\n return fxForwardSecurity;\n }", "private HpcSecurityRestServiceImpl() throws HpcException {}", "SignatureIdentification createSignatureIdentification();", "protected OpUserServiceImpl createServiceImpl() {\r\n return new OpUserServiceImpl();\r\n }", "public SapFactoryImpl() {\n super();\n }", "public interface SecurityConfiguration {\n\t\n\t/**\n\t * Gets the executor.\n\t *\n\t * @return the executor\n\t */\n\tExecutor getExecutor();\t\n\t\n\t/**\n\t * User preemptive auth.\n\t *\n\t * @return true, if successful\n\t */\n\tboolean userPreemptiveAuth();\n}", "public void create() {\n String salt = PasswordUtils.getSalt(30);\n\n // Protect user's password. The generated value can be stored in DB.\n String mySecurePassword = PasswordUtils.generateSecurePassword(password, salt);\n\n // Print out protected password\n System.out.println(\"My secure password = \" + mySecurePassword);\n System.out.println(\"Salt value = \" + salt);\n Operator op = new Operator();\n op.setUsername(username);\n op.setDescription(description);\n op.setSalt(salt);\n op.setPassword(mySecurePassword);\n op.setRol(rol);\n operatorService.create(op);\n message = \"Se creo al usuario \" + username;\n username = \"\";\n description = \"\";\n password = \"\";\n rol = null;\n }", "ExpressionTree createSecurityFeatureInitializer( WorkingCopy workingCopy,\n TreeMaker make, String id);", "public Provider() {\n super(PROVIDER_NAME, 0.1, \"WebID-TLS Provider\");\n }", "interface WithCreate {\n /**\n * Executes the create request.\n *\n * @return the created resource.\n */\n TrustedIdProvider create();\n\n /**\n * Executes the create request.\n *\n * @param context The context to associate with this operation.\n * @return the created resource.\n */\n TrustedIdProvider create(Context context);\n }", "@ServiceMethod(returns = ReturnType.SINGLE)\n public SecurityOperatorInner createOrUpdate(String pricingName, String securityOperatorName) {\n return createOrUpdateWithResponse(pricingName, securityOperatorName, Context.NONE).getValue();\n }", "public interface SecurityService {\n\n PasswordEncoder getPasswordEncoder();\n\n void createAdminUser(NewUser newUser);\n\n org.springframework.security.core.userdetails.User getCurrentUserFromCtx();\n\n User getCurrentUser();\n\n void createOfficeUser(NewOfficeUser newOfficeUser);\n\n void lockUser(User user);\n\n void unLockUser(User user);\n\n void changePassword(ChangePassword changePassword);\n\n boolean resetPassword(User user);\n\n boolean isLogged();\n\n\n}", "License createLicense();", "interface WithSecurityProfile {\n /**\n * Specifies the securityProfile property: The lab security profile..\n *\n * @param securityProfile The lab security profile.\n * @return the next definition stage.\n */\n WithCreate withSecurityProfile(SecurityProfile securityProfile);\n }", "public Encryptor(){\n\t\tSecurity.addProvider(new BouncyCastleProvider());\n\t}", "public interface ISecurityMonitorService {\n\n\n}", "FutureSecureMap<KeyType, ValueType> create(String name);", "public BasicSafetyCaseFactoryImpl() {\n\t\tsuper();\n\t}", "ITransport createTransport(T netconfAccessInfo) throws NetconfException;", "Secuencia createSecuencia();", "public CadesSignatureDemo() {\n Security.addProvider(new IAIK());\n }", "@Override\n\tpublic IUser creatUser() {\n\t\treturn new SqlServerUser();\n\t}", "public interface SecurityService\r\n{\r\n\t/**\r\n\t * This method return true if the given 'securityToken' is a valid token for the given security service. The security service can be any service\r\n\t * such as OAuth, LDAP, ActiveDirectory, OpenID etc. It is up to the implementor of this interface to interact with the appropriate security\r\n\t * service to determine if the given securityToken is valid. Reasons for a token to not be valid include but are not limited to, expired tokens, \r\n\t * incorrect tokens, not authenticated tokens etc.<br/>\r\n\t * This method will be used by the provider in a DIRECT environment to authenticate/validate a consumer.\r\n\t * \r\n\t * @param securityToken The token that shall be validated against a given security service such as LDAP, OAuth, Active Directory, etc.\r\n\t * @param requestMetadata Metadata that has been sourced from a request. The environmentID property is always null because the token is\r\n * not yet authenticated and therefore the environment is not yet determined. \r\n\t * \r\n\t * @return TRUE if the token is known and valid to the security server and not expired. If a token is expired then FALSE should be returned.\r\n\t */\r\n\tpublic boolean validate(String securityToken, RequestMetadata requestMetadata);\r\n\r\n\t/**\r\n\t * This method may contact the security server which can be an OAuth server, and LDAP server a Active Directory etc. In return it will provide \r\n\t * information that relate to the securityToken such as: <br/>\r\n\t * a) Information about the application and/or user of that securityToken (appUserInfo property populated in the TokenInfo) or<br/>\r\n\t * b) Information about the SIF environment or SIF session the securityToken relates to. This would be the case for already existing SIF\r\n\t * Environments.<br/>\r\n\t * Further an expire date might be set for the securityToken if the token has expired. If the securityToken does not expire then the \r\n\t * expire date is null in the returned TokenInfo object.<br/>\r\n * This method will be used by the provider in a DIRECT environment to get information about a consumer's security token.\r\n\t * \r\n\t * @param securityToken The security token for which the TokenInfo shall be returned.\r\n\t * @param requestMetadata Metadata that has been sourced from a request. The environmentID property is always null because the token is\r\n * not yet authenticated and therefore the environment is not yet determined. \r\n\t * \r\n\t * @return See Desc. It is expected that this method only returns either the environmentKey or the SIF environment ID or the SIF session token but\r\n\t * not all of these at the same time.\r\n\t */\r\n\tpublic TokenInfo getInfo(String securityToken, RequestMetadata requestMetadata);\r\n\t\r\n\t/**\r\n\t * This method may contact the security server which can be an OAuth server, and LDAP server a Active Directory etc. to generate a \r\n\t * security token based on the given 'coreInfo'. It is expected that any consumer or a provider in a BROKERED environment calls this \r\n\t * method to retrieve a security token which it will use as the authorisation token in all SIF requests to a provider or broker.\r\n\t * \r\n\t * @param coreInfo Information about the consumer/provider that might be used to generate a security token by the external security service.\r\n\t * In most cases it would at least need the application key.\r\n\t * @param password It is very likely that some sort of password will be required to generate a security token.\r\n\t * \r\n\t * @return A TokenInfo object which will have the 'token' property set (the security token). Optional the 'tokenExpiryDate' may be set\r\n\t * if the token has an expire date. If the 'tokenExpiryDate' is null it is assumed that the returned security token won't expire.\r\n\t * The returned token should only be a token without any authentication method as a prefix. For example the token may be\r\n\t * \"ZjI2NThiNTktNDM1Yi00YThkLTlmNzYtYzI0MDBiNjY1NWMxOlBhc3N3b3JkMQ\". It should not hold the authentication method such as 'Bearer'\r\n\t * (i.e. not look like this: \"Bearer ZjI2NThiNTktNDM1Yi00YThkLTlmNzYtYzI0MDBiNjY1NWMxOlBhc3N3b3JkMQ\"). The SIF3 Framework will\r\n\t * manage the authentication method.\r\n\t */\r\n\tpublic TokenInfo createToken(TokenCoreInfo coreInfo, String password);\r\n}", "public static ServiceProvider createServiceProvider() {\n \t//return new ActiveMQProvider();\n \treturn new RSPServiceProvider();\n }", "public Builder info(SecurityInfo info) {\n JodaBeanUtils.notNull(info, \"info\");\n this.info = info;\n return this;\n }", "public Permissions() {\r\n yamlC = new YamlCreator();\r\n StorageFactory.registerDefaultCreator(yamlC);\r\n StorageFactory.registerCreator(\"YAML\", yamlC);\r\n }", "private Object createInstance() throws InstantiationException, IllegalAccessException {\n\t\treturn classType.newInstance();\n\t}", "private static Object createNewInstance(String implement, String header, String expression) {\n\n\t\t// a feeble attempt at preventing arbitrary code execution\n\t\t// by limiting expressions to a single statement.\n\t\t// Otherwise the expression can be something like:\n\t\t// \tf(); } Object f() { System.exit(0); return null\n\t\tif (expression.contains(\";\"))\n\t\t\treturn null;\n\n\t\t// since we might create multiple expressions, we need their names to be unique\n\t\tString className = \"MyExpression\" + classNum++;\n\n\t\t// if we compile the class susseccfully, try and instantiate it\n\t\tif (writeAndCompile(className, implement, header, expression)) {\n\t\t\ttry {\n\t\t\t\tFile classFile = new File(path + className + \".class\");\n\t\t\t\t// load the class into the JVM, and try and get an instance of it\n\t\t\t\t//Class<?> newClass = ClassLoader.getSystemClassLoader().loadClass(className);\n\n\t\t\t\tURLClassLoader classLoader = URLClassLoader.newInstance(new URL[] { classFile.toURI().toURL() });\n\t\t\t\tClass<?> newClass = Class.forName(className, true, classLoader);\n\n\t\t\t\t// delete the class file, so we leave no trace\n\t\t\t\t// this is okay because we already loaded the class\n\t\t\t\ttry {\n\t\t\t\t\tclassFile.delete();\n\n\t\t\t\t// meh, we tried\n\t\t\t\t} catch (Exception e) {}\n\n\t\t\t\treturn newClass.newInstance();\n\t\t\t} catch (Exception e) {\n\t\t\t\te.printStackTrace();\n\t\t\t\t//System.out.println(\"Couldn't load class\");\n\t\t\t\treturn null;\n\t\t\t}\n\t\t} else {\n\t\t\tSystem.out.println(\"Couldn't write / compile source\");\n\t\t}\n\n\t\t// the class didn't compile\n\t\treturn null;\n\t}", "public interface Provider {\n Service newService();\n }", "public abstract I_Authenticate getSecurityCtx();", "AuthenticationMethod createAuthenticationMethod();", "SignatureSource createSignatureSource();", "@Override\n\t\tpublic MyUserBasicInfo create() {\n\t\t\treturn new MyUserBasicInfo();\n\t\t}", "public interface SecurityMechanism extends EObject {\r\n}", "public SecRole getNewSecRole();", "public SecRole getNewSecRole();", "WithCreate withEncryption(Encryption encryption);", "public IDetectionAlgorithm createInstance();", "public interface SOSFactory {\n SOS getSOS();\n}", "public void setSecurity(Security security)\n {\n __m_Security = security;\n }", "T create();", "T create();", "private static void genSecGroup() {\n\t\tSystem.out.println(\"This Program will generate a security group\");\n\t\tSystem.out.println(\"with the name bitcrusher and ssh ability for\");\n\t\tSystem.out.println(\"your ip address.\");\n\t\ttry{\n\t\t\tCreateSecurityGroupRequest secGrpRequest = new CreateSecurityGroupRequest(\"bitcrusher\", \"Ingress group for AWSTool\");\n\t\t\tCreateSecurityGroupResult res = ec2.createSecurityGroup(secGrpRequest);\n\t\t\tSystem.out.println(\"Group \" + res.getGroupId() + \"created.\");\n\t\t\t\n\t\t}catch(AmazonServiceException ase){\n\t\t\tSystem.out.println(\"Group exists. If needed set permissions with -ip option\");\n\t\t\tSystem.exit(0);\n\t\t}\n\t\t\n\t\tString ip = \"0.0.0.0/0\";\n\t\t\n\t\t\n\t\tList<String> ipRanges = Collections.singletonList(ip);\n\t\t\n\t\tIpPermission ipPerm = new IpPermission();\n\t\tipPerm.setFromPort(SSH);\n\t\tipPerm.setToPort(SSH);\n\t\tipPerm.setIpRanges(ipRanges);\n\t\tipPerm.setIpProtocol(\"tcp\");\n\t\t\n\t\tList<IpPermission> ipPermList = Collections.singletonList(ipPerm);\n\t\t\n\t\ttry{\n\t\t\tAuthorizeSecurityGroupIngressRequest ingRequest = \n\t\t\t\t\tnew AuthorizeSecurityGroupIngressRequest(\"bitcrusher\", ipPermList);\n\t\t\tec2.authorizeSecurityGroupIngress(ingRequest);\n\t\t\tSystem.out.println(\"Your ip has been authorized with the bitcrusher group.\");\n\t\t\t\n\t\t}catch(AmazonServiceException e){\n\t\t\tSystem.out.println(\"Ip already authorized\");\n\t\t\tSystem.exit(0);\n\t\t}\n\t}", "public interface Provider{\n Service newService();\n}", "public StimuliFactoryImpl() {\r\n\t\tsuper();\r\n\t}", "public SSDI_AMImpl() {\n }", "public EsoFactoryImpl()\r\n {\r\n super();\r\n }", "Cancion createCancion();", "@Override\n public ConcurrentContentSigner newSigner(\n String type, SignerConf conf, X509Cert[] certificateChain)\n throws ObjectCreationException {\n type = type.toLowerCase(Locale.ROOT);\n if (!types.contains(type)) {\n throw new ObjectCreationException(\"unknown signer type \" + type);\n }\n\n String str = conf.getConfValue(\"parallelism\");\n int parallelism = 20;\n if (str != null) {\n try {\n parallelism = Integer.parseInt(str);\n } catch (NumberFormatException ex) {\n throw new ObjectCreationException(\"invalid parallelism \" + str);\n }\n\n if (parallelism < 1) {\n throw new ObjectCreationException(\"invalid parallelism \" + str);\n }\n }\n\n str = conf.getConfValue(\"alias\");\n if (str == null) {\n throw new ObjectCreationException(\"alias is not specified\");\n }\n int keyId = Integer.parseInt(str);\n\n String algoName = conf.getConfValue(\"algo\");\n if (algoName == null) {\n throw new ObjectCreationException(\"algo is not specified\");\n }\n\n try {\n InitStatus initStatus = init(type);\n if (initStatus.status.get() != 1) {\n throw new ObjectCreationException(initStatus.details);\n }\n\n SignAlgo algo = SignAlgo.getInstance(algoName);\n String keyAlgoName;\n String bcKeyAlgoName;\n if (algo.isSM2SigAlgo()) {\n keyAlgoName = \"SM2\";\n bcKeyAlgoName = \"EC\";\n } else if (algo.isRSAPkcs1SigAlgo() || algo.isRSAPSSSigAlgo()) {\n keyAlgoName = \"RSA\";\n bcKeyAlgoName = \"RSA\";\n } else if (algo.isECDSASigAlgo() || algo.isPlainECDSASigAlgo()) {\n keyAlgoName = \"EC\";\n bcKeyAlgoName = \"EC\";\n } else {\n throw new ObjectCreationException(\"unsupported algo \" + algoName);\n }\n\n Provider provider = providerMap.get(type);\n\n // Method to read create PrivateKey and PublicKey object.\n // SANSEC use KeyPairGenerator.generateKeyPair to read the keypair-\n // No new keypair will be generated here.\n KeyPairGenerator kpGen = KeyPairGenerator.getInstance(keyAlgoName, provider);\n kpGen.initialize(keyId << 16);\n KeyPair kp = kpGen.generateKeyPair();\n\n PublicKey publicKey = KeyFactory.getInstance(bcKeyAlgoName, \"BC\")\n .generatePublic(new X509EncodedKeySpec(kp.getPublic().getEncoded()));\n\n return new JceSignerBuilder(kp.getPrivate(), publicKey, certificateChain, provider)\n .createSigner(algo, parallelism);\n } catch (GeneralSecurityException | XiSecurityException ex) {\n throw new ObjectCreationException(ex.getMessage(), ex);\n }\n }", "Account create();", "public interface Provider {\n Service newService();\n}", "public interface Provider {\n Service newService();\n}", "public interface ISecurityVerifier {\n public static final String COMPONENT_NAME = \"ISecurityVerifier\";\n\n Access getAllPossibleAccess(SecurityAccessor accessor, String resourceEntity, Access mask);\n\n boolean canAccess(SecurityAccessor accessor, String resourceEntity, Access access);\n\n boolean canAccess(SecurityAccessor accessor, String resourceEntity, Access access, Object... instances);\n\n void checkAccess(SecurityAccessor accessor, String resourceEntity, Access access) throws NoPermissionException;\n\n void checkAccess(SecurityAccessor accessor, String resourceEntity, Access access, Object... instances) throws NoPermissionException;\n\n boolean canAccessMappedResource(SecurityAccessor accessor, String mappedResource, Access access);\n\n void setAuthorityProvider(IAuthorityProvider provider);\n}", "public Contract create(){\n\t\treturn new Contract();\n\t}" ]
[ "0.8372126", "0.65761405", "0.6514828", "0.591147", "0.5898078", "0.58499986", "0.5760196", "0.56837964", "0.56692207", "0.56687546", "0.55524665", "0.54941416", "0.54818153", "0.5446256", "0.5438497", "0.5374959", "0.53495646", "0.5340338", "0.532247", "0.5322122", "0.5225234", "0.52042896", "0.5199466", "0.5185288", "0.51794094", "0.5176127", "0.5163261", "0.5134264", "0.51311415", "0.5125529", "0.5108728", "0.51035017", "0.5097398", "0.5090411", "0.5086978", "0.50855887", "0.5078055", "0.5061211", "0.5036936", "0.50340176", "0.5033926", "0.5033926", "0.5033926", "0.5033498", "0.5030926", "0.5025628", "0.5024006", "0.5008017", "0.49969986", "0.4990348", "0.49873808", "0.49837503", "0.49759647", "0.49711773", "0.49617988", "0.4955888", "0.49123386", "0.48942134", "0.48842415", "0.48786905", "0.48774457", "0.48548573", "0.48540688", "0.48472485", "0.4841263", "0.48327902", "0.48326927", "0.4831698", "0.4827712", "0.4819376", "0.48123014", "0.48094028", "0.48070756", "0.48010945", "0.4795806", "0.47836825", "0.47829333", "0.47745436", "0.4767528", "0.47673666", "0.47664458", "0.47637314", "0.47637314", "0.4763604", "0.4762005", "0.47559404", "0.4751773", "0.47465268", "0.47465268", "0.47443113", "0.47426963", "0.47354087", "0.47300106", "0.4728243", "0.4724867", "0.4724746", "0.47189456", "0.4708282", "0.4708282", "0.47042096", "0.4696077" ]
0.0
-1
Driver for the EchoServer Engine
public static void main(String[] args) throws IOException { ServerSocket serverSocket = null; Socket clientSocket = null; BufferedReader read = null; DataOutputStream write = null; // Attempt to open a server socket for inbound connections try { serverSocket = new ServerSocket(SERVERPORT); } catch (IOException e) { System.err.println("Failed to open server socket"); e.printStackTrace(); System.exit(1); } // Wait for a client to connect System.out.println("Waiting ..."); try { // This will block until someone trys to connect clientSocket = serverSocket.accept(); // Get our input and output classes read = new BufferedReader(new InputStreamReader(clientSocket.getInputStream())); write = new DataOutputStream(clientSocket.getOutputStream()); System.out.println("Client connection from " + clientSocket.getInetAddress()); // This will continue until the clients types "/quit" or otherwise drops the connection Scanner writer = new Scanner(System.in); while (true) { // String line = read.readLine(); // System.out.println(line); // if ("/quit".equalsIgnoreCase(line)) { // System.out.println("Closing connection with " + clientSocket.getInetAddress()); // break; // } Thread t = new ClientTaker(clientSocket, read, write); // System.out.printf("-> "); // line = writer.nextLine(); // line += "\r\n"; // write.writeBytes(line); t.start(); } } catch (SocketException e) { System.out.println("Client connection was disconnected"); } catch (IOException e) { e.printStackTrace(); } finally { read.close(); write.close(); serverSocket.close(); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SocketEchoServer(SourceModule module)\r\n {\r\n super(module);\r\n }", "public interface SocketControl {\n\n /**\n * 获取服务的IP和端口\n * @return 格式:ip:port,如127.0.0.1:8080\n */\n String getIpPort();\n\n /**\n * 获取服务的ServiceId\n * @return 服务的ServiceId\n */\n String getServiceId();\n\n /**\n * 获取服务的InstanceId\n * @return 服务的InstanceId\n */\n String getInstanceId();\n\n\n /**\n * 获取模块名称,也可以直接调用getIpPort()\n * @return 模块名称\n */\n String getModelName();\n\n\n /**\n * 模块下连接的标示\n * @param channel 管道对象\n * @return uk\n */\n String getUniqueKey(Channel channel);\n\n\n /**\n * 模块下连接的标示\n * @param ctx 管道对象\n * @return uk\n */\n String getUniqueKey(ChannelHandlerContext ctx);\n\n\n /**\n * 绑定key\n * @param ctx 当前连接对象\n * @param key key\n */\n void bindKey(ChannelHandlerContext ctx,String key);\n\n /**\n * 绑定key\n * @param ctx 当前连接对象\n * @param key key\n */\n void bindKey(Channel ctx,String key);\n\n /**\n * 获取key\n * @param ctx 当前链接对象\n * @return key\n */\n String getKey(Channel ctx);\n\n /**\n * 获取key\n * @param ctx 当前链接对象\n * @return key\n */\n String getKey(ChannelHandlerContext ctx);\n\n\n /**\n * 重置心跳时间\n * @param ctx 当前连接对象\n * @param heartTime 心跳时间(秒)\n */\n void resetHeartTime(Channel ctx,int heartTime);\n\n\n\n}", "public EchoClientHandler()\n {\n String data = \"hello zhang kylin \" ;\n firstMessage = Unpooled.buffer(2914) ;\n firstMessage.writeBytes(data.getBytes()) ;\n }", "S getServer();", "messages.Serverhello.ServerHello getServerHello();", "@Override\n\tpublic void handleServerCmd() {\n\t\t\n\t}", "public static void main(String [] args) {\n\t\t//System.load(\"/usr/local/src/freeswitch/libs/esl/java/libesljni.so\");\n\t\tSystem.load(\"/usr/local/freeswitch/scripts/Mod_CallCenterScripts/libesljni.so\");\n\t\tESLconnection con = new ESLconnection(\"127.0.0.1\",\"8021\",\"ClueCon\");\n\t//\tESLconnection con = new ESLconnection(\"10.128.83.112\",\"8021\",\"ClueCon\");\n\t\tESLevent evt;\n\t\tif (con.connected() == 1) System.out.println(\"connected\");\n\t\tcon.events(\"plain\",\"all\");\n\t\t\n\t\tint mode =0;\n\t\twhile (con.connected() == 1) {\t\t\t\t\t\t\n\t\t\t// Get an event - recvEvent will block if nothing is queued\n\t\t\tevt = con.recvEvent();\n\t\t\t//System.out.println(evt.serialize(\"plain\"));\n\t\t\tString str = \"\";\n\t\t\t//System.out.println(\"Got the body as :\"+str);\n\t\t\tstr = evt.getHeader(\"Event-Name\",-1);\n\t\t\tif(str==null){\n\t\t\t\tSystem.out.println(\"Got nul event skipping\");\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\tif(str.equals(\"CUSTOM\")){\n\t\t\t\t//System.out.println(\"Got a Custom event\"+str);\n\t\t\t\tstr = evt.getHeader(\"Event-Subclass\",-1);\n\t\t\t\tif(str.equals(\"callcenter::info\")){\n\t\t\t\t\tSystem.out.println(\"Got a CallCenter event\"+str);\n\t\t\t\t\tstr = evt.getHeader(\"CC-Action\",-1);\n\t\t\t\t\t//System.out.println(evt.serialize(\"plain\"));\n\t\t\t\t\tif(str.equals(\"member-queue-start\")){\n\t\t\t\t\t\tSystem.out.println(\"Someone entering the queue \"+str);\n\t\t\t\t\t\t//CC-Queue: support@default\n\t\t\t\t\t\t//CC-Action: member-queue-start\n\t\t\t\t\t\t//CC-Member-UUID: 453324f8-3424-4322-4242362fd23d \n\t\t\t\t\t\t//CC-Member-Session-UUID: b77c49c2-a732-11df-9438-e7d9456f8886\n\t\t\t\t\t\t//CC-Member-CID-Name: CHOUINARD MO\n\t\t\t\t\t\t//CC-Member-CID-Number: 4385551212\n\t\t\t\t\t\tString Caller = evt.getHeader(\"CC-Member-CID-Number\",-1);\n\t\t\t\t\t\tif(Caller.startsWith(\"11\")){\n\t\t\t\t\t\t\tCaller = Caller.substring(2);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(Caller.length()>10){\n\t\t\t\t\t\tCaller = Caller.substring(Caller.length()-10);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tString Query=\"Insert into Announcement(Number, Date, Mtype,Textualdate,CallUUID) value('\"+Caller+\"',NOW(),'M\"+mode+\"','\"+evt.getHeader(\"CC-Member-UUID\",-1)+\"','\"+evt.getHeader(\"CC-Member-Session-UUID\",-1)+\"')\";\n\t\t\t\t\t\tString Mesg= evt.getHeader(\"CC-Member-Session-UUID\",-1)+\",\";\n\t\t\t\t\t\t\t\tMesg+=updateandReturn(Query);\n\t\t\t\t\t\tif(mode<5){\n\t\t\t\t\t\t\tif(mode==0){\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t//SimpleMessage p = new SimpleMessage(Mesg);\n\t\t\t\t\t\t\t\t//Thread th = new Thread(p);\n\t\t\t\t\t\t\t\t//th.start();\n\t\t\t\t\t\t\t}else if(mode==1){\n\t\t\t\t\t\t\t\tPosition p = new Position(Mesg);\n\t\t\t\t\t\t\t\tThread th = new Thread(p);\n\t\t\t\t\t\t\t\tth.start();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse if(mode==2){\n\t\t\t\t\t\t\t\tSimpleTime p = new SimpleTime(Mesg);\n\t\t\t\t\t\t\t\tThread th = new Thread(p);\n\t\t\t\t\t\t\t\tth.start();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse if(mode==3){\n\t\t\t\t\t\t\t\tDynamicTime p = new DynamicTime(Mesg);\n\t\t\t\t\t\t\t\tThread th = new Thread(p);\n\t\t\t\t\t\t\t\tth.start();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse if(mode==4){\n\t\t\t\t\t\t\t\tManipulatedTime p = new ManipulatedTime(Mesg);\n\t\t\t\t\t\t\t\tThread th = new Thread(p);\n\t\t\t\t\t\t\t\tth.start();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t//\tmessage_announce(evt.getHeader(\"CC-Member-Session-UUID\",-1));\n\t\t\t\t\t\tmode++;\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t if(mode==5){\n\t\t\t\t\t\t\t\t\tSimpleMessage p = new SimpleMessage(Mesg);\n\t\t\t\t\t\t\t\t\tThread th = new Thread(p);\n\t\t\t\t\t\t\t\t\tth.start();\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tmode=0;\n\t\t\t\t\t\t}\n//\t\t\t\t\t\tSystem.out.println(evt.serialize(\"plain\"));\n\t\t\t\t\t\t//String Query=\"Insert into calls(StartTime, Number, Bound, TextualDate, CallUUID) values(Now(),'\"+Caller+\"','IN','\"+evt.getHeader(\"CC-Member-UUID\",-1)+\"','\"+evt.getHeader(\"CC-Member-Session-UUID\",-1)+\"')\";\n\t//update(Query);\n\t\t\t\t\t\t\t\t\t\n\t}\n\t\t\n\t\t\t\t}else{\n\t\t\t\t//\tSystem.out.println(\"EVent Subclass is \"+ str);\n\t//\t\t\t\tSystem.out.println(evt.serialize(\"plain\"));\n\t\t\t\t}\n\t\t\t}else{\n//\t\t\t\tSystem.out.println(evt.serialize(\"plain\"));\n\t\t\t}\n\n\t\t\t// Print the entire event in key : value format. serialize() according to the wiki usually takes no arguments\n\t\t\t// but if you do not put in something you will not get any output so I just stuck plain in.\t\t\t\n\n\t\t}\n\t}", "public static void main(String [] args) {\n\t\tSystem.load(\"/usr/local/src/freeswitch/libs/esl/java/libesljni.so\");\n\tSystem.load(\"/usr/local/freeswitch/scripts/Mod_CallCenterScripts/libesljni.so\");\n\t\t/*\n\t\t *\n\t\t * Trying to keep this simple (and I'm no java expert) I am instantiating the ESLconnection and\n\t\t * ESLevent object in a static reference here so remember if you don't plan on doing everything in main\n\t\t * you will need to instantiate your class first or you will get compile-time errors.\n\t\t *\n\t\t */\n\n\t\tESLconnection con = new ESLconnection(\"10.128.83.112\",\"8021\",\"ClueCon\");\n\n\t\tESLevent evt;\n\n\t\tif (con.connected() == 1) System.out.println(\"connected\");\n\t\tcon.events(\"plain\",\"all\");\n\n\t\t// Loop while connected to the socket -- not sure if this method is constantly updated so may not be a good test\n\t\twhile (con.connected() == 1) {\t\t\t\n\t\t\t// Get an event - recvEvent will block if nothing is queued\n\t\t\tevt = con.recvEvent();\n\t\t\t//System.out.println(evt.serialize(\"plain\"));\n\t\t\tString str = evt.getBody();\n\t\t\tSystem.out.println(\"Got the body as :\"+str);\n\t\t\tstr = evt.getHeader(\"Event-Name\",-1);\n\t\t\tif(str.equals(\"CUSTOM\")){\n\t\t\t\tSystem.out.println(\"Got a Custom event\"+str);\n\t\t\t\tstr = evt.getHeader(\"Event-Subclass\",-1);\n\t\t\t\tif(str.equals(\"callcenter::info\")){\n\t\t\t\t\tSystem.out.println(\"Got a CallCenter event\"+str);\n\t\t\t\t\tstr = evt.getHeader(\"CC-Action\",-1);\n\t\t\t\t\tif(str.equals(\"member-queue-end\")){\n\t\t\t\t\t\tSystem.out.println(\"Someone Leaving the queue \"+str);\n\t\t\t\t\t\t//CC-Queue: support@default\n\t\t\t\t\t\t//CC-Action: member-queue-start\n\t\t\t\t\t\t//CC-Member-UUID: 453324f8-3424-4322-4242362fd23d \n\t\t\t\t\t\t//CC-Member-Session-UUID: b77c49c2-a732-11df-9438-e7d9456f8886\n\t\t\t\t\t\t//CC-Member-CID-Name: CHOUINARD MO\n\t\t\t\t\t\t//CC-Member-CID-Number: 4385551212\n\t\t\t\t\t\tString Caller = evt.getHeader(\"CC-Member-CID-Number\",-1);\n\t\t\t\t\t\tif(Caller.startsWith(\"11\")){\n\t\t\t\t\t\t\tCaller = Caller.substring(2);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(Caller.length()>10){\n\t\t\t\t\t\tCaller = Caller.substring(Caller.length()-10);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tString jointime = evt.getHeader(\"CC-Member-Joined-Time\", -1);\n\t\t\t\t\t\tString leavtime = evt.getHeader(\"CC-Member-Leaving-Time\", -1);\n\t\t\t\t\t\tLong Queuetime = (long) 0;\n\t\t\t\t\t\t\t\tLong CallDuration=(long) 0;\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\tif(evt.getHeader(\"CC-Cause\", -1).trim().indexOf(\"Terminated\")>-1){\n\t\t\t\t\t\t\tString anstime = evt.getHeader(\"CC-Agent-Answered-Time\", -1);\n\t\t\t\t\t\t\t//String hookofftime = evt.getHeader(\"CC-Member-Leaving-Time\", -1);\n\t\t\t\t\t\t\tQueuetime = Long.parseLong(anstime)- Long.parseLong(jointime);\n\t\t\t\t\t\t\tCallDuration = Long.parseLong(leavtime)- Long.parseLong(anstime);\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\tQueuetime=Long.parseLong(leavtime)- Long.parseLong(jointime);\n\t\t\t\t\t\t}\n\t\t//String Query=\"Insert into calls(StartTime, Number, Bound, TextualDate, CallUUID) values(Now(),'\"+Caller+\"','IN','\"+evt.getHeader(\"CC-Member-UUID\",-1)+\"','\"+evt.getHeader(\"CC-Member-Session-UUID\",-1)+\"')\";\n\t String Query = \"Update calls set QueueTime=\"+Queuetime +\" , Duration=\"+CallDuration+\" where TextualDate='\"+evt.getHeader(\"CC-Member-UUID\",-1) +\"' and CallUUID='\"+evt.getHeader(\"CC-Member-Session-UUID\",-1)+\"'\";\n\t\tSystem.out.println(Query);\n\t update(Query);\n\t\t\t\t\t}\n\t\t\n\t\t\t\t}else{\n\t\t\t\t\tSystem.out.println(\"EVent Subclass is \"+ str);\n\t//\t\t\t\tSystem.out.println(evt.serialize(\"plain\"));\n\t\t\t\t}\n\t\t\t}else{\n//\t\t\t\tSystem.out.println(evt.serialize(\"plain\"));\n\t\t\t}\n\n\t\t\t// Print the entire event in key : value format. serialize() according to the wiki usually takes no arguments\n\t\t\t// but if you do not put in something you will not get any output so I just stuck plain in.\n\t\t\t\n\n\t\t}\n\t\t\n\t}", "public interface ISocketEchoServer extends ISocketServer\r\n{\r\n\r\n}", "public static void main(String[] args) throws Exception {\n TelepathyAPI.initialize(\"127.0.0.1\", 6387);\n System.out.println(\"Waiting for message\");\n\n /*BufferedInputStream inputStream = new BufferedInputStream(socket.getInputStream());\n while (true) {\n if (inputStream.available() > 0) {\n int i = inputStream.read();\n System.out.print(i);\n if ((i >= 32 && i <= 126) || (i >= 9 && i <= 13)) {\n System.out.println(\"\\t\" + (char) i);\n } else {\n System.out.println();\n }\n }\n }*/\n\n TelepathyAPI.addNewMessageListener(message -> {\n System.out.println(\"Message received\");\n System.out.println(message.key);\n System.out.println(message.type);\n System.out.println(message.message);\n TelepathyAPI.shutdown();\n });\n }", "public void run() {\n ServerSocketChannelFactory acceptorFactory = new OioServerSocketChannelFactory();\n ServerBootstrap server = new ServerBootstrap(acceptorFactory);\n\n // The pipelines string together handlers, we set a factory to create\n // pipelines( handlers ) to handle events.\n // For Netty is using the reactor pattern to react to data coming in\n // from the open connections.\n server.setPipelineFactory(new EchoServerPipelineFactory());\n\n server.bind(new InetSocketAddress(port));\n }", "public void startServer(PWModelDetails pwModelDetails) {\n try {\n List<ServerSap> serverSaps = null;\n try {\n serverSaps = ServerSap.getSapsFromSclFile(pwModelDetails.getSclFileName());\n } catch (SclParseException e) {\n logger.info(\"Error parsing SCL/ICD file: \" + e.getMessage());\n e.printStackTrace();\n return;\n }\n serverSap = serverSaps.get(0);\n serverSap.setPort(pwModelDetails.getPortNumber());\n\n InetAddress address = null;\n try {\n ipAddress = pwModelDetails.getIpAddress();\n address = InetAddress.getByName(ipAddress);\n } catch (UnknownHostException e) {\n logger.info(\"Unknown host: \" + ipAddress);\n logger.info(\"Proxy will run with the defualt IP as define in the SCL file.\");\n logger.info(\"Unknown host \" + ipAddress);\n return;\n }\n if (address != null) {\n serverSap.setBindAddress(address);\n }\n Runtime.getRuntime().addShutdownHook(new Thread() {\n @Override\n public void run() {\n if (serverSap != null) {\n serverSap.stop();\n }\n logger.info(\"Server was stopped\");\n }\n });\n ServerModel serverModel = serverSap.getModelCopy();\n// create a SampleServer instance that can be passed as a callback object to startListening() and\n// SmartPowerIEDServer sampleServer = new SmartPowerIEDServer();\n SoftGridIEDServer sampleServer = this;\n// Open MUC initialization\n List<BasicDataAttribute> branchCircuitBreakerVals = new ArrayList<BasicDataAttribute>(3);\n for (String reference : iedRefFcHashMap.keySet()) {\n BasicDataAttribute field = (BasicDataAttribute) serverModel.findModelNode(reference, iedRefFcHashMap.get(reference));\n if (field == null) {\n logger.info(\">>>>>> Error in obtaining SCL reference object = \" + reference);\n }\n branchCircuitBreakerVals.add(field);\n }\n// Power World Device Initialization\n ParameterGenerator parameterGenerator = new ParameterGenerator();\n parameterGenerator.setSclKeyToPWKeyMap(pwModelDetails.getSclToPWMapping());\n parameterGenerator.setKeyParameters(pwModelDetails.getKeyArray());\n parameterGenerator.setValueParameters(pwModelDetails.getDataFieldArray());\n parameterGenerator.setPersistedValues(pwModelDetails.getValueArray());\n parameterGenerator.setDeviceObjectName(pwModelDetails.getDeviceName());\n if (controlAPI == null) {\n controlAPI = IedControlerFactory.getPWComBridgeIterface();\n synchronized (controlAPI) {\n if (!controlAPI.isCaseOpened()) {\n controlAPI.openCase();\n }\n }\n }\n parameterGenerator.setControlAPI(controlAPI);\n// load power world data\n serverSap.startListening(sampleServer, parameterGenerator);\n try {\n serverSap.setValues(branchCircuitBreakerVals);\n } catch (Exception e) {\n logger.info(\"pwModelDetails.getModelNodeReference() = \" + pwModelDetails.getModelNodeReference());\n e.printStackTrace();\n }\n\n String[][] paramPack = parameterGenerator.getParamPack();\n type = IEDUtils.getIEDType(parameterGenerator.getDeviceObjectName());\n id = ++IED_COUNT;\n StringBuffer sb = new StringBuffer();\n String logDataSeperator = \":\";\n boolean loged = false;\n logEvent(\"IED : \" + type.name() + \" : \" + id + \" is Started...!\");\n String[] elements = null;\n while (true) {\n synchronized (this) {\n try {\n Thread.sleep(PW_INTERROGATION_INTERVAL);\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }\n\n elements = parameterGenerator.loadDataValues(paramPack);\n if (elements == null) {\n if(type.name().equals(\"BUS\"))\n {\n System.out.println(\"BUS\");\n }\n continue;\n }\n sb.append(\"Type:\").append(type.name());\n for (int i = 0; i < branchCircuitBreakerVals.size(); i++) {\n BasicDataAttribute modelNodes = branchCircuitBreakerVals.get(i);\n if (modelNodes != null && elements.length > i) {\n String pwKeyName = null;\n for (String sclKey : parameterGenerator.getSclKeyToPWKeyMap().keySet()) {\n if (modelNodes.getReference().toString().endsWith(sclKey)) {\n pwKeyName = sclKey;\n }\n }\n if (pwKeyName == null) {\n continue;\n }\n for (int j = 0; j < paramPack[0].length; j++) {\n if (!loged) {\n sb.append(logDataSeperator).append(paramPack[0][j]).append(logDataSeperator).append(elements[j]);\n }\n if (parameterGenerator.getSclKeyToPWKeyMap().get(pwKeyName).equals(paramPack[0][j])) {\n if (modelNodes instanceof BdaDoubleBitPos) {\n byte[] status = new byte[1];\n if (elements[j].equalsIgnoreCase(\"open\")) {\n status[0] = 0;\n } else {\n status[0] = 1;\n }\n ((BdaDoubleBitPos) modelNodes).setValue(status);\n } else if (modelNodes instanceof BdaVisibleString) {\n ((BdaVisibleString) modelNodes).setValue(elements[j]);\n } else if (modelNodes instanceof BdaFloat32) {\n ((BdaFloat32) modelNodes).setFloat(Float.parseFloat(elements[j]));\n }\n }\n }\n loged = true;\n }\n }\n serverStarted = true;\n// synchronized (logger) {\n// if (ConfigUtil.MANUAL_EXPERIMENT_MODE) {\n // if this string is not printed in the log file,\n logger.info(sb.toString());\n// }\n// }\n sb = new StringBuffer(\"\");\n loged = false;\n serverSap.setValues(branchCircuitBreakerVals);\n if (serverStoped) {\n serverStarted = false;\n break;\n }\n }\n } catch (Exception e) {\n e.printStackTrace();\n }\n }", "public static void main(String[] args) {\n try (BufferedReader br = new BufferedReader(new FileReader(\"src/main/resources/jel.log\"))) {\n String line = br.readLine();\n\n JsonNode root;\n JsonNode event;\n if (line != null) {\n //prepare the connection\n OtpNode node = new OtpNode(\"java\");\n OtpMbox mbox = node.createMbox(\"myMailbox\");\n String defaultServerNodeName = \"myserver@\" + node.host();\n System.out.format(\"Server Node to contact [%s]> \", defaultServerNodeName);\n OtpErlangTuple serverPidTuple = new OtpErlangTuple(new OtpErlangObject[]{new OtpErlangAtom(\"server\"), new OtpErlangAtom(defaultServerNodeName)});\n if (!node.ping(defaultServerNodeName, 1000)) {\n System.out.println(\"Erlang node is not available: \" + defaultServerNodeName);\n return;\n }\n\n root = mapper.readTree(line);\n event = root.get(\"Event\");\n\n //prepare the representation expected by Erlang and send\n OtpErlangList erlangStruct = convertObjectNode(event);\n sendMessage(mbox, \"server\", defaultServerNodeName, serverPidTuple, erlangStruct);\n\n while ((line = br.readLine()) != null) {\n root = mapper.readTree(line);\n event = root.get(\"Event\");\n\n //prepare the representation expected by Erlang and send\n erlangStruct = convertObjectNode(event);\n sendMessage(mbox, \"server\", defaultServerNodeName, serverPidTuple, erlangStruct);\n }\n }\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "public static void main (String[] arg) throws Exception {\n\t\t//TCPRelay relay = new TCPRelay (arg[0], Integer.parseInt(arg[1]));\n\t\t//relay.start();\n\t\t// EC2 server 67.202.42.132\n\t\tString hostname = arg[0];\n\t\tint port = Integer.parseInt(arg[1]);\n\t\t\n\t\tSocket socket = new Socket(hostname,port);\n\t\tInputStream in = socket.getInputStream();\n\t\tOutputStream out = socket.getOutputStream();\n\t\t\n\t\tString packetStr = \"11 09 10 00 00 50 c2 10 00 63 20 40 0a 01 00 00 01 04 00 00 10 1a 00 00 00 01 00 02 00 03 00 04 00 05 00 06 00 07 00\";\n\t\tbyte[] packet = ByteFormatUtils.stringToByteArray(packetStr);\n\t\tSystem.err.println (\"packet=\" + packet);\n\t\tSystem.err.println (\"packetLen=\" + packet.length);\n\t\twhile (true) {\n\t\t\tSystem.err.println (\"Writing \" + packetStr);\n\t\t\tXBeeUtil.writeAPIFrameToStream(packet, packet.length, out);\n\t\t\tout.flush();\n\t\t\t\n\t\t\tThread.sleep(5000);\n\t\t}\n\t}", "public static void echo_server_single( int portno ) \nthrows IOException\n {\n ServerSocket acc = new ServerSocket( portno );\n print_my_host_port( portno );\n while( true )\n {\n stdout.printf(\"accepting incoming connections (hash== %s) ...\\n\", \n acc.hashCode());\n Socket com = acc.accept();\n tcp_peeraddr_print( com );\n EchoServerWorker esw = new EchoServerWorker(com);\n esw.run();\n } // while\n}", "public interface NettyProxyService {\n /**\n * 心跳\n *\n * @param msg\n * @throws Exception\n */\n void processHeartbeatMsg(HeartbeatMsg msg) throws Exception;\n\n /**\n * 上传位置\n *\n * @param msg\n * @throws Exception\n */\n void processLocationMsg(LocationMsg msg) throws Exception;\n\n /**\n * 离线\n *\n * @param deviceNumber\n */\n void processInactive(String deviceNumber);\n}", "public interface ServerDriver {\n void start() throws Exception;\n\n void stop() throws Exception;\n\n void stopAtShutdown();\n\n void assertArrivedRequestMatching(Matcher<RequestSnapshot>... matchers) throws InterruptedException;\n\n String baseUrl();\n\n void respondAs(String content);\n}", "public void conectServer() {\n\n\t}", "public static void main(String[] args) \n {\n int port = DEFAULT_PORT; //Port to listen on\n\n\n ServerGui serverGui = new ServerGui();\n serverGui.setVisible(true);\n serverGui.setSize(450, 300);\n \n \n //----------------------------------\n // EchoServer sv = new EchoServer(port);\n \n }", "private static void runTest(SSLEngine ssle) throws Exception {\n byte[] msg_clihello = {\n (byte)0x16, (byte)0x03, (byte)0x01, (byte)0x00,\n (byte)0x6f, (byte)0x01, (byte)0x00, (byte)0x00,\n (byte)0x6b, (byte)0x03, (byte)0x01, (byte)0x48,\n (byte)0x90, (byte)0x71, (byte)0xfc, (byte)0xf9,\n (byte)0xa2, (byte)0x3a, (byte)0xd7, (byte)0xa8,\n (byte)0x0b, (byte)0x25, (byte)0xf1, (byte)0x2b,\n (byte)0x88, (byte)0x80, (byte)0x66, (byte)0xca,\n (byte)0x07, (byte)0x78, (byte)0x2a, (byte)0x08,\n (byte)0x9d, (byte)0x62, (byte)0x1d, (byte)0x89,\n (byte)0xc9, (byte)0x1e, (byte)0x1f, (byte)0xe5,\n (byte)0x92, (byte)0xfe, (byte)0x8d, (byte)0x00,\n (byte)0x00, (byte)0x24, (byte)0x00, (byte)0x88,\n (byte)0x00, (byte)0x87, (byte)0x00, (byte)0x39,\n (byte)0x00, (byte)0x38, (byte)0x00, (byte)0x84,\n (byte)0x00, (byte)0x35, (byte)0x00, (byte)0x45,\n (byte)0x00, (byte)0x44, (byte)0x00, (byte)0x33,\n (byte)0x00, (byte)0x32, (byte)0x00, (byte)0x41,\n (byte)0x00, (byte)0x04, (byte)0x00, (byte)0x05,\n (byte)0x00, (byte)0x2f, (byte)0x00, (byte)0x16,\n (byte)0x00, (byte)0x13, (byte)0xfe, (byte)0xff,\n (byte)0x00, (byte)0x0a, (byte)0x01, (byte)0x00,\n (byte)0x00, (byte)0x1e, (byte)0x00, (byte)0x00,\n (byte)0x00, (byte)0x16, (byte)0x00, (byte)0x14,\n (byte)0x00, (byte)0x00, (byte)0x11, (byte)0x6a,\n (byte)0x75, (byte)0x73, (byte)0x74, (byte)0x69,\n (byte)0x6e, (byte)0x2e, (byte)0x75, (byte)0x6b,\n (byte)0x2e, (byte)0x73, (byte)0x75, (byte)0x6e,\n (byte)0x2e, (byte)0x63, (byte)0x6f, (byte)0x6d,\n (byte)0x00, (byte)0x23, (byte)0x00, (byte)0x00\n };\n ByteBuffer bf_clihello = ByteBuffer.wrap(msg_clihello);\n\n SSLSession session = ssle.getSession();\n int appBufferMax = session.getApplicationBufferSize();\n int netBufferMax = session.getPacketBufferSize();\n\n ByteBuffer serverIn = ByteBuffer.allocate(appBufferMax + 50);\n ByteBuffer serverOut = ByteBuffer.wrap(\"I'm Server\".getBytes());\n ByteBuffer sTOc = ByteBuffer.allocate(netBufferMax);\n\n ssle.beginHandshake();\n\n // unwrap the clientHello message.\n SSLEngineResult result = ssle.unwrap(bf_clihello, serverIn);\n System.out.println(\"server unwrap \" + result);\n runDelegatedTasks(result, ssle);\n\n // one more step, ensure the clientHello message is parsed.\n SSLEngineResult.HandshakeStatus status = ssle.getHandshakeStatus();\n if ( status == HandshakeStatus.NEED_UNWRAP) {\n result = ssle.unwrap(bf_clihello, serverIn);\n System.out.println(\"server unwrap \" + result);\n runDelegatedTasks(result, ssle);\n } else if ( status == HandshakeStatus.NEED_WRAP) {\n result = ssle.wrap(serverOut, sTOc);\n System.out.println(\"server wrap \" + result);\n runDelegatedTasks(result, ssle);\n } else {\n throw new Exception(\"unexpected handshake status \" + status);\n }\n\n // enough, stop\n }", "public EchoClientHandler() {\n firstMessage = Unpooled.buffer(EchoClient.SIZE);\n for (int i = 0; i < firstMessage.capacity(); i ++) {\n firstMessage.writeByte((byte) i);\n }\n }", "public String getServer () throws java.io.IOException, com.linar.jintegra.AutomationException;", "public static void main(String[] args) throws Exception {\n\n ServerSocket socket = new ServerSocket(80);\n ServerSocketChannel channel = socket.getChannel();\n channel.configureBlocking(false);\n\n Selector selector = Selector.open();\n\n int interestSet = SelectionKey.OP_READ | SelectionKey.OP_WRITE;\n\n SelectionKey selectionKey = channel.register(selector, interestSet);\n\n String a = \"a\";\n\n selectionKey.attach(a);\n\n Object attachedObj = selectionKey.attachment();\n\n SelectionKey key = channel.register(selector, SelectionKey.OP_READ, a);\n\n selector.wakeup();\n\n }", "public static void main(String[] args) throws Exception {\n //TcpClient client = new TcpClient();\n System.out.println(\"Client Started\"); \n \n //test for infinite messages\n //client.infiniteHiTest();\n \n //test for 10 lac messages\n //client.definedForTest(1000000);\n \n //5000 messages with 45 sec delay\n //client.sendDataInDelay(5000,45000);\n \n \n Socket clientSocket = new Socket(\"localhost\", TcpServer.PORT); \n DataOutputStream outToServer = new DataOutputStream(clientSocket.getOutputStream());\n \n outToServer.writeUTF(\"HI from non mina\");\n outToServer.flush();\n \n \n \n \n \n //client.connector.dispose(true);\n \n }", "public static void main(String[] args) {\n\r\n\t\t\tnew EeeClient();\r\n\t\t\r\n\r\n\t\t\ttry {\r\n\t\t\t\tSocket socket = new Socket(\"192.168.1.19\", 7777);\r\n\r\n\t\t\t\tInputStream is = socket.getInputStream();\r\n\t\t\t\tDataInputStream dis = new DataInputStream(is);\r\n\r\n\t\t\t\tSystem.out.println(dis.readUTF());\r\n\t\t\t\tSystem.out.println(\"=========\");\r\n\t\t\t\t\r\n\r\n\t\t\t\tdis.close();\r\n\t\t\t\tis.close();\r\n\t\t\t\tsocket.close();\r\n\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\te.printStackTrace();\r\n\r\n\t\t\t}\r\n\r\n\t\t}", "private void run() throws IOException, InterruptedException {\n \t\t// InetSocketAddress endpoint = SocketAddresses.fromIp(\"10.95.162.221\",\r\n \t\t// 1234);\r\n \t\tInetSocketAddress endpoint = SocketAddresses.fromIp(\"127.0.0.1\", 1234);\r\n \r\n \t\tbyte[] buf = new byte[8 * 1024];\r\n \t\tnew Random().nextBytes(buf);\r\n \t\tByteBuffer seedBuffer = ByteBuffer.wrap(buf);\r\n \t\tNetContext context = new SimpleNetContext();\r\n \t\tEchoSession session = new EchoSession();\r\n \t\tconnection = TcpNetFactory.INSTANCE.openClient(context, endpoint, session);\r\n \r\n \t\tRuntime.getRuntime().addShutdownHook(new Thread() {\r\n \t\t\t@Override\r\n \t\t\tpublic void run() {\r\n \t\t\t\ttry {\r\n \t\t\t\t\tconnection.close();\r\n \t\t\t\t} catch (IOException e) {\r\n \t\t\t\t\t// TODO Auto-generated catch block\r\n \t\t\t\t\te.printStackTrace();\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t});\r\n \r\n \t\tfinal int loopTimeSec = 10;\r\n \t\tlong lastT = System.currentTimeMillis();\r\n \t\tconnection.sendBlocking(seedBuffer);\r\n \t\tlong seeded = seedBuffer.capacity();\r\n \t\tint loop = 1;\r\n \t\tlong lastRx = 0, lastTx = 0;\r\n \t\tfinal long start = System.currentTimeMillis();\r\n \r\n \t\twhile (connection.isConnected()) {\r\n \t\t\tlong sleepUntil = start + (loop * loopTimeSec * 1000L);\r\n \t\t\tThreadUtil.sleepUntilMs(sleepUntil);\r\n \r\n \t\t\tlong rx = session.getRx();\r\n \t\t\tlong tx = session.getTx();\r\n \t\t\tlong rxDiff = rx - lastRx;\r\n \t\t\tlong txDiff = tx - lastTx;\r\n \t\t\tlong diff = rxDiff + txDiff;\r\n \t\t\tlong now = System.currentTimeMillis();\r\n \t\t\tlong tDiff = now - lastT;\r\n\t\t\tdouble mbit = (diff * 8) / 10e6 / (tDiff / 1000f);\r\n\t\t\tdouble rxMb = (rxDiff / (2e20));\r\n\t\t\tdouble txMb = (txDiff / (2e20));\r\n \t\t\tSystem.out.printf(\"seed=%d, last %dsec rx=%.3fM, tx=%.3fM bytes => %.5f mbit/sec%n\", //\r\n \t\t\t\t\tseeded, loopTimeSec, rxMb, txMb, mbit);\r\n \t\t\tif (seeded < 512 * 1024) {\r\n \t\t\t\tSystem.out.println(\"seeding an additional \" + seedBuffer.capacity() + \" bytes into the echo chain\");\r\n \t\t\t\tseedBuffer.rewind();\r\n \t\t\t\tconnection.sendBlocking(seedBuffer);\r\n \t\t\t\tseeded += seedBuffer.capacity();\r\n \t\t\t}\r\n \t\t\t// if (rxDiff == 0 || txDiff == 0) {\r\n \t\t\t// session.forceWrite();\r\n \t\t\t// }\r\n \t\t\tloop++;\r\n \t\t\tlastRx = rx;\r\n \t\t\tlastTx = tx;\r\n \t\t\tlastT = now;\r\n \t\t}\r\n \t\t// TODO: save shutdown of clients\r\n \t\tSystem.exit(0);\r\n \t}", "public Server() {\n\t\tthis.currentMode = Mode.TEST; // TODO: implement\n\t}", "@Override\n public void run() {\n eventLoopGroup = EPOLL ? new EpollEventLoopGroup() : new NioEventLoopGroup();\n try {\n System.out.println(startServerMsg);\n LOGGER.info(startServerMsg);\n new ServerBootstrap()\n .group(eventLoopGroup)\n .channel(EPOLL ? EpollServerSocketChannel.class : NioServerSocketChannel.class)\n .childOption(ChannelOption.TCP_NODELAY, true)\n .childOption(ChannelOption.SO_KEEPALIVE,true)\n .childOption(ChannelOption.RCVBUF_ALLOCATOR,new AdaptiveRecvByteBufAllocator(1024,16*1024,1024*1024))\n .childHandler(new ChannelInitializer() {\n @Override\n protected void initChannel(Channel ch) {\n ChannelPipeline pipeline = ch.pipeline();\n pipeline.addLast(\"decoder\", new Decoder());\n pipeline.addLast(\"handler\",new TcpServerHandler(viewModel));\n }\n })\n .bind(port).sync().channel().closeFuture().syncUninterruptibly();\n } catch (InterruptedException e) {\n LOGGER.error(\"Failed to start server : \",e);\n e.printStackTrace();\n } finally {\n System.out.println(ANSI_RED+\"Server shutting down.\"+ANSI_RESET);\n LOGGER.info(\"Server shutting down.\");\n eventLoopGroup.shutdownGracefully();\n\n }\n }", "public static void main(String args[]) throws UnknownHostException, SocketException {\n DHT dhtObj = new DHT();\n dhtObj.provideService();\n\n }", "public static void main(String[] args) throws Exception {\n\tint port = 8989;\n\t \n AsynchronousServerSocketChannel server = AsynchronousServerSocketChannel\n .open();\n InetSocketAddress sAddr = new InetSocketAddress(port);\n server.bind(sAddr);\n System.out.format(\"Server is listening at %s%n\", sAddr);\n \n InetAddress iAddress = InetAddress.getLocalHost();\n String currentIp = iAddress.getHostAddress();\n System.out.println(\"Current IP address : \" +currentIp); //gives only host address\n \n DesertedServer dserver = new DesertedServer(server);\n Attachment attach = new Attachment();\n attach.server = dserver;\n server.accept(attach, new ConnectionHandler());\n Thread.currentThread().join();\n }", "public void run() throws IOException {\n @SuppressWarnings(\"resource\")\n //Listens for a connection on the port number.\n ServerSocket s0 = new ServerSocket(PORT_NUMBER);\n Socket s = s0.accept();\n\n //Sets up the buffers to read and to write on the socket.\n BufferedReader r = new BufferedReader(new InputStreamReader(\n s.getInputStream(), StandardCharsets.UTF_8));\n BufferedWriter w = new BufferedWriter(new OutputStreamWriter(\n s.getOutputStream(), StandardCharsets.UTF_8));\n \n \n String command;\n\n //Reads the commands wrote on the socket line per line\n while ((command = r.readLine()) != null) {\n String[] msg = split(' ', command);\n\n switch (JassCommand.valueOf(msg[COMMAND_INDEX])) {\n\n case PLRS:\n \n //Creates the players map with the arguments and calls the setPlayers function of the underlyingPlayer.\n Map<PlayerId, String> players = new HashMap<>();\n for (int i = 0; i < PlayerId.COUNT; i++) {\n players.put(PlayerId.ALL.get(i),\n deserializeString(split(',', msg[ARG_2_INDEX])[i]));\n }\n localPlayer.setPlayers(PlayerId.ALL.get(deserializeInt(msg[ARG_1_INDEX])),\n players);\n break;\n\n case CARD:\n \n //Calls the cardToPlay function of the underlying function with the arguments of the message.\n String[] st = split(',', msg[ARG_1_INDEX]);\n TurnState state = TurnState.ofPackedComponents(\n deserializeLong(st[ARG_0_INDEX]), deserializeLong(st[ARG_1_INDEX]),\n deserializeInt(st[ARG_2_INDEX]));\n Card c = localPlayer.cardToPlay(state,\n CardSet.ofPacked(deserializeLong(msg[ARG_2_INDEX])));\n w.write(serializeInt(c.packed()));\n w.newLine();\n w.flush();\n break;\n\n case HAND: \n localPlayer\n .updateHand(CardSet.ofPacked(deserializeLong(msg[ARG_1_INDEX])));\n break;\n\n case TRMP:\n localPlayer.setTrump(Color.ALL.get(deserializeInt(msg[ARG_1_INDEX])));\n break;\n\n case SCOR:\n localPlayer\n .updateScore(Score.ofPacked(deserializeLong(msg[ARG_1_INDEX])));\n break;\n\n case TRCK:\n localPlayer.updateTrick(Trick.ofPacked(deserializeInt(msg[ARG_1_INDEX])));\n break;\n\n case WINR:\n localPlayer\n .setWinningTeam(TeamId.ALL.get(deserializeInt(msg[ARG_1_INDEX])));\n break;\n\n default:\n }\n }\n }", "@Override\n public void run() {\n ServerChannel channel;\n if (socketFactory == null) {\n socketFactory = this;\n }\n serverLoop : while (!shutdown) {\n try {\n serverSocket = socketFactory.createServerSocket(port);\n\n Logger.log (new LogEvent (this, \"iso-server\",\n \"listening on \" + (bindAddr != null ? bindAddr + \":\" : \"port \") + port\n + (backlog > 0 ? \" backlog=\"+backlog : \"\")\n ));\n while (!shutdown) {\n try {\n if (pool.getAvailableCount() <= 0) {\n try {\n serverSocket.close();\n fireEvent(new ISOServerShutdownEvent(this));\n } catch (IOException e){\n Logger.log (new LogEvent (this, \"iso-server\", e));\n relax();\n }\n\n for (int i=0; pool.getIdleCount() == 0; i++) {\n if (shutdown) {\n break serverLoop;\n }\n if (i % 240 == 0 && cfg.getBoolean(\"pool-exhaustion-warning\", true)) {\n LogEvent evt = new LogEvent (this, \"warn\");\n evt.addMessage (\n \"pool exhausted \" + serverSocket.toString()\n );\n evt.addMessage (pool);\n Logger.log (evt);\n }\n ISOUtil.sleep (250);\n }\n serverSocket = socketFactory.createServerSocket(port);\n }\n channel = (ServerChannel) clientSideChannel.clone();\n channel.accept (serverSocket);\n\n if (cnt[CONNECT]++ % 100 == 0) {\n purgeChannels ();\n }\n WeakReference wr = new WeakReference (channel);\n channels.put (channel.getName(), wr);\n channels.put (LAST, wr);\n pool.execute (createSession(channel));\n setChanged ();\n notifyObservers (this);\n fireEvent(new ISOServerAcceptEvent(this));\n if (channel instanceof Observable) {\n ((Observable)channel).addObserver (this);\n }\n } catch (SocketException e) {\n if (!shutdown) {\n Logger.log (new LogEvent (this, \"iso-server\", e));\n relax();\n continue serverLoop;\n }\n } catch (IOException e) {\n Logger.log (new LogEvent (this, \"iso-server\", e));\n relax();\n }\n } // while !shutdown\n } catch (Throwable e) {\n Logger.log (new LogEvent (this, \"iso-server\", e));\n relax();\n }\n }\n }", "@Test\n public void testServer() throws Exception{\n ServerMain s=new ServerMain(1,3,2,\"test\",InetAddress.getLocalHost(),null);\n uut=new ChatMessageRequest(\"test\",\"test2\",\"test\",MessageTypes.PM);\n uut.serverVisit(new Client(\"test\",s).getServerVisitor());\n\n uut=new ChatMessageRequest(\"test\",\"test2\",\"test\",MessageTypes.MATCH);\n uut.serverVisit(new Client(\"test\",s).getServerVisitor());\n\n uut=new ChatMessageRequest(\"test\",\"test2\",\"test\",MessageTypes.MATCH);\n uut.serverVisit(new Client(\"testInvalid\",s).getServerVisitor());\n }", "public static void main(String[] args) {\n System.out.println(\"Begin Server...\");\n\n\n\n try {\n Remote r = Naming.lookup(\"UniversalRegistry\");\n IUniversalRegistry iur = (IUniversalRegistry)r;\n\n //on ajoute des voitures dans le registre universel\n Voiture v1 = new Voiture(1);\n iur.bind(\"v1\",v1);\n Voiture v2 = new Voiture(2);\n iur.bind(\"v2\",v2);\n\n\n //On ajoute des voitures electrique dans le registre universel\n VoitureElectrique ve = new VoitureElectrique(4,0);\n iur.bind(\"ve\",ve);\n VoitureElectrique ve1 = new VoitureElectrique(4,1);\n iur.bind(\"ve1\",ve1);\n\n VoitureElectrique ve3 = new VoitureElectrique(4,1);\n iur.bind(\"ve3\",ve3);\n\n ClassTest classTest = new ClassTest();\n iur.bind(\"cl\",classTest);\n\n\n }\n\n catch(Exception e){\n e.printStackTrace();\n }\n\n\n\n }", "public void startEchoTester(int rate);", "public static void main(String[] args) throws IOException {\n ServerFile severFile = new ServerFile();\n severFile.createChannel(\"127.0.0.1\",9091);\n// SocketChannel socketChannel = severFile.createChannel(\"127.0.0.1\",9090);\n// severFile.sendFile(socketChannel);\n }", "public static void main( String[] args )\n { \n \t\n \t\n \tString endPoint;\n \tif (args[0].equals(\"H\"))\n \t{\n \t\tplayer = new Hunter(timetoWall,maxWalls);\n \t endPoint = hunterEndpoint;}\n \t\n \telse\n \t{\n \t\tplayer= new Prey();\n \t\t endPoint = preyEndpoint;}\n \t\n \ttimetoWall = Integer.parseInt(args[1]);\n \tmaxWalls = Integer.parseInt(args[2]);\n\t\tSession session;\n try {\n messageLatch = new CountDownLatch(100);\n\n final ClientEndpointConfig cec = ClientEndpointConfig.Builder.create().build();\n\n ClientManager client = ClientManager.createClient();\n ClientManager client2 = ClientManager.createClient();\n \n Endpoint playersocket = new Endpoint() {\n\n\n\t\t\t\t@Override\n\t\t\t\tpublic void onOpen(Session session, EndpointConfig arg1) {\n\t\t\t\t//\ttry {\n session.addMessageHandler(new MessageHandler.Whole<String>() {\n public void onMessage(String message) {\n System.out.println(\"Received message: \"+message);\n process(message);\n \n messageLatch.countDown();\n }\n });\n\n// }\n\t\t\t\t\t\n\t\t\t\t}\n };\n \n \n Endpoint publisher = new Endpoint() {\n\n\t\t\t\t@Override\n\t\t\t\tpublic void onOpen(Session session, EndpointConfig arg1) {\n\t\t\t\t//\ttry {\n session.addMessageHandler(new MessageHandler.Whole<String>() {\n public void onMessage(String message) {\n System.out.println(\"Received message: \"+message);\n //System.out.println(\"Prey.java pos:\" + getpreypos(message));\n messageLatch.countDown();\n }\n });\n // SENT_MESSAGE = getPositionsCommand();\n // session.getBasicRemote().sendText(SENT_MESSAGE);\n // SENT_MESSAGE = getWallsCommand();\n // session.getBasicRemote().sendText(SENT_MESSAGE);\n // } catch (IOException e) {\n // e.printStackTrace();\n // }\n\n\t\t\t\t}\n };\n\n \n \t session= client.connectToServer(playersocket, cec, new URI(endPoint));\n \n\n\n client2.connectToServer(publisher, cec, new URI(publisherEndpoint));\n messageLatch.await(100, TimeUnit.SECONDS);\n\n\n\t\t\twhile (true)\n\t\t\t{\n\t\t\t\tSENT_MESSAGE = getPositionsCommand();\n\t\t\t\ttry {\n\t\t\t\t\tsession.getBasicRemote().sendText(SENT_MESSAGE);\n\t\t\t\t} catch (IOException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\n\t\t\t\tSENT_MESSAGE = player. makeMove(hunterPos,preyPos);\n\t\t\t\ttry {\n\t\t\t\t\tsession.getBasicRemote().sendText(SENT_MESSAGE);\n\t\t\t\t} catch (IOException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t}\n\n\n\n\n \n } catch (Exception e) {\n e.printStackTrace();\n }\n\n\n\n\n \n }", "public interface Server extends Endpoint, Resetable {\n\n /**\n * is bound.\n *\n * @return bound\n */\n boolean isBound();\n\n /**\n * get channels.\n *\n * @return channels\n */\n Collection<Channel> getChannels();\n\n /**\n * get channel.\n *\n * @param remoteAddress\n * @return channel\n */\n Channel getChannel(InetSocketAddress remoteAddress);\n\n}", "@Override\n public void socket() {\n }", "public void start() throws Exception {\n ServerSocket ssk = new ServerSocket(sskPort);\n \n while( !new File(\"halt\").exists() ) {\n Socket sk = null;\n try { \n _(\"accepting\");\n sk = ssk.accept();\n _(\"accepted\");\n \n BufferedReader reader = new BufferedReader( new InputStreamReader( sk.getInputStream() ) );\n PrintStream ps = new PrintStream( sk.getOutputStream() ); \n \n ps.println(\"Hello You\");\n String cmd = null;\n while( (cmd = reader.readLine() ) != null) {\n ps.println(\"You said : '\"+ cmd +\"'\"); \n _(\"> '\"+ cmd +\"'\");\n if ( cmd.trim().equals(\"exit\") || cmd.trim().equals(\"quit\") ) {\n ps.println(\"Bye !\"); \n _(\"> Bye!\");\n break;\n } else if ( cmd.trim().equals(\"test\") ) {\n //ps.print(\"1234\"); \n //String line = \"0x81 0x9B 0x94 0x63 0x15 0xF8 0xF8 0x10 0x35 0xD7 0xE7 0x07 0x76 0x99 0xE6 0x07 0x38 0x9D 0xEC 0x17 0x3A 0x8E 0xF9 0x3C 0x78 0x96 0xE0 0x4C 0x62 0x8F 0xE3 0x6E 0x1F \";\n String line = \"0x81 0xFE 0x57 0x62 0xC9 0xD6 0x4C 0x39 0xF8 0xED 0x64 0x56 0xA4 0x89 0x34 0x03 0xA7 0xA0 0x36 0x11 0xD2 0x8D 0x67 0x0F 0xE9 0xF6 0x77 0x42 0xE9 0xF6 0x77 0x42 0xE9 0xCD 0x0C 0x53 0xF2 0xE5 0x63 0x0F 0xAA 0xA5 0x24 0x79 0x92 0xE6 0x3A 0x42 0xE9 0xF6 0x77 0x42 0xE9 0xF6 0x77 0x42 0xE9 0xF6 0x77 0x42 0xD2 0x8D 0x66 0x59 0xFA 0xE4 0x3A 0x05 0xAC 0xA2 0x1E 0x32 0xE7 0xA5 0x3D 0x11 0xD2 0x8D 0x67 0x0F 0xE9 0xF6 0x77 0x42 0xE9 0xF6 0x77 0x79 0x92 0xE7 0x6C 0x51 0xFD 0xBB 0x3B 0x0B 0xBF 0xB3 0x21 0x0B 0xAC 0xA1 0x4C 0x39 0xF9 0xBB 0x77 0x42 0xE9 0xF6 0x77 0x42 0xE9 0xF6 0x4C 0x39 0xF8 0xED 0x64 0x50 0xA4 0xA5 0x32 0x16 0x80 0x86 0x79 0x11 0xA3 0xA5 0x4C 0x39 \";\n int[] trame = decodeFrame(line);\n for(int i=0; i < trame.length; i++) {\n ps.write(trame[i]);\n System.out.print(trame[i]+\" \");\n }\n System.out.println();\n ps.flush();\n }\n } \n _(\"quit\");\n \n } catch(Exception ex) {\n ex.printStackTrace();\n } finally {\n try { sk.close(); } catch(Exception ex) {}\n }\n }\n try { ssk.close(); } catch(Exception ex) {}\n _(\"Halting\");\n }", "@ArchTypeComponent(\n patterns = {@Pattern(name=\"testLayered\", kind = \"Layered\", role=\"Layer{1}\")}\n )\npublic interface ServerConnector { \n \n /** Send the on-the-wire string to the server side. \n * \n * @param onTheWireFormat the observation in the adopted \n * on-the-wire format. \n * @return a future that will eventually tell the status \n * of the transmission. \n */ \n public FutureResult sendToServer(String onTheWireFormat) throws IOException; \n \n /** Send a query for a set of observations to the server. \n * \n * @param query the query for observations. Use one of \n * those defined in the forwarder.query sub package as \n * these are the ONLY ones the server understands. \n * @param reponseType define the type of the \n * returned observations, either as a list of \n * StandardTeleObserations or as PHMR documents. \n * @return a future with the query result as one big \n * string that needs deserializing before it can \n * by understood. \n * @throws IOException \n * @throws Net4CareException \n * @throws UnknownCPRException \n */ \n\tpublic FutureResultWithAnswer queryToServer(Query query) throws IOException, Net4CareException; \n\t \n }", "@Before\r\n public void setup() throws IOException {\r\n echoClient = new EchoClient();\r\n echoClient.connect(\"127.0.0.1\", listeningPort);\r\n }", "public static void main(String[] args) {\n\t\t try {\n\t // TODO code application logic here\n\t//\t\t subscribe();\n\t EchoServerThread echoThread = EchoServerThread.getInstance();\n//\t String test = \"一\";\n//\t System.out.println(System.getProperty(\"file.encoding\"));// java默认编码是UTF-8\n//\t System.out.println(test);\n//\t System.out.println(test.length());\n//\t System.out.println(test.getBytes(\"GB2312\").length);\n//\t System.out.println(test.getBytes(\"UTF8\").length);\n//\t System.out.println(test.getBytes(\"GBK\").length);\n//\t System.out.println(new String(test.getBytes(\"GB2312\"),\"GB2312\"));//用什么拆就用什么组装,否则显示乱码\n//\t System.out.println(new String(test.getBytes(\"GB2312\"),\"GB2312\").length());//用什么拆就用什么组装,否则显示乱码\n\t } catch (Exception ex) {\n\t Logger.getLogger(MainTest.class.getName()).log(Level.SEVERE, null, ex);\n\t }\n\t}", "public static void main(String args[]){\n\n\n try {\n socket_obj = new Socket(ip, port_number);\n System.out.println(\"hello, i'm Connected!\");\n\n // br_obj = new BufferedReader(new InputStreamReader(socket_obj.getInputStream()));\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n } catch (IOException e) {\n e.printStackTrace();\n }\n \n MorampudiClient Client_obj = new MorampudiClient();\n int number = 0;\n while(number < 1000)\n {\n Random r_obj = new Random();\n int probability = r_obj.nextInt(20);// getting the probability with which each event can happen\n // System.out.println(probability);\n /**\n * checking for the designated probabilities for each event in the process object to happen\n */\n if(probability >= 0 && probability < 7)\n {\n Client_obj.send_message();\n }\n else if(probability > 7 && probability < 14){\n Client_obj.receive_message();\n }\n else if(probability >= 14 && probability < 19)\n {\n Client_obj.internal_event();\n }\n else{\n Client_obj.byzantine_failure();\n }\n number++;\n }\n System.out.println(logical_clock);\n System.out.println(\"hello\");\n\n\n /**\n * object for the Client class\n */\n \n }", "@Before\r\n public void setUp() throws Exception\r\n {\r\n\tmss = new MServerSocket(LOCAL_PORT, 0, InetAddress.getByName(LOCALHOST));\r\n\t\r\n \tSystem.out.println(\"MServerSocket created\");\r\n EchoServerThread accepterThread = new EchoServerThread(mss);\r\n accepterThread.start();\r\n }", "@Override\n\tpublic void run() \n\t{\n\t\tcommunicator = com.zeroc.Ice.Util.initialize();\n GameServerPrx clientPrx = GameServerPrx.checkedCast(\n communicator.stringToProxy(\"client:default -h 58.167.142.74 -p 10002\")).ice_twoway().ice_secure(false).ice_collocationOptimized(false).ice_compress(true);\n\n if(clientPrx == null)\n {\n //If connection is failed due to server problems\n System.err.println(\"SB Connect: \" + \"Invalid proxy\");\n return;\n }\n System.out.println(\"SB Connect: \" + \"Connected\");\n Server server = new Server();\n server.address = ServerInfo.ADDRESS;\n server.UUID = ServerInfo.UUID;\n server.port = ServerInfo.PORT;\n server.name = ServerInfo.NAME;\n server.players = (short) players;\n\t\tclientPrx.sendServerDetails(server);\n\t\tSystem.out.println(\"SB Connect: \" + \"Data sent\");\n\t}", "ClientMessageSender() {\n\n\t}", "public static void main(String[] args) {\n\t\trouter = new CommandRouter();\n\t\ttry {\n\t\t\t// setup our socket connection to the tv, but don't connect yet\n\t\t\tconn = new Connection(HOST, PORT, router);\n\n\t\t\t// Tell out router which network connection to use\n\t\t\trouter.setConnection(conn);\n\n\t\t\t// setup a handler for incoming GrantedSessionCommand message\n\t\t\t// objects\n\t\t\ttry {\n\t\t\t\trouter.registerCommandSubscriber(new ICommandSubscriber() {\n\t\t\t\t\tpublic void onCommandReceived(AbstractCommand command) {\n\t\t\t\t\t\t// Filter out the messages we care about\n\t\t\t\t\t\tif (command instanceof GrantedSessionCommand) {\n\t\t\t\t\t\t\t// Print our our unique key, this will be used for\n\t\t\t\t\t\t\t// subsequent connections\n\t\t\t\t\t\t\tUtilities.log(\"Your instanceId is \" + ((GrantedSessionCommand) command).getInstanceId());\n\n\n\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t//let's make the dock show up on the TV\n\t\t\t\t\t\t\t\trouter.publishCommand(new NavigationInputCommand(\"press_yahoo\"));\n\n\t\t\t\t\t\t\t\tThread.sleep(2000); //sleep for 2 seconds so the animation to dock finishes\n\n\t\t\t\t\t\t\t\t// Lets do something cool, like tell the TV to navigate to the right. Then do a little dance\n\t\t\t\t\t\t\t\t// This is the same as pressing \"right\" on your remote\n\t\t\t\t\t\t\t\trouter.publishCommand(new NavigationInputCommand(\"press_right\"));\n\n\t\t\t\t\t\t\t\tThread.sleep(1000);\n\n\t\t\t\t\t\t\t\t// slide to the left\n\t\t\t\t\t\t\t\trouter.publishCommand(new NavigationInputCommand(\"press_left\"));\n\n\t\t\t\t\t\t\t\tThread.sleep(1000);\n\n\t\t\t\t\t\t\t\t//slide to the right\n\t\t\t\t\t\t\t\trouter.publishCommand(new NavigationInputCommand(\"press_right\"));\n\n\t\t\t\t\t\t\t\tThread.sleep(1000);\n\n\t\t\t\t\t\t\t\t//take it back now, y'all\n\t\t\t\t\t\t\t\trouter.publishCommand(new NavigationInputCommand(\"press_left\"));\n\n\t\t\t\t\t\t\t\t//cha cha cha\n\t\t\t\t\t\t\t\trouter.publishCommand(new NavigationInputCommand(\"press_up\"));\n\t\t\t\t\t\t\t\tThread.sleep(1000);\n\t\t\t\t\t\t\t\trouter.publishCommand(new NavigationInputCommand(\"press_down\"));\n\t\t\t\t\t\t\t\tThread.sleep(1000);\n\t\t\t\t\t\t\t\trouter.publishCommand(new NavigationInputCommand(\"press_up\"));\n\t\t\t\t\t\t\t\tThread.sleep(1000);\n\t\t\t\t\t\t\t\trouter.publishCommand(new NavigationInputCommand(\"press_down\"));\n\t\t\t\t\t\t\t} catch (InterruptedException e) {\n\t\t\t\t\t\t\t\tUtilities.log(\"Problem writing to the network connection\");\n\t\t\t\t\t\t\t\tconn.close();\n\t\t\t\t\t\t\t\tSystem.exit(-1);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// Notify the main thread that everything we wanted to\n\t\t\t\t\t\t\t// do is done.\n\t\t\t\t\t\t\tsynchronized (conn) {\n\t\t\t\t\t\t\t\tconn.notifyAll();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else { // print out the others for educational purposes\n\t\t\t\t\t\t\tUtilities.log(\"Received: \" + command.toString());\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tpublic void onConnectionLost(Connection conn) {\n\t\t\t\t\t\tUtilities.log(\"Connection Lost!\");\n\t\t\t\t\t}\n\t\t\t\t}, GrantedSessionCommand.class);\n\t\t\t} catch (InterruptedException e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\t// Establish a connection\n\t\t\t\tconn.establish();\n\t\t\t\t// Since this is the first time we are connecting, we must\n\t\t\t\t// create a new session\n\t\t\t\trouter.publishCommand(new CreateSessionCommand(APP_ID, CONSUMER_KEY, SECRET, APP_NAME));\n\n\t\t\t\tString message = getUserInput(\"Code: \");\n\t\t\t\trouter.publishCommand(new AuthSessionCommand(message, conn.getPeerCertificate()));\n\n\t\t\t\t// Let's wait until everything is done. This thread will get\n\t\t\t\t// notified once we are ready to clean up\n\t\t\t\ttry {\n\t\t\t\t\tsynchronized (conn) {\n\t\t\t\t\t\tconn.wait();\n\t\t\t\t\t}\n\t\t\t\t} catch (InterruptedException e) {\n\t\t\t\t\te.printStackTrace();\n\t\t\t\t}\n\t\t\t} catch (IOException ioe) {\n\t\t\t\tUtilities.log(\"Error establishing connection to \" + HOST + \":\" + PORT);\n\t\t\t} catch (InterruptedException e) {\n\t\t\t\tUtilities.log(\"Error establishing connection to \" + HOST + \":\" + PORT);\n\t\t\t}\n\n\t\t\t// It is always good practice to clean up after yourself\n\t\t\tconn.close();\n\n\t\t} catch (UnknownHostException e) {\n\t\t\tUtilities.log(\"Error resolving \" + HOST);\n\t\t\tSystem.exit(-1);\n\t\t} catch (IOException e) {\n\t\t\tUtilities.log(\"Problem writing to the network connection\");\n\t\t\te.printStackTrace();\n\t\t\tSystem.exit(-1);\n\t\t}\n\n\t\tSystem.exit(1);\n\t}", "public static void main(String[] args) {//Èë¿Ú\n\t\tinitLog4j();\n\t\tlogger.info(\"Client launched successfully\");\n\t\t\n\n\t\t// Application logic\n\t\tApplicationLogic applicationLogic = new ApplicationLogic();\n\n\t\tsysReader = new BufferedReader(new InputStreamReader(System.in));\n\t\tString str = null;\n\t\twhile (true) {\n\t\t\tSystem.out.print(\"EchoClient> \");\n\t\t\t// Read from system input\n\t\t\ttry {\n\t\t\t\tstr = sysReader.readLine();\n\t\t\t} catch (IOException e) {\n\t\t\t\tSystem.out.println(\"Failed to read from system input\");\n\t\t\t\tlogger.error(\"Failed to read from system input\");\n\t\t\t}\n\t\t\tif (!str.trim().equals(\"\")) {\n\t\t\t\t// Get command\n\t\t\t\tString[] token = str.split(\" \");\n\t\t\t\tString cmd = token[0];\n\t\t\t\t// Send\n\t\t\t\tif (cmd.equals(\"send\")) {\n\t\t\t\t\tString msg = str.substring(4, str.length()).trim();\n\t\t\t\t\tif (!msg.equals(\"\")) {\n\t\t\t\t\t\tapplicationLogic.send(msg);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t// connect\n\t\t\t\telse if (cmd.equals(\"connect\")) {\n\t\t\t\t\tint length = token.length;\n\t\t\t\t\tif (length == 3) {\n\t\t\t\t\t\t// Get remote server address and port\n\t\t\t\t\t\tString add = token[1];\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tint port = Integer.parseInt(token[2]);\n\t\t\t\t\t\t\tString REMOTE_IP = add;\n\t\t\t\t\t\t\tint REMOTE_PORT = port;\n\t\t\t\t\t\t\tapplicationLogic.connect(REMOTE_IP, REMOTE_PORT);\n\t\t\t\t\t\t} catch (NumberFormatException e) {\n\t\t\t\t\t\t\tSystem.out.println(\"Illigal port format\");\n\t\t\t\t\t\t\tlogger.warn(\"Illigal port format\");\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t// Wrong format\n\t\t\t\t\telse {\n\t\t\t\t\t\tSystem.out\n\t\t\t\t\t\t\t\t.println(\"Connect command should be as follow:\\nconnect <address> <port>\");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t// disconnect\n\t\t\t\telse if (cmd.equals(\"disconnect\")) {\n\t\t\t\t\tapplicationLogic.disconnect();\n\t\t\t\t}\n\t\t\t\t// logLevel\n\t\t\t\telse if (cmd.equals(\"logLevel\")) {\n\t\t\t\t\tint length = token.length;\n\t\t\t\t\tif (length == 2) {\n\t\t\t\t\t\t// Get logLevel\n\t\t\t\t\t\tString logLevel = token[1];\n\t\t\t\t\t\tapplicationLogic.logLevel(logLevel);\n\t\t\t\t\t}\n\t\t\t\t\t// Wrong format\n\t\t\t\t\telse {\n\t\t\t\t\t\tSystem.out\n\t\t\t\t\t\t\t\t.println(\"logLevel command should be as follow:\\nlogLevel <Level> \");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t// help\n\t\t\t\telse if (cmd.equals(\"help\")) {\n\t\t\t\t\tapplicationLogic.help();\n\t\t\t\t}\n\t\t\t\t// quit\n\t\t\t\telse if (cmd.equals(\"quit\")) {\n\t\t\t\t\tapplicationLogic.quit();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\t// other inputs\n\t\t\t\telse {\n\t\t\t\t\tSystem.out\n\t\t\t\t\t\t\t.println(\"Incorrect command, please try again or input 'help'\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "@Override\n public void setUp() throws Exception {\n transport = new TFramedTransport(new TSocket(\"123.56.206.195\", 1982));\n\n\n\n TProtocol protocol = new TBinaryProtocol(transport);\n client = new SubjectServ.Client(protocol);\n transport.open();\n }", "public static void main( final String[] args ) throws Exception {\n\t\tString client = \"WS_client\";\n\n\t\tfinal WebSocketContainer container = ContainerProvider.getWebSocketContainer();\t\t\t\t\n\t\tfinal String uri = \"ws://localhost:9090/broadcast\";\n\t\ttry( Session session = container.connectToServer( EventHandler.class, URI.create( uri ) ) ) {\n\t\t\t\twhile (true) {\n\t\t\t\t\tFakeRobot fakeRobot = new FakeRobot(1);\n\t\t\t\t\tString fakeMessage = fakeRobot.NextMessage();\n\t\t\t\t\tsession.getBasicRemote().sendObject( new MessageHandler( client, fakeMessage ) );\n\t\t\t\t\tThread.sleep(1000 );\n\t\t\t\t}\n\t\t}\n//\t\t(( LifeCycle )container ).stop();\n\n\t\t// JSR-356 has no concept of Container lifecycle.\n\t\t// (This is an oversight on the spec's part)\n\t\t// This stops the lifecycle of the Client WebSocketContainer\n\t\n//\t\tif( container instanceof LifeCycle ) {\n//\t\t ( ( LifeCycle )container ).stop();\n//\t\t}\n\t}", "public static void main(String[] args) {\n Servidor s = new Servidor();\n try{\n VoteSystem channel = (VoteSystem) UnicastRemoteObject.exportObject(s, 0);\n Registry register = LocateRegistry.createRegistry(1099);\n register.bind(\"VoteSystem\", channel);\n ServerGUI sgui= new ServerGUI();\n ServerThread st = new ServerThread(sgui);\n st.setDaemon(true);\n st.start();\n sgui.setVisible(true);\n }\n catch(Exception e){\n e.printStackTrace();\n }\n }", "public TCPMessengerServer() {\n initComponents();\n customInitComponents();\n listenForClient(); \n }", "public static void main(String[] args){\n\t\tif (args.length != 1) {\n\t\t\tSystem.out.println(\"Usage: java EchoServer <EchoServer port>\");\n\t\t\tSystem.exit(1);\n\t\t}\n\n\t\tEchoServerMultiThreaded echoServerMultiThreaded = new EchoServerMultiThreaded();\n\t\techoServerMultiThreaded.start(args);\n\t}", "public String listen(){\t\n\t\tSystem.out.println(\"Server lauscht.\");\n\t\treturn receiveString();\n\t}", "public static void main(String[] args) {\n Server server = new Server(1234);\n server.listen();\n \n // YOUR CODE HERE\n // It is not required (or recommended) to implement the server in\n // this runner class.\n }", "public interface LiveHostEvents extends LiveEvents{\n /** Live infomation\n * @param strUrl Rtmp/Hls url\n * @param strSessionId SessionId\n */\n public void OnRtcLiveInfomation(String strUrl, String strSessionId);\n\n /** Guest want to line with you\n * @param strPeerId Peer's ID\n * @param strUserName Peer's user name\n * @param strBrief A brief\n */\n public void OnRtcLiveApplyLine(String strPeerId, String strUserName, String strBrief);\n\n /** Guest cancel line apply\n * @param strPeerId Peer's ID\n * @param strUserName Peer's user name\n */\n public void OnRtcLiveCancelLine(String strPeerId, String strUserName);\n}", "public static void main(String[] args) throws Exception {\n\n List<RequestHandle> requestHandleList = new ArrayList<RequestHandle>();\n requestHandleList.add(new LsfRequestServerHandle());\n\n final Server server = new Server(new DefaultServerRoute(),new ServerHandler(requestHandleList), GlobalManager.serverPort);\n Thread t= new Thread(new Runnable() {\n public void run() {\n //start server\n try {\n server.run();\n } catch (Exception e) {\n e.printStackTrace();\n }\n }\n });\n t.start();\n\n ServerConfig serverBean = new ServerConfig();\n serverBean.setAlias(\"test\");\n serverBean.setInterfaceId(IService.class.getCanonicalName());\n serverBean.setImpl(new IServerImpl());\n server.registerServer(serverBean);\n\n\n }", "@Override\n/**\n * Communication Tester method\n */\npublic String Communicate() throws RemoteException {\n\treturn \"Server Says Hi\";\n}", "public interface IServerHandler<_ATTACHMENT>\n{\n\t// Called right after the connection is accepted. Use this event to attach an object of\n\t// type _ATTACHMENT to the connection to store session data.\n void onConnect(IServerConnection<_ATTACHMENT> connection);\n // Called whenever a packet arrives at the server. Use ISendable.getPacketType to determine\n // the PacketType (enum) in order to respond appropriately.\n void onPacket(IServerConnection<_ATTACHMENT> connection, ISendable packet) throws IOException;\n // Called when the connection is closed. This can be called in three cases:\n // 1. the connection was dropped (network error)\n // 2. the other end closed the connection\n // 3. you called connection.close().\n void onClose(IServerConnection<_ATTACHMENT> connection);\n}", "ManagedEndpoint next();", "public static void main(String[] args) throws Exception{\n ZMQ.Context context = ZMQ.context(1);\n ZMQ.Socket socket = context.socket(ZMQ.REP);\n\n System.out.println(\"Binding hello world server\");\n socket.bind (\"tcp://*:5555\");\n\n while (true) {\n\n // Wait for next request from client\n byte[] reply = socket.recv(0);\n System.out.println(\"Received \" + reply.length );\n System.out.println(\"Received \" + \": [\" + new String(reply) + \"]\");\n\n Thread.sleep(1000);\n // Create a \"Hello\" message.\n // Ensure that the last byte of our \"Hello\" message is 0 because\n // our \"Hello World\" server is expecting a 0-terminated string:\n String requestString = \"Hello\" ;\n byte[] request = requestString.getBytes();\n //request[request.length-1]=0; //Sets the last byte to 0\n // Send the message\n System.out.println(\"Sending response \" + requestString );\n socket.send(request, 0);\n\n // Get the reply.\n }\n }", "private void sendEnvelop(HRProtocol env)\n\t{\n\t\ttry\n\t\t{\n\t\t\tclientSocket = new ObjectSocket(SERVER, PORT);\n\t\t\tclientSocket.sendObject(env);\t// Send to server\n\t\t}catch(UnknownHostException uhe)\n\t\t{\n\t\t\tuhe.printStackTrace();\n\t\t}catch(IOException ioe)\n\t\t{\n\t\t\tioe.printStackTrace();\n\t\t}\n\t}", "public interface ITransportHandler {\n\n /**\n * Processing device returned messages\n * \n * @author\n * @param devReplyStr Message information returned by the device\n */\n void handlePacket(String devReplyStr);\n\n /**\n * Error information processing apparatus returns <br>\n * \n * @author\n * @param devReplyErr Error messages returned by the device\n */\n void handleError(String devReplyErr);\n\n /**\n * Device interaction with the end of the glyph packets <br>\n * \n * @author\n * @return End glyph packets\n */\n String getPacketEndTag();\n\n /**\n * Encoding packets\n * \n * @author\n * @return Encoding packets\n */\n String getCharsetName();\n\n}", "public void run() throws Exception {\n ServerEndpoint se = getServerEndpoint();\n TestService service = new TestServiceImpl();\n int redirectPort = getPort() + 1;\n Redirector rd = new Redirector(getHost(),getPort(),redirectPort);\n ((TestServerEndpoint) se).redirect(redirectPort);\n Thread t = new Thread(rd);\n t.start();\n BasicJeriExporter exporter = new BasicJeriExporter(se,\n new BasicILFactory());\n TestService stub = (TestService) exporter.export(service);\n //Connect to the mux server\n Socket s = new Socket(getHost(),getPort());\n InputStream is = s.getInputStream();\n OutputStream os = s.getOutputStream();\n //Send client connection header\n ClientConnectionHeader cHeader = new ClientConnectionHeader();\n cHeader.send(os);\n //Receive ServerConnection header and verify format\n ServerConnectionHeader sHeader = new ServerConnectionHeader();\n try {\n sHeader.receive(is,getTimeout());\n } catch (ProtocolException e) {\n e.printStackTrace();\n throw new TestException(e.getMessage(),e);\n }\n //Make a remote call that returns something\n stub.doSomething();\n exporter.unexport(true);\n rd.stop();\n //Extract and analyze the messages sent by the mux server\n try {\n analyzeServerDataBytes(rd.getServerConversation());\n } catch (ProtocolException e) {\n e.printStackTrace();\n throw new TestException(e.getMessage(),e);\n }\n //Ping the server\n PingMessage pm = new PingMessage().setCookie((short)0x5544);\n pm.send(os);\n //Receive a ping ack from server and verify that the correct cookie\n //is included\n se = getServerEndpoint();\n service = new TestServiceImpl();\n exporter = new BasicJeriExporter(se,\n new BasicILFactory());\n stub = (TestService) exporter.export(service);\n //Connect to the mux server\n s = new Socket(getHost(),getPort());\n is = s.getInputStream();\n os = s.getOutputStream();\n PingAckMessage pam = new PingAckMessage().setCookie((short)0x5544);\n try {\n pam.receive(is,getTimeout());\n } catch (ProtocolException e) {\n e.printStackTrace();\n throw new TestException(e.getMessage(),e);\n }\n }", "@Override\n public void channelConnected(ChannelHandlerContext ctx, ChannelStateEvent e) {\n Channel channel = ctx.getChannel();\n //session.setAttachment(new Player(session));\n Client client = new Client(channel);\n channel.setAttachment(client);\n engine.addClient(client);\n }", "public void handle(Event ev) {\n \n //\t\tsynchronized (this) {\n \t\t//\t\tSystem.out.println(\"VsProxySession - \"+ ev.getDir() \n //\t\t+\" - Received an event type - \" + ev.getClass());\n \n \t\ttry {\n \t\t\t/********** Normal Events **********/\n \t\t\tif (ev instanceof ChannelInit)\n \t\t\t\thandleChannelInit((ChannelInit) ev);\n \t\t\telse if (ev instanceof RegisterSocketEvent)\n \t\t\t\thandleRegisterSocketEvent((RegisterSocketEvent) ev);\n \t\t\telse if (ev instanceof BlockOk)\n \t\t\t\thandleBlockOk((BlockOk) ev);\n \t\t\telse if (ev instanceof View)\n \t\t\t\thandleView((View) ev);\n \n \t\t\t/********** Stub Events => Clients->Server **********/\n \t\t\telse if (ev instanceof GroupInitStubEvent)\n \t\t\t\thandleGroupInitStubEvent((GroupInitStubEvent) ev);\n \t\t\telse if (ev instanceof LeaveStubEvent)\n \t\t\t\thandleLeaveStubEvent((LeaveStubEvent) ev);\n \t\t\telse if (ev instanceof GroupSendableStubEvent)\n \t\t\t\thandleGroupSendableStubEvent((GroupSendableStubEvent) ev);\t\n \t\t\telse if (ev instanceof BlockOkStubEvent)\n \t\t\t\thandleBlockOkStubEvent((BlockOkStubEvent) ev);\t\n \n \t\t\t/********** Stub Events => Server->Server **********/\n \t\t\telse if (ev instanceof NewClientProxyEvent)\n \t\t\t\thandleNewClientProxyEvent((NewClientProxyEvent) ev);\n \t\t\telse if (ev instanceof LeaveClientProxyEvent)\n \t\t\t\thandleLeaveClientProxyEvent((LeaveClientProxyEvent) ev);\n \t\t\telse if (ev instanceof GroupSendableProxyEvent)\n \t\t\t\thandleGroupSendableProxyEvent((GroupSendableProxyEvent) ev);\n \t\t\telse if (ev instanceof BlockOkProxyEvent)\n \t\t\t\thandleBlockOkProxyEvent((BlockOkProxyEvent) ev);\n \t\t\telse if (ev instanceof DecidedProxyEvent)\n \t\t\t\thandleDecidedProxyEvent((DecidedProxyEvent) ev);\n \t\t\telse if (ev instanceof UpdateProxyEvent)\n \t\t\t\thandleUpdateProxyEvent((UpdateProxyEvent) ev);\t\t\n \t\t\telse if (ev instanceof UpdateDecideProxyEvent)\n \t\t\t\thandleUpdateDecideProxyEvent((UpdateDecideProxyEvent) ev);\t\t\n \n \t\t\t/********** Pong detecture - For failure detection ********/\n \t\t\telse if (ev instanceof PongEvent){\n \t\t\t\thandlePongEvent((PongEvent) ev);\n \t\t\t}\n \n \t\t\t/********* If we don't handle the event warn *******/\n \t\t\telse{ \n \t\t\t\tSystem.out.println(\"VsProxySession: Event not treated - \" + \n \t\t\t\t\t\tev.getClass().toString());\n \t\t\t\tev.go();\n \t\t\t}\n \t\t} catch (AppiaException e) {\n \t\t\te.printStackTrace();\n \t\t}\n \t}", "public interface PacketChannelListener\r\n{\r\n\r\n /**\r\n * Called when a packet is fully reassembled.\r\n *\r\n * @param pc The source of the event.\r\n * @param pckt The reassembled packet\r\n */\r\n public void packetArrived(PacketChannel pc, ByteBuffer pckt) throws InterruptedException;\r\n\r\n /**\r\n * Called when some error occurs while reading or writing to the socket.\r\n *\r\n * @param pc The source of the event.\r\n * @param ex The exception representing the error.\r\n */\r\n public void socketException(PacketChannel pc, Exception ex);\r\n\r\n /**\r\n * Called when the read operation reaches the end of stream. This means that\r\n * the socket was closed.\r\n *\r\n * @param pc The source of the event.\r\n */\r\n public void socketDisconnected(PacketChannel pc, boolean failed);\r\n}", "public void testHello() {\n FakeEngineManagerListener engineManagerListener = new FakeEngineManagerListener();\n try {\n EngineManager engineManager =\n new EngineManager(engineManagerListener, TEST_MAIN_SC_XML);\n\n // EngineManager.Event event = EngineManager.Event.HELLO;\n Node utterance = makeDoc(\"hello\");\n\n engineManager.fireEvent(\"user_input\", utterance);\n Thread.sleep(1000); // give the async trigger a chance\n\n // now we should have some output (the reply, \"hello\").\n\n assertEquals(1, engineManagerListener.getTargets().size());\n assertNull(engineManagerListener.getTargets().get(0));\n\n assertEquals(1, engineManagerListener.getTargetTypes().size());\n assertEquals(\"x-java\", engineManagerListener.getTargetTypes().get(0));\n\n assertEquals(1, engineManagerListener.getDatas().size());\n if (engineManagerListener.getDatas().get(0) != null) {\n Map<String, Node> data = engineManagerListener.getDatas().get(0);\n assertEquals(1, data.size());\n assertTrue(data.keySet().contains(\"speak0\"));\n Node outputNode = data.values().iterator().next();\n assertEquals(\n \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-16\\\"?>\" //\n + \"<data xmlns=\\\"http://www.w3.org/2005/07/scxml\\\" name=\\\"speak0\\\">\\n\" //\n + \" <messageId xmlns=\\\"http://www.joelsgarage.com/callcenter\\\">hello</messageId>\\n\" //\n + \"</data>\\n\", //\n XMLUtil.writeXML(outputNode));\n }\n } catch (InitializationException e) {\n e.printStackTrace();\n fail();\n } catch (InterruptedException e) {\n e.printStackTrace();\n fail();\n }\n }", "public static void main(String[] args) throws UnknownHostException, IOException\n\t{\n\t\t Socket clientSocket = new Socket(\"localhost\", 6789);\n\t\t clientSocket.setSoTimeout(5000);\n\n\t\t DataOutputStream outToServer = new DataOutputStream(clientSocket.getOutputStream());\n\t\t BufferedReader inFromServer = new BufferedReader(new InputStreamReader(clientSocket.getInputStream()));\n\t\t outToServer.writeBytes(\"queryState\" + '\\n'); // warningClear , stopRequest, startRequest, queryState\n\t\t String clientMess = inFromServer.readLine();\n\t\t System.out.println(\"FROM SERVER: \" + clientMess);\n\t\t clientSocket.close();\n\t\t String mess = null;\n\t\t if(clientMess.equals(\"ON\"))\n\t\t {\n\t\t\t mess = \"stopRequest\";\n\t\t }\n\t\t else if(clientMess.equals(\"OFF\"))\n\t\t\t mess = \"startRequest\";\n\t\t Socket clientSocket2 = new Socket(\"localhost\", 6789);\n\t\t DataOutputStream outToServer2 = new DataOutputStream(clientSocket2.getOutputStream());\n\t\t BufferedReader inFromServer2 = new BufferedReader(new InputStreamReader(clientSocket2.getInputStream()));\n\t\t outToServer2.writeBytes(mess + '\\n'); // warningClear , stopRequest, startRequest, queryState\n\t\t System.out.println(\"FROM SERVER: \" +inFromServer2.readLine() );\n\t\t clientSocket2.close();\n\t\t \n\t}", "public interface AmqpServer extends Entity {\n \n /* AMQP protocol version strings. */\n\n String AMQP_0_8 = \"0-8\";\n String AMQP_0_9 = \"0-9\";\n String AMQP_0_9_1 = \"0-9-1\";\n String AMQP_0_10 = \"0-10\";\n String AMQP_1_0 = \"1-0\";\n\n PortAttributeSensorAndConfigKey AMQP_PORT = Attributes.AMQP_PORT;\n\n BasicAttributeSensorAndConfigKey<String> VIRTUAL_HOST_NAME = new BasicAttributeSensorAndConfigKey<String>(\n String.class, \"amqp.virtualHost\", \"AMQP virtual host name\", \"localhost\");\n\n BasicAttributeSensorAndConfigKey<String> AMQP_VERSION = new BasicAttributeSensorAndConfigKey<String>(\n String.class, \"amqp.version\", \"AMQP protocol version\");\n\n String getVirtualHost();\n\n String getAmqpVersion();\n\n Integer getAmqpPort();\n}", "public ServerConnecter() {\r\n\r\n\t}", "public static void main(final String[] args) {\n try (Socket socket = new Socket(getLocalHost(), TimeServer.DEFAULT_PORT)) {\n try (InputStream input = socket.getInputStream()) {\n try (BufferedReader reader = new BufferedReader(new InputStreamReader(input))) {\n try (OutputStream output = socket.getOutputStream()) {\n try (PrintWriter writer = new PrintWriter(output, true)) {\n \n final Console console = System.console();\n String text;\n do {\n text = console.readLine(\"Enter text: \");\n writer.println(text);\n System.out.println(reader.readLine());\n } while (!\"bye\".equals(text));\n }\n }\n }\n }\n } catch (UnknownHostException ex) {\n \n System.out.println(\"Server not found: \" + ex.getMessage());\n \n } catch (IOException ex) {\n \n System.out.println(\"I/O error: \" + ex.getMessage());\n }\n }", "protected void serverStarted()\n {\n // System.out.println\n // (\"Server listening for connections on port \" + getPort());\n }", "public static void main(String[] args) {\n\n HttpConnector connector = new HttpConnector();\n Wrapper wrapper = new SimpleWrapper();\n wrapper.setServletClass(\"ModernServlet\");\n Loader loader = new SimpleLoader();\n Valve valve1 = new HeaderLoggerValve();\n Valve valve2 = new ClientIPLoggerValve();// 在这里显示IP\n\n wrapper.setLoader(loader);\n ((Pipeline) wrapper).addValve(valve1);\n ((Pipeline) wrapper).addValve(valve2);\n\n connector.setContainer(wrapper);\n\n try {\n connector.initialize();\n connector.start();\n\n // make the application wait until we press a key.\n System.in.read();\n }\n catch (Exception e) {\n e.printStackTrace();\n }\n }", "public static void main(String[] args) throws Exception {\r\n\r\n EventLoopGroup group = new NioEventLoopGroup();\r\n try {\r\n Bootstrap b = new Bootstrap();\r\n b.group(group)\r\n .channel(NioSocketChannel.class)\r\n .handler(new ClientInitializer());\r\n\r\n // Start the connection attempt.\r\n Channel ch = b.connect(HOST, PORT).sync().channel();\r\n\r\n // Read commands from the stdin.\r\n ChannelFuture lastWriteFuture = null;\r\n BufferedReader in = new BufferedReader(new InputStreamReader(System.in));\r\n RandomString gen = new RandomString(10);\r\n \t\tint k=3;\r\n \t\tSystem.out.println(\"Prime number: \");\r\n \t\tint temp = Integer.parseInt(in.readLine());\r\n int N=2*temp+1;\r\n String s = gen.nextString();\r\n System.out.println(\"Username: \");\r\n String I=in.readLine();\r\n System.out.println(\"Password: \");\r\n String p=in.readLine();\r\n int g = 11;\r\n System.out.println(\"Generator g = \" + g);\r\n double x = hash(s+p);\r\n System.out.println(\"x=\"+x);\r\n double v = (Math.pow(g, x))%N;\r\n System.out.println(\"v=\"+v);\r\n //FirstPhase\r\n System.out.println(\"Sending to server I,s,v,N\");\r\n lastWriteFuture = ch.writeAndFlush(\"fi,\"+I+\",\"+s+\",\"+Double.toString(v)+\",\"+Integer.toString(N)+\"\\r\\n\");\r\n lastWriteFuture.sync();\r\n System.out.println(\"Data send\");\r\n int a= (int)Math.random()*1000;\r\n System.out.println(\"Generating a=\"+a);\r\n int A = (int) (Math.pow(g,a)%N);\r\n System.out.println(\"Calculating A=g^a mod N=\"+A);\r\n System.out.println(\"Sending to server I,A\");\r\n lastWriteFuture = ch.writeAndFlush(\"ft,\"+I+\",\"+A+\"\\r\\n\");\r\n lastWriteFuture.sync();\r\n System.out.println(\"Waiting server to respond...\");\r\n while(!ClientHandler.gotb){\r\n \t\r\n }\r\n \r\n double B = ClientHandler.B;\r\n double K =0.0;\r\n System.out.println(\"Recieving from server B=\"+B);\r\n double u = hash(Integer.toString(A)+Double.toString(B));\r\n System.out.println(\"Calculating U=h(A,B)=\"+u);\r\n System.out.println(\"Waiting server to respond...\");\r\n lastWriteFuture = ch.writeAndFlush(\"neddK\"+\"\\r\\n\");\r\n lastWriteFuture.sync();\r\n while(!ClientHandler.gotk){\r\n \t\r\n }\r\n if (u!=0.0){\r\n double servK = ClientHandler.K;\r\n double S=(Math.pow((B-k*((Math.pow(g,x))%N)),(a+u*x)))%N;\r\n K=hash(Double.toString(S));\r\n System.out.println(\"Calculating K=h(((B-k*(g^x mod N))^a+u*x) mod N = \"+K);\r\n if(servK==K){\r\n \t System.out.println(\"OK!\");\r\n }\r\n }\r\n //SecondPhase\r\n double M = hash((((int)hash(Integer.toString(N))^(int)hash(Integer.toString(g))))+Double.toString(hash(I))+s+Integer.toString(A)+Double.toString(B)+Double.toString(K));\r\n System.out.println(\"Calculating M=\"+M);\r\n System.out.println(\"Waiting server to respond...\");\r\n lastWriteFuture = ch.writeAndFlush(\"neddR\"+\"\\r\\n\");\r\n lastWriteFuture.sync();\r\n while(!ClientHandler.gotr){\r\n \t\r\n }\r\n if(hash(Integer.toString(A)+Double.toString(M)+Double.toString(K))==ClientHandler.R)\r\n \tSystem.out.println(\"Sucsess!\");\r\n else\r\n \tSystem.out.println(\"Error!\");\r\n lastWriteFuture = ch.writeAndFlush(\"bye\");\r\n lastWriteFuture.sync();\r\n /*for (;;) {\r\n String line = in.readLine();\r\n if (line == null) {\r\n break;\r\n }\r\n\r\n // Sends the received line to the server.\r\n lastWriteFuture = ch.writeAndFlush(line + \"\\r\\n\");\r\n\r\n // If user typed the 'bye' command, wait until the server closes\r\n // the connection.\r\n if (\"bye\".equals(line.toLowerCase())) {\r\n ch.closeFuture().sync();\r\n break;\r\n }\r\n }*/\r\n\r\n // Wait until all messages are flushed before closing the channel.\r\n if (lastWriteFuture != null) {\r\n lastWriteFuture.sync();\r\n }\r\n } finally {\r\n // The connection is closed automatically on shutdown.\r\n group.shutdownGracefully();\r\n }\r\n }", "public static native void speexEchoPlayback(short[] echoFrame);", "@Override\n public void messageReceived(ChannelHandlerContext ctx, MessageEvent e) {\n Channel ch = ctx.getChannel();\n //Player player = (Player) ch.getAttachment();\n Client client = (Client) ch.getAttachment();\n \n if (ch.isConnected()) { // && !client.getPlayer().destroyed() \n RSCPacket packet = (RSCPacket) e.getMessage();\n //player.addPacket(p); // Used to log packets for macro detection\n //engine.addPacket(p); // This one actually results in the packet being processed!\n client.pushToMessageQueue(packet);\n }\n }", "private void createAndListen() {\n\n\t\t\n\t}", "public static void main(String[] args) throws IOException {\n\n if (args.length != 1) // Test for correct argument list\n throw new IllegalArgumentException(\"Parameter(s): <Port>\");\n\n int servPort = Integer.parseInt(args[0]);\n\n DatagramSocket socket = new DatagramSocket(servPort);\n OperationRequestDecoder decoder = new OperationRequestDecoderBin();\n OperationResultEncoder encoder = new OperationResultEncoderBin();\n\n for (;;) { // Run forever, receiving and echoing datagrams\n DatagramPacket packet = new DatagramPacket(new byte[ECHOMAX], ECHOMAX);\n socket.receive(packet); // Receive packet from client\n\n int packLength = packet.getLength();\n // DECODE OPERATION OBJECT FROM BINARY\n\n OperationRequest request = decoder.decode(packet);\n byte error_code = 0;\n\n // Assert that byte length recieved is equal to object's TML value\n if(request.tml != packLength) {\n error_code = 127;\n }\n\n int num = 0;\n short op1 = request.operand1;\n short op2 = request.operand2;\n int opResult = -1;\n switch ((int)request.op_code) {\n // Addition\n case 0:\n opResult = op1 + op2;\n break;\n \n // Subtraction\n case 1:\n opResult = op1 - op2;\n break;\n \n // Multiplication\n case 2:\n opResult = op1 * op2;\n break;\n\n // Division\n case 3:\n opResult = op1 / op2;\n break;\n\n // Shift Right \n case 4: \n opResult = op1 >> op2;\n break;\n\n // Shift Left \n case 5: \n opResult = op1 << op2;\n break;\n \n // Not\n case 6:\n opResult = ~op1;\n break;\n\n default:\n error_code = 127;\n break;\n }\n\n byte tml = 7;\n \n OperationResult result = new OperationResult(tml, request.request_id, error_code, opResult);\n\n byte[] bin = encoder.encode(result);\n packet.setData(bin);\n socket.send(packet); // Send the same packet back to client\n }\n /* NOT REACHED */\n }", "public static void main(String[] args) {\n startupTime = DateUtil.getCurrentTimeSeconds();\n\n try {\n LoggingConfiguration.checkLoggingConfig();\n\n ServerConfiguration.load(\"server.ini\");\n GameConfiguration.load(\"game.ini\");\n\n log = LoggerFactory.getLogger(Kepler.class);\n ResourceLeakDetector.setLevel(ResourceLeakDetector.Level.ADVANCED);\n\n // TODO: The \"Standard\" ASCII from\n // http://patorjk.com/software/taag/#p=display&f=Standard&t=Kepler\n // On a grey background with white ASCII text\n // ASCII logo on the left side, contributors and other credits/info on the right side\n // TODO: also a way to disable the fancy headers, as in production it would only fill the logs\n log.info(\"Kepler - Habbo Hotel V21 Emulation\");\n\n if (!Storage.connect()) {\n return;\n }\n\n log.info(\"Setting up game\");\n\n WalkwaysManager.getInstance();\n ItemManager.getInstance();\n CatalogueManager.getInstance();\n RoomModelManager.getInstance();\n RoomManager.getInstance();\n PlayerManager.getInstance();\n FuserightsManager.getInstance();\n NavigatorManager.getInstance();\n GameScheduler.getInstance();\n CommandManager.getInstance();\n MessageHandler.getInstance();\n TextsManager.getInstance();\n\n // Get the server variables for the socket to listen on\n serverIP = ServerConfiguration.getString(\"server.bind\");\n serverPort = ServerConfiguration.getInteger(\"server.port\");\n\n // Get an InetAddressValidator\n InetAddressValidator validator = InetAddressValidator.getInstance();\n\n // Validate an IPv4 or IPv6 address\n if (!validator.isValid(serverIP)) {\n log.error(\"%s is not a valid IP\", serverIP);\n return;\n }\n\n // getByName parses IPv6, IPv4 and DNS all in one go\n serverIP = InetAddress.getByName(serverIP).getHostAddress();\n\n // Create the server instance\n // TODO: listen on both IPv4 and IPv6 if serverIP is 0.0.0.0 or localhost\n server = new NettyServer(serverIP, serverPort);\n server.createSocket();\n server.bind();\n\n Runtime.getRuntime().addShutdownHook(new Thread(() -> dispose()));\n\n } catch (Exception e) {\n e.printStackTrace();\n }\n }", "public void talk() {\n\n\t}", "@OnOpen\n public void onOpen(final Session session)\n {\n System.out.println(session.getId() + \" has open a connection\");\n // since all connection use the same process create a private context\n final YAPIContext yctx = new YAPIContext();\n try {\n yctx.PreregisterHubWebSocketCallback(session);\n } catch (YAPI_Exception e) {\n e.printStackTrace();\n return;\n }\n\n Thread thread = new Thread(new Runnable()\n {\n @Override\n public void run()\n {\n\n\n try {\n // register the YoctoHub/VirtualHub that start the connection\n yctx.UpdateDeviceList();\n\n // list all devices connected on this hub (only for debug propose)\n System.out.println(\"Device list:\");\n YModule module = YModule.FirstModuleInContext(yctx);\n while (module != null) {\n System.out.println(\" \" + module.get_serialNumber() + \" (\" + module.get_productName() + \")\");\n module = module.nextModule();\n }\n\n // play a bit with relay output :-)\n try {\n YRelay relay = YRelay.FirstRelayInContext(yctx);\n if (relay != null) {\n relay.set_state(YRelay.STATE_A);\n Thread.sleep(500);\n relay.set_state(YRelay.STATE_B);\n Thread.sleep(250);\n relay.set_state(YRelay.STATE_A);\n Thread.sleep(250);\n relay.set_state(YRelay.STATE_B);\n Thread.sleep(500);\n relay.set_state(YRelay.STATE_A);\n Thread.sleep(1000);\n relay.set_state(YRelay.STATE_B);\n Thread.sleep(500);\n relay.set_state(YRelay.STATE_A);\n Thread.sleep(1000);\n relay.set_state(YRelay.STATE_B);\n } else {\n System.out.println(\"No Relay connected\");\n }\n\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n\n } catch (YAPI_Exception ex) {\n System.out.println(\" error (\" + ex.getLocalizedMessage() + \")\");\n ex.printStackTrace();\n }\n // no not forget to FreeAPI to ensure that all pending operation\n // are finished and freed\n yctx.FreeAPI();\n }\n });\n thread.start();\n }", "void send();", "public ZwischenServer() throws IOException{\n\t\tFile paramfile = new File(\"/home/tobi/uniworks/netzwerke/UE2/Parameter.txt\");\n\t\tif(paramfile.canRead()){\n\t\t\tInputStream paramIs = new FileInputStream(paramfile);\n\t\t\tInputStreamReader paramIsr = new InputStreamReader(paramIs);\n\t\t\tBufferedReader paramBr = new BufferedReader(paramIsr);\n\t\t\tth = paramBr.readLine();\n\t\t\tcontent = th.substring(th.indexOf(' ', 0), th.length());\n\t\t\tth = th.substring(0, th.indexOf(' ', 0));\n\t\t\texchangeContent = content.substring(content.indexOf(';'), content.indexOf(')')-1);\n\t\t\tcontent = content.substring(content.indexOf('('), content.indexOf(';'));\n\t\t\tsocket8082 = new Socket(\"127.0.0.1\",8082);\n\t\t\tsocket80 = new Socket(th,80);\n\t\t}\n\t\telse\n\t\t\tSystem.out.println(\"Error file not found\");\n\t}", "public interface EchoService {\n String echo(String string);\n}", "private void sendToClient(String string) {\n\t\r\n}", "public Server() {}", "public void send() {\n\t}", "public interface JsInspectorChannelServer {\n int notify(long j, long j2, String str);\n\n int sendData(long j, String str);\n }", "public static void main(String[] args){\n\n GameClientImpl client = new GameClientImpl();\n client.startConnection(\"127.0.0.1\", ProtocolConfiguration.PORT);\n\n }", "public static void main(String[] args) {\n\t\tfinal Device lamp = new Device(\"Lamp\", \"Lamp\",\"Lamp\" ,\"img/lamp.png\");\r\n\t\t\r\n\t\t//2. Register the 2 functions\r\n\t\tlamp.registerFunction(\"SwitchOn\", \"Function exposed to server\");\r\n\t\tlamp.registerFunction(\"SwitchOff\", \"Function exposed to server for switching off the device\");\r\n\t\t\r\n\t\t//3. Set the type of communication layer. In this case it is a java implementation of websocket.\r\n\t\t//Depending the environment the driver is running, other implementation of the websocket layer can be injected\r\n\t\tlamp.setWebsocketLayer(new JavaWebsocketLayer(lamp));\r\n\t\t\r\n\t\t//a simple text label to display if lamp is on or off.\r\n\t\t//in a real lamp, instead displaying a label, the microcontroller will send an electric signal to a switch\r\n\t\tfinal JLabel state = new JLabel();\r\n\t\t\r\n\t\t//4. Add function handlers to execute the captured events\r\n\t\t//this implementation of the handler simply diplays Switched on or Switched off\r\n\t\tlamp.addFunctionHandler(new FunctionHandler() {\r\n\t\t\t\r\n\t\t\t@Override\r\n\t\t\tpublic void execute(String name, Map<String, String> input) {\r\n\t\t\t\ttry{\r\n\t\t\t\t\r\n\t\t\t\t\tif(name.equals(\"SwitchOn\")){\r\n\t\t\t\t\t\tstate.setIcon(new ImageIcon(new URL(\"http://72.13.93.222:8080/hatzouf/img/light-on.png\")));\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\t\tstate.setIcon(new ImageIcon(new URL(\"http://72.13.93.222:8080/hatzouf/img/light-off.png\")));\r\n\t\t\t\t\t}\r\n\t\t\t\t}catch(Exception e){\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t});\r\n\t\t\r\n\t\t//5. This handler is executed when the device is connected and ready for use.\r\n\t\tlamp.onReady(new OnReady() {\r\n\t\t\t\r\n\t\t\t@Override\r\n\t\t\tpublic void ready() {\r\n\t\t\t\tJFrame frame = new JFrame(\"Lamp\");\r\n\t\t\t\tframe.getContentPane().add(state, BorderLayout.NORTH);\r\n\t\t\t\tframe.setSize(300, 275);\r\n\t\t\t\tframe.setVisible(true);\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t});\r\n\t\t\r\n\t\t//6. connect the device to the hatzouf server\r\n\t\tlamp.connect(\"ws://72.13.93.222:8080/hatzouf/websockets/iot\");\r\n\t\t\r\n\t}", "public TrackClientPacketHandler() \n {\n super(Constants.DEVICE_CODE);\n }", "@Override\n\tpublic void sendPacket() {\n\t\t\n\t\tStringBuilder theURL = new StringBuilder();\n\t\t\n\t\ttheURL.append(core.modelCore.targetURL);\n\t\ttheURL.append(\"michael/updateevent.php?\");\n\t\ttheURL.append(\"page=\" + \"eleven\" +\"&\"); //page = \"three\"&\n\t\ttheURL.append(\"name=\" + core.modelCore.selectedEvent.eventName +\"&\");\n\t\ttheURL.append(\"answer=\" + yesBox.isChecked() +\"&\");\n\t\ttheURL.append(\"user=\" + core.modelCore.username);\n\t\t\n\t\tSystem.out.println( theURL.toString() );\n\t\t\n\t\tLogic_PHP.getResponseFromURL(core, theURL.toString());\n\t}", "void visitEchoNode(EchoNode node);", "public static void main(String[] args) throws Exception {\n\t\tfinal URI url = new URI(\"ws://localhost:2222/websockets/echo\");\n\n\t\tSystem.out.println(Thread.currentThread());\n\t\tClientManager client = ClientManager.createClient();\n\t\tclient.connectToServer(EchoClient.class, url);\n\t\tlatch.await();\n\t}", "public synchronized void listen() {\n// synchronized (this) {\n try {\n String input;\n if ((input = in.readLine()) != null) {\n parseCommand(input);\n }\n } catch (IOException ex) {\n Logger.getLogger(ClientIO.class.getName()).log(Level.SEVERE, null, ex);\n }\n// }\n }", "public Server(){\r\n \r\n this.m_Clients = new TeilnehmerListe();\r\n this.m_Port = 7575;\r\n }", "public interface DataRelayClient {\n\n /**\n * Send data in a loop over UDP\n */\n public void streamData(String pathToFile) throws IOException;\n\n /**\n * Receive data in a loop via UDP\n */\n public void receiveData() throws IOException;\n\n /**\n * Initialize TCP connection\n */\n public void initializeTCP() throws IOException;\n /**\n * Initialize UDP connection\n */\n public void initializeUDP() throws IOException;\n\n /**\n * Get client ID from the server\n */\n public void setID() throws IOException;\n\n /**\n * Check if client is first to connect\n */\n public boolean isFirstToConnect() throws IOException;\n\n /**\n * Initialize the client\n */\n public void initialize() throws Exception;\n}", "@Override\n public void channelActive(ChannelHandlerContext ctx) throws Exception {\n }", "public interface IServer extends Remote {\n /**\n * @param auction\n * @throws RemoteException\n */\n void placeAuction(AuctionBean auction) throws RemoteException;\n\n /**\n * @param client\n * @throws RemoteException\n * @throws InterruptedException\n */\n void register(IClient client) throws RemoteException, InterruptedException;\n\n void disconnect(IClient client) throws RemoteException;\n\n /**\n * @param client\n * @param newBid\n * @throws RemoteException\n */\n void raiseBid(IClient client, int newBid) throws RemoteException;\n\n /**\n * @param client\n * @throws RemoteException\n * @throws InterruptedException\n */\n void timeElapsed(IClient client) throws RemoteException, InterruptedException;\n\n\tvoid registerCredentials(String username, String password) throws RemoteException, InterruptedException;\n\n\tboolean verifyCredentials(String username, String password) throws RemoteException, InterruptedException;\n\t\n}" ]
[ "0.6252765", "0.6017072", "0.58827066", "0.585948", "0.5859095", "0.5770559", "0.5734598", "0.57247657", "0.5709314", "0.5651984", "0.5631291", "0.56280786", "0.56208616", "0.5617506", "0.56166923", "0.56153023", "0.5614779", "0.56091636", "0.5608712", "0.55868214", "0.55661845", "0.5544598", "0.55370873", "0.5530461", "0.5482042", "0.54731005", "0.54567593", "0.54362905", "0.5422177", "0.54109436", "0.5410658", "0.54023516", "0.5393362", "0.53890586", "0.53861946", "0.5374135", "0.5366954", "0.53541464", "0.53488004", "0.5342221", "0.5341677", "0.53416616", "0.53277063", "0.5326874", "0.5309358", "0.53083265", "0.529726", "0.5294174", "0.52881706", "0.5286034", "0.5285254", "0.52822506", "0.52654946", "0.526207", "0.5257696", "0.5256051", "0.5254916", "0.52538866", "0.52532727", "0.52440506", "0.524043", "0.522962", "0.52253073", "0.5223646", "0.52084666", "0.5208182", "0.520506", "0.52034295", "0.5201856", "0.5198989", "0.5198721", "0.519465", "0.51906914", "0.5188081", "0.51732427", "0.51685816", "0.516329", "0.5159262", "0.5156828", "0.51482", "0.5146248", "0.5145902", "0.51457775", "0.51442194", "0.51441956", "0.51438785", "0.513423", "0.5112453", "0.5111325", "0.5111323", "0.51107144", "0.5110397", "0.5110345", "0.5106176", "0.51036304", "0.509976", "0.50955737", "0.5086349", "0.50817466", "0.5080225", "0.5077519" ]
0.0
-1
Created by srbhj on 21102017.
public interface PetsReceived { public void petsReceived(ArrayList<Pet> pets); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void perish() {\n \n }", "private stendhal() {\n\t}", "@Override\n\tpublic void grabar() {\n\t\t\n\t}", "@Override\n\tpublic void comer() {\n\t\t\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void bicar() {\n\t\t\r\n\t}", "@Override\n public void func_104112_b() {\n \n }", "@Override\n\tprotected void getExras() {\n\n\t}", "private static void cajas() {\n\t\t\n\t}", "@Override\n public void init() {\n\n }", "@Override\r\n\tpublic void comer() \r\n\t{\n\t\t\r\n\t}", "@Override\r\n\tpublic void tires() {\n\t\t\r\n\t}", "public final void mo51373a() {\n }", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "@Override\n\tpublic void init() {\n\t\t\n\t}", "private void poetries() {\n\n\t}", "@Override\n\tpublic void gravarBd() {\n\t\t\n\t}", "@Override\n\tpublic void anular() {\n\n\t}", "@Override\n\tpublic void nadar() {\n\t\t\n\t}", "@Override\r\n\tpublic void dormir() {\n\t\t\r\n\t}", "@Override\r\n\t\tpublic void init() {\n\t\t\t\r\n\t\t}", "@Override\n\tpublic void entrenar() {\n\t\t\n\t}", "@Override\n\tprotected void interr() {\n\t}", "@Override\n protected void initialize() {\n\n \n }", "@Override\r\n\tpublic void rozmnozovat() {\n\t}", "private void init() {\n\n\t}", "@Override\n public void init() {\n }", "@Override\n void init() {\n }", "@Override\r\n\t\t\tpublic void annadir() {\n\r\n\t\t\t}", "@Override\n protected void getExras() {\n }", "public void mo38117a() {\n }", "@Override\n public int describeContents() { return 0; }", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n\tpublic void init() {\n\n\t}", "@Override\n public void init() {\n\n }", "@Override\n public void init() {\n\n }", "public void gored() {\n\t\t\n\t}", "@Override\n public void init() {}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void init() {\n\t\t\r\n\t}", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n protected void initialize() {\n }", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\n\tprotected void initialize() {\n\t\t\n\t}", "@Override\r\n\tpublic void init() {}", "@Override\n protected void init() {\n }", "@Override\n protected void initialize() \n {\n \n }", "public void mo4359a() {\n }", "@Override\n\tpublic void sacrifier() {\n\t\t\n\t}", "private void m50366E() {\n }", "protected boolean func_70814_o() { return true; }", "@Override\r\n\t\t\tpublic void ayuda() {\n\r\n\t\t\t}", "private void kk12() {\n\n\t}", "@Override\n\tpublic void nghe() {\n\n\t}", "@Override\n\tpublic void init()\n\t{\n\n\t}", "@Override\r\n\tpublic void init()\r\n\t{\n\t}", "@Override\n public void memoria() {\n \n }", "@Override\n\tpublic void init() {\n\t}", "@Override\r\n\tpublic void anularFact() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tpublic void dibujar() {\n\t\t\r\n\t}", "@Override\r\n\tprotected void initialize() {\r\n\t\t\r\n\t\t\r\n\t}", "private void init() {\n\n\n\n }", "private void strin() {\n\n\t}", "@Override\n\tprotected void initialize() {\n\n\t}", "@Override\n public void inizializza() {\n\n super.inizializza();\n }", "@Override\n\tpublic void jugar() {\n\t\t\n\t}", "@Override\n public void initialize() { \n }", "private Rekenhulp()\n\t{\n\t}", "@Override\n\tpublic void ligar() {\n\t\t\n\t}", "Constructor() {\r\n\t\t \r\n\t }", "@Override\n\tpublic void einkaufen() {\n\t}", "@Override\n\tpublic void one() {\n\t\t\n\t}", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "public void mo55254a() {\n }", "@Override\n\t\tpublic void init() {\n\t\t}", "public void mo6081a() {\n }", "@Override\n public void init() {\n }", "@Override\n public int retroceder() {\n return 0;\n }", "@Override\r\n\tprotected void initialize() {\n\r\n\t}", "@Override\n\tpublic int mettreAJour() {\n\t\treturn 0;\n\t}", "@Override\r\n\tpublic void publierEnchere() {\n\t\t\r\n\t}", "@Override\n\tprotected void initdata() {\n\n\t}", "@Override\n\tpublic void emprestimo() {\n\n\t}" ]
[ "0.5944444", "0.5826009", "0.5774786", "0.5710355", "0.5664571", "0.5664571", "0.56429845", "0.5632048", "0.5607264", "0.5590801", "0.5575239", "0.5575084", "0.55745554", "0.55409795", "0.55409795", "0.55409795", "0.55409795", "0.55409795", "0.5533713", "0.55269146", "0.5524366", "0.5520874", "0.55145025", "0.55124426", "0.5509696", "0.5508513", "0.55076206", "0.55062985", "0.54979867", "0.5489614", "0.548063", "0.54789156", "0.54507047", "0.544924", "0.5434237", "0.542375", "0.542375", "0.542375", "0.54182184", "0.54182184", "0.5412716", "0.5402549", "0.5401879", "0.5401879", "0.5401879", "0.54004794", "0.54004794", "0.54004794", "0.5390317", "0.5390317", "0.5390317", "0.5390317", "0.5390317", "0.5390317", "0.5389553", "0.5389553", "0.5384812", "0.5381722", "0.53807837", "0.5362102", "0.5358143", "0.53476536", "0.53452706", "0.5344641", "0.53365386", "0.53358865", "0.53307617", "0.5330702", "0.53287095", "0.53268635", "0.53204554", "0.53118676", "0.53118676", "0.5310185", "0.53095406", "0.5308999", "0.5307592", "0.5304593", "0.5275662", "0.52697426", "0.52650875", "0.5260111", "0.5259189", "0.5258161", "0.5253379", "0.5252866", "0.5252866", "0.5252866", "0.5252866", "0.5252866", "0.5252866", "0.5252866", "0.5217281", "0.52111095", "0.5210194", "0.52099895", "0.5208379", "0.5197049", "0.519107", "0.51787144", "0.51784605" ]
0.0
-1
Scanner sc = new Scanner(new File("taming.in")); PrintWriter pr=new PrintWriter(new FileWriter("taming.out"));
public static void main(String args[]) throws IOException { Scanner sc = new Scanner(System.in); int n=sc.nextInt(); int[] counter=new int[n]; int count=0; //Number of changes needed int count1=0; //Number of sections, where a section starts with a 0 int count2=0; //Section length counter int count3=0;//Count for over counting in 'length' ArrayList<Integer> length=new ArrayList<Integer>(); //section lengths ArrayList<Integer> over=new ArrayList<Integer>();//potential overcounts int tem=0; boolean x=false; for(int i=0; i<n; i++) { counter[i]=sc.nextInt(); if(i==0) { if(counter[i]==1) { count++; counter[0]=0; } count1++; } else if(counter[i]==0) { count1++; if(tem+1==i) over.add(i-1); } else if(counter[i]<=counter[i-1]) { count++; tem=i; count3++; } if(counter[i]==0&&i!=0||i==n-1) { if(i==n-1) { count2++; } if(x) { length.add(count2-count3); } count3=0; x=true; count2=0; } count2++; } Collections.sort(length); //for(int i=0; i<length.size(); i++) //{ // System.out.println(length.get(i)); //} int temp=count; for(int i=1; i<=n; i++) { if(count1-i>0) { for(int j=0; j<count1-i; j++) { temp+=length.get(j); } } else { for(int j=0; j<i-count1; j++) { if(over.size()>j) temp--; } temp+=(i-count1); } //pr.println(temp); System.out.println(temp); temp=count; } sc.close(); //pr.close(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void openFile(){\n\t\ttry{\n\t\t\t//input = new Scanner (new File(\"input.txt\")); // creates file \"input.txt\" or will rewrite existing file\n\t\t\tFile inFile = new File(\"input.txt\");\n\t\t\tinput = new Scanner(inFile);\n\t\t\t//for (int i = 0; i < 25; i ++){\n\t\t\t\t//s = input.nextLine();\n\t\t\t\t//System.out.println(s);\n\t\t\t//}\n\t\t}catch (SecurityException securityException){ // catch errors\n\t\t\tSystem.err.println (\"You do not have the write access to this file.\");\n\t\t\tSystem.exit(1);\n\t\t}catch (FileNotFoundException fnf){// catch errors\n\t\t\tSystem.err.println (\"Trouble opening file\");\n\t\t\tSystem.exit(1);\n\t\t}\n\t}", "public void readAndWrite() {\n Scanner scanner = new Scanner(System.in);\n String s = scanner.nextLine();\n List<String> passedFiles = new ArrayList<>();\n copy(new File(s), true, passedFiles);\n\n }", "private void outputFile() {\n // Define output file name\n Scanner sc = new Scanner(System.in);\n System.out.println(\"What do you want to call this file?\");\n String name = sc.nextLine();\n\n // Output to file\n Path outputFile = Paths.get(\"submissions/\" + name + \".java\");\n try {\n Files.write(outputFile, imports);\n if (imports.size() > 0)\n Files.write(outputFile, Collections.singletonList(\"\"), StandardOpenOption.APPEND);\n Files.write(outputFile, lines, StandardOpenOption.APPEND);\n } catch (IOException e) {\n e.printStackTrace();\n }\n\n }", "public static void main(String[] args) throws IOException {\n\t\tFile file = new File(\"fileAAA.txt\");\r\n\t\tPrintWriter output = new PrintWriter(file);\r\n\t\t\r\n\t\t//write name and age to file\r\n\t\toutput.println(\"Homer Akin\");\r\n\t\toutput.println(49);\r\n\t\toutput.close();\r\n\t\t\r\n\t\tScanner input = new Scanner(file);\r\n\t\tString name = input.nextLine();\r\n\t\tint age = input.nextInt();\r\n\t\t\r\n\t\tSystem.out.printf(\"Name: %s \\nAge : %d\",name, age);\t\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t}", "public static void main(String[] arg) {\n\t\tBufferedReader br = new BufferedReader(\r\n\t\t new FileReader(\"input.in\"));\r\n\r\n\t\t// PrintWriter class prints formatted representations\r\n\t\t// of objects to a text-output stream.\r\n\t\tPrintWriter pw = new PrintWriter(new\r\n\t\t BufferedWriter(new FileWriter(\"output.in\")));\r\n\r\n\t\t// Your code goes Here\r\n\r\n\t\tpw.flush();\r\n\t\tScanner sc = new Scanner(System.in);\r\n\t\tString x = sc.nextLine();\r\n\r\n\t\tSystem.out.println(\"hello world \" + x);\r\n\t}", "public static void files(Scanner input) throws FileNotFoundException { \n File inputName = inputVerify(input); // call inputVerify method to get the name of the input file \n\n System.out.print(\"Output file name: \"); // ask user for output file name and save it to outputFile variable \n\t\tString outputName = input.next();\n\n Scanner inputFile = new Scanner(inputName); // reads input file\n\n // creates a new PrintStream object to print to the output file\n PrintStream output = new PrintStream(new File(outputName)); \n\n // while loop that runs as long as the input file has another line\n while (input.hasNextLine()){\n String line = inputFile.nextLine(); // reads entire line\n output.println(line + \":\"); // prints name to file\n String scoreLine = inputFile.nextLine(); // reads next line\n abCount(scoreLine, output); // call abCount method\n }\n }", "public static void main(String[] args) throws java.io.IOException {\n\t\tPrintWriter pw = new PrintWriter (new FileWriter(\"writefile\"));\r\n\t\tSystem.out.print(\"Please enter Phone Number: \");\r\n\t\tphoneNumber=input.next();\r\n\t\tSystem.out.print(\"Please enter Contact Name: \");\r\n\t\tcontactName=input.next();\r\n\t\tSystem.out.println(\"Name: \" + contactName + \"\\tNumber: \" + phoneNumber);\r\n\t\tSystem.out.println(\"Starting printing to text file...\");\r\n\t\tpw.println(\"Name: \" + contactName + \" <Number: \" + phoneNumber);\r\n\t\tpw.close();\r\n\t\t\r\n\r\n\t}", "public static void echoFile(Scanner in) {\n }", "public void blankremover(String args) {\r\n\r\n Scanner file;\r\n PrintWriter writer;\r\n\r\n try {\r\n\r\n file = new Scanner(new File(args));\r\n writer = new PrintWriter(\"gpstest100.txt\");\r\n\r\n while (file.hasNext()) {\r\n String line = file.nextLine();\r\n if (!line.isEmpty()) {\r\n writer.write(line);\r\n writer.write(\"\\n\");\r\n }\r\n }\r\n\r\n file.close();\r\n writer.close();\r\n\r\n } catch (FileNotFoundException ex) {\r\n //Logger.getLogger(Test.class.getName()).log(Level.SEVERE, null, ex);\r\n \t \r\n } \r\n \r\n}", "public static void main(String[] args) // FileNotFoundException caught by this application\n {\n\n Scanner console = new Scanner(System.in);\n System.out.print(\"Input file: \");\n String inputFileName = console.next();\n System.out.print(\"Output file: \");\n String outputFileName = console.next();\n\n Scanner in = null;\n PrintWriter out =null;\n\n File inputFile = new File(inputFileName);\n try\n {\n in = new Scanner(inputFile);\n out = new PrintWriter(outputFileName);\n\n double total = 0;\n\n while (in.hasNextDouble())\n {\n double value = in.nextDouble();\n int x = in.nextInt();\n out.printf(\"%15.2f\\n\", value);\n total = total + value;\n }\n\n out.printf(\"Total: %8.2f\\n\", total);\n\n\n } catch (FileNotFoundException exception)\n {\n System.out.println(\"FileNotFoundException caught.\" + exception);\n exception.printStackTrace();\n }\n catch (InputMismatchException exception)\n {\n System.out.println(\"InputMismatchexception caught.\" + exception);\n }\n finally\n {\n\n in.close();\n out.close();\n }\n\n }", "public static void main(String[] args) throws FileNotFoundException {\n\n\t\tFile file = new File(\"B:\\\\output.txt\");\n\t\t\n\t\tScanner input = new Scanner(file);\n\t\t\n\t\twhile(input.hasNextLine()) {\n\t\t\tString tmp = input.nextLine();\n\t\t\t\n\t\t\tSystem.out.println(tmp);\n\t\t}\n\t\tinput.close();\n\t}", "public static void main(String[] args) throws IOException {\nFileInputStream fin=new FileInputStream(\"C:\\\\\\\\Users\\\\\\\\Dell\\\\\\\\Desktop\\\\\\\\input.txt\");\nFileOutputStream fout=new FileOutputStream(\"C:\\\\\\\\\\\\\\\\Users\\\\\\\\\\\\\\\\Dell\\\\\\\\\\\\\\\\Desktop\\\\\\\\\\\\\\\\output.txt\");\nint c=0;\nwhile((c=fin.read())!=-1)\n{\n\tfout.write(c);\n}\nSystem.out.println(\"written completed\");\n\t}", "public static void main(String[] args){\n\t\tBufferedReader indata = new BufferedReader(new InputStreamReader(System.in));\r\n\t\tString input=null;\r\n\t\ttry {\r\n\t\t\tinput=indata.readLine();\r\n\t\t} catch (IOException e1) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te1.printStackTrace();\r\n\t\t}\r\n\t\t\r\n\t\tFile file = new File(\"d:/addfile.txt\"); \r\n try { \r\n file.createNewFile();\r\n } catch (IOException e) { \r\n // TODO Auto-generated catch block \r\n e.printStackTrace(); \r\n }\r\n \r\n byte writebyte[] = new byte[1024];\r\n writebyte=input.getBytes();\r\n try{\r\n \tFileOutputStream in = new FileOutputStream(file);\r\n \ttry{\r\n \t\tin.write(writebyte, 0, writebyte.length); \r\n in.close();\r\n \t} catch (IOException e) { \r\n // TODO Auto-generated catch block \r\n e.printStackTrace(); \r\n } \r\n } catch (FileNotFoundException e) { \r\n // TODO Auto-generated catch block \r\n e.printStackTrace(); \r\n }\r\n \r\n if(input.equals(\"print\")){\r\n \ttry{\r\n \t\tFileInputStream out = new FileInputStream(file); \r\n \t\tInputStreamReader outreader = new InputStreamReader(out);\r\n \t\tint ch = 0;\r\n \t\twhile((ch=outreader.read())!=-1){\r\n \t\t\tSystem.out.print((char) ch);\r\n \t\t}\r\n \t\toutreader.close();\r\n \t}catch (Exception e) { \r\n \t\t// TODO: handle exception \r\n \t} \r\n }\r\n\t}", "public static void main(String[] args) throws IOException {\n\t\tFileWriter fw = new FileWriter(\"Names.txt\");\n\t\tPrintWriter outputFile = new PrintWriter(fw);\n\t\toutputFile.println(\"Matthew\");\n\t\toutputFile.println(\"Mark\");\n\t\toutputFile.println(\"Luke\");\n\t\toutputFile.close();\n\t\t\n\t\t//read from a file\n\t\tFile file = new File(\"Names.txt\");\n\t\tScanner inputFile = new Scanner(file);\n\t\t\n\t\twhile(inputFile.hasNext()) {\n\t\t\tString name = inputFile.nextLine();\n\t\t\tSystem.out.println(name);\n\t\t}\n\t\tinputFile.close();\n\t\t\n\t}", "public static void main(String[] args) throws FileNotFoundException {\n Scanner scanner = new Scanner(new FileInputStream(\"/Users/guoziren/IdeaProjects/剑指offer for Java/src/main/java/com/ustc/leetcode/algorithmidea/dynamicprogramming/input.txt\"));\n }", "public static void main(String[] args) throws FileNotFoundException {\n\t\tFile file = new File(\"Score.txt\");\r\n\t\tif(file.exists())\r\n\t\t{\r\n\t\t\tSystem.out.println(\"File is already exist! \");\r\n\t\t\tSystem.exit(0);\r\n\t\t}\r\n\t\t\r\n\t\tPrintWriter output = new PrintWriter(file);\r\n\t\t\r\n\t\toutput.print(\"John T Smith \");\r\n\t\toutput.println(90);\r\n\t\toutput.print(\"Eric asd asd: \");\r\n\t\toutput.println(80);\r\n\t\t\r\n\t\toutput.close();\r\n\t}", "public void whatGame() throws IOException{\n try{\n inFile = new Scanner(new File(\"output.txt\"));\n } catch (InputMismatchException e) {\n System.err.printf(\"ERROR: Cannot open %s\\n\", \"output.txt\");\n System.exit(1);\n }\n \n gameNumber = inFile.nextInt();\n System.out.println(gameNumber);\n inFile.close();\n \n try {\n outFile = new PrintWriter(\"output.txt\");\n } catch (IOException e) {\n e.printStackTrace();\n System.exit(1);\n }\n outFile.print(gameNumber+1);\n outFile.close();\n \n }", "public static void main(String[] args) throws IOException {\n\t\t FileInputStream file=new FileInputStream(\"C:\\\\Users\\\\DELL\\\\Desktop\\\\test.txt\");\r\n Scanner scan=new Scanner(file);\r\n while(scan.hasNextLine()){\r\n \t System.out.println(scan.nextLine());\r\n }\r\n \r\n file.close();\r\n\t}", "public static void main(String[] args) {\n\t\tSystem.out.println(\"Hudai\");\r\n\t\t\r\n\t\ttry {\r\n\t\t\t//System.setIn(new Scanner(new File(E:\\\\hudai\\\\filetry.txt)));\r\n\t\t\tSystem.setOut(new PrintStream(new FileOutputStream( new File(\"E:\\\\hudai\\\\filetry.txt\"))) );\r\n\t\t\tSystem.out.println(\"Happy to see \");\r\n\t\t\tSystem.out.println(\"মোঃ জুবায়ের ইবনে মোস্তফা\");\r\n\t\t\tSystem.out.println(\"Nothing\");\r\n\t\t\t\r\n\t\t\tSystem.setOut( new PrintStream(new FileOutputStream(FileDescriptor.out)));\r\n\t\t\tSystem.out.println(\"Happy to see \");\r\n\t\t\tSystem.out.println(\"Nothing\");\r\n\t\t} catch (FileNotFoundException e) {\r\n\t\t\t// TODO Auto-generated catch block\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "public void outputToFile(String filemame)\n {\n }", "public static void appendFile(PrintWriter pw, String file) throws IOException {\n\t\tfw = new FileWriter(file, true);\n\t\tmyFile = new File(file);\n\t\t//allows me to read file\n\t\tinFile = new Scanner(myFile);\n\t\t\n\t}", "public static void createCleanFile(Scanner in) {\n }", "public EnigmaFile() throws Exception\n {\n\n String path = Main.class.getClassLoader().getResource(\"filein.txt\").getPath();\n File currentDirectory=new File(path);\n finstream = new FileInputStream(currentDirectory);\n\n\n String pathToWrite = path.replaceFirst(\"filein.txt\",\"fileout.txt\");\n File outputFile = new File(pathToWrite);\n br = new BufferedReader(new InputStreamReader(finstream));\n outputFile.createNewFile();\n FileWriter fileWrite = new FileWriter(outputFile.getAbsoluteFile());\n writer = new BufferedWriter(fileWrite);\n\n\n }", "public static void main (String[] args) throws IOException\n {\n Scanner fileScan, lineScan;\n String fileName;\n\n Scanner scan = new Scanner(System.in);\n\n System.out.print (\"Enter the name of the input file: \");\n fileName = scan.nextLine();\n fileScan = new Scanner(new File(fileName));\n\n // Read and process each line of the file\n\n\n\n\n }", "public void setupFiles() {\n File inputDataFile = new File(inputFileName);\n try {\n inputFile = new Scanner(inputDataFile);\n FileWriter outputDataFileOA = new FileWriter(outputFileNameOA);\n FileWriter outputDataFileLL = new FileWriter(outputFileNameLL);\n outputFileOA = new PrintWriter(outputDataFileOA);\n outputFileLL = new PrintWriter(outputDataFileLL);\n outputFileOA.println(\"Output from open addressing hash table:\");\n outputFileOA.println();\n outputFileLL.println(\"Output from linked list hash table:\");\n outputFileLL.println();\n } catch (IOException e) {\n e.printStackTrace();\n }\n }", "public static void Print(String fileName)\r\n {\n File file = new File(System.getProperty(\"user.dir\")+\"\\\\\"+fileName+\".txt\"); \r\n \r\n try \r\n {\r\n Scanner sc = new Scanner(file);\r\n \r\n while (sc.hasNextLine()) \r\n {\r\n System.out.println(sc.nextLine());\r\n }\r\n }\r\n catch (FileNotFoundException ex) \r\n {\r\n Logger.getLogger(TxtReader.class.getName()).log(Level.SEVERE, null, ex);\r\n }\r\n \r\n \r\n }", "public static void main(String[] args) throws FileNotFoundException {\n\t\tFile inFile = new File(\"result/in.txt\");\n\t\tFile outFile = new File(\"result/out.txt\");\n\t\tint begin = 4;\n\t\t\n\t\tScanner cs = new Scanner(inFile);\n\t\tPrintWriter out = new PrintWriter(outFile);\n\t\t\n\t\twhile(cs.hasNextLine())\n\t\t{\n\t\t\tString line = cs.nextLine();\n\t\t\tline = line.substring(begin);\n\t\t\tout.println(line);\n\t\t}\n\t\tcs.close();\n\t\tout.close();\n\t\t\n\t}", "public static void main( String[] args ) throws Exception\n {\n ArrayList<String> sortedNames = new ArrayList<>();\n\n //accessing the input file\n File file = new File(\"src\\\\main\\\\java\\\\ex41\\\\exercise41_input.txt\");\n\n //directing scanner to read from input file\n Scanner input = new Scanner(file);\n\n\n //creating an output file\n File orderedNamesFile = new File(\"exercise41_output.txt\");\n\n //accessing the ability to write in output file\n FileWriter outputFile = new FileWriter(orderedNamesFile);\n\n\n /*using a while loop to read each line from input file and then add it to the arraylist sortedNames\n until there are no more lines*/\n while (input.hasNextLine()) {\n String name = input.nextLine();\n sortedNames.add(name);\n }\n\n //using collections function to sort the names in the arraylist\n Collections.sort(sortedNames);\n\n\n //writing in output file\n outputFile.write(\"\\nTotal of \" + sortedNames.size() + \" names: \\n\");\n outputFile.write(\"------------------------\\n\");\n\n\n //adding in the sorted names in arraylist to the output file\n for(String n : sortedNames)\n {\n outputFile.write(n + \"\\n\");\n }\n\n\n }", "public static void main(String[] args) throws IOException {\n\n\t\tSystem.out.println(\"Please enter the name of the file\");\n\t\tScanner input = new Scanner(System.in);\n\t\tString fileName = input.next();\n\t\tSystem.out.println(\"Would you like to write all words including duplicates? Ente 'yes' for \"\n\t\t\t\t+ \"all words including duplicates. Enter 'no' to write words without duplicates\");\n\t\tString duplicates = input.next();\n\t\t\n\t\tFile file = new File(\"C:\\\\NewWorkspace\\\\Lekcija15\\\\src\\\\Vjezbe\\\\\" + fileName);\n\t\tif(!file.exists()){\n\t\t\tSystem.out.println(\"File name \" + fileName + \" does NOT exist\");\n\t\t\tSystem.exit(0);\n\t\t}\n\t\tinput.close();\n\t\t\n\t\tSet<String> wordsSingle = new TreeSet<>();\n\t\tList<String> wordsDuplicates = new ArrayList<>();\n\n\t\tScanner read = new Scanner(file);\n\t\tString word;\n\n\t\twhile(read.hasNext()){\n\t\t\tword = read.next();\n\t\t\tif(duplicates.equals(\"yes\"))\n\t\t\t\twordsDuplicates.add(word);\n\t\t\telse\n\t\t\t\twordsSingle.add(word);\n\t\t}\n\t\tread.close();\n\t\t\n\t\tif(duplicates.equals(\"yes\")){\n\t\t\tCollections.sort(wordsDuplicates);\n\t\t\tfor(String words: wordsDuplicates)\n\t\t\t\tSystem.out.println(words);\n\t\t}\n\t\telse{\n\t\t\tfor(String words: wordsSingle)\n\t\t\t\tSystem.out.println(words);\n\t\t}\n\t}", "public static void writeFile(String inputFile, String outputFile, String[] encodings){\n File iFile = new File(inputFile);\n File oFile = new File(outputFile);\n //try catch for creating the output file\n try {\n //if it doesn't exist it creates the file. else if clears the output file\n\t if (oFile.createNewFile()){\n System.out.println(\"File is created!\");\n\t } else{\n PrintWriter writer = new PrintWriter(oFile);\n writer.print(\"\");\n writer.close();\n System.out.println(\"File cleared.\");\n\t }\n }\n catch(IOException e){\n e.printStackTrace();\n }\n //try catch to scan the input file\n try {\n Scanner scan = new Scanner(iFile);\n PrintWriter writer = new PrintWriter(oFile);\n //loop to look at each word in the file\n while (scan.hasNext()) {\n String s = scan.next();\n //loop to look at each character in the word\n for(int i = 0; i < s.length(); i++){\n if((int)s.charAt(i)-32 <= 94) {\n writer.print(encodings[(int)s.charAt(i)-32]);\n }\n }\n //gives the space between words\n writer.print(encodings[0]);\n }\n scan.close();\n }\n catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n }", "public static void main(String[] args) throws Exception {\n FileOutputStream file = new FileOutputStream(\"randoms.txt\");\n PrintWriter output = new PrintWriter(file);\n\n //write 100 random numbers to the file\n\n\n\n\n //open the file for input\n\n\n\n\n //print the sorted array on the screen\n\n\n\n}", "public Game(BufferedReader in, PrintWriter out) {\n \tthis.in= in;\n \tthis.out =out;\n}", "public static void main(String[] args) throws IOException {\n PrintWriter outputFile = new PrintWriter(\"ResultFile.txt\");\n\n outputFile.println(\"Line 1\");\n outputFile.println(\"Line 2\");\n outputFile.println(\"Line 3\");\n outputFile.println(\"Line 4\");\n\n\n outputFile.close();\n\n }", "public static void main(String[] args) throws IOException{\n\t\t\r\n\t\tScanner sc = new Scanner(new FileInputStream(\"leitura.txt\")); //Declarando o arquivo de entrada //classe Scanner importada do pacote java.util \t\t \r\n\t\tPrintStream ps = new PrintStream(\"saida.txt\"); //Declarando o arquivo de saida //classe PrintStream importada do pacote java.io\r\n\t \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \r\n\t\t\r\n\t\twhile( sc.hasNextLine() ){ //O metodo boolean hasNextLine() return true se houver uma proxima linha\r\n\t\t\tString linha = sc.nextLine(); //Lendo uma linha do arquivo de entrada\r\n\t\t\tps.println(linha);\t\t\t //Escrevendo no arquivo de saida\r\n\t\t\t\r\n\t\t}//while\r\n\t\t\r\n\t\tps.close(); //Fechando file de saida\r\n\t\tsc.close(); //Fechando file de entrada\r\n\t \r\n\t}", "public void printToFile(AI input) {\n\t\ttry {\n\t\t\t// Create file\n\t\t\tFileWriter fstream = new FileWriter(FILENAME);\n\t\t\tBufferedWriter out = new BufferedWriter(fstream);\n\t\t\tout.write(input.toString() + \"\\n\");\n\t\t\t// Close the output stream\n\t\t\tout.close();\n\t\t} catch (Exception e) { // Catch exception if any\n\t\t\tSystem.err.println(\"Error: \" + e.getMessage());\n\t\t}\n\t}", "private static void inputs(Scanner fileScanner) {\n\t\tSystem.out.printf(\"You will now need to enter in the correct pathway to the files containing: \\n\\t1.) RNA table\\n\\t2.) RNA strand\\n\\t3.) Output Protien strand (this will create a new file)\\n\");\n\t\tSystem.out.println(\"Example pathway: C:/CSC142_143/DataFiles/RNATable.txt\");\n\t\tSystem.out.print(\"Please enter file pathway for the RNA Table: \");\n\t\tsetRNATablePathway(fileScanner.next());\n\t\tSystem.out.print(\"Please enter file pathway for the RNA Strand: \");\n\t\tsetRNAStrandPathway(fileScanner.next());\n\t\tSystem.out.print(\"Please enter file pathway for the decoded protien: \");\n\t\tsetRNAOutPathway(fileScanner.next());\n\t\tfileScanner.close();\n\t\t\n\t}", "public void fileOpen () {\n\t\ttry {\n\t\t\tinput = new Scanner(new File(file));\n\t\t\tSystem.out.println(\"file created\");\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(\"file could not be created\");\n\t\t}\n\t}", "public static void main(String[] args)throws Exception {\n\t\tSystem.out.println(\"=======1\");\r\n\t\tFileInputStream fi1 = new FileInputStream(\"d:/test/test.txt\");\r\n\t\tint ch1;\r\n\t\twhile ((ch1=fi1.read())!=-1) {\r\n\t\t\tSystem.out.print((char)ch1);\r\n\t\t}\r\n\t\tfi1.close();\r\n\t\t\r\n\t\tSystem.out.println();\r\n\t\tSystem.out.println(\"=======2\");\r\n\t\tFileInputStream fi2 = new FileInputStream(\"d:/test/test.txt\");\r\n\t\tint ch2;\r\n\t\tbyte[] bt = new byte[1024];\r\n\t\tint i=0;\r\n\t\twhile((ch2= fi2.read())!=-1) {\r\n\t\t\tbt[i] = (byte)ch2;\r\n\t\t\ti++;\r\n\t\t}\r\n\t\tSystem.out.println(new String(bt));\r\n\t\tfi2.close();\r\n\t\t\r\n\t\tSystem.out.println(\"=======3\");\r\n\t\tFileReader fReader =new FileReader(\"d:/test/test.txt\");\r\n\t\tBufferedReader bReader=new BufferedReader(fReader);\r\n\t\tString str = null;\r\n\t\twhile((str = bReader.readLine())!=null) {\r\n\t\t\tSystem.out.println(str);\r\n\t\t}\r\n\t\tbReader.close();\r\n\t\tfReader.close();\r\n\t\t\r\n\t\tSystem.out.println(\"=======4\");\r\n\t\tScanner sc = new Scanner (new File(\"d:/test/add.txt\"));\r\n\t\tint hap=0,value=0;\r\n\t\twhile(sc.hasNext()) {\r\n\t\t\tvalue = sc.nextInt();\r\n\t\t\tSystem.out.println(\"Êý×Ö:\"+value);\r\n\t\t\thap+=value;\r\n\t\t}\r\n\t\tSystem.out.println(\"ºÍ:\"+hap);\r\n\t\tsc.close();\r\n\t\t\r\n\t\tSystem.out.println(\"=======6\");\r\n\t\tFileWriter fw6 = new FileWriter(\"d:/test/fi6.txt\");\r\n\t\tScanner sc6= new Scanner(System.in);\r\n\t\tString str6=null; \r\n\t\twhile(!(str6=sc6.nextLine()).equals(\"\")) {\r\n\t\t\tfw6.write(str6 +\"\");\r\n\t\t}\r\n\t\tfw6.close();\r\n\t\t\r\n\t\tSystem.out.println(\"=======5\");\r\n\t\tFileOutputStream fos = new FileOutputStream(\"d:/test/fi5.txt\");\r\n\t\tint ch;\r\n\t\twhile((ch = System.in.read())!=13) {\r\n\t\t\tfos.write((byte)ch);\r\n\t\t}\r\n\t\tfos.close();\r\n\t\t\r\n\t\tSystem.out.println(\"=======7\");\r\n\t\tFileInputStream fi7 = new FileInputStream(\"c:/windows/win.ini\");\r\n\t\tFileOutputStream fo7 = new FileOutputStream(\"d:/test/fi7.txt\");\r\n\t\tint ch7;\r\n\t\twhile((ch7 = fi7.read())!=-1) {\r\n\t\t\t fo7.write((byte)ch7);\r\n\t\t}\r\n\t\tSystem.out.println(\"½áÊø\");\r\n\t\tfi7.close();\r\n\t\tfo7.close();\r\n\t\t\r\n\t\tSystem.out.println(\"=======8\");\r\n\t\tFileInputStream fi8 = new FileInputStream(args[0]);\r\n\t\tFileOutputStream fo8 = new FileOutputStream(args[1]);\r\n\t\tint ch8;\r\n\t\twhile((ch8 = fi8.read())!=-1) {\r\n\t\t\t fo8.write((byte)ch8);\r\n\t\t}\r\n\t\tSystem.out.println(\"½áÊø\");\r\n\t\tfi8.close();\r\n\t\tfo8.close();\r\n\t}", "public void convertInputToOutput() throws FileNotFoundException {\n PrintWriter outputFile = null;\n Scanner input = null;\n int eval = 0;\n String post = \"\";\n try {\n File file = new File(\"..\\\\COSC602_P3_Input.txt\");\n outputFile = new PrintWriter(\"..\\\\COSC602_P3_Output_bkinney0.txt\");\n input = new Scanner(file);\n }\n catch(FileNotFoundException ex){\n System.out.println(\"Error openeing files\");\n throw ex;\n }\n while (input.hasNextLine()) {\n \n String line = input.nextLine();\n String exp = line.replaceAll(\"\\\\s\", \"\"); \n if (!exp.isEmpty()){\n outputFile.println(\"Original Infix: \" + line);\n try{\n post = this.convertInfix(exp); \n }\n catch(NumberFormatException numberException){\n outputFile.println(\"**Invalid Expression** \\n\\n\");\n continue; \n }\n try{\n eval = this.evalPostfix(post);\n }\n catch(NullPointerException nullException){\n outputFile.println(\"**Invalid Expression** \\n\\n\");\n continue; \n } \n \n outputFile.println(\"Corresponding Postfix: \" + post ); \n outputFile.println(\"Evaluation Result: =\"+eval +\" \\n\\n\");\n }\n } \n \n input.close();\n outputFile.close();\n }", "public static void main(String args[]) throws FileNotFoundException{\n\t\tFile file = new File(\"input.txt\");\r\n\t\tScanner scan = new Scanner(file);\r\n\t\twhile (scan.hasNext()) {\r\n\t\t\tString fName = scan.next();\r\n\t\t\tString lName = scan.next();\r\n\t\t\tSystem.out.println(\"Full name is: \" + fName + \" \" + lName);\r\n\t\t}\r\n\t\t\tscan.close();\r\n\t\t\r\n\t}", "static void createNew() \r\n\t {\n boolean flag = false;\r\n Scanner file = new Scanner(System.in);\r\n System.out.println(\"Enter a new file name\");\r\n String newfilename = file.next();\r\n File createfile = new File(\"D:\\\\java_project\\\\\"+newfilename+\".txt\");\r\n try\r\n\t\t {\r\n\t\t flag = createfile.createNewFile();\r\n\t\t System.out.println(\"flag value\" + flag);\r\n\t\t if(!flag)\r\n\t\t {\r\n\t\t \t System.out.println(\"Same file name already exisy\" + createfile.getPath());\r\n\t\t } \r\n\t\t else \r\n\t\t {\r\n\t\t \t System.out.println(\"file is created sucessfully\" + createfile.getPath() + \" created \");\r\n\t\t }\r\n\t\t } \r\n\t\t catch (IOException ioe) \r\n\t\t {\r\n\t\t System.out.println(\"Error while Creating File in Java\" + ioe);\r\n\t\t }\r\n\t\t \r\n\t\t \t }", "public static void main(String[] args) {\ntry\r\n{\r\n\tFileWriter fw= new FileWriter(\"D:/abc.txt\");\r\n\tString s=\"india \\t is my country\";\r\n\tfw.write(s);\r\n\tfw.flush();\r\n\tfw.close();\r\n}\r\ncatch(IOException e)\r\n{\r\n\tSystem.out.println(e);\r\n}\r\n\t}", "public static void main(String args[]) throws IOException {\n\r\n\r\n\r\n launch(args);\r\n\r\n/*\r\n String stemmer = \"Stemmer\";\r\n\r\n\r\n FileInputStream inputStream = new FileInputStream(\"d:\\\\documents\\\\users\\\\talmormi\\\\Downloads\\\\finalStemmer\\\\marge89.txt\");\r\n BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(inputStream));\r\n String line = bufferedReader.readLine();\r\n String[] splitLine1={};\r\n //splitLine1 = line.split(\"~\");\r\n while (line!=null){\r\n splitLine1 = line.split(\"~\");\r\n char firstLetter = splitLine1[0].charAt(0);\r\n if (!(firstLetter >= 'A' && firstLetter <= 'Z') && !(firstLetter >= 'a' && firstLetter <= 'z')) {\r\n FileOutputStream outputStream = new FileOutputStream(\"d:\\\\documents\\\\users\\\\talmormi\\\\Downloads\\\\finalStemmer\\\\postings\" + \"\\\\\" +stemmer+\"numbers.txt\", true);\r\n BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(outputStream));\r\n while (!(firstLetter >= 'A' && firstLetter <= 'Z') && !(firstLetter >= 'a' && firstLetter <= 'z') && line!=null) {\r\n bw.write(line);\r\n bw.newLine();\r\n line = bufferedReader.readLine();\r\n if (line!=null) {\r\n splitLine1 = line.split(\"~\");\r\n firstLetter = splitLine1[0].charAt(0);\r\n }\r\n }\r\n bw.flush();\r\n bw.close();\r\n outputStream.close();\r\n }\r\n else {\r\n //FileOutputStream outputStream = new FileOutputStream(path + \"\\\\\" +stemmer + \"\" +firstLetter + \".txt\", true);\r\n //BufferedWriter bw1= new BufferedWriter(new OutputStreamWriter(outputStream));\r\n while (line!=null && ((firstLetter >= 'A' && firstLetter <= 'Z') || (firstLetter >= 'a' && firstLetter <= 'z'))){\r\n firstLetter = splitLine1[0].toUpperCase().charAt(0);\r\n char nextLetter = splitLine1[0].toUpperCase().charAt(0);\r\n // FileOutputStream outputStream = new FileOutputStream(path + \"\\\\\"+stemmer + \"\" +firstLetter+\".txt\", true);\r\n // BufferedWriter bw1 = new BufferedWriter(new OutputStreamWriter(outputStream));\r\n PrintWriter out = new PrintWriter(new BufferedWriter(new FileWriter(new File(\"d:\\\\documents\\\\users\\\\talmormi\\\\Downloads\\\\finalStemmer\\\\postings\" + \"\\\\\"+stemmer + \"\" +firstLetter+\".txt\"))));\r\n while (line!=null && firstLetter==nextLetter) {\r\n out.println(line);\r\n line = bufferedReader.readLine();\r\n if (line!=null){\r\n splitLine1 = line.split(\"~\");\r\n nextLetter = splitLine1[0].toUpperCase().charAt(0);\r\n }\r\n }\r\n out.close();\r\n }\r\n\r\n }\r\n }\r\n bufferedReader.close();\r\n inputStream.close();\r\n */\r\n\r\n //Searcher searcher = new Searcher();\r\n //searcher.pathQuery(\"D:\\\\לימודים\\\\שנה ג\\\\סמסטר א\\\\אחזור\\\\מנוע חיפוש\\\\queries.txt\");\r\n\r\n /* String s = \"0512\";\r\n String firstWord=s.substring(0,2);\r\n String secondWord=\":\"+ s.substring(2);\r\n\r\n String time = firstWord +secondWord;\r\n double firstnumber = Double.parseDouble(firstWord);\r\n DecimalFormat df = new DecimalFormat(\"#.###\");\r\n firstWord =df.format(firstnumber);\r\n*/\r\n\r\n\r\n /* Parse p = new Parse();\r\n String[] words = {\"1\" , \"Mar\" , \"1994\",};\r\n p.parser(words,\"s\",\"s\");\r\n*/\r\n /* String s= \"4\";\r\n String g =s.substring(s.length()-1);\r\n //if((s.substring(s.length()-1))== null) {\r\n g = s.substring(0, s.length() - 1);\r\n System.out.println(g);\r\n //}\r\n*/\r\n // ReadFile r = new ReadFile(\"C:\\\\Users\\\\USER\\\\Desktop\\\\לימודים\\\\'שנה ג\\\\אחזור מידע\\\\corpus\");\r\n // ReadFile r = new ReadFile(\"d:\\\\documents\\\\users\\\\shamaid\\\\Downloads\\\\corpus\\\\corpus\");\r\n // r.ReadAndSplitFile();\r\n\r\n\r\n /* long \t\t\t\t\tfinishTime \t= System.nanoTime();\r\n System.out.println(\"Time: \" + (finishTime - startTime)/1000000.0 + \" ms\");\r\n long\t\t\ttotalTime = 0;\r\n totalTime += (finishTime - startTime)/1000000.0;\r\n System.out.println(\"Total time: \" + totalTime/60000.0 + \" min\");\r\n*/\r\n/*\r\n Parse parser = new Parse();\r\n\r\n String[] test = {\"Michal\", \"Talmor\", \"Af\", \"bdfa\", \"cadf\", \"Michal\", \"Talmor\", \"ijre\", \"Talmor\", \"Af\"};\r\n\r\n\r\n //parser.parseRange(test,0,\"text\",\"doc1\");\r\n parser.parser(test,\"text\", \"doc1\");\r\n*/\r\n\r\n }", "public static void main(String[] args) throws FileNotFoundException {\n\t\t\t\n\t\tScanner scan = new Scanner(new File(\"input.txt\"));\n\t\t\n\t\tParser parse;\n\t\tCode code = new Code();\n\t\tSymbolTable st = new SymbolTable();\n\t\t\n\t\twhile(scan.hasNextLine()) {\n\t\t\tString inCode = scan.nextLine();\t\n\t\t\tparse = new Parser(inCode);\n\t\t}\n\t\t\n\t}", "public void recordOrder(){ \n PrintWriter output = null;\n try{\n output = \n new PrintWriter(new FileOutputStream(\"record.txt\", true));\n }\n catch(Exception e){\n System.out.println(\"File not found\");\n System.exit(0);\n }\n output.println(Tea);//writes into the file contents of String Tea\n output.close();//closes file\n }", "public static File name(Scanner user) {\n System.out.println(\"Input file name\");\n String fileName = user.nextLine();\n File file = new File(fileName);\n return file;\n }", "public static void main(String[] args) {\n\t\t\n\t\tOutputStream os = null;\n\t\tOutputStreamWriter osw = null;\n\t\tBufferedWriter bw = null;\n\t\tPrintWriter ps = null;\n\t\ttry {\n\t\t\tos = new FileOutputStream(\"test01.txt\",true); //기존 파일에 내용 추가 //File없이 바로 쓰면 디렉터리를 만들어주지 않아 오류\n\t\t\tosw = new OutputStreamWriter(os);\n\t\t\tbw = new BufferedWriter(osw);\n\t\t\tps = new PrintWriter(bw);\n\t\t\t/*\n\t\t\tbw.write(\"문자열스트림으로 변환\");\n\t\t\tbw.newLine();\n\t\t\tbw.write(\"새로운 라인 작성\");\n\t\t\t*/\n\t\t\t\n\t\t\tps.println(\"문자열스트림으로 변환\");\n\t\t\tps.println(\"새로운 라인 작성\");\n\t\t\tps.println(\"한줄작성후 개행\");\n\t\t\t\n\t\t\t\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} catch (IOException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} finally {\n\t\t\ttry {\n\t\t\t\tif(ps != null) {ps.close();}\n\t\t\t\tif(bw != null) {bw.close();}\n\t\t\t\tif(osw != null) {osw.close();}\n\t\t\t\tif(os != null) {os.close();}\n\t\t\t} catch (IOException e) {\n\t\t\t\t// TODO Auto-generated catch block\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t}", "public void readfiles1(String file_name){\n \n\n try{\n File fname1 = new File(file_name);\n Scanner sc = new Scanner(fname1);\n \n while (sc.hasNext()){\n String temp = sc.nextLine();\n String[] sts = temp.split(\" \");\n outs.addAll(Arrays.asList(sts));\n\n }\n\n // for (int i = 0;i<outs.size();i++){\n // System.out.println(outs.get(i));\n //}\n\n }catch(Exception ex){\n System.out.println(ex.getMessage());\n }\n }", "void readFile()\n {\n Scanner sc2 = new Scanner(System.in);\n try {\n sc2 = new Scanner(new File(\"src/main/java/ex45/exercise45_input.txt\"));\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n while (sc2.hasNextLine()) {\n Scanner s2 = new Scanner(sc2.nextLine());\n while (s2.hasNext()) {\n //s is the next word\n String s = s2.next();\n this.readFile.add(s);\n }\n }\n }", "public void convert(File infile, File outfile) throws IOException, ParseException, NumberFormatException,\n java.text.ParseException {\n outfile = outfile.getAbsoluteFile();\n if (outfile.isDirectory()) {\n outfile = new File(outfile, \"sampletab.pre.txt\");\n }\n \n if (!outfile.getParentFile().exists()) {\n outfile.getParentFile().mkdirs();\n }\n \n convert(infile, new FileWriter(outfile));\n }", "public static void main(String[] args) throws IOException{\n\t\tBufferedReader in =new BufferedReader(new FileReader(input));\r\n\tPrintWriter out = new PrintWriter(new FileWriter(output));\r\n\t\t\r\n\t\tint t = Integer.parseInt(in.readLine());\r\n\t\t\r\n\t\tfor(int i=1; i<=t; i++){\r\n\t\t\tout.print(\"Case #\"+i+\": \");\r\n\t\t\tint n = Integer.parseInt(in.readLine());\r\n\t\t\toneTest(n, in, out);\r\n\t\t\tout.println();\r\n\t\t}\r\n\t\tout.flush();\r\n\t}", "public void generate() throws FileNotFoundException, UnsupportedEncodingException {\n\t\twriter = new PrintWriter(outputFile, \"UTF-8\");\n\t\tFile file = new File(inputFile);\n\t\treader = new Scanner(file);\n\t\tinitializeFile();\n\t\t\n\t\tString line = readLine();\n\t\twhile (line != null) {\n\t\t\tprocess(line);\n\t\t\tline = readLine();\n\t\t}\n\t\t\n\t\tfinishFile();\n\t\twriter.close();\n\t}", "void openFile(String fileName){\n\t\ttry {\n\t\t\tout = new BufferedWriter(new FileWriter(fileName));\n\t\t\tString dateTime = new SimpleDateFormat(\"dd/MM/yyyy HH:mm\").format(new Date()); \n\t\t\t//out.write(\"Início dos testes \" + dateTime + \"\\n\" );\n\t\t} catch (IOException e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\t\n\t}", "public TextFile(Scanner input) {\n \tSystem.out.println(\"Enter your Textfile name: \");\n \tString textfilename = input.nextLine(); \n \ttextFile = new File(textfilename);\n \tthis.checkFile();\n }", "static void save() {\n String fileName, line = \"\"; char answer;\n System.out.print(\"Enter file name to save: \"); fileName = scan.nextLine();\n File file = new File(fileName);\n \n if ( file.isFile() ) {\n System.out.printf(\"WARNING: %s exists.\\n\", fileName);\n System.out.print(\"Overwrite (y/n)? \");\n \n while (line.length() < 1) line = scan.nextLine().toUpperCase();\n answer = line.charAt(0);\n\n switch (answer) {\n case 'N': save(); // reprompt\n case 'Y': break; // save the file\n default: save();\n }\n }\n pgmInf.savePgmFileAs(fileName);\n System.out.println(\"Terrain file saved.\");\n }", "public static void enterNewTXTFile(String input, String id, String newName, String newHandle, String newTime, String newTweet)\n {\n try {\n String str = Integer.parseInt(id)+ \" \" +newName+ \" \" +newHandle+ \" \" +newTime+ \" \" +newTweet+ \" \";\n writer = new BufferedWriter(new FileWriter(input, true)); // continue to write to existing output file\n writer.write(str);\n writer.newLine();\n writer.close();\n \n } catch (Exception e) { System.out.println(e); }\n }", "public static void files() throws IOException {\n\n\n try {\n BufferedReader reader = new BufferedReader(new FileReader(\"D:\\\\Text.txt\"));\n String line;\n while ((line = reader.readLine()) != null) {\n Palindroms.palindromeByReverse(line);\n BufferedWriter writer = new BufferedWriter(new OutputStreamWriter(new FileOutputStream(\"D:\\\\output.txt\")));\n writer.append(line);\n writer.close();\n }\n reader.close();\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n } catch (IOException e) {\n e.printStackTrace();\n } finally {\n System.out.println(\"Bye!\");\n }\n }", "public void writeFile(String data){\n\t\t\n\t\tcurrentLine = data;\n\t\t\n\t\t\ttry{ \n\t\t\t\tFile file = new File(\"/Users/bpfruin/Documents/CSPP51036/hw3-bpfruin/src/phfmm/output.txt\");\n \n\t\t\t\t//if file doesnt exists, then create it\n\t\t\t\tif(!file.exists()){\n\t\t\t\t\tfile.createNewFile();\n\t\t\t\t}\n \n\t\t\t\t//true = append file\n\t\t\t\tFileWriter fileWriter = new FileWriter(file,true);\n \t \tBufferedWriter bufferWriter = new BufferedWriter(fileWriter);\n \t \tbufferWriter.write(data);\n \t \tbufferWriter.close();\n \n \n\t\t\t}catch(IOException e){\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t\n\t\t\n\t}", "public static void main(String[] args) {\n\t\tString[] names;\r\n\t\tnames = new String[] {\"AV\", \"Amit\", \"Abhinav\", \"Sajal\", \"Tarvinder\",\"Punit\",\"Vibhor\"};\r\n\t\tList<String> nameList = Arrays.asList(names);\r\n\t\t\r\n\t\tFile file = new File(\"Name_File.txt\");\r\n\t\twriteToFile(file, nameList);\r\n\t\t\r\n\t\treadFromFile(file);\r\n\r\n\t}", "public ThingToWriteFile(String filename) { \n\t\ttry { \t\n\t\t\tout = new BufferedWriter(new FileWriter(filename));\n\t\t}\n\t\tcatch (FileNotFoundException ee){\n\t\t\tSystem.out.println(\"File \" + filename + \" not found.\");\n\t\t\tSystem.exit(0);\n\t\t}\n\t\tcatch (IOException e){\n\t\t\tSystem.out.println(\"File \" + filename + \" cannot be read.\");\n\t\t\tSystem.exit(0);\n\t\t}\n\t}", "public static void createFile(String path) {\n try {\n Scanner scanner = new Scanner(System.in);\n System.out.println(\"Enter the file name :\");\n String filepath = path+\"/\"+scanner.next();\n File newFile = new File(filepath);\n newFile.createNewFile();\n System.out.println(\"File is Created Successfully\");\n\n } catch (Exception ex) {\n System.out.println(ex.getMessage());\n }\n }", "public static void main(String[] args) {\n\t\tString ruta=\"personas.txt\";\n\t\tFile fichero = new File(ruta);\n\t\tif (!fichero.exists()) {\n\t\t\ttry {\n\t\t\t\tfichero.createNewFile();\n\t\t\t\tSystem.out.println(\"Archivo creado\");\n\t\t\t} catch (Exception e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}else {\n\t\t\ttry {\n\t\t\t\tBufferedWriter bw = new BufferedWriter(new FileWriter(ruta, false));\n\t\t\t\tScanner sc = new Scanner (System.in);\n\t\t\t\tString introducir=\"\";\n\t\t\t\tdo {\n\t\t\t\t\tSystem.out.println(\"Introduce el dni de la persona:\");\n\t\t\t\t\tString dni=sc.nextLine();\n\t\t\t\t\tSystem.out.println(\"Introduce el nombre:\");\n\t\t\t\t\tString nombre=sc.nextLine();\n\t\t\t\t\tSystem.out.println(\"Introduce lo apellidos:\");\n\t\t\t\t\tString apellidos=sc.nextLine();\n\t\t\t\t\tSystem.out.println(\"Introduce la dirección:\");\n\t\t\t\t\tString direccion=sc.nextLine();\n\t\t\t\t\tSystem.out.println(\"Introduce el teléfono:\");\n\t\t\t\t\tString telefono=sc.nextLine();\n\t\t\t\t\tSystem.out.println(\"Introduce el email:\");\n\t\t\t\t\tString email=sc.nextLine();\n\t\t\t\t\tSystem.out.println(\"¿Desea introducir los datos de otra persona?\");\n\t\t\t\t\tintroducir=sc.nextLine();\n\t\t\t\t\tbw.write(dni +\"//\"+nombre +\"//\"+apellidos +\"//\"+direccion +\"//\"+ telefono + \"//\" + email);\n\t\t\t\t\tbw.newLine();\n\t\t\t\t}while(introducir.equalsIgnoreCase(\"si\"));\n\t\t\t\tbw.close();\n\t\t\t} catch (Exception e) {\n\t\t\t\te.printStackTrace();\n\t\t\t}\n\t\t}\n\t}", "public static void main(String args[])throws FileNotFoundException {\n PrintStream diskWriter = new PrintStream(new File(\"please.txt\"));\n\n\n int numbers=0;\n Random myRandom = new Random();\n numbers = myRandom.nextInt(10)+1;\n diskWriter.println(numbers);\n System.out.println(numbers);\n\n\n numbers = myRandom.nextInt(10)+1;\n diskWriter.println(numbers);\n System.out.println(numbers);\n //numbers = myRandom.nextInt(10)+1;\n //diskWriter.println(numbers);\n //System.out.println(diskScanner.next());\n\n //numbers = myRandom.nextInt(10)+1;\n //diskWriter.println(numbers);\n // System.out.println(diskScanner.next());\n\n //numbers = myRandom.nextInt(10)+1;\n //diskWriter.println(numbers);\n // System.out.println(diskScanner.next());\n\n //numbers = myRandom.nextInt(10)+1;\n //diskWriter.println(numbers);\n //System.out.println(diskScanner.next());\n\n // numbers = myRandom.nextInt(10)+1;\n //diskWriter.println(numbers);\n //System.out.println(diskScanner.next());\n\n // numbers = myRandom.nextInt(10)+1;\n // diskWriter.println(numbers);\n // System.out.println(diskScanner.next());\n\n }", "public static void main(String[] args) throws IOException\n {\n \n // Declare Variables \n int count = 0;\n \n // PrintWriter class to create and open new file\n PrintWriter outputFile = new PrintWriter(\"NumbersJamesM.txt\"); \n \n // For loop to add 1 to the number each time\n for (count = 1; count <= 10; count++) // Initilize count to 1,\n { // Run until count is more than 10\n // After each loop add 1 to count. \n \n outputFile.println(count); // Output current count number to outputFile\n \n } \n \n // Close the file \n outputFile.close();\n \n }", "public static void setIO(String inFile, String outFile)\r\n\r\n\t// Opens the input file \"inFile\" and output file \"outFile.\"\r\n\t// Sets the current input character \"current\" to the first character on the input stream.\r\n\r\n\t{\r\n\t\ttry\r\n\t\t{\r\n\t\t\tinStream = new BufferedReader( new FileReader(inFile) ); //Set the BufferedReader to read from \"inFile.\"\r\n\t\t\toutStream = new PrintWriter( new FileOutputStream(outFile) ); //Set PrintWriter to write to the output file \"outFile.\"\r\n\t\t\tcurrent = inStream.read(); //Set current to the first character in the file.\r\n\t\t}\r\n\t\tcatch(FileNotFoundException e) //Output error message if input or output files cannot be found.\r\n\t\t{\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\tcatch(IOException e)\r\n\t\t{\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t}", "public void copy(String file1, String file2) throws FileNotFoundException{\r\n\t\tFile original = new File(file1);\r\n\t\tFile copied = new File(file2);\r\n\t\t\r\n\t\tScanner input = new Scanner(original);\r\n\t\tPrintWriter output = new PrintWriter(copied);//writes new file\r\n\t\t\r\n\t\twhile(input.hasNextLine()){\r\n\t\t\tString next = input.nextLine();\r\n\t\t\toutput.println(next);\t\t\t\r\n\t\t}\r\n\t\toutput.close();\r\n\t\tinput.close();\r\n\t}", "public void writeOut(PrintWriter pw){}", "public static void cleanFile(Scanner in) {\n }", "public void save() throws FileNotFoundException {\n PrintWriter myWriter = new PrintWriter(\"duke.txt\");\n for (Task t : TaskList.getTasklist()) {\n myWriter.println(t.toString());\n }\n myWriter.flush();\n myWriter.close();\n }", "public void addfile() {\n\t\tString name;\r\n\t\tSystem.out.println(\"Enter the file name you want to add\");\r\n Scanner sc = new Scanner(System.in);\r\n name = sc.nextLine();\r\n try {\r\n \t\tFile file = new File(\"g:\\\\LockedMe\\\\\"+name);\r\n \t\tif(file.createNewFile()) {\r\n \t\t\tSystem.out.println(\"New file created\");\r\n \t\t}\r\n \t\telse {\r\n \t\t\tif(file.exists())\r\n \t\t\t{\r\n \t\t\t\tSystem.out.println(\"file already exists\");\r\n \t\t\t}\r\n \t\t\telse\r\n \t\t\t{\r\n \t\t\t\tSystem.out.println(\"file does not exist\");\r\n \t\t\t}\r\n \t\t}\r\n }\r\n catch(Exception e)\r\n {\r\n \t e.printStackTrace();\r\n }\r\n\t}", "void toFile (String fileName);", "public void saveFile() {\n\t\tPrintWriter output = null;\n\t\ttry {\n\t\t\toutput = new PrintWriter(\"/Users/katejeon/Documents/Spring_2020/CPSC_35339/avengers_project/game_result.txt\");\n\t\t\toutput.println(textArea.getText());\n\t\t\toutput.flush();\n\t\t} catch (FileNotFoundException e) {\n\t\t\te.printStackTrace();\n\t\t\tSystem.out.println(\"File doesn't exist.\");\n\t\t} finally {\n\t\t\toutput.close();\n\t\t}\n\t}", "static void createNewFile(String path) \n\t\t{\n\t\tLinkedList<String> defaultData = new LinkedList<String>();\n\t\tdefaultData.add(\"1,Frank,West,98,95,87,78,77,80\");\n\t\tdefaultData.add(\"2,Dianne,Greene,78,94,88,87,95,92\");\n\t\tdefaultData.add(\"3,Doug,Lei,78,94,88,87,95,92\");\n\t\tdefaultData.add(\"4,James,Hewlett,69,92,74,77,89,91\");\n\t\tdefaultData.add(\"5,Aroha,Wright,97,92,87,83,82,92\");\n\t\t\n\t\ttry \n\t\t{\n\t\t\tPrintWriter newFile = new PrintWriter(path, \"UTF-8\"); // Create .txt file in given path\n\t\t\t\n\t\t\tfor (String s : defaultData) \n\t\t\t{\n\t\t\t\tnewFile.println(s); // Write To file\n\t\t\t}\n\t\t\t\n\t\t\tnewFile.close(); // Close File\n\t\t\t\n\t\t} catch (FileNotFoundException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t} catch (UnsupportedEncodingException e) {\n\t\t\t// TODO Auto-generated catch block\n\t\t\te.printStackTrace();\n\t\t}\n\t\t\n\t\tSystem.out.println(\"studentData.txt Created Successfully!\");\n\t\t\n\t}", "public static void main(String[] args){\n File testFile = new File(args[1]);\n File testFile_new = new File(args[2]);\n String all = \"\";\n // read all data\n try {\n Scanner input = null;\n input = new Scanner(testFile);\n while (input.hasNext()){\n all += input.nextLine() + \"\\r\\n\";\n }\n } catch (FileNotFoundException e) {\n e.printStackTrace();\n }\n // print and replace\n System.out.println(all);\n all = all.replaceAll(args[0], \"\");\n // save to other file with replaced\n try{\n PrintWriter output = new PrintWriter(testFile_new);\n output.write(all);\n output.close();\n } catch (FileNotFoundException ex){\n ex.printStackTrace();\n }\n }", "public abstract void saveToFile(PrintWriter out);", "public void recordOrder(){\n PrintWriter output = null;\n try{\n output = \n new PrintWriter(new FileOutputStream(\"record.txt\", true));\n }\n catch(Exception e){//throws exception\n System.out.println(\"File not found\");\n System.exit(0);\n }\n output.println(Coffee);//prints in file contents of Coffee\n output.close();//closes file\n }", "private static void writeToOutput() {\r\n FileWriter salida = null;\r\n String archivo;\r\n JFileChooser jFC = new JFileChooser();\r\n jFC.setDialogTitle(\"KWIC - Seleccione el archivo de salida\");\r\n jFC.setCurrentDirectory(new File(\"src\"));\r\n int res = jFC.showSaveDialog(null);\r\n if (res == JFileChooser.APPROVE_OPTION) {\r\n archivo = jFC.getSelectedFile().getPath();\r\n } else {\r\n archivo = \"src/output.txt\";\r\n }\r\n try {\r\n salida = new FileWriter(archivo);\r\n PrintWriter bfw = new PrintWriter(salida);\r\n System.out.println(\"Índice-KWIC:\");\r\n for (String sentence : kwicIndex) {\r\n bfw.println(sentence);\r\n System.out.println(sentence);\r\n }\r\n bfw.close();\r\n System.out.println(\"Se ha creado satisfactoriamente el archivo de texto\");\r\n } catch (Exception e) {\r\n e.printStackTrace();\r\n }\r\n }", "public void saveGame(){\r\n Scanner in = new Scanner(System.in);\r\n Boolean nameIsFine = false;\r\n String filename;\r\n int input;\r\n do {\r\n System.out.println(\"Filename?\");\r\n filename = this.savePath + File.separator + this.getFilename() + \".ser\";\r\n File newFile = new File(filename);\r\n if(newFile.exists()) {\r\n System.out.println(\"This file already exists.\");\r\n System.out.println(\"Do you want to change the file name?\");\r\n System.out.println(\"Yes: '1', No: '0'.\");\r\n input = in.nextInt();\r\n if (input == 0) {\r\n nameIsFine = true;\r\n } else {\r\n if (input != 1){\r\n System.out.println(\"This is not an option.\");\r\n }\r\n System.out.println(\"Give a different filename.\");\r\n }\r\n } else {\r\n nameIsFine = true;\r\n }\r\n } while(!nameIsFine);\r\n this.save(filename);\r\n }", "public void writeFile()\n\t{\n\t\t//Printwriter object\n\t\tPrintWriter writer = FileUtils.openToWrite(\"TobaccoUse.txt\");\n\t\twriter.print(\"Year, State, Abbreviation, Percentage of Tobacco Use\\n\");\n\t\tfor(int i = 0; i < tobacco.size(); i++)\n\t\t{\n\t\t\tStateTobacco state = tobacco.get(i);\n\t\t\tString name = state.getState();\n\t\t\tString abbr = state.getAbbreviation();\n\t\t\tdouble percent = state.getPercentUse();\n\t\t\tint year = state.getYear();\n\t\t\twriter.print(\"\"+ year + \", \" + name + \", \" + abbr + \", \" + percent + \"\\n\");\n\t\t} \n\t\twriter.close(); //closes printwriter object\n\t}", "public static void main (String arg[]) throws FileNotFoundException {\n\t\t\n \tScanner fin = new Scanner(new FileReader(\"input.txt\"));\n \tPrintWriter writer = new PrintWriter(\"output.txt\");\n\t\t\n\t\twhile (true) {\n\t\t\t\n\t\t\tString input = fin.nextLine();\n\t\t\tif (input.compareTo(\"0\") == 0) break;\n\t\t\t\n\t\t\tboolean[] array = new boolean[input.length()];\n\t\t\tfor (int i = 1; i < input.length(); i++) {\n\t\t\t\tarray[i] = (input.substring(i, i+1).compareTo(\"1\") == 0) ? true : false;\n\t\t\t}\n\t\t\t\n\t\t\tQueue<Integer> answer = new LinkedList<Integer>();\n\t\t\t\n\t\t\tfor (int i = 1; i < input.length(); i++) {\n\t\t\t\t\n\t\t\t\tif (array[i] == false) continue;\n\t\t\t\t\n\t\t\t\tanswer.add(i);\n\t\t\t\t\n\t\t\t\tfor (int j = i; j < input.length(); j += i) {\n\t\t\t\t\tarray[j] = !array[j];\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\twhile (answer.peek() != null) {\n\t\t\t\t\n\t\t\t\tint out = answer.poll();\n\t\t\t\tSystem.out.println(out);\n\t\t\t\twriter.print(out);\n\t\t\t\tif (answer.peek() != null) writer.print(\" \");\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\twriter.println();\n\t\t\t\n\t\t}\n\t\t\n\t\tfin.close();\n\t\twriter.close();\n\t\t\n\t}", "public void input(Scanner in) { \r\n if (in.hasNext()) firstName = in.next();\r\n if (in.hasNext()) lastName = in.next();\r\n\t}", "public void generateOutputFile(String inputFile) {\n\n String outputFile = properties.getProperty(\"output.directory\")\n + properties.getProperty(\"output.file.distinct\");\n\n\n try (PrintWriter out = new PrintWriter(new BufferedWriter(\n new FileWriter(outputFile)))){\n\n loopThroughTokens(out);\n\n\n } catch (FileNotFoundException fileNotFound) {\n fileNotFound.printStackTrace();\n } catch (IOException inputOutputException) {\n inputOutputException.printStackTrace();\n } catch (Exception exception) {\n exception.printStackTrace();\n }\n }", "public static void main(String[] args) {\n Scanner scan =new Scanner(System.in);\n\n System.out.println(\"What's the path to the file?\");\n String path = scan.next();\n System.out.println(\"What text should i put there?\");\n String text = scan.next();\n System.out.println(\"How many lines of it?\");\n int lines = scan.nextInt();\n //while loop for asking number lines>0\n\n writeMoreLinesIntoFile(path, text, lines);\n }", "public static void main (String[] args) {\n \n //initilialize Scanner, pass file input in same directory, pass to boyGirl function\n Scanner input = new Scanner(new File('tas.txt'));\n boyGirl(input);\n }", "public static void main(String[] args) {\n\t\tFile myFile = new File(\"newfile.txt\");\n\t\t/*try {\n\t\t\tboolean isCreated = myFile.createNewFile();\n\t\t\tif(isCreated) {\n\t\t\t\tSystem.out.println(\"Your file is created\");\n\t\t\t} else {\n\t\t\t\tSystem.out.println(\"File wasn't created, or it's already there\");\n\t\t\t}\n\t\t} catch (FileNotFoundException fnf){\n\t\t\tfnf.printStackTrace();\n\t\t} catch (IOException ioe) {\n\t\t\tioe.printStackTrace();\n\t\t} */\n\t\t\n\t\t////////////////////// WRITE TO A FILE //////////////////////////////\n\t\t/*\n\t\t * \n\t\t */\n\t\ttry{\n\t\t byte[] writeArr = {1,2,3,4,5};\n\t\t FileWriter os = new FileWriter(\"newfile.txt\");\n\t\t for(int i = 0; i < writeArr.length ; i++){\n\t\t os.write( writeArr[i] ); \n\t\t }\n\t\t os.close();\n\t\t \n\t\t \n\t\t FileReader is = new FileReader(\"newfile.txt\");\n\t\t BufferedReader bfr = new BufferedReader((is));\n\t\t bfr.readLine()\n\t\t int size = is.available();\n\t\t \n\t\t for(int i=0; i< size; i++){\n\t\t System.out.print(is.read() + \" \");\n\t\t }\n\t\t is.close();\n\t\t }catch(IOException e){\n\t\t System.out.print(\"Exception\");\n\t\t }\t\n\t\t\n\t\t\n\n\t}", "public static void main(String[] args) throws IOException {\r\n\t\t\r\n\t\tScanner sc = new Scanner (System.in);//new File (\"trucks.in\"));\r\n\t\t\r\n\t\tint n = sc.nextInt(); int k = sc.nextInt();\r\n\t\tint ntrucks = 0;\r\n\t\t\r\n\t\tStack <Integer> stack = new Stack <Integer>();\r\n\t\tstack.push(n);\r\n\t\t\r\n\t\twhile (!stack.isEmpty()){\r\n\t\t\tint a = stack.pop();\r\n\t\t\tif (a>k){\r\n\t\t\t\tstack.push(a/2);\r\n\t\t\t\tstack.push(a/2+a%2);\r\n\t\t\t}else{\r\n\t\t\t\tntrucks++;\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\tFileWriter fw = new FileWriter(\"trucks.out\");\r\n\t\t\r\n\t\tfw.write(ntrucks+\"\");\r\n\t\r\n\t\tfw.write(\"\\n\");\r\n\t\tfw.close();\r\n\t}", "public void reWriteFile(String filename,String data) {\n\n if (filename.trim().length() > 0) {\n try {\n PrintWriter output = new PrintWriter(filename);\n\n output.write(data);\n\n output.close();\n } catch (IOException e) {\n System.out.println(\"I/O Error\");\n }\n } else {\n System.out.println(\"Enter a filename:\");\n }\n }", "public static void main(String[] args) throws IOException {\n if(args.length == 0 || args.length == 1 || args.length > 2) {\n\n System.err.println(\" Usage: Lex <inputfile> <outputfile>\");\n \n System.exit(1);\n }\n\n\n // variable declarations\n Scanner input = null;\n \n PrintWriter output = null;\n \n String[] n = null;\n \n String line = null;\n \n int lines = -1;\n \n int lineNumber = 0; \n \n\n // Count the total lines of file\n input = new Scanner(new File (args [0] ));\n \n while( input.hasNextLine () ) {\n \n input.nextLine ();\n \n ++lineNumber;\n }\n\n input.close ();\n \n input = null;\n\n // Recreate Scanner\n input = new Scanner(new File(args[0]));\n\n // creates String array\n n = new String[lineNumber];\n\n // Place all inputs in a String array\n while(input.hasNextLine()) {\n \n n[++lines] = input.nextLine();\n }\n\t \n // Recreate PrintWriter\n output = new PrintWriter(new FileWriter(args[1]));\n \n // create List\n\t List l = new List();\t \n \n \n l.append(0);\n\n // Insertion Sort\n for(int j = 1; j < n.length; ++j) {\n \n String type = n[j];\n\n int i = j - 1;\n \n // move Index to the back of list\n l.moveBack();\n\n // comparing the current line and each line of List\n while(i > -1 && type.compareTo(n[l.get()]) <= 0) {\n \n --i;\n \n l.movePrev();\n }\n \n if(l.index() > -1){\n \n l.insertAfter(j);\n \n }else{\n \n l.prepend(j);\n } \n }\n\n // move Index to front of the list\n l.moveFront();\n\n // Loop control for List for the correct order of output\n while(l.index() > -1) {\n \n output.println(n[l.get()]);\n \n l.moveNext();\n }\n \n // Close input and output\n input.close();\n \n output.close();\n }", "public static void saveDataToFile() {\n DateFormat dateFormat = new SimpleDateFormat(\"yyyy MM dd, HH mm\");\n Date date = new Date();\n String fileName= dateFormat.format(date)+\".txt\";\n\n try {\n PrintWriter writer = new PrintWriter(fileName, \"UTF-8\");\n writer.print(\"Wins: \");\n writer.println(wins);\n writer.print(\"Draws: \");\n writer.println(draws);\n writer.print(\"Losses: \");\n writer.println(loses);\n writer.close();\n System.out.println(\"File Write Successful\");\n } catch (IOException e) {\n\n }\n\n\n }", "public void writeToFile(String s,String outFile) \n\t{\n\t\ttry \n\t\t{\n\t\t\tbw = new BufferedWriter(new FileWriter(outFile));\n\t\t\tbw.write(s);\n\t\t\tMyLogger.writeMessage(\"Results written to file\", MyLogger.DebugLevel.RESULTS);\n\t\t\tbw.close();\n\t\t}\n\t\tcatch(IOException e) {\n\t\t\tSystem.err.println(\"Exception: writing to output.txt\");\n\t\t\tSystem.err.println(\"Exiting\");\n\t\t\tSystem.err.println(e.getMessage());\n\t\t\te.printStackTrace();\n\t\t\tSystem.exit(1);\n\t\t}\n\t\t\n\t}", "public void processInput(String theFile){processInput(new File(theFile));}", "static void printHeader(String fn, PrintWriter out) throws IOException\n{\n\t@SuppressWarnings(\"resource\")\n\tScanner input = new Scanner(new FileInputStream(new File(fn)));\n\twhile(input.hasNext())\n\t{\n\t\tString line = input.nextLine();\n\t\tif(line.length() == 0) continue;\n\t\tif(line.charAt(0) == '#') out.println(line);\n\t\telse break;\n\t}\n}", "public static void processFile(String inputpath, String outputpath)\r\n\t{\r\n\t\ttry {\r\n\t\t\t//create both files\r\n\t\t\tFile input = new File(inputpath);\r\n\t\t\tFile output = new File(outputpath);\r\n\t\t\t//read over the input file and put the results in the output file\r\n\t\t\tFileWriter fw = new FileWriter(output); \r\n\t\t\tScanner scan = new Scanner(input);\r\n\t\t\twhile(scan.hasNextLine()) {\r\n\t\t\t\tString word = scan.nextLine();\r\n\t\t\t\t//this looks for the word in the data structure.\r\n\t\t\t\t//If it exists, it writes it in the output file\r\n\t\t\t\tif(data.search(word)) {\r\n\t\t\t\t\tfw.write(word);\r\n\t\t\t\t} else {\r\n\t\t\t\t\t//If not, it gets the suggestions\r\n\t\t\t\t\tList<String> suggestions = data.suggest(word);\r\n\t\t\t\t\tif(suggestions.size() == 0) {\r\n\t\t\t\t\t\tfw.write(\"There are no suggestions for \"+ word + \".\");\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tString sugg = \"\";\r\n\t\t\t\t\t\tfor(String s : suggestions) {\r\n\t\t\t\t\t\t\tsugg += s +\" \";\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tfw.write(sugg);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tfw.write(\"\\r\\n\"); //this adds a new line\r\n\t\t\t}\r\n\t\t\tfw.close(); \r\n\t\t\tscan.close(); \r\n\t\t} catch (Exception e) {\r\n\t\t\t//If any exception, an error is printed \r\n\t\t\tSystem.out.println(\"Error reading or writing the files\");\r\n\t\t}\r\n\t\t\r\n\t}", "public static void main(String[] args) throws FileNotFoundException {\n\n PrintWriter output = new PrintWriter(new FileOutputStream(\"./A-large.out\"));\n run(new Scanner(new FileInputStream(\"./A-large.in\")), output);\n output.close();\n }", "public static void main(String[] args) {\r\n\t\tPrintWriter writer = null;\r\n\t\ttry {\r\n\t\t\twriter = new PrintWriter(\"FILE NAME.txt\", \"UTF-8\");\r\n\t\t} catch (FileNotFoundException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t} catch (UnsupportedEncodingException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\twriter.println(\"The first line\");\r\n\t\twriter.println(\"The second line\");\r\n\t\twriter.close();\r\n\r\n\t}", "public void readFile()\r\n\t{\r\n\t\t\r\n\t\ttry\r\n\t\t{\r\n\t\t\tx = new Scanner(new File(\"clean vipr measles results.txt\"));\r\n\t\t\t\r\n\t\t\twhile (x.hasNext())\r\n\t\t\t{\r\n\t\t\t\tString a = x.next();\r\n\t\t\t\tString b = x.next();\r\n\t\t\t\tString c = x.next();\r\n\t\t\t\t\r\n\t\t\t\tSystem.out.printf(\"%s %s %s \\n\\n\", a,b,c);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tx.close();\r\n\t\t}\r\n\t\tcatch (Exception e)\r\n\t\t{\r\n\t\t\tSystem.out.println(\"file not found\");\r\n\t\t}\r\n\t\r\n\t}", "public static void main(String[] args) {\n\t\tint choice;\n\t\t\n\t\tScanner sc=new Scanner(System.in);\n\t\ttry\n\t\t{\n\t\t\t\n\t\t\n\t\tFileOutputStream fos=new FileOutputStream(\"F:\\\\Student.txt\");\n\t\tObjectOutputStream dos=new ObjectOutputStream(fos);\n\t FileInputStream fis=new FileInputStream(\"F:\\\\student.txt\");\t\n\t\tObjectInputStream ois=new ObjectInputStream(fis);\n\t //ArrayList<StudentDet> arl=new ArrayList<StudentDet>();\n\t \n\t\t\n\t\tSystem.out.println(\"1.Store data into file\");\n\t System.out.println(\"2.read whos age is > 18 and write into another file\");\n\t System.out.println(\"exit\");\n\t\tSystem.out.println(\"enter choice\");\n\t\tchoice=sc.nextInt();\n\t\t\n\t\tStudentOperation so=new StudentOperation();\n\t \n\t // sdt.accept();\n\t \n\t\t/*StudentDet sd=new StudentDet();\n\t\tStudentDet sd1=new StudentDet(1,10,220406,\"a\");\n\t\tStudentDet sd2=new StudentDet(4,15,220406,\"am\");\n\t\tStudentDet sd3=new StudentDet(3,33,220406,\"amber\");\n\t\tStudentDet sd4=new StudentDet(5,23,220406,\"er\");\n\t\tStudentDet sd5=new StudentDet(6,19,220406,\"amer\");\n\t\tStudentDet sd6=new StudentDet(2,20,220406,\"ambr\");\n\t\t*/\n\t\t\n\t\tswitch(choice)\n\t\t{\n\t\tcase 1:so.store(); \n\t\t\tbreak;\n\t\t\n\t\tcase 2:\tso.Readstore();\n\t\tbreak;\n\t\t\n\t\tdefault:System.out.println(\"invalid choice\");\n\t\tbreak;\t\n\t\t}\n\t\t}\n\t\tcatch(Exception e)\n\t\t{\n\t\t\tSystem.out.println(e.getMessage());\n\t\t}\n\t \n\t}", "public static void modifytext (String name) throws IOException {\n // Copy the contents of the input file and put it into the new file\n File inputF = new File(\"src/main/java/ex45/\"+ name +\".txt\");\n Path dest = inputF.toPath();\n Path src = Paths.get(\"src/main/java/ex45/exercise45_input.txt\");\n Files.copy(src, dest);\n\n // This process will replace the word 'utilize' with the word 'use'\n String utilize = new String(Files.readAllBytes(dest));\n Charset charset = StandardCharsets.UTF_8;\n utilize = utilize.replaceAll(\"utilize\", \"use\");\n Files.write(dest, utilize.getBytes(charset));\n\n System.out.print(\"Your file has been created.\");\n }", "public void printDataToFile(){\n\ttry {\n\t File file = new File(\"media/gameOutput.txt\");\n \n\t // if file doesnt exists, then create it\n\t if (!file.exists()) {\n\t\tfile.createNewFile();\n\t }\n \n\t FileWriter fw = new FileWriter(file.getAbsoluteFile());\n\t BufferedWriter bw = new BufferedWriter(fw);\n\t bw.write(printString);\n\t bw.close();\n\t} catch (IOException e) {\n\t e.printStackTrace();\n\t}\n }", "public static void main(String[] args) \r\n\t {\n\t FileInputStream ins = null;\r\n\t FileOutputStream outs = null;\r\n\t \r\n\t try\r\n\t {\r\n\t \t //input file -->abc.txt\r\n\t File infile =new File(\"C:\\\\Users\\\\omsai\\\\Desktop\\\\abc.txt\");\r\n\t \r\n\t //output file -->outfile\r\n\t File outfile =new File(\"C:\\\\Users\\\\omsai\\\\Desktop\\\\copy.txt\");\r\n\t \r\n\t ins = new FileInputStream(infile);\r\n\t outs = new FileOutputStream(outfile);\r\n\t \r\n\t byte[] buffer = new byte[1024];\r\n\t int length;\r\n\t \r\n\t //copy contents of inputfile to output file\r\n\t while ((length = ins.read(buffer)) > 0) {\r\n\t outs.write(buffer, 0, length);\r\n\t } \r\n\t \r\n\t //close input and output files\r\n\t ins.close();\r\n\t outs.close();\r\n\t \r\n\t \r\n\t System.out.println(\"File copied successfully!!\");\r\n\t } \r\n\t \r\n\t catch(IOException ioe) \r\n\t {\r\n\t ioe.printStackTrace();\r\n\t } \r\n\t }", "public static void main(String[] args) {\n\t\ttry {\n\t\t\tFile f11 = new File(\"Usama's 1st file.txt\");\n\t\t\tScanner myReader = new Scanner(f11);\n\t\t\t\n\t\t\twhile(myReader.hasNextLine())\n\t\t\t{\n\t\t\t\tString data = myReader.nextLine();\n\t\t\t\tSystem.out.println(data);\n\t\t\t}\n\t\t\tmyReader.close();\n\t\t} catch(FileNotFoundException e) {\n\t\t\tSystem.out.println(\"An unexpected error has been occured! :(\");\n\t\t\te.printStackTrace();\n\t\t}\n\t\t\n\n\t}" ]
[ "0.6527008", "0.6323545", "0.6283668", "0.6279706", "0.62634176", "0.62571067", "0.61937034", "0.60734624", "0.60576874", "0.5981932", "0.59710604", "0.5958416", "0.5908498", "0.5883718", "0.5877746", "0.586404", "0.583957", "0.5833188", "0.5830046", "0.58199525", "0.5818296", "0.5801264", "0.57983786", "0.5780788", "0.57623935", "0.5750036", "0.574429", "0.57324207", "0.57104266", "0.57103443", "0.57032007", "0.5688499", "0.5685338", "0.5672194", "0.562413", "0.5623845", "0.56191313", "0.5601218", "0.5599134", "0.5589354", "0.5576533", "0.557113", "0.5568185", "0.5559293", "0.5552066", "0.5534959", "0.55337197", "0.55336905", "0.55276304", "0.5488184", "0.5486755", "0.5483824", "0.5476208", "0.5474444", "0.5456261", "0.544587", "0.5436946", "0.54317033", "0.5428649", "0.5426258", "0.54184234", "0.5414967", "0.54051095", "0.54043025", "0.5402761", "0.54010206", "0.53943104", "0.5390872", "0.5379234", "0.53774023", "0.5377216", "0.5373816", "0.53646773", "0.5342417", "0.5340705", "0.53397197", "0.53373903", "0.5336884", "0.5335702", "0.53347355", "0.5334718", "0.53305006", "0.53252774", "0.53200144", "0.53183514", "0.53146654", "0.53123456", "0.53094405", "0.5309334", "0.5304119", "0.53008795", "0.5297642", "0.5296067", "0.5281877", "0.5276859", "0.527309", "0.52720344", "0.5271583", "0.5268006", "0.5267715", "0.5258547" ]
0.0
-1
normally no parse listeners should be set, so create an own list for it
@Override public void preInit( ProcessEngineConfigurationImpl processEngineConfiguration) { if (processEngineConfiguration.getCustomPostBPMNParseListeners() == null) { processEngineConfiguration.setCustomPostBPMNParseListeners(new ArrayList<BpmnParseListener>()); } // add parse listener processEngineConfiguration.getCustomPostBPMNParseListeners().add(new TaskNameBeautifierBpmnParseListener()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public List<String> listeners();", "@Override\n protected List<IElementParser<ActImpl>> createParserList() {\n List<IElementParser<ActImpl>> result = new ArrayList<>();\n result.add(new SubElementManeuverGroupsParser());\n result.add(new SubElementStartTriggerParser());\n result.add(new SubElementStopTriggerParser());\n return result;\n }", "private void setListeners() {\n\n }", "private void addListeners() {\n \t\tfHistoryListener= new HistoryListener();\n \t\tfHistory.addOperationHistoryListener(fHistoryListener);\n \t\tlistenToTextChanges(true);\n \t}", "@Override\r\n\tprotected void setListeners() {\n\t\t\r\n\t}", "public interface IParseObjectListener {\n void onItemCLick(ParseObject parseObject);\n}", "@Override\r\n\tprotected void listeners() {\n\t\t\r\n\t}", "List<LoggingEvent> parse(String xml) throws ParseException;", "private static void addConsumer()\r\n\t{\r\n\t\tparsers++;\r\n\t\tParser consumer = new Parser();\r\n\t\tconsumer.start();\r\n\t}", "@Override\r\n\tprotected void attachListeners() {\n\t\t\r\n\t}", "protected void attachListeners() {\n\t\t\n\t}", "private void setListeners() {\n\t\trefreshButton.addActionListener(new refreshButtonListener());\n\n\t\tthis.list.addMouseListener(new MouseAdapter() {\n\n\t\t\t@Override\n\t\t\tpublic void mouseClicked(MouseEvent event) {\n\t\t\t\tif (event.getClickCount() == 2 && list.getSelectedValue() != null && !list.getSelectedValue().equals(\"\") && tabs.getSelectedIndex() != -1) {\n\t\t\t\t\tlaunchDocument(tabs.getTitleAt(tabs.getSelectedIndex()), list.getSelectedValue());\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\ttabs.addChangeListener(new ChangeListener() {\n\n\t\t\t@Override\n\t\t\tpublic void stateChanged(ChangeEvent arg0) {\n\t\t\t\tif (!tabs.getTitleAt(tabs.getSelectedIndex()).equals(\"Chat\")) {\n\t\t\t\t\tlistmodel.clear();\n\t\t\t\t\tmakeRequest();\n\t\t\t\t}\n\t\t\t}\n\n\t\t});\n\t}", "protected EventListenerList getEventListenerList() {\r\n return listenerList;\r\n }", "void parseEventList() {\n\t\tfor (int eventsId : events.keySet()) {\n\t\t\tfinal Event event = events.get(eventsId);\n\t\t\tif (users.get(event.getUser().getName()).isActiveStatus()\n\t\t\t\t\t&& !event.isViewed()\n\t\t\t\t\t&& event.getInnerSisdate().compareTo(\n\t\t\t\t\t\t\tnew GregorianCalendar()) >= 0) {\n\t\t\t\tevent.setViewed(true);\n\t\t\t\tfinal SimpleDateFormat fm = new SimpleDateFormat(\n\t\t\t\t\t\t\"dd.MM.yyyy-HH:mm:ss\");\n\t\t\t\tt.schedule(new TimerTask() {\n\t\t\t\t\t@Override\n\t\t\t\t\tpublic void run() {\n\t\t\t\t\t\tif (event.isActive()) {\n\t\t\t\t\t\t\tgenerateEventMessage(\"User \"\n\t\t\t\t\t\t\t\t\t+ event.getUser().getName()\n\t\t\t\t\t\t\t\t\t+ \" \"\n\t\t\t\t\t\t\t\t\t+ fm.format(event.getInnerSisdate()\n\t\t\t\t\t\t\t\t\t\t\t.getTime()) + \" \" + event.getText());\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}, event.getInnerSisdate().getTime());\n\n\t\t\t}\n\t\t}\n\n\t}", "private static void informListeners() {\r\n\t\tfor (ATEListener l : listeners) {\r\n\t\t\tl.classListChanged( );\r\n\t\t}\r\n\t}", "@Override\n\tprotected void initListeners() {\n\t\t\n\t}", "protected List<RunListener> getRunListeners() {\n return Collections.emptyList();\n }", "@Override\n protected void initializeEventList()\n {\n }", "void registerListeners();", "public interface EventParser {\n\n\t/**\n\t * Parses the given String for XML to extract the parameter and assign them\n\t * to the members.\n\t * \n\t * @param xml\n\t * XML-Content\n\t * @return List of logging events\n\t * @throws ParseException\n\t * if fails to parse\n\t */\n\tList<LoggingEvent> parse(String xml) throws ParseException;\n\n\t/**\n\t * Parses the given input stream for XML to extract the parameter and assign\n\t * them to the members.\n\t * \n\t * @param is\n\t * XML Content\n\t * @return List of logging events\n\t * @throws ParseException\n\t * if fails to parse\n\t */\n\tList<LoggingEvent> parse(InputStream is) throws ParseException;\n\n\t/**\n\t * Get header of the event list.\n\t * \n\t * @return the header\n\t */\n\tString getResponseHeader();\n\n\t/**\n\t * Get the response for given events back to log4js.\n\t * \n\t * @param state\n\t * state of logging.\n\t * @param message\n\t * possible error message\n\t * @param throwable\n\t * possible exception\n\t * @return the message for response.\n\t */\n\tString getResponse(String state, String message, Throwable throwable);\n\n}", "protected PListParser() {\n logger = AppRegistryBridge.getInstance().getLoggingBridge();\n }", "List<String> getListenerTypes();", "public interface iOnParse {\n\tvoid onParse(String htmlEle);\n}", "@Override\r\n\tpublic void initListeners() {\n\t\t\r\n\t}", "protected void installListeners() {\n\n\t}", "public static ArrayList<HeadingListener> getListeners() {\n return _listeners;\n }", "private void setListener() {\n\t}", "public abstract void registerListeners();", "void addMultipleDocumentListener(MultipleDocumentListener l);", "@Override\n public void startDocument() throws SAXException {\n System.out.println(\"Start parsing document...\");\n nameList = new ArrayList<String>();\n }", "public synchronized List<EventListener> getListeners() {\n \treturn listeners;\n }", "protected void installListeners() {\n\t}", "List<LoggingEvent> parse(InputStream is) throws ParseException;", "public interface EnqueteListListener {\n}", "@Override\n\tpublic void getListener(){\n\t}", "@Override\n\tprotected void setListener() {\n\n\t}", "@Override\n\tprotected void setListener() {\n\n\t}", "protected void installListeners() {\n }", "protected void installListeners() {\n }", "@Override\n\tpublic void setListener() {\n\n\t}", "public AbstractListenerDialog() {\n\t\tlisteners = new ArrayList<>();\n\t}", "List<Runnable> getItemListeners();", "public ArrayList getTaskListeners(){\n initListener();\n return listeners;\n }", "@Override\n\tprotected void setListenerAndAdapter() {\n\t\t\n\t}", "@Override\r\n\tpublic void setListener() {\n\r\n\t}", "@Override\r\n\tpublic void setListener() {\n\r\n\t}", "public void addListeners()\n {\n nameEdit.addTextChangedListener(new TextWatcher()\n {\n @Override\n public void afterTextChanged(Editable arg0)\n {\n boolean isEmpty = nameEdit.getText().toString().isEmpty();\n acceptButton.setEnabled(!isEmpty);\n }\n\n @Override\n public void beforeTextChanged(CharSequence s, int start, int count, int after){}\n\n @Override\n public void onTextChanged(CharSequence s, int start, int before, int count) {}\n });\n\n numStandsEdit.addTextChangedListener(new TextWatcher()\n {\n @Override\n public void afterTextChanged(Editable s)\n {\n acceptButton.setEnabled(checkNumber());\n }\n @Override\n public void beforeTextChanged(CharSequence s, int start, int count, int after) {}\n\n @Override\n public void onTextChanged(CharSequence s, int start, int before, int count) {}\n });\n }", "@Override\n\tpublic void addListener() {\n\t\t\n\t}", "@Override\n\tpublic void onParser(JSONArray response) {\n\n\t}", "LateListenerNotifier()\r\n/* :17: */ {\r\n/* :18:858 */ this.l = l;\r\n/* :19: */ }", "public interface RecordListener {\n\t\t/**\n\t\t * Handles successfully parsed sample record.\n\t\t */\n\t\tvoid handleParsedRecord(SampleRecord record);\n\n\t\t/**\n\t\t * Handles input that could not be parsed due to a formatting problem.\n\t\t * @param line The line of text that could not be parsed.\n\t\t */\n\t\tvoid handleBadRecordFormat(String line);\n\t}", "private void initEventList(){\r\n\t\t/*\r\n\t\t * we save a valid event list in internal storage so we can load them in\r\n\t\t * our main activity. So we make sure there is either a valid one alreay in storage\r\n\t\t * or we get a fresh one from our server and save it in storage.\r\n\t\t */\r\n\t\t\r\n\t\t// first try to get an existing eventlist from storage\r\n\t\tJSONObject eventList = FileUtils.readEventListFromStorage(this);\r\n\t\t\r\n\t\tif(eventList != null) {\r\n\t\t\tif(eventListIsValid(eventList)){\r\n\t\t\t\tstartMuseek();\r\n\t\t\t} else {\r\n\t\t\t\tServerConnector.getEventListFromServer(mServerListener, mLocation);\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tServerConnector.getEventListFromServer(mServerListener, mLocation);\r\n\t\t}\r\n\t\t\r\n\t}", "public void addNPTListener(NPTListener l){}", "@Override\n public void onAdded() {\n }", "List<StatusListener> mo9950b();", "protected void initModifiedListeners()\n\t{\n\t\tif (path != null)\n\t\t{\n\t\t\tpath.addModifiedListener(this);\n\t\t}\n\t}", "public UserListListener() {\n }", "public Iterator<Object> listeners() {\n return Arrays.asList(fListeners).iterator();\n }", "@Override\n\tpublic void StartListening()\n\t{\n\t\t\n\t}", "void onListeningStarted();", "public interface Listener {}", "public void addScheduleChangeListener(ScheduleChangeListener lst) {\r\n\t\tlisteners.add(lst);\r\n\t}", "public void addListeners()\n {\n super.addListeners();\n BookingLine recBookingLine = (BookingLine)this.getRecord(BookingLine.BOOKING_LINE_FILE);\n Booking recBooking = (Booking)this.getRecord(Booking.BOOKING_FILE);\n recBooking.addArDetail(null, recBookingLine, false);\n \n recBookingLine.getField(BookingLine.PRICE).addListener(new CopyDataHandler(recBookingLine.getField(BookingLine.PRICING_STATUS_ID), new Integer(PricingStatus.MANUAL), null));\n recBookingLine.addListener(new BookingLineStatusHandler(null));\n }", "public void parse() {\n }", "private static void fireListChanged(Object tag)\n {\n // if (DEBUG.Enabled) Log.info(\"fireListChanged: \" + Util.tags(tag));\n \n // if (disableEvents)\n // return;\n // for (MetadataListListener mdl : listeners) {\n // try {\n // mdl.listChanged();\n // } catch (Throwable t) {\n // Log.warn(\"listener update: \" + Util.tags(mdl), t);\n // }\n // }\n }", "public interface RSSItemListener {\n\n void addRSSItem(RSSItem rssItem);\n\n ArrayList<RSSItem> getAllRSSItems();\n\n int getRSSItemCount();\n\n}", "@Override\n\tpublic void init() {\n\t\tregisterBeanDefinitionParser(\"processorEventMulticaster\",\n\t\t\t\tnew ProcessorEventMulticasterDefinitionParser());\n\t\tregisterBeanDefinitionParser(\"processorEventListener\",\n\t\t\t\tnew ProcessorEventListenerDefinitionParser());\n\t}", "protected Listener(){super();}", "protected void registerListener() {\r\n\t\t// do nothing\r\n\t}", "public static void addListener(MetadataListListener listener) {\n if (DEBUG.Enabled) Log.debug(\"listeners no longer allowed, will not report to: \" + Util.tags(listener));\n // listeners.add(listener);\n }", "public WifiScannerParseable() {\r\n\t\tmWifiData = new ArrayList<WifiSignalScan>();\r\n\r\n\t}", "public interface PostListResponseListener {\n void fireInitData(List<Post> posts);\n}", "public ArrayList<InputAxisListener> getListenersList(){\n\t\treturn mInputAxisListenerList;\n\t}", "public interface LogTypeCallback {\n\n void onLogType(ArrayList<String> values);\n}", "private void fireOnTweetsReceived(ArrayList<AbstractTweet> arlis) {\n if ( mOnNewTweet != null ){\n mOnNewTweet.onNewTweet(arlis);\n }\n else{\n throw new NullPointerException(\"fireOnTweetsReceived(): WARNING:: we don't have listener registered. Suspicious logic\"); \n }\n }", "public GpsRecordManager()\n {\n registeredListeners = new LinkedHashSet<>();\n }", "@PostConstruct\n public void init() {\n for (GithubParser parser : getBeans()) {\n List<String> events = parser.getEvents();\n for (String eventType : events) {\n this.parsers.put(eventType, parser);\n }\n }\n }", "public LALParser() {\n logins = new ArrayList<>();\n }", "private static void registerEventListener() {\r\n\r\n log.info(\"Registering event listener for Listeners\"); //$NON-NLS-1$\r\n\r\n try {\r\n ObservationManager observationManager = ContentRepository\r\n .getHierarchyManager(ContentRepository.CONFIG)\r\n .getWorkspace()\r\n .getObservationManager();\r\n\r\n observationManager.addEventListener(new EventListener() {\r\n\r\n public void onEvent(EventIterator iterator) {\r\n // reload everything\r\n reload();\r\n }\r\n }, Event.NODE_ADDED\r\n | Event.NODE_REMOVED\r\n | Event.PROPERTY_ADDED\r\n | Event.PROPERTY_CHANGED\r\n | Event.PROPERTY_REMOVED, \"/\" + CONFIG_PAGE + \"/\" + \"IPConfig\", true, null, null, false); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$\r\n }\r\n catch (RepositoryException e) {\r\n log.error(\"Unable to add event listeners for Listeners\", e); //$NON-NLS-1$\r\n }\r\n }", "public FeedParsers() {\n super(FEED_PARSERS_KEY);\n }", "public ServerParser() \n\t{\n\t\t m_fileNames = new ArrayList<String>();\n\t\t m_fileNames.add(\"xml/time_context_element.xml\");\n\t\t m_fileNames.add(\"xml/location_context_element.xml\");\n\t m_fileNames.add(\"xml/velocity_context_element.xml\");\n\t m_fileNames.add(\"xml/temperature_context_element.xml\");\n\t}", "public interface\t\tUCallbackList\n{\n /**\n * Removes all the registered callbacks.\n * <p>\n\t */\n\tpublic void\t\tremoveAll();\n\n /**\n * Removes the registered callback associated with the given tag.\n * <p>\n * @param tag The tag associated with the removed callback.\n\t */\n\tpublic void\t\tremoveUCallbackListener(String\t\ttag);\n\n /**\n * Registers a callback associated with the given tag.\n * <p>\n * @param listener The registered callback.\n * @param tag The tag associated with the registered callback.\n\t */\n\tpublic void\t\taddUCallbackListener(UCallbackListener listener,\n\t\t\t\t\t\t\t\t\t\t String tag);\n\n /**\n * Returns the callback associated with the given tag.\n * <p>\n * @param tag The tag associated with the callback.\n\t * @return The callback or null.\n\t */\n\tpublic UCallbackListener\t\tgetUCallbackListener(String tag);\n\n /**\n * Calls the actionPerformed method of all the registered callbacks.\n * <p>\n\t */\n\tpublic void\t\tnotifyUCallbackListeners();\n\n /**\n * Calls the actionPerformed method of a registered callback\n\t * associated with the given event.\n * <p>\n * @param event The event associated with the registered callback.\n\t */\n\tpublic void\t\tnotifyUCallbackListener(URBIEvent event);\n}", "private void addPresenceListener() {\n StanzaTypeFilter presenceFilter = new StanzaTypeFilter(Presence.class);\n\n connection.addAsyncStanzaListener(new StanzaListener() {\n @Override\n public void processPacket(Stanza packet) throws SmackException.NotConnectedException {\n Presence presence = (Presence) packet;\n String username = presence.getFrom();\n username = TextUtils.split(username, \"@\")[0];\n String status = Presence.Type.available.equals(((Presence) packet).getType())\n ? \"online\" : \"offline\";\n if (rosterListener != null) {\n rosterListener.presenceCallback(username, status);\n }\n }\n }, presenceFilter);\n }", "protected void messageList() {\r\n\t\tif (smscListener != null) {\r\n\t\t\tmessageStore.print();\r\n\t\t} else {\r\n\t\t\tSystem.out.println(\"You must start listener first.\");\r\n\t\t}\r\n\t}", "private void addListeners(){\n Conservable[] listenerFromProductTypeRelation = this.productRelation.getListener();\n this.listener[0] = listenerFromProductTypeRelation[0];\n this.listener[1] = listenerFromProductTypeRelation[1];\n this.listener[2] = this.post;\n this.listener[3] = this.productRelation;\n this.listener[4] = this;\n }", "private Parser() {\n objetos = new ListaEnlazada();\n }", "static //@Override\n\tpublic void addListener(final Listener listener) {\n\t\tif (null == stListeners) {\n\t\t\tstListeners = new LinkedList<>();\n\t\t}\n\t\tstListeners.add(listener);\n\t}", "public interface StationMarkerListener {\n void onNewMarkers(List<StationMarker> markers);\n}", "private DefaultListener() {\n }", "List<ContinuousQueryListener<K, ?>> getListeners();", "protected void parse() throws ParseException {\n String s;\n try {\n s=getFullText();\n } catch (IOException ioe) {\n if (ioe instanceof FileNotFoundException) {\n throw new DataNotFoundException (\"Could not find log file.\", ioe);\n } else {\n throw new ParseException (\"Error getting log file text.\", new File (getFileName()));\n }\n }\n StringTokenizer sk = new StringTokenizer(s);\n ArrayList switches = new ArrayList(10);\n while (sk.hasMoreElements()) {\n String el =sk.nextToken().trim();\n if (el.startsWith(\"-J\")) {\n if (!(el.equals(\"-J-verbose:gc\"))) {\n if (!(el.startsWith(\"-J-D\"))) {\n JavaLineswitch curr = new JavaLineswitch(el.substring(2));\n addElement (curr); \n }\n }\n }\n }\n }", "void initBeforeParsing() {\r\n }", "public Collection<T> getListeners() {\n return new ArrayList(_elements);\n }", "@Override\n\tpublic void postParse() {\n\t}", "@Override\n\tpublic void postParse() {\n\t}", "private void addListListeners() {\n\n MouseListener ml = new MouseAdapter() {\n @Override\n public void mouseReleased(MouseEvent e) {\n int index = checkInTimeList.locationToIndex(e.getPoint());\n if(e.getButton() == MouseEvent.BUTTON3 && e.getClickCount() == 1){\n if(checkInTimeList.isSelectedIndex(index) && checkInTimeList instanceof HostCheckInList )\n ((HostCheckInList)checkInTimeList).doPopupMenuLogic(e); \n }\n\n } // end MouseReleased\n }; // end MouseAdapter class\n checkInTimeList.addMouseListener(ml);\n \n \n KeyListener keyListener = new KeyAdapter() {\n @Override\n public void keyReleased(KeyEvent e) {\n if(e.getKeyChar() == KeyEvent.VK_DELETE || Character.toUpperCase((char)e.getKeyChar()) == 'D')\n removeCheckInDates();\n \n }\n }; // end MouseAdapter class\n checkInTimeList.addKeyListener(keyListener);\n\n }", "public ProcessInstrumenter(){\n\t\tparser = new DOMParser();\n\t\tnoActivity.add(\"variables\");\n\t\tnoActivity.add(\"correlationSets\");\n\t\tnoActivity.add(\"partnerLinks\");\n\t\tnoActivity.add(\"eventHandlers\");\n\t\tnoActivity.add(\"faultHandlers\");\n\t\tnoActivity.add(\"compensationHandlers\");\n\t}", "public void afterPropertiesSet() {\n String[] listenerClassNames = StringUtil.split(GetterUtil.getString(\n com.liferay.util.service.ServiceProps.get(\n \"value.object.listener.it.acsoftware.brokerportlet.model.BrokerMessageListener\")));\n\n if (listenerClassNames.length > 0) {\n try {\n List<ModelListener<BrokerMessageListener>> listenersList = new ArrayList<ModelListener<BrokerMessageListener>>();\n\n for (String listenerClassName : listenerClassNames) {\n listenersList.add((ModelListener<BrokerMessageListener>) InstanceFactory.newInstance(\n getClassLoader(), listenerClassName));\n }\n\n listeners = listenersList.toArray(new ModelListener[listenersList.size()]);\n } catch (Exception e) {\n _log.error(e);\n }\n }\n }", "@Override\n public void addListener(String className) {\n\n }", "public AutoEvents() {\n super();\n _autoEventList = new ArrayList();\n }", "private void addAllActiveXListeners()\n throws ActiveXException\n {\n Enumeration e;\n Guid iid;\n \n e = listeners.keys();\n\n while(e.hasMoreElements())\n {\n iid = (Guid) e.nextElement();\n addActiveXListener1(getDispatchPointer(), iid); \n }\n }" ]
[ "0.67689335", "0.6211579", "0.62038374", "0.618352", "0.60375375", "0.5976252", "0.59704167", "0.5863454", "0.5852905", "0.582928", "0.5808153", "0.578782", "0.5779263", "0.5777389", "0.5776829", "0.5694316", "0.5685335", "0.5675813", "0.5664432", "0.566251", "0.565573", "0.5650912", "0.56474024", "0.5635887", "0.5576615", "0.55461967", "0.55422324", "0.5537057", "0.5536129", "0.5522715", "0.55192566", "0.5511884", "0.55078447", "0.55014354", "0.54870564", "0.5486192", "0.5486192", "0.54771596", "0.54771596", "0.5474539", "0.54686946", "0.54467356", "0.54312444", "0.5425612", "0.542501", "0.542501", "0.5419116", "0.54073733", "0.54050887", "0.53978527", "0.53772074", "0.53592044", "0.5330396", "0.53170824", "0.5314722", "0.53125894", "0.5309677", "0.5301956", "0.52857745", "0.52800155", "0.5277257", "0.5256043", "0.5244645", "0.5238075", "0.5228584", "0.52237475", "0.5221882", "0.52115434", "0.5206797", "0.5203697", "0.5199841", "0.51995146", "0.51981425", "0.51936644", "0.5186635", "0.5184117", "0.5167479", "0.5163271", "0.516257", "0.51615214", "0.51447123", "0.51437336", "0.51381373", "0.513621", "0.5136174", "0.5128304", "0.51261383", "0.511784", "0.51174", "0.5107818", "0.5105837", "0.50997114", "0.5098554", "0.5096677", "0.5096677", "0.50953674", "0.50935453", "0.5080893", "0.5073437", "0.5073317", "0.5057586" ]
0.0
-1
Send SMS Method invoke after click on Send SMS Button
@Override public void onClick(View v) { if (v == mBtnSendSms) { String strMobileNumber = mEditTextMobileNumber.getText().toString().trim(); String strSmeBody = mEditTextSmsBody.getText().toString().trim(); sendSms(strMobileNumber, strSmeBody);// Send SMS Method } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\t public void onClick(View arg0) {\n\t screenDialog.dismiss();\r\n\t String sms = messageText.getText().toString();\r\n\t \ttry {\r\n\t\t\t\tSmsManager smsManager = SmsManager.getDefault();\r\n\t\t\t\tsmsManager.sendTextMessage(phone, null, sms, null, null);\r\n\t\t\t\tToast.makeText(getApplicationContext(), \"SMS Sent!\",\r\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tToast.makeText(getApplicationContext(),\r\n\t\t\t\t\t\t\"SMS faild, please try again later!\",\r\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\t }", "public void onClick(View v)\r\n {\n sendSMS(textView.getText().toString());\r\n }", "public void send(View v)\r\n {\r\n \t// get the phone number from the phone number text field\r\n String phoneNumber = phoneTextField.getText().toString();\r\n // get the message from the message text box\r\n String msg = msgTextField.getText().toString(); \r\n\r\n // make sure the fields are not empty\r\n if (phoneNumber.length()>0 && msg.length()>0)\r\n {\r\n \t// call the sms manager\r\n PendingIntent pi = PendingIntent.getActivity(this, 0,\r\n new Intent(this, SendSMSActivity.class), 0);\r\n SmsManager sms = SmsManager.getDefault();\r\n \r\n // this is the function that does all the magic\r\n sms.sendTextMessage(phoneNumber, null, msg, pi, null);\r\n \r\n }\r\n else\r\n {\r\n \t// display message if text fields are empty\r\n Toast.makeText(getBaseContext(),\"All field are required\",Toast.LENGTH_SHORT).show();\r\n }\r\n\r\n }", "public void sendSms() {\n\n }", "SendSMSResponse sendSMSProcess(SendSMSRequest smsRequest) throws Exception;", "@Override\r\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tsendSmsNew(phoneNum);\r\n\t\t\t\tsetTextSend();\r\n\t\t\t}", "private void SendSms()\n {\n try {\n Intent i = new Intent();\n startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse(\"sms:\" + number[index])));\n startActivity(i);\n Toast.makeText(this, \"Option sms Chosen...\", Toast.LENGTH_LONG).show();\n } catch (Exception e) {\n\n }\n }", "@Override\n public void onClick(View arg0) {\n\n String messageToSend = \"Thank you for shopping. Your order will be delivered soon.\";\n String number = \"6476710881\";\n SmsManager.getDefault().sendTextMessage(number, null, messageToSend, null,null);\n Toast.makeText(getApplicationContext(), \"Your Payment is done\", Toast.LENGTH_LONG).show();\n\n Intent myIntent = new Intent(getApplicationContext(),LoginActivity.class);\n startActivity(myIntent);\n\n }", "@Override\n public void send() {\n System.out.println(\"send message by SMS\");\n }", "private void sendSMS() {\n String msg = \"\";\n\n switch (s) {\n case \"Accelerometre\":\n msg = acce;\n break;\n case \"Lumiere\":\n msg = light;\n break;\n case \"Proximite\":\n msg = proxi;\n break;\n case \"Gyroscope\":\n msg = gyro;\n break;\n }\n\n String num = numero.getText().toString();\n\n final int PERMISSION_REQUEST_CODE = 1;\n\n if (checkSelfPermission(android.Manifest.permission.SEND_SMS) ==\n PackageManager.PERMISSION_DENIED) {\n Log.d(\" permission \", \" permission denied to SEND_SMS - requesting it \");\n String[] permissions = {android.Manifest.permission.SEND_SMS};\n requestPermissions(permissions, PERMISSION_REQUEST_CODE);\n } else {\n if (num.length() == 10) {\n SmsManager.getDefault().sendTextMessage(num, null, msg, null, null);\n numero.setText(\"\");\n } else {\n //On affiche un petit message d'erreur dans un Toast\n Toast toast = Toast.makeText(CapteurActivity.this, \"Veuilliez écrire un numero a 10 chiffres\", Toast.LENGTH_LONG);\n toast.show();\n\n }\n }\n }", "@Step\n public void clickSendSMSButton(){\n actionWithWebElements.clickOnElement(sendSMSButton);\n }", "@Override\n\t\tpublic void onClick(View v) {\n\t\t\tUri uri = Uri.parse(\"smsto://08000000123\");\n\t\t\tIntent intent = new Intent(Intent.ACTION_SENDTO, uri);\n\t\t\tintent.putExtra(\"sms_body\", \"SMS message\");\n\t\t\tstartActivity(intent);\n\t\t}", "void requestSendSMSCode(Context context,String phone);", "public void onClick(View view) {\n sendSMSMessage(profile_general,phoneNo);\n GoHome();\n }", "private void showSendSMSActivity() {\n Uri uri = getIntent().getData();\n if (uri == null) {\n return;\n }\n\n // get phone number where to send the SMS\n String ssp = uri.getSchemeSpecificPart();\n String number = ContactsAccessHelper.normalizePhoneNumber(ssp);\n if (number.isEmpty()) {\n return;\n }\n\n // find person by phone number in contacts\n String person = null;\n ContactsAccessHelper db = ContactsAccessHelper.getInstance(this);\n Contact contact = db.getContact(this, number);\n if (contact != null) {\n person = contact.name;\n }\n\n // get SMS thread id by phone number\n int threadId = db.getSMSThreadIdByNumber(this, number);\n if (threadId >= 0) {\n // get the count of unread sms of the thread\n int unreadCount = db.getSMSMessagesUnreadCountByThreadId(this, threadId);\n\n // open thread's SMS conversation activity\n Bundle arguments = new Bundle();\n arguments.putInt(FragmentArguments.THREAD_ID, threadId);\n arguments.putInt(FragmentArguments.UNREAD_COUNT, unreadCount);\n arguments.putString(FragmentArguments.CONTACT_NUMBER, number);\n String title = (person != null ? person : number);\n CustomFragmentActivity.show(this, title, SMSConversationFragment.class, arguments);\n }\n\n // open SMS sending activity\n Bundle arguments = new Bundle();\n arguments.putString(FragmentArguments.CONTACT_NAME, person);\n arguments.putString(FragmentArguments.CONTACT_NUMBER, number);\n String title = getString(R.string.New_message);\n CustomFragmentActivity.show(this, title, SMSSendFragment.class, arguments);\n }", "@Override\n public void onClick(View v) {\n sendMessage(phone_from_intent);\n }", "protected void sendSMSMessage(String phonnumber) {\n String message = null;\r\n if (BookElectionFrgament.BTTtime == true) {\r\n message = \"Hey! The tee time booking is confirmed as follows Date -\" + BookElectionFrgament.formattedDate + \"\\n, Time - \" + BookElectionFrgament.timeselected + \"\\n, No. of Holes - \" + BookElectionFrgament.hole + \"\\nSee you at Karma Lakelands! \";\r\n } else if (Bookingdriverange.BDRTime == true) {\r\n message = \"Hey! The driving range booking is confirmed as follows Date -\" + Bookingdriverange.formattedDate + \"\\n, Time - \" + Bookingdriverange.timeselected + \"\\n, Balls - \" + Bookingdriverange.bucketselected + \"\\nSee you at Karma Lakelands! \";\r\n\r\n }\r\n\r\n try {\r\n SmsManager smsManager = SmsManager.getDefault();\r\n\r\n smsManager.sendTextMessage(phonnumber, null, message, null, null);\r\n\r\n // Customdialog messagedialog= new Customdialog(SMS1.this);\r\n // messagedialog.show();\r\n\r\n Toast.makeText(getApplicationContext(), \"Your message has been sent successfully!\", Toast.LENGTH_SHORT).show();\r\n } catch (Exception e) {\r\n Toast.makeText(getApplicationContext(), \"SMS failed, please try again.\", Toast.LENGTH_SHORT).show();\r\n e.printStackTrace();\r\n }\r\n }", "@Override\r\n\tpublic void onClick(View v) {\n\t\tswitch (v.getId()) { \r\n case R.id.send: \r\n \tif(!number.getText().toString().equals(\"\")&&number.getText().toString()!=null){\r\n\t\t\t\tif(!content.getText().toString().equals(\"\")&&content.getText().toString()!=null){\r\n\t\t\t\t\t//创建一个PendingIntent对象\r\n\t\t\t\t\tPendingIntent pi = PendingIntent.getActivity(SendSmsAct.this, 0, new Intent(), 0);\r\n\t\t\t\t\t//发送短信\r\n\t\t\t\t\t//短信具有字数限制,分条发送\r\n//\t\t\t\t\t ArrayList<String> list = sManager.divideMessage(content.getText().toString()); //因为一条短信有字数限制,因此要将长短信拆分 \r\n//\t\t\t for(String text:list){ \r\n//\t\t\t\t\t\t\tsManager.sendTextMessage(number.getText().toString(), null, text, pi, null);\r\n//\t\t\t }\r\n//\t\t\t\t\t\tsManager.sendTextMessage(number.getText().toString(), null, content.getText().toString(), pi, null);\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tif (content.getText().toString().length() > 70) { \r\n\t\t\t\t\t\t ArrayList<String> msgs = sManager.divideMessage(content.getText().toString()); \r\n\t\t\t\t\t\t ArrayList<PendingIntent> sentIntents = new ArrayList<PendingIntent>(); \r\n\t\t\t\t\t\t for(int i = 0;i<msgs.size();i++){ \r\n\t\t\t\t\t\t sentIntents.add(pi); \r\n\t\t\t\t\t\t } \r\n\t\t\t\t\t\t sManager.sendMultipartTextMessage(number.getText().toString(), null, msgs, sentIntents, null); \r\n\t\t\t\t\t\t} else { \r\n\t\t\t\t\t\t\tsManager.sendTextMessage(number.getText().toString(), null, content.getText().toString(), pi, null); \r\n\t\t\t\t\t\t} \r\n\t\t\t\t\t//提示短信发送成功\r\n\t\t\t\t\tToast.makeText(SendSmsAct.this, \"短信发送成功\", 8000).show();\r\n\t\t\t\t}else{\r\n\t\t\t\t\tToast.makeText(SendSmsAct.this, \"无信息内容\", 8000).show();\r\n\t\t\t\t}\r\n\t\t\t}else{\r\n\t\t\t\tToast.makeText(SendSmsAct.this, \"无号码\", 8000).show();\r\n\t\t\t}\r\n break; \r\n case R.id.encrysend: \r\n \tif(!number.getText().toString().equals(\"\")&&number.getText().toString()!=null){\r\n\t\t\t\tif(!content.getText().toString().equals(\"\")&&content.getText().toString()!=null){\r\n\t\t\t\t\t//从数据库中读取私钥,并使用MD5解密\r\n\t\t\t\t\tString userName = \"\";\r\n\t\t\t\t\tuserName = FileUtil.readFileSdcard(FileUtil.Folder_NAME+\"/me.txt\");\r\n\t\t\t\t\tif(userName.equals(\"\")){\r\n\t\t\t\t\t\tToast.makeText(SendSmsAct.this, \"未创建密钥\", 8000).show();\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tSQLiteHelper sqlLH = new SQLiteHelper(SendSmsAct.this);\r\n\t\t\t\t\t\tprivateKey2 = sqlLH.queryPrivateKey(userName);\r\n\t\t\t\t\t\tSystem.out.println(\"@@@@@@@@privateKey2\"+privateKey2);\r\n\t\t\t\t\t\tif(privateKey2.equals(\"\")){\r\n\t\t\t\t\t\t\tToast.makeText(SendSmsAct.this, \"未创建密钥\", 8000).show();\r\n\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t//通过弹出窗口来输入私钥,获取privateKey\r\n\t\t\t\t\t\t\tAlertDialog.Builder builder = new Builder(SendSmsAct.this);\r\n\t\t\t\t\t\t\tbuilder.setTitle(\"请输入口令\"); //设置对话框标题\r\n\t\t\t\t\t\t\tbuilder.setIcon(android.R.drawable.btn_star); //设置对话框标题前的图标\r\n\t\t\t\t\t\t\tfinal EditText edit = new EditText(SendSmsAct.this);\r\n\t\t\t\t\t\t\tedit.setTransformationMethod(PasswordTransformationMethod.getInstance());\r\n\t\t\t\t\t\t\tbuilder.setView(edit);\r\n\t\t\t\t\t\t\tbuilder.setPositiveButton(\"确认\", \r\n\t\t\t\t\t\t\t\t\tnew DialogInterface.OnClickListener() {\r\n\t\t\t\t\t\t\t\t@Override\r\n\t\t\t\t\t\t\t\tpublic void onClick(DialogInterface dialog, int which) {\r\n\t\t\t\t\t\t\t\tprivateKey = edit.getText().toString();\r\n\t\t\t\t\t\t\t\tSystem.out.println(\"@@@@@@@@privateKey\"+privateKey);\r\n\t\t\t\t\t\t\t\tif(!MD5Util.encryph(privateKey).equals(privateKey2)){\r\n\t\t\t\t\t\t\t\t\tToast.makeText(SendSmsAct.this, \"口令不符\", 8000).show();\r\n\r\n\t\t\t\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t\t\t\t//从本地文件中读取收件人的公钥\r\n\t\t\t\t\t\t\t\t\t\tString name = number.getText().toString();\r\n\t\t\t\t\t\t\t\t\t\tString publicKey = \"\";\r\n\t\t\t\t\t\t\t\t\t\tpublicKey = FileUtil.readFileSdcard(FileUtil.File_NAME+name+\".txt\");\r\n\t\t\t\t\t\t\t\t\t\tif(!publicKey.equals(\"\")){\r\n\t\t\t\t\t\t\t\t\t\t\tSystem.out.println(\"@@@@@@@@publicKey\"+publicKey);\r\n\t\t\t\t\t\t\t\t\t\t\tDhKey dhkey = new DhKey(MD5Util.encryph(privateKey));\r\n\t\t\t\t\t\t\t\t\t\t\tBigInteger k = dhkey.getK(publicKey);\r\n\t\t\t\t\t\t\t\t\t\t\tSystem.out.println(\"@@@@@@@@K\"+k);\r\n\t\t\t\t\t\t\t\t\t\t\tString message = content.getText().toString();\r\n\t\t\t\t\t\t\t\t\t\t\tSystem.out.println(\"@@@@@@@@message\"+message);\r\n//\t\t\t\t\t\t\t\t\t\t\tAESUtil aes = new AESUtil();\r\n//\t\t\t\t\t\t\t\t\t\t\tString ciphermessage = \"yyyy:\"+aes.AESEncode(k.toString(), message);\r\n\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\t\tDESUtil Des = new DESUtil();\r\n\t\t\t\t\t\t\t\t\t\t\tString ciphermessage = \"yyyy:\"+Des.DESEncode(k.toString(), message);\r\n\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\t\tSystem.out.println(\"@@@@@@@@AESEncode\"+ciphermessage);\r\n\t\t\t\t\t\t\t\t\t\t\t//创建一个PendingIntent对象\r\n\t\t\t\t\t\t\t\t\t\t\tPendingIntent pi = PendingIntent.getActivity(SendSmsAct.this, 0, new Intent(), 0);\r\n\t\t\t\t\t\t\t\t\t\t\t//发送短信\r\n\t\t\t\t\t\t\t\t\t\t\t//短信具有字数限制,分条发送\r\n//\t\t\t\t\t\t\t\t\t\t\t ArrayList<String> list = sManager.divideMessage(ciphermessage); //因为一条短信有字数限制,因此要将长短信拆分 \r\n//\t\t\t\t\t\t\t\t\t for(String text:list){ \r\n//\t\t\t\t\t\t\t\t\t\t\t\t\tsManager.sendTextMessage(number.getText().toString(), null, text, pi, null);\r\n//\t\t\t\t\t\r\n//\t\t\t\t\t\t\t\t\t }\r\n//\t\t\t\t\t\t\t\t\t\t\t\tsManager.sendTextMessage(number.getText().toString(), null, ciphermessage, pi, null);\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\tif (ciphermessage.length() > 70) { \r\n\t\t\t\t\t\t\t\t\t\t\t\t ArrayList<String> msgs = sManager.divideMessage(ciphermessage); \r\n\t\t\t\t\t\t\t\t\t\t\t\t ArrayList<PendingIntent> sentIntents = new ArrayList<PendingIntent>(); \r\n\t\t\t\t\t\t\t\t\t\t\t\t for(int i = 0;i<msgs.size();i++){ \r\n\t\t\t\t\t\t\t\t\t\t\t\t sentIntents.add(pi); \r\n\t\t\t\t\t\t\t\t\t\t\t\t } \r\n\t\t\t\t\t\t\t\t\t\t\t\t sManager.sendMultipartTextMessage(number.getText().toString(), null, msgs, sentIntents, null); \r\n\t\t\t\t\t\t\t\t\t\t\t\t} else { \r\n\t\t\t\t\t\t\t\t\t\t\t\t\tsManager.sendTextMessage(number.getText().toString(), null, ciphermessage, pi, null); \r\n\t\t\t\t\t\t\t\t\t\t\t\t} \r\n\t\t\t\t\t\t\t\t\t\t\t//提示短信发送成功\r\n\t\t\t\t\t\t\t\t\t\t\tToast.makeText(SendSmsAct.this, \"短信发送成功\", 8000).show();\r\n\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t\t\t\t\tToast.makeText(SendSmsAct.this, \"无收件人公钥,查证\", 8000).show();\r\n\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t});\r\n\t\t\t\t\t\t\tbuilder.setNegativeButton(\"取消\", new DialogInterface.OnClickListener() {\r\n\t\t\t\t\t\t\t@Override\r\n\t\t\t\t\t\t\tpublic void onClick(DialogInterface dialog, int which) {\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t});\r\n\t\t\t\t\t\t\tbuilder.setCancelable(true); //设置按钮是否可以按返回键取消,false则不可以取消\r\n\t\t\t\t\t\t\tAlertDialog dialog = builder.create(); //创建对话框\r\n\t\t\t\t\t\t\tdialog.setCanceledOnTouchOutside(true); //设置弹出框失去焦点是否隐藏,即点击屏蔽其它地方是否隐藏\r\n\t\t\t\t\t\t\tdialog.show();\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\tToast.makeText(SendSmsAct.this, \"无信息内容\", 8000).show();\r\n\t\t\t\t}\r\n\t\t\t}else{\r\n\t\t\t\tToast.makeText(SendSmsAct.this, \"无号码\", 8000).show();\r\n\t\t\t}\r\n break; \r\n \r\n case R.id.nokey:\r\n \tIntent intent = new Intent();\r\n \tintent.setClass(SendSmsAct.this,ProduceKeyAct.class); \r\n \tstartActivity(intent);\r\n default: \r\n break; \r\n } \r\n\t}", "public void smsSendMessage(String phoneNumber, String messageContent) {\n try {\n //EditText editText = (EditText) findViewById(R.id.editText_main);\n // Set the destination phone number to the string in editText.\n String destinationAddress = \"07956765611\";\n // Find the sms_message view.\n //EditText smsEditText = (EditText) findViewById(R.id.sms_message);\n // Get the text of the SMS message.\n String smsMessage = \"Hi Kobi\";\n // Set the service center address if needed, otherwise null.\n String scAddress = null;\n // Set pending intents to broadcast\n // when message sent and when delivered, or set to null.\n PendingIntent sentIntent = null, deliveryIntent = null;\n // Use SmsManager.\n SmsManager smsManager = SmsManager.getDefault();\n\n smsManager.sendTextMessage\n (destinationAddress, scAddress, smsMessage,\n sentIntent, deliveryIntent);\n } catch (Exception e) {\n e.printStackTrace();\n }\n }", "protected void sendSMS(String number) {\n Uri uri = Uri.parse(\"smsto:\" + number);\n Intent sendIntent = new Intent(Intent.ACTION_SENDTO, uri);\n sendIntent.putExtra(\"sms_body\", \"Denk an deinen TODO\");\n context.startActivity(sendIntent);\n }", "public void sendMessage(View v) {\n // retrieve the text typed in by the user in the EditText\n String message = ((EditText)(findViewById(R.id.editText_message))).getText().toString();\n // create an implicit intent to any app with SENDTO capability\n // set the destination (5556 is the phone number of the second emulator instance)\n Uri destination = Uri.parse(\"smsto:5556\");\n Intent smsIntent = new Intent(Intent.ACTION_SENDTO, destination);\n // pass the composed message to the messaging activity\n smsIntent.putExtra(\"sms_body\", message);\n // launch the intent\n startActivity(smsIntent);\n }", "private void sendSms(String strPhoneNumber, String strSms) {\n if (ActivityCompat.checkSelfPermission(this, Manifest.permission.SEND_SMS) == PackageManager.PERMISSION_GRANTED) {// checking runtime permission for Sending SMS\n try {\n SmsManager smsManager = SmsManager.getDefault();\n smsManager.sendTextMessage(strPhoneNumber, null, strSms, null, null);// this statement send sms(background)\n Toast.makeText(getApplicationContext(), \"Message Sent Successful\", Toast.LENGTH_LONG).show();// Showing Toast after sending SMS\n } catch (Exception e) {\n Toast.makeText(getApplicationContext(), e.getMessage().toString(), Toast.LENGTH_LONG).show();// Showing Toast if SMS sending fail\n e.printStackTrace();\n }\n } else {\n if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {\n requestPermissions(new String[]{Manifest.permission.SEND_SMS}, 10);// Grant runtime permission for sending SMS\n }\n }\n\n }", "@Override\r\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tsmsReceiver = new SMSReceiver();\r\n\t\t\t\tIntentFilter filter = new IntentFilter();\r\n\t\t\t\tfilter.addAction(SMS_ACTION);\r\n\t\t\t\tMainActivity.this.registerReceiver(smsReceiver, filter);\r\n\t\t\t}", "public void sendMessage(View buttonView)\n {\n state = 0;\n Intent intent = new Intent(this, DisplayMessageActivity.class);\n EditText editText = (EditText) findViewById(R.id.Message);\n EditText editTextPhoneNumber = (EditText) findViewById(R.id.Phone);\n String message = editText.getText().toString();\n String phoneNumberMessage = editTextPhoneNumber.getText().toString();\n intent.putExtra(EXTRA_MESSAGE, message);\n intent.putExtra(EXTRA_PHONEMESSAGE, phoneNumberMessage);\n startActivity(intent);\n }", "public void sendClick(View view) {\n String message = input.getText().toString();\n uart.send(message);\n }", "private static void sendSms(Context context, String number, String message)\n {\n \t// Create an intent for sending an sms to a specified number\n \t\tIntent intent = new Intent(Intent.ACTION_SENDTO, Uri.parse(Constants.URI_SMS + number));\n \t\t\n \t\t// Optional, text to send\n \t\tintent.putExtra(Constants.URI_SMS_BODY, message);\n \t\t\n \t\t((Activity) context).finish();\n \t\tcontext.startActivity(intent);\n }", "@Override\r\n public void onClick(View v) {\n String dest = txcontacts.getText().toString().trim();\r\n if (PhoneNumberUtils.isWellFormedSmsAddress(dest)) {\r\n\r\n // dest, serviceCenter (null for default), message,\r\n // sentIntent, deliveryIntent\r\n // Set the second parameter to null. The scAddress relates\r\n // to the address of the server on the cellular network that will handle\r\n // the message, it is not the address of the sender.\r\n\r\n smsManager.sendTextMessage(txcontacts.getText().toString(), null, etmessage.getText()\r\n .toString(), sentIntent, null);\r\n\r\n Toast.makeText(Message.this, \"SMS message sent\", Toast.LENGTH_LONG).show();\r\n etmessage.setText(\"\");\r\n\r\n } else {\r\n Toast.makeText(Message.this, \"SMS destination invalid - try again\", Toast.LENGTH_LONG).show();\r\n }\r\n }", "public void onClick(View view) {\n\t\t\tsendSMSMessage(profile_silent,phoneNo);\n\t\t\tGoHome();\n }", "@SuppressLint(\"NewApi\")\n @Override\n public void onClick(View v) {\n sPhone = etPhone.getText().toString();\n sSms = etSms.getText().toString();\n\n //if (sPhone.length() > 0 && sSms.length() > 0)\n // sendSMS(sPhone, sSms);\n\n\n etSms.getText().clear();\n\n Intent i = new Intent(SMSActivity.this, AlarmService.class);\n i.putExtra(\"exPhone\", sPhone);\n i.putExtra(\"exSmS\", sSms);\n\n smsData.put(\"Phone\", sPhone);\n smsData.put(\"Message\", sSms);\n\n\n pIntent = PendingIntent.getService(getApplicationContext(), 0, i, PendingIntent.FLAG_UPDATE_CURRENT);\n\n aManager = (AlarmManager) getSystemService(ALARM_SERVICE);\n c.setTimeInMillis(System.currentTimeMillis());\n c.set(Calendar.HOUR_OF_DAY, hour);\n c.set(Calendar.MINUTE, minute);\n aManager.set(AlarmManager.RTC_WAKEUP, c.getTimeInMillis(), pIntent);\n Toast.makeText(getApplicationContext(), \"Sms scheduled! \", Toast.LENGTH_SHORT).show();\n\n\n onSaveClickedSP(v);\n send15minNotification(hour, minute);\n sendsentNotification(hour, minute);\n\n Intent intent = new Intent(SMSActivity.this, SucessSMSActivity.class);\n startActivity(intent);\n\n }", "public void sendSMS() {\n //http://www.mkyong.com/android/how-to-send-sms-message-in-android/\n\n Intent intent = getIntent();\n String userName = intent.getStringExtra(LoginActivity.USER_NAME);\n String userDOB = intent.getStringExtra(LoginActivity.DOB);\n String doctorName = intent.getStringExtra(LoginActivity.DOCTOR_NAME);\n String doctorNumber = intent.getStringExtra(LoginActivity.DOCTOR_NUMBER);\n String sms = \"Hello Dr. \" + doctorName + \", your patient \" + userName + \" \" +\n \"whose date of birth is \" + userDOB + \" is suspected of having dementia \" +\n \"based on the anomalous behavior tracked on the Early Detection Dementia App.\";\n\n\n try {\n SmsManager smsManager = SmsManager.getDefault();\n smsManager.sendTextMessage(doctorNumber, null, sms, null, null);\n Toast.makeText(getApplicationContext(), \"SMS Sent!\",\n Toast.LENGTH_LONG).show();\n } catch (Exception e) {\n Toast.makeText(getApplicationContext(),\n \"SMS faild, please try again later!\",\n Toast.LENGTH_LONG).show();\n e.printStackTrace();\n }\n\n }", "public static void enviarSMS(Activity actividad, String texto, String numerodestino) {\n Uri uri = Uri.parse(\"smsto:\" + numerodestino);\n Intent i = new Intent(Intent.ACTION_SENDTO, uri);\n i.putExtra(\"sms_body\", texto);\n //i.setPackage(\"com.whatsapp\");\n actividad.startActivity(i);\n }", "public void sms(int nr, String text) {\n Provider.sendeSms (nr, text);\n }", "private void sendSMS(String phoneNumber, String message) {\n ArrayList<PendingIntent> sentPendingIntents = new ArrayList<PendingIntent>();\n ArrayList<PendingIntent> deliveredPendingIntents = new ArrayList<PendingIntent>();\n PendingIntent sentPI = PendingIntent.getBroadcast(this, 0,\n new Intent(this, SmsSentReceiver.class), 0);\n PendingIntent deliveredPI = PendingIntent.getBroadcast(this, 0,\n new Intent(this, SmsDeliveredReceiver.class), 0);\n try {\n SmsManager sms = SmsManager.getDefault();\n ArrayList<String> mSMSMessage = sms.divideMessage(message);\n for (int i = 0; i < mSMSMessage.size(); i++) {\n sentPendingIntents.add(i, sentPI);\n deliveredPendingIntents.add(i, deliveredPI);\n }\n sms.sendMultipartTextMessage(phoneNumber, null, mSMSMessage,\n sentPendingIntents, deliveredPendingIntents);\n\n } catch (Exception e) {\n Snackbar.make(fab, \"SMS sending failed...\", Snackbar.LENGTH_LONG)\n .setAction(\"Action\", null).show();\n e.printStackTrace();\n }\n\n }", "public void sendmessage(View v){\n \tIntent intent =new Intent();//意图\n \tintent.setAction(Intent.ACTION_SENDTO);//设置发短信意图\n \tintent.setData(Uri.parse(\"smsto:\"+1358752546));//设置拨号的信息\n \t//问题:怎么不能用11位电话号码\n \tString message=\"我是水哥,有妹子么\";\n \tintent.putExtra(\"sms_body\", message);\n \tstartActivity(intent);//开启意图\t \n }", "public void onClickSend(View view) {\n //String string = editText.getText().toString();\n //serialPort.write(string.getBytes());\n //tvAppend(txtResponse, \"\\nData Sent : \" + string + \"\\n\");\n }", "public void onPressShareWithSMS() {\r\n if (!requireSMSPermissions()) {\r\n return;\r\n }\r\n\r\n shareSMS();\r\n }", "public java.lang.String sendSMS(java.lang.String accessCode, java.lang.String toNumber, java.lang.String body) throws java.rmi.RemoteException;", "@Override\n public void sendSms(String smsBody) {\n }", "protected void onSendMessage(View view){\n et = (EditText)findViewById(R.id.message);\n String message = et.getText().toString();\n Intent intent = new Intent(this, ReceiveMessageActivity.class);\n intent.putExtra(\"message\",message);\n startActivity(intent);\n }", "@Override\r\n\t\t\tpublic void onClick(View arg0) {\n\t\t\t\tRandom ra=new Random();\r\n\t\t\t\tint val=ra.nextInt(999);\r\n\t\t\t\tSmsManager sms=SmsManager.getDefault();\r\n\t\t\t\tsms.sendTextMessage(txt_phone.getText().toString(), null, val+\"\", null, null);\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\tIntent i=new Intent(getApplicationContext(), OTP_Reg.class);\r\n\t\t\t\ti.putExtra(\"name\", txt_name.getText().toString());\r\n\t\t\t\ti.putExtra(\"phone\", txt_phone.getText().toString());\r\n\t\t\t\ti.putExtra(\"otp\", val+\"\");\r\n\t\t\t\t\r\n\t\t\t\tstartActivity(i);\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t}", "@Override\r\n\tpublic void onClick(View arg0) {\n\t\tIntent myobj=new Intent(Intent.ACTION_SENDTO,Uri.parse(\"smsto:\"+e2.getText().toString()));\r\n\t\tmyobj.putExtra(\"sms_body\",e1.getText().toString());\r\n\t\tstartActivity(myobj);\r\n\t}", "private void shareSMS() {\r\n EventSharer.shareSMS(this, event.uid);\r\n }", "public void sendMessage() {\n //Get data from preferences\n SharedPreferences SP = PreferenceManager.getDefaultSharedPreferences(DashItApplication.getAppContext());\n if (SP.getBoolean(\"sendSms\", false)) {\n String myName = SP.getString(\"myName\", \"NA\");\n String myPhoneNumber = SP.getString(\"myPhoneNumber\", \"NA\");\n String emergencyContact = SP.getString(\"contact\", \"NA\");\n String location = \"http://maps.google.com/?q=\";\n location += accidentLocation;\n String message = getString(R.string.sms_message_contact) + myName + getString(R.string.sms_message_help) +\n getString(R.string.sms_message_your_phone_number) + myPhoneNumber + \",\" +\n getString(R.string.sms_message_location) + location;\n String hashMessage = \"SHA-256 Hash:\" + hashFromFilesAndLocation;\n //Send SMS\n if (emergencyContact.length() > 2 && !emergencyContact.equalsIgnoreCase(\"NA\")) {\n try {\n SmsManager smsManager = SmsManager.getDefault();\n smsManager.sendTextMessage(emergencyContact, null, message, null, null);\n smsManager.sendTextMessage(emergencyContact, null, hashMessage, null, null);\n handler.post(new Runnable() {\n @Override\n public void run() {\n Toast.makeText(DashItApplication.getAppContext(), R.string.instruction_sms_sent_successful, Toast.LENGTH_LONG).show();\n }\n });\n } catch (Exception e) {\n handler.post(new Runnable() {\n @Override\n public void run() {\n Toast.makeText(DashItApplication.getAppContext(), R.string.instruction_sms_sent_unsuccessful, Toast.LENGTH_LONG).show();\n }\n });\n e.printStackTrace();\n }\n }\n }\n }", "private void send() {\n Toast.makeText(this, getString(R.string.message_sent, mBody, Contact.byId(mContactId).getName()),\n Toast.LENGTH_LONG).show();\n finish(); // back to DirectShareActivity\n }", "@Override\n\tpublic void sendSMS() {\n\t\tSystem.out.println(\"Logic B\" + \" Send By: \" + getVendorName());\n\t}", "public void sendMessage(String phoneNumber, String message) {\n\n if(message.isEmpty() || message.replace(\" \",\"\").isEmpty()){\n Toast.makeText(getApplicationContext(), \"Empty SMS!\",\n Toast.LENGTH_LONG).show();\n return;\n }\n\n if(phoneNumber != null) {\n PendingIntent piSent = PendingIntent.getBroadcast(getApplicationContext(), 0, new Intent(SENT), 0);\n PendingIntent piDelivered = PendingIntent.getBroadcast(getApplicationContext(), 0, new Intent(DELIVERED), 0);\n SmsManager smsManager = SmsManager.getDefault();\n\n int length = message.length();\n try {\n if (length > MAX_SMS_MESSAGE_LENGTH) {\n ArrayList<String> messagelist = smsManager.divideMessage(message);\n smsManager.sendMultipartTextMessage(phoneNumber, null, messagelist, null, null);\n Toast.makeText(getApplicationContext(), \"More than one SMS sent.\",\n Toast.LENGTH_LONG).show();\n } else {\n smsManager.sendTextMessage(phoneNumber, null, message, piSent, piDelivered);\n Toast.makeText(getApplicationContext(), \"SMS sent.\",\n Toast.LENGTH_LONG).show();\n }\n addSentMessageToDB(phoneNumber,message);\n addSentMessageToThread(message);\n } catch (Exception e) {\n Toast.makeText(getApplicationContext(),\n \"SMS failed, please try again.\",\n Toast.LENGTH_LONG).show();\n e.printStackTrace();\n }\n }\n else{\n Toast.makeText(getApplicationContext(),\n \"The contact does not have a phone number\",\n Toast.LENGTH_LONG).show();\n }\n }", "@OnClick(R.id.enter_chat1)\n public void sendMessage() {\n if (getView() == null) {\n return;\n }\n EditText editText = getView().findViewById(R.id.chat_edit_text1);\n sendMessageBackend(editText.getText().toString(), utils.getChatUser());\n updateListAdapter();\n editText.setText(\"\");\n }", "public void onClickSend(View view) {\n String string = editText.getText().toString();\n serialPort.write(string.getBytes());\n tvAppend(textView, \"\\nData Sent : \" + string + \"\\n\");\n\n }", "private void sendToBtAct(String msg) {\n Intent intent = new Intent(\"getTextToSend\");\n // You can also include some extra data.\n intent.putExtra(\"tts\", msg);\n LocalBroadcastManager.getInstance(this).sendBroadcast(intent);\n }", "public void sendSmsMessage(String message)\n throws Exception {\n }", "public void onSendMessage(View view) {\n // get the EditText view of the layout with the id: message\n EditText messageView = (EditText) findViewById(R.id.message);\n // get the text added by the user in the EditText\n String messageText = messageView.getText().toString();\n // Create a new Intent with an action of SEND\n Intent intent = new Intent(Intent.ACTION_SEND);\n // set the MIME type for the Intent\n intent.setType(\"text/plain\");\n // Add to the Intent the text from the EditText view\n intent.putExtra(Intent.EXTRA_TEXT, messageText);\n // get the text form a string resource\n String chooserTitle = getString(R.string.chooser);\n // wrap the Intent in a chooser so Android always ask for with app to choose\n Intent chosenIntent = Intent.createChooser(intent, chooserTitle);\n // Start the activity of whatever app is available\n startActivity(chosenIntent);\n }", "@Override\n public void sendMessage(String message, String phoneNumber, final int command) {\n String SENT = \"SMS_SENT\";\n String DELIVERED = \"SMS_DELIVERED\";\n\n PendingIntent sentPI = PendingIntent.getBroadcast(this, 0, new Intent(\n SENT), 0);\n\n // DELIVER PendingIntent\n PendingIntent deliveredPI = PendingIntent.getBroadcast(this, 0,\n new Intent(DELIVERED), 0);\n\n BroadcastReceiver sendSMS = new BroadcastReceiver() {\n @Override\n public void onReceive(Context arg0, Intent arg1) {\n switch (getResultCode()) {\n case Activity.RESULT_OK:\n Toast.makeText(getBaseContext(), \"SMS sent\",\n Toast.LENGTH_SHORT).show();\n break;\n case SmsManager.RESULT_ERROR_GENERIC_FAILURE:\n Toast.makeText(getBaseContext(), \"Generic failure\",\n Toast.LENGTH_SHORT).show();\n break;\n case SmsManager.RESULT_ERROR_NO_SERVICE:\n Toast.makeText(getBaseContext(), \"No service\",\n Toast.LENGTH_SHORT).show();\n break;\n case SmsManager.RESULT_ERROR_NULL_PDU:\n Toast.makeText(getBaseContext(), \"Null PDU\",\n Toast.LENGTH_SHORT).show();\n break;\n case SmsManager.RESULT_ERROR_RADIO_OFF:\n Toast.makeText(getBaseContext(), \"Radio off\",\n Toast.LENGTH_SHORT).show();\n break;\n }\n }\n };\n\n // DELIVERY BroadcastReceiver\n BroadcastReceiver deliverSMS = new BroadcastReceiver() {\n @Override\n public void onReceive(Context arg0, Intent arg1) {\n switch (getResultCode()) {\n case Activity.RESULT_OK:\n\n hideProgressDialog();\n\n mPresenter.updateDatabase(command,mVehicle.getId());\n\n /*Toast.makeText(getBaseContext(), \"SMS delivered\",\n Toast.LENGTH_SHORT).show();*/\n break;\n case Activity.RESULT_CANCELED:\n Toast.makeText(getBaseContext(), \"SMS not delivered\",\n Toast.LENGTH_SHORT).show();\n break;\n }\n }\n };\n// STEP-3___\n // ---Notify when the SMS has been sent---\n registerReceiver(sendSMS, new IntentFilter(SENT));\n\n // ---Notify when the SMS has been delivered---\n registerReceiver(deliverSMS, new IntentFilter(DELIVERED));\n\n SmsManager sms = SmsManager.getDefault();\n sms.sendTextMessage(phoneNumber, null, message, sentPI, deliveredPI);\n\n }", "@Test\n public void smsTest() {\n driver.findElement(MobileBy.id(\"com.google.android.apps.messaging:id/start_new_conversation_button\")).click();\n \n wait.until(ExpectedConditions.elementToBeClickable(MobileBy.id(\"com.google.android.apps.messaging:id/recipient_text_view\")));\n driver.findElementById(\"recipient_text_view\").sendKeys(\"9980698804\");\n \n ((AndroidDriver<MobileElement>) driver).pressKey(new KeyEvent(AndroidKey.ENTER));\n \n \n driver.manage().timeouts().implicitlyWait(50, TimeUnit.SECONDS);\n \n // Focus on the message text box\n String messageBoxLocator = \"resourceId(\\\"com.google.android.apps.messaging:id/compose_message_text\\\")\";\n driver.findElement(MobileBy.AndroidUIAutomator(messageBoxLocator)).click();\n \n driver.findElementById(\"com.google.android.apps.messaging:id/compose_message_text\").sendKeys(\"Hello from Appium\");\n \n // Send the message\n driver.findElementById(\"com.google.android.apps.messaging:id/send_message_button_icon\").click();\n \n // Wait for message to show\n wait.until(ExpectedConditions.presenceOfElementLocated(MobileBy.id(\"message_text\")));\n \n // Assertion\n String sentMessageText = driver.findElementById(\"com.google.android.apps.messaging:id/message_text\").getText();\n Assert.assertEquals(sentMessageText, \"Hello from Appium\");\n }", "public void sendMessage (View view)\r\n\t{\r\n\t\t// Respond to the button click\r\n\t\tIntent intent = new Intent(this, DisplayMessageActivity.class);\r\n\t\tEditText editText = (EditText) findViewById(R.id.edit_message);\r\n\t\tString message = editText.getText().toString();\r\n\t\tintent.putExtra(EXTRA_MESSAGE, message);\r\n\t\tstartActivity(intent);\r\n\t}", "@Override\n public void onClick(View view) {\n String msg = mSendView.getText().toString();\n currMessage = msg;\n mSendView.setText(\"\");\n sendMessage(msg);\n refresh();\n\n }", "@Override\n public void onClick(View view) {\n send();\n }", "@Override\n public void onClick(View view) {\n String sms = \"FINDME location is \";\n if (LOCATION != null) {\n sms = sms + \"coordinates\" + \"*\" + LOCATION.latitude + \"*\" + LOCATION.longitude;\n }\n sendSms(\"0473848248\", sms);\n }", "public void sendMessage(View view) {\n Intent intent = new Intent(this, DisplayMessageActivity.class);\n //EditText editText = (EditText) findViewById(R.id.edit_message);\n //String message = editText.getText().toString();\n //intent.putExtra(EXTRA_MESSAGE, message);\n\n startActivity(intent);\n }", "public void sendMessage()\r\n {\r\n MessageScreen messageScreen = new MessageScreen(_lastMessageSent);\r\n pushScreen(messageScreen);\r\n }", "public void btnHelpClick(){\n try {\n String Tag = TAG + \"-BtnHelp\";\n // Get number\n String number = getMyPhoneNO();\n ReceiveMessageThread receiveMessageThread;\n // Mount the message to be sent\n String msg = \"*SOS*;Number:\" + number + \";\";\n Log.i(Tag, msg);\n // Show message to user\n showProgressDialog(\"Sending distress message...\");\n // Disable Help Button\n btn_help.setEnabled(false);\n // Start thread to send message\n receiveMessageThread = new ReceiveMessageThread(msgHandler, msg);\n receiveMessageThread.start();\n }\n catch (Exception e){\n Log.i(TAG , \"Caught this exception: \" + e.getMessage());\n }\n }", "private void composeSmsMessage(String message) {\n Intent intent = new Intent(Intent.ACTION_SENDTO, Uri.parse(CDC_SMS_PREFIX));\n intent.putExtra(\"sms_body\", message);\n if (intent.resolveActivity(getPackageManager()) != null) {\n Log.d(TAG, \"Ready to send sms\");\n intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n startActivity(intent);\n }\n }", "public void sendMessage(View view) {\n\n Intent intent = new Intent(this, DisplayMessageActivity.class);\n\n EditText editText = (EditText) findViewById(R.id.editText);\n\n String message = editText.getText().toString();\n\n intent.putExtra(EXTRA_MESSAGE, message);\n\n\n\n startActivity(intent);\n\n }", "@Step\n public void enterSmsIntoInput(String smsCode){\n actionWithWebElements.enterTextIntoInput(confirmationSmsCodeInput, smsCode);\n }", "public void sendMessage(View view) {\n Intent intent = new Intent(this, DisplayMessageActivity.class);\n EditText editText = (EditText) findViewById(R.id.editText);\n String message = editText.getText().toString();\n intent.putExtra(EXTRA_MESSAGE, message);\n startActivity(intent);\n\n }", "private void sendMessage() {\n if (mRecipientAddress == null) {\n if (mDevices.getSelectedItem() == null) {\n mStatusText.append(\"Please select a device to message.\\n\");\n return;\n }\n if (mMessage.getText() == null || mMessage.getText().toString().equals(\"\")) {\n mStatusText.append(\"Please enter a message to send.\\n\");\n return;\n }\n }\n WifiDirectClientAsyncTask t = new WifiDirectClientAsyncTask(this, mMessage.getText().toString());\n if (Build.VERSION.SDK_INT>=Build.VERSION_CODES.HONEYCOMB)\n t.executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);\n else\n t.execute();\n }", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\t\n\t\t\t\tIntent intent=new Intent(MainActivity.this,NewSms.class);\n\t\t\t\tstartActivity(intent);\n\t\t\t\tfinish();\n\t\t\t\t\n\t\t\t}", "@Override\n public void onClick(View view) {\n\n runOnUiThread(\n new Runnable() {\n @Override\n public void run() {\n MainActivity\n .this\n .connectionManager.getTo().println(\n MainActivity\n .this\n .send_text.getText().toString()\n );\n }\n }\n );\n\n }", "public void onClick(View v) {\n\t\t\t\t\t\ttry\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tString phoneno=phonenoET.getText().toString();\n\t\t\t\t\t\t\tif(phoneno.equals(\"\"))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tToast.makeText(getApplicationContext(),\"Enter Phone No.\",Toast.LENGTH_LONG).show();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse if(phoneno.length()!=10)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tToast.makeText(getApplicationContext(),\"Wrong Phone No.\",Toast.LENGTH_LONG).show();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t//uniquecode=\"hello\";\n\t\t\t\t\t\t\t\t//double code=Math.random();\n\t\t\t\t\t\t\t\t//Toast.makeText(getApplicationContext(),\"\"+code+\"\",Toast.LENGTH_LONG).show();\n\t\t\t\t\t\t\t\tuniquecode=Integer.toString((int)(Math.random()*1000000000));\n\t\t\t\t\t\t\t\t//Toast.makeText(getApplicationContext(),\"Unique CODE: \"+uniquecode,Toast.LENGTH_LONG).show();\n\t\t\t\t\t\t\t\tSmsManager sms=SmsManager.getDefault();\n\t\t\t\t\t\t\t\tsms.sendTextMessage(phoneno, null,\"Unique CODE: \"+uniquecode, null, null);\n\t\t\t\t\t\t\t\tToast.makeText(getApplicationContext(),\"Msg Sent\",Toast.LENGTH_SHORT).show();\n\t\t\t\t\t\t\t\tDate date = new Date();\n\t\t\t\t\t\t\t\tSimpleDateFormat dateFormat = new SimpleDateFormat(\"dd/MM/yyyy\");\n\t\t\t\t\t\t\t\tString currentDate = dateFormat.format(date);\n\t\t\t\t\t\t\t\tSimpleDateFormat timeFormat = new SimpleDateFormat(\"HH:mm:ss\");\n\t\t\t\t\t\t\t\tString currentTime = timeFormat.format(date);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tmBuilder.setContentTitle(\"Unique Code Sent\");\n\t\t\t\t\t\t\t\tmBuilder.setContentText(\"to \"+phoneno+\"\\non \"+currentDate+\"\");\n\t\t\t\t\t\t\t\tmBuilder.setTicker(\"Password Alert!\");\n\t\t\t\t\t\t\t\tmBuilder.setSmallIcon(R.drawable.ic_launcher);\n\t\t\t\t\t\t\t\t//mBuilder.setNumber(++numMessages);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tmNotificationManager = (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);\n\t\t\t\t\t\t\t\t/* notificationID allows you to update the notification later on. */ \n\t\t\t\t\t\t\t\tmNotificationManager.notify((int)(Math.random()*1000), mBuilder.build());\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t//Intent i=new Intent(getApplicationContext(),Read_Activity.class);\n\t\t\t\t\t\t\t\t//startActivity(i);\n\t\t\t\t\t\t\t\tphonenoET.setEnabled(false);\n\t\t\t\t\t\t\t\tsendb.setEnabled(false);\n\t\t\t\t\t\t\t\tucodeET.setVisibility(0);\n\t\t\t\t\t\t\t\tnextb.setVisibility(0);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tcatch(Exception ex)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tToast.makeText(getApplicationContext(),ex.toString(),Toast.LENGTH_LONG).show();\n\t\t\t\t\t\t\tToast.makeText(getApplicationContext(),\"Msg not Sent\",Toast.LENGTH_LONG).show();\n\t\t\t\t\t\t}\n\t\t\t\t\t}", "@Override\r\n public void onClick(View v) {\n String msg = ed_msg.getText().toString();\r\n try {\r\n\t\t\t\t\tsend(HOST, PORT, msg.getBytes());\r\n\t\t\t\t\t\r\n\t \tmHandler.sendMessage(mHandler.obtainMessage()); \r\n\t \tcontent =HOST +\":\"+ msg +\"\\n\";\r\n\t\t\t\t} catch (IOException e) {\r\n\t\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n }", "public void sendMessage(View view) {\n Intent intent = new Intent(this, DisplayMessageActivity.class);\n String message = \"You pressed the button!\";\n intent.putExtra(EXTRA_MESSAGE, message);\n startActivity(intent);\n\n }", "@Override\r\n\tpublic void mesage() {\n\t\tSystem.out.println(\"通过语音发短信\");\r\n\t}", "public void sendMessage(View view) {\n\t\t// Do something in response to button\n\t\tIntent intent = new Intent(this, DisplayMessageActivity.class);\n\t\tstartActivity(intent);\n\n\t}", "public void sendMessage(View view) {\n EditText editText = findViewById(R.id.user_message);\n String message = editText.getText().toString();\n\n Intent intent = new Intent(this, MessageActivity.class);\n\n intent.putExtra(\"EXTRA_MESSAGE\", message);\n\n startActivity(intent);\n }", "private boolean sendSms(final Event event2send) {\n final Customer customer = event2send.getCustomer();\n final Unit unit = customer.getUnit();\n\n final String text2send = TextUtils.convert2ascii(format(event2send));\n final Map<String, Object> unitOptions = getUnitOptions(unit);\n @SuppressWarnings(\"unchecked\")\n final Map<String, String> smsOptions = (Map<String, String>) unitOptions.get(\"sms\");\n\n try {\n assertSmsOptions(smsOptions);\n smsGatewayService.send(customer.getPhoneNumber(), text2send, smsOptions);\n LOG.info(\"event sent via SMS, id=\" + event2send.getId() + \", phone=\" + customer.getPhoneNumber());\n } catch (Throwable t) {\n if (t instanceof SmsException\n && SmsGatewayService.FailureType.BAD_PHONE_NUMBER == ((SmsException) t).getFailureType()) {\n LOG.warning(\"failed to send SMS (bad phone number), ID= + event2send.getId()\");\n } else {\n LOG.log(Level.SEVERE, \"failed to send SMS, ID=\" + event2send.getId(), t);\n }\n return false;\n }\n return true;\n }", "public void clickButton(View v) {\n\n // Get the text we want to send.\n EditText et = (EditText) findViewById(R.id.editText);\n String msg = et.getText().toString();\n\n // Then, we start the call.\n PostMessageSpec myCallSpec = new PostMessageSpec();\n\n\n myCallSpec.url = SERVER_URL_PREFIX + \"post_msg.json\";\n myCallSpec.context = ChatActivity.this;\n // Let's add the parameters.\n HashMap<String,String> m = new HashMap<String,String>();\n m.put(\"app_id\", MY_APP_ID);\n m.put(\"msg\", msg);\n myCallSpec.setParams(m);\n\n startSpinner();\n\n // Actual server call.\n if (uploader != null) {\n // There was already an upload in progress.\n uploader.cancel(true);\n }\n uploader = new ServerCall();\n //startSpinner();\n uploader.execute(myCallSpec);\n }", "private void sendSMS(String msg) {\n SmsManager smsManager = SmsManager.getDefault();\n for (String destinationAddress : destinationAddresses) {\n smsManager.sendTextMessage(\n destinationAddress,\n null,\n msg,\n null,\n null\n );\n }\n }", "@Override\r\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tif(checkPhoneNum()){\r\n\t\t\t\t\tet_phone.setVisibility(View.GONE);\r\n\t\t\t\t\tly_two.setVisibility(View.VISIBLE);\r\n\t\t\t\t\tbt_next.setVisibility(View.GONE);\r\n\t\t\t\t\tbt_login.setVisibility(View.VISIBLE);\r\n\t\t\t\t\tsetTextSend();\r\n\t\t\t\t\tsendSmsNew(phoneNum);\r\n\t\t\t\t}else{\r\n\t\t\t\t\tToast.makeText(mContext, \"请输入正确的手机号\", Toast.LENGTH_LONG).show();\r\n\t\t\t\t}\r\n\t\t\t}", "public void onClick(View v) {\n\t\t\t\tLog.d(\"on\", \"274\");\n\t\t\t\tIntent smsIntent = new Intent(Intent.ACTION_VIEW);\n\t\t\t\tsmsIntent.setType(\"vnd.android-dir/mms-sms\");\n\t\t\t\tsmsIntent.putExtra(\"sms_body\", translatedText);\n\t\t\t\tstartActivity(smsIntent);\n\n\t\t\t}", "@Override\r\n public void onClick(View v)\r\n {\n if (\"\" != mSendOnBoardEdit.getText().toString()){\r\n DJIDrone.getDjiMainController().sendDataToExternalDevice(mSendOnBoardEdit.getText().toString().getBytes(),new DJIExecuteResultCallback(){\r\n\r\n @Override\r\n public void onResult(DJIError result)\r\n {\r\n // TODO Auto-generated method stub\r\n \r\n }\r\n \r\n });\r\n }\r\n }", "@Override\n public void onClick(View view) {\n intent.putExtra(SEND_KEY,sendText.getText().toString());\n\n //Start next Activity/No data is passed back to this activity\n startActivity(intent);\n\n }", "@Override\n public void onActionClicked(View view, Card card) {\n AlertDialog.Builder mbuilder=new AlertDialog.Builder(EventHandler.this);\n View mView=getLayoutInflater().inflate(R.layout.event_registerinflate,null);\n final EditText mContact=(EditText)mView.findViewById(R.id.editContact);\n Button btnEvent=(Button)mView.findViewById(R.id.btnregisterEvent);\n\n final int PERMISSION_REQUEST_CODE = 1;\n\n if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.M) {\n\n if (checkSelfPermission(Manifest.permission.SEND_SMS)\n == PackageManager.PERMISSION_DENIED) {\n\n Log.d(\"permission\", \"permission denied to SEND_SMS - requesting it\");\n String[] permissions = {Manifest.permission.SEND_SMS};\n\n requestPermissions(permissions, PERMISSION_REQUEST_CODE);\n\n }\n }\n\n\n btnEvent.setOnClickListener(new View.OnClickListener() {\n @Override\n public void onClick(View v) {\n\n String myNum=mContact.getText().toString().trim();\n String myMsg= \"You successfully registered to \" +eh.getName()+\" which is to be conducted on\"+\" \"+eh.getDate();\n if(myNum==null || myNum.equals(\"\")){\n Toast.makeText(EventHandler.this, \"Field cant be Empty\", Toast.LENGTH_SHORT).show();\n }\n else if(TextUtils.isDigitsOnly(myNum)){\n SmsManager smsManager=SmsManager.getDefault();\n smsManager.sendTextMessage(myNum,null,myMsg,null,null);\n Toast.makeText(EventHandler.this, \"Registration message Sent\", Toast.LENGTH_SHORT).show();\n\n }\n else{\n Toast.makeText(EventHandler.this, \"Please Enter Integer only\", Toast.LENGTH_SHORT).show();\n }\n\n }\n });\n mbuilder.setView(mView);\n AlertDialog dialog=mbuilder.create();\n dialog.show();\n\n\n }", "public void goToSendCommand(View view){\n Log.i(tag, \"About to launch SendCommand\");\n Intent i = new Intent(this, SendCommand.class);\n startActivity(i);\n }", "private void sendMessage(String message)\n {\n\t\tif(regid == null || regid.equals(\"\"))\n\t\t{\n\t\t Toast.makeText(this, \"You must register first\", Toast.LENGTH_LONG).show();\n\t\t return;\n\t\t}\n\t\tString messageType = ((Spinner)findViewById(R.id.spinner_message_type)).getSelectedItem().toString();\n\t\tnew AsyncTask<String, Void, String>()\n\t\t{\n\t\t @Override\n\t\t protected String doInBackground(String... params)\n\t\t {\n\t\t\tString msg = \"\";\n\t\t\ttry\n\t\t\t{\n\t\t\t Bundle data = new Bundle();\n\t\t\t data.putString(\"message\", params[0]);\n\t\t\t if(params[1].equals(\"Echo\"))\n\t\t\t {\n\t\t\t\tdata.putString(\"action\", \"com.antoinecampbell.gcmdemo.ECHO\");\n\t\t\t }\n\t\t\t else if(params[1].equals(\"Broadcast\"))\n\t\t\t {\n\t\t\t\tdata.putString(\"action\", \"com.antoinecampbell.gcmdemo.BROADCAST\");\n\t\t\t }\n\t\t\t else if(params[1].equals(\"Notification\"))\n\t\t\t {\n\t\t\t\tdata.putString(\"action\", \"com.antoinecampbell.gcmdemo.NOTIFICATION\");\n\t\t\t }\n\t\t\t String id = Integer.toString(msgId.incrementAndGet());\n\t\t\t gcm.send(Globals.GCM_SENDER_ID + \"@gcm.googleapis.com\", id, Globals.GCM_TIME_TO_LIVE, data);\n\t\t\t msg = \"Sent message\";\n\t\t\t}\n\t\t\tcatch (IOException ex)\n\t\t\t{\n\t\t\t msg = \"Error :\" + ex.getMessage();\n\t\t\t}\n\t\t\treturn msg;\n\t }\n\n\t @Override\n\t protected void onPostExecute(String msg)\n\t {\n\t \tToast.makeText(context, msg, Toast.LENGTH_SHORT).show();\n\t }\n\t}.execute(message, messageType);\n }", "public void sendText(View view)\n {\n String toSay = editText.getText().toString();\n editText.getText().clear();\n findViewById(R.id.main_layout).requestFocus();\n InputMethodManager imm = (InputMethodManager) getSystemService(Activity.INPUT_METHOD_SERVICE);\n imm.hideSoftInputFromWindow(view.getWindowToken(), 0);\n logicController.ConnectToServer(toSay, false);\n //ttsCont.speakThis(toSay);\n //toastWithTimer(toSay, true);\n }", "@Override\n\tpublic void SendMessage() {\n\t\tSystem.out.println( phoneName+\"'s SendMessage.\" );\n\t}", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\tif(edittext_phone.length()!=11)\n\t\t\t\t{\n\t\t\t\t\tToast.makeText(getBaseContext(), \"手机号码有误!\", Toast.LENGTH_LONG).show();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tif(edittext_pas.length()<1)\n\t\t\t\t{\n\t\t\t\t\tToast.makeText(getBaseContext(), \"请输入密码!\", Toast.LENGTH_LONG).show();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\n\t\t\t\tverfy_button.setEnabled(false);\n\t\t\t\ttime=30;\n\t\t\t\trelativeLayoutregist.setVisibility(View.INVISIBLE);\n\t\t\t\trelativeLayouttijiao.setVisibility(View.VISIBLE);\n\t\t\t\t//传电话号码\n\t\t\t\ttextview_phone.setText(edittext_phone.getText().toString());\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t//Todo 发送短信,获取验证码\n\t\t\t\tinitSDK();\n\t\t\t\tSMSSDK.getVerificationCode(\"86\",textview_phone.getText().toString());\n\t\t\t\t\t\n\t\t\t\thandler.postDelayed(runnable, 1000); \n\t\t\t\t \n\t\t\t}", "public void sendSmsMessage(String phoneNumber, String message)\n {\n if(phoneNumber != null)\n chatTransport.getParentChatSession()\n .setDefaultSmsNumber(phoneNumber);\n\n SMSManager.sendSMS(phoneNumber, message, chatTransport, chatPanel);\n\n this.dispose();\n }", "public void sendSmsMessage(String phoneNumber, String message)\n throws Exception {\n }", "private void sendMessage(String contactNumber) {\n Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(\"sms:\" + contactNumber));\n startActivity(intent);\n }", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\ttry {\n\t\t\t\t\tString body = etBody.getText().toString();\n\t\t\t\t\tTApplicatioin.multiUserChat.sendMessage(body);\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t// TODO: handle exception\n\t\t\t\t}\n\t\t\t}", "private void enviarMensaje (String numero, String mensaje){\n try {\n SmsManager sms = SmsManager.getDefault();\n sms.sendTextMessage(numero,null,mensaje,null,null);\n Toast.makeText(getApplicationContext(), \"Mensaje Enviado.\", Toast.LENGTH_LONG).show();\n }\n catch (Exception e) {\n Toast.makeText(getApplicationContext(), \"Mensaje no enviado, datos incorrectos.\", Toast.LENGTH_LONG).show();\n e.printStackTrace();\n }\n }", "public void handleSMSAlert()\n\t{\n\t\t\n\t\tWebDriverWait wait=new WebDriverWait(driver, 60);\n\t\t\n\t\twait.until(ExpectedConditions.visibilityOf(checker));\n\t\t\n\t\tif(!Generic.getAttribute(checker, \"resourceId\").contains(\"message\"))\n\t\t\treturn; // No Alert found\n\t\telse\n\t\t{\n\t\t\tif(checker.getText().contains(\"verification could not be completed\"))\n\t\t\t\tAssert.fail(\"Phone Verification failed\");\n\t\t\t\n\t\t\tLog.info(\"== Handling SMS Alert ==\");\n\t\t\tokButton.click();\n\t\t\t\n\t\t\twaitOnProgressBarId(60);\n\t\t}\n\t\t\n\t\twait.until(ExpectedConditions.visibilityOf(checker));\n\t\t\n\t\tif(!Generic.getAttribute(checker, \"resourceId\").contains(\"message\"))\n\t\t\treturn; // No Alert found\n\t\telse\n\t\t{\n\t\t\tLog.info(\"== Handling second SMS Alert ==\");\n\t\t\tokButton.click();\n\t\t\t\n\t\t\twait.until(ExpectedConditions.visibilityOf(checker));\n\t\t}\n\t\t\t\t\n\t\t\n\t\t\n\t}", "@Override\n\tpublic void onClick(View v) {\n\t\tswitch (v.getId()) {\n\t\tcase R.id.btn_cancel:\n\t\t\tdismiss();\n\t\t\tbreak;\n\t\tcase R.id.btn_send:\n\t\t\tsendSMS();\n\t\t\tdismiss();\n\t\t\tbreak;\n\t\tdefault:\n\t\t\tbreak;\n\t\t}\n\t}", "public void sendMessage(View view) {\n }", "@Override\n\tvoid doSecondStep(String code) throws SmsException {\n\t\tString action = getElement(\"<form name=\\\"__aspnetForm\\\" method=\\\"post\\\" action=\\\"\", \"\\\"\");\n\t\tString postUrl = baseUrl + action;\n\t\t\n\t\t//Set input parameters:\n\t\tNameValuePair[] postParameters = {\n\t\t\tnew NameValuePair(\"__VIEWSTATE\", getElement(\"name=\\\"__VIEWSTATE\\\" value=\\\"\", \"\\\"\")),\n\t\t\tnew NameValuePair(\"SmsSender:PrePhone\", def),\n\t\t\tnew NameValuePair(\"SmsSender:phoneNumber\", phoneNumber),\n\t\t\tnew NameValuePair(\"SmsSender:smsText\", message),\n\t\t\tnew NameValuePair(\"SmsSender:code\", code),\n\t\t\tnew NameValuePair(\"SmsSender:Button1\", \"Отправить\") };\n\t\t\n\t\tpostData(postUrl, postParameters);\n\t\t\n\t}", "@Override\n public void call(Object... args) {\n runOnUiThread(new Runnable() {\n @Override\n public void run() {\n\n //edit.setText(\"Success!!!!!\");\n Toast.makeText(getApplicationContext(),\"Success send Test \",Toast.LENGTH_LONG).show();\n }\n });\n }", "@Override\r\n\tpublic void onClick(View v) {\n\t\tswitch (v.getId()) {\r\n case R.id.sendd:\r\n buffer = new byte[]{'d'};\r\n if (sendMessage(buffer) == -1) {\r\n Toast.makeText(getActivity(), \"失败,请检查连接!\", Toast.LENGTH_SHORT).show();\r\n } else {\r\n Toast.makeText(getActivity(), \"正在关闭,请稍后...\", Toast.LENGTH_SHORT).show();\r\n }\r\n break;\r\n case R.id.sendz:\r\n buffer = new byte[]{'z'};\r\n if (sendMessage(buffer) == -1) {\r\n Toast.makeText(getActivity(), \"失败,请检查连接!\", Toast.LENGTH_SHORT).show();\r\n } else {\r\n Toast.makeText(getActivity(), \"正在关闭,请稍后...\", Toast.LENGTH_SHORT).show();\r\n }\r\n break;\r\n case R.id.sendrclear:\r\n byte[] a = new byte[]{60,0,0};\r\n sendR(a);\r\n break;\r\n case R.id.sendrcloud:\r\n byte[] b = new byte[]{0,2,0};\r\n sendR(b);\r\n break;\r\n\r\n case R.id.sendrcloud2:\r\n byte[] c = new byte[]{127,2,0};\r\n sendR(c);\r\n break;\r\n\r\n case R.id.sendrrain:\r\n byte[] d = new byte[]{60,1,1};\r\n sendR(d);\r\n break;\r\n\r\n\t\tdefault:\r\n\t\t\tbreak;\r\n\t\t}\r\n\r\n\t}", "public void sendSMS(String incomingNumber, Context context){\n\t\tString t = getContactText(incomingNumber);\n\t\tif(t != null){\n\t\t\tLog.d(TAG,\"Contact Specific\");\n\t\t\tsend(incomingNumber,context,t);\n\t\t}\n\t\telse{\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// If not\n\t\t\tLog.d(TAG,\"in sendSMS non Contact Specific\");\n\t\t\tsend(incomingNumber,context);\n\t\t}\n\t}", "public void sendMessageToMobile(final String str) {\r\n\r\n\t\tnew Thread(new Runnable() {\r\n\r\n\t\t\t@Override\r\n\t\t\tpublic void run() {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tPrintWriter out = new PrintWriter(new OutputStreamWriter(s.getOutputStream(), \"utf-8\"), true);\r\n\r\n\t\t\t\t\tif (!str.isEmpty()){\r\n\t\t\t\t\t\tout.println(str);\r\n\t\t\t\t\t\tout.flush();\r\n\t\t\t\t\t\tSystem.out.println(\"sent to mobile: \"+ str);\r\n\t\t\t\t\t} \r\n\t\t\t\t}\r\n\t\t\t\tcatch (IOException e) {\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t} \r\n\t\t\t}\r\n\t\t}).start();\r\n\t}", "@Override\n \t public void onClick(View v) {\n \t\tRegno=(EditText) findViewById(R.id.regno);\n \t\tRouteno=(EditText) findViewById(R.id.routeno);\n \t\tDriver =(EditText) findViewById(R.id.name);\n \t\tPhone = (EditText) findViewById(R.id.phone);\n \t\t\n \t\tmrg = Regno.getText().toString();\n \t\tmrn = Routeno.getText().toString();\n \t\tmd = Driver.getText().toString();\n \t\tmp = Phone.getText().toString();\n \t\t\n \t\tIntent intentVibrate =new Intent(getApplicationContext(),VibrateService.class);\n \t\tstartService(intentVibrate);\n \t\t \t\t\n \t\t sendData();\n \t\t }" ]
[ "0.79975164", "0.7922593", "0.7859705", "0.7833966", "0.757914", "0.7566105", "0.7565452", "0.7475996", "0.7456983", "0.7450973", "0.73838", "0.73447585", "0.73093885", "0.7291197", "0.72868896", "0.71907634", "0.7072489", "0.70631504", "0.7025915", "0.702233", "0.70068085", "0.69921046", "0.69835556", "0.69535774", "0.6923599", "0.69109565", "0.6905555", "0.68993926", "0.689442", "0.6887168", "0.68440527", "0.6819463", "0.6818755", "0.6814037", "0.6810718", "0.67920095", "0.67787355", "0.6773273", "0.67716247", "0.67631894", "0.67323077", "0.6726906", "0.6723199", "0.67079586", "0.67067695", "0.6696329", "0.6688835", "0.66463625", "0.6633713", "0.6604742", "0.6572891", "0.655683", "0.65515006", "0.6548116", "0.65250456", "0.6518281", "0.651635", "0.6511127", "0.65026456", "0.6494673", "0.6462593", "0.64594775", "0.644605", "0.64433664", "0.6441233", "0.64411485", "0.6416496", "0.6415053", "0.6407734", "0.6390799", "0.63901377", "0.6375606", "0.637362", "0.6371168", "0.63546723", "0.63247234", "0.6313659", "0.63086176", "0.63053435", "0.63033885", "0.6303352", "0.62947166", "0.62838537", "0.6270613", "0.6268462", "0.6265695", "0.6264415", "0.6256098", "0.6251157", "0.62408125", "0.62285984", "0.62153757", "0.62105036", "0.61914307", "0.6171457", "0.6163845", "0.614632", "0.6144117", "0.6143415", "0.61334443" ]
0.7997189
1
Send SMS Method Body
private void sendSms(String strPhoneNumber, String strSms) { if (ActivityCompat.checkSelfPermission(this, Manifest.permission.SEND_SMS) == PackageManager.PERMISSION_GRANTED) {// checking runtime permission for Sending SMS try { SmsManager smsManager = SmsManager.getDefault(); smsManager.sendTextMessage(strPhoneNumber, null, strSms, null, null);// this statement send sms(background) Toast.makeText(getApplicationContext(), "Message Sent Successful", Toast.LENGTH_LONG).show();// Showing Toast after sending SMS } catch (Exception e) { Toast.makeText(getApplicationContext(), e.getMessage().toString(), Toast.LENGTH_LONG).show();// Showing Toast if SMS sending fail e.printStackTrace(); } } else { if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) { requestPermissions(new String[]{Manifest.permission.SEND_SMS}, 10);// Grant runtime permission for sending SMS } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public void sendSms(String smsBody) {\n }", "public java.lang.String sendSMS(java.lang.String accessCode, java.lang.String toNumber, java.lang.String body) throws java.rmi.RemoteException;", "SendSMSResponse sendSMSProcess(SendSMSRequest smsRequest) throws Exception;", "public void sendSms() {\n\n }", "void requestSendSMSCode(Context context,String phone);", "public String sendSms() {\r\n\t\ttry {\r\n\t\t\t// Construct data\r\n\t\t\tString user = \"username=\" + \"[email protected]\";\r\n\t\t\tString hash = \"&hash=\" + \"Leonxandercs3\";\r\n\t\t\tString message = \"&message=\" + \"Prueba de Envio de Sms desde Java...by tu papi Alexander\";\r\n\t\t\tString sender = \"&sender=\" + \"Alexander\t\";\r\n\t\t\tString numbers = \"&numbers=\" + \"51954191116\";\r\n\r\n\t\t\t// Send data\r\n\t\t\tHttpURLConnection conn = (HttpURLConnection) new URL(\"https://api.txtlocal.com/send/?\").openConnection();\r\n\t\t\tString data = user + hash + numbers + message + sender;\r\n\t\t\tconn.setDoOutput(true);\r\n\t\t\tconn.setRequestMethod(\"POST\");\r\n\t\t\tconn.setRequestProperty(\"Content-Length\", Integer.toString(data.length()));\r\n\t\t\tconn.getOutputStream().write(data.getBytes(\"UTF-8\"));\r\n\t\t\tfinal BufferedReader rd = new BufferedReader(new InputStreamReader(conn.getInputStream()));\r\n\t\t\tfinal StringBuffer stringBuffer = new StringBuffer();\r\n\t\t\tString line;\r\n\t\t\twhile ((line = rd.readLine()) != null) {\r\n\t\t\t\tstringBuffer.append(line);\r\n\t\t\t\tSystem.out.println(line);\r\n\t\t\t}\r\n\t\t\trd.close();\r\n\t\t\t\r\n\t\t\treturn stringBuffer.toString();\r\n\t\t} catch (Exception e) {\r\n\t\t\tSystem.out.println(\"Error SMS \"+e);\r\n\t\t\treturn \"Error \"+e;\r\n\t\t}\r\n\t}", "public void send(View v)\r\n {\r\n \t// get the phone number from the phone number text field\r\n String phoneNumber = phoneTextField.getText().toString();\r\n // get the message from the message text box\r\n String msg = msgTextField.getText().toString(); \r\n\r\n // make sure the fields are not empty\r\n if (phoneNumber.length()>0 && msg.length()>0)\r\n {\r\n \t// call the sms manager\r\n PendingIntent pi = PendingIntent.getActivity(this, 0,\r\n new Intent(this, SendSMSActivity.class), 0);\r\n SmsManager sms = SmsManager.getDefault();\r\n \r\n // this is the function that does all the magic\r\n sms.sendTextMessage(phoneNumber, null, msg, pi, null);\r\n \r\n }\r\n else\r\n {\r\n \t// display message if text fields are empty\r\n Toast.makeText(getBaseContext(),\"All field are required\",Toast.LENGTH_SHORT).show();\r\n }\r\n\r\n }", "@Override\n public void send() {\n System.out.println(\"send message by SMS\");\n }", "private void sendSMS() {\n String msg = \"\";\n\n switch (s) {\n case \"Accelerometre\":\n msg = acce;\n break;\n case \"Lumiere\":\n msg = light;\n break;\n case \"Proximite\":\n msg = proxi;\n break;\n case \"Gyroscope\":\n msg = gyro;\n break;\n }\n\n String num = numero.getText().toString();\n\n final int PERMISSION_REQUEST_CODE = 1;\n\n if (checkSelfPermission(android.Manifest.permission.SEND_SMS) ==\n PackageManager.PERMISSION_DENIED) {\n Log.d(\" permission \", \" permission denied to SEND_SMS - requesting it \");\n String[] permissions = {android.Manifest.permission.SEND_SMS};\n requestPermissions(permissions, PERMISSION_REQUEST_CODE);\n } else {\n if (num.length() == 10) {\n SmsManager.getDefault().sendTextMessage(num, null, msg, null, null);\n numero.setText(\"\");\n } else {\n //On affiche un petit message d'erreur dans un Toast\n Toast toast = Toast.makeText(CapteurActivity.this, \"Veuilliez écrire un numero a 10 chiffres\", Toast.LENGTH_LONG);\n toast.show();\n\n }\n }\n }", "public abstract EOutgoingSMSAcceptionStatus rawSendMessage(OutgoingSMSDto smsOut) throws IOException;", "public void smsSendMessage(String phoneNumber, String messageContent) {\n try {\n //EditText editText = (EditText) findViewById(R.id.editText_main);\n // Set the destination phone number to the string in editText.\n String destinationAddress = \"07956765611\";\n // Find the sms_message view.\n //EditText smsEditText = (EditText) findViewById(R.id.sms_message);\n // Get the text of the SMS message.\n String smsMessage = \"Hi Kobi\";\n // Set the service center address if needed, otherwise null.\n String scAddress = null;\n // Set pending intents to broadcast\n // when message sent and when delivered, or set to null.\n PendingIntent sentIntent = null, deliveryIntent = null;\n // Use SmsManager.\n SmsManager smsManager = SmsManager.getDefault();\n\n smsManager.sendTextMessage\n (destinationAddress, scAddress, smsMessage,\n sentIntent, deliveryIntent);\n } catch (Exception e) {\n e.printStackTrace();\n }\n }", "com.polytech.spik.protocol.SpikMessages.Sms getSms();", "@Override\n public String sendSms(String phone, String smsContext) {\n String extno = \"\";\n StringBuilder param = new StringBuilder();\n param.append(\"&account=\" + account);\n param.append(\"&pswd=\" + password);\n param.append(\"&mobile=\" + phone);\n try {\n param.append(\"&msg=\" + URLEncoder.encode(smsContext, \"utf-8\"));\n } catch (UnsupportedEncodingException e) {\n e.printStackTrace();\n return \"\";\n }\n param.append(\"&needstatus=\" + false);\n param.append(\"&extno=\" + extno);\n\n try {\n return SmsUtil.sendSms(url, param.toString());\n } catch (IOException e) {\n e.printStackTrace();\n return null;\n }\n }", "@Override\n public void onClick(View v) {\n if (v == mBtnSendSms) {\n String strMobileNumber = mEditTextMobileNumber.getText().toString().trim();\n String strSmeBody = mEditTextSmsBody.getText().toString().trim();\n sendSms(strMobileNumber, strSmeBody);// Send SMS Method\n }\n\n }", "public void sendmessage(View v){\n \tIntent intent =new Intent();//意图\n \tintent.setAction(Intent.ACTION_SENDTO);//设置发短信意图\n \tintent.setData(Uri.parse(\"smsto:\"+1358752546));//设置拨号的信息\n \t//问题:怎么不能用11位电话号码\n \tString message=\"我是水哥,有妹子么\";\n \tintent.putExtra(\"sms_body\", message);\n \tstartActivity(intent);//开启意图\t \n }", "public static void enviarSMS(Activity actividad, String texto, String numerodestino) {\n Uri uri = Uri.parse(\"smsto:\" + numerodestino);\n Intent i = new Intent(Intent.ACTION_SENDTO, uri);\n i.putExtra(\"sms_body\", texto);\n //i.setPackage(\"com.whatsapp\");\n actividad.startActivity(i);\n }", "public void sendSmsMessage(String message)\n throws Exception {\n }", "protected void sendSMSMessage(String phonnumber) {\n String message = null;\r\n if (BookElectionFrgament.BTTtime == true) {\r\n message = \"Hey! The tee time booking is confirmed as follows Date -\" + BookElectionFrgament.formattedDate + \"\\n, Time - \" + BookElectionFrgament.timeselected + \"\\n, No. of Holes - \" + BookElectionFrgament.hole + \"\\nSee you at Karma Lakelands! \";\r\n } else if (Bookingdriverange.BDRTime == true) {\r\n message = \"Hey! The driving range booking is confirmed as follows Date -\" + Bookingdriverange.formattedDate + \"\\n, Time - \" + Bookingdriverange.timeselected + \"\\n, Balls - \" + Bookingdriverange.bucketselected + \"\\nSee you at Karma Lakelands! \";\r\n\r\n }\r\n\r\n try {\r\n SmsManager smsManager = SmsManager.getDefault();\r\n\r\n smsManager.sendTextMessage(phonnumber, null, message, null, null);\r\n\r\n // Customdialog messagedialog= new Customdialog(SMS1.this);\r\n // messagedialog.show();\r\n\r\n Toast.makeText(getApplicationContext(), \"Your message has been sent successfully!\", Toast.LENGTH_SHORT).show();\r\n } catch (Exception e) {\r\n Toast.makeText(getApplicationContext(), \"SMS failed, please try again.\", Toast.LENGTH_SHORT).show();\r\n e.printStackTrace();\r\n }\r\n }", "String sendSimpleMessageV2(String from, String fromMail, String to, String subject, String body);", "public void sendToAdmin(String sessionid, Smsmodel sms, String vals) throws ProtocolException, MalformedURLException, IOException {\r\n String val = null;\r\n System.out.println(\"hello boy \" + vals);\r\n String sender = \"DND_BYPASSGetItDone\";\r\n URL url = new URL(\"http://www.smslive247.com/http/index.aspx?cmd=sendmsg&sessionid=\" + sessionid + \"&message=\" + sms.getVendorMessage() + \"&sender=\" + sender + \"&sendto=\" + vals + \"&msgtype=0\");\r\n //http://www.bulksmslive.com/tools/geturl/Sms.php?username=abc&password=xyz&sender=\"+sender+\"&message=\"+message+\"&flash=0&sendtime=2009-10- 18%2006:30&listname=friends&recipients=\"+recipient; \r\n //URL gims_url = new URL(\"http://smshub.lubredsms.com/hub/xmlsmsapi/send?user=loliks&pass=GJP8wRTs&sender=nairabox&message=Acct%3A5073177777%20Amt%3ANGN1%2C200.00%20CR%20Desc%3ATesting%20alert%20Avail%20Bal%3ANGN%3A1%2C342%2C158.36&mobile=08065711040&flash=0\");\r\n final String USER_AGENT = \"Mozilla/5.0\";\r\n\r\n HttpURLConnection con = (HttpURLConnection) url.openConnection();\r\n con.setRequestMethod(\"GET\");\r\n con.setRequestProperty(\"User-Agent\", USER_AGENT);\r\n int responseCode = con.getResponseCode();\r\n BufferedReader in = new BufferedReader(new InputStreamReader(con.getInputStream()));\r\n String inputLine;\r\n StringBuffer response = new StringBuffer();\r\n // System.out.println(messageModel.getBody() + \" dude\");\r\n while ((inputLine = in.readLine()) != null) {\r\n response.append(inputLine);\r\n }\r\n in.close();\r\n String responseCod = response.toString();\r\n }", "public String sendPushSMS(String username,String password,String message,String mobiles ,String smsId,String vendorID,String sender, String flash, String scheduleDate, String scheduleTime ){\n\t\tString user = \"mahaforest\";\n\t\tString pass = \"1327e811606505f48ce612a22b2979e6\";\n\t\tString route = \"4\";;\n\t\tString unicode = \"0\";\n\n\t\tString parameter = \"authkey=\" +vendorID+ \"mobiles=\"+ mobiles + \"&message=\" + message + \"&sender=\"\n\t\t\t\t+ sender + \"&route=\"+route+\"unicode=\"+unicode;\n\t\n\n\t\tbyte[] postData = parameter.getBytes(StandardCharsets.UTF_8);\n\t\tint postDataLength = postData.length;\n\n\t\tBufferedReader rd = null;\n\t\tStringBuilder sb = null;\n\t\tString line = null;\n\n\t\tString MainURL = \"https://control.msg91.com/api/sendhttp.php\";\n\n\t\tString FinalUrl = MainURL + parameter;\n\n\t\tURL url;\n\t\ttry {\n\t\t\t// url = new URL(\n\t\t\t// \"https://control.msg91.com/api/sendhttp.php?authkey=85509AJLB0vH7J55642514&mobiles=8149799364&message=Welcome to MahaOnline SMS Gateway&sender=MAHGOV&route=4&unicode=0\");\n\t\t\turl = new URL(MainURL);\n\n\t\t\tHttpURLConnection http = (HttpURLConnection) url\n\t\t\t\t\t.openConnection();\n\t\t\thttp.setDoOutput(true);\n\t\t\thttp.setInstanceFollowRedirects(false);\n\t\t\thttp.setRequestMethod(\"POST\");\n\t\t\thttp.setRequestProperty(\"Content-Type\",\n\t\t\t\t\t\"application/x-www-form-urlencoded\");\n\t\t\thttp.setRequestProperty(\"Content-Length\",\n\t\t\t\t\tInteger.toString(postDataLength));\n\t\t\thttp.setRequestProperty(\"charset\", \"UTF8\");\n\t\t\thttp.setUseCaches(false);\n\n\t\t\tDataOutputStream wr = new DataOutputStream(\n\t\t\t\t\thttp.getOutputStream());\n\t\t\twr.write(postData);\n\t\t\twr.flush();\n\t\t\twr.close();\n\t\t\t// http.connect();\n\n\t\t\tint statusCode;\n\t\t\tstatusCode = http.getResponseCode();\n\t\t\trd = new BufferedReader(new InputStreamReader(\n\t\t\t\t\thttp.getInputStream(), \"UTF8\"));\n\t\t\tsb = new StringBuilder();\n\n\t\t\tsb.append(\"{ data :\");\n\t\t\twhile ((line = rd.readLine()) != null) {\n\t\t\t\tsb.append(line + '\\n');\n\t\t\t}\n\n\t\t\tsb.append(\"}\");\n\t\t\trd.close();\n\n\t\t\tString jsonResponse = sb.toString();\n\t\t} catch (Exception e) {\n\t\t\tSystem.out.println(\"RunJob Exception \" + e.toString());\n\t\t}\n\t\t\n\t\t\n\t\treturn null;\n\t}", "public static ApiResponse sendSms(String host, String accessToken, String tel, String message) throws ApiRequestException {\n String url = host + SMS_MESSAGING_OUTBOX;\n String[] telArray = tel.split(\",\");\n JSONObject object = new JSONObject();\n\n try {\n if (telArray.length == 1) {\n object.put(\"Address\", \"tel:\" + telArray[0]);\n } else {\n for (int i = 0; i < telArray.length; i++) {\n telArray[i] = \"tel:\" + telArray[i];\n }\n object.put(\"Address\", telArray);\n }\n object.put(\"Message\", message);\n } catch (JSONException e) {\n e.printStackTrace();\n }\n\n \n HttpPost post = new HttpPost(url);\n post.setHeader(\"Authorization\", \"Bearer \"+accessToken);\n \n\t log.info(\"ServiceProviderSMS :: sendSms POST to url: \" + url);\n\t log.info(\"ServiceProviderSMS :: sendSms Request: \" + object);\n\t \n ApiResponse response = ApiRequestManager.postJSON(object, post);\n\n\t log.info(\"ServiceProviderSMS :: sendSms Response: \" + response.toJson());\n\n return response;\n }", "SendSmsResponse sendSms(String templateId, String phoneNumber, Map<String, String> personalisation, String reference) throws NotificationClientException;", "@Override\r\n\t public void onClick(View arg0) {\n\t screenDialog.dismiss();\r\n\t String sms = messageText.getText().toString();\r\n\t \ttry {\r\n\t\t\t\tSmsManager smsManager = SmsManager.getDefault();\r\n\t\t\t\tsmsManager.sendTextMessage(phone, null, sms, null, null);\r\n\t\t\t\tToast.makeText(getApplicationContext(), \"SMS Sent!\",\r\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\r\n\t\t\t} catch (Exception e) {\r\n\t\t\t\tToast.makeText(getApplicationContext(),\r\n\t\t\t\t\t\t\"SMS faild, please try again later!\",\r\n\t\t\t\t\t\tToast.LENGTH_LONG).show();\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\t }", "@Override\n\tpublic void sendSMS() {\n\t\tSystem.out.println(\"Logic B\" + \" Send By: \" + getVendorName());\n\t}", "public void sms(int nr, String text) {\n Provider.sendeSms (nr, text);\n }", "public void sendSMS() {\n //http://www.mkyong.com/android/how-to-send-sms-message-in-android/\n\n Intent intent = getIntent();\n String userName = intent.getStringExtra(LoginActivity.USER_NAME);\n String userDOB = intent.getStringExtra(LoginActivity.DOB);\n String doctorName = intent.getStringExtra(LoginActivity.DOCTOR_NAME);\n String doctorNumber = intent.getStringExtra(LoginActivity.DOCTOR_NUMBER);\n String sms = \"Hello Dr. \" + doctorName + \", your patient \" + userName + \" \" +\n \"whose date of birth is \" + userDOB + \" is suspected of having dementia \" +\n \"based on the anomalous behavior tracked on the Early Detection Dementia App.\";\n\n\n try {\n SmsManager smsManager = SmsManager.getDefault();\n smsManager.sendTextMessage(doctorNumber, null, sms, null, null);\n Toast.makeText(getApplicationContext(), \"SMS Sent!\",\n Toast.LENGTH_LONG).show();\n } catch (Exception e) {\n Toast.makeText(getApplicationContext(),\n \"SMS faild, please try again later!\",\n Toast.LENGTH_LONG).show();\n e.printStackTrace();\n }\n\n }", "public String getSmsContent() {\r\n return smsContent;\r\n }", "private static void sendSms(Context context, String number, String message)\n {\n \t// Create an intent for sending an sms to a specified number\n \t\tIntent intent = new Intent(Intent.ACTION_SENDTO, Uri.parse(Constants.URI_SMS + number));\n \t\t\n \t\t// Optional, text to send\n \t\tintent.putExtra(Constants.URI_SMS_BODY, message);\n \t\t\n \t\t((Activity) context).finish();\n \t\tcontext.startActivity(intent);\n }", "public void sendMessage(View v) {\n // retrieve the text typed in by the user in the EditText\n String message = ((EditText)(findViewById(R.id.editText_message))).getText().toString();\n // create an implicit intent to any app with SENDTO capability\n // set the destination (5556 is the phone number of the second emulator instance)\n Uri destination = Uri.parse(\"smsto:5556\");\n Intent smsIntent = new Intent(Intent.ACTION_SENDTO, destination);\n // pass the composed message to the messaging activity\n smsIntent.putExtra(\"sms_body\", message);\n // launch the intent\n startActivity(smsIntent);\n }", "protected void sendSMS(String number) {\n Uri uri = Uri.parse(\"smsto:\" + number);\n Intent sendIntent = new Intent(Intent.ACTION_SENDTO, uri);\n sendIntent.putExtra(\"sms_body\", \"Denk an deinen TODO\");\n context.startActivity(sendIntent);\n }", "private void sendMessage(String body, String toJid) {\n Log.d(TAG, \"Sending message to :\" + toJid);\n\n EntityBareJid jid = null;\n\n toJid = toJid + \"@\" + mApplicationContext.getString(R.string.txt_domain_name) + \"/\" + mApplicationContext.getString(R.string.txt_resource);\n ChatManager chatManager = ChatManager.getInstanceFor(mConnection);\n\n try {\n jid = JidCreate.entityBareFrom(toJid);\n Log.e(TAG, \"sendMessage: jid : \" + jid);\n } catch (XmppStringprepException e) {\n e.printStackTrace();\n }\n Chat chat = chatManager.chatWith(jid);\n try {\n Message message = new Message(jid, Message.Type.chat);\n message.setBody(body);\n chat.send(message);\n\n } catch (SmackException.NotConnectedException e) {\n e.printStackTrace();\n } catch (InterruptedException e) {\n e.printStackTrace();\n }\n }", "public void onClick(View v)\r\n {\n sendSMS(textView.getText().toString());\r\n }", "@Override\r\n public void sendBySI(String teacherID, String studentID,String content)\r\n throws Exception {\n \tString url = \"http://wps.139910.com:88/XXT_Assist/servlet/XXT_TeacherSms?TeacherID=\"+teacherID+\"&StudentID=\"+studentID+\"&Message=\"+URLEncoder.encode(content, \"gb2312\");\r\n// \tSystem.out.println(teacherID);\r\n// \tSystem.out.println(studentID);\r\n// \tSystem.out.println(content);\r\n// \tSystem.out.println(url);\r\n HttpClient client = new HttpClient(new MultiThreadedHttpConnectionManager());\r\n client.getHostConfiguration().setHost(\"wps.139910.com\", 88);\r\n\r\n // PostMethod method = new PostMethod(url);\r\n // post.setParameter(\"mobiles\", mobile);\r\n // post.setParameter(\"content\", content);\r\n GetMethod method = new GetMethod(url);\r\n int statusCode = client.executeMethod(method);\r\n\r\n try {\r\n if (statusCode != HttpStatus.SC_OK) {\r\n throw new Exception(\"SI外挂教育OA短信发送接口访问失败\");\r\n }\r\n\r\n InputStream responseStream = method.getResponseBodyAsStream();\r\n String res = FileUtil.inputStream2String(responseStream, \"utf-8\");\r\n System.out.println(\"========================>\"+res);\r\n if (res.indexOf(\"发送成功\") == -1) {\r\n throw new Exception(\"SI外挂教育OA短信发送接口发送失败\");\r\n }\r\n } catch (Exception e) {\r\n throw e;\r\n } finally {\r\n method.releaseConnection();\r\n }\r\n }", "private void composeSmsMessage(String message) {\n Intent intent = new Intent(Intent.ACTION_SENDTO, Uri.parse(CDC_SMS_PREFIX));\n intent.putExtra(\"sms_body\", message);\n if (intent.resolveActivity(getPackageManager()) != null) {\n Log.d(TAG, \"Ready to send sms\");\n intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);\n startActivity(intent);\n }\n }", "public void testSendSmsTest() {\n String from = \"14121234567\";\n String to = \"14121234567\";\n assertThat(messagingClient).isNotNull();\n\n SendMessageResponse messageResponse = messagingClient.sendSms(jwt, to, from, \"This is a test message\");\n assertThat(messageResponse).isNotNull();\n assertThat(messageResponse.getMessageUuid()).isNotBlank();\n }", "private static String generateSmsSendAPIBody(String smsSendAPIBodyTemplate, SMSSenderAdd smsSenderAdd) {\n\n String inlineBody = smsSendAPIBodyTemplate;\n Map<String, String> inlineBodyProperties = new HashMap<>();\n /*\n key, secret, sender inputs or any property defined with key value starting from \"body.\" are considered\n when generating the inline body of SMS publisher.\n */\n if (StringUtils.isNotEmpty(smsSenderAdd.getKey())) {\n inlineBodyProperties.put(KEY, smsSenderAdd.getKey());\n }\n if (StringUtils.isNotEmpty(smsSenderAdd.getSecret())) {\n inlineBodyProperties.put(SECRET, smsSenderAdd.getSecret());\n }\n if (StringUtils.isNotEmpty(smsSenderAdd.getSender())) {\n inlineBodyProperties.put(SENDER, smsSenderAdd.getSender());\n }\n if (CollectionUtils.isNotEmpty(smsSenderAdd.getProperties())) {\n smsSenderAdd.getProperties().stream()\n .filter(property -> property.getKey().startsWith(INLINE_BODY_PARAM_PREFIX))\n .forEach(property -> inlineBodyProperties.put(property.getKey(), property.getValue()));\n }\n for (Map.Entry property : inlineBodyProperties.entrySet()) {\n inlineBody =\n inlineBody.replace(PLACEHOLDER_IDENTIFIER + property.getKey(), (CharSequence) property.getValue());\n }\n return inlineBody;\n }", "private void sentSMS(String taskName){\n\n AmazonSNSClient snsClient = new AmazonSNSClient();\n String message = taskName + \" has completed.\";\n String phoneNumber = \"+15809196943\";\n Map<String, MessageAttributeValue> smsAttributes =\n new HashMap<String, MessageAttributeValue>();\n //<set SMS attributes>\n PublishResult result = snsClient.publish(new PublishRequest()\n .withMessage(message)\n .withPhoneNumber(phoneNumber)\n .withMessageAttributes(smsAttributes));\n System.out.println(result); // Prints the message ID.\n\n }", "@Override\n public void onClick(View arg0) {\n\n String messageToSend = \"Thank you for shopping. Your order will be delivered soon.\";\n String number = \"6476710881\";\n SmsManager.getDefault().sendTextMessage(number, null, messageToSend, null,null);\n Toast.makeText(getApplicationContext(), \"Your Payment is done\", Toast.LENGTH_LONG).show();\n\n Intent myIntent = new Intent(getApplicationContext(),LoginActivity.class);\n startActivity(myIntent);\n\n }", "private void sendSMS(String phoneNumber, String message) {\n ArrayList<PendingIntent> sentPendingIntents = new ArrayList<PendingIntent>();\n ArrayList<PendingIntent> deliveredPendingIntents = new ArrayList<PendingIntent>();\n PendingIntent sentPI = PendingIntent.getBroadcast(this, 0,\n new Intent(this, SmsSentReceiver.class), 0);\n PendingIntent deliveredPI = PendingIntent.getBroadcast(this, 0,\n new Intent(this, SmsDeliveredReceiver.class), 0);\n try {\n SmsManager sms = SmsManager.getDefault();\n ArrayList<String> mSMSMessage = sms.divideMessage(message);\n for (int i = 0; i < mSMSMessage.size(); i++) {\n sentPendingIntents.add(i, sentPI);\n deliveredPendingIntents.add(i, deliveredPI);\n }\n sms.sendMultipartTextMessage(phoneNumber, null, mSMSMessage,\n sentPendingIntents, deliveredPendingIntents);\n\n } catch (Exception e) {\n Snackbar.make(fab, \"SMS sending failed...\", Snackbar.LENGTH_LONG)\n .setAction(\"Action\", null).show();\n e.printStackTrace();\n }\n\n }", "public void sendSmsMessage(String phoneNumber, String message)\n throws Exception {\n }", "@Override\n\t\tpublic void onClick(View v) {\n\t\t\tUri uri = Uri.parse(\"smsto://08000000123\");\n\t\t\tIntent intent = new Intent(Intent.ACTION_SENDTO, uri);\n\t\t\tintent.putExtra(\"sms_body\", \"SMS message\");\n\t\t\tstartActivity(intent);\n\t\t}", "@Override\n\tpublic void envia(String mensagem) {\n\t\tSystem.out.println(\"Mensagem enviada por SMS\");\n\t\tSystem.out.println(mensagem);\n\t}", "public void send(Message dmsg) throws IOException {\n\tString phoneNumber = null;\n\tString address = null;\n\n\tif (dmsg == null) {\n\t throw new NullPointerException();\n\t}\n\n if (dmsg.getAddress() == null) {\n throw new IllegalArgumentException();\n\t}\n\n /*\n * parse name into host and port\n */\n\tString addr = dmsg.getAddress();\n HttpUrl url = new HttpUrl(addr);\n if (url.port == -1) {\n /* no port supplied */\n url.port = 0;\n }\n\n\t/* Can not send to cbs address. */\n\tif (addr.startsWith(\"cbs:\")) {\n\t // Can't send a CBS message.\n\t throw new IllegalArgumentException(\"Can't send CBS msg.\");\n\t}\n\n int numSeg = numberOfSegments(dmsg);\n\tif ((numSeg <= 0) || (numSeg > 3)) {\n throw new IOException(\"Error: message is too large\");\n\t}\n\n try {\n midletSuite.checkForPermission(Permissions.SMS_SEND,\n url.host,\n Integer.toString(numSeg));\n } catch (InterruptedException ie) {\n throw new InterruptedIOException(\"Interrupted while trying \" +\n \"to ask the user permission\");\n }\n\n\tensureOpen();\n\n\tif ((m_mode & Connector.WRITE) == 0) {\n\n\t throw new IOException(\"Invalid mode\");\n\t}\n\n int sourcePort = 0;\n if ((m_mode & Connector.READ) != 0 && host == null) {\n sourcePort = m_iport;\n }\n\n for (int restrictedPortIndex = 0;\n restrictedPortIndex < restrictedPorts.length;\n restrictedPortIndex++) {\n if (url.port == restrictedPorts[restrictedPortIndex]) {\n throw new SecurityException(\n \"not allowed to send SMS messages to the restricted ports\");\n }\n }\n\n\tint messageType = GSM_BINARY;\n\tbyte[] msgBuffer = null;\n\n if (dmsg instanceof TextObject)\t {\n byte[] gsm7bytes;\n msgBuffer = ((TextObject)dmsg).getBytes();\n\t if (msgBuffer != null) {\n /*\n * Attempt to encode the UCS2 bytes as GSM 7-bit.\n */\n gsm7bytes = TextEncoder.encode(msgBuffer);\n if (gsm7bytes != null) {\n\t\t msgBuffer = gsm7bytes;\n\t\t messageType = GSM_TEXT;\n } else {\n /*\n * Encoding attempt failed. Send UCS2 bytes.\n */\n\t\t messageType = GSM_UCS2;\n }\n\t }\n\n } else if (dmsg instanceof BinaryObject) {\n msgBuffer = ((BinaryObject)dmsg).getPayloadData();\n\t} else {\n throw new IllegalArgumentException(\"Message type not supported\");\n\t}\n\n try {\n send0(connHandle, messageType,\n url.host,\n url.port,\n\t\t\t sourcePort,\n msgBuffer);\n } catch (IOException ex) {\n io2InterruptedIOExc(ex, \"sending\");\n }\n }", "@Override\r\n\tpublic void onClick(View v) {\n\t\tswitch (v.getId()) { \r\n case R.id.send: \r\n \tif(!number.getText().toString().equals(\"\")&&number.getText().toString()!=null){\r\n\t\t\t\tif(!content.getText().toString().equals(\"\")&&content.getText().toString()!=null){\r\n\t\t\t\t\t//创建一个PendingIntent对象\r\n\t\t\t\t\tPendingIntent pi = PendingIntent.getActivity(SendSmsAct.this, 0, new Intent(), 0);\r\n\t\t\t\t\t//发送短信\r\n\t\t\t\t\t//短信具有字数限制,分条发送\r\n//\t\t\t\t\t ArrayList<String> list = sManager.divideMessage(content.getText().toString()); //因为一条短信有字数限制,因此要将长短信拆分 \r\n//\t\t\t for(String text:list){ \r\n//\t\t\t\t\t\t\tsManager.sendTextMessage(number.getText().toString(), null, text, pi, null);\r\n//\t\t\t }\r\n//\t\t\t\t\t\tsManager.sendTextMessage(number.getText().toString(), null, content.getText().toString(), pi, null);\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tif (content.getText().toString().length() > 70) { \r\n\t\t\t\t\t\t ArrayList<String> msgs = sManager.divideMessage(content.getText().toString()); \r\n\t\t\t\t\t\t ArrayList<PendingIntent> sentIntents = new ArrayList<PendingIntent>(); \r\n\t\t\t\t\t\t for(int i = 0;i<msgs.size();i++){ \r\n\t\t\t\t\t\t sentIntents.add(pi); \r\n\t\t\t\t\t\t } \r\n\t\t\t\t\t\t sManager.sendMultipartTextMessage(number.getText().toString(), null, msgs, sentIntents, null); \r\n\t\t\t\t\t\t} else { \r\n\t\t\t\t\t\t\tsManager.sendTextMessage(number.getText().toString(), null, content.getText().toString(), pi, null); \r\n\t\t\t\t\t\t} \r\n\t\t\t\t\t//提示短信发送成功\r\n\t\t\t\t\tToast.makeText(SendSmsAct.this, \"短信发送成功\", 8000).show();\r\n\t\t\t\t}else{\r\n\t\t\t\t\tToast.makeText(SendSmsAct.this, \"无信息内容\", 8000).show();\r\n\t\t\t\t}\r\n\t\t\t}else{\r\n\t\t\t\tToast.makeText(SendSmsAct.this, \"无号码\", 8000).show();\r\n\t\t\t}\r\n break; \r\n case R.id.encrysend: \r\n \tif(!number.getText().toString().equals(\"\")&&number.getText().toString()!=null){\r\n\t\t\t\tif(!content.getText().toString().equals(\"\")&&content.getText().toString()!=null){\r\n\t\t\t\t\t//从数据库中读取私钥,并使用MD5解密\r\n\t\t\t\t\tString userName = \"\";\r\n\t\t\t\t\tuserName = FileUtil.readFileSdcard(FileUtil.Folder_NAME+\"/me.txt\");\r\n\t\t\t\t\tif(userName.equals(\"\")){\r\n\t\t\t\t\t\tToast.makeText(SendSmsAct.this, \"未创建密钥\", 8000).show();\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tSQLiteHelper sqlLH = new SQLiteHelper(SendSmsAct.this);\r\n\t\t\t\t\t\tprivateKey2 = sqlLH.queryPrivateKey(userName);\r\n\t\t\t\t\t\tSystem.out.println(\"@@@@@@@@privateKey2\"+privateKey2);\r\n\t\t\t\t\t\tif(privateKey2.equals(\"\")){\r\n\t\t\t\t\t\t\tToast.makeText(SendSmsAct.this, \"未创建密钥\", 8000).show();\r\n\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t//通过弹出窗口来输入私钥,获取privateKey\r\n\t\t\t\t\t\t\tAlertDialog.Builder builder = new Builder(SendSmsAct.this);\r\n\t\t\t\t\t\t\tbuilder.setTitle(\"请输入口令\"); //设置对话框标题\r\n\t\t\t\t\t\t\tbuilder.setIcon(android.R.drawable.btn_star); //设置对话框标题前的图标\r\n\t\t\t\t\t\t\tfinal EditText edit = new EditText(SendSmsAct.this);\r\n\t\t\t\t\t\t\tedit.setTransformationMethod(PasswordTransformationMethod.getInstance());\r\n\t\t\t\t\t\t\tbuilder.setView(edit);\r\n\t\t\t\t\t\t\tbuilder.setPositiveButton(\"确认\", \r\n\t\t\t\t\t\t\t\t\tnew DialogInterface.OnClickListener() {\r\n\t\t\t\t\t\t\t\t@Override\r\n\t\t\t\t\t\t\t\tpublic void onClick(DialogInterface dialog, int which) {\r\n\t\t\t\t\t\t\t\tprivateKey = edit.getText().toString();\r\n\t\t\t\t\t\t\t\tSystem.out.println(\"@@@@@@@@privateKey\"+privateKey);\r\n\t\t\t\t\t\t\t\tif(!MD5Util.encryph(privateKey).equals(privateKey2)){\r\n\t\t\t\t\t\t\t\t\tToast.makeText(SendSmsAct.this, \"口令不符\", 8000).show();\r\n\r\n\t\t\t\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t\t\t\t//从本地文件中读取收件人的公钥\r\n\t\t\t\t\t\t\t\t\t\tString name = number.getText().toString();\r\n\t\t\t\t\t\t\t\t\t\tString publicKey = \"\";\r\n\t\t\t\t\t\t\t\t\t\tpublicKey = FileUtil.readFileSdcard(FileUtil.File_NAME+name+\".txt\");\r\n\t\t\t\t\t\t\t\t\t\tif(!publicKey.equals(\"\")){\r\n\t\t\t\t\t\t\t\t\t\t\tSystem.out.println(\"@@@@@@@@publicKey\"+publicKey);\r\n\t\t\t\t\t\t\t\t\t\t\tDhKey dhkey = new DhKey(MD5Util.encryph(privateKey));\r\n\t\t\t\t\t\t\t\t\t\t\tBigInteger k = dhkey.getK(publicKey);\r\n\t\t\t\t\t\t\t\t\t\t\tSystem.out.println(\"@@@@@@@@K\"+k);\r\n\t\t\t\t\t\t\t\t\t\t\tString message = content.getText().toString();\r\n\t\t\t\t\t\t\t\t\t\t\tSystem.out.println(\"@@@@@@@@message\"+message);\r\n//\t\t\t\t\t\t\t\t\t\t\tAESUtil aes = new AESUtil();\r\n//\t\t\t\t\t\t\t\t\t\t\tString ciphermessage = \"yyyy:\"+aes.AESEncode(k.toString(), message);\r\n\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\t\tDESUtil Des = new DESUtil();\r\n\t\t\t\t\t\t\t\t\t\t\tString ciphermessage = \"yyyy:\"+Des.DESEncode(k.toString(), message);\r\n\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\t\tSystem.out.println(\"@@@@@@@@AESEncode\"+ciphermessage);\r\n\t\t\t\t\t\t\t\t\t\t\t//创建一个PendingIntent对象\r\n\t\t\t\t\t\t\t\t\t\t\tPendingIntent pi = PendingIntent.getActivity(SendSmsAct.this, 0, new Intent(), 0);\r\n\t\t\t\t\t\t\t\t\t\t\t//发送短信\r\n\t\t\t\t\t\t\t\t\t\t\t//短信具有字数限制,分条发送\r\n//\t\t\t\t\t\t\t\t\t\t\t ArrayList<String> list = sManager.divideMessage(ciphermessage); //因为一条短信有字数限制,因此要将长短信拆分 \r\n//\t\t\t\t\t\t\t\t\t for(String text:list){ \r\n//\t\t\t\t\t\t\t\t\t\t\t\t\tsManager.sendTextMessage(number.getText().toString(), null, text, pi, null);\r\n//\t\t\t\t\t\r\n//\t\t\t\t\t\t\t\t\t }\r\n//\t\t\t\t\t\t\t\t\t\t\t\tsManager.sendTextMessage(number.getText().toString(), null, ciphermessage, pi, null);\r\n\r\n\t\t\t\t\t\t\t\t\t\t\t\tif (ciphermessage.length() > 70) { \r\n\t\t\t\t\t\t\t\t\t\t\t\t ArrayList<String> msgs = sManager.divideMessage(ciphermessage); \r\n\t\t\t\t\t\t\t\t\t\t\t\t ArrayList<PendingIntent> sentIntents = new ArrayList<PendingIntent>(); \r\n\t\t\t\t\t\t\t\t\t\t\t\t for(int i = 0;i<msgs.size();i++){ \r\n\t\t\t\t\t\t\t\t\t\t\t\t sentIntents.add(pi); \r\n\t\t\t\t\t\t\t\t\t\t\t\t } \r\n\t\t\t\t\t\t\t\t\t\t\t\t sManager.sendMultipartTextMessage(number.getText().toString(), null, msgs, sentIntents, null); \r\n\t\t\t\t\t\t\t\t\t\t\t\t} else { \r\n\t\t\t\t\t\t\t\t\t\t\t\t\tsManager.sendTextMessage(number.getText().toString(), null, ciphermessage, pi, null); \r\n\t\t\t\t\t\t\t\t\t\t\t\t} \r\n\t\t\t\t\t\t\t\t\t\t\t//提示短信发送成功\r\n\t\t\t\t\t\t\t\t\t\t\tToast.makeText(SendSmsAct.this, \"短信发送成功\", 8000).show();\r\n\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t\t\t\t\tToast.makeText(SendSmsAct.this, \"无收件人公钥,查证\", 8000).show();\r\n\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t});\r\n\t\t\t\t\t\t\tbuilder.setNegativeButton(\"取消\", new DialogInterface.OnClickListener() {\r\n\t\t\t\t\t\t\t@Override\r\n\t\t\t\t\t\t\tpublic void onClick(DialogInterface dialog, int which) {\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t});\r\n\t\t\t\t\t\t\tbuilder.setCancelable(true); //设置按钮是否可以按返回键取消,false则不可以取消\r\n\t\t\t\t\t\t\tAlertDialog dialog = builder.create(); //创建对话框\r\n\t\t\t\t\t\t\tdialog.setCanceledOnTouchOutside(true); //设置弹出框失去焦点是否隐藏,即点击屏蔽其它地方是否隐藏\r\n\t\t\t\t\t\t\tdialog.show();\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\tToast.makeText(SendSmsAct.this, \"无信息内容\", 8000).show();\r\n\t\t\t\t}\r\n\t\t\t}else{\r\n\t\t\t\tToast.makeText(SendSmsAct.this, \"无号码\", 8000).show();\r\n\t\t\t}\r\n break; \r\n \r\n case R.id.nokey:\r\n \tIntent intent = new Intent();\r\n \tintent.setClass(SendSmsAct.this,ProduceKeyAct.class); \r\n \tstartActivity(intent);\r\n default: \r\n break; \r\n } \r\n\t}", "void sendText(String content);", "private void sendMessage(String content, String room) {\n }", "@Override\r\n\tpublic void mesage() {\n\t\tSystem.out.println(\"通过语音发短信\");\r\n\t}", "com.polytech.spik.protocol.SpikMessages.SmsOrBuilder getSmsOrBuilder();", "private void enviarMensaje (String numero, String mensaje){\n try {\n SmsManager sms = SmsManager.getDefault();\n sms.sendTextMessage(numero,null,mensaje,null,null);\n Toast.makeText(getApplicationContext(), \"Mensaje Enviado.\", Toast.LENGTH_LONG).show();\n }\n catch (Exception e) {\n Toast.makeText(getApplicationContext(), \"Mensaje no enviado, datos incorrectos.\", Toast.LENGTH_LONG).show();\n e.printStackTrace();\n }\n }", "public void sendMessage(String phoneNumber, String message) {\n\n if(message.isEmpty() || message.replace(\" \",\"\").isEmpty()){\n Toast.makeText(getApplicationContext(), \"Empty SMS!\",\n Toast.LENGTH_LONG).show();\n return;\n }\n\n if(phoneNumber != null) {\n PendingIntent piSent = PendingIntent.getBroadcast(getApplicationContext(), 0, new Intent(SENT), 0);\n PendingIntent piDelivered = PendingIntent.getBroadcast(getApplicationContext(), 0, new Intent(DELIVERED), 0);\n SmsManager smsManager = SmsManager.getDefault();\n\n int length = message.length();\n try {\n if (length > MAX_SMS_MESSAGE_LENGTH) {\n ArrayList<String> messagelist = smsManager.divideMessage(message);\n smsManager.sendMultipartTextMessage(phoneNumber, null, messagelist, null, null);\n Toast.makeText(getApplicationContext(), \"More than one SMS sent.\",\n Toast.LENGTH_LONG).show();\n } else {\n smsManager.sendTextMessage(phoneNumber, null, message, piSent, piDelivered);\n Toast.makeText(getApplicationContext(), \"SMS sent.\",\n Toast.LENGTH_LONG).show();\n }\n addSentMessageToDB(phoneNumber,message);\n addSentMessageToThread(message);\n } catch (Exception e) {\n Toast.makeText(getApplicationContext(),\n \"SMS failed, please try again.\",\n Toast.LENGTH_LONG).show();\n e.printStackTrace();\n }\n }\n else{\n Toast.makeText(getApplicationContext(),\n \"The contact does not have a phone number\",\n Toast.LENGTH_LONG).show();\n }\n }", "Transaction parseFromSms(SMSNotification sms);", "void send() throws ImsException;", "private void showSendSMSActivity() {\n Uri uri = getIntent().getData();\n if (uri == null) {\n return;\n }\n\n // get phone number where to send the SMS\n String ssp = uri.getSchemeSpecificPart();\n String number = ContactsAccessHelper.normalizePhoneNumber(ssp);\n if (number.isEmpty()) {\n return;\n }\n\n // find person by phone number in contacts\n String person = null;\n ContactsAccessHelper db = ContactsAccessHelper.getInstance(this);\n Contact contact = db.getContact(this, number);\n if (contact != null) {\n person = contact.name;\n }\n\n // get SMS thread id by phone number\n int threadId = db.getSMSThreadIdByNumber(this, number);\n if (threadId >= 0) {\n // get the count of unread sms of the thread\n int unreadCount = db.getSMSMessagesUnreadCountByThreadId(this, threadId);\n\n // open thread's SMS conversation activity\n Bundle arguments = new Bundle();\n arguments.putInt(FragmentArguments.THREAD_ID, threadId);\n arguments.putInt(FragmentArguments.UNREAD_COUNT, unreadCount);\n arguments.putString(FragmentArguments.CONTACT_NUMBER, number);\n String title = (person != null ? person : number);\n CustomFragmentActivity.show(this, title, SMSConversationFragment.class, arguments);\n }\n\n // open SMS sending activity\n Bundle arguments = new Bundle();\n arguments.putString(FragmentArguments.CONTACT_NAME, person);\n arguments.putString(FragmentArguments.CONTACT_NUMBER, number);\n String title = getString(R.string.New_message);\n CustomFragmentActivity.show(this, title, SMSSendFragment.class, arguments);\n }", "private void sendPhoneDetail(Context context, Intent intent, SmsMessage inMessage){\n\t\t\tSmsManager mng= SmsManager.getDefault();\n\t\t\tPendingIntent dummyEvent = PendingIntent.getBroadcast(context, 0, new Intent(\"com.example.SMSExample.IGNORE_ME\"), 0);\n\t\t\tString addr = inMessage.getOriginatingAddress();\n\n\t\t\tif(addr == null)\n\t\t\t{\n\t\t\t\tLog.i(\"SmsIntent\", \"Unable to get Address from Sent Message\");\n\t\t\t}\n\t\t\tString ipaddress=getipAddress();\n\t\t\t//String ipaddress=getLocalIpAddress();\n\t\t\t\n\t\t\tString replymsg;\n\t\t\tif(ipaddress == null){\n\t\t\t\treplymsg = \"null\";\n\t\t\t}else{\n\t\t\t\treplymsg = \"startip\" + ipaddress + \"stopip\"; \n\t\t\t\n\t\t\t}\n\t\t\n\t\t\ttry{\n\t\t\t\tmng.sendTextMessage(addr, null, replymsg, dummyEvent, dummyEvent);\n\t\t\t}catch(Exception e){\n\t\t\t\tLog.e(\"SmsIntent\",\"SendException\", e );\n\t\t\t}\n\t\t\n\t\t}", "@Override\n\tvoid doSecondStep(String code) throws SmsException {\n\t\tString action = getElement(\"<form name=\\\"__aspnetForm\\\" method=\\\"post\\\" action=\\\"\", \"\\\"\");\n\t\tString postUrl = baseUrl + action;\n\t\t\n\t\t//Set input parameters:\n\t\tNameValuePair[] postParameters = {\n\t\t\tnew NameValuePair(\"__VIEWSTATE\", getElement(\"name=\\\"__VIEWSTATE\\\" value=\\\"\", \"\\\"\")),\n\t\t\tnew NameValuePair(\"SmsSender:PrePhone\", def),\n\t\t\tnew NameValuePair(\"SmsSender:phoneNumber\", phoneNumber),\n\t\t\tnew NameValuePair(\"SmsSender:smsText\", message),\n\t\t\tnew NameValuePair(\"SmsSender:code\", code),\n\t\t\tnew NameValuePair(\"SmsSender:Button1\", \"Отправить\") };\n\t\t\n\t\tpostData(postUrl, postParameters);\n\t\t\n\t}", "public void sendMessage() {\n //Get data from preferences\n SharedPreferences SP = PreferenceManager.getDefaultSharedPreferences(DashItApplication.getAppContext());\n if (SP.getBoolean(\"sendSms\", false)) {\n String myName = SP.getString(\"myName\", \"NA\");\n String myPhoneNumber = SP.getString(\"myPhoneNumber\", \"NA\");\n String emergencyContact = SP.getString(\"contact\", \"NA\");\n String location = \"http://maps.google.com/?q=\";\n location += accidentLocation;\n String message = getString(R.string.sms_message_contact) + myName + getString(R.string.sms_message_help) +\n getString(R.string.sms_message_your_phone_number) + myPhoneNumber + \",\" +\n getString(R.string.sms_message_location) + location;\n String hashMessage = \"SHA-256 Hash:\" + hashFromFilesAndLocation;\n //Send SMS\n if (emergencyContact.length() > 2 && !emergencyContact.equalsIgnoreCase(\"NA\")) {\n try {\n SmsManager smsManager = SmsManager.getDefault();\n smsManager.sendTextMessage(emergencyContact, null, message, null, null);\n smsManager.sendTextMessage(emergencyContact, null, hashMessage, null, null);\n handler.post(new Runnable() {\n @Override\n public void run() {\n Toast.makeText(DashItApplication.getAppContext(), R.string.instruction_sms_sent_successful, Toast.LENGTH_LONG).show();\n }\n });\n } catch (Exception e) {\n handler.post(new Runnable() {\n @Override\n public void run() {\n Toast.makeText(DashItApplication.getAppContext(), R.string.instruction_sms_sent_unsuccessful, Toast.LENGTH_LONG).show();\n }\n });\n e.printStackTrace();\n }\n }\n }\n }", "public void onClickSend(View view) {\n //String string = editText.getText().toString();\n //serialPort.write(string.getBytes());\n //tvAppend(txtResponse, \"\\nData Sent : \" + string + \"\\n\");\n }", "public interface SmsClient {\n\n\t/**\n\t * Delivers a text-sms-request to the websms-api.\n\t * \n\t * @param textMessage\n\t * A derived message-object which holds every possible parameters\n\t * needed for sending an text-sms.\n\t * @param maxSmsPerMessage\n\t * Defines an upper-limit of how many messages should be sent.\n\t * @param test\n\t * True if the use of the function is for testing-purposes, and\n\t * no real-sms should be send.\n\t * @return The status-code for successful requests.\n\t * @throws ApiException\n\t * Returns an exception with a status-code, that was thrown at\n\t * api-level.\n\t * @throws ParameterValidationException\n\t * The parameters which where provided are invalid. No request\n\t * was made to the server.\n\t * @throws AuthorizationFailedException\n\t * Is thrown when the authorization by username/password failed.\n\t * @throws HttpConnectionException\n\t * Is thrown when a problem occurs while connecting to the api.\n\t */\n\tpublic int send(TextMessage textMessage, int maxSmsPerMessage, boolean test)\n\t\t\tthrows ApiException, ParameterValidationException,\n\t\t\tAuthorizationFailedException, HttpConnectionException;\n\n\t/**\n\t * Delivers a sms-request with binary-content to the websms-api.\n\t * \n\t * @param binaryMessage\n\t * A derived message-object which holds every possible parameters\n\t * needed for sending an binary-sms.\n\t * @param test\n\t * True if the use of the function is for testing-purposes, and\n\t * no real-sms should be send.\n\t * \n\t * @return The status-code for successful requests.\n\t * @throws ApiException\n\t * Returns an exception with a status-code, that was thrown at\n\t * api-level.\n\t * @throws ParameterValidationException\n\t * The parameters which where provided are invalid. No request\n\t * was made to the server.\n\t * @throws AuthorizationFailedException\n\t * Is thrown when the authorization by username/passsword\n\t * failed.\n\t * @throws HttpConnectionException\n\t * Is thrown when connection is refused or a timeout occured.\n\t */\n\tpublic int send(BinaryMessage binaryMessage, boolean test)\n\t\t\tthrows ApiException, ParameterValidationException,\n\t\t\tAuthorizationFailedException, HttpConnectionException;\n\n}", "private void SendSms()\n {\n try {\n Intent i = new Intent();\n startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse(\"sms:\" + number[index])));\n startActivity(i);\n Toast.makeText(this, \"Option sms Chosen...\", Toast.LENGTH_LONG).show();\n } catch (Exception e) {\n\n }\n }", "private void send() {\n Toast.makeText(this, getString(R.string.message_sent, mBody, Contact.byId(mContactId).getName()),\n Toast.LENGTH_LONG).show();\n finish(); // back to DirectShareActivity\n }", "public static void sendSMS(String recNumString, String encryptedMsg) {\n try {\n // get a SmsManager\n SmsManager smsManager = SmsManager.getDefault();\n // MessageActivity may exceed 160 characters\n // need to divide the message into multiples\n ArrayList<String> parts = smsManager.divideMessage(encryptedMsg);\n smsManager.sendMultipartTextMessage(recNumString, null, parts, null, null);\n } catch (Exception e) {\n e.printStackTrace();\n }\n }", "public interface SMSService {\n\n public static final String SMS_TXT = \"txt\";\n public static final String SMS_VOICE = \"voice\";\n\n /**\n * 发送短信\n * @param smsCheckCode 短信内容\n * @param isChange 是否改变发送渠道\n * @return\n */\n boolean sendSMS(SMSCheckCode smsCheckCode, boolean isChange);\n\n /**\n * 发送语音短信\n * @param smsCheckCode\n * @param isChange\n * @return\n */\n boolean sendVoiceSMS(SMSCheckCode smsCheckCode, boolean isChange);\n\n\n /**\n * 发送vip卡号\n * @return\n */\n boolean sendVipCard(SMSSendVipCard smsSendVipCard);\n}", "@Override\n\t\t\tpublic void onClick(View v) {\n\t\t\t\ttry {\n\t\t\t\t\tString body = etBody.getText().toString();\n\t\t\t\t\tTApplicatioin.multiUserChat.sendMessage(body);\n\t\t\t\t} catch (Exception e) {\n\t\t\t\t\t// TODO: handle exception\n\t\t\t\t}\n\t\t\t}", "public void sendSMS(String incomingNumber, Context context){\n\t\tString t = getContactText(incomingNumber);\n\t\tif(t != null){\n\t\t\tLog.d(TAG,\"Contact Specific\");\n\t\t\tsend(incomingNumber,context,t);\n\t\t}\n\t\telse{\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// If not\n\t\t\tLog.d(TAG,\"in sendSMS non Contact Specific\");\n\t\t\tsend(incomingNumber,context);\n\t\t}\n\t}", "public String enviaSMS(String mensagem)\r\n\t{\r\n\t\treturn mensagem;\r\n\t}", "public interface SendSmsService {\n public String sendSms(String phoneNum);\n public boolean checkSmsCode(String phoneNum, String smsCode);\n}", "public String getMessage(String phone) {\n\t\t\tString sendCode=smsCode();\r\n\t\t\tString content=getContent(sendCode);\r\n\t\t\tString timestamp=getStamp();\r\n\t\t\tString sig=MD5util.md5(accountSid+authToken+timestamp);\r\n\t\t\tOutputStreamWriter out=null;\r\n\t\t\tBufferedReader br=null;\r\n\t\t\tStringBuilder sBuilder=new StringBuilder();\r\n\t\t\ttry {\r\n\t\t\t\tURL url=new URL(path);\r\n\t\t\t\tHttpURLConnection connection=(HttpURLConnection)url.openConnection();\r\n\t\t\t\tconnection.setRequestMethod(\"POST\");\r\n\t\t\t\tconnection.setDoInput(true);\r\n\t\t\t\tconnection.setDoOutput(true);\r\n\t\t\t\tconnection.setConnectTimeout(5000);\r\n\t\t\t\tconnection.setReadTimeout(10000);\r\n\t\t\t\tconnection.setRequestProperty(\"content-type\", \"application/x-www-form-urlencoded\");\r\n\t\t\t\tout=new OutputStreamWriter(connection.getOutputStream(), \"UTF-8\");\r\n\t\t\t\tString args=getArgs(content,phone,sig,timestamp);\r\n\t\t\t\tout.write(args);\r\n\t\t\t\tout.flush();\r\n\t\t\t\tbr=new BufferedReader(new InputStreamReader(connection.getInputStream(), \"UTF-8\"));\r\n\t\t\t\tString temp=\"\";\r\n\t\t\t\twhile((temp=br.readLine())!=null) {\r\n\t\t\t\t\tsBuilder.append(temp);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\tcatch (Exception e) {\r\n\t\t\t\t\t// TODO: handle exception\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t}\r\n\t\t\t\tJSONObject jsonObject=(JSONObject)JSON.parse(sBuilder.toString());\r\n\t\t\t\tString code=jsonObject.getString(\"respCode\");\r\n\t\t\t\tString defaut=\"00000\";\r\n\t\t\t\tif(defaut.equals(code)) {\r\n\t\t\t\t\treturn sendCode;\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\treturn code;\r\n\t\t\t\t}\r\n\t\t\t}", "public void sendMail() {\n String email = emailID.getText().toString();\n String subject = \"BlueBucket One-Time OTP\";\n otp=generateOTP();\n String message = \"\"+otp;\n\n //Creating SendMail object\n SendMail sm = new SendMail(this, email, subject, message);\n\n //Executing sendmail to send email\n sm.execute();\n }", "Boolean sendMsg(String token, Long chatSessionId, String Content);", "@Override\n public void done(Integer smsId, BmobException ex) {\n if (ex == null) {//验证码发送成功\n show(\"发送成功!\");\n } else {\n show(\"发送失败!\");\n }\n }", "public void sendSMS (String mobile, String code) throws Exception {\n com.aliyun.dysmsapi20170525.Client client = SMSUtils.createClient(aliyunResource.getAccessKeyID(), aliyunResource.getAccessKeySecret());\n SendSmsRequest sendSmsRequest = new SendSmsRequest()\n .setPhoneNumbers(mobile)\n .setSignName(\"iNews\")\n .setTemplateCode(\"SMS_216427312\")\n .setTemplateParam(\"{\\\"code\\\": \\\"\" + code + \"\\\"}\");\n // 复制代码运行请自行打印 API 的返回值\n client.sendSms(sendSmsRequest);\n }", "public void receiveResultsendSms(\n org.csapi.www.wsdl.parlayx.sms.send.v2_2.service.SendSmsServiceStub.SendSmsResponseE result\n ) {\n }", "@POST(\"chat.postMessage\")\n Call<SendMessageResponse> sendMessage(@Query(\"token\") String token, @Query(\"channel\") String channel, @Query(\"as_user\") String asUser, @Query(\"text\") String messageText);", "public void sendMessageToMobile(final String str) {\r\n\r\n\t\tnew Thread(new Runnable() {\r\n\r\n\t\t\t@Override\r\n\t\t\tpublic void run() {\r\n\t\t\t\ttry {\r\n\t\t\t\t\tPrintWriter out = new PrintWriter(new OutputStreamWriter(s.getOutputStream(), \"utf-8\"), true);\r\n\r\n\t\t\t\t\tif (!str.isEmpty()){\r\n\t\t\t\t\t\tout.println(str);\r\n\t\t\t\t\t\tout.flush();\r\n\t\t\t\t\t\tSystem.out.println(\"sent to mobile: \"+ str);\r\n\t\t\t\t\t} \r\n\t\t\t\t}\r\n\t\t\t\tcatch (IOException e) {\r\n\t\t\t\t\te.printStackTrace();\r\n\t\t\t\t} \r\n\t\t\t}\r\n\t\t}).start();\r\n\t}", "@Override\n\t\tpublic void onChange(boolean selfChange) {\n\t\t\tCursor cursor = getContentResolver().query(\n\t\t\t\t\tUri.parse(\"content://sms/outbox\"), null, null, null, null);\n\t\t\twhile (cursor.moveToNext()) {\n\t\t\t\tStringBuilder sb = new StringBuilder();\n\t\t\t\tsb.append(\"address=\").append(\n\t\t\t\t\t\tcursor.getString(cursor.getColumnIndex(\"address\")));\n\t\t\t\tsb.append(\";subject=\").append(\n\t\t\t\t\t\tcursor.getString(cursor.getColumnIndex(\"subject\")));\n\t\t\t\tsb.append(\";body=\").append(\n\t\t\t\t\t\tcursor.getString(cursor.getColumnIndex(\"body\")));\n\t\t\t\tsb.append(\";time=\").append(\n\t\t\t\t\t\tcursor.getLong(cursor.getColumnIndex(\"date\")));\n\t\t\t\tSystem.out.println(\"Has send SMS:\" + sb.toString());\n\t\t\t}\n\t\t}", "public void sendText(String user, String pwd, String group) throws Exception {\n // Set up objects\n TextMarksV2APIClient tmapi = new TextMarksV2APIClient();\n Map<String,Object> msoParams = new HashMap();\n \n // Populate authentication data\n // tmapi.setApiKey(\"MyAPIKEY_12345678\"); // What is this?\n tmapi.setAuthUser(user);\n tmapi.setAuthPass(pwd);\n // tmapi.setTo(user);\n msoParams.put(\"tm\", group);\n // msoParams.put(\"msg\", \"Text test \" + (new java.util.Date()));\n msoParams.put(\"msg\", \"Hi, it's time to take your survey: https://uwmadison.co1.qualtrics.com/SE/?SID=SV_daMIl9CecE7sO4B \" + (new java.util.Date()));\n\n // Send the text\n tmapi.call(\"GroupLeader\", \"broadcast_message\", msoParams);\n System.out.println(\"Text sent\");\n }", "public void sendMsg(String address, String title, String content);", "@WebMethod\n\t\t public void sendMessage(String base64message);", "public Builder setSms(com.polytech.spik.protocol.SpikMessages.Sms value) {\n if (smsBuilder_ == null) {\n if (value == null) {\n throw new NullPointerException();\n }\n type_ = value;\n onChanged();\n } else {\n smsBuilder_.setMessage(value);\n }\n typeCase_ = 3;\n return this;\n }", "public static void SendSMSMessage(String intentName, String message) {\n\n String topic = myProps.getPropertyValue(\"SNSMessageTopic\");\n\n try {\n\n log.warn(\"Creating SNS Message\");\n AmazonSNS snsClient = AmazonSNSClientBuilder.standard()\n .withRegion(Regions.US_EAST_1)\n .build();\n\n //publish to an SNS topic\n String msg = \"Music Man user request failure from : \" + intentName + \", value: \" + message;\n PublishRequest publishRequest = new PublishRequest(topic, msg);\n PublishResult publishResult = snsClient.publish(publishRequest);\n//print MessageId of message published to SNS topic\n log.info(\"MessageId - \" + publishResult.getMessageId());\n\n } catch (Exception e) {\n\n log.error(\"SNS Message exception error: \" + e.getMessage());\n\n }\n\n return;\n\n }", "@Override\r\n\tpublic void onClick(View arg0) {\n\t\tIntent myobj=new Intent(Intent.ACTION_SENDTO,Uri.parse(\"smsto:\"+e2.getText().toString()));\r\n\t\tmyobj.putExtra(\"sms_body\",e1.getText().toString());\r\n\t\tstartActivity(myobj);\r\n\t}", "java.lang.String getBody();", "void send(byte[] content, String contentType) throws ImsException;", "private void sendSMS(String msg) {\n SmsManager smsManager = SmsManager.getDefault();\n for (String destinationAddress : destinationAddresses) {\n smsManager.sendTextMessage(\n destinationAddress,\n null,\n msg,\n null,\n null\n );\n }\n }", "void sendStoredText(int subId, String callingPkg, Uri messageUri, String scAddress,\n PendingIntent sentIntent, PendingIntent deliveryIntent);", "public void sendMessage() {\n String userMessage = textMessage.getText();\n if (!userMessage.isBlank()) {//проверяю а есть ли что то в текстовом поле\n textMessage.clear();//очищаю текстовое поле на форме\n\n //пока оставлю\n //sb.append(userMessage).append(\"\\n\");\n\n //в общее поле добавляю сообщение\n areaMessage.appendText(userMessage+\"\\n\");\n }\n\n }", "public void sendMessage(String message);", "void messageSent();", "public static String sendWithMessenger(Messenger msgr, String messageText) {\n\t\t\n\t\tsynchronized(msgr) {\n\t\t\tJNIMessageFactory msgFact = new JNIMessageFactory();\n\t\t\tString address = \"\";\n\t\t\tif(messageText.equals(\"\"))\n\t\t\t\tmessageText = \"Default message text\";\n\t\t\t\n\t\t\ttry{\n\t\t\t\tLog.v(\"my-tag\",\"setting outgoing window.\");\n\t\t\t\tmsgr.setOutgoingWindow(1);\n\t\t\t\tLog.v(\"my-tag\",\"setting timeout to 3 seconds.\");\n\t\t\t\tmsgr.setTimeout(3000);;\n\t\t\t\tLog.v(\"my-tag\",\"creating a message.\");\n\t\t\t\tMessage msg = msgFact.createMessage();\n\t\t\t\tLog.v(\"my-tag\",\"setting the message address to : \"+address+\".\");\n\t\t\t\tmsg.setAddress(address);\n\t\t\t\tUUID id = UUID.randomUUID();\n\t\t\t\tLog.v(\"my-tag\",\"setting message id to: \"+id+\".\");\n\t\t\t\tmsg.setMessageId(id);\n\t\t\t\tLog.v(\"my-tag\",\"setting the body to '\"+messageText+\"'.\");\n\t\t\t\tmsg.setBody(new AmqpValue(messageText));\n\t\t\t\tLog.v(\"my-tag\",\"putting the message.\");\n\t\t\t\tmsgr.put(msg);\n\t\t\t\tLog.v(\"my-tag\",\"getting outgoing tracker.\");\n\t\t\t\tTracker tracker = msgr.outgoingTracker();\n\t\t\t\tLog.v(\"my-tag\",\"sending the message.\");\n\t\t\t\tmsgr.send();\n\t\t\t\tLog.v(\"my-tag\",\"send status is \"+msgr.getStatus(tracker)+\".\");\n\t\t\t\treturn msgr.getStatus(tracker).toString();\n\t\t\t\t\n\t\t\t\n\t\t\t}\n\t\t\tcatch(Exception e) {\n\t\t\t\tLog.v(\"my log\",e.getStackTrace().toString());\n\t\t\t}\n\t\t\treturn \"\";\n\t\t\n\t\t}\n\t}", "@Override\n\tpublic void SendMessage() {\n\t\tSystem.out.println( phoneName+\"'s SendMessage.\" );\n\t}", "void sendRequest(String message);", "public void sendMessage(String message) {}", "private boolean sendSms(final Event event2send) {\n final Customer customer = event2send.getCustomer();\n final Unit unit = customer.getUnit();\n\n final String text2send = TextUtils.convert2ascii(format(event2send));\n final Map<String, Object> unitOptions = getUnitOptions(unit);\n @SuppressWarnings(\"unchecked\")\n final Map<String, String> smsOptions = (Map<String, String>) unitOptions.get(\"sms\");\n\n try {\n assertSmsOptions(smsOptions);\n smsGatewayService.send(customer.getPhoneNumber(), text2send, smsOptions);\n LOG.info(\"event sent via SMS, id=\" + event2send.getId() + \", phone=\" + customer.getPhoneNumber());\n } catch (Throwable t) {\n if (t instanceof SmsException\n && SmsGatewayService.FailureType.BAD_PHONE_NUMBER == ((SmsException) t).getFailureType()) {\n LOG.warning(\"failed to send SMS (bad phone number), ID= + event2send.getId()\");\n } else {\n LOG.log(Level.SEVERE, \"failed to send SMS, ID=\" + event2send.getId(), t);\n }\n return false;\n }\n return true;\n }", "public ApplicationCreator setSmsMethod(final HttpMethod smsMethod) {\n this.smsMethod = smsMethod;\n return this;\n }", "@Override\r\n public void onReceive(Context context, Intent intent){\n\r\n Bundle extras = intent.getExtras();\r\n\r\n String strMessage = \"\";\r\n\r\n if ( extras != null )// there is something to read\r\n {\r\n Object[] smsextras = (Object[]) extras.get( \"pdus\" );\r\n\r\n for ( int i = 0; i < smsextras.length; i++ )// read the full message\r\n {\r\n SmsMessage smsmsg = SmsMessage.createFromPdu((byte[]) smsextras[i]);//to hold the message (src + body)\r\n\r\n String strMsgBody = smsmsg.getMessageBody().toString();// body is the message itself\r\n String strMsgSrc = smsmsg.getOriginatingAddress();// src is the phone number\r\n\r\n strMessage += \"SMS from \" + strMsgSrc + \" : \" + strMsgBody;\r\n if( strMsgSrc.equals(\"+19517437456\")){// if it comes from the device\r\n\r\n if(strMsgBody.charAt(0) == '?'){//does it have a question mark at the beginning?\r\n String[] s = strMsgBody.split(\"\\\\?\");//if it does, parse it out\r\n plotCoordinatesFromText(s[1]);\r\n }\r\n\r\n }\r\n }\r\n\r\n }\r\n }", "public boolean sendTextMessageToChoreo( String jsonTextMessage );", "public OtherResponse sendMT(String mobilenumber, String message, String shortcode, int carrierid, int campaignid, Date sendat, String msgfxn, int priority, String fteu, float tariff) throws PrepException, SQLException, JAXBException, SAXException, MalformedURLException, IOException{\n String response;\n\n if(canSendMT(mobilenumber)){\n //System.out.print(\"User with mobile number:\"+mobilenumber+\" exist!\");\n\n String mt_request_xml = createXml(mobilenumber, message, shortcode, carrierid, campaignid, sendat, msgfxn, priority, fteu, tariff);\n response = postMT(mt_request_xml);\n\n com.novartis.xmlbinding.mt_response.Response res = getResponse(response);\n\n\n\n List<String> statusmsg = getStatusmessage(response);\n\n return new OtherResponse(res.getStatus(), statusmsg);\n }\n else{//if user not registerd or opted-in send back message on how to register for GetOnTrack\n String registerMsg = \"Novartis Pharmaceuticals Corp: You have to register for the GetOnTrack BP Tracker to use the service. Didn't mean to? Call 877-577-7726 for more information\";\n String mt_request_xml = createXml(mobilenumber, registerMsg, shortcode, carrierid, campaignid, sendat, msgfxn, priority, fteu, tariff);\n response = postMT(mt_request_xml);\n com.novartis.xmlbinding.mt_response.Response res = getResponse(response);\n //com.novartis.xmlbinding.mt_response.Response res = getResponse(\"<?xml version=\\\"1.0\\\" encoding=\\\"utf-8\\\"?><response><mts><mt><mobilenumber>\"+mobilenumber+\"</mobilenumber></mt></mts><status>FAIL</status><statusmessage><exceptions><exception>User not opted in for SMS</exception></exceptions></statusmessage></response>\");\n\n\n //System.out.print(\"User with mobile number:\"+mobilenumber+\" does not exist!\");\n List<String> statusmsg = getStatusmessage(response);\n\n return new OtherResponse(res.getStatus(), statusmsg);\n }\n\n }", "private void sendSms(SmsTracker tracker) {\n HashMap map = tracker.mData;\n\n byte smsc[] = (byte[]) map.get(\"smsc\");\n byte pdu[] = (byte[]) map.get(\"pdu\");\n\n Message reply = obtainMessage(EVENT_SEND_SMS_COMPLETE, tracker);\n mCm.sendSMS(SimUtils.bytesToHexString(smsc),\n SimUtils.bytesToHexString(pdu), reply);\n }", "public interface LKSmsService {\n\n /**\n * 发送 短信\n * @param sms\n *\n * @return\n */\n Result sendSms(SmsRequest sms) throws IOException;\n\n\n\n}" ]
[ "0.81323695", "0.7933584", "0.7540706", "0.7446484", "0.7190366", "0.70539695", "0.69916075", "0.69597024", "0.68377423", "0.6823415", "0.666103", "0.66394204", "0.6620715", "0.6616711", "0.6587819", "0.6585257", "0.65688187", "0.6514331", "0.6464325", "0.64036995", "0.63988", "0.6396385", "0.6385891", "0.6365839", "0.63520116", "0.63303596", "0.63202536", "0.63127005", "0.6272506", "0.6244588", "0.6237032", "0.62254804", "0.62130916", "0.6205305", "0.6204282", "0.61991394", "0.61913186", "0.6162041", "0.6145513", "0.6116892", "0.6099653", "0.6089695", "0.60772353", "0.60585195", "0.60581726", "0.60541266", "0.6047599", "0.6038456", "0.6032582", "0.60160905", "0.60126746", "0.6003076", "0.59906757", "0.5986912", "0.5984363", "0.5972485", "0.5953178", "0.5943535", "0.5940517", "0.5933422", "0.59253407", "0.5917472", "0.59052926", "0.59039843", "0.59019214", "0.5898778", "0.58980423", "0.5888179", "0.5886624", "0.58773243", "0.5849422", "0.5826584", "0.58153826", "0.5783878", "0.57642776", "0.5761807", "0.5756175", "0.5754938", "0.5743789", "0.573645", "0.57340956", "0.5722727", "0.57215315", "0.5715365", "0.5710579", "0.57104456", "0.57042843", "0.5698929", "0.56928456", "0.5692166", "0.5690682", "0.5689543", "0.56836087", "0.5681772", "0.5665032", "0.5662613", "0.5659977", "0.56593734", "0.56562424", "0.565489" ]
0.6462633
19
region GETs and SETs
public String getName() { return name; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\r\n\tpublic void get() {\n\t\t\r\n\t}", "public void get() {\n }", "public String get();", "@Override\n public void get() {}", "public T get() {\n return value;\n }", "@Test\n\tpublic void get_test()\n\t{\n\t\tb.set(1,2,'x');\n\t\tassertEquals(b.get(1,2),'x');\n\t}", "public T get() {\n return value;\n }", "public T get() {\n return value;\n }", "protected Object doGetValue() {\n\t\treturn value;\n\t}", "public synchronized int get() { \n return this.soma_pares; \n }", "String get();", "String get();", "protected abstract Set method_1559();", "String setValue();", "public int\t\tget() { return value; }", "protected static void get() {\n\t\tstepsTable.get();\n\t\tstepsTable.getWeek();\n\t\tactive.get();\n\t\tmeals.get();\n\t\taccountInfo.get();\n\t\t\n\t}", "public abstract String get();", "boolean get();", "@Override\n String get();", "public Object get()\n {\n return m_internalValue;\n }", "public V get() {\n return value;\n }", "public final Object get() {\n return getValue();\n }", "public String get()\n {\n return val;\n }", "@Test\n public void testGetSets() {\n ref.setKey(\"test23\");\n assertEquals(\"test23\", ref.getKey());\n ref.setAuthor(\"test23\");\n assertEquals(\"test23\", ref.getAuthor());\n ref.setEditor(\"test23\");\n assertEquals(\"test23\", ref.getEditor());\n ref.setTitle(\"test23\");\n assertEquals(\"test23\", ref.getTitle());\n ref.setBooktitle(\"test23\");\n assertEquals(\"test23\", ref.getBooktitle());\n ref.setYear(\"1839\");\n assertEquals(\"1839\", ref.getYear());\n ref.setPublisher(\"Otava\");\n assertEquals(\"Otava\", ref.getPublisher());\n ref.setJournal(\"test23\");\n assertEquals(\"test23\", ref.getJournal());\n ref.setVolume(\"3\");\n assertEquals(\"3\", ref.getVolume());\n ref.setNumber(\"123\");\n assertEquals(\"123\", ref.getNumber());\n ref.setSeries(\"test23\");\n assertEquals(\"test23\", ref.getSeries());\n ref.setEdition(\"3rd\");\n assertEquals(\"3rd\", ref.getEdition());\n ref.setPages(\"12-35\");\n assertEquals(\"12-35\", ref.getPages());\n ref.setMonth(\"May\");\n assertEquals(\"May\", ref.getMonth());\n ref.setNote(\"test23\");\n assertEquals(\"test23\", ref.getNote());\n }", "public int getSet() {\n return set;\n }", "boolean getSet();", "double get();", "public Object getValue(){\n \treturn this.value;\n }", "public int getlife(){\r\n return life;\r\n}", "public Object getValue() { return _value; }", "public Object getValue()\n {\n\treturn value;\n }", "@Test\n public void testSongGettersSetters() {\n Integer id = 4;\n String title=\"title\",uri = \"uri\";\n\n Song song = new Song();\n song.setId(id);\n song.setTitle(title);\n song.setUri(uri);\n\n assertEquals(\"Problem with id\",id, song.getId());\n assertEquals(\"Problem with title\",title, song.getTitle());\n assertEquals(\"Problem with uri\",uri, song.getUri());\n }", "T get();", "T get();", "T get();", "T get();", "public Object getVal()\n { return val; }", "long get();", "public void setdat()\n {\n }", "public int setValue (int val);", "public S getValue() { return value; }", "public int getx(){\r\n return z;\r\n}", "public String getValue() {\n/* 99 */ return this.value;\n/* */ }", "String getVal();", "@Test\n public void testValueGetter() {\n final List<ConfigDocument> docs = Arrays.asList(new ConfigDocument(DS_1), new ConfigDocument(DS_2), new ConfigDocument(DS_3), new ConfigDocument(RANDOM));\n final ConfigSearchResult<?> result = new ConfigSearchResult<>(docs);\n assertEquals(result.getValues(), Arrays.asList(DS_1, DS_2, DS_3, RANDOM));\n }", "protected abstract String getPropertyValue(Server instance);", "public byte[] get(){\n return this.value;\n }", "public void testGetterAndSetter() {\n UDDIOperationInput uddiOperationInput = new UDDIOperationInput();\n\n //Test Get and Set ElementType\n QName qName = new QName(UDDI_NS_URI, \"input\");\n assertNotNull(\"getElementType was null\",\n uddiOperationInput.getElementType());\n assertTrue(\"getElementType was incorrect\",\n uddiOperationInput.getElementType().equals(qName));\n\n //Test Get and Set Required\n uddiOperationInput.setRequired(isRequired);\n assertFalse(\"getRequired returned true\",\n uddiOperationInput.getRequired());\n isRequired = true;\n uddiOperationInput.setRequired(isRequired);\n assertTrue(\"getRequired returned false\",\n uddiOperationInput.getRequired());\n\n //Test Get and Set BusinessName\n uddiOperationInput.setBusinessName(businessName);\n assertTrue(\"getBusinessName incorrect\",\n uddiOperationInput.getBusinessName().equals(businessName));\n\n //Test Get and Set ServiceName\n uddiOperationInput.setServiceName(serviceName);\n assertTrue(\"getServiceName incorrect\",\n uddiOperationInput.getServiceName().equals(serviceName));\n }", "public String getValor()\n/* 17: */ {\n/* 18:27 */ return this.valor;\n/* 19: */ }", "public java.lang.String getGet() {\n return instance.getGet();\n }", "public int getValue() {\n/* 450 */ return this.value;\n/* */ }", "public int getValue() \n {\n return value;\n }", "public String get() {\n return value;\n\t}", "public Object getNewValue()\n {\n return newValue;\n }", "public void setData(){\n\t\tif(companyId != null){\t\t\t\n\t\t\tSystemProperty systemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"BUSINESS_TYPE\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tbusinessType = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"MAX_INVALID_LOGIN\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tinvalidloginMax = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"SKU_GENFLAG\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tautomaticItemCode = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"SKU_GENFORMAT\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tformatItemCode = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"DO_NUMBERFORMAT\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tdeliveryItemNoFormat = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"STO_NUMBERFORMAT\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tstockOpnameNoFormat = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"RN_NUMBERFORMAT\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\treceiptItemNoFormat = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"PLU_GENFLAG\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tautomaticProdCode = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"PLU_FORMAT_TYPE\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tprodCodeFormat = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"SO_NUMBERFORMAT\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tsalesNoFormat = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"SOINV_NUMBERFORMAT\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tinvoiceNoFormat = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"SORCPT_NUMBERFORMAT\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\treceiptNoFormat = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"DEFAULT_TAX_TYPE\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tsalesTax = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"DELIVERY_COST\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tdeliveryCost = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"PO_NUMBERFORMAT\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tpurchaceNoFormat = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"PINV_NUMBERFORMAT\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tpurchaceInvoiceNoFormat = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"PAYMENT_NUMBERFORMAT\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\tpaymentNoFormat = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t\t\n\t\t\tsystemProperty = systemPropertyService\n\t\t\t\t\t.searchSystemPropertyNameAndCompany(\"TAX_VALUE\", companyId);\n\t\t\tif(systemProperty!=null){\n\t\t\t\ttaxValue = systemProperty.getSystemPropertyValue();\n\t\t\t}\n\t\t} else {\n\t\t\tbusinessType = null;\n\t\t\tinvalidloginMax = null;\n\t\t\tautomaticItemCode = null;\n\t\t\tformatItemCode = null;\n\t\t\tdeliveryItemNoFormat = null;\n\t\t\tstockOpnameNoFormat = null;\n\t\t\treceiptItemNoFormat = null;\n\t\t\tautomaticProdCode = null;\n\t\t\tprodCodeFormat = null;\n\t\t\tsalesNoFormat = null;\n\t\t\tinvoiceNoFormat = null;\n\t\t\treceiptNoFormat = null;\n\t\t\tsalesTax = null;\n\t\t\tdeliveryCost = null;\n\t\t\tpurchaceNoFormat = null;\n\t\t\tpurchaceInvoiceNoFormat = null;\n\t\t\tpaymentNoFormat = null;\n\t\t\ttaxValue = null;\n\t\t}\n\t}", "public Object getValue() { return this.value; }", "public abstract void set(DataType x, DataType y, DataType z);", "void set(T t);", "private void getSavedValues() {\r\n\r\n if (this.pl_expert.getParam(\"displayNodeDegree\") != null) {\r\n this.display_node_degree_current = this.pl_expert.getParam(\"displayNodeDegree\");\r\n } else {\r\n this.display_node_degree_current = display_node_degree_default;\r\n }\r\n\r\n if (this.pl_expert.getParam(\"displayEdges\") != null) {\r\n this.display_edges_current = this.pl_expert.getParam(\"displayEdges\");\r\n } else {\r\n this.display_edges_current = display_edges_default;\r\n }\r\n\r\n if (this.pl_expert.getParam(\"scale\") != null) {\r\n this.scale_current = this.pl_expert.getParam(\"scale\");\r\n } else {\r\n this.scale_current = scale_default;\r\n }\r\n\r\n if (this.pl_expert.getParam(\"minWeight\") != null) {\r\n this.minweight_edges_current = this.pl_expert.getParam(\"minWeight\");\r\n } else {\r\n this.minweight_edges_current = minweight_edges_default;\r\n }\r\n\r\n if (this.pl_expert.getParam(\"iterations\") != null) {\r\n this.iterations_current = this.pl_expert.getParam(\"iterations\");\r\n } else {\r\n this.iterations_current = iterations_default;\r\n }\r\n\r\n if (this.pl_expert.getParam(\"vote_value\") != null) {\r\n this.vote_value_current = this.pl_expert.getParam(\"vote_value\");\r\n } else {\r\n this.vote_value_current = vote_value_default;\r\n }\r\n\r\n if (this.pl_expert.getParam(\"keep_value\") != null) {\r\n this.keepclass_value_current = this.pl_expert.getParam(\"keep_value\");\r\n } else {\r\n this.keepclass_value_current = keepclass_value_default;\r\n }\r\n\r\n if (this.pl_expert.getParam(\"mut_value\") != null) {\r\n this.mut_value_current = this.pl_expert.getParam(\"mut_value\");\r\n } else {\r\n this.mut_value_current = mut_value_default;\r\n }\r\n\r\n if (this.pl_expert.getParam(\"mutationParameter\") != null) {\r\n this.mut_option_current = this.pl_expert.getParam(\"mutationParameter\");\r\n } else {\r\n this.mut_option_current = mut_option_default;\r\n }\r\n\r\n if (this.pl_expert.getParam(\"Update_param\") != null) {\r\n this.update_param_current = this.pl_expert.getParam(\"Update_param\");\r\n } else {\r\n this.update_param_current = update_param_default;\r\n }\r\n\r\n if (this.pl_expert.getParam(\"Alg_param\") != null) {\r\n this.alg_param_current = this.pl_expert.getParam(\"Alg_param\");\r\n } else {\r\n this.alg_param_current = alg_param_default;\r\n }\r\n\r\n if (this.pl_expert.getParam(\"only_sub\") != null) {\r\n this.display_sub_current = new Boolean(this.pl_expert.getParam(\"only_sub\")).booleanValue();\r\n } else {\r\n this.display_sub_current = display_sub_default;\r\n }\r\n\r\n this.is_alg_started = false;\r\n }", "public int get () { return rating; }", "public String get()\n {\n return this.string;\n }", "@Override\n\tpublic void get() {\n\t\tSystem.out.println(\"this is get\");\n\t}", "Object getValor();", "public int geti(){\r\n return i;\r\n}", "public int getValue() { return 42; }", "public String setter() {\n\t\treturn prefix(\"set\");\n\t}", "Object readValue();", "public int getLiving(){\n return living;\n }", "public int value() { \n return this.value; \n }", "public abstract Object getValue(Context context) throws PropertyException;", "private void assignment() {\n\n\t\t\t}", "public int getValue(){\n return value;\n }", "public Object get (int i)\r\n {\r\n }", "public int getValue(){\n return this.value;\n }", "private synchronized T val() {\n\t\t\treturn val;\n\t\t}", "public boolean isValueGet() {\r\n return valueGet;\r\n }", "public Empresa getEmpresa()\r\n/* 84: */ {\r\n/* 85:131 */ return this.empresa;\r\n/* 86: */ }", "protected void storeCurrentValues() {\n }", "@Before(order=0)\n\tpublic void getProperty() {\n\t\tconfigReader = new ConfigReaders();\n\t\tprop = configReader.init_prop();\n\t\t\n\t}", "public Value getValue(){\n return this.value;\n }", "public int getDef(){\r\n return def;\r\n }", "public T set(T obj);", "public void setValue(S s) { value = s; }", "@Override\n\tprotected void getData() {\n\t\t\n\t}", "public void setValor(String valor)\n/* 22: */ {\n/* 23:34 */ this.valor = valor;\n/* 24: */ }", "public int getLives(){return lives;}", "public int getYearsOffice()\n {\n return yearsOffice;\n}", "int getNumber () { return number; }", "public int getVal() {\n return val;\n }", "@Test\n public void setAndGetTest() {\n GameEntity t2 = new GameEntity(new Rectangle(10.0, 10.0));\n\n //Set and getting temp node\n t2.getView().setTranslateX(5.0);\n t2.getView().setTranslateY(5.0);\n Circle temp = new Circle(4);\n t2.setView(temp);\n assertEquals(\"Expected view to be changed\", temp, t2.getView());\n\n //Testing the alive and dead of the object\n t2.setAlive(false);\n assertEquals(\"Expected the object state to be set to dead.\", false, t2.isAlive());\n assertEquals(\"Expected the reverse of object state to be set to alive.\", true, t2.isDead());\n }", "public void setProp(String key, String value){\t\t\n \t\t//Check which of property to set & set it accordingly\n \t\tif(key.equals(\"UMPD.latestReport\")){\n \t\t\tthis.setLatestReport(value);\n<<<<<<< HEAD\n\t\t} \n=======\n \t\t\treturn;\n \t\t} \n \t\tif (key.equals(\"UMPD.latestVideo\")) {\n \t\t\tthis.setLastestVideo(value);\n \t\t\treturn;\n \t\t}\n>>>>>>> 45a14c6cf04ac0844f8d8b43422597ae953e0c42\n \t}\n //-----------------------------------------------------------------------------\n \t/**\n \t * @return - a list of <code>FieldAndval</code> objects representing the set \n \t * properties\n \t */\n \tpublic ArrayList<FieldAndVal> getSetPropsList(){\n \t\tcreateSetPropsList();\n \t\treturn setPropsList;\n \t}\n //-----------------------------------------------------------------------------\n \t/**\n \t * \n \t */\n \tprivate void createSetPropsList(){\n \t\tif((this.latestReport).length()>0){\n \t\t\tsetPropsList.add(new FieldAndVal(\"UMPD.latestReport\", this.latestReport));\n \t\t}\n \t}\n //-----------------------------------------------------------------------------\n \t/**\n \t * @return lastestVideo - \n \t */\n \tpublic String getLastestVideo() {\n \t\treturn lastestVideo;\n \t}", "public void readAndSetData(){\n//\t\tentityMember = entitySelection.getItemAt(entitySelection.getSelectedIndex());\n\t\t\n\t\tzValue = 0.0f;\n\t\t//read in z value\n\t\ttry{\n\t\t\tzValue = Float.valueOf(zPosInput.getText());\n\t\t}catch(Exception e){\n\t\t\tSystem.err.println(\"Could not read z input value - setting to 0!\");\n\t\t\tzValue = 0.0f;\n\t\t}\n\t\t//Z coord, check water, then terrain, if neither then use absolute\n\t\tif(offsetFromWaterMenuItem.isSelected()){\n\t\t\taboveWater = true;\n\t\t\taboveTerrain = false;\n\t\t}else if(offsetFromTerrainMenuItem.isSelected()){\n\t\t\taboveTerrain = true;\n\t\t\taboveWater = false;\n\t\t}else{\n\t\t\taboveWater = false;\n\t\t\taboveTerrain = false;\n\t\t}\n\t\t\n\t\ttry{\n\t\t\trotX = Float.valueOf(rotXField.getText());\n\t\t\trotY = Float.valueOf(rotYField.getText());\n\t\t\trotZ = Float.valueOf(rotZField.getText());\n\t\t\tscale = Float.valueOf(scaleField.getText());\n\t\t}catch(Exception e){\n\t\t\tSystem.err.println(\"Could not read rotations or scale input value - setting values to standard\");\n\t\t\trotX = 0.0f;\n\t\t\trotY = 0.0f;\n\t\t\trotZ = 0.0f;\n\t\t\tscale = 1.0f;\n\t\t}\n\t\t\n\t\t\n\t}", "@Test\n public void testSetNombre() {\n System.out.println(\"setNombre\");\n Receta instance = new Receta();\n instance.setNombre(\"nom1\");\n String expResult = \"nom1\";\n String result = instance.getNombre();\n assertEquals(expResult, result);\n }", "V getValue() {\n return value;\n }", "public int[] get() {\n return res;\n }", "public void setM_Locator_ID (int M_Locator_ID)\n{\nset_Value (\"M_Locator_ID\", new Integer(M_Locator_ID));\n}", "@Test\r\n\tpublic void testGettersSetters()\r\n\t{\r\n\t\tPerson p = new Person(42);\r\n\t\tp.setDisplayName(\"Fred\");\r\n\t\tassertEquals(\"Fred\", p.getFullname());\r\n\t\tp.setPassword(\"hunter2\");\r\n\t\tassertEquals(\"hunter2\", p.getPassword());\r\n\t\tassertEquals(42, p.getID());\r\n\t}", "public int getDef(){\n return def;\n }", "public int getEva(){\n return eva;\n }", "public int Getx(){\n\t\treturn x;\n\t}", "@Override\n\tpublic void getData() {\n\t\t\n\t}" ]
[ "0.6138022", "0.60937715", "0.60075986", "0.6004755", "0.59934765", "0.59905636", "0.5987933", "0.5987933", "0.5957747", "0.59332436", "0.59300697", "0.59300697", "0.5902764", "0.5902516", "0.5846901", "0.5819307", "0.57253015", "0.57095826", "0.5709198", "0.57032967", "0.56546056", "0.5563008", "0.55505735", "0.55230963", "0.55081266", "0.5503752", "0.5479001", "0.5438189", "0.5435103", "0.5432297", "0.54078805", "0.54027504", "0.53986275", "0.53986275", "0.53986275", "0.53986275", "0.5389448", "0.5387214", "0.5374237", "0.53675514", "0.5352166", "0.53449136", "0.5343498", "0.53398556", "0.5339097", "0.53267384", "0.53260463", "0.53166854", "0.5305522", "0.529631", "0.52906114", "0.5283271", "0.52804273", "0.52719265", "0.52711433", "0.526217", "0.52615887", "0.525627", "0.5252011", "0.524952", "0.52474356", "0.5245336", "0.5241252", "0.5239473", "0.5239053", "0.52382433", "0.5236045", "0.5234262", "0.52297384", "0.52254254", "0.52241874", "0.5217824", "0.52171636", "0.52136254", "0.52000904", "0.51987326", "0.5191643", "0.51888645", "0.51860833", "0.5184502", "0.5184436", "0.5183323", "0.51821667", "0.5175613", "0.51715475", "0.51703054", "0.5160837", "0.51572084", "0.51566374", "0.5155104", "0.51530874", "0.51404953", "0.5139561", "0.5132617", "0.513163", "0.5130247", "0.5127121", "0.5126404", "0.51229566", "0.511479", "0.5112215" ]
0.0
-1
Inflate the layout for this fragment
@Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { View RootView = inflater.inflate(R.layout.fragment_view_map, container, false); nav_map = (BottomNavigationView)RootView.findViewById(R.id.map_nav); home_frame = (FrameLayout)RootView.findViewById(R.id.view_map); pm25MapFragment = new PM25MapFragment(); psiMapFragment = new PSIMapFragment(); gymMapFragment = new GymMapFragment(); healthierCaterersMap = new HealthierCaterersMap(); setFragment(pm25MapFragment); nav_map.setOnNavigationItemSelectedListener(new BottomNavigationView.OnNavigationItemSelectedListener() { @Override public boolean onNavigationItemSelected(@NonNull MenuItem item) { switch(item.getItemId()){ case R.id.nav_pm25 : { setFragment(pm25MapFragment); return true; } case R.id.nav_psi :{ setFragment(psiMapFragment); return true; } case R.id.nav_gym :{ setFragment(gymMapFragment); return true; } case R.id.nav_healthier_cateriers :{ setFragment(healthierCaterersMap); return true; } default: return false; } } }); return RootView; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_main_allinfo, container, false);\n }", "@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n\t\t\tBundle savedInstanceState) {\n\t\treturn inflater.inflate(R.layout.wallpager_layout, null);\r\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_invit_friends, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View inflate = inflater.inflate(R.layout.fragment_zhuye, container, false);\n initView(inflate);\n initData();\n return inflate;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n // Defines the xml file for the fragment\n return inflater.inflate(R.layout.fragment_posts, parent, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n return inflater.inflate(R.layout.ilustration_fragment, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.fragment_sow_drug_cost_per_week, container, false);\n\n db = new DataBaseAdapter(getActivity());\n hc = new HelperClass();\n pop = new FeedSowsFragment();\n\n infltr = (LayoutInflater) getActivity().getSystemService(Context.LAYOUT_INFLATER_SERVICE);\n parent = (LinearLayout) v.findViewById(R.id.layout_for_add);\n tvTotalCost = (TextView) v.findViewById(R.id.totalCost);\n\n getData();\n setData();\n\n return v;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_stream_list, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.fragment_event, container, false);\n\n\n\n\n\n\n\n\n return v;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_feed, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.screen_select_list_student, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View rootView = inflater.inflate(R.layout.fragment_overall, container, false);\n mNamesLayout = (LinearLayout) rootView.findViewById(R.id.fragment_overall_names_layout);\n mOverallView = (OverallView) rootView.findViewById(R.id.fragment_overall_view);\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState)\n {\n\n\n view = inflater.inflate(R.layout.fragment_earning_fragmant, container, false);\n ini(view);\n return view;\n }", "@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n super.onCreateView(inflater, container, savedInstanceState);\n final View rootview = inflater.inflate(R.layout.activity_email_frag, container, false);\n ConfigInnerElements(rootview);\n return rootview;\n }", "@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n\t\t\tBundle savedInstanceState) {\n\t\trootView = inflater.inflate(R.layout.fragment_attack_armor, container, false);\r\n\r\n\t\tfindInterfaceElements();\r\n\t\taddRangeSelector();\r\n\t\tupdateHeadings();\r\n\t\tsetListeners();\r\n\r\n\t\tsetFromData();\r\n\r\n\t\treturn rootView;\r\n\t}", "@SuppressLint(\"InflateParams\")\r\n\t@Override\r\n\tpublic View initLayout(LayoutInflater inflater) {\n\t\tView view = inflater.inflate(R.layout.frag_customer_all, null);\r\n\t\treturn view;\r\n\t}", "@Override\r\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_fore_cast, container, false);\r\n initView();\r\n mainLayout.setVisibility(View.GONE);\r\n apiInterface = RestClinet.getClient().create(ApiInterface.class);\r\n loadData();\r\n return view;\r\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_friend, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n rootView = inflater.inflate(R.layout.fragment_detail, container, false);\n image = rootView.findViewById(R.id.fr_image);\n name = rootView.findViewById(R.id.fr_name);\n phoneNumber = rootView.findViewById(R.id.fr_phone_number);\n email = rootView.findViewById(R.id.fr_email);\n street = rootView.findViewById(R.id.fr_street);\n city = rootView.findViewById(R.id.fr_city);\n state = rootView.findViewById(R.id.fr_state);\n zipcode = rootView.findViewById(R.id.fr_zipcode);\n dBrith = rootView.findViewById(R.id.date_brith);\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_pm25, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_kkbox_playlist, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View rootView = inflater.inflate(R.layout.fragment_feed_pager, container, false);\n\n// loadData();\n\n findViews(rootView);\n\n setViews();\n\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n layout = (FrameLayout) inflater.inflate(R.layout.fragment_actualites, container, false);\n\n relLayout = (RelativeLayout) layout.findViewById(R.id.relLayoutActus);\n\n initListView();\n getXMLData();\n\n return layout;\n }", "@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n rootView = inflater.inflate(R.layout.frag_post_prayer_video, container, false);\n setCustomDesign();\n setCustomClickListeners();\n return rootView;\n }", "@Override\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\n\t\t\tBundle savedInstanceState) {\n\t\treturn inflater.inflate(R.layout.lf_em4305_fragment, container, false);\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_recordings, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view=inflater.inflate(R.layout.fragment_category, container, false);\n initView(view);\n bindRefreshListener();\n loadParams();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_cm_box_details, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view=inflater.inflate(R.layout.fragment_layout12, container, false);\n\n iniv();\n\n init();\n\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_details, container, false);\n //return inflater.inflate(R.layout.fragment_details, container, false);\n getIntentValues();\n initViews();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_mem_body_blood, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_qiugouxiaoxi, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View inflate = inflater.inflate(R.layout.fragment_coll_blank, container, false);\n initView(inflate);\n initData();\n return inflate;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_attendance_divide, container, false);\n\n initView(view);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n // Defines the xml file for the fragment\n return inflater.inflate(R.layout.show_program_fragment, parent, false);\n }", "@Override\n public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container,\n @Nullable Bundle savedInstanceState) {\n return inflater.inflate(R.layout.visualization_fragment, container, false);\n\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n rootView = inflater.inflate(R.layout.fragment_category_details_page, container, false);\n initializeAll();\n\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n final View v = inflater.inflate(R.layout.fragemnt_reserve, container, false);\n\n\n\n\n return v;\n }", "protected int getLayoutResId() {\n return R.layout.activity_fragment;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_all_quizs, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n role = getArguments().getInt(\"role\");\n rootview = inflater.inflate(R.layout.fragment_application, container, false);\n layout = rootview.findViewById(R.id.patentDetails);\n progressBar = rootview.findViewById(R.id.progressBar);\n try {\n run();\n } catch (IOException e) {\n e.printStackTrace();\n }\n return rootview;\n }", "@Override\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container,\n\t\t\tBundle savedInstanceState) {\n\t\tview = inflater.inflate(R.layout.fragment_zhu, null);\n\t\tinitView();\n\t\tinitData();\n\t\treturn view;\n\t}", "@Override\n\t\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState)\n\t\t{\n\t\t\tView rootView = inflater.inflate(R.layout.maimfragment, container, false);\n\t\t\treturn rootView;\n\t\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n // Inflate the layout for this fragment\n return inflater.inflate(R.layout.fragment__record__week, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_porishongkhan, container, false);\n\n\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_dashboard, container, false);\n resultsRv = view.findViewById(R.id.db_results_rv);\n resultText = view.findViewById(R.id.db_search_empty);\n progressBar = view.findViewById(R.id.db_progressbar);\n lastVisitText = view.findViewById(R.id.db_last_visit);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(getLayoutId(), container, false);\n init(view);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_feedback, container, false);\n self = getActivity();\n initUI(view);\n initControlUI();\n initData();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.fragment_service_summery, container, false);\n tvVoiceMS = v.findViewById(R.id.tvVoiceValue);\n tvDataMS = v.findViewById(R.id.tvdataValue);\n tvSMSMS = v.findViewById(R.id.tvSMSValue);\n tvVoiceFL = v.findViewById(R.id.tvVoiceFLValue);\n tvDataBS = v.findViewById(R.id.tvDataBRValue);\n tvTotal = v.findViewById(R.id.tvTotalAccountvalue);\n return v;\n }", "@Override\r\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\r\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_clan_rank_details, container, false);\r\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_star_wars_list, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View inflate = inflater.inflate(R.layout.fragment_lei, container, false);\n\n initView(inflate);\n initData();\n return inflate;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_quotation, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_wode_ragment, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n\n\n\n\n\n return inflater.inflate(R.layout.fragment_appoint_list, parent, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n if (rootView == null) {\n rootView = inflater.inflate(R.layout.fragment_ip_info, container, false);\n initView();\n }\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_offer, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_rooms, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n\n View view = inflater.inflate(R.layout.fragment_img_eva, container, false);\n\n getSendData();\n\n initView(view);\n\n initData();\n\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_project_collection, container, false);\n ButterKnife.bind(this, view);\n fragment = this;\n initView();\n getCollectionType();\n // getCategoryList();\n initBroadcastReceiver();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_yzm, container, false);\n initView(view);\n return view;\n }", "@Override\r\n\tpublic View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n\t\tmainLayout = inflater.inflate(R.layout.fragment_play, container, false);\r\n\t\treturn mainLayout;\r\n\t}", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_invite_request, container, false);\n initialiseVariables();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n getLocationPermission();\n return inflater.inflate(R.layout.centrum_fragment, container, false);\n\n\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View rootView = inflater.inflate(R.layout.fragment_habit_type_details, container, false);\n\n habitTitle = rootView.findViewById(R.id.textViewTitle);\n habitReason = rootView.findViewById(R.id.textViewReason);\n habitStartDate = rootView.findViewById(R.id.textViewStartDate);\n habitWeeklyPlan = rootView.findViewById(R.id.textViewWeeklyPlan);\n\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View v = inflater.inflate(R.layout.fragment_information_friends4, container, false);\n\n if (getArguments() != null) {\n FriendsID = getArguments().getString(\"keyFriends\");\n }\n\n return v;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_post_details, container, false);\n\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_hotel, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view=inflater.inflate(R.layout.fragment_bus_inquiry, container, false);\n initView();\n initData();\n initDialog();\n getDataFromNet();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_weather, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_srgl, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_ground_detail_frgment, container, false);\n init();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_book_appointment, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_wheretogo, container, false);\n ids();\n setup();\n click();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n binding = DataBindingUtil\n .inflate(inflater, R.layout.fragment_learning_leaders, container, false);\n init();\n\n return rootView;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_end_game_tab, container, false);\n\n setupWidgets();\n setupTextFields(view);\n setupSpinners(view);\n\n // Inflate the layout for this fragment\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.memoir_fragment, container, false);\n\n getUserIdFromSharedPref();\n configureUI(view);\n configureSortSpinner();\n configureFilterSpinner();\n\n networkConnection = new NetworkConnection();\n new GetAllMemoirTask().execute();\n\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_jadwal, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n view = inflater.inflate(R.layout.fragment_delivery_detail, container, false);\n initialise();\n\n\n\n return view;\n }", "@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_4, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_all_product, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_group_details, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment06_7, container, false);\n initView(view);\n setLegend();\n setXAxis();\n setYAxis();\n setData();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_downloadables, container, false);\n }", "@Override\n public View onCreateView(@NonNull LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.movie_list_fragment, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_like, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_hall, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_unit_main, container, false);\n TextView mTxvBusinessAassistant = (TextView) view.findViewById(R.id.txv_business_assistant);\n TextView mTxvCardINformation = (TextView) view.findViewById(R.id.txv_card_information);\n RelativeLayout mRelOfficialWebsite = (RelativeLayout) view.findViewById(R.id.rel_official_website);\n RelativeLayout mRelPictureAblum = (RelativeLayout) view.findViewById(R.id.rel_picture_album);\n TextView mTxvQrCodeCard = (TextView) view.findViewById(R.id.txv_qr_code_card);\n TextView mTxvShareCard = (TextView) view.findViewById(R.id.txv_share_card);\n mTxvBusinessAassistant.setOnClickListener(this.mOnClickListener);\n mTxvCardINformation.setOnClickListener(this.mOnClickListener);\n mRelOfficialWebsite.setOnClickListener(this.mOnClickListener);\n mRelPictureAblum.setOnClickListener(this.mOnClickListener);\n mTxvQrCodeCard.setOnClickListener(this.mOnClickListener);\n mTxvShareCard.setOnClickListener(this.mOnClickListener);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_moviespage, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_s, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_overview, container, false);\n\n initOverviewComponents(view);\n registerListeners();\n initTagListener();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_bahan_ajar, container, false);\n initView(view);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {\n root = (ViewGroup) inflater.inflate(R.layout.money_main, container, false);\n context = getActivity();\n initHeaderView(root);\n initView(root);\n\n getDate();\n initEvetn();\n return root;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup parent, Bundle savedInstanceState) {\n // Defines the xml file for the fragment\n return inflater.inflate(R.layout.fragment_historical_event, parent, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_event_details, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_video, container, false);\n unbinder = ButterKnife.bind(this, view);\n initView();\n initData();\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n\n v= inflater.inflate(R.layout.fragment_post_contacts, container, false);\n this.mapping(v);\n return v;\n }", "@Nullable\n @Override\n public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_measures, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n View view = inflater.inflate(R.layout.fragment_feed, container, false);\n findViews(view);\n return view;\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_surah_list, container, false);\n }", "@Override\n public View onCreateView(LayoutInflater inflater, ViewGroup container,\n Bundle savedInstanceState) {\n return inflater.inflate(R.layout.fragment_data_binded, container, false);\n }" ]
[ "0.6739604", "0.67235583", "0.6721706", "0.6698254", "0.6691869", "0.6687986", "0.66869223", "0.6684548", "0.66766286", "0.6674615", "0.66654444", "0.66654384", "0.6664403", "0.66596216", "0.6653321", "0.6647136", "0.66423255", "0.66388357", "0.6637491", "0.6634193", "0.6625158", "0.66195583", "0.66164845", "0.6608733", "0.6596594", "0.65928894", "0.6585293", "0.65842897", "0.65730995", "0.6571248", "0.6569152", "0.65689117", "0.656853", "0.6566686", "0.65652984", "0.6553419", "0.65525705", "0.65432084", "0.6542382", "0.65411425", "0.6538022", "0.65366334", "0.65355957", "0.6535043", "0.65329415", "0.65311074", "0.65310687", "0.6528645", "0.65277404", "0.6525902", "0.6524516", "0.6524048", "0.65232015", "0.65224624", "0.65185034", "0.65130377", "0.6512968", "0.65122765", "0.65116245", "0.65106046", "0.65103024", "0.6509013", "0.65088093", "0.6508651", "0.6508225", "0.6504662", "0.650149", "0.65011525", "0.6500686", "0.64974767", "0.64935696", "0.6492234", "0.6490034", "0.6487609", "0.6487216", "0.64872116", "0.6486594", "0.64861935", "0.6486018", "0.6484269", "0.648366", "0.6481476", "0.6481086", "0.6480985", "0.6480396", "0.64797544", "0.647696", "0.64758915", "0.6475649", "0.6474114", "0.6474004", "0.6470706", "0.6470275", "0.64702207", "0.6470039", "0.6467449", "0.646602", "0.6462256", "0.64617974", "0.6461681", "0.6461214" ]
0.0
-1
=============================== Croppable Atlas Sprite ===============================
public CroppableAtlasSprite obtainSprite(ETexture texture) { return obtainSprite(ResourceCache.getTexture(texture)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void removeSprites(){\r\n\r\n\t}", "private static void loadSprites(){\n \t\tshipSprites.put(\"SCOUT_BLUE\", new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/blue/scout.png\"), 0, 0.5f));\n \t\tshipSprites.put(\"HUNTER_BLUE\", new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/blue/hunter.png\"), 0, 0.5f));\n \t\tshipSprites.put(\"DESTROYER_BLUE\", new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/blue/destroyer.png\"), 0, 0.5f));\n \t\tshipSprites.put(\"COLONIZER_BLUE\", new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/blue/colonizer.png\"), 0.5f, 0.5f));\n \t\t\n \t\t/*\n \t\t * Ships Red Player\n \t\t */\n \t\tshipSprites.put(\"SCOUT_RED\", new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/red/scout.png\"), 0, 0.5f));\n \t\tshipSprites.put(\"HUNTER_RED\", new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/red/hunter.png\"), 0, 0.5f));\n \t\tshipSprites.put(\"DESTROYER_RED\", new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/red/destroyer.png\"), 0, 0.5f));\n \t\tshipSprites.put(\"COLONIZER_RED\", new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/red/colonizer.png\"), 0.5f, 0.5f));\n \n \t\t/*\n \t\t * Path Arrows\n \t\t */\n\t\tpathTextures.put(\"HEAD\", Toolkit.getDefaultToolkit().getImage(\"res/path/head.png\"));\n\t\tpathTextures.put(\"START\", Toolkit.getDefaultToolkit().getImage(\"res/path/start.png\"));\n\t\tpathTextures.put(\"STRAIGHT\", Toolkit.getDefaultToolkit().getImage(\"res/path/straight.png\"));\n\t\tpathTextures.put(\"TURN\", Toolkit.getDefaultToolkit().getImage(\"res/path/turn.png\"));\n \t\t\n \t\t/*\n \t\t * Planets\n \t\t */\n \t\tmetalplanets.put(0, new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/planets/metalplanet_0.png\"), 0.5f, 0));\n \t\tmetalplanets.put(1, new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/planets/metalplanet_1.png\"), 0.5f, 0));\n \t\tmetalplanets.put(2, new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/planets/metalplanet_2.png\"), 0.5f, 0));\n \t\tmetalplanets.put(3, new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/planets/metalplanet_3.png\"), 0.5f, 0));\n \t\tgasplanets.put(0, new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/planets/gasplanet_0.png\"), 0.5f, 0));\n \t\tgasplanets.put(1, new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/planets/gasplanet_1.png\"), 0.5f, 0));\n \t\tgasplanets.put(2, new Sprite(Toolkit.getDefaultToolkit().getImage(\"res/icons/planets/gasplanet_2.png\"), 0.5f, 0));\n \t\t\n \t\t/*\n \t\t * Colony Sprite\n \t\t */\n \t\tloadColonySprites(Color.RED, \"RED\");\n \t\tloadColonySprites(Color.BLUE, \"BLUE\");\n \t}", "abstract public void loadSprite();", "public Sprite() {}", "private void updateSprite(){\n //facing front\n getImage().clear();\n getImage().drawImage(SHEET,-(frame%SHEET_W)*SPRITE_W,0);\n if(!goLeft) getImage().mirrorHorizontally();\n if (iframes>0&&iframes%10<5) setImage(SpriteHelper.makeWhite( getImage()));\n else frame = frame + 1 % (SHEET_H* SHEET_W);\n }", "public static void init()\n {\n \tSpriteSheet sheet = new SpriteSheet(ImageLoader.loadImage(\"/sprites/spritesheet.png\"));\n BufferedImage img;\n /*for(int y = 0;y<4;y++)\n \t{\n \t\t\n \timg = sheet.crop(width*y,0,width,height);\n \t\t\n \t\tplayer.add(img);\n \t}*/\n hero = sheet.crop(0,0,width,height);\n heroUp = sheet.crop(width,0,width,height);\n heroLeft = sheet.crop(width*2,0,width,height);\n heroRight = sheet.crop(width*3,0,width,height);\n \n heroDown1 = sheet.crop(0,height+32,width+1,height);\n heroDown2 = sheet.crop(width+1,height+32,width+1,height);\n heroUp1 = sheet.crop(width*2+2,height+32,width,height);\n heroUp2 = sheet.crop(width*3+2,height+32,width,height);\n heroLeft1 = sheet.crop(width*4+2,height+32,width,height);\n heroLeft2 = sheet.crop(width*5+2,height+32,width,height);\n heroRight1 = sheet.crop(width*6+2,height+32,width,height);\n heroRight2 = sheet.crop(width*7+2,height+32,width,height);\n \n /*for(int i = 0;i<4;i++)\n {\n \tfor(int y = 0;y<4;y++)\n \t{\n \t\tif(y==1)\n \t\t{\n \t\t\timg = sheet.crop(width*y,height*i,width,height);\n \t\t}\n \t\telse\n \t\t{\n \t\t\timg = sheet.crop(width*y+1,height*i+1,width,height);\n \t\t}\n \t\tplayer.add(img);\n \t}\n }*/\n sheet = new SpriteSheet(ImageLoader.loadImage(\"/sprites/PokemonTileSet.png\"));\n for(int i = 0;i<50;i++)\n {\n \tfor(int y = 0;y<8;y++)\n \t{\n \t\timg = sheet.crop(tileW*y,tileH*i,tileW,tileH);\n \t\tassets.add(img);\n \t}\n }\n \n /*\n hero = sheet.crop(0,0,width,height);\n heroUp = sheet.crop(width,0,width,height);\n heroLeft = sheet.crop(width*2,0,width,height);\n heroRight = sheet.crop(width*3,0,width,height);\n \n treeTopLeft = sheet.crop(0,firstRow,tWidth,tHeight);\n treeTopRight = sheet.crop(tWidth,firstRow,tWidth,tHeight);\n treeMidLeft = sheet.crop(tWidth*2,firstRow,tWidth,tHeight);\n treeMidRight = sheet.crop(tWidth*3,firstRow,tWidth,tHeight);\n treeBotLeft = sheet.crop(tWidth*4,firstRow,tWidth,tHeight);\n treeBotRight = sheet.crop(tWidth*5,firstRow,tWidth,tHeight);\n treeTopLeftGrass = sheet.crop(tWidth*6,firstRow,tWidth,tHeight);\n treeTopRightGrass = sheet.crop(tWidth*7,firstRow,tWidth,tHeight);\n treeTopLeftMushroom = sheet.crop(tWidth*8,firstRow,tWidth,tHeight);\n grass = sheet.crop(tWidth*9,firstRow,tWidth,tHeight);\n \n wildGrass = sheet.crop(0,secondRow,tWidth,tHeight);\n mushroom = sheet.crop(tWidth,secondRow,tWidth,tHeight);\n logLeft = sheet.crop(tWidth*2,secondRow,tWidth,tHeight);\n logRight = sheet.crop(tWidth*3,secondRow,tWidth,tHeight);\n ledgeLeft = sheet.crop(tWidth*4,secondRow,tWidth,tHeight);\n ledgeMid = sheet.crop(tWidth*5,secondRow,tWidth,tHeight);\n ledgeRight = sheet.crop(tWidth*6,secondRow,tWidth,tHeight);\n treeLeftOverlap = sheet.crop(tWidth*7,secondRow,tWidth,tHeight);\n treeRightOverlap = sheet.crop(tWidth*8,secondRow,tWidth,tHeight);\n \n heroWalkingDown1 = sheet.crop(0,thirdRow,width+1,height);\n heroWalkingDown2 = sheet.crop(width+1,thirdRow,width+1,height);\n heroWalkingUp1 = sheet.crop(width*2+1,thirdRow,width,height);\n heroWalkingUp2 = sheet.crop(width*3+1,thirdRow,width,height);\n heroWalkingLeft1 = sheet.crop(width*4+1,thirdRow,width,height);\n heroWalkingLeft2 = sheet.crop(width*5+1,thirdRow,width,height);\n heroWalkingRight1 = sheet.crop(width*6+1,thirdRow,width,height);\n heroWalkingRight2 = sheet.crop(width*7+1,thirdRow,width,height);\n */\n }", "public void onUpReleased(){\n// player.getSprite().setFitHeight(50);\n shipSoundPlayer.stop();\n if(GameEngine.isPlaying)\n player.setSprite(\"Sprites\\\\spaceship_new.png\");\n }", "private void ini_Sprites()\r\n\t{\r\n\t\tLogger.DEBUG(\"ini_Sprites\");\r\n\t\tResourceCache.LoadSprites(false);\r\n\t}", "protected abstract void chooseSprite();", "@Override\n public void draw(Batch batch, float parentAlpha) {\n\n if(vidas == 0){\n sprite.setBounds(body.getPosition().x-7,body.getPosition().y-12,16,16);\n sprite.draw(batch);\n\n }else{\n sprite.setBounds(body.getPosition().x-7,body.getPosition().y-7,16,16);\n sprite.setPosition(body.getPosition().x - 9f, body.getPosition().y - 9);\n sprite.draw(batch);\n patrullar();\n }\n\n\n }", "public void initSpriteSheet() {\n\t\tString url = \"https://amiealbrecht.files.wordpress.com/2016/08/set-cards.jpg?w=1250\";\n\n\t\tcimg = loadImage(url, \"png\");\n\t}", "void turnToSprite(Sprite s) {\n turnToPoint(s._x, s._y);\n }", "public void init(){\n\t\n\t\t//background init\n\t\tthis.background = new Sprite(this.scene, \"space-backdrop.png\", 1280 * 5, 800 * 5);\n\t\tthis.background.setBoundAction(\"background\");\n\t\tthis.background.setSpeedScale(0.2);\n\t\tthis.background.setSpeed(0);\n\t\tthis.sprites.add(this.background);\n\t\t\n\t\t//compass init\n\t\tthis.compass = new Sprite(this.scene, \"compass.png\", 100, 100);\n\t\tthis.compass.setSpeed(0);\n\t\tthis.compass.setPosition(this.compass.getWidth() / 2, this.scene.getHeight() - this.compass.getHeight() / 2);\n\t\t\n\t\t//earth init\n\t\tthis.earth = new Planet(this.scene, \"earth.png\", 4800, 4800);\n\t\tthis.earth.setSpeed(0);\n\t\tthis.earth.setPosition(0, 7000);\n\t\tthis.earth.setBoundAction(\"continue\");\n\t\tthis.sprites.add(this.earth);\n\t\t\n\t\t//ship init\n\t\tthis.mainSprite = new Ship(this.scene, \"cannon.png\", 50, 50, this.k);\n\t\tthis.mainSprite.keyListen = true;\n\t\tthis.mainSprite.setSpeed(0);\n\t\tthis.mainSprite.setPosition(this.scene.getWidth() / 2, this.scene.getHeight() / 2);\n\t\t\n\t\t//asteroids init\n\t\tthis.asteroids.add(new Body(this.scene, \"asteroid.png\", 250, 250, this));\n\t\tthis.asteroids.get(0).setBoundAction(\"continue\");\n\t\tthis.asteroids.get(0).setSpeed(0);\n\t\tthis.asteroids.get(0).setPosition(0, 0);\n\t\tthis.sprites.add(this.asteroids.get(0));\n\t\t\n\t\tfor(int i = 1; i < 200; i++){\n\t\t\t\n\t\t\tint size = (int) Math.round(Math.random() * 400 + 50);\n\t\t\tlong x = Math.round(Math.random() * this.background.getWidth() - (this.background.getWidth() / 2));\n\t\t\tlong y = Math.round(Math.random() * this.background.getHeight() - (this.background.getHeight() / 2));\n\t\t\t\n\t\t\twhile(x > 0 && x < this.scene.getWidth()){\n\t\t\t\tx = Math.round(Math.random() * this.background.getWidth() - (this.background.getWidth() / 2));\n\t\t\t}\n\t\t\t\n\t\t\twhile(y > 0 && y < this.scene.getHeight()){\n\t\t\t\ty = Math.round(Math.random() * this.background.getHeight() - (this.background.getHeight() / 2));\n\t\t\t}\n\t\t\t\n\t\t\tthis.asteroids.add(new Body(this.scene, \"asteroid.png\", size, size, this));\n\t\t\tthis.asteroids.get(i).setBoundAction(\"continue\");\n\t\t\tthis.asteroids.get(i).setSpeed(0);\n\t\t\tthis.asteroids.get(i).setPosition(x, y);\n\t\t\t\n\t\t\tthis.sprites.add(this.asteroids.get(i));\n\t\t}\n\t\t\n\t\t\n\t\t//chest init\n\t\tthis.chests.add(new Chest(this.scene, \"chest.png\", 100, 50));\n\t\tthis.chests.get(0).setBoundAction(\"continue\");\n\t\tthis.chests.get(0).setSpeed(0);\n\t\tthis.chests.get(0).setPosition(500, 500);\n\t\tthis.sprites.add(this.chests.get(0));\n\t\t\n\t\tfor(int i = 1; i < this.numChests; i++){\n\t\t\t\n\t\t\tthis.chests.add(new Chest(this.scene, \"chest.png\", 100, 50));\n\t\t\tthis.chests.get(i).setBoundAction(\"continue\");\n\t\t\tthis.chests.get(i).setSpeed(0);\n\t\t\t\n\t\t\tboolean keepGoing = true;\n\t\t\tdo{\n\t\t\t\t\n\t\t\t\tlong x = Math.round(Math.random() * this.background.getWidth() - (this.background.getWidth() / 2));\n\t\t\t\tlong y = Math.round(Math.random() * this.background.getHeight() - (this.background.getHeight() / 2));\n\t\t\t\t\n\t\t\t\twhile(x > 0 && x < this.scene.getWidth()){\n\t\t\t\t\tx = Math.round(Math.random() * this.background.getWidth() - (this.background.getWidth() / 2));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\twhile(y > 0 && y < this.scene.getHeight()){\n\t\t\t\t\ty = Math.round(Math.random() * this.background.getHeight() - (this.background.getHeight() / 2));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tthis.chests.get(i).setPosition(x, y);\n\t\t\t\t\n\t\t\t\t//check for collisions with asteroids\n\t\t\t\tboolean colliding = false;\n\t\t\t\tfor(int j = 0; j < this.asteroids.size() && colliding == false; j++){\n\t\t\t\t\tif(this.asteroids.get(j).collidesWith(this.chests.get(i))){\n\t\t\t\t\t\tcolliding = true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tkeepGoing = colliding;\n\t\t\t\t\n\t\t\t}while(keepGoing);\n\t\t\t\n\t\t\tthis.sprites.add(this.chests.get(i));\n\t\t\t\n\t\t}//end for\n\t\n\t\tthis.scene.start();\n\t\t\n\t\tSystem.out.println(\"==== Welcome to Space Smuggler! ====\");\n\t\tSystem.out.println(\"(WASD to move)\");\n\t\tSystem.out.println(\"Follow your compass in the bottom left corner to find treasure.\");\n\t\tSystem.out.println(\"Collect all of the treasure, then follow your compass to Earth!\");\n\t\tSystem.out.println(\"Watch out for the asteroids though, their gravitational pull is strong!\");\n\t\tSystem.out.println(\"Crashing into one will certainly kill you! D:\");\n\t\tSystem.out.println(\"Good Luck!\");\n\t\t\n\t}", "public void evaluateSprite(){\n if(this.orientation == Orientation.FACING_NORTH) {\n texture = new Texture(Gdx.files.internal(\"/assets/gameObjects/playerFacingNorth.png\"));\n }\n if(this.orientation == Orientation.FACING_WEST){\n texture = new Texture(Gdx.files.internal(\"/assets/gameObjects/playerFacingWest.png\"));\n }\n if(this.orientation == Orientation.FACING_SOUTH){\n texture = new Texture(Gdx.files.internal(\"/assets/gameObjects/playerFacingSouth.png\"));\n }\n if(this.orientation == Orientation.FACING_EAST){\n texture = new Texture(Gdx.files.internal(\"/assets/gameObjects/playerFacingEast.png\"));\n }\n\n this.sprite = new Sprite(texture);\n }", "public void act() \n {\n setImage(\"1up.png\");\n setImage(\"acrate.png\");\n setImage(\"Betacactus.png\");\n setImage(\"bullet1.png\");\n setImage(\"bullet2.png\");\n setImage(\"burst.png\");\n setImage(\"cowboy.png\");\n setImage(\"fOxen1.png\");\n setImage(\"fOxen2.png\");\n setImage(\"fOxen3.png\");\n setImage(\"fOxen4.png\");\n setImage(\"fOxenH.png\");\n setImage(\"fWagon1.png\");\n setImage(\"fWagon2.png\");\n setImage(\"fWagon3.png\");\n setImage(\"fWagon4.png\");\n setImage(\"fWagonH.png\");\n setImage(\"health.png\");\n setImage(\"indian.png\");\n setImage(\"normal.png\");\n setImage(\"oxen.png\");\n setImage(\"oxen2.png\");\n setImage(\"oxen3.png\");\n setImage(\"oxen4.png\");\n setImage(\"oxen-hit.png\");\n setImage(\"plasma.png\");\n setImage(\"rapid.png\");\n setImage(\"snake1.png\");\n setImage(\"snake2.png\");\n setImage(\"snake3.png\");\n setImage(\"snake4.png\");\n setImage(\"spread.png\");\n setImage(\"theif.png\");\n setImage(\"train1.png\");\n setImage(\"train-hit.png\");\n setImage(\"wagon.png\");\n setImage(\"wagonhit.png\");\n setImage(\"wave.png\");\n getWorld().removeObject(this);\n }", "private void buildSprites() {\n\t\tSpriteRotatable sprite = new SpriteRotatable(new Vec2f(0, 0), 1);\n\t\tsprite.setCentered(true);\n\t\tspriteManager.addSprite(sprite, \"avenger.png\");\n\t\tsprite.setVisible(true);\n\t\ttarget = new SpriteRotatable(new Vec2f(2, 2), 1);\n\t\ttarget.setCentered(true);\n\t\tspriteManager.addSprite(target, \"fighter.png\");\n\t\ttarget.setVisible(true);\n\n\t}", "public void sprite() {\n\t\tspr.setPosition(sprite.getX(),sprite.getY());\n\t\tsprite = spr;\n\t}", "public Missile(SimpleSlickGame _game, int x, int y, int destX, int destY, Entity owner) \r\n\t{\r\n\t\t//the super constructor is called to give the x and y coordinates and call the game to use its variable and \r\n\t\tsuper(_game, x,y);\r\n\t\tsetHitboxRadius(20); \r\n\t\tthis.startX = x;\r\n\t\tthis.startY = y;\r\n\t\tthis.owner = owner;\r\n\t\tthis.destX = destX;\r\n\t\tthis.destY = destY;\r\n\t\tsetLocation(startX, startY);\r\n\t\trecalculateVector(destX, destY);\r\n\t\t\r\n\t\t//Initializes and adds a particle system to the entity\r\n\t\ttry \r\n\t\t{\r\n\n\t\t\tImage particleImg = new Image (\"Particles/particle.png\");\r\n\n\t\t\tparticles = new ParticleSystem(particleImg,150);\r\n\t\t\t\r\n\n\t\t//\tFile xmlFile = new File (\"Particles/fire effect.xml\");\r\n\t\t//\temitter = ParticleIO.loadEmitter(xmlFile);\r\n\t\t\temitter = ParticleIO.loadEmitter(\"Particles/fire effect.xml\");\r\n\n\t\t\temitter.setPosition(this.getPositionX(), this.getPositionY(),false);\r\n\t\t\t\r\n\t\t\tparticles.addEmitter(emitter);\r\n\t\t\tparticles.setBlendingMode(ParticleSystem.BLEND_ADDITIVE);\r\n\t\t\t\r\n\t\t} catch (SlickException e1) {\r\n\t\t\tSystem.out.println(\"cannot find xml file / particle image\");\r\n\t\t\te1.printStackTrace();\r\n\t\t} catch (IOException e) {\r\n\t\t\tSystem.out.println(\"Cannot assign xml file to emitter. File might be missing.\");\r\n\t\t\te.printStackTrace();\r\n\t\t}\r\n\t\t\r\n\t\t//Adds sound files to the entity\r\n\t\ttry\r\n\t\t{\r\n\t\t\tSound sound = new Sound(\"Sounds/lazer.wav\");\r\n\t\t\tfloat pitch = ((float)game.r.nextInt(200) + 800)/1000;\r\n\t\t\tsound.play(pitch,1f);\r\n\t\t} catch (SlickException e){\r\n\t\t\tSystem.out.println(\"Could not find sound file\");\r\n\t\t}\r\n\t\t\r\n\t\t//Adds sprites to the entity\r\n\t\ttry\r\n\t\t{\r\n\t\t\tmissileImg = new Image(\"Graphics/Fireball.png\");\r\n\t\t\tthis.setSprite(missileImg);\r\n\t\t} catch (SlickException e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tSystem.out.println(\"ERROR: Could not find sprite\");\r\n\t\t}\r\n\t}", "Ground(Sprite sprite) {Collect.Hit(\"BoardFactory.java\",\"Ground(Sprite sprite)\");this.background = sprite; Collect.Hit(\"BoardFactory.java\",\"Ground(Sprite sprite)\", \"3015\");}", "@Override\n public void checkCollision( Sprite obj )\n {\n \n }", "public void addSprite(Scene pScene, int x, int y) {\n\t\t\r\n\t}", "Sprite(Sprite s) {\n _img = s._img;\n _x = s._x;\n _y = s._y;\n _w = s._w;\n _h = s._h;\n _rotVector = new PVector(s._rotVector.x, s._rotVector.y, 0);\n _front = s._front;\n _hitboxCenter = new PVector(s._hitboxCenter.x, s._hitboxCenter.y);\n _hitbox = new PVector[s._hitbox.length];\n for (int i = 0; i < _hitbox.length; i++) {\n _hitbox[i] = new PVector(s._hitbox[i].x, s._hitbox[i].y);\n }\n _flipped = s._flipped;\n }", "public void updateClientSprite()\n\t{\n\t\tServerMessage message = new ServerMessage(ClientPacket.SPRITE_CHANGE);\n\t\tmessage.addInt(m_id);\n\t\tmessage.addInt(m_sprite);\n\t\tgetSession().Send(message);\n\t}", "@Override\n public Sprite createSprite(SnakeSmash game) {\n Texture texture = game.getAssetManager().get(\"pinkSquare.png\");\n return new Sprite(texture, texture.getWidth(), texture.getHeight());\n }", "@Override\n public void checkCollision( Sprite obj )\n {\n\n }", "public CopyOfPlayer(){ //Loads and scales the images\n for (int i = 0; i < robotImages.length; i++){\n for (int j = 0; j < black.length; j++){\n robotImages[i][j].scale(300, 300);\n }\n }\n costume = PrefLoader.getCostume(); //Sets costume according to file\n setImage(robotImages[costume][2]);\n }", "public Celda(int x, int y) {\n this.x=x;\n this.y=y;\n this.tipo=CAMINO;\n this.celdaSelec =false;\n\n indexSprite = 0; //indice que corresponde a una subimagen de frente\n\n try {\n jugador = ImageIO.read(new File(\"images/jugador.png\"));\n obstaculo = ImageIO.read(new File(\"images/obstaculo.png\"));\n obstaculo20 = ImageIO.read(new File(\"images/obstaculo-2.png\"));\n obstaculo21 = ImageIO.read(new File(\"images/obstaculo-3.png\"));\n obstaculo22 = ImageIO.read(new File(\"images/obstaculo-4.png\"));\n obstaculo23 = ImageIO.read(new File(\"images/obstaculo-5.png\"));\n obstaculo24 = ImageIO.read(new File(\"images/obstaculo-6.png\"));\n obstaculo25 = ImageIO.read(new File(\"images/obstaculo-7.png\"));\n adversario = ImageIO.read(new File(\"images/adversario.png\"));\n recompensa = ImageIO.read(new File(\"images/recompensa.png\"));\n casa = ImageIO.read(new File(\"images/casa.png\"));\n\n imagenSprites = ImageIO.read(new File(\"images/sprite_jugador.png\"));\n imagenSpritesAdversario = ImageIO.read(new File(\"images/sprite_adversario.png\"));\n //creo una array de 4 x 1\n sprites = new BufferedImage[4 * 1];\n spritesAdversario = new BufferedImage[4 * 1];\n //lo recorro separando las imagenes\n for (int i = 0; i < 1; i++) {\n for (int j = 0; j < 4; j++) {\n sprites[(i * 4) + j] = imagenSprites.getSubimage(i * PIXEL_CELDA, j * PIXEL_CELDA,PIXEL_CELDA, PIXEL_CELDA);\n spritesAdversario[(i * 4) + j] = imagenSpritesAdversario.getSubimage(i * PIXEL_CELDA, j * PIXEL_CELDA, PIXEL_CELDA, PIXEL_CELDA);\n }\n }\n //adversario = spritesAdversario[indexSprite];\n } catch (IOException error) {\n System.out.println(\"Error: \" + error.toString());\n }\n }", "private void generateSprites() {\n final int PIXEL_ZOMBIE_SKIN = 0xa0ff90;\n final int PIXEL_SKIN = 0xFF9993;\n\n int pix = 0;\n for (int i = 0; i < 18; i++) {\n int skin = PIXEL_SKIN;\n int clothes = 0xFFffff;\n\n if (i > 0) {\n skin = PIXEL_ZOMBIE_SKIN;\n clothes = (random.nextInt(0x1000000) & 0x7f7f7f);\n }\n for (int t = 0; t < 4; t++) {\n for (int d = 0; d < 16; d++) {\n double dir = d * Math.PI * 2 / 16.0;\n\n if (t == 1)\n dir += 0.5 * Math.PI * 2 / 16.0;\n if (t == 3)\n dir -= 0.5 * Math.PI * 2 / 16.0;\n\n // if (i == 17)\n // {\n // dir = d * Math.PI * 2 / 64;\n // }\n\n double cos = Math.cos(dir);\n double sin = Math.sin(dir);\n\n for (int y = 0; y < 12; y++) {\n int col = 0x000000;\n for (int x = 0; x < 12; x++) {\n int xPix = (int) (cos * (x - 6) + sin * (y - 6) + 6.5);\n int yPix = (int) (cos * (y - 6) - sin * (x - 6) + 6.5);\n\n if (i == 17) {\n if (xPix > 3 && xPix < 9 && yPix > 3 && yPix < 9) {\n col = 0xff0000 + (t & 1) * 0xff00;\n }\n } else {\n if (t == 1 && xPix > 1 && xPix < 4 && yPix > 3 && yPix < 8)\n col = skin;\n if (t == 3 && xPix > 8 && xPix < 11 && yPix > 3 && yPix < 8)\n col = skin;\n\n if (xPix > 1 && xPix < 11 && yPix > 5 && yPix < 8) {\n col = clothes;\n }\n if (xPix > 4 && xPix < 8 && yPix > 4 && yPix < 8) {\n col = skin;\n }\n }\n sprites[pix++] = col;\n\n // If we just drew a pixel, make the next one an almost-black\n // pixel, and if it's already an almost-black one, make it\n // transparent (full black). (This is all honored only if the\n // next pixel isn't actually set to something else.) This takes\n // advantage of the left-to-right scanning of the sprite\n // generation to create a slight shadow effect on each sprite.\n if (col > 1) {\n col = 1;\n } else {\n col = 0;\n }\n }\n }\n }\n }\n }\n }", "private void drawSprite(int x, int y, int u, int v)\n {\n GlStateManager.color4f(1.0F, 1.0F, 1.0F, 1.0F);\n this.mc.getTextureManager().bindTexture(STAT_ICONS);\n float f = 0.0078125F;\n float f1 = 0.0078125F;\n int i = 18;\n int j = 18;\n Tessellator tessellator = Tessellator.getInstance();\n BufferBuilder bufferbuilder = tessellator.getBuffer();\n bufferbuilder.begin(7, DefaultVertexFormats.POSITION_TEX);\n bufferbuilder.pos((double)(x + 0), (double)(y + 18), (double)this.zLevel).tex((double)((float)(u + 0) * 0.0078125F), (double)((float)(v + 18) * 0.0078125F)).endVertex();\n bufferbuilder.pos((double)(x + 18), (double)(y + 18), (double)this.zLevel).tex((double)((float)(u + 18) * 0.0078125F), (double)((float)(v + 18) * 0.0078125F)).endVertex();\n bufferbuilder.pos((double)(x + 18), (double)(y + 0), (double)this.zLevel).tex((double)((float)(u + 18) * 0.0078125F), (double)((float)(v + 0) * 0.0078125F)).endVertex();\n bufferbuilder.pos((double)(x + 0), (double)(y + 0), (double)this.zLevel).tex((double)((float)(u + 0) * 0.0078125F), (double)((float)(v + 0) * 0.0078125F)).endVertex();\n tessellator.draw();\n }", "@Override\n\tpublic void draw(Graphics2D g2) {\n\t\tBufferedImage subImage = getSprite().getSubimage(0*128,0,128,193);\n\t\tg2.drawImage(subImage,getPositionX(),getPositionY(),null);\n\t}", "public void removeSprite(Sprite s) {\r\n sprites.removeSprite(s);\r\n }", "@Override\n public void chooseSprite() {\n switch(direction){\n case 0:\n sprite=Sprite.python_down;\n if(moving)\n sprite=Sprite.movingSprite(Sprite.python_down,Sprite.python_down_1,Sprite.python_down_2,Sprite.python_down_3,animate,40);\n break;\n case 1:\n sprite=Sprite.python_right;\n if(moving)\n sprite=Sprite.movingSprite(Sprite.python_right,Sprite.python_right_1,Sprite.python_right_2,animate,40);\n break;\n case 2:\n sprite=Sprite.python_up;\n if(moving)\n sprite=Sprite.movingSprite(Sprite.python_up,Sprite.python_up_1,Sprite.python_up_2,animate,40);\n break;\n case 3:\n sprite=Sprite.python_left;\n if(moving)\n sprite=Sprite.movingSprite(Sprite.python_left,Sprite.python_left_1,Sprite.python_left_2,animate,40);\n break;\n\n\n }\n\n }", "public BoardFactory(PacManSprites spriteStore) {Collect.Hit(\"BoardFactory.java\",\"BoardFactory(PacManSprites spriteStore)\");this.sprites = spriteStore; Collect.Hit(\"BoardFactory.java\",\"BoardFactory(PacManSprites spriteStore)\", \"689\");}", "void smallgunHandler() {\n for (Sprite smb: smBullets) {\n \n smb.display();\n if(usingCoil){\n smb.forward(120);\n }else{\n smb.forward(40);\n }\n\n }\n}", "Sprite(String url, float x, float y, float w, float h) {\n _img = loadImage(url);\n _x = x;\n _y = y;\n _w = w;\n _h = h;\n _rotVector = new PVector(1, 0, 0);\n resetRectHitbox();\n }", "public void updateSprites() {\n this.model.getSprites().values().forEach(x -> x.setPosition(this.x, this.y));\n }", "@Override\r\n\tpublic void destroy(Sprite collider) {\n\t}", "public abstract void createSprites() throws FileNotFoundException;", "private void loadSpritesheet() {\n\t\tobjects = new SpriteSheet(\"res\\\\pong.png\");\n\t\tobjects_hires = new SpriteSheet(\"res\\\\ponghires.png\",\n\t\t\t\tSpriteSheet.LINEAR);\n\t}", "Wall(Sprite sprite) {Collect.Hit(\"BoardFactory.java\",\"Wall(Sprite sprite)\");this.background = sprite; Collect.Hit(\"BoardFactory.java\",\"Wall(Sprite sprite)\", \"2420\");}", "@Override\n public boolean visit(CssSprite x, Context ctx) {\n out.printOpt(\"/* CssSprite */\");\n out.newlineOpt();\n addSubstitition(x);\n return false;\n }", "public void move(){\n\t\tswitch(state){\r\n\t\t\tcase ATField.SPRITE_STAND:\r\n\t\t\t\tspriteX = 0;\r\n\t\t\t\tcoords = standbySprite.get(spriteX);\r\n\t\t\t\tspriteImg = new Rect(coords.left,coords.top,coords.right,coords.bottom);\r\n\t\t\t\tactualImg = new Rect(x, y, x + width, y + height);\r\n\t\t\t\tbreak;\r\n\t\t\t\r\n\t\t\r\n\t\t\tcase ATField.SPRITE_WALK:\r\n\t\t\t\tif(spriteX >walkSprite.size() - 1){\r\n\t\t\t\t\tspriteX = 0;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tcoords = walkSprite.get(spriteX);\r\n\t\t\t\tspriteImg = new Rect(coords.left,coords.top,coords.right,coords.bottom);\r\n\t\t\t\tactualImg = new Rect(x, y, x + width, y + height);\r\n\t\t\t\tspriteX++;\r\n\t\t\t\t\r\n\t\t\tbreak;\r\n\t\t\t\r\n\t\t\tcase ATField.SPRITE_RUN:\r\n\t\t\t\t\r\n\t\t\t\tif(spriteX >runSprite.size() - 1){\r\n\t\t\t\t\tspriteX = 0;\r\n\t\t\t\t\tsetState(STAND);\r\n\t\t\t\t}\r\n\t\t\t\tcoords = runSprite.get(spriteX);\r\n\t\t\t\tspriteImg = new Rect(coords.left,coords.top,coords.right,coords.bottom);\r\n\t\t\t\tactualImg = new Rect(x, y, x + width, y + height);\r\n\t\t\t\tspriteX++;\r\n\t\t\t\tbreak;\r\n\t\t\t\r\n\t\t\tcase ATField.SPRITE_JUMP:\r\n\t\t\t\tif(spriteX >5){\r\n\t\t\t\t\tsetState(STAND);\r\n\t\t\t\t}\r\n\t\t\t\tcoords = jumpSprite.get(0);\r\n\t\t\t\tspriteImg = new Rect(coords.left,coords.top,coords.right,coords.bottom);\r\n\t\t\t\tactualImg = new Rect(x, y, x + width, y + height);\r\n\t\t\t\tspriteX++;\r\n\t\t\t\tbreak;\r\n\t\t}\r\n\t}", "int indexOfSpriteThatCollided(Array<? extends Sprite> sprites, Sprite sprite);", "private void initSprites(){\r\n try\r\n {\r\n spriteSheet = ImageIO.read (spriteSheetFile);\r\n }\r\n catch (IOException e)\r\n {\r\n System.out.println(\"SPRITE spritesheet not found\");\r\n } \r\n try\r\n {\r\n iconSheet=ImageIO.read(playerIconFile);\r\n }\r\n catch (IOException e)\r\n {\r\n System.out.println(\"PLAYERICON spritesheet not found\");\r\n } \r\n\r\n // saves images to array\r\n for(int i=0;i<3;i++){\r\n bomb[i]=new BufferedImage(32,32,BufferedImage.TYPE_INT_ARGB); \r\n bomb[i]=spriteSheet.getSubimage(i*32,6,32,32);\r\n }\r\n for(int i=0;i<4;i++){\r\n icons[i] = new BufferedImage(30,30,BufferedImage.TYPE_INT_ARGB);\r\n icons[i] = iconSheet.getSubimage(0, 31*i, 30, 30);\r\n }\r\n }", "public JewelSprite(int type, int x, int y) {\n\t this.type = type;\n\t setxPos(x);\n\t setyPos(y);\n\n\t String imagePath = \"/\" + Integer.toString(type) + \".png\";\n\t jewelImage = new Image(Jewel.class.getResourceAsStream(imagePath));\n\t ImageView jewelImageView = new ImageView();\n\t jewelImageView.setImage(jewelImage);\n\t jewelImageView.setStyle(\"-fx-background-color:transparent;\");\n\n\t setNode(jewelImageView);\n\t }", "public void resetSprites() {\n\t\tSPRITE_LIST.clear();\n\t}", "private void updateSprites() {\n\t\tpaddle1.setX(paddle1X);\r\n\t\tpaddle1.setY(paddle1Y);\r\n\r\n\t\tpaddle2.setX(paddle2X);\r\n\t\tpaddle2.setY(paddle2Y);\r\n\r\n\t\tball.setX(ballX);\r\n\t\tball.setY(ballY);\r\n\r\n\t\tscore.setVisible(paused);\r\n\t}", "@Override\n public void draw(Batch batch) {\n batch.draw(sprite.getTexture(),\n this.position.x * Game.UNIT_SCALE,\n this.position.y * Game.UNIT_SCALE,\n sprite.getWidth() / 2 * Game.UNIT_SCALE,\n sprite.getHeight() / 2 * Game.UNIT_SCALE,\n this.sprite.getWidth() * Game.UNIT_SCALE,\n this.sprite.getHeight() * Game.UNIT_SCALE,\n 1.0f,\n 1.0f,\n 0,\n sprite.getRegionX(),\n sprite.getRegionY(),\n sprite.getRegionWidth(),\n sprite.getRegionHeight(),\n isFlipped, false\n );\n\n if (Game.getDebugMode()) {\n batch.draw(debug.getTexture(),\n this.position.x * Game.UNIT_SCALE,\n this.position.y * Game.UNIT_SCALE,\n aabb.getWidth() / 2 * Game.UNIT_SCALE,\n aabb.getHeight() / 2 * Game.UNIT_SCALE,\n this.aabb.getWidth() * Game.UNIT_SCALE,\n this.aabb.getHeight() * Game.UNIT_SCALE,\n 1.0f,\n 1.0f,\n 0,\n sprite.getRegionX(),\n sprite.getRegionY(),\n sprite.getRegionWidth(),\n sprite.getRegionHeight(),\n isFlipped, false\n );\n }\n }", "public Player() {\n\t\timg = new ImageIcon(\"rick.jpg\");\n\t\tplayer = img.getImage();\n\t\ttileX = 1;\n\t\ttileY = 1;\n\t\tsetCastraveti(0);\n\t}", "public Stage1()\n { \n // Create a new world with 600x400 cells with a cell size of 1x1 pixels.\n super(1200, 900, 1);\n \n GreenfootImage image = getBackground();\n image.setColor(Color.BLACK);\n image.fill();\n star();\n \n \n \n //TurretBase turretBase = new TurretBase();\n playerShip = new PlayerShip();\n scoreDisplay = new ScoreDisplay();\n addObject(scoreDisplay, 100, 50);\n addObject(playerShip, 100, 450);\n \n }", "void defaultsetup(int phi) \n {// The Images should be loded here... Also add labels here\n System.out.println(\"IN DEFAULT SETUP..\");\n if( phi == 0) \n whiteToPlay = true;\n else if (phi == 1) \n whiteToPlay = false;\n // White Chess Pieces\n whiteHorse1.position = 1; whiteHorse1.color = 0;\n whiteHorse2.position = 6; whiteHorse2.color = 0;\n whiteQueen.position = 3; whiteQueen.color = 0;\n whiteKing.position =4 ; whiteKing.color = 0;\n whiteCastle1.position = 0; whiteCastle1.color = 0;\n whiteCastle2.position = 7; whiteCastle2.color = 0;\n whiteBishop1.position = 2; whiteBishop1.color = 0;\n whiteBishop2.position = 5; whiteBishop2.color = 0;\n int y = 8;\n for(int x = 0 ; x < 8; x++)\n {\n whitePawn[x] = new pawn();\n whitePawn[x].position = 8+x;\n whitePawn[x].color = 0;\n }\n //Black Chess Pieces\n blackHorse1.position = 57; blackHorse1.color = 1;\n blackHorse2.position = 62; blackHorse2.color = 1;\n blackQueen.position = 59; blackQueen.color = 1;\n blackKing.position = 60; blackKing.color = 1;\n blackCastle1.position = 56;blackCastle1.color = 1;\n blackCastle2.position = 63;blackCastle2.color = 1;\n blackBishop1.position = 58;blackBishop1.color = 1;\n blackBishop2.position = 61;blackBishop2.color = 1;\n y = 8;\n for(int x = 0 ; x < 8; x++)\n {\n blackPawn[x] = new pawn();\n blackPawn[x].position = 48+x;\n blackPawn[x].color = 1;\n }\n \n this.updatePositions();\n }", "void moveToSprite(Sprite s) {\n _x = s._x;\n _y = s._y;\n }", "public Image sprite(){\n\t\treturn (face);\n\t}", "public void act() \n {\n String worldname = getWorld().getClass().getName();\n if (worldname == \"Level0\")\n setImage(new GreenfootImage(\"vibranium.png\"));\n else if (worldname == \"Level1\")\n setImage(rocket.getCurrentImage());\n setLocation(getX()-8, getY()); \n if (getX() == 0) \n {\n getWorld().removeObject(this);\n }\n \n }", "private void loadSprites() throws IOException {\n \t\tsprites.put(\"fullBin\", ImageIO.read(new File(\"user-trash-full64.png\")));\n \t\tsprites.put(\"emptyBin\", ImageIO.read(new File(\"user-trash64.png\")));\n \t\tsprites.put(\"sysfileLarge\", ImageIO.read(new File(\"sysfile1-48.png\")));\n \t\tsprites.put(\"sysfileMedium\", ImageIO.read(new File(\"sysfile2-32.png\")));\n \t\tsprites.put(\"sysfileSmall\", ImageIO.read(new File(\"sysfile3-16.png\")));\n \t\tsprites.put(\"junk\", ImageIO.read(new File(\"junk.png\")));\n \t\tsprites.put(\"grass\", ImageIO.read(new File(\"grass.jpg\")));\n \t}", "public Phaser(double x, double y, GameComponents.Canvas acanvas)\r\n {\r\n super(x, y, acanvas);\r\n myImage = null;\r\n isPhasing = false;\r\n }", "public native Sprite clone();", "Sprite(float x, float y, float w, float h) {\n _img = createImage(1, 1, RGB);\n _x = x;\n _y = y;\n _w = w;\n _h = h;\n _rotVector = new PVector(1, 0, 0);\n resetRectHitbox();\n }", "public int getLength () { return spriteLength; }", "private void setSpritesPosition()\r\n\t{\r\n\t\tfloat w = Gdx.graphics.getWidth();\r\n\t\tfloat h = Gdx.graphics.getHeight();\r\n\t\t\r\n\t\tsetX(camera.position.x-camera.viewportWidth/2 + 0.1f * camera.viewportWidth/2);\r\n\t\tsetY(camera.position.y + camera.viewportHeight/2 - 0.15f*w/h* camera.viewportHeight/2);\r\n\t\theroHealth.setX(getX());\r\n\t\theroHealth.setY(getY());\r\n\t\t\r\n\t\tcover.setX(getX() + 10f/270f * heroHealth.getWidth());\r\n\t\tcover.setY(getY());\r\n\t\t\r\n\t}", "@Override\n\tpublic void move() {\n\t\tx += ((direction) * xSpeed);\n\t\t//If any sprite has collided with the left or right edge of the screen set collided to true\n\t\tif (x >= 800 - spriteImage.getWidth(null) || x <= 0) collided = true;\n\t}", "public Sprite(String newSpriteLocation){\n\t\timages = new Texture[1];\n\t\timages[0] = new Texture(newSpriteLocation);\n\t}", "public void removeSprite(Sprite s) {\n this.sprites.removeSprite(s);\n }", "public Boat() {\n batch = new SpriteBatch();\n }", "GameObject(int x, int y){\n loadSprite();\n this.x = x;\n this.y = y;\n }", "private void populateFromSprite() {\n long start = System.currentTimeMillis();\n int bitSetIndex = 0;\n BufferedImage bImage = (BufferedImage) sprite.m_image;\n //BufferedImage img = ImageIO.read(new File(\"assets/LoopBitmap.bmp\"));\n int color;\n // Loop through image according to scale\n for(int i = 0; i < sprite.getWidth(); i+=scale) {\n for(int j = 0; j < sprite.getHeight(); j+= scale) {\n // Get color at pixel i, j, if black set Bitmap index to true.\n color = bImage.getRGB(i, j);\n if(color == Color.BLACK.getRGB()) { //tempColor.equals(Color.black)) {\n this.set(bitSetIndex, true);\n //System.out.println(\"'BLACK' Color = \"+color + \" i=\"+ i + \", j=\"+j);\n }\n bitSetIndex++;\n }\n }\n long end = System.currentTimeMillis();\n// System.out.println(\">>>>>>>>>>>>>>>>>>>>>>>>>>>>\");\n// System.out.println(\"BITMAP DONE :)\");\n// System.out.println(\"Time to build = \"+(end-start)+\"ms\");\n// System.out.println(\">>>>>>>>>>>>>>>>>>>>>>>>>>>>\");\n }", "public Sprite(String pathname) throws IOException {\n\t\tBufferedImage img = ImageIO.read(new File(pathname));\n\t\tint nbcol = img.getWidth() / SPRITE_WIDTH;\n\t\tint nblig = img.getHeight() / SPRITE_HEIGHT;\n\t\tm_length = nblig * nbcol;\n\t\tm_sprites = new BufferedImage[m_length];\n\t\tfor (int i = 0; i < m_length; i++) {\n\t\t\tint x = i % nbcol;\n\t\t\tint y = i / nbcol;\n\t\t\tm_sprites[i] = img.getSubimage(x * SPRITE_WIDTH, y * SPRITE_HEIGHT, SPRITE_WIDTH, SPRITE_HEIGHT);\n\t\t}\n\t}", "private void circleCollison() {\n\t\t\n\t}", "@Override\n\tpublic void show() {\n\t backgroundImage = new Texture(Gdx.files.internal(\"resources/images/menu.png\"));\n\t soccerImage = new Texture(Gdx.files.internal(\"resources/images/ball.gif\"));\n\t boomerangImage = new Texture(Gdx.files.internal(\"resources/images/boomerang.gif\"));\n\t wolfImage = new Texture(Gdx.files.internal(\"resources/images/wolf.gif\"));\n\t boyImage = new Texture(Gdx.files.internal(\"resources/images/bueno2.png\"));\n\t boyImageInv = new Texture(Gdx.files.internal(\"resources/images/bueno2Inv.png\"));\n\t grassImage = new Texture(Gdx.files.internal(\"resources/images/piso.png\"));\n\t \n\n\t // load the drop sound effect and the rain background \"music\"\n\t dropSound = Gdx.audio.newSound(Gdx.files.internal(\"resources/drop.wav\"));\n\t rainMusic = Gdx.audio.newMusic(Gdx.files.internal(\"resources/rain.mp3\"));\n\n\t // start the playback of the background music immediately\n\t rainMusic.setLooping(true);\n\t //rainMusic.play();\n\n\t // create the camera and the SpriteBatch\n\t camera = new OrthographicCamera();\n\t camera.setToOrtho(false, 800, 480);\n\t batch = new SpriteBatch();\n\n\t // create a Rectangle to logically represent the boy\n\t boy = new Rectangle();\n\t boy.x = 130; //800 / 2 - 50 / 2; // center the boy horizontally\n\t boy.y = 235; // just above the ground\n\t boy.width = 50;\n\t boy.height = 74;\n\t \n\t //boy2\n\t boy2 = new Rectangle();\n\t boy2.x = 130;\n\t boy2.y = 160; \n\t boy2.width = 50;\n\t boy2.height = 74;\n\t \n\t //create a grass Rectangle to represent the grass\n\t grass = new Rectangle();\n\t grass.x = 0;\n\t grass.y = camera.viewportHeight/2-30;\n\t \n\t grass2 = new Rectangle();\n\t grass2.x = camera.viewportWidth;\n\t grass2.y = camera.viewportHeight/2-30;\n\t \n\t velocidad = 8;\n\t counterGravity = 0.0;\n\t \n\t countObjs = 1;\n\t //stateTime = 0;\n\n\t // create the soccerballs array and spawn the first soccer ball\n\t soccerballs = new Array<Rectangle>();\n\n\t //create the boomerans array and spawn the first boomerang\n\t boomerangs = new Array<Rectangle>();\n\t \n\n\t spawnBoomerangs();\n\t spawnSoccerBall();\n\t\t\n\t}", "public DebugOverlay(SpriteBatch sb) {\n\n\n viewport = new FitViewport(PixClient.V_WIDTH, PixClient.V_HEIGHT, new OrthographicCamera());\n\n labels = new Label[labelCount];\n\n stage = new Stage(viewport, sb);\n\n Table table = new Table();\n table.bottom().right();\n table.setHeight(300);\n table.setWidth(200);\n table.setPosition(Gdx.graphics.getWidth() - table.getWidth(), 0);\n\n\n\n for(int i = 0; i < labelCount; i++) {\n\n labels[i] = new Label(\"\", new Label.LabelStyle(new BitmapFont(), Color.WHITE));\n table.add(labels[i]).right();\n table.row();\n\n }\n\n Pixmap pixmap = new Pixmap(1, 1, Pixmap.Format.RGBA8888);\n pixmap.setColor(0, 0, 0, 0.75f);\n pixmap.fill();\n\n table.setBackground(new TextureRegionDrawable(new TextureRegion(new Texture(pixmap) ) ) );\n stage.addActor(table);\n }", "public void func_180435_a(TextureAtlasSprite p_180435_1_) {\n/* 215 */ int var2 = getFXLayer();\n/* */ \n/* 217 */ if (var2 == 1) {\n/* */ \n/* 219 */ this.particleIcon = p_180435_1_;\n/* */ }\n/* */ else {\n/* */ \n/* 223 */ throw new RuntimeException(\"Invalid call to Particle.setTex, use coordinate methods\");\n/* */ } \n/* */ }", "public native Sprite copy(Sprite sprite);", "public DumbEnemy(){\n setImage(new GreenfootImage(SPRITE_W,SPRITE_H));\n }", "public void addSprite(Sprite s) {\n sprites.addSprite(s);\n }", "public static void load() {\n\t\tspritesheet = new Spritesheet(\"src/de/kaffeeliebhaber/assets/pyxel/voland_spritesheet_new.png\", 32, 32);\n\t\tspritesheet.load();\n\t\t\n\t\t// load player\n\t\tAssetsLoader.loadPlayerAssets();\n\t\t\n\t\t// load crate\n\t\tAssetsLoader.loadCrates();\n\t\t\n\t\t// load item spritesheet \n\t\tspritesheetInventory = new Spritesheet(Config.ITEM_SPRITESHEET, Config.ITEM_SIZE, Config.ITEM_SIZE);\n\t\tspritesheetInventory.load();\n\t\t\n\t\t// load font \n\t\tloadFonts();\n\t\t\n\t\t// ui\n\t\timageUI = ImageLoader.loadImage(\"src/de/kaffeeliebhaber/assets/ui/ui.png\");\n\t\t\n\t\tAssetsLoader.loadInfoPaneAssets();\n\t\t\n\t\t// npc\n\t\tspritesheetNPC = new Spritesheet(\"src/de/kaffeeliebhaber/assets/AH_SpriteSheet_People1.png\", 16, 16);\n\t\tspritesheetNPC.load();\n\t\t\n\t\t// fox\n\t\tspritesheetNPCFox = new Spritesheet(\"src/de/kaffeeliebhaber/assets/imgs/72c68863962b7a6b5a9f5f5bcc5afb16.png\", 32, 32);\n\t\tspritesheetNPCFox.load();\n\n\t\t// *** LOAD NPCs\n\t\tAssetsLoader.loadFoxAssets();\n\t\t\n\t\tAssetsLoader.loadNPCs();\n\t\t\n\t\tspritesheetFemale = new Spritesheet(\"src/de/kaffeeliebhaber/assets/imgs/Female 01-1.png\", 32, 32);\n\t\tspritesheetFemale.load();\n\t}", "public void movement(){\n\t\t\n\t\tdelayCounter++;\n\t\t\n\t\tif(direction == Direction.RIGHT){\n\t\t\txCoor += 1;\n\t\t\tbound.x = xCoor+30;\n\t\t\t\n\t\t\tif ( image == Assets.enemySprite[0] && delayCounter >= delay ){\n\t\t\t\timage = Assets.enemySprite[1];\n\t\t\t\tdelayCounter = 0;\n\t\t\t}\n\t\t\telse if ( image == Assets.enemySprite[1] && delayCounter >= delay ){\n\t\t\t\timage = Assets.enemySprite[2];\n\t\t\t\tdelayCounter = 0;\n\t\t\t}\n\t\t\telse if ( image == Assets.enemySprite[2] && delayCounter >= delay ){\n\t\t\t\timage = Assets.enemySprite[0];\n\t\t\t\tdelayCounter = 0;\n\t\t\t}\n\t\t}\n\t\tif(direction == Direction.LEFT){\n\t\t\txCoor -= 1;\n\t\t\tbound.x = xCoor+30;\n\t\t\t\n\t\t\tif ( image == Assets.enemySprite[3] && delayCounter >= delay ){\n\t\t\t\timage = Assets.enemySprite[4];\n\t\t\t\tdelayCounter = 0;\n\t\t\t}\n\t\t\telse if ( image == Assets.enemySprite[4] && delayCounter >= delay ){\n\t\t\t\timage = Assets.enemySprite[5];\n\t\t\t\tdelayCounter = 0;\n\t\t\t}\n\t\t\telse if ( image == Assets.enemySprite[5] && delayCounter >= delay ){\n\t\t\t\timage = Assets.enemySprite[3];\n\t\t\t\tdelayCounter = 0;\n\t\t\t}\n\t\t}\n\t\telse if(direction == Direction.UPWARD){\n\t\t\tyCoor += 1;\n\t\t\tbound.y = yCoor+30;\n\t\t\t\n\t\t\tif ( image == Assets.enemySprite[10] && delayCounter >= delay ){\n\t\t\t\timage = Assets.enemySprite[11];\n\t\t\t\tdelayCounter = 0;\n\t\t\t}\n\t\t\telse if ( image == Assets.enemySprite[11] && delayCounter >= delay ){\n\t\t\t\timage = Assets.enemySprite[10];\n\t\t\t\tdelayCounter = 0;\n\t\t\t}\n\t\t}\n\t\telse if(direction == Direction.DOWNWARD){\n\t\t\tyCoor -= 1;\n\t\t\tbound.y = yCoor+30;\n\t\t\t\n\n\t\t\tif ( image == Assets.enemySprite[6] && delayCounter >= delay ){\n\t\t\t\timage = Assets.enemySprite[7];\n\t\t\t\tdelayCounter = 0;\n\t\t\t}\n\t\t\telse if ( image == Assets.enemySprite[7] && delayCounter >= delay ){\n\t\t\t\timage = Assets.enemySprite[8];\n\t\t\t\tdelayCounter = 0;\n\t\t\t}\n\t\t\telse if ( image == Assets.enemySprite[8] && delayCounter >= delay ){\n\t\t\t\timage = Assets.enemySprite[6];\n\t\t\t\tdelayCounter = 0;\n\t\t\t}\n\t\t}\n\t\t\t\n\t\tenemyWalk += 1;\n\t\t\n\t\t//This parts checks to see if the enemy has to turn or not.\n\t\tif(enemyWalk == screen.maps[screen.currentMap].path.getTileWidth()){\n\t\t\tint x = xCoor;\n\t\t\tint y = yCoor;\n\t\t\t\n\t\t\tif(direction == Direction.RIGHT){\n\t\t\t\tx = xCoor + 1;\n\t\t\t\tprevious = direction;\n\t\t\t}\n\t\t\tif(direction == Direction.LEFT){\n\t\t\t\tx = xCoor - 1;\n\t\t\t\tprevious = direction;\n\t\t\t}\n\t\t\tif(direction == Direction.UPWARD){\n\t\t\t\ty = yCoor + 1;\n\t\t\t\tprevious = direction;\n\t\t\t}\n\t\t\tif(direction == Direction.DOWNWARD){\n\t\t\t\ty = yCoor - 1;\n\t\t\t\tprevious = direction;\n\t\t\t}\n\t\t\t\n\t\t\tint tileBlockX = (int) (x/screen.maps[screen.currentMap].path.getTileWidth());\n\t\t\tint tileBlockY = (int) (y/screen.maps[screen.currentMap].path.getTileHeight());\n\t\t\t\n\t\t\t//As long as the enemy has not gone the opposite direction, the enemy will continue to move in the direction is was going originally.\n\t\t\tif(tileBlockX < screen.maps[screen.currentMap].path.getWidth()-1 && tileBlockX > 0){\n\t\t\t\tif(tileBlockY < screen.maps[screen.currentMap].path.getHeight()-1 && tileBlockY > 0){\n\t\t\t\t\tif(screen.maps[screen.currentMap].path.getCell(tileBlockX, tileBlockY + 1).getTile().getProperties().containsKey(\"ground\") == true && previous != Direction.DOWNWARD){\n\t\t\t\t\t\tdirection = Direction.UPWARD;\n\t\t\t\t\t\timage = Assets.enemySprite[10];\n\t\t\t\t\t}\n\t\t\t\t\tif(screen.maps[screen.currentMap].path.getCell(tileBlockX, tileBlockY - 1).getTile().getProperties().containsKey(\"ground\") == true && previous != Direction.UPWARD){\n\t\t\t\t\t\tdirection = Direction.DOWNWARD;\n\t\t\t\t\t\timage = Assets.enemySprite[6];\n\t\t\t\t\t}\n\t\t\t\t\tif(screen.maps[screen.currentMap].path.getCell(tileBlockX + 1, tileBlockY).getTile().getProperties().containsKey(\"ground\") == true && previous != Direction.LEFT){\n\t\t\t\t\t\tdirection = Direction.RIGHT;\n\t\t\t\t\t\timage = Assets.enemySprite[0];\n\t\t\t\t\t}\n\t\t\t\t\tif(screen.maps[screen.currentMap].path.getCell(tileBlockX - 1, tileBlockY).getTile().getProperties().containsKey(\"ground\") == true && previous != Direction.RIGHT){\n\t\t\t\t\t\tdirection = Direction.LEFT;\n\t\t\t\t\t\timage = Assets.enemySprite[3];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t//If the enemy makes it to the end, it is no longer in game.\n\t\t\tif(screen.maps[screen.currentMap].path.getCell(tileBlockX, tileBlockY).getTile().getProperties().containsKey(\"finish\") == true){\n\t\t\t\tinGame = false;\n\t\t\t\tscreen.playerHealth--;\n\t\t\t}\n\t\t\t\n\t\t\tenemyWalk = 0;\n\t\t}\n\t}", "public void boom() {\n\t\tboom.setPosition(sprite.getX(),sprite.getY());\n\t\tsprite = boom;\n\t}", "public void moveLeft() {\r\n speedX = -6;\r\n Texture r1 = changeImg (\"./graphics/characters/player/leftWalk1.png\");\r\n img = new Sprite (r1);\r\n }", "public void blit() {}", "public void handle(long currentNanoTime)\n {\n double elapsedTime = (currentNanoTime - lastNanoTime.value) / 1000000000.0;\n lastNanoTime.value = currentNanoTime;\n\n\n // Lógica do Jogo\n\n darion.setVelocity(0,0);\n if (input.contains(\"LEFT\")){\n \n darion.setImage(\"darionesq.png\");\n \n darion.addVelocity(-50,0);\n \n \n } \n \n if (input.contains(\"RIGHT\")){\n darion.setImage(\"dariondir.png\");\n darion.addVelocity(50,0);\n } \n if (input.contains(\"UP\")){\n darion.setImage(\"dariontras.png\");\n darion.addVelocity(0,-50);\n } \n if (input.contains(\"DOWN\")){\n darion.setImage(\"darionfrente.png\");\n darion.addVelocity(0,50);\n } \n\n\n darion.update(elapsedTime);\n \n\n \n\n // Detecta as colisões com a lixeira\n\n Iterator<Sprite> lixoIter = lixoList.iterator();\n Iterator<Sprite> mudaIter = mudaList.iterator();\n \n while ( lixoIter.hasNext())\n {\n Sprite lixo = lixoIter.next();\n //Sprite muda = mudaIter.next();\n if ( darion.intersects(lixo))\n {\n lixoIter.remove();\n score.value++;\n s.clip_lixo.play(99);\n \n if(lixoList.isEmpty() == true){\n // define a tela de fundo e seus respectivos sons\n //darion.setImage(\"fundo2.jpg\");\n darion.setPosition(0, 0);\n s.clip.stop();\n s.clip3.stop();\n //s.clip_Parabens.play();\n s.clip_Corr.play();\n s.clip_Finale.play();\n \n Alert dialogoInfo = new Alert(Alert.AlertType.INFORMATION);\n \n dialogoInfo.setTitle(\"As Aventuras de Darion\");\n dialogoInfo.setHeaderText(\"Parabéns... Sua Pontuação foi >>>>>>>>> \"+ (100 * score.value)+\" <<<<<<<<<\");\n String version = System.getProperty(\"java.version\");\n String content = String.format(\"Parabéns !!! Você conseguiu a preservar a natureza !!!! Lembre-se devemos sempre preservar o meio ambiente, para que futuras gerações também se beneficie dos benefícios do meio ambiente !!! Para Finalizar o Jogo pressione 'ESC' !!! Para começar um novo Jogo pressione 'N' !!!\",version);\n dialogoInfo.setContentText(content);\n dialogoInfo.getDialogPane().setMinHeight(Region.USE_PREF_SIZE);\n dialogoInfo.setResizable(true);\n dialogoInfo.show();\n \n \n \n ////////////////////////////////////// \n }\n\n\n }\n\n }\n while ( mudaIter.hasNext())\n {\n //Sprite lixo = lixoIter.next();\n Sprite muda = mudaIter.next();\n if ( darion.intersects(muda))\n {\n mudaIter.remove();\n score.value--;\n s.clip_Erro.play(99);\n \n\n }\n\n }\n \n \n\n\n // renderiza as atualizações\n gc.clearRect(0, 0, 700,500);\n gc.drawImage( space, 0, 0 );\n darion.render( gc );\n\n\n for (Sprite lixo : lixoList ){\n lixo.render( gc );}\n for (Sprite muda : mudaList ){\n muda.render( gc );}\n \n \n \n // cria e mostra na tela o nome e a pontuação\n String pointsText = \"Score: \" + (100 * score.value);\n gc.fillText( pointsText, 10, 81 );\n gc.strokeText( pointsText, 10, 81 );\n \n String nText = \"Novo Jogo\";\n gc.fillText( nText, 473, 39 );\n gc.strokeText( nText, 473, 39 );\n\n String Text = \"Sair\";\n gc.fillText( Text, 745, 39 );\n gc.strokeText( Text, 745, 39 );\n \n String help = \"Ajuda\";\n gc.fillText( help, 745, 91 );\n gc.strokeText( help, 745, 91 );\n\n String TituloText = \"As Aventuras de Darion\";\n gc.fillText( TituloText, 10, 39 );\n gc.strokeText( TituloText, 10, 39 );\n\n if(lixoList.isEmpty() == true){\n // define a tela de fundo e seus respectivos sons\n \n darion.setPosition(650, 230);\n \n \n String pText = \" !!!!!!! Jogo Finalizado !!!!!!\";\n gc.fillText( pText, 250, 250 );\n gc.strokeText( pText, 250, 250 );\n \n score.value=0;\n \n }\n\n }", "public StoneSummon() {\n// ArrayList<BufferedImage> images = SprssssssaasssssaddddddddwiteUtils.loadImages(\"\"\n createStones();\n\n }", "public static void load(){\r\n\t \ttry {\r\n\t \t\t// load and set all sprites\r\n\t\t\t\tsetBlueGarbage(ImageIO.read(classPath.getResourceAsStream(\"/images/blueGarbage.png\")));\r\n\t\t\t\tsetRank(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/rank.png\")));\r\n\t\t\t\tsetRedGarbage(ImageIO.read(classPath.getResourceAsStream(\"/images/redGarbage.png\")));\r\n\t\t\t\tsetYellowGarbage(ImageIO.read(classPath.getResourceAsStream(\"/images/yellowGarbage.png\")));\r\n\t\t\t\tsetGreenGarbage(ImageIO.read(classPath.getResourceAsStream(\"/images/greenGarbage.png\")));\r\n\t\t\t\tsetBlueSnakeBodyPart(ImageIO.read(classPath.getResourceAsStream(\"/images/blueSnakeBodyPart.png\")));\r\n\t\t\t\tsetRedSnakeBodyPart(ImageIO.read(classPath.getResourceAsStream(\"/images/redSnakeBodyPart.png\")));\r\n\t\t\t\tsetYellowSnakeBodyPart(ImageIO.read(classPath.getResourceAsStream(\"/images/yellowSnakeBodyPart.png\")));\r\n\t\t\t\tsetGreenSnakeBodyPart(ImageIO.read(classPath.getResourceAsStream(\"/images/greenSnakeBodyPart.png\")));\r\n\t\t\t\tsetHeart(ImageIO.read(classPath.getResourceAsStream(\"/images/heart.png\")));\r\n\t\t\t\tsetGameScreenBackground(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/gameScreenBackground.png\")));\r\n\t\t\t\tsetGameScreenHeader(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/gameScreenHeader.png\")));\r\n\t\t\t\tsetGameOver(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/gameOver.png\")));\r\n\t\t\t\tsetHitsOwnBody(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/hitsOwnBody.png\")));\r\n\t\t\t\tsetHitsWall(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/hitsWall.png\")));\r\n\t\t\t\tsetWrongColor(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/wrongColor.png\")));\r\n\t\t\t\tsetHelpScreenBackground(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/helpScreenBackground.png\")));\r\n\t\t\t \tsetWarningScreenBackground(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/warningScreenBackground.png\")));\r\n\t\t\t \tsetOkButton(ImageIO.read(classPath.getClass().getResource(\"/images/okButton.png\")));\r\n\t\t\t \tsetMenuScreenBackground(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/menuScreenBackground.png\")));\r\n\t\t\t\tsetStartButton(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/startButton.png\")));\r\n\t\t\t\tsetExitButton(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/exitButton.png\")));\r\n\t\t\t\tsetHelpButton(ImageIO.read(classPath.getClass().getResourceAsStream(\"/images/helpButton.png\")));\r\n\t\t\t\t\r\n\t \t} \r\n\t \tcatch (Exception e) {\r\n\t\t\t\tJOptionPane.showMessageDialog(null, e.getStackTrace(), \"Erro ao carregar imagens\", JOptionPane.ERROR_MESSAGE);\r\n\t\t\t\tSystem.exit(0);\r\n\t\t\t\r\n\t\t\t}\t\r\n \t\r\n \t}", "@Override\r\n\tpublic void command() {\n\t\tShape r = new Rectangle(0, 0, p.getImage().getWidth(), p.getImage().getHeight());\r\n\t\tr.setCenterX(p.getLoc().x + dx);\r\n\t\tr.setCenterY(p.getLoc().y + dy);\r\n\t\tSystem.out.println(commandBlockType);\r\n\t\tif (!m.isColliding(r)) {\r\n\t\t\tp.setColliding(false);\r\n\t\t\tp.getLoc().x+=dx;\r\n\t\t\tp.getLoc().y+=dy;\r\n\t\t} else {\r\n\t\t\tp.setColliding(true);\r\n\t\t}\r\n\t}", "public zombie_bg()\n { \n // Create a new world with 600x400 cells with a cell size of 1x1 pixels.\n super(1010,900, 1); \n setPaintOrder(ScoreBoard.class, player.class, zomb_gen.class, options.class);\n populate();\n \n }", "@Override\n protected void paintComponent(Graphics g) {\n super.paintComponent(g);\n g.drawImage(image, 1, 0, null); \n g.drawImage(player, 1, 0, null); \n \n }", "@Override\n public void paintComponent(Graphics g){\n super.paintComponent(g);\n if(ingame){\n\n int screenWidth = this.getWidth();\n int screenHeight = this.getHeight();\n\n\n for(int i = 0; i < end_positions.size(); i++){\n End_position item = end_positions.get(i);\n g.setColor(Color.green);\n g.fillRect(item.getDestinationX()*screenWidth/LEVEL_WIDTH,item.getDestinationY()*screenHeight/LEVEL_HEIGHT,item.getImage().getWidth(null)*screenWidth/LEVEL_WIDTH,item.getImage().getWidth(null)*screenHeight/LEVEL_HEIGHT);\n }\n\n g.setColor(Color.white);\n g.fillRect(player.getCurrentX()*screenWidth/LEVEL_WIDTH,player.getCurrentY()*screenHeight/LEVEL_HEIGHT,player.getImage().getWidth(null)*screenWidth/LEVEL_WIDTH,player.getImage().getWidth(null)*screenHeight/LEVEL_HEIGHT);\n\n\n for(int i = 0; i < boxes.size(); i++){\n Box item = boxes.get(i);\n g.setColor(Color.yellow);\n g.fillRect(item.getCurrentX()*screenWidth/LEVEL_WIDTH,item.getCurrentY()*screenHeight/LEVEL_HEIGHT,item.getImage().getWidth(null)*screenWidth/LEVEL_WIDTH,item.getImage().getWidth(null)*screenHeight/LEVEL_HEIGHT);\n }\n for(int i = 0; i < walls.size(); i++){\n Wall item = walls.get(i);\n\n g.setColor(Color.red);\n g.fillRect(item.getDestinationX()*screenWidth/LEVEL_WIDTH,item.getDestinationY()*screenHeight/LEVEL_HEIGHT,item.getImage().getWidth(null)*screenWidth/LEVEL_WIDTH,item.getImage().getWidth(null)*screenHeight/LEVEL_HEIGHT);\n\n }\n\n }\n\n }", "public GameObject(String name, int x, int y) {\n this.image = GameObject.processing.loadImage(\"images\" + File.separator + name + \".png\");\n this.xPosition = x;\n this.yPosition = y;\n this.active = true;\n }", "private void setSprite(String filepath){\n try {\n this.sprite = new Sprite(new Texture(Gdx.files.internal(filepath)));\n }\n catch (Exception e){\n }\n }", "public void draw(GameCanvas canvas){\n if(tags.length > 0 && body != null){\n FilmstripAsset fa;\n float angle = (float)((getBody().getAngle() + Math.PI * 4) % (Math.PI * 2));\n\n if (isDead) {\n ImageAsset ia = (ImageAsset) assetMap.get(tags[4]);\n Affine2 aff = new Affine2();\n aff.setToRotationRad((float)(deadAngle + Math.PI/2));\n aff.preScale(ia.getImageScale().x,ia.getImageScale().y * 0.6f );\n aff.preTranslate(body.getPosition().x * drawScale.x, body.getPosition().y*drawScale.y);\n canvas.draw(ia.getTexture(), Color.WHITE, ia.getOrigin().x, ia.getOrigin().y,aff);\n return;\n }\n\n if (isSecondStage){\n fa = (FilmstripAsset) assetMap.get(tags[3]);\n }\n else if(angle <= Math.PI*0.25f || angle > Math.PI*1.75f){\n fa = (FilmstripAsset) assetMap.get(tags[1]);\n }\n else if(angle <= Math.PI*0.75f && angle > Math.PI*0.25f){\n fa = (FilmstripAsset) assetMap.get(tags[2]);\n }\n else if(angle <= Math.PI*1.25f && angle > Math.PI*0.75f){\n fa = (FilmstripAsset) assetMap.get(tags[0]);\n }\n else {\n fa = (FilmstripAsset) assetMap.get(tags[3]);\n }\n\n if(fa != null){\n int nFrame = (GameObject.counter / fa.getSpeed()) % fa.getNumFrames();\n TextureRegion texture = fa.getTexture(nFrame/2);\n\n Affine2 aff = new Affine2();\n aff.setToScaling(fa.getImageScale().x * 1, fa.getImageScale().y * 0.7f);\n aff.preShear(-0.2f, 0);\n aff.preTranslate((body.getPosition().x)* drawScale.x - fa.getImageScale().x * fa.getTexture(nFrame/2).getRegionWidth() * 0.05f , (body.getPosition().y -0.2f ) * drawScale.y - fa.getTexture(nFrame/2).getRegionHeight() * fa.getImageScale().y * 0.05f);\n canvas.draw(fa.getTexture(nFrame/2), new Color(0,0,0,0.5f), fa.getOrigin().x, fa.getOrigin().y, aff);\n\n canvas.draw(texture, Color.WHITE,fa.getOrigin().x,fa.getOrigin().y,body.getPosition().x*drawScale.x,body.getPosition().y*drawScale.x,0,fa.getImageScale().x,fa.getImageScale().y);\n }\n }\n }", "public static void loadBg() {\n bg = new Texture (Gdx.files.internal(\"data/bbb.png\"));\n textureBg =new TextureRegion(bg);\n player = new Texture (Gdx.files.internal(\"data/nave2.png\"));\n texturePlayer =new TextureRegion(player);\n gameOver = new Texture (Gdx.files.internal(\"data/gameOver.png\"));\n textureGameOver =new TextureRegion(gameOver);\n textureGameOver.flip(false, true);\n laser= new Texture (Gdx.files.internal(\"data/disparo_sprite.png\"));\n textureLaser = new TextureRegion(laser);\n obstacle= new Texture (Gdx.files.internal(\"data/square.gif\"));\n textureObstacle = new TextureRegion(obstacle);\n title= new Texture (Gdx.files.internal(\"data/invadpt2.png\"));\n textureTitle = new TextureRegion(title);\n win = new Texture (Gdx.files.internal(\"data/win.png\"));\n textureWin =new TextureRegion(win);\n textureWin.flip(false, true);\n ranking = new Texture (Gdx.files.internal(\"data/ranking.png\"));\n textureRanking =new TextureRegion(ranking);\n textureRanking.flip(false, true);\n ranking1 = new Texture (Gdx.files.internal(\"data/ranking1.png\"));\n textureRanking1 =new TextureRegion(ranking1);\n textureRanking1.flip(false, true);\n ranking2 = new Texture (Gdx.files.internal(\"data/ranking2.png\"));\n textureRanking2 =new TextureRegion(ranking2);\n textureRanking2.flip(false, true);\n superEnemy= new Texture (Gdx.files.internal(\"data/superEnemy.png\"));\n textureSuperEnemy = new TextureRegion(superEnemy);\n textureSuperEnemy.flip(false, true);\n\n text1=new Texture(Gdx.files.internal(\"data/bg.jpg\"));\n text2 = new TextureRegion(text1);\n text= new TextureAtlas();\n text.addRegion(\"text\",text2);\n text.addRegion(\"text\",text1,0,0,20,30);\n loadColorInvaders();\n\n\n }", "public void addSprite(Sprite s) {\r\n this.sprites.addSprite(s);\r\n }", "public void act() \n {\n move(4); \n collision();\n \n \n }", "@Override\r\n public void init() {\n Image bgImage = assets().getImage(\"images/bg.png\");\r\n ImageLayer bgLayer = graphics().createImageLayer(bgImage);\r\n graphics().rootLayer().add(bgLayer);\r\n\r\n // Create tiles\r\n tiles = new int[BOARD_MAX_WIDTH][BOARD_MAX_HEIGHT];\r\n printTiles();\r\n\r\n // Place mines at random positions\r\n int placedMines = 0;\r\n Random r = new Random();\r\n while (placedMines < MINES) {\r\n int row = r.nextInt(BOARD_MAX_WIDTH);\r\n int col = r.nextInt(BOARD_MAX_HEIGHT);\r\n if (tiles[row][col] == TILE_EMPTY) {\r\n tiles[row][col] = TILE_MINE;\r\n placedMines++;\r\n }\r\n }\r\n printTiles();\r\n\r\n // Count number of mines around blank tiles\r\n for (int row = 0; row < BOARD_MAX_WIDTH; row++) {\r\n for (int col = 0; col < BOARD_MAX_WIDTH; col++) {\r\n // Check surrounding tiles if mine\r\n if (tiles[row][col] == TILE_MINE) {\r\n for (int rowCheck = -1; rowCheck <= 1; rowCheck++) {\r\n for (int colCheck = -1; colCheck <= 1; colCheck++) {\r\n if (tileExistAndNotMine(row+rowCheck, col+colCheck)) {\r\n tiles[row+rowCheck][col+colCheck]++;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n printTiles();\r\n\r\n // Create tile map\r\n Map<Integer, TileType> tileMap = new HashMap<Integer, TileType>();\r\n tileMap.put(0, TileType.EMPTY);\r\n tileMap.put(1, TileType.ONE);\r\n tileMap.put(2, TileType.TWO);\r\n tileMap.put(3, TileType.THREE);\r\n tileMap.put(4, TileType.FOUR);\r\n tileMap.put(5, TileType.FIVE);\r\n tileMap.put(6, TileType.SIX);\r\n tileMap.put(7, TileType.SEVEN);\r\n tileMap.put(8, TileType.EIGHT);\r\n tileMap.put(9, TileType.MINE);\r\n\r\n // Create a GroupLayer to hold the sprites\r\n GroupLayer groupLayer = graphics().createGroupLayer();\r\n graphics().rootLayer().add(groupLayer);\r\n\r\n // Create graphic tiles\r\n tileList = new ArrayList<Tile>();\r\n for (int row = 0; row < BOARD_MAX_WIDTH; row++) {\r\n for (int col = 0; col < BOARD_MAX_WIDTH; col++) {\r\n Tile tile = new Tile(groupLayer, col*Tile.SIZE, row*Tile.SIZE, tileMap.get(tiles[row][col]), row, col);\r\n tileList.add(tile);\r\n }\r\n }\r\n\r\n // Timer text\r\n CanvasImage canvasImage = graphics().createImage(160, 70);\r\n timerLabel = canvasImage.canvas();\r\n ImageLayer countDownLayer = graphics().createImageLayer(canvasImage);\r\n countDownLayer.setTranslation(180, 10);\r\n graphics().rootLayer().add(countDownLayer);\r\n\r\n // Cleared tiles text\r\n CanvasImage clearedTilesImage = graphics().createImage(160, 70);\r\n clearedTilesLabel = clearedTilesImage.canvas();\r\n ImageLayer clearedTilesLayer = graphics().createImageLayer(clearedTilesImage);\r\n clearedTilesLayer.setTranslation(180, 30);\r\n graphics().rootLayer().add(clearedTilesLayer);\r\n updateClearedTiles();\r\n }", "private void spawnStuff(PlayScreen screen, float delta) {\n if (stageId!=3 && stageId!=5) {\n isCombatEnabled = true;\n int where;\n boolean spawnRight = true;\n float speed;\n\n\n //Alien Spawn\n if (System.currentTimeMillis() - lastASpawn >= SpawnATimer + extraTimer) {\n speed = (float)(Utils.doRandom(250,400));\n lastASpawn = System.currentTimeMillis();\n int count = 3;\n if (stageId==4) count = 1;\n for (int i = 0; i < count; i++) {\n if (stageId==4){\n speed = (float) (speed*0.75);\n where = Utils.doRandom(0,100);\n if (where < 50){\n spawnRight = true;\n }else{\n spawnRight = false;\n }\n\n }\n if (spawnRight) {\n int x = (int) screen.gameViewport.getWorldWidth();\n int y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - Alien.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x - Alien.width, y, Alien.width, Alien.height)))\n hits = true;\n }\n }\n screen.entities.add(new Alien(new Vector2(x, y), 1, screen.alienImages, speed, screen.player));\n }else{\n int x = 0 - Alien.width;\n int y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - Alien.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x + Alien.width*2 , y, Alien.width, Alien.height)))\n hits = true;\n }\n }\n screen.entities.add(new Alien(new Vector2(x, y), 1, screen.alienImages, speed, screen.player,false));\n }\n }\n }\n //AcidAlien Spawn\n if (System.currentTimeMillis() - lastBSpawn >= SpawnBTimer + extraTimer) {\n speed = 200;\n lastBSpawn = System.currentTimeMillis();\n if (stageId==4){\n speed = speed/2;\n where = Utils.doRandom(0,100);\n if (where < 50){\n spawnRight = true;\n }else{\n spawnRight = false;\n }\n\n }\n if (spawnRight) {\n int x = (int) screen.gameViewport.getWorldWidth();\n int y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - AcidAlien.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x - AcidAlien.width, y, AcidAlien.width, AcidAlien.height)))\n hits = true;\n }\n }\n screen.entities.add(new AcidAlien(new Vector2(x, y), screen.alien2Images, screen.acidImage, speed, screen.player));\n }else{\n int x = 0 - AcidAlien.width;\n int y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - AcidAlien.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x + AcidAlien.width*2, y, AcidAlien.width, AcidAlien.height)))\n hits = true;\n }\n }\n screen.entities.add(new AcidAlien(new Vector2(x, y), screen.alien2Images, screen.acidImage, speed, screen.player,false));\n }\n }\n //FastAlien Spawn\n if (System.currentTimeMillis() - lastCSpawn >= SpawnCTimer + extraTimer) {\n speed= Utils.doRandom(250,400);\n lastCSpawn = System.currentTimeMillis();\n if (stageId==4){\n speed = speed/2;\n where = Utils.doRandom(0,100);\n if (where < 50){\n spawnRight = true;\n }else{\n spawnRight = false;\n }\n\n }\n if (spawnRight) {\n int x = (int) screen.gameViewport.getWorldWidth();\n int y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - FastAlien.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x - FastAlien.width, y, FastAlien.width, FastAlien.height)))\n hits = true;\n }\n }\n screen.entities.add(new FastAlien(new Vector2(x, y), 1, screen.alien3Images,speed, screen.player));\n }else{\n int x = 0 - FastAlien.width;\n int y =0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - FastAlien.height);\n for (int h=0;h<collisions.size();h++){\n if (Collision.checkWalls(collisions.get(h),new Rectangle(x-FastAlien.width*2,y,FastAlien.width,FastAlien.height))) hits = true;\n }\n }\n screen.entities.add(new FastAlien(new Vector2(x, y), 1, screen.alien3Images, speed,screen.player,false));\n }\n\n }\n\n //Item Spawn\n if (System.currentTimeMillis() - lastCapsuleSpawn >= SpawnTimerCapsule ) {\n speed = 500;\n int x = 0;\n int y = 0;\n lastCapsuleSpawn = System.currentTimeMillis();\n if (stageId==4){\n speed = speed/2;\n where = Utils.doRandom(0,100);\n if (where < 50){\n spawnRight = true;\n }else{\n spawnRight = false;\n }\n\n }\n if (spawnRight) {\n x = (int) screen.gameViewport.getWorldWidth();\n y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - BlueBulletItem.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x - BlueBulletItem.width, y, BlueBulletItem.width, BlueBulletItem.height)))\n hits = true;\n }\n }\n }else{\n x = 0 - BlueBulletItem.width;\n y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - BlueBulletItem.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x + BlueBulletItem.width *2, y, BlueBulletItem.width, BlueBulletItem.height)))\n hits = true;\n }\n }\n }\n\n int capsule = screen.random.nextInt(2);\n\n if (capsule == 0) {\n if (spawnRight) {\n screen.items.add(new RedBulletItem(x, y, speed, screen.itemRedImages));\n }else{\n screen.items.add(new RedBulletItem(x, y, speed, screen.itemRedImages,false));\n }\n } else if (capsule == 1) {\n if (spawnRight) {\n screen.items.add(new BlueBulletItem(x, y, speed, screen.itemBlueImages));\n }else{\n screen.items.add(new BlueBulletItem(x, y, speed, screen.itemBlueImages,false));\n }\n }\n\n }\n if (System.currentTimeMillis() - lastHealthSpawn >= SpawnTimerHealth) {\n speed = 500;\n lastHealthSpawn = System.currentTimeMillis();\n if (stageId==4){\n speed = speed/2;\n where = Utils.doRandom(0,100);\n if (where < 50){\n spawnRight = true;\n }else{\n spawnRight = false;\n }\n\n }\n if (spawnRight) {\n int x = (int) screen.gameViewport.getWorldWidth();\n int y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - BlueBulletItem.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x - BlueBulletItem.width, y, BlueBulletItem.width, BlueBulletItem.height)))\n hits = true;\n }\n }\n screen.items.add(new GreenCapsuleItem(x, y, speed, screen.itemGreenImages));\n }else{\n int x = 0 - BlueBulletItem.width;\n int y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - BlueBulletItem.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x + BlueBulletItem.width*2, y, BlueBulletItem.width, BlueBulletItem.height)))\n hits = true;\n }\n }\n screen.items.add(new GreenCapsuleItem(x, y, speed, screen.itemGreenImages,false));\n }\n }\n /*if (System.currentTimeMillis() - lastBombSpawn >= SpawnTimerBomb) {\n lastBombSpawn = System.currentTimeMillis();\n int x = (int) screen.gameViewport.getWorldWidth();\n int y =0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - PurpleCapsuleItem.height);\n for (int h=0;h<collisions.size();h++){\n if (Collision.checkWalls(collisions.get(h),new Rectangle(x,y,PurpleCapsuleItem.width,PurpleCapsuleItem.height))) hits = true;\n }\n }\n screen.items.add(new PurpleCapsuleItem(x, y, 500, screen.itemPurpleImages));\n }*/\n }else{\n if (stageId==3) {\n //SPACE STAGE\n ///SPAWN ENEMY SHIP:\n //TODO\n if (PlayScreen.entities.size() == 1) {\n isCombatEnabled = false;\n //no enemy spawned, so spawn:\n if (spawnIterator >= killCount) {\n //TODO END STAGE\n } else {\n System.out.println(\"SPAWNS SHIP\");\n spawnIterator++;\n screen.entities.add(new EnemyShipOne(new Vector2(0, 0), 100, screen.enemyShipOne, true, screen.player));\n\n }\n }\n //Items:\n //Item Spawn\n if (System.currentTimeMillis() - lastCapsuleSpawn >= SpawnTimerCapsule) {\n lastCapsuleSpawn = System.currentTimeMillis();\n int x = (int) screen.gameViewport.getWorldWidth();\n int y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - BlueBulletItem.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x, y, BlueBulletItem.width, BlueBulletItem.height)))\n hits = true;\n }\n }\n screen.items.add(new BlackBulletItem(x, y, 1000, screen.itemBlackImages));\n\n\n }\n }else{\n if (stageId == 5){\n isCombatEnabled = true;\n float speed;\n boolean spawnRight=true;\n int where=0;\n //TODO FINAL STAGE\n if (!isBossSpawned){\n //TODO\n screen.entities.add(new Boss(new Vector2(PlayScreen.gameViewport.getWorldWidth(),PlayScreen.gameViewport.getWorldHeight()/2 - Boss.height/2),screen.player));\n isBossSpawned=true;\n }\n //Item Spawn\n if (System.currentTimeMillis() - lastCapsuleSpawn >= SpawnTimerCapsule ) {\n speed = 500;\n int x = 0;\n int y = 0;\n lastCapsuleSpawn = System.currentTimeMillis();\n if (stageId==4){\n speed = speed/2;\n where = Utils.doRandom(0,100);\n if (where < 50){\n spawnRight = true;\n }else{\n spawnRight = false;\n }\n\n }\n if (spawnRight) {\n x = (int) screen.gameViewport.getWorldWidth();\n y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - BlueBulletItem.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x - BlueBulletItem.width, y, BlueBulletItem.width, BlueBulletItem.height)))\n hits = true;\n }\n }\n }else{\n x = 0 - BlueBulletItem.width;\n y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - BlueBulletItem.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x + BlueBulletItem.width *2, y, BlueBulletItem.width, BlueBulletItem.height)))\n hits = true;\n }\n }\n }\n\n int capsule = screen.random.nextInt(2);\n\n if (capsule == 0) {\n if (spawnRight) {\n screen.items.add(new RedBulletItem(x, y, speed, screen.itemRedImages));\n }else{\n screen.items.add(new RedBulletItem(x, y, speed, screen.itemRedImages,false));\n }\n } else if (capsule == 1) {\n if (spawnRight) {\n screen.items.add(new BlueBulletItem(x, y, speed, screen.itemBlueImages));\n }else{\n screen.items.add(new BlueBulletItem(x, y, speed, screen.itemBlueImages,false));\n }\n }\n\n }\n if (System.currentTimeMillis() - lastHealthSpawn >= SpawnTimerHealth) {\n speed = 500;\n lastHealthSpawn = System.currentTimeMillis();\n if (stageId == 4) {\n speed = speed / 2;\n where = Utils.doRandom(0, 1);\n if (where < 50) {\n spawnRight = true;\n } else {\n spawnRight = false;\n }\n\n }\n if (spawnRight) {\n int x = (int) screen.gameViewport.getWorldWidth();\n int y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - BlueBulletItem.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x - BlueBulletItem.width, y, BlueBulletItem.width, BlueBulletItem.height)))\n hits = true;\n }\n }\n screen.items.add(new GreenCapsuleItem(x, y, speed, screen.itemGreenImages));\n } else {\n int x = 0 - BlueBulletItem.width;\n int y = 0;\n boolean hits = true;\n while (hits) {\n hits = false;\n y = screen.random.nextInt((int) screen.gameViewport.getWorldHeight() - BlueBulletItem.height);\n for (int h = 0; h < collisions.size(); h++) {\n if (Collision.checkWalls(collisions.get(h), new Rectangle(x + BlueBulletItem.width * 2, y, BlueBulletItem.width, BlueBulletItem.height)))\n hits = true;\n }\n }\n screen.items.add(new GreenCapsuleItem(x, y, speed, screen.itemGreenImages, false));\n }\n }\n //TODO\n }\n }\n }\n\n //run .update(delta) on all objects\n for (int i=0; i<screen.entities.size();i++){\n screen.entities.get(i).update(delta);\n }\n\n for (int i=0; i<screen.items.size();i++){\n screen.items.get(i).update(delta);\n }\n\n //labels set:\n screen.labelHealth.setText(\"Health: \" + screen.player.health + \"/\" + screen.player.maxHealth);\n if (scoreBased) {\n screen.labelInfo.setText(\"Score: \" + screen.player.score + \"/\" + scoreGoal);\n }else{\n if (killCount>0){\n screen.labelInfo.setText(\"Score: \" + screen.player.score + \"/\" + killCount);\n }else{\n if (boss){\n screen.labelInfo.setText(\"Boss: \"+screen.player.score + \"/\" + Boss.bossHealth);\n }else{\n screen.labelInfo.setText(\"\");\n }\n\n }\n }\n if (this.stageId == 999) {\n screen.labelInfo.setText(\"Score: \" + screen.player.score);\n }\n\n\n }", "void setup() {\n size(2048, 2048); //sets size of canvas\n \n //names entities and their position\n player = new Sprite(tankURL, 100, 400, 100, 100);\n smbulletbase = new Sprite(tankbulletURL, 100, 400, 100, 100);\n enemyBase = new Sprite(enemytankURL, 100, 400, 100, 100);\n medkit = new Sprite(healthURL, 100, 400, 100, 100);\n kaboomBase = new Sprite(explosionURL, 100, 400, 100, 100);\n minigun = new Sprite(minigunURL, 100, 400, 100, 100);\n coilgun = new Sprite(coilgunURL, 100, 400, 100, 100);\n \n \n //sets size of some pictures\n smbulletbase.setSize(50, 50);\n minigun.setSize(150,150);\n coilgun.setSize(150,150);\n \n //initialization of scene switcher library\n scsw = new SceneSwitcher();\n scsw.addScene(\"Title\", new Scene(() -> drawTitle()));\n scsw.addScene(\"Game\", new Scene(() -> drawGame()));\n scsw.addScene(\"Death\", new Scene(() -> drawDeath()));\n \n \n //sets players front angle\n player.frontAngle(90);\n \n //sets up audio library\n ktAudio = new KTAudioController(this);\n clickEffect = new KTSound(this, gunshotURL);\n ktAudio.add(clickEffect);\n \n\n}", "public void makeGibs(Sprite s, boolean left, Vector2 basePos, boolean isMapTexture, Class<? extends Action> actionClass, int b, int seed){\n\t\tAtlasSprite as = (AtlasSprite) s;\n\t\tBlockDefinition def = MapSystem.getDef(b);\n\t\t\n\t\tfloat pix = 1f/2048f;\n\t\tint size = Math.max(((AtlasSprite)(s)).getAtlasRegion().packedHeight, ((AtlasSprite)(s)).getAtlasRegion().packedWidth);\n\t\tIntArray arr;\n\t\tif (def.breaksWithBigPieces){\n\t\t\tarr = decompositions4[size][seed % decompositions[size].length];\n\t\t} else \n\t\t\tarr = decompositions[size][seed % decompositions[size].length];\n\t\tfor (int i = 0; i < arr.size; i+=4){\n\t\t\tSprite spr = spritePool.obtain();\n\t\t\tspr.setRegion(as.getAtlasRegion());\n\t\t\tAtlasRegion reg = as.getAtlasRegion();\n\t\t\t\n\t\t\t//reg.setRegion(s.getAtlasRegion());\n\t\t\tint x = arr.get(i);\n\t\t\tint y = arr.get(i+1);\n\t\t\tint w = arr.get(i+2);\n\t\t\tint h = arr.get(i+3);\n\t\t\t/*reg.originalWidth = s.getAtlasRegion().originalWidth;\n\t\t\treg.originalHeight = s.getAtlasRegion().originalHeight;\n\t\t\treg.offsetX = s.getAtlasRegion().offsetX;\n\t\t\treg.offsetY = s.getAtlasRegion().offsetY;\n\t\t\treg.packedWidth = w;//s.getAtlasRegion().packedWidth;\n\t\t\treg.packedHeight = h;//s.getAtlasRegion().packedHeight;*/\n\t\t\t\n\t\t\tif (x > reg.packedWidth)continue;//outside of x range\n\t\t\tif (x + w >= reg.packedWidth){//too wide\n\t\t\t\tw = reg.packedWidth - x;\n\t\t\t}\n\t\t\tif (y > reg.packedHeight)continue;//outside of y range\n\t\t\tif (y + h >= reg.packedHeight){//too high\n\t\t\t\th = reg.packedHeight - y;\n\t\t\t}//*/\n\t\t\t//reg.offsetX += x;\n\t\t\tif (left){\n\t\t\t\tspr.setU(s.getU()-x*pix);\n\t\t\t\tspr.setV2(s.getV()+as.getAtlasRegion().packedHeight*pix-y*pix);\n\t\t\t\tspr.setU2(s.getU()-x*pix-w*pix);\n\t\t\t\tspr.setV(s.getV()+as.getAtlasRegion().packedHeight*pix-y*pix-h*pix);\t//*/\n\t\t\t\t}\t//*/\n\t\t\telse {\n\t\t\t\tspr.setU(s.getU()+x*pix);\n\t\t\t\tspr.setV2(s.getV()+as.getAtlasRegion().packedHeight*pix-y*pix);\n\t\t\t\tspr.setU2(s.getU()+x*pix+w*pix);\n\t\t\t\tspr.setV(s.getV()+as.getAtlasRegion().packedHeight*pix-y*pix-h*pix);\t//*/\n\t\t\t\t\n\t\t\t}\n\t\t\tspr.setSize(w, h);\n\t\t\t\n\t\t\t//Gdx.app.log(TAG, \" su \" + spr.getU()/pix + \" sv \"+ spr.getV()/pix + \" su2 \" + spr.getU2()/pix + \" sv2 \"+ spr.getV2()/pix + \" w \"+w+\" h \"+h + \" x \"+x + \" y \"+y\n\t\t\t//\t\t+ \" i \"+i);\n\t\t\t//Gdx.app.log(TAG, \" su \" + spr.getU() + \" sv \"+ spr.getV() + \" su2 \" + spr.getU2() + \" sv2 \"+ spr.getV2() + \" w \"+w+\" h \"+h + \" x \"+x + \" y \"+y\n\t\t\t//\t\t+ \" i \"+i);\n\t\t\n\t\t\t//setRegion(spr, reg);\n\t\t\t\n\t\t\tEntity e = engine.createEntity();\n\t\t\tBody body = engine.createComponent(Body.class);\n\t\t\tPosition pos = engine.createComponent(Position.class);\n\t\t\tPhysics physics = engine.createComponent(Physics.class);\n\t\t\tphysics.vel.set(MathUtils.random(-3f, 3f), MathUtils.random(5f, 15f));\n\t\t\tbody.width = w/32f;\n\t\t\tbody.height = h/32f;\n\t\t\tpos.pos.set(basePos)\n\t\t\t.add(w/32f, h/32f)\n\t\t\t.add(as.getAtlasRegion().offsetX/16f, as.getAtlasRegion().offsetY/16f)\n\t\t\t//.sub(2.5f-0f/16f, 2f+5f/16f)\n\t\t\t//.sub(eBody.width, eBody.height);\n\t\t\t;\n\t\t\tif (left){\n\t\t\t\t//pos.pos.add(as.getAtlasRegion().packedWidth/16f - x/16f-w/16f, y/16f);\n\t\t\t\tGdx.app.log(TAG, \"LEFT\");\n\t\t\t\tspr.setFlip(true, false);\n\t\t\t\tpos.pos.add(x/16f, y/16f);\n\t\t\t} else {\n\t\t\t\t\n\t\t\t\tpos.pos.add(x/16f, y/16f);\n\t\t\t}\n\t\t\t\n\t\t\tActionList actionList = engine.createComponent(ActionList.class);\n\t\t\tif (actionClass != null){\n\t\t\t\tactionList.addToStart(Pools.obtain(actionClass));\n\t\t\t\t\n\t\t\t}\n\t\t\te.add(pos);\n\t\t\te.add(physics);\n\t\t\te.add(body);\n\t\t\te.add(actionList);\n\t\t\tphysics.limit.set(10,10, 10);\n\t\t\t//physics.gravity.set(0, -30);\n\t\t\tSpriteStatic sprite = engine.createComponent(SpriteStatic.class);\n\t\t\tsprite.s = spr;\n\t\t\tif (isMapTexture){\n\t\t\t\te.add(engine.createComponent(SpriteIsMapTexture.class));\n\t\t\t}\n\t\t\t\n\t\t\te.add(sprite);\n\t\t\tCollidesWithMap coll = engine.createComponent(CollidesWithMap.class);\n\t\t\te.add(coll);\n\t\t\tOnMap onMap = engine.createComponent(OnMap.class);\n\t\t\te.add(onMap);\n\t\t\t\n\t\t\t\n\t\t\tItem item = Pools.obtain(Item.class);\n\t\t\titem.set(def.particleItemID, w * h, 1f);\n\t\t\t//body.width += Main.PX * 4;\n\t\t\t//body.height += Main.PX * 4;\n\t\t\t//item.id = ;\n\t\t\t//Gdx.app.log(TAG, \"item \"+item.id);\n\t\t\t\n\t\t\t//item.count = ;\n\t\t\titem.hash = Inventory.nextHash();\n\t\t\te.add(item);\n\t\t\t\n\t\t\t\n\t\t\t/*BlockPart part = engine.createComponent(BlockPart.class);\n\t\t\tpart.id = (b & Map.ID_MASK) >> Map.ID_BITS;\n\t\t\tpart.count = w * h;\n\t\t\te.add(part);*/\n\t\t\t\n\t\t\t\t\t\t\n\t\t\t\n\t\t\tengine.addEntity(e);;\n\t\t\t//break;\n\t\t}\n\t\t\n\t}", "private void muerte(){\r\n\t\t for(Icon i:sprites.elementAt(4))\r\n\t \t {\r\n\t \t\t grafico.setIcon(i);\r\n\t \t\t try {\r\n\t\t\t\tThread.sleep(300);\r\n\t\t\t} catch (InterruptedException e) {\r\n\t\t\t\t// TODO Auto-generated catch block\r\n\t\t\t\te.printStackTrace();\r\n\t\t\t}\r\n\t \t }\r\n\t \t grafico.setIcon(null);\r\n\t}", "public void setBattleSprite(Sprite battleSprite)\n {\n this.battleSprite = battleSprite;\n }", "@Override\r\n public boolean dye() {\r\n if (getX() > 3100 || getX() < 10 || getY() < 10 || getY() > 3100) {\r\n return true;\r\n }\r\n// int pixel = mapRGB.getRGB((int) getX(), (int) getY());\r\n// int red = (pixel >> 16) & 0xff;\r\n// if(red==255){this.handler.getWaves().removeEnemy(); return true;}\r\n int k = collision(velX, velY, this.getX(), this.getY());\r\n if(k!=0) {\r\n this.handler.getWaves().removeEnemy(); \r\n return true;\r\n }\r\n else{\r\n zombie_x = getX(); \r\n zombie_y = getY();\r\n }\r\n //I proiettili hanno una portata limitata o se ha colpito il player o se è uscito dalla mappa o se è andato contro un muro\r\n if ((this.getHealth() == 0) || (handler.getPlayer().getBounds().contains(getX(), getY()))) {\r\n int n = (int) (Math.random() * 10);\r\n if(n>1) n=2;\r\n switch (n) {\r\n case 2:\r\n this.handler.addSprite(new StandardZombie(zombie_x, zombie_y, 3, 200, 25, handler.getPlayer(), this.handler, 30, 60, 60, 5, new Animation(Assets.zombie, 20), new Animation(Assets.zombieAttack, 35), new Sound(Assets.zombieBite), new Sound(Assets.zombieHit)));\r\n break;\r\n case 0:\r\n this.handler.addSprite(new StandardZombie(zombie_x, zombie_y, 4, 70, 50, handler.getPlayer(), this.handler, 0, 60, 60, 20, new Animation(Assets.zombie2, 15), new Animation(Assets.zombie2Attack, 15), new Sound(Assets.zombieBite), new Sound(Assets.zombieHit)));\r\n break;\r\n case 1:\r\n this.handler.addSprite(new SpittleZombie(zombie_x, zombie_y, 3, 500, 40, handler.getPlayer(), this.handler, 0, 60, 60, 45, new Animation(Assets.zombie3, 15), new Animation(Assets.zombie3Attack, 15), new Sound(Assets.zombieBite), new Sound(Assets.zombieHit)));\r\n break;\r\n }\r\n return true;\r\n }\r\n \r\n return false;\r\n }", "ArrayList<Sprite> getSpriteArray();", "public void gameRender(int x, int y) throws IOException {\n if (dbImage == null) {\n dbImage = new BufferedImage(PWIDTH, PHEIGHT, BufferedImage.TYPE_INT_RGB);\n if (dbImage == null) {\n System.out.println(\"dbImage is null\");\n return;\n } else {\n graphics = dbImage.getGraphics();\n }\n }\n\n int width = backgroundImage.getWidth();//width of background image\n graphics.drawImage(backgroundImage, x, y, null);//draws image on main game panel\n graphics.drawImage(backgroundImage, x + width, y, null);//draws image off screen for scrolling reasons\n if (nextStage == 1) {\n graphics.drawImage(planetImageTransformed, PWIDTH - planetImageTransformed.getWidth() / 2, PHEIGHT / 2 - planetImageTransformed.getHeight() / 2, null);\n }\n for (int i = 0; i < Ship.health; i++) { //i < 5\n graphics.drawImage(health.getHealthimage(), 30 * i, 10, 30, 30, null); //20*i, 10, 30, 30, nul \n }\n\n for (int j = 0; j < Shield.count; j++) { // draw Shield Image\n graphics.drawImage(shield.getShieldImage(), 30 * j, 80, 30, 30, null);\n }\n\n if (nextStage == 1) {\n graphics.drawImage(planetImageTransformed, PWIDTH - planetImageTransformed.getWidth() / 2, PHEIGHT / 2 - planetImageTransformed.getHeight() / 2, null);\n }\n\n if (stageChange) {\n if (nextStage == 1) {\n currentStage = new Stage1();\n planetImageTransformed = planetImage;\n scaleCount = 0;\n scale = 1;\n collectFromStage();\n }\n\n if (nextStage == 2) {\n currentStage = new Stage2();\n collectFromStage();\n }\n\n if (nextStage == 3) {\n currentStage = new Stage3();\n collectFromStage();\n }\n\n stageChange = false;\n }\n\n if (cutsceneChange) {\n\n if (nextCutscene == 1) {\n currentCutscene = new Cutscene1();\n currentStage = new Stage2();\n collectFromCutscenes();\n Animator.cutsceneRunning = true;\n\n }\n if (nextCutscene == 2) {\n currentCutscene = new Cutscene2();\n currentStage = new Stage3();\n collectFromCutscenes();\n Animator.cutsceneRunning = true;\n }\n cutsceneChange = false;\n }\n\n synchronized (gameData.figures) {//runs through each game figures and renders them\n GameFigure f;\n for (GameFigure figure : gameData.figures) {\n f = (GameFigure) figure;\n f.render(graphics);\n }\n }\n }" ]
[ "0.6790776", "0.66856647", "0.6640622", "0.65535057", "0.6456288", "0.64535403", "0.6435134", "0.6420284", "0.63573855", "0.63415223", "0.6212522", "0.61570823", "0.61399764", "0.6121884", "0.6060202", "0.60406816", "0.60104644", "0.59955317", "0.5994872", "0.5989763", "0.59784687", "0.5967487", "0.5967364", "0.5967102", "0.5962057", "0.5959352", "0.5953237", "0.59509534", "0.59427464", "0.592697", "0.5913257", "0.59014", "0.5873902", "0.5872699", "0.5872038", "0.58630383", "0.58504164", "0.5846982", "0.5841718", "0.5829201", "0.58283544", "0.58280575", "0.5817366", "0.5806819", "0.5805621", "0.5803804", "0.5799516", "0.5798205", "0.5795086", "0.57893926", "0.57835585", "0.5782821", "0.5769808", "0.5762545", "0.5756285", "0.57503134", "0.5741518", "0.5741156", "0.5740986", "0.5736329", "0.5730665", "0.57306075", "0.57252926", "0.57163286", "0.57136464", "0.5699112", "0.56929106", "0.5688795", "0.5684374", "0.56774396", "0.5663931", "0.56610656", "0.56473863", "0.5637614", "0.5626753", "0.56247264", "0.56176424", "0.5607906", "0.56009173", "0.5600341", "0.5598946", "0.5587823", "0.55839497", "0.55804", "0.5570177", "0.55653906", "0.5556752", "0.55567384", "0.5556236", "0.55504763", "0.554949", "0.5546025", "0.5545979", "0.55426174", "0.55352724", "0.5521844", "0.55217713", "0.5514576", "0.5509825", "0.5504274", "0.55021447" ]
0.0
-1
=============================== Animation Mode Transition ===============================
public static AnimationModeTransition obtainAnimationModeTransition() { return animationModeTransitionPool.obtain(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void animate()\n\t{\n\t\tanimation.read();\n\t}", "@Override\n public void animate() {\n }", "Animation getShowAnimation();", "private void rerunAnimation() {\n transition.playFromStart();\r\n}", "public void readyToGoAnimation() {\n TranslateTransition leave = new TranslateTransition(Duration.millis(600), syncBox);\n leave.setByY(80.0);\n // Buttons slide in and clickable address appears simultaneously.\n TranslateTransition arrive = new TranslateTransition(Duration.millis(600), controlsBox);\n arrive.setToY(0.0);\n FadeTransition reveal = new FadeTransition(Duration.millis(500), addressControl);\n reveal.setToValue(1.0);\n ParallelTransition group = new ParallelTransition(arrive, reveal);\n // Slide out happens then slide in/fade happens.\n SequentialTransition both = new SequentialTransition(leave, group);\n both.setCycleCount(1);\n both.setInterpolator(Interpolator.EASE_BOTH);\n both.play();\n }", "public void setAnimation()\n {\n if(speed<0)\n {\n if(animationCount % 4 == 0)\n animateLeft();\n }\n else\n {\n if(animationCount % 4 == 0)\n animateRight();\n }\n }", "@Override\r\n protected boolean hasAnimation() {\r\n return true;\r\n }", "protected abstract void animate(int anim);", "public void animationTrans() {\n float unitAngle;\n if (type == CIRCLE) {\n unitAngle = (float) 360 / defaultCount;\n } else {\n unitAngle = 45f;\n }\n final float oldAngle = mAngle;\n float nAngle = mAngle % actualAngle;\n float gapAngle = (float) (nAngle / unitAngle) - (int) (nAngle / unitAngle);\n\n final float willAngle;\n if (type == CIRCLE) {\n willAngle = (float) ((0.5 - gapAngle) * unitAngle);\n } else {\n if (gapAngle < 0.5) {\n willAngle = (float) ((0 - gapAngle) * unitAngle);\n } else {\n willAngle = (float) ((1 - gapAngle) * unitAngle);\n }\n }\n Animation a = new Animation() {\n\n @Override\n protected void applyTransformation(float interpolatedTime, Transformation t) {\n\n mAngle = oldAngle + willAngle * interpolatedTime;\n\n requestLayout();\n }\n\n @Override\n public boolean willChangeBounds() {\n return true;\n }\n };\n\n a.setDuration(200);\n startAnimation(a);\n }", "@Override\n protected void animStart() {\n }", "private void processStatesAnimation() {\n if(getState() == JUMPING_STATE || getState() == FALLING_STATE) {\n if(getDirection() == DIRECTION_RIGHT)\n setAnim(jumpingRight);\n else if(getDirection() == DIRECTION_LEFT)\n setAnim(jumpingLeft);\n }\n\n if(getState() == NORMAL_STATE) {\n if(getDirection() == DIRECTION_STOPPED_RIGHT)\n setAnim(standingRight);\n else if(getDirection() == DIRECTION_STOPPED_LEFT)\n setAnim(standingLeft);\n else if(getDirection() == DIRECTION_RIGHT)\n setAnim(walkingRight);\n else if(getDirection() == DIRECTION_LEFT)\n setAnim(walkingLeft);\n }\n\n if(getState() == DYING_STATE) \n setAnim(dying);\n }", "@Override\n public void onAnimationStart(Animation anim) {\n }", "@Override\n public void onAnimationStart(Animation anim) {\n }", "@Override\n public void onAnimationStart(Animation anim) {\n }", "@Override\n public void onAnimationStart(Animation anim) {\n }", "public void readyToGoAnimation() {\n TranslateTransition arrive = new TranslateTransition(Duration.millis(1200), controlsBox);\n arrive.setInterpolator(new ElasticInterpolator(EasingMode.EASE_OUT, 1, 2));\n arrive.setToY(0.0);\n FadeTransition reveal = new FadeTransition(Duration.millis(1200), addressControl);\n reveal.setToValue(1.0);\n ParallelTransition group = new ParallelTransition(arrive, reveal);\n group.setDelay(NotificationBarPane.ANIM_OUT_DURATION);\n group.setCycleCount(1);\n group.play();\n }", "@Override\r\n public void onAnimationStart(Animator arg0)// 动画开始\r\n {\n\r\n }", "@Override\n\t\tpublic void onAnimationStart(Animator animation) {\n\t\t\t\n\t\t}", "@Override\n public Animation onCreateAnimation(int transit, boolean enter, int nextAnim) {\n if (nextAnim == 0) {\n return super.onCreateAnimation(transit, enter, nextAnim);\n }\n\n Animation anim = android.view.animation.AnimationUtils.loadAnimation(getContext(), nextAnim);\n\n //using hardware layer to make the animation stutter free\n rootView.setLayerType(View.LAYER_TYPE_HARDWARE, null);\n\n anim.setAnimationListener(new Animation.AnimationListener() {\n @Override\n public void onAnimationStart(Animation animation) {}\n @Override\n public void onAnimationEnd(Animation animation) {\n\n //setting the layer type back to none after animation\n rootView.setLayerType(View.LAYER_TYPE_NONE, null);\n }\n\n @Override\n public void onAnimationRepeat(Animation animation) {}\n });\n return anim;\n }", "@Override\n\t\t\t\t\tpublic void onAnimationStart(Animator animation) {\n\t\t\t\t\t\t\n\t\t\t\t\t}", "@Override\n protected void animStop() {\n }", "public void mo5964b() {\n this.f5416fa.setVisibility(0);\n this.f5416fa.setImageBitmap(C1413m.f5711i);\n ObjectAnimator duration = ObjectAnimator.ofFloat(this.f5416fa, \"translationY\", new float[]{0.0f, -((float) C1413m.f5711i.getHeight())}).setDuration(350);\n ObjectAnimator duration2 = ObjectAnimator.ofFloat(this.f5416fa, \"alpha\", new float[]{1.0f, 0.9f, 0.8f, 0.7f, 0.55f, 0.35f, 0.2f, 0.1f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f}).setDuration(350);\n duration.start();\n duration2.start();\n long j = (long) 240;\n ObjectAnimator.ofFloat(this.f5436pa, \"alpha\", new float[]{0.0f, 0.3f, 0.5f, 0.7f, 0.9f, 1.0f}).setDuration(j).start();\n this.f5438qa.getMeasuredHeight();\n this.f5384D.getmImageViewHeight();\n C1413m.m6828a(27, this.f5389I);\n ObjectAnimator.ofFloat(this.f5386F, \"alpha\", new float[]{0.0f, 1.0f}).setDuration(j).start();\n ObjectAnimator.ofFloat(this.f5384D, \"alpha\", new float[]{0.0f, 1.0f}).setDuration(j).start();\n ObjectAnimator.ofFloat(this.f5385E, \"alpha\", new float[]{0.0f, 1.0f}).setDuration(j).start();\n this.f5384D.getTexView().setText(getResources().getString(R.string.pause));\n this.f5384D.getmImageView().setImageResource(R.drawable.iqoo_buttonanimation);\n this.f5393M = (AnimationDrawable) this.f5384D.getmImageView().getDrawable();\n this.f5393M.start();\n duration.addListener(new C1300Wa(this));\n }", "public void mo5969f() {\n this.f5416fa.setVisibility(0);\n this.f5416fa.setImageBitmap(C1413m.f5711i);\n ObjectAnimator duration = ObjectAnimator.ofFloat(this.f5416fa, \"translationY\", new float[]{0.0f, -((float) C1413m.f5711i.getHeight())}).setDuration(350);\n ObjectAnimator duration2 = ObjectAnimator.ofFloat(this.f5416fa, \"alpha\", new float[]{1.0f, 0.9f, 0.8f, 0.7f, 0.55f, 0.35f, 0.2f, 0.1f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f}).setDuration(350);\n duration.start();\n duration2.start();\n long j = (long) 240;\n ObjectAnimator.ofFloat(this.f5386F, \"alpha\", new float[]{0.0f, 1.0f}).setDuration(j).start();\n ObjectAnimator.ofFloat(this.f5384D, \"alpha\", new float[]{0.0f, 1.0f}).setDuration(j).start();\n ObjectAnimator.ofFloat(this.f5385E, \"alpha\", new float[]{0.0f, 1.0f}).setDuration(j).start();\n this.f5384D.getTexView().setText(getResources().getString(R.string.pause));\n duration.addListener(new C1298Va(this));\n }", "public abstract void animationStarted();", "@Override public void onAnimationStart(Animator arg0) {\n\n }", "@Override\n public void onAnimationStart(Animator animation) {\n }", "public void onAnimationStart(Animation animation) {\n\r\n }", "public void enterAnimation() {\n overridePendingTransition(R.anim.slide_in_right, R.anim.slide_out_left);\n }", "void startAnimation();", "@Override\n\t\t\tpublic void onAnimationStart(Animation animation) {\n\t\t\t\t\n\t\t\t}", "@Override\n\t\t\tpublic void onAnimationStart(Animation animation) {\n\t\t\t\t\n\t\t\t}", "public void e()\n/* */ {\n/* 193 */ if (!this.g) {\n/* 194 */ AnimatorSet localAnimatorSet = new AnimatorSet();\n/* 195 */ localAnimatorSet.play(a(this.b)).with(b(this.c));\n/* 196 */ localAnimatorSet.setDuration(this.f).start();\n/* 197 */ this.c.setVisibility(View.VISIBLE);\n/* 198 */ this.g = true;\n/* */ }\n/* */ }", "void onAnimationStart();", "@Test\n\tpublic void animationTest() {\n\t\t\n\t\tMap<Direction, TimeAnimation> animationMap = Player.makePlayerAnimation(PlayerType.CAVEMAN.name(), \n\t\t\t\tPlayerState.IDLE, 1, 1, null);\n\t\t\n\t\t// Test setting idle animation to north\n\t\tarcher.setAnimation(animationMap.get(Direction.N));\n\t\t\n\t\t// Test setting idle animation to south\n\t\tarcher.setAnimation(animationMap.get(Direction.S));\n\t\t\t\t\n\t\t// Test setting idle animation to south west\n\t\tarcher.setAnimation(animationMap.get(Direction.SW));\n\t}", "@Override\n\tpublic void onAnimationStart(Animator arg0) {\n\t\tif (mState.getState() != 0) {\n\t\t\tGBTools.GBsetAlpha(bv, 0.0F);\n\t\t\tbv.setState(mState.getState());\n\t\t\tbv.setPressed(false);\n\t\t}\n\t\tbv.bringToFront();\n\t\tmBoardView.invalidate();\n\t}", "@Override\r\n\t\t\t\tpublic void onAnimationStart(Animation animation) {\n\r\n\t\t\t\t}", "@Override\r\n\t\t\t\tpublic void onAnimationStart(Animation animation) {\n\r\n\t\t\t\t}", "@Override\n\t\tpublic void onAnimationStart(Animation animation) {\n\t\t\t\n\t\t}", "@Override\n\t\t\t\t\t\t\tpublic void onAnimationStart(Animation arg0) {\n\n\t\t\t\t\t\t\t}", "@Override\n\t\t\t\t\t\t\tpublic void onAnimationStart(Animation arg0) {\n\n\t\t\t\t\t\t\t}", "public void onAnimationStart(Animation animation) {\n }", "@Override\n public void onAnimationStart(Animation arg0) {\n \n }", "private void m125730y() {\n this.f90219I.set(false);\n View view = this.f90216F;\n if (view != null && view.getVisibility() == 0 && !this.f90218H.get()) {\n this.f90216F.clearAnimation();\n AlphaAnimation alphaAnimation = new AlphaAnimation(1.0f, 0.0f);\n alphaAnimation.setDuration(500);\n alphaAnimation.setAnimationListener(new Animation.AnimationListener() {\n /* class com.zhihu.android.topic.platfrom.TopicFragment.animationAnimation$AnimationListenerC258283 */\n\n public void onAnimationRepeat(Animation animation) {\n }\n\n public void onAnimationStart(Animation animation) {\n TopicFragment.this.f90218H.set(true);\n }\n\n public void onAnimationEnd(Animation animation) {\n TopicFragment.this.f90216F.setVisibility(8);\n TopicFragment.this.f90218H.set(false);\n if (TopicFragment.this.f90219I.get()) {\n TopicFragment.this.m125731z();\n }\n }\n });\n this.f90216F.startAnimation(alphaAnimation);\n }\n }", "@Override\n\t\t\t\t\t\t\tpublic void onAnimationStart(Animator arg0) {\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}", "T setSequencedAnimation(Boolean sequencedAnimation);", "@Override\n\t\tprotected void doTransition() {\n\t\t\t\n\t\t}", "@Override\n\t\t\t\t\tpublic void onAnimationStart(Animation animation) {\n\t\t\t\t\t\t\n\t\t\t\t\t}", "@Override\n public Animator onCreateAnimator(int transit, boolean enter, int nextAnim) {\n return ValueAnimator.ofFloat(.0F, 1.F).setDuration(ChildAnimationAction.DURATION);\n }", "private void animateDrawer(){\n int[] location = new int[2];\n int leftDelta;\n pageFontEl.getLocationOnScreen(location);\n if(switchState == \"off\"){\n leftDelta = 0;\n switchState = \"on\";\n } else{\n leftDelta = common.dip2px(HomeActivity.this, 130);\n switchState = \"off\";\n }\n pageFontEl.layout(leftDelta, 0, leftDelta + pageFontEl.getWidth(), 0 + pageFontEl.getHeight());\n }", "void animation() {\n LinearLayout linearLayout = findViewById(R.id.loginLinear);\n animationDrawable = (AnimationDrawable)linearLayout.getBackground();\n animationDrawable.setEnterFadeDuration(5000);\n animationDrawable.setExitFadeDuration(5000);\n\n }", "@Override\n public void onAnimationStart(Animation animation) {\n\n }", "@Override\r\n\t\t\tpublic void onAnimationStart(Animation animation) {\n\r\n\t\t\t}", "@Override\r\n\t\t\tpublic void onAnimationStart(Animation animation) {\n\r\n\t\t\t}", "@Override\r\n\t\t\tpublic void onAnimationStart(Animation animation) {\n\r\n\t\t\t}", "@Override\n\t\t\tpublic void onAnimationStart(Animation arg0) {\n\t\t\t\t\n\t\t\t}", "@Override\n\t\t\tpublic void onAnimationStart(Animation arg0) {\n\t\t\t\t\n\t\t\t}", "public void onAnimationRepeat(Animation animation) {\n\r\n }", "private void setupWindowsAnimations() {\n }", "@Override\r\n\t\t\t\t\tpublic void onAnimationStart(Animation animation) {\n\t\t\t\t\t\t\r\n\t\t\t\t\t}", "@Override\r\n public void onAnimationRepeat(Animator arg0)// 动画重复\r\n {\n\r\n }", "private void idleAnimation(){\n timer++;\n if( timer > 4 ){\n setImage(loadTexture());\n animIndex++;\n timer= 0;\n if(animIndex > maxAnimIndex ){\n animIndex = 0;\n }\n }\n }", "@Override public void onAnimationRepeat(Animator arg0) {\n\n }", "public void updateAnimation() {\n\t\tif (anim < 1000) {\n\t\t\tanim++;\n\t\t} else anim = 0;\n\t}", "public void toggleAnim(boolean show) {\n if (animatorSet != null) {\n if (preAnimationEndAlpha == (show ? 1f : 0f)) {\n return;\n } else {\n animatorSet.cancel();\n }\n }\n if (show) {\n toogleVisible(mContainer, 0f, 1f, SmoothImageView.ANIMATION_DURATION);\n /* boolean needShow = false;\n for (View control : mControlsVisible.keySet()) {\n //[BUGFIX]-Modify by TCTNJ, dongliang.feng, 2015-06-23, PR1027856 begin\n Boolean prevVisibility = mControlsVisible.get(control);\n needShow = needShow || prevVisibility;\n if (!prevVisibility) {\n continue;\n }\n //[BUGFIX]-Modify by TCTNJ, dongliang.feng, 2015-06-23, PR1027856 end\n toogleVisible(control, 0f, 1f, SmoothImageView.ANIMATION_DURATION);\n }\n if (needShow) {\n toogleVisible(mContainer, 0f, 1f, SmoothImageView.ANIMATION_DURATION);\n }*/\n preAnimationEndAlpha = 1f;\n } else {\n toogleVisible(mContainer, 1f, 0f, SmoothImageView.ANIMATION_DURATION);\n /* for (View control : mControlsVisible.keySet()) {\n //[BUGFIX]-Modify by TCTNJ, dongliang.feng, 2015-06-23, PR1027856 begin\n Boolean prevVisibility = mControlsVisible.get(control);\n if (!prevVisibility) {\n continue;\n }\n //[BUGFIX]-Modify by TCTNJ, dongliang.feng, 2015-06-23, PR1027856 end\n toogleVisible(control, 1f, 0f, SmoothImageView.ANIMATION_DURATION);\n }*/\n preAnimationEndAlpha = 0f;\n }\n if (animatorSet != null) {\n animatorSet.start();\n }\n }", "protected abstract void animationLogicTemplate();", "@Override\r\n\t\t\tpublic void onAnimationStart(Animation animation) {\n\t\t\t\t\r\n\t\t\t}", "@Override\n public void onAnimationStart(Animation animation) {\n\n }", "@Override\n public void onAnimationStart(Animation animation) {\n }", "@Override\n\tpublic void onAnimationStart(Animation arg0) {\n\t\t\n\t}", "@Override\n\tpublic void onAnimationStart(Animation arg0) {\n\t\t\n\t}", "@Override\n public void onAnimationStart(Animator arg0) {\n\n }", "public void mo5967d() {\n this.f5416fa.setVisibility(0);\n this.f5416fa.setImageBitmap(C1413m.f5711i);\n ObjectAnimator duration = ObjectAnimator.ofFloat(this.f5416fa, \"translationY\", new float[]{-((float) C1413m.f5711i.getHeight()), 0.0f}).setDuration(240);\n ObjectAnimator duration2 = ObjectAnimator.ofFloat(this.f5416fa, \"alpha\", new float[]{0.0f, 0.2f, 0.3f, 0.4f, 0.5f, 0.6f, 0.7f, 0.8f, 0.9f, 1.0f}).setDuration(240);\n duration.start();\n duration2.start();\n long j = (long) 240;\n ObjectAnimator.ofFloat(this.f5436pa, \"alpha\", new float[]{1.0f, 0.9f, 0.8f, 0.7f, 0.6f, 0.5f, 0.4f, 0.3f, 0.2f, 0.0f}).setDuration(j).start();\n LinearLayout linearLayout = this.f5438qa;\n ObjectAnimator.ofFloat(linearLayout, \"translationY\", new float[]{0.0f, (float) ((linearLayout.getMeasuredHeight() - this.f5384D.getmImageViewHeight()) - C1413m.m6828a(27, this.f5389I))}).setDuration(j).start();\n ObjectAnimator.ofFloat(this.f5438qa, \"alpha\", new float[]{1.0f, 0.0f}).setDuration(j).start();\n duration.addListener(new C1304Ya(this));\n }", "@Override\n\tpublic void onAnimationStart(Animation animation) {\n\n\t}", "public void startAnimation() {\n animationStart = System.currentTimeMillis();\n }", "public abstract void animationStopped();", "@Override\n\t\t\tpublic void onAnimationStart(Animation animation) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void onAnimationStart(Animation animation) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void onAnimationStart(Animation animation) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void onAnimationStart(Animation animation) {\n\n\t\t\t}", "public void setAnimation() {\r\n\r\n // start outside the screen and move down until the clock is out of sight\r\n ObjectAnimator moveDown = ObjectAnimator.ofFloat(this, \"y\", -100, screenY + 100);\r\n AnimatorSet animSet = new AnimatorSet();\r\n animSet.play(moveDown);\r\n\r\n // Set duration to 4000 milliseconds\r\n animSet.setDuration(4000);\r\n\r\n animSet.start();\r\n\r\n }", "private void setupWindowAnimations() {\n getWindow().requestFeature(Window.FEATURE_CONTENT_TRANSITIONS);\n getWindow().setBackgroundDrawable(new ColorDrawable(Color.BLACK));\n\n\n\n Slide slideTransition = new Slide();\n slideTransition.setSlideEdge(Gravity.BOTTOM);\n getWindow().setEnterTransition(slideTransition);\n\n\n Slide slideTransitionExit = new Slide();\n slideTransitionExit.setSlideEdge(Gravity.TOP);\n getWindow().setExitTransition(slideTransitionExit);\n\n\n\n }", "private final void m75360j() {\n ((FrameLayout) mo78146a(R.id.selectorLayout)).animate().cancel();\n FrameLayout frameLayout = (FrameLayout) mo78146a(R.id.selectorLayout);\n C32569u.m150513a((Object) frameLayout, C6969H.m41409d(\"G7A86D91FBC24A43BCA0F8947E7F1\"));\n frameLayout.setAlpha(1.0f);\n FrameLayout frameLayout2 = (FrameLayout) mo78146a(R.id.selectorLayout);\n C32569u.m150513a((Object) frameLayout2, C6969H.m41409d(\"G7A86D91FBC24A43BCA0F8947E7F1\"));\n frameLayout2.setTranslationY(0.0f);\n }", "default Animator getInAnimation() {\n return null;\n }", "@Override\n public void onAnimationStart(Animator arg0) {\n\n }", "public void animate(){\n\n if (ra1.hasStarted() && ra2.hasStarted()) {\n\n// animation1.cancel();\n// animation1.reset();\n// animation2.cancel();\n// animation2.reset();\n gear1Img.clearAnimation();\n gear2Img.clearAnimation();\n initializeAnimations(); // Necessary to restart an animation\n button.setText(R.string.start_gears);\n }\n else{\n gear1Img.startAnimation(ra1);\n gear2Img.startAnimation(ra2);\n button.setText(R.string.stop_gears);\n }\n }", "@Override\n public void onAnimationRepeat(Animation arg0) {\n \n }", "@Override\n\t\t\tpublic void onAnimationStart(Animation animation) {\n\t\t\t}", "private void animateIn() {\n AnimatorSet buildAnimatorSet = buildAnimatorSet(this.mLayoutView, (float) this.mLayoutView.findViewById(C0010R$id.panel_container).getHeight(), 0.0f, 0.0f, 1.0f, 250);\n ValueAnimator valueAnimator = new ValueAnimator();\n valueAnimator.setFloatValues(0.0f, 1.0f);\n buildAnimatorSet.play(valueAnimator);\n buildAnimatorSet.start();\n this.mLayoutView.getViewTreeObserver().removeOnPreDrawListener(this.mOnPreDrawListener);\n }", "public void mo5968e() {\n this.f5416fa.setVisibility(0);\n this.f5416fa.setImageBitmap(C1413m.f5711i);\n ObjectAnimator duration = ObjectAnimator.ofFloat(this.f5416fa, \"translationY\", new float[]{-((float) C1413m.f5711i.getHeight()), 0.0f}).setDuration(240);\n ObjectAnimator duration2 = ObjectAnimator.ofFloat(this.f5416fa, \"alpha\", new float[]{0.0f, 0.2f, 0.3f, 0.4f, 0.5f, 0.6f, 0.7f, 0.8f, 0.9f, 1.0f}).setDuration(240);\n duration.start();\n duration2.start();\n long j = (long) 160;\n ObjectAnimator.ofFloat(this.f5436pa, \"alpha\", new float[]{1.0f, 0.9f, 0.8f, 0.7f, 0.6f, 0.5f, 0.4f, 0.3f, 0.2f, 0.0f}).setDuration(j).start();\n ObjectAnimator.ofFloat(this.f5438qa, \"alpha\", new float[]{1.0f, 0.0f}).setDuration(j).start();\n duration.addListener(new C1302Xa(this));\n }", "@Override\n public void onAnimationRepeat(Animation animation) {\n }", "@Override\n public void onAnimationRepeat(Animation animation) {\n }", "@Override\n public void onAnimationRepeat(Animation animation) {\n }", "@Override\n public void onAnimationRepeat(Animation animation) {\n }", "private void createAnimation () {\n // KeyFrame frame = new KeyFrame(Duration.millis(MILLISECOND_DELAY), e -> myManager.step());\n // myAnimation = new Timeline();\n // myAnimation.setCycleCount(Timeline.INDEFINITE);\n // myAnimation.getKeyFrames().add(frame);\n }", "public void finishTransition() {\n animTimer = 0;\n if (gameTransition) playTime = 0.0f;\n roomTransition = false;\n gameTransition = false;\n fadeToBlack = true;\n }", "@Override\n\t\t\t\t\t\t\tpublic void onAnimationRepeat(Animation arg0) {\n\n\t\t\t\t\t\t\t}", "@Override\n\t\t\t\t\t\t\tpublic void onAnimationRepeat(Animation arg0) {\n\n\t\t\t\t\t\t\t}", "@Override\r\n\t\t\tpublic void onAnimationStart(Animation arg0) {\n\t\t\t\t\r\n\t\t\t}", "default boolean shouldAnimate() {\n return true;\n }", "@Override\n public void onAnimationRepeat(Animation animation) {\n\n }" ]
[ "0.69119555", "0.68628776", "0.67899776", "0.6766517", "0.6756024", "0.6742305", "0.6717942", "0.6691332", "0.66859305", "0.6676659", "0.6629302", "0.65811896", "0.65811896", "0.65811896", "0.65811896", "0.65536934", "0.65411985", "0.65375584", "0.6526198", "0.6523622", "0.65223205", "0.65124804", "0.6488168", "0.64759964", "0.64340305", "0.64310056", "0.64298356", "0.64244014", "0.64022917", "0.64004254", "0.64004254", "0.63968164", "0.63956314", "0.63932747", "0.6388493", "0.63735557", "0.63735557", "0.6367061", "0.63583857", "0.63583857", "0.6358128", "0.63388544", "0.6338274", "0.6333514", "0.6332423", "0.6323674", "0.63170767", "0.6312924", "0.63118494", "0.6307373", "0.63060784", "0.6302655", "0.6302655", "0.6302655", "0.6301022", "0.6301022", "0.6297103", "0.6286211", "0.628028", "0.62764204", "0.6267911", "0.62571603", "0.6251332", "0.6246183", "0.6239302", "0.6238144", "0.62281036", "0.62145084", "0.621319", "0.621319", "0.6212627", "0.62110716", "0.62098384", "0.62088096", "0.6205027", "0.61989623", "0.61989623", "0.61989623", "0.61989623", "0.6198117", "0.61942846", "0.61938524", "0.6192973", "0.6190717", "0.6189621", "0.6187101", "0.61688614", "0.6160871", "0.6144969", "0.6143539", "0.6143539", "0.6143539", "0.6143539", "0.6136354", "0.61352587", "0.61242425", "0.61242425", "0.61239374", "0.61083466", "0.6095857" ]
0.63289183
45
=============================== Particle Effect ===============================
public static PooledEffect obtainParticleEffect(EParticleEffect effect) { try { return particleEffectPool.get(effect).obtain(); } catch (Exception e) { LOG.error("could not obtain particle effect", e); return null; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Particles particles();", "public void drawParticles() {}", "protected void playParticle(){\n\t\teffectData.getPlayParticles().playParticles(effectData, effectData.getDisplayAt());\n\t}", "@Override\n \t\t\t\tpublic void doCreateQuadParticle() {\n \n \t\t\t\t}", "private static void updateParticle(int index) {\n\n\t\tfloat posX = particles[index].getPositionX(); // Current X position of the particle\n\t\tfloat posY = particles[index].getPositionY(); // Current Y position of the particle\n\t\tfloat vX = particles[index].getVelocityX(); // Current horizontal velocity of the particle\n\t\tfloat vY = particles[index].getVelocityY();\t// Current vertical velocity of the particle\n\t\tint age = particles[index].getAge();\t// Current age of the particle\n\t\t\n\t\t// Fill the circle's color and transparency\n\t\tUtility.fill(particles[index].getColor(), particles[index].getTransparency());\n\t\t\n\t\t// Draw the circle\n\t\tUtility.circle(posX, posY, particles[index].getSize());\n\t\t\n\t\t// Update vertical velocity effected by gravity\n\t\tvY = vY + 0.3f;\n\t\t// Update the particle's vertical velocity, XY positions and its age\n\t\tparticles[index].setVelocityY(vY);\n\t\tparticles[index].setPositionX(posX + vX);\n\t\tparticles[index].setPositionY(posY + vY);\n\t\tparticles[index].setAge(age + 1);\n\t\t\n\t\t// Call this method to remove the old particles\n\t\tremoveOldParticles(80);\n\t\t\n\n\t}", "private void draw() {\n ctx.clearRect(0, 0, width, height);\n\n for (ImageParticle p : particles) {\n p.opacity = p.remainingLife / p.life * 0.5;\n\n // Draw particle from image\n ctx.save();\n ctx.translate(p.x, p.y);\n ctx.scale(p.size, p.size);\n //ctx.translate(p.image.getWidth() * (-0.5), p.image.getHeight() * (-0.5));\n ctx.translate(-HALF_WIDTH, -HALF_HEIGHT);\n ctx.setGlobalAlpha(p.opacity);\n ctx.drawImage(p.image, 0, 0);\n ctx.restore();\n\n //p.remainingLife--;\n p.remainingLife *= 0.98;\n //p.size *= 0.99;\n p.x += p.vX;\n p.y += p.vY;\n\n //regenerate particles\n if (p.remainingLife < 0 || p.size < 0 || p.opacity < 0.01) {\n if (running) {\n p.reInit();\n } else {\n particles.remove(p);\n }\n }\n }\n }", "public void updateParticles() {\n\n // Update walkingAnimation particle effect\n walkingParticleEffect.update(Gdx.graphics.getDeltaTime());\n if(walkingParticleEffect.isComplete()) {\n walkingParticleEffect.reset();\n }\n\n // Update getting hit particle effect\n if(damaged) {\n gettingHitParticleEffect.update(Gdx.graphics.getDeltaTime());\n if(gettingHitParticleEffect.isComplete() && !dead) {\n damaged = false;\n gettingHitParticleEffect.reset();\n }\n }\n }", "private void createParticle(double par1, double par3, double par5, double par7, double par9, double par11, int[] par13ArrayOfInteger, int[] par14ArrayOfInteger, boolean par15, boolean par16)\n {\n EntityFireworkSparkFX entityfireworksparkfx = new EntityFireworkSparkFX(this.worldObj, par1, par3, par5, par7, par9, par11, this.theEffectRenderer);\n entityfireworksparkfx.setTrail(par15);\n entityfireworksparkfx.setTwinkle(par16);\n int i = this.rand.nextInt(par13ArrayOfInteger.length);\n entityfireworksparkfx.setColour(par13ArrayOfInteger[i]);\n\n if (par14ArrayOfInteger != null && par14ArrayOfInteger.length > 0)\n {\n entityfireworksparkfx.setFadeColour(par14ArrayOfInteger[this.rand.nextInt(par14ArrayOfInteger.length)]);\n }\n\n this.theEffectRenderer.addEffect(entityfireworksparkfx);\n }", "@Override\n\tpublic void onClick(View arg0) {\n\t\tParticleSystem ps = new ParticleSystem(this, 100, R.drawable.star_pink, 800);\n\t\tps.setScaleRange(0.7f, 1.3f);\n\t\tps.setSpeedRange(0.1f, 0.25f);\n\t\tps.setAcceleration(0.0001f, 90);\n\t\tps.setRotationSpeedRange(90, 180);\n\t\tps.setFadeOut(200, new AccelerateInterpolator());\n\t\tps.oneShot(arg0, 100);\n\t}", "List<? extends Particle> update(double timeDelta);", "public void update(){\n\t\tfor(ParticleEffect effect : effects){\n\t\t\teffect.update();\n\t\t}\n\t}", "public Particle() {\n\t}", "public void spawnParticle(String particle, double x, double y, double z, double dx, double dy, double dz, double speed, int count);", "public void _applyModifier(Particle particle) {\n this.particle = particle;\n life = particle.life;\n outer = particle.outer;\n texture = particle.texture;\n sprite = particle.sprite;\n isInnerScreen = particle.isInnerScreen;\n this.physicParticle = particle.physicParticle;\n x = physicParticle.x;\n y = physicParticle.y;\n mass = physicParticle.mass;\n charge = physicParticle.charge;\n\n modify();\n }", "protected void updateParticles() {\n\n\t\tfor (int i = 0; i < particles.size(); i++) {\n\t\t\tVParticle p = particles.get(i);\n\t\t\tif (p.neighbors == null) {\n\t\t\t\tp.neighbors = particles;\n\t\t\t}\n\t\t\tfor (BehaviorInterface b : behaviors) {\n\t\t\t\tb.apply(p);\n\t\t\t}\n\t\t}\n\t\tfor (int i = 0; i < particles.size(); i++) {\n\t\t\tVParticle p = particles.get(i);\n\t\t\tp.scaleVelocity(friction);\n\t\t\tp.update();\n\t\t}\n\t}", "@Override\n \t\t\t\tpublic void doCreateLineParticle() {\n \n \t\t\t\t}", "public void spawnParticle ( Particle particle , double x , double y , double z , int count , double offsetX ,\n\t\t\tdouble offsetY , double offsetZ , double extra ) {\n\t\tspawnParticle ( particle , x , y , z , count , offsetX , offsetY , offsetZ );\n\t}", "public void mouseDragged() {\n pma_ParticleVerlet p = new pma_ParticleVerlet(mouseX,mouseY);\n p.lock();\n // if there is at least one particle and this is the current continuous line\n if (physics.particles.size() > 0 && continuous == current) {\n // get the previous particle (aka the last in the list)\n pma_ParticleVerlet prev = physics.particles.get(physics.particles.size()-1);\n // create a spring between the previous and the current particle of length 10 and strength 1\n pma_Spring s = new pma_Spring(p,prev,10,1);\n // add the spring to the physics system\n physics.addSpring(s);\n } else {\n current = continuous;\n }\n // unlock previous particle\n if (prev!=null) {\n prev.unlock();\n }\n // add the particle to the physics system\n physics.addParticle(p);\n // create a forcefield around this particle with radius 20 and force -1.5 (aka push)\n pma_i_BehaviorParticle b = new pma_BehaviorAttraction(p,20,-1.5f);\n // add the behavior to the physics system (will be applied to all particles)\n physics.addBehavior(b);\n // make current particle the previous one...\n prev=p;\n}", "public void setParticles(int particles) {\r\n\t\tthis.particles = particles;\r\n\t}", "public float particleOffset(int axis);", "public ParticleSystemPainter(EffectManager effectManager) {\r\n\t\tthis.effectManager = effectManager;\r\n\t}", "@Test\n public void testUpdateParticle() {\n\n pe.updateParticle(p, 0.0f, new Vector3f(), new Vector3f());\n // at the very start of the anim, the particle should be its start size\n assertThat(p.size, is(0.2f));\n // when some time has passed the particle should have a different size\n p.life -= 2.0f;\n pe.updateParticle(p, 2.0f, new Vector3f(), new Vector3f());\n assertThat(p.size, is(0.56f));\n // updating start-size should change the value\n pe.setStartSize(0.7f);\n // please note that there is no change in life here!\n pe.updateParticle(p, 0.0f, new Vector3f(), new Vector3f());\n assertThat(p.size, is(0.96000004f));\n // same goes for endSize\n pe.setEndSize(3.0f);\n pe.updateParticle(p, 0.0f, new Vector3f(), new Vector3f());\n assertThat(p.size, is(1.1600001f));\n }", "public static void update() {\n\t\t\n\t\t// Fill the background for every call\n\t\tUtility.background(Utility.color(235, 213, 186));\n\t\t\n\t\t// Create 10 new random particles\n\t\tcreateNewParticles(10);\n\t\t\n\t\t// Track every particle in the array then update their feature\n\t\tfor (int i = 0; i < particles.length; i++) {\n\t\t\tif (particles[i] != null) {\n\t\t\t\tupdateParticle(i);\n\t\t\t}\n\n\t\t}\n\n\t}", "private Particle[] createParticles(int N){\n Particle[] arr = new Particle[N];\n double v = 0, avgV = 0;\n\n int i = 0;\n while(i < N) {\n double sum = 0, d = (1.0 / N);\n if(T < 150.0) d *= 0.5;\n if(T < 50.0) d *= 0.5;\n while (sum < 1.0 / (N + 1)) {\n sum += func(v) * d;\n v += d;\n }\n System.out.println(\"v=\" + v + \", func(v)=\" + func(v));\n\n arr[i] = new Particle(0, 0, 400);\n double dir = Math.random() * 2 * Math.PI;\n arr[i].setVelocity(v, dir);\n\n avgV += v;\n\n i += 1;\n }\n\n avgV /= N;\n System.out.println(\"AvgV=\" + avgV);\n return arr;\n }", "boolean emitParticleMaybe(RenderState renderData, IParticle reusedParticle, PointF point, PointF vec);", "@Override\n\tprotected void onInitializeParticle(final Particle pParticle, final float pAlpha) {\n\t\tpParticle.setAlpha(pAlpha);\n\t}", "@Override\n public void run()\n {\n final int minX = region.getMinimumPoint().getX();\n final int minZ = region.getMinimumPoint().getZ();\n final int maxX = region.getMaximumPoint().getX();\n final int maxZ = region.getMaximumPoint().getZ();\n final int midX = (maxX - minX) / 2;\n final int midZ = (maxZ - minZ) / 2;\n double playerY = player.getLocation().getY();\n\n if (midX / 6 > 0)\n {\n int tmp = 0;\n final int amount = midX / 5;\n for (int i = 0; i < amount; i++)\n {\n final int x = minX + midX - tmp;\n final int x2 = minX + midX + tmp;\n for (double y = playerY - 10; y <= playerY + 10; y++)\n {\n player.spawnParticle(Particle.FLAME, x, y, minZ, 0);\n player.spawnParticle(Particle.FLAME, x, y, maxZ, 0);\n player.spawnParticle(Particle.FLAME, x2, y, minZ, 0);\n player.spawnParticle(Particle.FLAME, x2, y, maxZ, 0);\n }\n tmp += 5;\n }\n }\n if (midZ / 6 > 0)\n {\n int tmp = 0;\n final int amount = midZ / 5;\n for (int i = 0; i < amount; i++)\n {\n final int z = minZ + midZ - tmp;\n final int z2 = minZ + midZ + tmp;\n\n for (double y = playerY - 10; y <= playerY + 10; y++)\n {\n player.spawnParticle(Particle.FLAME, minX, y, z, 0);\n player.spawnParticle(Particle.FLAME, maxX, y, z, 0);\n player.spawnParticle(Particle.FLAME, minX, y, z2, 0);\n player.spawnParticle(Particle.FLAME, maxX, y, z2, 0);\n }\n tmp += 5;\n }\n }\n\n for (double y = playerY - 40; y <= 256; y++)\n {\n player.spawnParticle(Particle.FLAME, minX, y, minZ, 0);\n player.spawnParticle(Particle.FLAME, minX, y, maxZ, 0);\n player.spawnParticle(Particle.FLAME, maxX, y, minZ, 0);\n player.spawnParticle(Particle.FLAME, maxX, y, maxZ, 0);\n }\n timer--;\n\n if (0 > this.timer)\n {\n player.sendMessage(\"§5Boundaries have been expired.\");\n this.cancel();\n }\n }", "public void onUpdate() {\n super.onUpdate();\n\n if (this.world.isRemote) {\n double d0 = this.posX + (this.rand.nextDouble() * 2.0D - 1.0D) * (double) this.width * 0.5D;\n double d1 = this.posY + 0.05D + this.rand.nextDouble() * 1.0D;\n double d2 = this.posZ + (this.rand.nextDouble() * 2.0D - 1.0D) * (double) this.width * 0.5D;\n //double d3 = (this.rand.nextDouble() * 2.0D - 1.0D) * 0.3D;\n double d4 = this.rand.nextDouble() * 0.1D;\n //double d5 = (this.rand.nextDouble() * 2.0D - 1.0D) * 0.3D;\n this.world.spawnParticle(ticksExisted % 2 == 0 ? EnumParticleTypes.FLAME : EnumParticleTypes.SMOKE_NORMAL, d0, d1, d2, 0, d4, 0);\n } else if (--this.lifeTicks < 0) {\n this.setDead();\n }\n }", "public void explosion(){\n explosionEffect.play(pitch, volume);\n }", "public void secrete() {\n\t\t/* Instantiate a new virus particle */\n\t\tSim.lps.add(new Lambda_phage(prob_surface, prob_enzymes));\n\t}", "private static boolean testUpdateParticle() {\n\t\tparticles = new Particle[1];\n\t\tparticles[0] = new Particle(3, 3, 10, 10);\n\t\t\n\t\tparticles[0].setVelocityX(-1);\n\t\tparticles[0].setVelocityY(-2);\n\t\tupdateParticle(0);\n\t\t\n\t\tif (particles[0].getPositionX() != 2 || particles[0].getPositionY() != 1.3) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false; \n\t}", "public void spawnParticle ( Particle particle , double x , double y , double z , int count , double offsetX ,\n\t\t\tdouble offsetY , double offsetZ ) {\n\t\thandleOptional ( ).ifPresent ( handle -> {\n\t\t\tof ( particle ).display ( new Location ( getWorld ( ) , x , y , z ) ,\n\t\t\t\t\t\t\t\t\t ( float ) offsetX , ( float ) offsetY , ( float ) offsetZ ,\n\t\t\t\t\t\t\t\t\t 1.0F , count , null , handle );\n\t\t} );\n\t}", "public int getParticles() {\r\n\t\treturn particles;\r\n\t}", "public Particle(Point2D.Double c)\n {\n center = c;\n }", "private static void createNewParticles(int number) {\n\t\t// The following declarations are to initialize the random range for the \n\t\t// particle's feature\n\t\tint maxX = Fountain.positionX + 3;\n\t\tint minX = Fountain.positionX - 3;\n\t\tint boundX = maxX - minX;\n\t\tint maxY = Fountain.positionY + 3;\n\t\tint minY = Fountain.positionY - 3;\n\t\tint boundY = maxY - minY;\n\t\t\n\t\tint particleCount = 0; // For counting the new particles' amount\n\n\t\t\n\t\t\tfor (int i = 0; i < particles.length; i++) {\n\t\t\t\tif (particles[i] == null) {\n\t\t\t\t\t++particleCount;\n\t\t\t\t\t\n\t\t\t\t\t// Following codes are to prepare the setting for the particle\n\t\t\t\t\tint positionX = randGen.nextInt(boundX + 1) + maxX;\n\t\t\t\t\tint positionY = randGen.nextInt(boundY + 1) + maxY;\n\t\t\t\t\tfloat xVelocity = -1 + randGen.nextFloat() * (2);\n\t\t\t\t\tfloat yVelocity = -10 + randGen.nextFloat() * (5);\n\t\t\t\t\tfloat amount = randGen.nextFloat() * 1;\n\t\t\t\t\tint color = Utility.lerpColor(Fountain.startColor, Fountain.endColor, amount);\n\t\t\t\t\tfloat size = randGen.nextFloat() * (11 - 4);\n\t\t\t\t\tint age = randGen.nextInt(40 + 1);\n\t\t\t\t\tint transparency = randGen.nextInt((96)) + 32;\n\t\t\t\t\t\n\t\t\t\t\t// TO set the new particle with random feature\n\t\t\t\t\tparticles[i] = new Particle();\n\t\t\t\t\tparticles[i].setPositionX(positionX);\n\t\t\t\t\tparticles[i].setPositionY(positionY);\n\t\t\t\t\tparticles[i].setVelocityX(xVelocity);\n\t\t\t\t\tparticles[i].setVelocityY(yVelocity);\n\t\t\t\t\tparticles[i].setSize(size);\n\t\t\t\t\tparticles[i].setColor(color);\n\t\t\t\t\tparticles[i].setAge(age);\n\t\t\t\t\tparticles[i].setTransparency(transparency);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t// Once after creating 10 new particles, ends this method\n\t\t\t\tif (particleCount >= number) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}", "public void add(Particle particle) {\n this.particles.add(particle);\n }", "private ParticleEffectFactory(final Node root) {\r\n explosions = new ArrayList<ParticleMesh>();\r\n asteroidTrails = new ArrayList<ParticleMesh>();\r\n missileTrails = new ArrayList<ParticleMesh>();\r\n \r\n rootNode = root;\r\n \r\n DisplaySystem display = DisplaySystem.getDisplaySystem();\r\n bs = display.getRenderer().createBlendState();\r\n bs = DisplaySystem.getDisplaySystem().getRenderer().createBlendState();\r\n bs.setBlendEnabled(true);\r\n bs.setSourceFunction(BlendState.SourceFunction.SourceAlpha);\r\n bs.setDestinationFunction(BlendState.DestinationFunction.One);\r\n bs.setTestEnabled(true);\r\n bs.setTestFunction(BlendState.TestFunction.GreaterThan);\r\n\r\n ts = display.getRenderer().createTextureState();\r\n ts.setTexture(TextureManager.loadTexture(\r\n ResourceLocatorTool.locateResource(ResourceLocatorTool.TYPE_TEXTURE,\r\n \"data/textures/flaresmall.jpg\"), \r\n Texture.MinificationFilter.BilinearNoMipMaps,\r\n Texture.MagnificationFilter.Bilinear));\r\n\r\n zs = display.getRenderer().createZBufferState();\r\n zs.setWritable(false);\r\n zs.setEnabled(true);\r\n\r\n for (int i = 0; i < 5; i++) {\r\n createExplosion();\r\n }\r\n \r\n for (int i = 0; i < 5; i++) {\r\n createMissileTrail();\r\n }\r\n }", "public void update()\n {\n // start from the bottom of the world\n\n for (int y = height - 1; y >= 0; --y)\n {\n // compute offset to this and next line\n\n int thisOffset = y * width;\n \n // are we at top or bottom?\n\n boolean atTop = y == 0;\n boolean atBot = y == height - 1;\n\n // process line in random order\n \n for (int x: xRndIndex[rnd.nextInt(RND_INDEX_CNT)])\n {\n // index of this pixel\n \n int ip = thisOffset + x;\n \n // value of this pixel\n\n int p = pixels[ip];\n\n // don't process inert matter\n\n if (p == AIR || p == ROCK || p == EARTH)\n continue;\n\n // are we on a left or right edge?\n\n boolean atLeft = x == 0;\n boolean atRight = x == width - 1;\n\n // indices of pixels around this particle\n\n int iuc = ip - width;\n int idc = ip + width;\n int idl = idc - 1;\n int idr = idc + 1;\n int il = ip - 1;\n int ir = ip + 1;\n\n // get pixels for each index\n\n int uc = atTop ? ROCK : pixels[iuc];\n int dc = atBot ? ROCK : pixels[idc];\n int dl = atBot || atLeft ? ROCK : pixels[idl];\n int dr = atBot || atRight ? ROCK : pixels[idr];\n int l = atLeft ? ROCK : pixels[il];\n int r = atRight ? ROCK : pixels[ir];\n \n // the following actions propogate elements around the\n // world, they do not conserve matter\n\n // if fire, propogate fire\n\n if (p == FIRE1 || p == FIRE2 || p == FIRE3 || \n p == FIRE4 || p == FIRE5 || p == FIRE6)\n {\n int[] burn = {atLeft ? ip : il,\n atRight ? ip : ir,\n atTop ? ip : iuc,\n atBot ? ip : idc};\n\n\n for (int ib: burn)\n {\n int b = pixels[ib];\n\t\t\t\t\t \n\t\t\t\t\t // fire burns plants and oil, makes steam out of water\n\t\t\t\t\t \n if ((b == PLANT || b == OIL || b == COLUMBINE) &&\n rnd.nextInt(FIRE_CHANCE_IN) == 0)\n pixels[ib] = FIRE1;\n else\n if (b == WATER)\n {\n pixels[ib] = STEAM;\n pixels[ip] = STEAM;\n\t\t\t\t\t\t pixels[iuc] = STEAM;\n p = STEAM;\n break;\n }\n }\n // move fire along\n\n if (p == FIRE1)\n {\n pixels[ip] = FIRE3;\n continue;\n }\n if (p == FIRE2)\n {\n pixels[ip] = FIRE3;\n continue;\n }\n if (p == FIRE3)\n {\n pixels[ip] = FIRE4;\n continue;\n }\n if (p == FIRE4)\n {\n pixels[ip] = FIRE5;\n continue;\n }\n if (p == FIRE5)\n {\n pixels[ip] = FIRE6;\n continue;\n }\n if (p == FIRE6)\n {\n pixels[ip] = AIR;\n continue;\n }\n }\n // if this is steam, evaporate into air\n\n if (p == STEAM)\n { pixels[ip] = AIR;\n continue;\n\t\t\t }\n\n // if this is an everything sucker\n\n if (p == AIR_SOURCE)\n {\n int[] targets = {atLeft ? ip : il,\n atRight ? ip : ir,\n atTop ? ip : iuc,\n atBot ? ip : idc};\n for (int it: targets)\n pixels[it] = AIR;\n continue;\n }\n // if this is a water source\n\n if (p == WATER_SOURCE)\n {\n int[] targets = {atLeft ? ip : il,\n atRight ? ip : ir,\n atTop ? ip : iuc,\n atBot ? ip : idc};\n for (int it: targets)\n if (pixels[it] == AIR &&\n rnd.nextInt(WATER_CHANCE_IN) == 0)\n pixels[it] = WATER;\n continue;\n }\n // if this is a fire source\n\n if (p == OIL_SOURCE)\n {\n int[] targets = {atRight ? ip : ir,\n atLeft ? ip : il,\n atTop ? ip : iuc,\n atBot ? ip : idc};\n for (int it: targets)\n if (pixels[it] == AIR)\n pixels[it] = OIL;\n continue;\n }\n // if this is a sand source\n\n if (p == SAND_SOURCE)\n {\n int[] targets = {atLeft ? ip : il,\n atRight ? ip : ir,\n atTop ? ip : iuc,\n atBot ? ip : idc};\n for (int it: targets)\n if (pixels[it] == AIR &&\n rnd.nextInt(SAND_CHANCE_IN) == 0)\n pixels[it] = SAND;\n continue;\n }\n // if this is a plant, propogate growth\n\n if (p == PLANT)\n {\n\n int iul = iuc - 1;\n int iur = iuc + 1;\n\n int[] targets = {atLeft ? ip : il,\n atLeft || atTop ? ip : iul,\n atRight ? ip : ir,\n atRight || atTop ? ip : iur,\n atTop ? ip : iuc,\n atBot ? ip : idc,\n atBot || atLeft ? ip : idl,\n atBot || atRight ? ip : idr,\n };\n\t\t\t\t if (pixels[idl] == PLANT && pixels[idc] == PLANT && \n\t\t\t\t pixels[idr] == PLANT && pixels[ir] == PLANT && \n\t\t\t\t\t pixels[il] == PLANT && pixels[iuc] == WATER)\n\t\t\t\t\t pixels[ip] = COLUMBINE;\n for (int ix: targets)\n if (pixels[ix] == AIR)\n for (int it: targets)\n if (pixels[it] == WATER && rnd.nextInt(PLANT_CHANCE_IN) == 0)\n pixels[it] = PLANT;\n\t\t\t\t continue;\n }\n // if this is a flower\n\n if (p == COLUMBINE)\n\t\t\t {\n\t\t\t continue;\n\t\t\t }\n // if this is a fire source\n\n if (p == FIRE_SOURCE)\n {\n int[] targets = {atLeft ? ip : il,\n atRight ? ip : ir,\n atTop ? ip : iuc,\n atBot ? ip : idc};\n for (int it: targets)\n if (pixels[it] == PLANT || pixels[it] == OIL)\n pixels[it] = FIRE1;\n continue;\n }\n // all actions from this point on conserve matter\n // we only calculate the place to which this particle\n // will move, the the default is to do nothing\n\n int dest = NO_CHANGE;\n \n // if it's a oil\n\n if (p == OIL)\n {\n // compute indices for up left and up right\n\n int iul = iuc - 1;\n int iur = iuc + 1;\n\n // get pixels for each index\n\n int ul = atTop || atLeft ? ROCK : pixels[iul];\n int ur = atTop || atRight ? ROCK : pixels[iur];\n\n // if there is sand/earth above, erode that\n\n if (uc == EARTH || uc == SAND)\n dest = iuc; \n\n // if pixles up left and up right sand/water\n\n else if ((ul == EARTH || ul == SAND) && \n (ur == EARTH || ur == SAND))\n dest = rnd.nextBoolean() ? iul : iur;\n\n // if air underneath, go down\n \n else if (dc == AIR)\n dest = idc;\n \n // if air on both sides below, pick one\n\n else if (dl == AIR && dr == AIR)\n dest = rnd.nextBoolean() ? idl : idr;\n\n // if air only down left, go left\n\n else if (dl == AIR)\n dest = idl;\n\n // if air only down right, go right\n\n else if (dr == AIR)\n dest = idr;\n\n // if air on both sides below, pick one\n\n else if ((l == AIR || l == EARTH || l == SAND) &&\n (r == AIR || r == EARTH || r == SAND))\n dest = rnd.nextBoolean() ? il : ir;\n\n // if air only down left, go left\n\n else if (l == AIR || l == EARTH || l == SAND)\n dest = il;\n\n // if air only down right, go right\n\n else if (r == AIR || r == EARTH || r == SAND)\n dest = ir;\n\n // the case where water flows out two pixels\n \n else\n {\n // get items 2 pixels on either side of this one\n\n int ill = ip - 2;\n int irr = ip + 2;\n int ll = x < 2 ? ROCK : pixels[ill];\n int rr = x > width - 3 ? ROCK : pixels[irr];\n\n // if air on both sides, pick one\n\n if (ll == AIR && rr == AIR)\n dest = rnd.nextBoolean() ? irr : ill;\n \n // if air only right right, go right right\n \n else if (rr == AIR)\n dest = irr;\n \n // if air only left left, go left left\n\n else if (ll == AIR)\n dest = ill;\n }\n }\n // if it's water\n\n else if (p == WATER)\n {\n // compute indices for up left and up right\n\n int iul = iuc - 1;\n int iur = iuc + 1;\n\n // get pixels for each index\n\n int ul = atTop || atLeft ? ROCK : pixels[iul];\n int ur = atTop || atRight ? ROCK : pixels[iur];\n\n // if there is sand/earth above, erode that\n\n if (uc == EARTH || uc == SAND)\n dest = iuc; \n\n // if pixles up left and up right sand/water\n\n else if ((ul == EARTH || ul == SAND) && \n (ur == EARTH || ur == SAND))\n dest = rnd.nextBoolean() ? iul : iur;\n\n // if air underneath, go down\n \n else if (dc == AIR || dc == OIL)\n dest = idc;\n\n // if air on both sides below, pick one\n\n else if ((dl == AIR || dl == OIL) && (dr == AIR || dr == OIL))\n dest = rnd.nextBoolean() ? idl : idr;\n\n // if air only down left, go left\n\n else if (dl == AIR || dl == OIL)\n dest = idl;\n\n // if air only down right, go right\n\n else if (dr == AIR || dr == OIL)\n dest = idr;\n\n // if air on both sides below, pick one\n\n else if ((l == AIR || l == EARTH || l == SAND) &&\n (r == AIR || r == EARTH || r == SAND))\n dest = rnd.nextBoolean() ? il : ir;\n\n // if air only down left, go left\n\n else if (l == AIR || l == EARTH || l == SAND)\n dest = il;\n\n // if air only down right, go right\n\n else if (r == AIR || r == EARTH || r == SAND)\n dest = ir;\n\n // the case where water flows out two pixels\n \n else\n {\n // get items 2 pixels on either side of this one\n\n int ill = ip - 2;\n int irr = ip + 2;\n int ll = x < 2 ? ROCK : pixels[ill];\n int rr = x > width - 3 ? ROCK : pixels[irr];\n\n // if air on both sides, pick one\n\n if (ll == AIR && rr == AIR)\n dest = rnd.nextBoolean() ? irr : ill;\n \n // if air only right right, go right right\n \n else if (rr == AIR)\n dest = irr;\n \n // if air only left left, go left left\n\n else if (ll == AIR)\n dest = ill;\n }\n }\n // all other elements behave like sand\n\n else\n {\n // if air underneath, go down\n \n if (dc == AIR || dc == WATER)\n dest = idc;\n\n // if air on both sides below, pick one\n\n else if ((dl == AIR || dl == WATER) && \n (dr == AIR || dr == WATER))\n dest = rnd.nextBoolean() ? idl : idr;\n\n // if air only down left, go left\n\n else if (dl == AIR || dl == WATER)\n dest = idl;\n\n // if air only down right, go right\n\n else if (dr == AIR || dr == WATER)\n dest = idr;\n }\n // if a change is requried, swap pixles\n\n try\n {\n if (dest != NO_CHANGE)\n {\n if (pixels[ip] == WATER_SOURCE)\n out.println(\"swap1 WS & \" + Element.lookup(pixels[dest]));\n if (pixels[dest] == WATER_SOURCE)\n out.println(\"swap2 WS & \" + Element.lookup(pixels[ip]));\n\n pixels[ip] = pixels[dest];\n pixels[dest] = p;\n }\n }\n catch (Exception ex)\n {\n ex.printStackTrace();\n out.println(\" X: \" + x);\n out.println(\" Y: \" + y);\n out.println(\"Source: \" + Element.lookup(p));\n out.println(\"Source: \" + Element.lookup(pixels[ip]));\n out.println(\" Dest: \" + Element.lookup(pixels[dest]));\n \n }\n }\n }\n }", "@Override\n public SpriteParticleSystem build(Engine engine, float fontX, float fontY)\n {\n\t final float particlesXSpawn = fontX;\n\t final float particlesYSpawn = fontY;\n\n\t //Max & min rate are the maximum particles per second and the minimum particles per second.\n\t final float maxRate = 100;\n\t final float minRate = 80;\n\n\t //This variable determines the maximum particles in the particle system.\n\t final int maxParticles = 30;\n\n\t //Particle emitter which will set all of the particles at a ertain point when they are initialized.\n\t final PointParticleEmitter pointParticleEmtitter = new PointParticleEmitter(particlesXSpawn, particlesYSpawn);\n\n\t //Creating the particle system.\n\t\tparticleSystem = new SpriteParticleSystem (pointParticleEmtitter, maxRate, minRate, maxParticles, ResourcesManager.getInstance().waterDrop, vbom);\n\n\t //And now, lets create the initiallizers and modifiers.\n\t //Velocity initiallizer - will pick a random velocity from -20 to 20 on the x & y axes. Play around with this value.\n\t particleSystem.addParticleInitializer(new VelocityParticleInitializer<Sprite>(-25, 25, 0, 150));\n\n\t //Acceleration initializer - gives all the particles the earth gravity (so they accelerate down).\n\t particleSystem.addParticleInitializer(new GravityParticleInitializer<Sprite>());\n\n\t //And now, adding an alpha modifier, so particles slowly fade out. This makes a particle go from alpha = 1 to alpha = 0 in 3 seconds, starting exactly when the particle is spawned.\n\t //particleSystem.addParticleModifier(new AlphaParticleModifier<Sprite>(1, 0, 0, 0));\n\n\t //Lastly, expire modifier. Make particles die after 3 seconds - their alpha reached 0.\n\t particleSystem.addParticleInitializer(new ExpireParticleInitializer<Sprite>(3)); \n\n\t return particleSystem;\n}", "public EntityDataParticle() {\n\t\tm_speed=0.5f;\n\t\tm_rotation=0;\n\t\tm_duration=0.5f;\n\t\tm_type=0;\n\t}", "public void onUpdate() {\n/* 150 */ this.prevPosX = this.posX;\n/* 151 */ this.prevPosY = this.posY;\n/* 152 */ this.prevPosZ = this.posZ;\n/* */ \n/* 154 */ if (this.particleAge++ >= this.particleMaxAge)\n/* */ {\n/* 156 */ setDead();\n/* */ }\n/* */ \n/* 159 */ this.motionY -= 0.04D * this.particleGravity;\n/* 160 */ moveEntity(this.motionX, this.motionY, this.motionZ);\n/* 161 */ this.motionX *= 0.9800000190734863D;\n/* 162 */ this.motionY *= 0.9800000190734863D;\n/* 163 */ this.motionZ *= 0.9800000190734863D;\n/* */ \n/* 165 */ if (this.onGround) {\n/* */ \n/* 167 */ this.motionX *= 0.699999988079071D;\n/* 168 */ this.motionZ *= 0.699999988079071D;\n/* */ } \n/* */ }", "public Particle(int x, int y, int life) {\n this.x = x;\n this.y = y;\n this.xDouble = x;\n this.yDouble = y;\n this.zDouble = 0.0;\n this.life = life + (random.nextInt(life) - life / 2);\n this.sprite = particle_normal;\n\n // Sets the distance delta for the particle to travel to a\n // random (bell-curved) value in the range -1 to 1\n this.xDelta = random.nextGaussian() / 2;\n this.yDelta = random.nextGaussian() / 2;\n this.zDelta = random.nextFloat() + 1.5;\n }", "void effect(Entity e, BoardPosition bp);", "@Test\n\tpublic void simpleAdvances() {\n\t\tmodel.addParticle(new Vector(300, 300), 1.0, new Vector(), 10.0);\n\t\tmodel.advance();\n\t\t//StdOut.println(\"\" + model.getParticleAt(0).getPosition().toString());\n\t}", "private float[] generateParticleVelocities()\n {\n float velocities[] = new float[mEmitRate * 3];\n for ( int i = 0; i < mEmitRate * 3; i +=3 )\n {\n Vector3f nexVel = getNextVelocity();\n velocities[i] = nexVel.x;\n velocities[i+1] = nexVel.y;\n velocities[i+2] = nexVel.z;\n }\n return velocities;\n }", "@Override\r\n\tpublic void onUpdate()\r\n {\r\n \t//update pos\r\n\t\tthis.prevPosX = this.posX;\r\n this.prevPosY = this.posY;\r\n this.prevPosZ = this.posZ;\r\n \r\n if(host != null)\r\n {\r\n \tupdateHostPosition();\r\n }\r\n \r\n //fade state\r\n switch (this.fadeState)\r\n {\r\n case 0: //fade in\r\n \tthis.fadeTick++;\r\n \tthis.particleAlpha = this.fadeTick * 0.2F;\r\n \t\r\n \tif (this.fadeTick > 5) this.fadeState = 1;\r\n \tbreak;\r\n case 1: //age++\r\n \tthis.playSpeedCount += this.playSpeed;\r\n \tthis.particleAge = this.frameSize * (int)this.playSpeedCount;\r\n \tthis.particleAlpha = 1F;\r\n \tbreak;\r\n case 2: //fade out\r\n \tthis.fadeTick--;\r\n \tthis.particleAlpha = this.fadeTick * 0.2F;\r\n \t\r\n \tif (this.fadeTick < 1)\r\n \t{\r\n \t\tthis.setExpired();\r\n \t\treturn;\r\n \t}\r\n \tbreak;\r\n \tdefault:\r\n \t\tthis.setExpired();\r\n \t\treturn;\r\n }\r\n \r\n //stay at last frame\r\n if (this.particleAge >= particleMaxAge)\r\n {\r\n \t\tthis.particleAge = this.particleMaxAge;\r\n \t\t\r\n \t\t//count stay ticks\r\n \t\tif (this.stayTickCount > this.stayTick)\r\n \t\t{\r\n \t\t\tthis.particleAge = this.particleMaxAge + 1; //next loop flag\r\n \t\t\tthis.stayTickCount = 0;\r\n \t\t}\r\n \t\telse\r\n \t\t{\r\n \t\t\tthis.stayTickCount += 1;\r\n \t\t}\r\n \t}\r\n\r\n //loop play\r\n if (this.particleAge > this.particleMaxAge)\r\n {\r\n \t//loop times--\r\n \tif (--this.playTimes <= 0)\r\n \t{\r\n \t\tthis.fadeState = 2; //change to fade out\r\n \t}\r\n \telse\r\n \t{\r\n \t\tthis.particleAge = 0;\r\n \t\tthis.playSpeedCount = 0F;\r\n \t}\r\n }\r\n }", "public void spawnParticle ( Particle particle , double x , double y , double z , int count ) {\n\t\thandleOptional ( ).ifPresent ( handle -> {\n\t\t\tof ( particle ).display ( new Location ( getWorld ( ) , x , y , z ) ,\n\t\t\t\t\t\t\t\t\t 0.0F , 0.0F , 0.0F , 1.0F , count , null , handle );\n\t\t} );\n\t}", "public ArrayList<Particle> getParticles()\n\t{\n\t\treturn particles;\n\t}", "public void effect() {\n }", "public ParticleEmotion(World world, Entity host, double posX, double posY, double posZ, float height, int hostType, int emoType)\r\n {\r\n super(world, posX, posY, posZ);\r\n this.host = host;\r\n this.setSize(0F, 0F);\r\n this.setPosition(posX, posY, posZ);\r\n this.prevPosX = posX;\r\n this.prevPosY = posY;\r\n this.prevPosZ = posZ;\r\n this.motionX = 0D;\r\n this.motionZ = 0D;\r\n this.motionY = 0D;\r\n this.particleType = emoType;\r\n this.particleScale = this.rand.nextFloat() * 0.05F + 0.275F;\r\n this.particleAlpha = 0F;\r\n this.playSpeed = 1F;\r\n this.playSpeedCount = 0F;\r\n this.stayTick = 10;\r\n this.stayTickCount = 0;\r\n this.fadeTick = 0;\r\n this.fadeState = 0; //0:fade in, 1:normal, 2:fade out, 3:set dead\r\n this.frameSize = 1;\r\n this.addHeight = height;\r\n this.hostType = hostType; //0:any entity, 1:entity, 2:block\r\n this.particleAge = -1; //prevent showing the emo's initial moving from posY = 0\r\n this.canCollide = false;\r\n \r\n //set icon position\r\n switch(this.particleType)\r\n {\r\n case 1: //小愛心\r\n \tthis.particleIconX = 0.0625F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 4;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n\t\t\tbreak;\r\n case 2: //噴汗\r\n \tthis.particleIconX = 0.0625F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 3;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 5;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \tbreak;\r\n case 3: //問號\r\n \tthis.particleIconX = 0.125F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n\t\t\tbreak;\r\n case 4: //驚嘆號\r\n \tthis.particleIconX = 0.125F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//long stay\r\n \tthis.stayTick = 20;\r\n \tbreak;\r\n case 5: //點點點\r\n \tthis.particleIconX = 0.1875F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 20;\r\n \t//slow play\r\n \tthis.playSpeed = 0.5F;\r\n\t\t\tbreak;\r\n case 6: //冒青筋\r\n \tthis.particleIconX = 0.1875F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \tbreak;\r\n case 7: //音符\r\n \tthis.particleIconX = 0.25F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 15;\r\n \tthis.playTimes = 1;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//short stay\r\n \tthis.stayTick = 3;\r\n \t//slow play\r\n \tthis.playSpeed = 0.7F;\r\n \tbreak;\r\n case 8: //cry\r\n \tthis.particleIconX = 0.3125F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 3;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \t//slow play\r\n \tthis.playSpeed = 0.5F;\r\n \tbreak;\r\n case 9: //流口水\r\n \tthis.particleIconX = 0.3125F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 2;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//no stay\r\n \tthis.stayTick = 1;\r\n \t//slow play\r\n \tthis.playSpeed = 0.5F;\r\n \tbreak;\r\n case 10: //混亂\r\n \tthis.particleIconX = 0.375F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 4;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//short stay\r\n \tthis.stayTick = 1;\r\n \tbreak;\r\n case 11: //尋找\r\n \tthis.particleIconX = 0.375F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 2;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//short stay\r\n \tthis.stayTick = 0;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \tbreak;\r\n case 12: //驚嚇\r\n \tthis.particleIconX = 0.4375F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 14;\r\n \tthis.playTimes = 1;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//long stay\r\n \tthis.stayTick = 20;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \t//large frame\r\n \tthis.frameSize = 2;\r\n \tbreak;\r\n case 13: //點頭\r\n \tthis.particleIconX = 0.5F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 2;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \tbreak;\r\n case 14: //+_+\r\n \tthis.particleIconX = 0.5F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 2;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \tbreak;\r\n case 15: //kiss\r\n \tthis.particleIconX = 0.5625F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//long stay\r\n \tthis.stayTick = 15;\r\n \t//slow play\r\n \tthis.playSpeed = 0.7F;\r\n \tbreak;\r\n case 16: //lol\r\n \tthis.particleIconX = 0.5625F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 3;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \tbreak;\r\n case 17: //奸笑\r\n \tthis.particleIconX = 0.625F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 15;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//slow play\r\n \tthis.playSpeed = 0.5F;\r\n \tbreak;\r\n case 18: //殘念\r\n \tthis.particleIconX = 0.6875F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \t//slow play\r\n \tthis.playSpeed = 0.4F;\r\n \tbreak;\r\n case 19: //舔舔\r\n \tthis.particleIconX = 0.6875F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 3;\r\n \t//cancel fade in\r\n \tthis.particleAlpha = 1F;\r\n \tthis.fadeState = 1;\r\n \tthis.fadeTick = 3;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \tbreak;\r\n case 20: //orz\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//long stay\r\n \tthis.stayTick = 20;\r\n \t//slow play\r\n \tthis.playSpeed = 0.5F;\r\n \tbreak;\r\n case 21: //O\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 22: //X\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.5625F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 23: //!?\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.625F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 24: //rock\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.6875F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 25: //paper\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.75F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 26: //scissors\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.8125F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 27: //-w-\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.875F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 28: //-口-\r\n \tthis.particleIconX = 0.75F;\r\n \tthis.particleIconY = 0.9375F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 40;\r\n \tbreak;\r\n case 29: //blink\r\n \tthis.particleIconX = 0.8125F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//slow play\r\n \tthis.playSpeed = 0.35F;\r\n \t//long stay\r\n \tthis.stayTick = 20;\r\n \tbreak;\r\n case 30: //哼\r\n \tthis.particleIconX = 0.8125F;\r\n \tthis.particleIconY = 0.5F;\r\n \tthis.particleMaxAge = 7;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \t//short stay\r\n \tthis.stayTick = 3;\r\n \tbreak;\r\n case 31: //臉紅紅\r\n \tthis.particleIconX = 0.875F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 3;\r\n \tthis.particleScale += 0.2F;\r\n \tthis.playTimes = 1;\r\n \t//short fade in\r\n \tthis.fadeTick = 3;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \t//long stay\r\n \tthis.stayTick = 30;\r\n \tbreak;\r\n case 32: //尷尬\r\n \tthis.particleIconX = 0.875F;\r\n \tthis.particleIconY = 0.25F;\r\n \tthis.particleMaxAge = 5;\r\n \tthis.playTimes = 4;\r\n \t//slow play\r\n \tthis.playSpeed = 0.75F;\r\n \t//no stay\r\n \tthis.stayTick = 0;\r\n \tbreak;\r\n case 33: //:P\r\n \tthis.particleIconX = 0.875F;\r\n \tthis.particleIconY = 0.625F;\r\n \tthis.particleMaxAge = 4;\r\n \tthis.playTimes = 1;\r\n \t//slow play\r\n \tthis.playSpeed = 0.25F;\r\n \t//long stay\r\n \tthis.stayTick = 30;\r\n \tbreak;\r\n case 34: //|||\r\n \tthis.particleIconX = 0.875F;\r\n \tthis.particleIconY = 0.9375F;\r\n \tthis.particleMaxAge = 0;\r\n \tthis.particleScale += 0.3F;\r\n \tthis.playTimes = 1;\r\n \t//long stay\r\n \tthis.stayTick = 50;\r\n \tbreak;\r\n default: //汗\r\n \tthis.particleIconX = 0F;\r\n \tthis.particleIconY = 0F;\r\n \tthis.particleMaxAge = 15;\r\n \tthis.playTimes = 1;\r\n\t\t\tbreak;\r\n }\r\n \r\n //init position\r\n this.px = posX;\r\n this.py = posY;\r\n this.pz = posZ;\r\n this.addx = 0D;\r\n this.addy = 0D;\r\n this.addz = 0D;\r\n \r\n calcParticlePosition();\r\n }", "public static void main(String[] args) {\n double T = Double.parseDouble(args[0]);\n double deltaT = Double.parseDouble(args[1]);\n \n // declares double t, sets to 0\n double t = 0.0;\n \n // declares and sets gravitational constant\n double g = 6.67e-11;\n \n // declares string \"background\" for background image\n String background = \"starfield.jpg\";\n \n // read the first 2 input values from the input\n int N = StdIn.readInt();\n double R = StdIn.readDouble();\n \n // sets the size of the universe\n setUniverse(R);\n \n // declare arrays for each category, each of which has\n // N elements, one for each particle\n double[] px = new double[N]; // array for position of x\n double[] py = new double[N]; // array for position of y\n double[] vx = new double[N]; // array for velocity of x\n double[] vy = new double[N]; // array for velocity of y\n double[] mass = new double[N]; // array for mass\n String[] picture = new String[N]; // array for pictures of particles\n \n \n // fills each array with input information\n for (int i = 0; i < N; i++) {\n \n px[i] = StdIn.readDouble();\n py[i] = StdIn.readDouble();\n vx[i] = StdIn.readDouble();\n vy[i] = StdIn.readDouble();\n mass[i] = StdIn.readDouble();\n picture[i] = StdIn.readString();\n \n }\n \n // draw the universe background\n drawUniverse(background);\n \n // draw each particle in its initial position:\n for (int i = 0; i < N; i++) {\n StdDraw.picture(px[i], py[i], picture[i]);\n }\n \n// Part 3: Update the universe at each time-step\n \n // The following while loop will allow us to calculate the\n // change in position for each particle (based on the force\n // from all other particles), and then redraw the background\n // and particles. The loop also tallies how much \"time\" \n // has gone by so that once the time has summed to T, \n // the program stops executing.\n \n while (t < T) {\n \n // declare new arrays forcex and forcey for the\n // x and y components of the force for each planet\n _______________________________;\n _______________________________;\n \n // In the next section, we want to calculate the force that each\n // body experiences, from all the other bodies combined. To do this,\n // we will need to use a double for loop. It is your job to figure\n // out what happens in each for loop.\n \n // For each body x, for each body y, you'll want to calculate the force\n // that y exerts on x, which is a function of the distance between\n // x and y and the size of x and y. You'll calculate both the force\n // in the x direction and the force in the y direction.\n \n // fills the arrays, with each element\n // corresponding to a different particle\n for (______________________) {\n \n // Runs through the particles, calculating the force\n // from each particle j on the particle i in question\n for (______________________) {\n \n // declares variables for x and y distances between the bodies\n double dx = _______________;\n double dy = _______________;\n \n // calculates the distance between planets i and j\n // note: you can use a method for this!\n double distance = _____________________;\n \n // calculates the overall force between i and j\n double forcej = _______________;\n \n // calculates x and y components of force between i and j\n double forcejx = ______________________;\n double forcejy = ______________________;\n \n // keep track of the net force on particle i \n // in both x and y directions\n forcex[i] = ______________________;\n forcey[i] = ______________________;\n \n }\n }\n \n // draw the universe background\n _______________________________;\n \n // calculate the new velocity and position for each particle\n for (int i = 0; i < N; i++) {\n \n // calculates acceleration in x and y directions\n double ax = _____________________________;\n double ay = _____________________________;\n \n // calculates velocity in x and y directions\n vx[i] = _____________________________;\n vy[i] = _____________________________;\n \n // calculates new x and y coordinates\n // to determine position\n px[i] = _____________________________;\n py[i] = _____________________________;\n \n // draws each particle in its new position\n _____________________________________;\n \n }\n \n // waits 40 milliseconds before continuing\n StdDraw.show();\n StdDraw.pause(20);\n \n // increments t by deltaT\n t = t + deltaT;\n \n }\n \n \n \n \n }", "public ParticleEffects(Player player, ProtectedRegion region)\n {\n this.player = player;\n this.region = region;\n this.timer = 20;\n\n if (activePlayer == null)\n activePlayer = new HashMap<>();\n\n if (activePlayer.containsKey(player))\n {\n Bukkit.getScheduler().cancelTask(activePlayer.get(player));\n activePlayer.remove(player);\n }\n\n this.runTaskTimer(Claim.getInstance(), 5L, 15L);\n\n activePlayer.put(player, this.getTaskId());\n }", "public Particle(double xstart, double ystart, double velx, double vely, Compound c) {\r\n\t\tpos = new Vector(xstart, ystart);\r\n\t\tvel = new Vector(velx, vely);\r\n\t\tcompound = c;\r\n\t\tactivated = false;\r\n\t}", "public Particle(double x, double y, int depth)\n\t{\n\t\tposition = new Vec3f(x,y,0);\n\t\tthis.depth=depth;\n\t}", "@Override\n public void effect() {\n\n }", "public PotionEffect(int id, int duration, int amplifier, boolean ambient, boolean showParticles)\r\n/* 26: */ {\r\n/* 27: 36 */ this.id = id;\r\n/* 28: 37 */ this.duration = duration;\r\n/* 29: 38 */ this.amplifier = amplifier;\r\n/* 30: 39 */ this.ambient = ambient;\r\n/* 31: 40 */ this.showParticles = showParticles;\r\n/* 32: */ }", "private ParticleMesh createExplosion() {\r\n ParticleMesh pMesh = ParticleFactory.buildParticles(\"explosion\", 30);\r\n pMesh.setEmissionDirection(new Vector3f(0.0f, 1.0f, 0.0f));\r\n pMesh.setMaximumAngle(3.1415927f);\r\n pMesh.setMinimumAngle(0);\r\n pMesh.getParticleController().setSpeed(0.1f);\r\n pMesh.setMinimumLifeTime(20.0f);\r\n pMesh.setMaximumLifeTime(150.0f);\r\n pMesh.setStartSize(15);\r\n pMesh.setEndSize(2);\r\n pMesh.getParticleController().setControlFlow(false);\r\n pMesh.getParticleController().setRepeatType(Controller.RT_CLAMP);\r\n pMesh.warmUp(80);\r\n pMesh.setInitialVelocity(2.5f);\r\n pMesh.setStartColor(new ColorRGBA(1.0f, 0.312f, 0.121f, 1.0f));\r\n pMesh.setEndColor(new ColorRGBA(1.0f, 0.24313726f, 0.03137255f, 0.0f));\r\n pMesh.setRenderState(ts);\r\n pMesh.setRenderState(bs);\r\n pMesh.setRenderState(zs);\r\n\r\n rootNode.attachChild(pMesh);\r\n rootNode.updateRenderState();\r\n \r\n explosions.add(pMesh);\r\n \r\n return pMesh;\r\n }", "public Particle(Point[] landmarks, int width, int height) {\r\n this.landmarks = landmarks;\r\n this.worldWidth = width;\r\n this.worldHeight = height;\r\n random = new Random();\r\n x = random.nextFloat() * width;\r\n y = random.nextFloat() * height;\r\n orientation = random.nextFloat() * 2f * ((float)Math.PI);\r\n forwardNoise = 0f;\r\n turnNoise = 0f;\r\n senseNoise = 0f; \r\n }", "public FallingParticle(double m,double d) {\r\n\t\t\t\tthis.m = m;\r\n\t\t\t\tthis.d = d;\r\n\t\t\t\t\t\t\t\r\n\t\t}", "public void nextTextureIndexX() {\n/* 245 */ this.particleTextureIndexX++;\n/* */ }", "public void onTick() {\n // Tick all particles\n Iterator<Particle> iterator = this.particles.iterator();\n while (iterator.hasNext()) {\n Particle particle = iterator.next();\n\n // Tick this particle\n particle.onTick();\n\n // Remove particle when removed flag is set\n if (particle.removed) {\n iterator.remove();\n }\n }\n }", "protected void updateImpl(@NotNull final ParticleData particleData, final float tpf) {\n\n }", "public void update() {\n Iterator<Particle> iter = particles.iterator();\n\n while (iter.hasNext()) {\n Particle p = iter.next();\n if (p.isDead()) {\n iter.remove();\n } else {\n p.update();\n }\n }\n }", "public void place (Particle particle)\n {\n _layer.pointToLayer(place(particle.getPosition()), true);\n }", "PositionEffect getPositionEffect();", "private void displayParticles(Player p, double radius, ParticleColor color){\n //just some math to create a circle, and send it to the player. z+0.1f so they arent inside of the bottom block.\n double part = 2 * Math.PI / particlePoints;\n for (int i = 0; i < particlePoints; i++)\n {\n double alpha = part * i;\n float x = (float) (location.getX() + radius * Math.cos(alpha));\n float z = (float) (location.getZ() + radius * Math.sin(alpha));\n float y = (float) (location.getY()+0.1f);\n PacketHelper.displaySingleParticle(p, x, y, z, color);\n }\n }", "public Particle(String id, String spritename) {\r\n\t\tsuper(id);\r\n\t\tsprite = Sprite.getSprite(spritename); //FIXME: use a generic particle sprite\r\n\t}", "public void setAlphaF(float p_82338_1_) {\n/* 102 */ if (this.particleAlpha == 1.0F && p_82338_1_ < 1.0F) {\n/* */ \n/* 104 */ (Minecraft.getMinecraft()).effectRenderer.func_178928_b(this);\n/* */ }\n/* 106 */ else if (this.particleAlpha < 1.0F && p_82338_1_ == 1.0F) {\n/* */ \n/* 108 */ (Minecraft.getMinecraft()).effectRenderer.func_178931_c(this);\n/* */ } \n/* */ \n/* 111 */ this.particleAlpha = p_82338_1_;\n/* */ }", "private void createParticleOutsideOfBB(){\n\t\tint x = 0;\n\t\tint y = 0;\n\t\tint r = randInt.getRandInt(1, 4);\n\t\tif(movementType == 0){\n\t\t\tx = randInt.getRandInt(0,xMin);\n\t\t\ty = randInt.getRandInt(0,799);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tswitch (r) {\n\t\t\tcase 1: \n\t\t\t\tx = randInt.getRandInt(0,599);\n\t\t\t\ty = randInt.getRandInt(0,yMin);\n\t\t\t\tbreak;\n\t\t\tcase 2:\n\t\t\t\tx = randInt.getRandInt(0,599);\n\t\t\t\ty = randInt.getRandInt(yMax,799);\n\t\t\t\tbreak;\n\t\t\tcase 3:\n\t\t\t\tx = randInt.getRandInt(0,xMin);\n\t\t\t\ty = randInt.getRandInt(0,799);\n\t\t\t\tbreak;\n\t\t\tcase 4:\n\t\t\t\tx = randInt.getRandInt(xMax,599);\n\t\t\t\ty = randInt.getRandInt(0,799);\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\tparticleCollection.add(new Particle(x,y,1,1,width,height,randInt.getRandInt(0,1),randInt.getRandInt(0,1),worldMatrix));\n\t}", "public ParticleHandler getParticleHandler() {\n return particleHandler;\n }", "public void onUpdate()\n {\n this.prevPosX = this.posX;\n this.prevPosY = this.posY;\n this.prevPosZ = this.posZ;\n this.motionY -= 0.03999999910593033D;\n this.moveEntity(this.motionX, this.motionY, this.motionZ);\n this.motionX *= 0.9800000190734863D;\n this.motionY *= 0.9800000190734863D;\n this.motionZ *= 0.9800000190734863D;\n\n if (this.onGround)\n {\n this.motionX *= 0.699999988079071D;\n this.motionZ *= 0.699999988079071D;\n this.motionY *= -0.5D;\n }\n\n if (this.fuse-- <= 0)\n {\n if (!this.worldObj.isRemote)\n {\n this.setDead();\n this.explode();\n }\n } else\n {\n this.worldObj.spawnParticle(\"smoke\", this.posX, this.posY + 0.5D, this.posZ, 0.0D, 0.0D, 0.0D);\n }\n }", "public interface IParticleProviderModel extends IBakedModel {\n\n// /**\n// * Gets the textures to use for hit particles at the given face and hit vector.\n// *\n// * @param hitVec The vector.\n// * @param faceHit The face.\n// * @param world The world.\n// * @param pos The position.\n// * @param state The state.\n// * @return The textures to use.\n// */\n// Iterable<TextureAtlasSprite> getHitEffects(Vector3 hitVec, EnumFacing faceHit, IBlockAccess world, BlockPos pos, IBlockState state);\n//\n// /**\n// * Gets the textures to use for destroy particles.\n// *\n// * @param world The world.\n// * @param pos The position.\n// * @param state The state.\n// * @return The textures to use.\n// */\n// Iterable<TextureAtlasSprite> getDestroyEffects(IBlockAccess world, BlockPos pos, IBlockState state);\n\n}", "public PotionEffect(PotionEffect paramwq)\r\n/* 35: */ {\r\n/* 36: 44 */ this.id = paramwq.id;\r\n/* 37: 45 */ this.duration = paramwq.duration;\r\n/* 38: 46 */ this.amplifier = paramwq.amplifier;\r\n/* 39: 47 */ this.ambient = paramwq.ambient;\r\n/* 40: 48 */ this.showParticles = paramwq.showParticles;\r\n/* 41: */ }", "public void poke(int mouse_x, int mouse_y) {\n\t\tint distance = 0;\n\t\tint i=0;\n\t\tfor (Particle p : pm.particlesystem) {\n\t\t\t//distance = p.getDistance(mouse_x, mouse_y);\n\t\t\tif(distance <= orad+200){//Ändern!\n\t\t\t\tSystem.out.println(i);\n\t\t\t\tparticle = p;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\ti++;\n\t\t}\n\t\t\n\t\tSystem.out.println(\"Poke erkannt!\");\n\t\tSystem.out.println(particle.getSpeed(0));\n\t\tSystem.out.println(particle.getSpeed(1));\n\t\tparticle.setSpeed(20, 20);\n\t\t\n\t\t\n\t\tSystem.out.println(particle.getSpeed(0));\n\t\tSystem.out.println(particle.getSpeed(1));\n\t\t\n\t\t\n//\t\tfor(int i = 0; i < 100; i++){\n//\t\t\tTestController.wait(300);\n//\t\t\tgui.repaint();\n//\t\t}\n\t\t\n\t}", "public Particle(FitnessFunction fitnessFunc){\n rnd = new Random();\n position = new double[2];\n position[0] = rnd.nextDouble()*(upperp - lowerp) + lowerp;\n position[1] = rnd.nextDouble()*(upperp - lowerp) + lowerp;\n pbest = position;\n v = new double[2];\n v[0] = rnd.nextDouble()*(upperv - lowerv) + lowerv;\n v[1] = rnd.nextDouble()*(upperv - lowerv) + lowerv;\n this.fitnessFunction = fitnessFunc;\n }", "public void spawnParticle ( Particle particle , Location location , int count , double offsetX , double offsetY ,\n\t\t\tdouble offsetZ , double extra ) {\n\t\thandleOptional ( ).ifPresent ( handle -> {\n\t\t\tof ( particle ).display ( location ,\n\t\t\t\t\t\t\t\t\t ( float ) offsetX , ( float ) offsetY , ( float ) offsetZ ,\n\t\t\t\t\t\t\t\t\t 1.0F , count , null , handle );\n\t\t} );\n\t}", "public static void tick() {\n try {\n getActiveParticles().stream().filter((p) -> (p != null)).filter((p) -> (p.active)).forEach((p) -> {\n p.tick();\n });\n } catch (java.util.ConcurrentModificationException ex) {}\n }", "public void afterTick(ParticleField field){\n }", "public void draw() {\n\t\tfor (int i = 0; i < particleCount; i++) {\r\n\t\t\tif (particles[i] != null) {\r\n\t\t\t\tglBegin(GL_QUADS);\r\n\t\t\t\t{\r\n\t\t\t\t\tparticles[i].draw();\r\n\t\t\t\t}\r\n\t\t\t\tglEnd();\r\n\t\t\t}\r\n\t\t}\r\n\t\tglColor3f(1, 1, 1);\r\n\t}", "@Override\n\tpublic ParticleEffect load(AssetManager manager, String fileName, FileHandle file,\n\t\t\tParticleEffectParameter parameter) {\n\t\tParticleEffect effect = new ParticleEffect();\n\t\teffect.load(file, file.parent());\n\t\treturn effect;\n\t}", "public void addRandomParticles(int n, Compound c, double temperature) {\r\n\t\tVector dim = Vector.sub(phys.getboundBR(), phys.getboundTL());\r\n\t\tVector center = Vector.add(phys.getboundBR(), phys.getboundTL()).mul(0.5);\r\n\t\tfor (int i = 0; i < n; i++) {\r\n\t\t\tdouble angle = Math.random()*2.0*Math.PI;\r\n\t\t\tdouble speed = Math.sqrt(PhysicsSimulation.BOLTZMANN * temperature * 3.0 / c.getmass());\r\n\t\t\tParticle p = new Particle((Math.random() - 0.5)*dim.x + center.x, (Math.random() - 0.5)*dim.y + center.y, speed * Math.cos(angle), speed * Math.sin(angle), c);\r\n\t\t\tphys.addParticle(p);\r\n\r\n\t\t\t//System.out.println(p.getVelocity());\r\n\t\t\t//System.out.println(p.getPosition());\r\n\t\t\t\r\n\t\t}\r\n\t}", "public Explosion(int particleNr, int x, int y) {\r\n\t\tthis.state = STATE_ALIVE;\r\n\t\tthis.particles = new Particle[particleNr];\r\n\t \tfor (int i = 0; i < this.particles.length; i++) {\r\n\t\t\tParticle p = new Particle(x, y);\r\n\t\t\tthis.particles[i] = p;\r\n\t\t}\r\n\t \tthis.size = particleNr;\r\n\t}", "@Override\n\tprotected void enterEffect() {\n\t\t\n\t}", "private void calculateRecForces(){\n\t\t\n\t\t\n\t\tfor(Particle p : this){\n\t\t\t//Pg 183 Lee[05]\n\t\t\t//For each grid point that this particle has been interpolated to\n\t\t\tfor(int dx = -ASSIGNMENT_SCHEME_ORDER; dx < ASSIGNMENT_SCHEME_ORDER; dx++)\n\t\t\t{\n\t\t\t\tfor(int dy = -ASSIGNMENT_SCHEME_ORDER; dy < ASSIGNMENT_SCHEME_ORDER; dy++)\n\t\t\t\t{\n\t\t\t\t\tdouble uX = p.getPosition().re()/1.0 * CELL_SIDE_COUNT;//Scaled fractional coordinate\n\t\t\t\t\tdouble uY = p.getPosition().im()/1.0 * CELL_SIDE_COUNT;//Scaled fractional coordinate\n\t\t\t\t\tint particleCellX = (int)Math.round(p.getPosition().re()/1.0 * CELL_SIDE_COUNT);\n\t\t\t\t\tint particleCellY = (int)Math.round(p.getPosition().im()/1.0 * CELL_SIDE_COUNT);\n\t\t\t\t\tint thisX = particleCellX + dx;\n\t\t\t\t\tint thisY = particleCellY + dy;\n\t\t\t\t\tif(thisX >= 0 && thisY >= 0 && thisX < CELL_SIDE_COUNT && thisY < CELL_SIDE_COUNT)\n\t\t\t\t\t{\n\t\t\t\t\t\tdouble dQdx = p.getCharge() * M.evaluateDerivative(uX - thisX) * M.evaluate(uY - thisY);\n\t\t\t\t\t\tdouble dQdy = p.getCharge() * M.evaluate(uX - thisX) * M.evaluateDerivative(uY - thisY);\n\t\t\t\t\t\tp.addToForce(-dQdx * convolutedMatrix[thisX][thisY].re(), -dQdy * convolutedMatrix[thisX][thisY].re()); //FIXME .re()?\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t}", "public VParticle addParticle(VParticle particle) {\n\t\tVParticle p = returnIfConstrained(particle);\n\t\t\n\t\t//particles.add(p);\n\t\treturn p;\n\t}", "private void init(int numberOfParticles, int dimensions) {\n MersenneTwisterFast mt = Utils.getMTInstance();\n double pos;\n double vel;\n \n Particle p = null;\n for (int i = 0; i < numberOfParticles; i++) {\n\n\n List<Double> tempPosition = new ArrayList<Double>(dimensions);\n List<Double> tempVelocity = new ArrayList<Double>(dimensions);\n for (int j = 0; j < dimensions; j++) {\n pos = this.getLowerBound().get(j) + (mt.nextDouble() * (this.getUpperBound().get(j) - this.getLowerBound().get(j)));\n vel = (this.getLowerBound().get(j) - this.getUpperBound().get(j)) / 2 + (mt.nextDouble() * (((this.getUpperBound().get(j)\n - this.getLowerBound().get(j)) / 2 - (this.getLowerBound().get(j) - this.getUpperBound().get(j)) / 2) + 1));\n tempPosition.add(pos);\n tempVelocity.add(vel);\n }\n if (this.phi == 0) {\n p = new Particle(this, tempPosition, this.informantsPerParticle);\n } else {\n p = new Particle(this, tempPosition, this.informantsPerParticle, this.phi);\n }\n\n p.setBestPosition(Utils.doubleListDeepCopy(tempPosition));\n p.setVelocity(tempVelocity);\n p.evaluate(getCostFunction());\n this.getPopulation().add(p);\n\n }\n \n }", "void applyEffects();", "public void spawnParticle ( Particle particle , Location location , int count ,\n\t\t\tdouble offsetX , double offsetY , double offsetZ ) {\n\t\thandleOptional ( ).ifPresent ( handle -> {\n\t\t\tof ( particle ).display ( location ,\n\t\t\t\t\t\t\t\t\t ( float ) offsetX , ( float ) offsetY , ( float ) offsetZ ,\n\t\t\t\t\t\t\t\t\t 1.0F , count , null , handle );\n\t\t} );\n\t}", "public void a(boolean paramBoolean)\r\n/* 143: */ {\r\n/* 144:162 */ this.d.a(this.e, this.f, this.g, \"random.explode\", 4.0F, (1.0F + (this.d.rng.nextFloat() - this.d.rng.nextFloat()) * 0.2F) * 0.7F);\r\n/* 145:163 */ if ((this.i < 2.0F) || (!this.b)) {\r\n/* 146:164 */ this.d.a(EnumParticleEffect.EXPLOSION_LARGE, this.e, this.f, this.g, 1.0D, 0.0D, 0.0D, new int[0]);\r\n/* 147: */ } else {\r\n/* 148:166 */ this.d.a(EnumParticleEffect.EXPLOSION_HUGE, this.e, this.f, this.g, 1.0D, 0.0D, 0.0D, new int[0]);\r\n/* 149: */ }\r\n/* 150: */ Iterator<BlockPosition> localIterator;\r\n/* 151:169 */ if (this.b) {\r\n/* 152:170 */ for (localIterator = this.j.iterator(); localIterator.hasNext();)\r\n/* 153: */ {\r\n/* 154:170 */ BlockPosition localdt = localIterator.next();\r\n/* 155:171 */ BlockType localatr = this.d.getBlock(localdt).getType();\r\n/* 156:173 */ if (paramBoolean)\r\n/* 157: */ {\r\n/* 158:174 */ double d1 = localdt.getX() + this.d.rng.nextFloat();\r\n/* 159:175 */ double d2 = localdt.getY() + this.d.rng.nextFloat();\r\n/* 160:176 */ double d3 = localdt.getZ() + this.d.rng.nextFloat();\r\n/* 161: */ \r\n/* 162:178 */ double d4 = d1 - this.e;\r\n/* 163:179 */ double d5 = d2 - this.f;\r\n/* 164:180 */ double d6 = d3 - this.g;\r\n/* 165: */ \r\n/* 166:182 */ double d7 = MathUtils.sqrt(d4 * d4 + d5 * d5 + d6 * d6);\r\n/* 167: */ \r\n/* 168:184 */ d4 /= d7;\r\n/* 169:185 */ d5 /= d7;\r\n/* 170:186 */ d6 /= d7;\r\n/* 171: */ \r\n/* 172:188 */ double d8 = 0.5D / (d7 / this.i + 0.1D);\r\n/* 173:189 */ d8 *= (this.d.rng.nextFloat() * this.d.rng.nextFloat() + 0.3F);\r\n/* 174:190 */ d4 *= d8;\r\n/* 175:191 */ d5 *= d8;\r\n/* 176:192 */ d6 *= d8;\r\n/* 177: */ \r\n/* 178:194 */ this.d.a(EnumParticleEffect.EXPLOSION_NORMAL, (d1 + this.e * 1.0D) / 2.0D, (d2 + this.f * 1.0D) / 2.0D, (d3 + this.g * 1.0D) / 2.0D, d4, d5, d6, new int[0]);\r\n/* 179:195 */ this.d.a(EnumParticleEffect.l, d1, d2, d3, d4, d5, d6, new int[0]);\r\n/* 180: */ }\r\n/* 181:198 */ if (localatr.getMaterial() != Material.air)\r\n/* 182: */ {\r\n/* 183:199 */ if (localatr.a(this)) {\r\n/* 184:200 */ localatr.a(this.d, localdt, this.d.getBlock(localdt), 1.0F / this.i, 0);\r\n/* 185: */ }\r\n/* 186:202 */ this.d.setBlock(localdt, BlockList.air.instance(), 3);\r\n/* 187:203 */ localatr.a(this.d, localdt, this);\r\n/* 188: */ }\r\n/* 189: */ }\r\n/* 190: */ }\r\n/* 191: */ BlockPosition localdt;\r\n/* 192:207 */ if (this.a) {\r\n/* 193:208 */ for (localIterator = this.j.iterator(); localIterator.hasNext();)\r\n/* 194: */ {\r\n/* 195:208 */ localdt = localIterator.next();\r\n/* 196:209 */ if ((this.d.getBlock(localdt).getType().getMaterial() == Material.air) && (this.d.getBlock(localdt.down()).getType().m()) && (this.c.nextInt(3) == 0)) {\r\n/* 197:210 */ this.d.setBlock(localdt, BlockList.fire.instance());\r\n/* 198: */ }\r\n/* 199: */ }\r\n/* 200: */ }\r\n/* 201: */ }", "@Override\n public void applyParticleAtAttacker(int type, Entity target, float[] vec)\n {\n \t\tTargetPoint point = new TargetPoint(this.dimension, this.posX, this.posY, this.posZ, 64D);\n \n \t\tswitch (type)\n \t\t{\n \t\tcase 1: //light cannon\n \t double shotHeight = 1.85D;\n \t \n \t if(this.isRiding() && this.getRidingEntity() instanceof BasicEntityMount)\n \t {\n \t \tshotHeight = 0.8D;\n \t }\n \t \n \t\t\tCommonProxy.channelP.sendToAllAround(new S2CSpawnParticle(this, target, shotHeight, 0D, 0D, 0, true), point);\n \t\tbreak;\n \t\tcase 2: //heavy cannon\n \t\tcase 3: //light aircraft\n \t\tcase 4: //heavy aircraft\n\t\tdefault: //melee\n\t\t\tCommonProxy.channelP.sendToAllAround(new S2CSpawnParticle(this, 0, true), point);\n\t\tbreak;\n \t\t}\n \t}", "public static native int OpenMM_AmoebaWcaDispersionForce_addParticle(PointerByReference target, double radius, double epsilon);", "@Override\n\tpublic void pintar() {\n\t\n\t\tapp.image(water, this.px, this.py);\n\t\t\n\t}", "public interface Particle extends VisualValue, Point\n{\n}", "public void a(PotionEffect paramwq)\r\n/* 44: */ {\r\n/* 45: 52 */ if (this.id != paramwq.id) {\r\n/* 46: 53 */ a.warn(\"This method should only be called for matching effects!\");\r\n/* 47: */ }\r\n/* 48: 55 */ if (paramwq.amplifier > this.amplifier)\r\n/* 49: */ {\r\n/* 50: 56 */ this.amplifier = paramwq.amplifier;\r\n/* 51: 57 */ this.duration = paramwq.duration;\r\n/* 52: */ }\r\n/* 53: 58 */ else if ((paramwq.amplifier == this.amplifier) && (this.duration < paramwq.duration))\r\n/* 54: */ {\r\n/* 55: 59 */ this.duration = paramwq.duration;\r\n/* 56: */ }\r\n/* 57: 60 */ else if ((!paramwq.ambient) && (this.ambient))\r\n/* 58: */ {\r\n/* 59: 61 */ this.ambient = paramwq.ambient;\r\n/* 60: */ }\r\n/* 61: 63 */ this.showParticles = paramwq.showParticles;\r\n/* 62: */ }", "public void addNoCollisionElement(Particle p)\n {\n noCollisionElements.add(p);\n p.addNoCollisionElementFree(this);\n }", "public void spawnParticle ( Particle particle , Location location , int count ) {\n\t\thandleOptional ( ).ifPresent ( handle -> {\n\t\t\tof ( particle ).display ( location , 0.0F , 0.0F , 0.0F , 1.0F , count , null , handle );\n\t\t} );\n\t}", "public static void displaySingleParticle(Player p, float x, float y, float z, ParticleColor color){\n PacketPlayOutWorldParticles packet = new PacketPlayOutWorldParticles(EnumParticle.REDSTONE, true, x, y, z, color.getRed(), color.getGreen(), color.getBlue(), 1, 0, 0);\n ((CraftPlayer) p).getHandle().playerConnection.sendPacket(packet);\n }", "private void predict(Particle a) {\n if (a == null) return;\n double dt;\n\n for (int i = 0; i < this.N; i++) { // add events to collisions with other particles\n dt = a.timeToHit(particles[i]);\n if (dt < 0.0) dt = 0.0;\n if (dt != INFINITY)\n pq.insert(new Event(dt, a, particles[i]));\n }\n\n dt = a.timeToHitVerticalWall();\n if (dt < 0.0) dt = 0.0;\n if (dt != INFINITY)\n pq.insert(new Event(dt, a, null)); // add events to collisions with walls\n\n dt = a.timeToHitHorizontalWall();\n if (dt < 0.0) dt = 0.0;\n if (dt != INFINITY)\n pq.insert(new Event(dt, null, a));\n }", "protected void callAlgorithm() {\r\n String name = makeImageName(image.getImageName(), \"_particle\");\r\n\r\n if (image.getNDims() == 2) { // source image is 2D\r\n\r\n int[] destExtents = new int[2];\r\n\r\n destExtents[0] = image.getExtents()[0]; // X dim\r\n destExtents[1] = image.getExtents()[1]; // Y dim\r\n\r\n if (outputPanel.isOutputNewImageSet()) {\r\n\r\n try {\r\n resultImage = (ModelImage) image.clone();\r\n resultImage.setImageName(name);\r\n\r\n // Make algorithm\r\n particleAlgo2D = new AlgorithmMorphology2D(resultImage, kernelOpen, kernelSizeOpen, kernelClose,\r\n kernelSizeClose,\r\n AlgorithmMorphology2D.PARTICLE_ANALYSIS_NEW, itersOpen,\r\n itersErode, 0, 0, outputPanel.isProcessWholeImageSet(), showFrame);\r\n\r\n if (outputPanel.isProcessWholeImageSet() == false) {\r\n particleAlgo2D.setMask(image.generateVOIMask());\r\n }\r\n\r\n // particleAlgo2D = new AlgorithmMorphology2D(resultImage, kernel, 5,\r\n // AlgorithmMorphology2D.PARTICLE_ANALYSIS_NEW, iters, regionFlag);\r\n // This is very important. Adding this object as a listener allows the algorithm to\r\n // notify this object when it has completed or failed. See algorithm performed event.\r\n // This is made possible by implementing AlgorithmedPerformed interface\r\n particleAlgo2D.addListener(this);\r\n\r\n createProgressBar(image.getImageName(), particleAlgo2D);\r\n \r\n // Hide dialog\r\n setVisible(false);\r\n\r\n if (isRunInSeparateThread()) {\r\n\r\n // Start the thread as a low priority because we wish to still have user interface work fast.\r\n if (particleAlgo2D.startMethod(Thread.MIN_PRIORITY) == false) {\r\n MipavUtil.displayError(\"A thread is already running on this object\");\r\n }\r\n } else {\r\n particleAlgo2D.run();\r\n\r\n }\r\n } catch (OutOfMemoryError x) {\r\n MipavUtil.displayError(\"Dialog particle analysis new: unable to allocate enough memory\");\r\n\r\n if (resultImage != null) {\r\n resultImage.disposeLocal(); // Clean up memory of result image\r\n resultImage = null;\r\n }\r\n\r\n return;\r\n }\r\n\r\n } else {\r\n\r\n try {\r\n\r\n // No need to make new image space because the user has choosen to replace the source image Make the\r\n // algorithm class particleAlgo2D = new AlgorithmMorphology2D( image, kernel, kernelSize,\r\n // AlgorithmMorphology2D.PARTICLE_ANALYSIS_NEW, itersD, 0, 0, 0, regionFlag );\r\n particleAlgo2D = new AlgorithmMorphology2D(image, kernelOpen, kernelSizeOpen, kernelClose, kernelSizeClose,\r\n AlgorithmMorphology2D.PARTICLE_ANALYSIS_NEW, itersOpen,\r\n itersErode, 0, 0, outputPanel.isProcessWholeImageSet(), showFrame);\r\n\r\n if (outputPanel.isProcessWholeImageSet() == false) {\r\n particleAlgo2D.setMask(image.generateVOIMask());\r\n }\r\n\r\n // This is very important. Adding this object as a listener allows the algorithm to\r\n // notify this object when it has completed or failed. See algorithm performed event.\r\n // This is made possible by implementing AlgorithmedPerformed interface\r\n particleAlgo2D.addListener(this);\r\n\r\n createProgressBar(image.getImageName(), particleAlgo2D);\r\n \r\n // Hide the dialog since the algorithm is about to run.\r\n setVisible(false);\r\n\r\n // These next lines set the titles in all frames where the source image is displayed to\r\n // \"locked - \" image name so as to indicate that the image is now read/write locked!\r\n // The image frames are disabled and then unregisted from the userinterface until the\r\n // algorithm has completed.\r\n Vector<ViewImageUpdateInterface> imageFrames = image.getImageFrameVector();\r\n\r\n titles = new String[imageFrames.size()];\r\n\r\n for (int i = 0; i < imageFrames.size(); i++) {\r\n titles[i] = ((Frame) (imageFrames.elementAt(i))).getTitle();\r\n ((Frame) (imageFrames.elementAt(i))).setTitle(\"Locked: \" + titles[i]);\r\n ((Frame) (imageFrames.elementAt(i))).setEnabled(false);\r\n userInterface.unregisterFrame((Frame) (imageFrames.elementAt(i)));\r\n }\r\n\r\n if (isRunInSeparateThread()) {\r\n\r\n // Start the thread as a low priority because we wish to still have user interface.\r\n if (particleAlgo2D.startMethod(Thread.MIN_PRIORITY) == false) {\r\n MipavUtil.displayError(\"A thread is already running on this object\");\r\n }\r\n } else {\r\n particleAlgo2D.run();\r\n }\r\n } catch (OutOfMemoryError x) {\r\n MipavUtil.displayError(\"Dialog particle analysis new: unable to allocate enough memory\");\r\n\r\n return;\r\n }\r\n }\r\n } else if ((image.getNDims() == 3) && !do25D) {\r\n int[] destExtents = new int[3];\r\n\r\n destExtents[0] = image.getExtents()[0];\r\n destExtents[1] = image.getExtents()[1];\r\n destExtents[2] = image.getExtents()[2];\r\n\r\n if (outputPanel.isOutputNewImageSet()) {\r\n\r\n try {\r\n resultImage = (ModelImage) image.clone();\r\n resultImage.setImageName(name);\r\n\r\n // Make algorithm\r\n particleAlgo3D = new AlgorithmMorphology3D(resultImage, kernelOpen, kernelSizeOpen,\r\n AlgorithmMorphology3D.PARTICLE_ANALYSIS, itersClose,\r\n itersOpen, 0, 0, outputPanel.isProcessWholeImageSet());\r\n\r\n if (outputPanel.isProcessWholeImageSet() == false) {\r\n particleAlgo3D.setMask(image.generateVOIMask());\r\n }\r\n\r\n // This is very important. Adding this object as a listener allows the algorithm to\r\n // notify this object when it has completed or failed. See algorithm performed event.\r\n // This is made possible by implementing AlgorithmedPerformed interface\r\n particleAlgo3D.addListener(this);\r\n\r\n createProgressBar(image.getImageName(), particleAlgo3D);\r\n \r\n // Hide dialog\r\n setVisible(false);\r\n\r\n if (isRunInSeparateThread()) {\r\n\r\n // Start the thread as a low priority because we wish to still have user interface work fast\r\n if (particleAlgo3D.startMethod(Thread.MIN_PRIORITY) == false) {\r\n MipavUtil.displayError(\"A thread is already running on this object\");\r\n }\r\n } else {\r\n particleAlgo3D.run();\r\n }\r\n } catch (OutOfMemoryError x) {\r\n MipavUtil.displayError(\"Dialog particle analysis new: unable to allocate enough memory\");\r\n\r\n if (resultImage != null) {\r\n resultImage.disposeLocal(); // Clean up image memory\r\n resultImage = null;\r\n }\r\n\r\n return;\r\n }\r\n } else {\r\n\r\n try {\r\n\r\n // Make algorithm\r\n particleAlgo3D = new AlgorithmMorphology3D(image, kernelOpen, kernelSizeOpen,\r\n AlgorithmMorphology3D.PARTICLE_ANALYSIS, itersClose,\r\n itersOpen, 0, 0, outputPanel.isProcessWholeImageSet());\r\n\r\n if (outputPanel.isProcessWholeImageSet() == false) {\r\n particleAlgo3D.setMask(image.generateVOIMask());\r\n }\r\n\r\n // This is very important. Adding this object as a listener allows the algorithm to\r\n // notify this object when it has completed or failed. See algorithm performed event.\r\n // This is made possible by implementing AlgorithmedPerformed interface\r\n particleAlgo3D.addListener(this);\r\n\r\n createProgressBar(image.getImageName(), particleAlgo3D);\r\n \r\n // Hide dialog\r\n setVisible(false);\r\n\r\n // These next lines set the titles in all frames where the source image is displayed to\r\n // \"locked - \" image name so as to indicate that the image is now read/write locked!\r\n // The image frames are disabled and then unregisted from the userinterface until the\r\n // algorithm has completed.\r\n Vector<ViewImageUpdateInterface> imageFrames = image.getImageFrameVector();\r\n\r\n titles = new String[imageFrames.size()];\r\n\r\n for (int i = 0; i < imageFrames.size(); i++) {\r\n titles[i] = ((ViewJFrameBase) (imageFrames.elementAt(i))).getTitle();\r\n ((ViewJFrameBase) (imageFrames.elementAt(i))).setTitle(\"Locked: \" + titles[i]);\r\n ((ViewJFrameBase) (imageFrames.elementAt(i))).setEnabled(false);\r\n userInterface.unregisterFrame((Frame) (imageFrames.elementAt(i)));\r\n }\r\n\r\n if (isRunInSeparateThread()) {\r\n\r\n // Start the thread as a low priority because we wish to still have user interface work fast\r\n if (particleAlgo3D.startMethod(Thread.MIN_PRIORITY) == false) {\r\n MipavUtil.displayError(\"A thread is already running on this object\");\r\n }\r\n } else {\r\n particleAlgo3D.run();\r\n }\r\n } catch (OutOfMemoryError x) {\r\n MipavUtil.displayError(\"Dialog particle analysis new: unable to allocate enough memory\");\r\n\r\n return;\r\n }\r\n }\r\n } else if (do25D) {\r\n int[] destExtents = new int[3];\r\n\r\n destExtents[0] = image.getExtents()[0]; // X dim\r\n destExtents[1] = image.getExtents()[1]; // Y dim\r\n destExtents[2] = image.getExtents()[2]; // Z dim\r\n\r\n // convert to 2.5d kernel type\r\n if (kernelOpen == AlgorithmMorphology3D.CONNECTED6) {\r\n kernelOpen = AlgorithmMorphology25D.CONNECTED4;\r\n } else if (kernelOpen == AlgorithmMorphology3D.CONNECTED24) {\r\n kernelOpen = AlgorithmMorphology25D.CONNECTED12;\r\n } else if (kernelOpen == AlgorithmMorphology3D.SIZED_SPHERE) {\r\n kernelOpen = AlgorithmMorphology25D.SIZED_CIRCLE;\r\n }\r\n\r\n if (outputPanel.isOutputNewImageSet()) {\r\n\r\n try {\r\n resultImage = (ModelImage) image.clone();\r\n resultImage.setImageName(name);\r\n\r\n // Make algorithm\r\n particleAlgo25D = new AlgorithmMorphology25D(resultImage, kernelOpen, kernelSizeOpen,\r\n AlgorithmMorphology25D.PARTICLE_ANALYSIS, itersClose,\r\n 0, 0, 0, outputPanel.isProcessWholeImageSet());\r\n\r\n if (outputPanel.isProcessWholeImageSet() == false) {\r\n particleAlgo25D.setMask(image.generateVOIMask());\r\n }\r\n\r\n // particleAlgo25D = new AlgorithmMorphology25D(resultImage, kernel, 5,\r\n // AlgorithmMorphology25D.PARTICLE_ANALYSIS, iters, regionFlag);\r\n // This is very important. Adding this object as a listener allows the algorithm to\r\n // notify this object when it has completed or failed. See algorithm performed event.\r\n // This is made possible by implementing AlgorithmedPerformed interface\r\n particleAlgo25D.addListener(this);\r\n\r\n createProgressBar(image.getImageName(), particleAlgo25D);\r\n \r\n // Hide dialog\r\n setVisible(false);\r\n\r\n if (isRunInSeparateThread()) {\r\n\r\n // Start the thread as a low priority because we wish to still have user interface work fast.\r\n if (particleAlgo25D.startMethod(Thread.MIN_PRIORITY) == false) {\r\n MipavUtil.displayError(\"A thread is already running on this object\");\r\n }\r\n } else {\r\n particleAlgo25D.run();\r\n }\r\n } catch (OutOfMemoryError x) {\r\n MipavUtil.displayError(\"Dialog particle analysis new: unable to allocate enough memory\");\r\n\r\n if (resultImage != null) {\r\n resultImage.disposeLocal(); // Clean up memory of result image\r\n resultImage = null;\r\n }\r\n\r\n return;\r\n }\r\n } else {\r\n\r\n try {\r\n\r\n // No need to make new image space because the user has choosen to replace the source image\r\n // Make the algorithm class\r\n particleAlgo25D = new AlgorithmMorphology25D(image, kernelOpen, kernelSizeOpen,\r\n AlgorithmMorphology25D.PARTICLE_ANALYSIS, itersClose,\r\n 0, 0, 0, outputPanel.isProcessWholeImageSet());\r\n\r\n if (outputPanel.isProcessWholeImageSet() == false) {\r\n particleAlgo25D.setMask(image.generateVOIMask());\r\n }\r\n\r\n // This is very important. Adding this object as a listener allows the algorithm to\r\n // notify this object when it has completed or failed. See algorithm performed event.\r\n // This is made possible by implementing AlgorithmedPerformed interface\r\n particleAlgo25D.addListener(this);\r\n\r\n createProgressBar(image.getImageName(), particleAlgo25D);\r\n \r\n // Hide the dialog since the algorithm is about to run.\r\n setVisible(false);\r\n\r\n // These next lines set the titles in all frames where the source image is displayed to\r\n // \"locked - \" image name so as to indicate that the image is now read/write locked!\r\n // The image frames are disabled and then unregisted from the userinterface until the\r\n // algorithm has completed.\r\n Vector<ViewImageUpdateInterface> imageFrames = image.getImageFrameVector();\r\n\r\n titles = new String[imageFrames.size()];\r\n\r\n for (int i = 0; i < imageFrames.size(); i++) {\r\n titles[i] = ((Frame) (imageFrames.elementAt(i))).getTitle();\r\n ((Frame) (imageFrames.elementAt(i))).setTitle(\"Locked: \" + titles[i]);\r\n ((Frame) (imageFrames.elementAt(i))).setEnabled(false);\r\n userInterface.unregisterFrame((Frame) (imageFrames.elementAt(i)));\r\n }\r\n\r\n if (isRunInSeparateThread()) {\r\n\r\n // Start the thread as a low priority because we wish to still have user interface.\r\n if (particleAlgo25D.startMethod(Thread.MIN_PRIORITY) == false) {\r\n MipavUtil.displayError(\"A thread is already running on this object\");\r\n }\r\n } else {\r\n particleAlgo25D.run();\r\n }\r\n } catch (OutOfMemoryError x) {\r\n MipavUtil.displayError(\"Dialog particle analysis new: unable to allocate enough memory\");\r\n\r\n return;\r\n }\r\n }\r\n }\r\n }", "public static void setup() {\n\t\ttestUpdateParticle();\n\t\ttestRemoveOldParticles();\n\t\t\n\t\tif (testUpdateParticle() == true || testRemoveOldParticles() == true) {\n\t\t\tSystem.out.println(\"FAILED\");\n\t\t}\n\t\t\n\t\t// Build a new random field.\n\t\trandGen = new Random();\n\n\t\tpositionX = 400; // middle of the screen (left to right): 400\n\t\tpositionY = 300; // middle of the screen (top to bottom): 300\n\t\tstartColor = Utility.color(23, 141, 235); // blue: Utility.color(23,141,235)\n\t\tendColor = Utility.color(23, 200, 255); // lighter blue: Utility.color(23,200,255)\n\t\t\n\t\t// This array can store 800 particles\n\t\tparticles = new Particle[800];\n\n\t}", "void render() {\n smooth();\n for (int x = 0; x < yvalues.length; x++) {\n noStroke();\n fill(0,0,255,100);\n ellipseMode(CENTER);\n ellipse(x*xspacing,yvalues[x],16,16);\n }\n }" ]
[ "0.82349837", "0.73908633", "0.736397", "0.70645106", "0.6938308", "0.67684466", "0.67618215", "0.6752844", "0.6699516", "0.6665414", "0.6636304", "0.65851295", "0.6572504", "0.6531342", "0.6518128", "0.65148014", "0.6493121", "0.64576477", "0.64515895", "0.63985664", "0.6383213", "0.6327793", "0.63217634", "0.6298418", "0.62904584", "0.6284866", "0.62049", "0.6184658", "0.6183083", "0.6164956", "0.6157031", "0.6124836", "0.6102027", "0.6085948", "0.6066688", "0.6064976", "0.60570985", "0.6046464", "0.60461986", "0.6006375", "0.5994447", "0.59901077", "0.59782314", "0.59765387", "0.5967834", "0.59290874", "0.5917149", "0.59046453", "0.5895675", "0.5888735", "0.58873904", "0.5858394", "0.58439577", "0.5811077", "0.580811", "0.5797343", "0.5786202", "0.57741004", "0.5773898", "0.57544106", "0.5752365", "0.57465756", "0.57312006", "0.5724188", "0.572331", "0.5695138", "0.5677329", "0.56722385", "0.5669777", "0.5654757", "0.5647526", "0.5641383", "0.5634414", "0.5632766", "0.5626071", "0.562273", "0.5621914", "0.561997", "0.56170595", "0.56067294", "0.5598741", "0.55598146", "0.55541086", "0.5551703", "0.5549164", "0.55484176", "0.55425", "0.55395687", "0.5528856", "0.5523845", "0.55192894", "0.55109656", "0.54983073", "0.5477707", "0.54738593", "0.54637253", "0.54547215", "0.5448915", "0.5447936", "0.54345715", "0.54337585" ]
0.0
-1
Returns string if config is incomplete, null if config is ready
public String getMissing(SurvivalGamesCustomData customData) { if (getDeathCenter() == null) return null; if (UtilLoc.getDistance2d(getWorld().getSpawnLocation(), getDeathCenter()) >= _radius) { return "World spawn isn't inside the Deathmatch!"; } if (_radius < 6) { return "Deathmatch is too small"; } for (ArrayList<Pair<Block, FakeEntity>> teams : customData.getTeams().values()) { int i = 0; for (Pair<Block, FakeEntity> spawns : teams) { if (!customData.isInside(spawns.getKey().getLocation())) { return "Spawnpoint " + i + " is not inside Deathmatch"; } i++; } } return null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public String getStringConfiguration()\r\n\t{\r\n\t\treturn config;\r\n\t}", "public String configString() {\n return this.configString;\n }", "public String getStringConfiguration() {\n\t\treturn config;\n\t}", "public String getConfig();", "public String getConfigString()\n {\n return debug ? \"debug\" : \"release\";\n }", "public String getConfig() {\n\t\treturn(config);\n\t}", "public abstract String getConfig();", "public String getConfig() {\n\n return config;\n }", "private static String getLocalConfigString(String name) {\n\t\ttry {\n\t\t\treturn (String) LOCAL_CONFIG_CLASS.getField(name).get(null);\n\t\t} catch (Exception e) {\n\t\t\tLog.e(LOG_TAG, \"No local configuration found with key \" + name);\n\t\t\treturn null;\n\t\t}\n\t}", "public String configurationInfo();", "public String getConfiguration(){\n\t\treturn this.config;\n\t}", "@XmlAttribute(name=\"cfg\")\n\tpublic String getCfgAsString() {\n\t\tif(cfg != null)\n\t\t\treturn cfg.toString();\n\t\treturn null;\n\t}", "public Config getConfig();", "public String getMandatoryString(String key) throws ConfigNotFoundException;", "public com.google.protobuf.Any getConfiguration() {\n if (configurationBuilder_ == null) {\n return configuration_ == null ? com.google.protobuf.Any.getDefaultInstance() : configuration_;\n } else {\n return configurationBuilder_.getMessage();\n }\n }", "public String configString() {\n \n String boardConfig = \"\";\n // adds each element in the array to the string with a space in between\n // condition is numPiles - 1 so last element does not print with a space afterwards\n \n for (int i = 0; i < numPiles - 1; i++){\n boardConfig += piles[i] + \" \";\n }\n boardConfig += piles[numPiles - 1] + \" \";\n \n //check if valid board still\n assert isValidSolitaireBoard();\n \n //return the current board configuration string\n return boardConfig;\n }", "public String toString() {\r\n\t\treturn configurationFileString;\r\n\t}", "@java.lang.Override\n public com.google.protobuf.Any getConfiguration() {\n return configuration_ == null ? com.google.protobuf.Any.getDefaultInstance() : configuration_;\n }", "public String getConfiguration()\r\n\t{\r\n\t\treturn _configuration; \r\n\t}", "public String getConfiguration() {\n return configuration;\n }", "@Override\n public boolean hasConfig() {\n return config_ != null;\n }", "public String getConfiguration() {\r\n\t\treturn configuration;\r\n\t}", "@Override\n\tpublic Map<String, String> getConfig() {\n\t\treturn null;\n\t}", "@java.lang.Override\n public boolean hasConfig() {\n return config_ != null;\n }", "public String getNomeConfigurazione() {\n return null;\r\n }", "String getConfigName();", "public String readConfig(Context context) {\n\n String ret = \"\";\n\n try {\n InputStream inputStream = context.openFileInput(\"config.txt\");\n\n if (inputStream != null) {\n InputStreamReader inputStreamReader = new InputStreamReader(inputStream);\n BufferedReader bufferedReader = new BufferedReader(inputStreamReader);\n String receiveString = \"\";\n StringBuilder stringBuilder = new StringBuilder();\n\n while ((receiveString = bufferedReader.readLine()) != null) {\n stringBuilder.append(receiveString);\n }\n\n inputStream.close();\n ret = stringBuilder.toString();\n }\n } catch (FileNotFoundException e) {\n Log.e(\"Config\", \"File not found: \" + e.toString());\n } catch (IOException e) {\n Log.e(\"Config\", \"Can not read file: \" + e.toString());\n }\n\n return ret;\n }", "public String getConfiguration() {\n return this.configuration;\n }", "public String getCurrentUrlConfig() {\n String primary = AbstractConfigHandler.getPrimaryDataServer();\n if (primary == null) {\n logger.debug(\"No primary dataserver found\");\n urlUnset();\n return null;\n } else {\n String url = addressHandler.getHttpAddress(primary);\n if (url == null) {\n logger.debug(\"No url set for dataserver: \" + primary);\n urlUnset();\n return null;\n } else {\n return verifyHttpProcess(url);\n }\n }\n }", "ConfigBlock getConfig();", "@NonNull\n public String getString(String key) {\n return mConfigurations.optString(key, \"\");\n }", "public Object getConfig() {\n return config;\n }", "public String getConfigurationFileString() {\r\n\t\treturn configurationFileString;\r\n\t}", "public String getUserConfig() {\n return userConfig;\n }", "public String getString() {\r\n\t\ttype(ConfigurationItemType.STRING);\r\n\t\treturn stringValue;\r\n\t}", "private String getPlaymeidFromConfig(){\n\t\tString playmeid = \"\";\n\t\ttry {\n\t\t\tString filePath = \"/system/etc/manufactory.conf\";\n\t\t\tFile file = new File(filePath);\n\t\t\tif (!file.isFile()) {\n\t\t\t\treturn playmeid;\n\t\t\t}\n\t\t\tFileInputStream fin = new FileInputStream(filePath);\n\t\t\tint length = fin.available();\n\t\t\tif(length == 32){\n\t\t\t\tbyte[] buffer = new byte[length];\n\t\t\t\tfin.read(buffer);\n//\t\t\t\tplaymeid = EncodingUtils.getString(buffer, \"UTF-8\");\n\t\t\t\tfin.close();\n\t\t\t\treturn new String(buffer);\n\t\t\t}\n\t\t\tfin.close();\n\t\t} catch (Exception e) {\n\t\t\te.printStackTrace();\n\t\t}\n\t\treturn playmeid;\n\t}", "public java.lang.String getAnswerFileConfigString() {\r\n return answerFileConfigString;\r\n }", "@Override\n\tpublic Properties getConfig() {\n\t\treturn null;\n\t}", "public String get(String key) {\n\t\tInstant start = Instant.now();\n\t\tString value = getConfig(key);\n\t\tLOGGER.debug(\"Access to config {} to get {} took {}\", uniqueInstance.instanceUUID, key, Duration.between(start, Instant.now()));\t\t\n\t\treturn value;\n\t}", "public C getConfig()\n {\n return config;\n }", "String getConfigFileName();", "public Optional<String> safeGet(String key) {\n\t\tInstant start = Instant.now();\n\t\tOptional<String> result;\n\t\ttry {\n\t\t\tresult = Optional.of(get(key));\n\t\t} catch (ConfigException e) {\n\t\t\tLOGGER.warn(\"No value was found for key {}: an Optional.empty() will be returned\", key);\n\t\t\tresult = Optional.empty();\n\t\t}\n\t\tLOGGER.debug(\"Access to config {} to safeGet {} took {}\", uniqueInstance.instanceUUID, key, Duration.between(start, Instant.now()));\n\t\treturn result;\n\t}", "public JsonObject getConfig() {\n return config;\n }", "public String getConfigName () {\n return this.configName;\n }", "public Config getConfig() {\n return config;\n }", "RootConfig getConfig();", "default Component getConfigComponent()\r\n {\r\n return null;\r\n }", "private String generateConfigurationString() {\n\t\tStringBuilder configuration = new StringBuilder();\n\t\tconfigurationHolder.entrySet().stream().forEach(line -> {\n\t\t\tconfiguration.append(line.getKey()+\"=\"+line.getValue()+\"\\n\");\n\t\t});\n\t\treturn configuration.toString();\n\t}", "public boolean hasConfig() {\n return configBuilder_ != null || config_ != null;\n }", "public String getConfigurationValue() {\n return newConfigValue;\n }", "@Override\n public String getString(String key) {\n \n if (overrideConfig.containsKey(key)) {\n return overrideConfig.get(key);\n }\n \n return ConfigurationFactory.getConfiguration().getString(key);\n }", "protected abstract String getXmppConfigResources();", "public DerivedFeatureConfig getConfig() {\n if (configBuilder_ == null) {\n return config_ == null ? DerivedFeatureConfig.getDefaultInstance() : config_;\n } else {\n return configBuilder_.getMessage();\n }\n }", "public p getConfig() {\n return c.K();\n }", "public com.google.protobuf.AnyOrBuilder getConfigurationOrBuilder() {\n if (configurationBuilder_ != null) {\n return configurationBuilder_.getMessageOrBuilder();\n } else {\n return configuration_ == null ?\n com.google.protobuf.Any.getDefaultInstance() : configuration_;\n }\n }", "@JavascriptInterface\n public String config(String config) {\n String response = mManager.config(config);\n if (Log.isLoggable(HybridManager.TAG, Log.DEBUG)) {\n Log.d(HybridManager.TAG, \"config response is \" + response);\n }\n return response;\n }", "public static String readConfigValue(Context context, String key) {\n Resources resources = context.getResources();\n try {\n InputStream inputStream = resources.openRawResource(R.raw.config);\n Properties properties = new Properties();\n properties.load(inputStream);\n return properties.getProperty(key);\n } catch (Exception e) {\n e.printStackTrace();\n }\n return \"\";\n }", "@Override\r\n\tpublic String toString() {\n\t\treturn \"Incorrect Configuration: \"+super.toString();\r\n\t}", "private String getConfigInfo(boolean verbose) {\r\n StringBuilder builder = new StringBuilder();\r\n\r\n GridHubConfiguration config = getRegistry().getConfiguration();\r\n builder.append(\"<b>Config for the hub :</b><br/>\");\r\n builder.append(prettyHtmlPrint(config));\r\n\r\n if (verbose) {\r\n\r\n GridHubConfiguration tmp = new GridHubConfiguration();\r\n\r\n builder.append(\"<b>Config details :</b><br/>\");\r\n builder.append(\"<b>hub launched with :</b>\");\r\n builder.append(tmp.hubConfig);\r\n\r\n\r\n builder.append(\"<br/><b>the final configuration comes from :</b><br/>\");\r\n builder.append(\"<b>the default :</b><br/>\");\r\n builder.append(prettyHtmlPrint(tmp));\r\n\r\n builder.append(prettyHtmlPrint(tmp));\r\n }\r\n return builder.toString();\r\n }", "public boolean configSet() {\n return config != null;\n }", "protected String buildConfigString() {\n if (multicastAddress == null) {\n throw new IllegalStateException(\"'multcastAddress' is not set\");\n }\n\n if (multicastPort == null) {\n throw new IllegalStateException(\"'multcastPort' is not set\");\n }\n\n return \"UDP(mcast_addr=\"\n + multicastAddress\n + \";mcast_port=\"\n + multicastPort\n + \";ip_ttl=32):\"\n + \"PING(timeout=3000;num_initial_members=6):\"\n + \"FD(timeout=3000):\"\n + \"VERIFY_SUSPECT(timeout=1500):\"\n + \"pbcast.NAKACK(gc_lag=10;retransmit_timeout=600,1200,2400,4800):\"\n + \"pbcast.STABLE(desired_avg_gossip=10000):\"\n + \"FRAG:\"\n + \"pbcast.GMS(join_timeout=5000;join_retry_timeout=2000;\"\n + \"shun=true;print_local_addr=false)\";\n }", "public String getConfigToSave() {\n return configToSave;\n }", "public String getConfigToSave() {\n return configToSave;\n }", "public String getConfigToSave() {\n return configToSave;\n }", "public String getConfigToSave() {\n return configToSave;\n }", "public static Config getConfig(){\n return _Config;\n }", "private void GetConfig()\n {\n boolean useClassPath = false;\n if(configFile_ == null)\n {\n useClassPath = true;\n configFile_ = \"data.config.lvg\";\n }\n // read in configuration file\n if(conf_ == null)\n {\n conf_ = new Configuration(configFile_, useClassPath);\n }\n }", "public String getCurrentConfigSuffix() {\r\n return currentConfigSuffix;\r\n }", "public DeviceConfig getConfig() {\n return config;\n }", "public boolean isSetConfig() {\n return this.config != null;\n }", "public MyConfig getConfig() {\n return config;\n }", "public static Config getConfig() {\r\n\t\treturn cfg;\r\n\t}", "public YangString getLocalConfigApnValue() throws JNCException {\n YangString localConfigApn = (YangString)getValue(\"local-config-apn\");\n if (localConfigApn == null) {\n localConfigApn = new YangString(\"default.apnni.com\"); // default\n }\n return localConfigApn;\n }", "public String getConfig(String configKey) {\n\t\t// Do something if key doesn't exist\n\t\t\n\t\treturn serverOptions.get(configKey);\n\t}", "public String getXMLConfiguration()\n {\n return this.XMLConfiguration;\n }", "public String getStatus() {\n return ready ? \"ready\" : \"not ready\";\n }", "static Buffer getASPConfigBuffer()\n {\n return ASPConfigFile.cfg;\n }", "public static String getString(Tag tag){\n makeInstance();\n return settingsFile.getString(tag);\n }", "public static String getString(final String key) {\r\n if (PROP == null) {\r\n throw new RuntimeException(\"Config hasn't been initialized yet.\");\r\n }\r\n if (PROP.containsKey(key))\r\n return PROP.getProperty(key);\r\n else\r\n throw new RuntimeException(\"No config key found for [\" + key + \"].\"\r\n + \" from PROP:\" + PROP);\r\n }", "public static String getTaskConfiguration(ScheduledTask task){\r\n\t\treturn task.getTaskConfiguration();\r\n\t}", "boolean hasStartingConfig() {\n return startCfg_ != null;\n }", "public String getDesc() {\n return \"This bootstrap determines if the Payment Plan Configuration needs to be downloaded.\";\n }", "public final String ping() {\n\t\tlog.debug(\"I'm here \\\"\" + workDir + \"\\\"\");\n\t\treturn configRootDir;\n\t}", "public Object\tgetConfiguration();", "protected String getLocationInfo() {\n\t\tString locInfo = \"\";\n\t\tif (currParseLocation != null) {\n\t\t\tlocInfo = StreamsResources.getStringFormatted(StreamsResources.RESOURCE_BUNDLE_NAME,\n\t\t\t\t\t\"ConfigParserHandler.at.line\", currParseLocation.getLineNumber());\n\t\t}\n\t\treturn locInfo;\n\t}", "EventWriterConfig getConfig();", "public String getProperty(String key) {\r\n \tif (mConfig.containsKey(key)){\r\n \t\treturn mConfig.getProperty(key);\r\n \t}else{\r\n \t\tSystem.out.println(\"[ERROR] Not defined property key: \" + key);\r\n \t\treturn null;\r\n \t}\r\n \r\n }", "public String getFuncConfig() {\n\t\treturn funcConfig;\n\t}", "boolean hasConfiguration();", "@java.lang.Override\n public boolean hasConfiguration() {\n return configuration_ != null;\n }", "public static String getConfigFileName() {\r\n\t\treturn configFileName;\r\n\t}", "private static String readPropertiesFile() {\n Properties prop = new Properties();\n\n try (InputStream inputStream = MembershipService.class.getClassLoader().getResourceAsStream(\"config.properties\")) {\n\n if (inputStream != null) {\n prop.load(inputStream);\n } else {\n throw new FileNotFoundException(\"property file 'config.properties' not found in the classpath\");\n }\n } catch (Exception e) {\n return \"\";\n }\n return prop.getProperty(\"introducer\");\n }", "public ConfigCommon getConfig() {\n return config;\n }", "@Override\n\tpublic Map<String, String> getConf() {\n\t\treturn null;\n\t}", "public String getConfigurationField() {\n return configField;\n }", "protected Config getConfig () {\n return this.conf;\n }", "public boolean isConfigInitalized()\n\t{\n\t\treturn this.isInitialized;\n\t}", "public String readTemplateHtConfig() throws IOException {\n StringBuilder sb = new StringBuilder();\n URL url = new URL(HumantaskEditorConstants.DUMMY_HTCONFIG_LOCATION);\n try (InputStream inputStream = url.openConnection().getInputStream();\n BufferedReader in = new BufferedReader(new InputStreamReader(inputStream,\n HumantaskEditorConstants.UTF8_STRING))) {\n String inputLine;\n while ((inputLine = in.readLine()) != null) {\n sb.append(inputLine).append(HumantaskEditorConstants.NEWLINE_CHAR);\n }\n } catch (IOException e) {\n IStatus editorStatus = new Status(IStatus.ERROR, Activator.PLUGIN_ID, e.getMessage());\n ErrorDialog.openError(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(),\n HumantaskEditorConstants.ERROR_MESSAGE,\n HumantaskEditorConstants.ERROR_READING_FROM_PROJECT_MESSAGE, editorStatus);\n }\n return sb.toString();\n }", "private String getString() {\n\t\treturn null;\n\t}", "Configuration getConfiguration();", "Configuration getConfiguration();" ]
[ "0.69960487", "0.6857309", "0.68475425", "0.67496216", "0.67336243", "0.67312294", "0.6558554", "0.6523057", "0.6410004", "0.6379875", "0.62685496", "0.62422585", "0.6099389", "0.5956475", "0.5947704", "0.5933898", "0.5917341", "0.5915325", "0.58949745", "0.5874884", "0.5832322", "0.5828457", "0.5785934", "0.578217", "0.5757384", "0.57261336", "0.57155704", "0.5699277", "0.56822985", "0.5663859", "0.56636864", "0.56221086", "0.56203645", "0.55766124", "0.5570328", "0.5558247", "0.5556306", "0.55338377", "0.5513847", "0.54991615", "0.54968", "0.549046", "0.54904073", "0.54877496", "0.546459", "0.54608333", "0.54448605", "0.5428427", "0.5412176", "0.5408214", "0.5391188", "0.5382907", "0.5381009", "0.53741753", "0.53722566", "0.53590614", "0.53523314", "0.5346681", "0.5338759", "0.53377783", "0.5330215", "0.53140545", "0.53140545", "0.53140545", "0.53140545", "0.5312299", "0.5309042", "0.5305875", "0.529815", "0.5283131", "0.5282455", "0.5276272", "0.52755964", "0.5267823", "0.52667445", "0.5250773", "0.52479523", "0.52356386", "0.5231676", "0.5212279", "0.5212189", "0.5210565", "0.521041", "0.52099824", "0.5196344", "0.519159", "0.51878995", "0.5186854", "0.51783997", "0.51760644", "0.5172912", "0.5170002", "0.51660055", "0.51601005", "0.5158156", "0.5156797", "0.5153445", "0.51504374", "0.5136168", "0.5134901", "0.5134901" ]
0.0
-1
Instantiates a new query region manager impl.
@SuppressWarnings("PMD.ConstructorCallsOverridableMethod") public QueryRegionManagerImpl(Toolbox tb, DataGroupController dataGroupController) { super(tb.getEventManager()); myToolbox = tb; myModuleStateController = new QueryRegionStateController(this, tb); myQueryRegions = New.set(); myRemoveAllEventListener = event -> removeAllQueryRegions(); myToolbox.getEventManager().subscribe(DataRemovalEvent.class, myRemoveAllEventListener); myToolbox.getUIRegistry().getContextActionManager().registerContextMenuItemProvider(ContextIdentifiers.DELETE_CONTEXT, Void.class, myDeleteContextMenuProvider); addService( new QueryRegionPickHandler(myToolbox.getControlRegistry().getControlContext(ControlRegistry.GLUI_CONTROL_CONTEXT), myToolbox.getEventManager(), dataGroupController, this::getQueryRegions)); addService(new QueryRegionSelectionHandler(myToolbox.getUIRegistry().getContextActionManager(), dataGroupController, myToolbox.getUIRegistry().getMainFrameProvider(), myToolbox.getDataFilterRegistry(), this::getQueryRegions)); // Register the state manager after all the other plugins so that // queries will get activated after other layers. myListener = event -> { if (event.getStage() == ApplicationLifecycleEvent.Stage.PLUGINS_INITIALIZED) { myToolbox.getModuleStateManager().registerModuleStateController("Query Areas", myModuleStateController); myToolbox.getEventManager().unsubscribe(ApplicationLifecycleEvent.class, myListener); myListener = null; } }; myToolbox.getEventManager().subscribe(ApplicationLifecycleEvent.class, myListener); bindEvent(DataTypeInfoFocusEvent.class, this::handleDataTypeInfoFocusEvent); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public SystemRegionExample() {\n oredCriteria = new ArrayList<Criteria>();\n }", "public Region() { }", "public Region() {\n }", "public CustomerAddressQuery region(CustomerAddressRegionQueryDefinition queryDef) {\n startField(\"region\");\n\n _queryBuilder.append('{');\n queryDef.define(new CustomerAddressRegionQuery(_queryBuilder));\n _queryBuilder.append('}');\n\n return this;\n }", "public QueryRegistry() {\r\n }", "public RegionView() {\n initComponents();\n this.regionController=new RegionController(new MyConnection().getConnection());\n bindingTable();\n }", "WithCreate withRegion(Region location);", "WithCreate withRegion(Region location);", "public QueryLocator() {\n this(new Random().nextInt(1024));\n }", "private Queries() {\n // prevent instantiation\n }", "public QueryExecutorMDB() {\n\t}", "WithCreate withRegion(String location);", "WithCreate withRegion(String location);", "public SuperRegionAccessBean () {\n super();\n }", "Geq createGeq();", "public RegionDAO(SessionFactory factory) {\r\n this.factory = factory;\r\n }", "public RegionSample() {\n\t\tsuper();\n\t}", "public void instantiation() {\n TokenCredential tokenCredential = new DefaultAzureCredentialBuilder().build();\n\n // BEGIN: com.azure.monitor.query.MetricsQueryClient.instantiation\n MetricsQueryClient metricsQueryClient = new MetricsQueryClientBuilder()\n .credential(tokenCredential)\n .buildClient();\n // END: com.azure.monitor.query.MetricsQueryClient.instantiation\n\n // BEGIN: com.azure.monitor.query.MetricsQueryAsyncClient.instantiation\n MetricsQueryAsyncClient metricsQueryAsyncClient = new MetricsQueryClientBuilder()\n .credential(tokenCredential)\n .buildAsyncClient();\n // END: com.azure.monitor.query.MetricsQueryAsyncClient.instantiation\n }", "private HRegionInfo createRegion(final HTableDescriptor\n htd, byte[] startKey, byte[] endKey)\n throws IOException {\n Table meta = connection.getTable(TableName.META_TABLE_NAME, tableExecutorService);\n HRegionInfo hri = new HRegionInfo(htd.getTableName(), startKey, endKey);\n MetaTableAccessor.addRegionToMeta(meta, hri);\n meta.close();\n return hri;\n }", "public Region() {\n initComponents();\n bindingTabel();\n }", "public CloudinsRegionRecord() {\n super(CloudinsRegion.CLOUDINS_REGION);\n }", "public void setRegion(String region);", "public TrafficRegions() {\n }", "IRegion getRegion();", "public CustomerAddressQuery regionId() {\n startField(\"region_id\");\n\n return this;\n }", "public Query() {\n\n// oriToRwt = new HashMap();\n// oriToRwt.put(); // TODO\n }", "protected BaseQuery(QueryFactory queryFactory, String queryString,\n Map<String, Object> namedParameters, String[] projection, long startOffset, int maxResults,\n boolean local) {\n this.paramsDefined = true;\n this.queryFactory = queryFactory;\n this.queryString = queryString;\n this.namedParameters = namedParameters;\n this.projection = projection != null && projection.length > 0 ? projection : null;\n this.startOffset = startOffset < 0 ? 0 : (int) startOffset;\n this.maxResults = maxResults;\n this.local = local;\n }", "public Query() {\r\n }", "public static de.fraunhofer.fokus.movepla.model.Region create(long regionId) {\n return getPersistence().create(regionId);\n }", "public DataGeocoderImpl() {\r\n\t\tmanager = DALLocator.getDataManager();\r\n\t}", "public VendorLocationsDAOImpl() {\n\t\tsuper();\n\t}", "public interface RegionService {\n\t\n\tRegion getById(Long id);\n\tList<Region> getAll();\n}", "public interface RegionDao {\n Long create(Region reg);\n Region read(Long id);\n void update(Region reg);\n void delete(Region reg);\n List<Region> findAll();\n List<Region> findForName(String name);\n List<Region> findForIndeces(int start,int end);\n List<Region> getPorcies(int count_el);\n}", "public void setRegion(String region) {\n this.region = region;\n }", "public void setRegion(String region) {\n this.region = region;\n }", "public IntercityBus(){\n super(\"CombustionEngine\");\n super.setRegion(\"Regional\");\n }", "public void setRegion(CoordinateRadius region);", "public Query() {\n initComponents();\n }", "public SolrQuery() {\n super(null);\n store = null;\n }", "public static QueryInterface createQuery() {\n return new XmlQuery();\n }", "public CloudinsRegionRecord(Long id, String name, Long managerId, String managerName, String hostIp, String hostUsername, String hostPassword, String company, String remark) {\n super(CloudinsRegion.CLOUDINS_REGION);\n\n set(0, id);\n set(1, name);\n set(2, managerId);\n set(3, managerName);\n set(4, hostIp);\n set(5, hostUsername);\n set(6, hostPassword);\n set(7, company);\n set(8, remark);\n }", "public void setRegion(Region region) {\n this.region = region;\n }", "public ProtectedRegion createRegion(UUID id, UUID owner, Location location, Material material)\n\t{\n\t\t// Create the region instance\n\t\tProtectedRegion region = new ProtectedRegion(name, material, id, owner, location, radius(), height());\n\t\tif(!lore().isEmpty()) region.setLore(lore());\n\t\tif(!title().isEmpty()) region.setTitle(title());\n\t\treturn region;\n\t}", "@Override\r\n public void addQueryRegion(QueryRegion region)\r\n {\n removeQueryRegion(region.getGeometries());\r\n\r\n synchronized (myQueryRegions)\r\n {\r\n myQueryRegions.add(region);\r\n }\r\n\r\n Collection<PolygonGeometry> geometries = New.collection(region.getGeometries().size());\r\n for (PolygonGeometry polygon : region.getGeometries())\r\n {\r\n if (polygon.getRenderProperties().isDrawable() || polygon.getRenderProperties().isPickable())\r\n {\r\n geometries.add(polygon);\r\n }\r\n }\r\n myToolbox.getGeometryRegistry().addGeometriesForSource(this, geometries);\r\n\r\n myChangeSupport.notifyListeners(listener -> listener.queryRegionAdded(region), myDispatchExecutor);\r\n }", "public void setRegion(String region) {\r\n this.region = region;\r\n }", "public void setRegion(String region) {\r\n this.region = region;\r\n }", "public void setRegion(String region) {\r\n this.region = region;\r\n }", "public void setRegion(String region) {\n this.region = region;\n }", "public void setRegion(String region) {\n this.region = region;\n }", "public void setRegion(String region) {\n this.region = region;\n }", "public HRegionServer(HServerAddress address, HBaseConfiguration conf)\n throws IOException { \n this.abortRequested = false;\n this.fsOk = true;\n this.conf = conf;\n this.connection = ServerConnectionManager.getConnection(conf);\n \n this.isOnline = false;\n \n // Config'ed params\n this.numRetries = conf.getInt(\"hbase.client.retries.number\", 2);\n this.threadWakeFrequency = conf.getInt(THREAD_WAKE_FREQUENCY, 10 * 1000);\n this.msgInterval = conf.getInt(\"hbase.regionserver.msginterval\", 3 * 1000);\n this.serverLeaseTimeout =\n conf.getInt(\"hbase.master.lease.period\", 120 * 1000);\n \n // Cache flushing thread.\n this.cacheFlusher = new MemcacheFlusher(conf, this);\n \n // Compaction thread\n this.compactSplitThread = new CompactSplitThread(this);\n \n // Log rolling thread\n this.logRoller = new LogRoller(this);\n \n // Log flushing thread\n this.logFlusher =\n new LogFlusher(this.threadWakeFrequency, this.stopRequested);\n \n // Task thread to process requests from Master\n this.worker = new Worker();\n this.workerThread = new Thread(worker);\n \n // Server to handle client requests\n this.server = HbaseRPC.getServer(this, address.getBindAddress(), \n address.getPort(), conf.getInt(\"hbase.regionserver.handler.count\", 10),\n false, conf);\n // Address is givin a default IP for the moment. Will be changed after\n // calling the master.\n this.serverInfo = new HServerInfo(new HServerAddress(\n new InetSocketAddress(DEFAULT_HOST,\n this.server.getListenerAddress().getPort())), System.currentTimeMillis(),\n this.conf.getInt(\"hbase.regionserver.info.port\", 60030));\n if (this.serverInfo.getServerAddress() == null) {\n throw new NullPointerException(\"Server address cannot be null; \" +\n \"hbase-958 debugging\");\n }\n this.numRegionsToReport = \n conf.getInt(\"hbase.regionserver.numregionstoreport\", 10); \n \n this.leases = new Leases(\n conf.getInt(\"hbase.regionserver.lease.period\", 60 * 1000),\n this.threadWakeFrequency);\n \n int nbBlocks = conf.getInt(\"hbase.regionserver.nbreservationblocks\", 4);\n for(int i = 0; i < nbBlocks; i++) {\n reservedSpace.add(new byte[DEFAULT_SIZE_RESERVATION_BLOCK]);\n }\n \n // Register shutdown hook for HRegionServer, runs an orderly shutdown\n // when a kill signal is recieved\n Runtime.getRuntime().addShutdownHook(new ShutdownThread(this));\n }", "void addRegion(Region region);", "public interface RegionMapper {\n List<Province> queryAllProvince();\n String queryProvince(@Param(\"provinceId\") Integer provinceId);\n String queryCityByPid(@Param(\"cityId\") Integer cityId );\n String queryDistrictByCode(@Param(\"areaId\") Integer areaId);\n\n List<Region> regionlist(int pid);\n}", "public void setRegionManager(final RegionManagerBean injRegionManager) {\n regionManager = injRegionManager;\n }", "public QueryUtils() {\n }", "public static Finder<Long, Region> find() {\n return new Finder<Long, Region>(Long.class, Region.class);\n }", "public InlineQueryResultLocation() {\n super();\n }", "private Region creatRegion(String rName) {\n\t\tfor (Region region : listRegions) {\r\n\t\t\tif (region.getName().equals(rName)) {\r\n\t\t\t\treturn region;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn null;\r\n\t}", "private QueryGenerator() {\n }", "public void setRegion(String region) {\n this.region = region;\n }", "public TileRegion() {\n\t\tthis.bounds = new Rectangle();\n\t\tthis.type\t= CollisionType.land;\n\t}", "Region region();", "Region region();", "Region region();", "Region region();", "public interface DaoRegion {\n Long create(Region region);\n Region read(Long id);\n void update(Region region);\n void delete (Region region);\n List<Region> findAll();\n List<Region> findRegionByName(Region region);\n List<Region> findRegionById(Long id1, Long id2);\n List<Region> RegionPortion(int id, int size);\n}", "public ExplorerManager() {\n init();\n }", "public Builder setRegion(String region) {\n try {\n _locbld.setRegion(region);\n } catch (InvalidLocaleIdentifierException e) {\n throw new IllegalArgumentException(e);\n }\n return this;\n }", "public Region(String areaName, String zipCode, String regions) {\n this.areaName = areaName;\n this.zipCode = zipCode;\n this.regions = regions;\n }", "public Builder withRegion(final String region) {\n this.region = region;\n return this;\n }", "public void setRegion(EnumRegion region)\n {\n this.region = region;\n }", "private void registerCaches(){\n // Initialize region arraylist\n prisoners = new HashMap<>();\n regions = QueryManager.getRegions();\n prisonBlocks = QueryManager.getPrisonBlocks();\n portals = QueryManager.getPortals();\n }", "public QueryBuilder()\n {\n\tlabel = null;\n\tqueryCondition = null;\n\tselectionLimiter = null;\n\tselectionSorter = null;\n\n\tvariablesMap = new HashMap<String, Expression>();\n\tselectionLabelsReferencedByStats = new HashSet<String>();\n }", "public TypeOfRegion getRegion();", "private DbQuery() {}", "private UnitManager() {\r\n\t\tUM = new UnitMap(); // create an object\r\n\t}", "public com.clarifai.grpc.api.utils.Matrix.MatrixUint64.Builder getRegionLocationMatrixBuilder() {\n \n onChanged();\n return getRegionLocationMatrixFieldBuilder().getBuilder();\n }", "@Override\n\tprotected void initializeRegionAndEndpoint(ProcessContext context) {\n\t}", "public QueryPager() {\n }", "public VRpHrStpDAOImpl() {\r\n super();\r\n }", "private void loadSearchRegions() {\n showProgress(ApplicationConstants.DIALOG_HEADER, \"Please wait while we retrieve regions from server.\");\n String authToken = ShPrefManager.with(getActivity()).getToken();\n RestClient.getAPI().getRegions(authToken, new RestCallback<RegionsResponse>() {\n @Override\n public void failure(RestError restError) {\n OpenHomeUtils.showToast(getActivity().getApplicationContext(), \"Could not load regions from the server.\", Toast.LENGTH_LONG);\n }\n\n @Override\n public void success(RegionsResponse regionsResponse, Response response) {\n if (regionsResponse.getMessage().size() > 0) {\n regionsList = regionsResponse.getMessage();\n setOnClickListeners();\n populateRegions();\n } else {\n String message = \"There is an error loading data. Please contact administrator..\";\n CustomDialogFragment regSuccessDialogFragment = CustomDialogFragment.newInstance(R.string.try_again,\n message, ApplicationConstants.BUTTON_OK, 0);\n regSuccessDialogFragment.show(getActivity().getFragmentManager(), \"AddPropertyFragment\");\n }\n }\n });\n\n getAllHazards();\n }", "public Region getRegion() {\n return region;\n }", "public QuarkusInfinispanRegionFactory(Supplier<Executor> cacheExecutorSupplier) {\n this.cacheExecutorSupplier = cacheExecutorSupplier;\n }", "public RiftsawServiceLocator() {\n }", "@Bean\n @Qualifier(\"localSegment\")\n public CommandBus localSegment(TransactionManager transactionManager) {\n CommandBus commandBus = new AsynchronousCommandBus();\n commandBus.registerHandlerInterceptor(new TransactionManagingInterceptor(transactionManager));\n return commandBus;\n }", "protected JPAQuery<T> createQuery() {\n\t\tJPAQuery<T> query = new JPAQuery<>(entityManager);\n\t\tquery.from(getDslRoot());\n\t\treturn query;\n\t}", "public Region(World world, int width, int height) {\n\t\tthis.width = width;\n\t\tthis.height = height;\n\t\tcellGrid = new CellGrid(this,width,height);\n\t\tentities = new EntityList(this);\n\t\twalls = new Walls();\n\t\tthis.world = world;\n\t\tthis.soundEngine = new SoundEngine();\n\t\tthis.addBoundingWalls();\n\t}", "public Region(String n,Set<Territoire> lT,Boolean plusGRegion) {\n\t\tthis.nom=n;\n\t\tthis.listeTerritoire=lT;\n\t\tthis.plusGrandeRegion=plusGRegion;\n\t}", "public ProtectedRegion createRegion(UUID owner, Location location, Material material)\n\t{\n\t\t// Generate new id for the region\n\t\tUUID id = UUID.randomUUID();\n\t\treturn createRegion(id, owner, location, material);\n\t}", "public QRFragment() {\n }", "private static void init() throws Exception \r\n\t{\r\n dynamoDB = new AmazonDynamoDBClient(new ClasspathPropertiesFileCredentialsProvider());\r\n Region usEast1 = Region.getRegion(Regions.US_EAST_1);\r\n dynamoDB.setRegion(usEast1);\r\n }", "public ProductIndexQuery() {\n\t}", "WithResourceGroup withRegion(Region location);", "WithResourceGroup withRegion(Region location);", "public OWLAnonymousIndividualHGDB()\r\n\t{\r\n\r\n\t}", "public OperationFactory() {\n initMap();\n }", "private ASTQuery() {\r\n dataset = Dataset.create();\r\n }", "@Delegate\n @Path(\"/projects/{project}/regions/{region}\")\n RegionOperationApi getRegionOperationApi(@PathParam(\"project\") String project, @PathParam(\"region\") String region);", "private void loadSearchRegions() {\n showProgress(ApplicationConstants.DIALOG_HEADER, \"Please wait while we retrieve matching results.\");\n String authToken = ShPrefManager.with(getActivity()).getToken();\n RestClient.getAPI().getRegions(authToken, new RestCallback<RegionsResponse>() {\n @Override\n public void failure(RestError restError) {\n hideProgress();\n OpenHomeUtils.showToast(getActivity().getApplicationContext(), restError.getErrorMessage(), Toast.LENGTH_LONG);\n }\n\n @Override\n public void success(RegionsResponse regionsResponse, Response response) {\n hideProgress();\n if (regionsResponse.getMessage().size() > 0) {\n regionsList = regionsResponse.getMessage();\n for (RegionsResponse.Regions region : regionsList) {\n listingsCount += region.getListingsCount();\n if (region.getParentId() == 0)\n adapterList.add(region);\n }\n regionsAdapter = new RegionsAdapter(getActivity(), adapterList, 0);\n mRecyclerView.setAdapter(regionsAdapter);\n currentAdapter = \"R\";\n listingsCountDisplayTextView.setText(listingsCount + \" Listings\");\n currentDisplayingParentId = 0;\n\n } else {\n String message = \"No results to display. Please modify the search criteria and try again.\";\n CustomDialogFragment regSuccessDialogFragment = CustomDialogFragment.newInstance(R.string.try_again,\n message, ApplicationConstants.BUTTON_OK, 0);\n regSuccessDialogFragment.show(getActivity().getFragmentManager(), \"SearchRegionsFragment\");\n }\n }\n });\n }", "@Query(\"from Region\")\n\tpublic List<Region> findAllRegiones();" ]
[ "0.64868903", "0.6375734", "0.6335579", "0.6074685", "0.6009711", "0.58873457", "0.56554604", "0.56554604", "0.56525743", "0.5562071", "0.5517902", "0.5507369", "0.5507369", "0.5468432", "0.544377", "0.541333", "0.53538364", "0.5347308", "0.5335456", "0.5319787", "0.5316477", "0.5301801", "0.5299512", "0.52900404", "0.5279094", "0.5221322", "0.5206003", "0.5184844", "0.517667", "0.5165358", "0.5135513", "0.51206505", "0.51167053", "0.5072817", "0.50586975", "0.5051997", "0.5027075", "0.50188196", "0.50096834", "0.5008372", "0.50039923", "0.50034577", "0.49958187", "0.49925822", "0.49767628", "0.49767628", "0.49767628", "0.49616677", "0.49616677", "0.49616677", "0.49591002", "0.4947903", "0.4944459", "0.49183226", "0.49173167", "0.49170294", "0.4889632", "0.4886243", "0.48775825", "0.4876047", "0.48754853", "0.48687485", "0.48687485", "0.48687485", "0.48687485", "0.4863369", "0.48618287", "0.48479608", "0.48353186", "0.48341268", "0.48175722", "0.4810713", "0.48078197", "0.48053655", "0.48027888", "0.48023987", "0.4798177", "0.47958767", "0.47929925", "0.47781911", "0.47759113", "0.47728184", "0.4770691", "0.47559974", "0.47528666", "0.47501028", "0.47467038", "0.47442403", "0.4741248", "0.4734998", "0.47227544", "0.47226274", "0.4718583", "0.4718583", "0.47137114", "0.47077084", "0.4707093", "0.47041348", "0.47038463", "0.47016552" ]
0.60035694
5
Handles a data type focus change.
private void handleDataTypeInfoFocusEvent(DataTypeInfoFocusEvent event) { if (event.getSource() == this) { return; } Collection<? extends DataTypeInfo> types = event.getTypes(); synchronized (myQueryRegions) { if (event.getFocusType() == FocusType.HOVER_GAINED && types.stream().anyMatch(t -> t.isQueryable())) { myQueryRegions.forEach(r -> r.getGeometries().forEach( g -> g.getRenderProperties().setHidden(!types.stream().anyMatch(t -> r.appliesToType(t.getTypeKey()))))); } else { myQueryRegions.forEach(r -> r.getGeometries().forEach(g -> g.getRenderProperties().setHidden(false))); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void typeEvent(KeyEvent e) {\n char typed = e.getKeyChar();\n //if the char is not a number remove the char\n if (typed < '0' || typed > '9') {\n //input is illigal so put empty char insted of the sent char\n e.setKeyChar(Character.MIN_VALUE);\n } else {\n //update the text that is in the text filed and the value in the factory\n updateShapeFactory(updateValue(e));\n }\n //show the update\n repaint();\n }", "private void changeFocus() {\n focusChange(etTitle, llTitle, mActivity);\n focusChange(etOriginalPrice, llOriginalPrice, mActivity);\n focusChange(etTotalItems, llTotalItems, mActivity);\n focusChange(etDescription, llDescription, mActivity);\n }", "public native final EditorBaseEvent changedType(String val) /*-{\n\t\tthis.changedType = val;\n\t\treturn this;\n\t}-*/;", "@Override\n\tprotected void handleFocus (Context context, boolean focus) {\n\t\tif (focus) context.requestFocus();\n\t}", "@Override\n public void focus(FieldEvents.FocusEvent event) {\n TextField tf = (TextField) event.getSource();\n tf.setCursorPosition(tf.getValue().length());\n }", "protected void processKeyTyped(KeyEvent e) {\n char kChar = e.getKeyChar();\n if (editor != null ||\n !autoEdit ||\n e.isConsumed() ||\n isReadOnly() ||\n kChar == 0 ||\n kChar == '\\t' ||\n kChar == '\\r' ||\n kChar == '\\n' ||\n kChar == ' ' || \n kChar == 27 || // ESCAPE\n isToggleItem(subfocus) ||\n (e.isAltDown() ^ e.isControlDown()) ||\n !canSet(subfocus, false))\n return;\n startEdit(subfocus);\n Component eComp = null;\n if (editor != null && (eComp = editor.getComponent()) != null) {\n eComp.dispatchEvent(e);\n }\n }", "private void selectedDasTypeChanged() {\n\t\tselectedDasType = (DASType) jcbDasType.getSelectedItem();\n\t}", "@Override\n\tpublic void setFocus() {\n\t\t\n\t}", "@Override\n\tpublic void setFocus() {\n\t\t\n\t}", "@Override\n\tpublic void setFocus() {\n\t\t\n\t}", "@Override\n\tpublic void setFocus() {\n\t\t\n\t}", "@Override\n\tpublic void setFocus() {\n\t\t\n\t}", "@Override\n\tpublic void setFocus() {\n\n\t}", "@Override\n\tpublic void setFocus() {\n\n\t}", "@Override\n\tpublic void setFocus() {\n\n\t}", "@Override\n\tpublic void setFocus() {\n\n\t}", "@Override\n public void setFocus() {\n }", "@Override\n public void focusLost(FocusEvent e) {\n String newValue = recordForm.getValueAt(currentColumn);\n recordNotifier.changeRecord(currentRow, currentColumn, newValue);\n }", "@Override\r\n\tpublic void setFocus() {\r\n\t}", "private void vatTxtKeyTyped(java.awt.event.KeyEvent evt) {\n }", "@Override\n\tpublic void setFocus() {\n\t}", "private void OnChanged(boolean focus)\r\n {\n if (!focus)\r\n {\r\n //If the validation returns false (the field doesn't match)\r\n if (!Validate())\r\n {\r\n //Reset the text to the default\r\n setText(\"000-000-0000\");\r\n selectAll();\r\n }\r\n }\r\n }", "public void focus() {}", "@Override\n public void inputTypeChange(ModelInputTypes m) {\n \n }", "@Override\r\n\tpublic void setFocus() {\n\t\t\r\n\t}", "private void handleLCTypeChange() {\n\t\tString lc = cbLoadingCharge.getText();\n\t\tif (optionB[3].equals(lc)) {\n\t\t\ttxtLC_article.setEnabled(false);\n\t\t\ttxtLC_article.setText(EMPTYSTRING);\n\t\t} else {\n\t\t\ttxtLC_article.setEnabled(true);\n\t\t}\n\t}", "@Override\r\n public void focusGained(FocusEvent event) {\r\n }", "@Override\n\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\n\t\t\t}", "@Override\n\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\n\t\t\t}", "@Override\n\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\n\t\t\t}", "private void updateDataType(){\n\t\tif(propertiesObj == null)\n\t\t\treturn;\n\n\t\tboolean deleteKids = false;\n\t\tint index = cbDataType.getSelectedIndex();\n\t\tQuestionDef questionDef = (QuestionDef)propertiesObj;\n\t\tif((questionDef.getDataType() == QuestionDef.QTN_TYPE_LIST_EXCLUSIVE ||\n\t\t\t\tquestionDef.getDataType() == QuestionDef.QTN_TYPE_LIST_MULTIPLE) &&\n\t\t\t\t!(index == DT_INDEX_SINGLE_SELECT || index == DT_INDEX_MULTIPLE_SELECT)){\n\t\t\tif(questionDef.getOptionCount() > 0 && !Window.confirm(LocaleText.get(\"changeWidgetTypePrompt\"))){\n\t\t\t\tindex = (questionDef.getDataType() == QuestionDef.QTN_TYPE_LIST_EXCLUSIVE) ? DT_INDEX_SINGLE_SELECT : DT_INDEX_MULTIPLE_SELECT;\n\t\t\t\tcbDataType.setSelectedIndex(index);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tdeleteKids = true;\n\t\t}\n\t\telse if((questionDef.getDataType() == QuestionDef.QTN_TYPE_REPEAT) &&\n\t\t\t\t!(index == DT_INDEX_REPEAT)){\n\t\t\tif(!Window.confirm(LocaleText.get(\"changeWidgetTypePrompt\"))){\n\t\t\t\tindex = DT_INDEX_REPEAT;\n\t\t\t\tcbDataType.setSelectedIndex(index);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tdeleteKids = true;\n\t\t}\n\n\t\t//cbDataType.setSelectedIndex(index);\n\t\tsetQuestionDataType((QuestionDef)propertiesObj);\n\t\tformChangeListener.onFormItemChanged(propertiesObj);\n\t\tif(deleteKids)\n\t\t\tformChangeListener.onDeleteChildren(propertiesObj);\n\t}", "protected void keyTyped(char c, int code)\r\n\t{\r\n\t\tif (customBindingTickStart > 0)\r\n\t\t{\r\n\t\t\tthis.lastKeyCode = code;\r\n\t\t\treturn;\r\n\t\t}\r\n\t\t\r\n\t\tif (JoypadControlList.textInputName != null \r\n\t\t\t\t&& JoypadControlList.textInputName.getVisible())\r\n\t\t{\r\n\t\t\tthis.lastKeyCode = code;\r\n\t\t\tJoypadControlList.textInputName.textboxKeyTyped(c, code);\r\n\t\t\treturn;\r\n\t\t}\r\n\t\t\r\n\t\tif (c == ' ' && controllers.size() > 0)\r\n\t\t{\r\n\t\t\ttoggleController();\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\ttry{\r\n\t\t\t\tsuper.keyTyped(c, code);}\r\n\t\t\tcatch(java.io.IOException e){}\r\n\t\t}\r\n\t}", "@Override\n public void focusGained(FocusEvent e) {\n }", "@Override\r\n\t\t\t\t\t\t\tpublic void focusGained(FocusEvent arg0) {\n\r\n\t\t\t\t\t\t\t}", "@Override\n\t\t\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\t\t\n\t\t\t\t\t}", "@Override\n\t\t\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\t\t\n\t\t\t\t\t}", "@Override\r\n public void focusGained(FocusEvent e) {\n }", "@Override\n\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\n\t\t}", "@Override\n\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\n\t\t}", "void setDataType(int type );", "@Override\n\t\t\t\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}", "@Override\n\t\t\t\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}", "@Override\n\t\t\t\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}", "@Override\n\t\t\t\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}", "@Override\n\t\t\t\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}", "@Override\n\t\t\t\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}", "@Override\n\t\t\t\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}", "@Override\n public void focusGained(FocusEvent e) {\n }", "@Override\n public void focusGained(FocusEvent e) {\n }", "@Override\n public void focusGained(FocusEvent e) {\n }", "@Override\n public void focusGained(FocusEvent e) {\n }", "@Override\n\tpublic void focusGained(FocusEvent arg0) {\n\t\t\n\t}", "@Override\n\tpublic void focusGained(FocusEvent arg0) {\n\t\t\n\t}", "@Override\r\n\tpublic void setFocus() {\n\r\n\t}", "@Override\r\n\tpublic void setFocus() {\n\r\n\t}", "@Override\r\n\tpublic void setFocus() {\n\r\n\t}", "@Override\r\n\tpublic void setFocus() {\n\r\n\t}", "@Override\r\n\tpublic void setFocus() {\n\r\n\t}", "@Override\r\n\tpublic void setFocus() {\n\r\n\t}", "@Override\r\n\tpublic void setFocus() {\n\r\n\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\t\n\t\t\t}", "@Override\r\n\t\t\tpublic void focusGained(FocusEvent arg0) {\n\t\t\t\t\r\n\t\t\t}", "@Override\n\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\n\t\t}", "@Override\n\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\n\t\t}", "@Override\n\t\tpublic void keyTyped(KeyEvent arg0) {\n\t\t\t\n\t\t}", "@Override\n\t\t\tpublic void onAudioFocusChange(int arg0) {\n\t\t\t}", "@Override\n\t\t\t\tpublic void keyTyped(KeyEvent arg0)\n\t\t\t\t{\n\t\t\t\t\t\n\t\t\t\t}", "@Override public void keyTyped(KeyEvent e)\n {\n if (this.focusedComponent != null)\n this.focusedComponent.executeEvent(new KeyTypeEvent(e.getKey(),e.getKeyCode()));\n }", "private void jTextFieldPrecioKeyTyped(java.awt.event.KeyEvent evt) {\n char car = evt.getKeyChar();\n if (jTextFieldPrecio.getText().length() >= 9) {\n evt.consume();\n }\n if ((car < '0' || car > '9')) {\n evt.consume();\n }\n }", "private void txtCodigoPlatDiaKeyTyped(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_txtCodigoPlatDiaKeyTyped\n char c = evt.getKeyChar();\n if(c<'0' || c>'9') evt.consume();\n }", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\t\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t\t}", "@Override\n\tpublic void enter(ViewChangeEvent event) {\n\t\tuserTextField.focus();\n\t}", "public void setFocus();", "@Override\n\t\t\tpublic void focusGained(FocusEvent e) {\n\t\t\t\t\n\t\t\t}", "@Override\n\t\t\tpublic void focusGained(FocusEvent e) {\n\t\t\t\t\n\t\t\t}", "@Override\n\t\tpublic void keyTyped(KeyEvent e) {\n\n\t\t}", "@Override\n\t\t\t\tpublic void keyTyped(KeyEvent e) {\n\t\t\t\t\t\n\t\t\t\t}" ]
[ "0.5972439", "0.5767851", "0.5714471", "0.5646163", "0.5641537", "0.55092347", "0.54170763", "0.5395798", "0.5395798", "0.5395798", "0.5395798", "0.5395798", "0.5352831", "0.5352831", "0.5352831", "0.5352831", "0.53273803", "0.53269696", "0.5325742", "0.53163785", "0.53115594", "0.5310079", "0.5297361", "0.52925664", "0.52863604", "0.52835506", "0.5278447", "0.52539796", "0.52539796", "0.52539796", "0.5244854", "0.5234546", "0.52307564", "0.5221003", "0.521925", "0.521925", "0.5216169", "0.5211414", "0.5211414", "0.5208481", "0.5207865", "0.5207865", "0.5207865", "0.5207865", "0.5207865", "0.5207865", "0.5207865", "0.52008486", "0.52008486", "0.52008486", "0.52008486", "0.51985955", "0.51985955", "0.51881516", "0.51881516", "0.51881516", "0.51881516", "0.51881516", "0.51881516", "0.51881516", "0.51766086", "0.51766086", "0.51766086", "0.51766086", "0.51766086", "0.51766086", "0.51717454", "0.5168021", "0.5168021", "0.5168021", "0.5163103", "0.51630116", "0.515056", "0.51498723", "0.5148842", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.5144054", "0.51337516", "0.5128145", "0.5121448", "0.5121448", "0.5115107", "0.51076144" ]
0.6187007
0
remove old region(s) that are the same as the new region (have same geometries) before adding in new region to prevent feature duplication
@Override public void addQueryRegion(QueryRegion region) { removeQueryRegion(region.getGeometries()); synchronized (myQueryRegions) { myQueryRegions.add(region); } Collection<PolygonGeometry> geometries = New.collection(region.getGeometries().size()); for (PolygonGeometry polygon : region.getGeometries()) { if (polygon.getRenderProperties().isDrawable() || polygon.getRenderProperties().isPickable()) { geometries.add(polygon); } } myToolbox.getGeometryRegistry().addGeometriesForSource(this, geometries); myChangeSupport.notifyListeners(listener -> listener.queryRegionAdded(region), myDispatchExecutor); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void removeRegion(Region region);", "@Override\n \tpublic void regionsRemoved(RegionEvent evt) {\n \t\t\n \t}", "private void removeQueryBoundsFromGeometryRegistry(QueryRegion region)\r\n {\r\n myToolbox.getGeometryRegistry().removeGeometriesForSource(this, new HashSet<Geometry>(region.getGeometries()));\r\n }", "public Gel_BioInf_Models.VirtualPanel.Builder clearRelevantRegions() {\n relevantRegions = null;\n fieldSetFlags()[6] = false;\n return this;\n }", "public void handlesBlockingRegionDrag() {\r\n \t\tObject[] cells = graph.getDescendants(graph.getSelectionCells());\r\n \t\t// Put cells not in a blocking region to back\r\n \t\tHashSet<Object> putBack = new HashSet<Object>();\r\n \t\tfor (Object cell2 : cells) {\r\n \t\t\tif (cell2 instanceof JmtCell && ((JmtCell) cell2).parentChanged()) {\r\n \t\t\t\t// This cell was moved in, out or between blocking regions\r\n \t\t\t\tJmtCell cell = (JmtCell) cell2;\r\n \t\t\t\tObject key = ((CellComponent) cell.getUserObject()).getKey();\r\n \t\t\t\tObject oldRegionKey, newRegionKey;\r\n \t\t\t\tif (!(cell.getParent() instanceof BlockingRegion)) {\r\n \t\t\t\t\t// Object removed from blocking region\r\n \t\t\t\t\tputBack.add(cell2);\r\n \t\t\t\t\toldRegionKey = ((BlockingRegion) cell.getPrevParent()).getKey();\r\n \t\t\t\t\tmodel.removeRegionStation(oldRegionKey, key);\r\n \t\t\t\t\t// If region is empty, removes region too\r\n \t\t\t\t\tif (model.getBlockingRegionStations(oldRegionKey).size() == 0) {\r\n \t\t\t\t\t\tmodel.deleteBlockingRegion(oldRegionKey);\r\n \t\t\t\t\t}\r\n \t\t\t\t\t// Allow adding of removed objects to a new blocking region\r\n \t\t\t\t\tenableAddBlockingRegion(true);\r\n \t\t\t\t} else if (cell.getPrevParent() instanceof BlockingRegion) {\r\n \t\t\t\t\t// Object changed blocking region\r\n \t\t\t\t\toldRegionKey = ((BlockingRegion) cell.getPrevParent()).getKey();\r\n \t\t\t\t\tmodel.removeRegionStation(oldRegionKey, key);\r\n \t\t\t\t\t// If region is empty, removes region too\r\n \t\t\t\t\tif (model.getBlockingRegionStations(oldRegionKey).size() == 0) {\r\n \t\t\t\t\t\tmodel.deleteBlockingRegion(oldRegionKey);\r\n \t\t\t\t\t}\r\n \t\t\t\t\tnewRegionKey = ((BlockingRegion) cell.getParent()).getKey();\r\n \t\t\t\t\tmodel.addRegionStation(newRegionKey, key);\r\n \t\t\t\t} else {\r\n \t\t\t\t\t// Object added to a blocking region\r\n \t\t\t\t\tnewRegionKey = ((BlockingRegion) cell.getParent()).getKey();\r\n \t\t\t\t\tif (!model.addRegionStation(newRegionKey, key)) {\r\n \t\t\t\t\t\t// object cannot be added to blocking region (for\r\n \t\t\t\t\t\t// example it's a source)\r\n \t\t\t\t\t\tcell.removeFromParent();\r\n \t\t\t\t\t\tgraph.getModel().insert(new Object[] { cell }, null, null, null, null);\r\n \t\t\t\t\t\tputBack.add(cell);\r\n \t\t\t\t\t}\r\n \t\t\t\t\t// Doesn't allow adding of selected objects to a new\r\n \t\t\t\t\t// blocking region\r\n \t\t\t\t\tenableAddBlockingRegion(false);\r\n \t\t\t\t}\r\n \t\t\t\t// Resets parent for this cell\r\n \t\t\t\tcell.resetParent();\r\n \t\t\t}\r\n \t\t\t// Avoid insertion of a blocking region in an other\r\n \t\t\telse if (cell2 instanceof BlockingRegion) {\r\n \t\t\t\tBlockingRegion region = (BlockingRegion) cell2;\r\n \t\t\t\tif (region.getParent() != null) {\r\n \t\t\t\t\tregion.removeFromParent();\r\n \t\t\t\t\tgraph.getModel().insert(new Object[] { region }, null, null, null, null);\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t}\r\n \t\t// Puts cells removed from blocking regiont on background\r\n \t\tgraph.getModel().toBack(putBack.toArray());\r\n \t}", "private void cleanProblematicOverlappedRegions(RegionLocations locations) {\n RegionInfo region = locations.getRegionLocation().getRegion();\n\n boolean isLast = isEmptyStopRow(region.getEndKey());\n\n while (true) {\n Map.Entry<byte[], RegionLocations> overlap =\n isLast ? cache.lastEntry() : cache.lowerEntry(region.getEndKey());\n if (\n overlap == null || overlap.getValue() == locations\n || Bytes.equals(overlap.getKey(), region.getStartKey())\n ) {\n break;\n }\n\n if (LOG.isDebugEnabled()) {\n LOG.debug(\n \"Removing cached location {} (endKey={}) because it overlaps with \"\n + \"new location {} (endKey={})\",\n overlap.getValue(),\n Bytes.toStringBinary(overlap.getValue().getRegionLocation().getRegion().getEndKey()),\n locations, Bytes.toStringBinary(locations.getRegionLocation().getRegion().getEndKey()));\n }\n\n cache.remove(overlap.getKey());\n }\n }", "private void removeArea() {\n \t\tthis.set.remove( this.area );\n \t\tthis.finish();\n \t}", "@Test (timeout=180000)\n public void testDegenerateRegions() throws Exception {\n TableName table = TableName.valueOf(\"tableDegenerateRegions\");\n try {\n setupTable(table);\n assertNoErrors(doFsck(conf,false));\n assertEquals(ROWKEYS.length, countRows());\n\n // Now let's mess it up, by adding a region with a duplicate startkey\n HRegionInfo hriDupe =\n createRegion(tbl.getTableDescriptor(), Bytes.toBytes(\"B\"), Bytes.toBytes(\"B\"));\n TEST_UTIL.getHBaseCluster().getMaster().assignRegion(hriDupe);\n TEST_UTIL.getHBaseCluster().getMaster().getAssignmentManager()\n .waitForAssignment(hriDupe);\n ServerName server = regionStates.getRegionServerOfRegion(hriDupe);\n TEST_UTIL.assertRegionOnServer(hriDupe, server, REGION_ONLINE_TIMEOUT);\n\n HBaseFsck hbck = doFsck(conf,false);\n assertErrors(hbck, new ERROR_CODE[] { ERROR_CODE.DEGENERATE_REGION, ERROR_CODE.DUPE_STARTKEYS,\n ERROR_CODE.DUPE_STARTKEYS });\n assertEquals(2, hbck.getOverlapGroups(table).size());\n assertEquals(ROWKEYS.length, countRows());\n\n // fix the degenerate region.\n doFsck(conf,true);\n\n // check that the degenerate region is gone and no data loss\n HBaseFsck hbck2 = doFsck(conf,false);\n assertNoErrors(hbck2);\n assertEquals(0, hbck2.getOverlapGroups(table).size());\n assertEquals(ROWKEYS.length, countRows());\n } finally {\n cleanupTable(table);\n }\n }", "private void removeAllQueryBoundsFromGeometryRegistry()\r\n {\r\n myToolbox.getGeometryRegistry().removeGeometriesForSource(this);\r\n }", "private void populateRegionFilterComboBox() {\n Collection<String> uniqueRegions = new TreeSet<>();\n for (ReceiverRecord record : records) {\n uniqueRegions.add(record.getRegion());\n }\n regionFilterComboBox.getItems().removeAll(regionFilterComboBox.getItems());\n regionFilterComboBox.getItems().add(regionString);\n regionFilterComboBox.getItems().addAll(uniqueRegions);\n regionFilterComboBox.getSelectionModel().select(0);\n }", "private ArrayList<Region> processRegions(ArrayList<Region> list, int oldStart, int newStart, RegionSequenceData parent, String trackName) {\n // first make a deep clone of the list\n ArrayList<Region> newList=new ArrayList<Region>(list.size());\n for (Region reg:list) {\n Region newreg=reg.clone();\n newreg.setParent(null);\n newList.add(newreg);\n }\n if (oldStart==newStart) return newList; // no need to update reference frame\n // now update all coordinates since the frame of reference has been altered\n for (Region reg:newList) {\n reg.updatePositionReferenceFrame(oldStart, newStart); // this is \"recursive\" for nested regions\n }\n return newList;\n }", "void retainOutlineAndBoundaryGrid() {\n\t\tfor (final PNode child : getChildrenAsPNodeArray()) {\n\t\t\tif (child != selectedThumbOutline && child != yellowSIcolumnOutline && child != boundary) {\n\t\t\t\tremoveChild(child);\n\t\t\t}\n\t\t}\n\t\tcreateOrDeleteBoundary();\n\t}", "public void clearDirtyAreas() {\n synchronized (dirtyAreas) {\n dirtyAreas.clear();\n }\n renderedAreas.clear();\n fullUpdate = false;\n dirtyAreaCounter = 0;\n }", "@Override\n public void resetMap(){\n segmentList=new ArrayList<>();\n intersectionList=new ArrayList<>();\n this.setChanged();\n this.notifyObservers();\n }", "protected void doDeleteBoth() {\r\n\t\tif (renderer.surface != null) {\r\n\t\t\tUndoableMapEdit undo = new UndoableMapEdit(renderer.surface);\r\n\t\t\tdeleteEntitiesOf(renderer.surface.basemap, renderer.selectedRectangle, false);\r\n\t\t\tdeleteEntitiesOf(renderer.surface.buildingmap, renderer.selectedRectangle, true);\r\n\t\t\tundo.setAfter();\r\n\t\t\taddUndo(undo);\r\n\t\t\trepaint();\r\n\t\t}\r\n\t}", "public void deleteSelected() {\r\n \t\tObject cells[] = graph.getSelectionCells();\r\n \t\tGraphModel graphmodel = graph.getModel();\r\n \r\n \t\t// If a cell is a blocking region avoid removing its edges and\r\n \t\t// select its element at the end of the removal process\r\n \t\tSet edges = new HashSet();\r\n \t\tSet<Object> select = new HashSet<Object>();\r\n \r\n \t\t// Set with all regions that can be deleted as its child were removed\r\n \t\tSet<Object> regions = new HashSet<Object>();\r\n \t\t// Set with all JmtCells that we are removing\r\n \t\tSet<Object> jmtCells = new HashSet<Object>();\r\n \r\n \t\t// Giuseppe De Cicco & Fabio Granara\r\n \t\t// for(int k=0; k<cells.length; k++){\r\n \t\t// if(cells[k] instanceof JmtEdge){\r\n \t\t// ((JmtCell)(graphmodel.getParent(graphmodel.getSource((JmtEdge)cells[k])))).SubOut();\r\n \t\t// ((JmtCell)(graphmodel.getParent(graphmodel.getTarget((JmtEdge)cells[k])))).SubIn();\r\n \t\t// }\r\n \t\t//\r\n \t\t// }\r\n \t\tfor (int i = 0; i < cells.length; i++) {\r\n \t\t\tif (!(cells[i] instanceof BlockingRegion)) {\r\n \t\t\t\t// Adds edge for removal\r\n \t\t\t\tedges.addAll(DefaultGraphModel.getEdges(graphmodel, new Object[] { cells[i] }));\r\n \t\t\t\t// Giuseppe De Cicco & Fabio Granara\r\n \t\t\t\t// quando vado a eliminare un nodo, a cui collegato un arco,\r\n \t\t\t\t// vado ad incrementare o diminuire il contatore per il\r\n \t\t\t\t// pulsanteAGGIUSTATUTTO\r\n \t\t\t\t// Iterator iter = edges.iterator();\r\n \t\t\t\t// while (iter.hasNext()) {\r\n \t\t\t\t// Object next = iter.next();\r\n \t\t\t\t// if (next instanceof JmtEdge){\r\n \t\t\t\t// ((JmtCell)(graphmodel.getParent(graphmodel.getSource((JmtEdge)next)))).SubOut();\r\n \t\t\t\t// ((JmtCell)(graphmodel.getParent(graphmodel.getTarget((JmtEdge)next)))).SubIn();\r\n \t\t\t\t// }\r\n \t\t\t\t//\r\n \t\t\t\t// }\r\n \t\t\t\t// Stores parents information and cell\r\n \t\t\t\tif (cells[i] instanceof JmtCell) {\r\n \t\t\t\t\tif (((JmtCell) cells[i]).getParent() instanceof BlockingRegion) {\r\n \t\t\t\t\t\tregions.add(((JmtCell) cells[i]).getParent());\r\n \t\t\t\t\t}\r\n \t\t\t\t\tjmtCells.add(cells[i]);\r\n \t\t\t\t}\r\n \t\t\t} else {\r\n \t\t\t\t// Adds node for selection\r\n \t\t\t\tObject[] nodes = graph.getDescendants(new Object[] { cells[i] });\r\n \t\t\t\tfor (Object node : nodes) {\r\n \t\t\t\t\tif (node instanceof JmtCell || node instanceof JmtEdge) {\r\n \t\t\t\t\t\tselect.add(node);\r\n \t\t\t\t\t}\r\n \t\t\t\t}\r\n \t\t\t\t// Removes blocking region from data structure\r\n \t\t\t\tmodel.deleteBlockingRegion(((BlockingRegion) cells[i]).getKey());\r\n \t\t\t}\r\n \t\t}\r\n \r\n \t\tif (!edges.isEmpty()) {\r\n \t\t\tgraphmodel.remove(edges.toArray());\r\n \t\t}\r\n \t\t// removes cells from graph\r\n \t\tgraphmodel.remove(cells);\r\n \r\n \t\t// Checks if all children of a blocking region have been removed\r\n \t\tIterator<Object> it = regions.iterator();\r\n \t\twhile (it.hasNext()) {\r\n \t\t\tjmtCells.add(null);\r\n \t\t\tBlockingRegion region = (BlockingRegion) it.next();\r\n \t\t\tList child = region.getChildren();\r\n \t\t\tboolean empty = true;\r\n \t\t\tfor (int i = 0; i < child.size(); i++) {\r\n \t\t\t\tif (child.get(i) instanceof JmtCell && !jmtCells.contains(child.get(i))) {\r\n \t\t\t\t\tempty = false;\r\n \t\t\t\t\tbreak;\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t\tif (empty) {\r\n \t\t\t\tmodel.deleteBlockingRegion(region.getKey());\r\n \t\t\t\tgraphmodel.remove(new Object[] { region });\r\n \t\t\t}\r\n \t\t}\r\n \r\n \t\t// Removes cells from data structure\r\n \t\tfor (Object cell : cells) {\r\n \t\t\tif (cell instanceof JmtCell) {\r\n \t\t\t\tmodel.deleteStation(((CellComponent) ((JmtCell) cell).getUserObject()).getKey());\r\n \t\t\t} else if (cell instanceof JmtEdge) {\r\n \t\t\t\tJmtEdge link = (JmtEdge) cell;\r\n \t\t\t\tmodel.setConnected(link.getSourceKey(), link.getTargetKey(), false);\r\n \t\t\t}\r\n \t\t}\r\n \r\n \t\t// If no stations remains gray select and link buttons\r\n \t\tif (graph.getModel().getRootCount() == 0) {\r\n \t\t\tcomponentBar.clearButtonGroupSelection(0);\r\n \t\t\tsetConnect.setEnabled(false);\r\n \t\t\tsetSelect.setEnabled(false);\r\n \t\t}\r\n \r\n \t\t// Selects components from removed blocking regions\r\n \t\tif (select.size() > 0) {\r\n \t\t\tgraph.setSelectionCells(select.toArray());\r\n \t\t\t// Resets parent information of cells that changed parent\r\n \t\t\tit = select.iterator();\r\n \t\t\twhile (it.hasNext()) {\r\n \t\t\t\tObject next = it.next();\r\n \t\t\t\tif (next instanceof JmtCell) {\r\n \t\t\t\t\t((JmtCell) next).resetParent();\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t}\r\n \t}", "public Builder clearRegion() {\n \n region_ = 0;\n onChanged();\n return this;\n }", "@Test (timeout=180000)\n public void testDupeRegion() throws Exception {\n TableName table =\n TableName.valueOf(\"tableDupeRegion\");\n try {\n setupTable(table);\n assertNoErrors(doFsck(conf, false));\n assertEquals(ROWKEYS.length, countRows());\n\n // Now let's mess it up, by adding a region with a duplicate startkey\n HRegionInfo hriDupe =\n createRegion(tbl.getTableDescriptor(), Bytes.toBytes(\"A\"), Bytes.toBytes(\"B\"));\n\n TEST_UTIL.getHBaseCluster().getMaster().assignRegion(hriDupe);\n TEST_UTIL.getHBaseCluster().getMaster().getAssignmentManager()\n .waitForAssignment(hriDupe);\n ServerName server = regionStates.getRegionServerOfRegion(hriDupe);\n TEST_UTIL.assertRegionOnServer(hriDupe, server, REGION_ONLINE_TIMEOUT);\n\n // Yikes! The assignment manager can't tell between diff between two\n // different regions with the same start/endkeys since it doesn't\n // differentiate on ts/regionId! We actually need to recheck\n // deployments!\n while (findDeployedHSI(getDeployedHRIs((HBaseAdmin) admin), hriDupe) == null) {\n Thread.sleep(250);\n }\n\n LOG.debug(\"Finished assignment of dupe region\");\n\n // TODO why is dupe region different from dupe start keys?\n HBaseFsck hbck = doFsck(conf, false);\n assertErrors(hbck, new ERROR_CODE[] { ERROR_CODE.DUPE_STARTKEYS,\n ERROR_CODE.DUPE_STARTKEYS});\n assertEquals(2, hbck.getOverlapGroups(table).size());\n assertEquals(ROWKEYS.length, countRows()); // seems like the \"bigger\" region won.\n\n // fix the degenerate region.\n doFsck(conf,true);\n\n // check that the degenerate region is gone and no data loss\n HBaseFsck hbck2 = doFsck(conf,false);\n assertNoErrors(hbck2);\n assertEquals(0, hbck2.getOverlapGroups(table).size());\n assertEquals(ROWKEYS.length, countRows());\n } finally {\n cleanupTable(table);\n }\n }", "public void toggleRegion(){\n\t\tif(getRegion() == regionNormal)\n\t\t\tsetRegion(regionDown);\n\t\t\n\t\telse if(getRegion() == regionDown)\n\t\t\tsetRegion(regionNormal);\t\t\n\t}", "private void cleanWorldsAndRegions() {\n Set<PermissionRegion> usedRegions = new HashSet<>();\n Set<PermissionWorld> usedWorlds = new HashSet<>();\n\n List<PermissionEntity> entities = new ArrayList<>();\n entities.addAll(getGroups().values());\n entities.addAll(getPlayers().values());\n\n for (PermissionEntity entity : entities) {\n for (Entry entry : entity.getPermissions()) {\n if (entry.getRegion() != null)\n usedRegions.add(entry.getRegion());\n if (entry.getWorld() != null)\n usedWorlds.add(entry.getWorld());\n }\n }\n\n // Determine what needs to be deleted\n Set<PermissionRegion> regionsToDelete = new HashSet<>(getRegions().values());\n regionsToDelete.removeAll(usedRegions);\n Set<PermissionWorld> worldsToDelete = new HashSet<>(getWorlds().values());\n worldsToDelete.removeAll(usedWorlds);\n\n // Re-build lists\n getRegions().clear();\n for (PermissionRegion region : usedRegions) {\n getRegions().put(region.getName(), region);\n }\n getWorlds().clear();\n for (PermissionWorld world : usedWorlds) {\n getWorlds().put(world.getName(), world);\n }\n\n // Tell underlying DAO about deleted regions/worlds\n if (!regionsToDelete.isEmpty())\n deleteRegions(regionsToDelete);\n if (!worldsToDelete.isEmpty())\n deleteWorlds(worldsToDelete);\n }", "@Override\n public void undo() {\n node.toggleBoundaryMarker();\n }", "public void mouseExited(MouseEvent e) {\n if (e.getSource() instanceof MapBean) {\n // erase the old line first\n paintRubberband(rPoint1, rPoint2);\n // set the second point to null so that a new line will be\n // re-drawn if the mouse comes back, and the line will use\n // the old starting point.\n rPoint2 = null;\n }\n }", "public void removeRedundancies()\n\t{\n\t\tfinal List<FeatureElement> newFeatureElements = new ArrayList<FeatureElement>(featureElements.size());\n\t\t\n\t\tfor (final FeatureElement element : featureElements)\n\t\t{\n\t\t\tboolean shouldAdd = true;\n\t\t\t\n\t\t\tif (element instanceof AbsoluteFeatureElement)\n\t\t\t{\n\t\t\t\tfinal AbsoluteFeatureElement abs = (AbsoluteFeatureElement) element;\n\t\t\t\t\n\t\t\t\tfor (int i = 0; i < newFeatureElements.size(); ++i)\n\t\t\t\t{\n\t\t\t\t\tfinal FeatureElement alreadyAdded = newFeatureElements.get(i);\n\t\t\t\t\t\n\t\t\t\t\tif (alreadyAdded instanceof AbsoluteFeatureElement)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal AbsoluteFeatureElement other = (AbsoluteFeatureElement) alreadyAdded;\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (abs.position() == other.position())\t// same positions\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (abs.equals(other))\t// already have this one, no need to add\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tshouldAdd = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse if (abs.generalises(other))\t// have something more specific, so no need to add\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tshouldAdd = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse if (other.generalises(abs))\t// have something more general, so we should replace that\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tnewFeatureElements.set(i, abs);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t// just already added by replacement, so no need to add again\n\t\t\t\t\t\t\t\tshouldAdd = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tfinal RelativeFeatureElement rel = (RelativeFeatureElement) element;\n\t\t\t\t\n\t\t\t\tfor (int i = 0; i < newFeatureElements.size(); ++i)\n\t\t\t\t{\n\t\t\t\t\tfinal FeatureElement alreadyAdded = newFeatureElements.get(i);\n\t\t\t\t\t\n\t\t\t\t\tif (alreadyAdded instanceof RelativeFeatureElement)\n\t\t\t\t\t{\n\t\t\t\t\t\tfinal RelativeFeatureElement other = (RelativeFeatureElement) alreadyAdded;\n\t\t\t\t\t\t\n\t\t\t\t\t\tif (rel.walk().equals(other.walk()))\t// equal walks\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif (rel.equals(other))\t// already have this one, no need to add\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tshouldAdd = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse if (rel.generalises(other))\t// have something more specific, so no need to add\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tshouldAdd = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse if (other.generalises(rel))\t// have something more general, so we should replace that\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tnewFeatureElements.set(i, rel);\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t// just already added by replacement, so no need to add again\n\t\t\t\t\t\t\t\tshouldAdd = false;\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif (shouldAdd)\n\t\t\t{\n\t\t\t\tnewFeatureElements.add(element);\n\t\t\t}\n\t\t}\n\t\t\n\t\tfeatureElements = newFeatureElements;\n\t}", "public void setRegionid(int newRegionid) {\n regionid = newRegionid;\n }", "void addRegion(Region region);", "void removeExistingGlue() {\r\n\t\tfor (int i = outputStream.size() - 1; i >= 0; i--) {\r\n\t\t\tRTObject c = outputStream.get(i);\r\n\t\t\tif (c instanceof Glue) {\r\n\t\t\t\toutputStream.remove(i);\r\n\t\t\t} else if (c instanceof ControlCommand) { // e.g.\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t// BeginString\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\toutputStreamDirty();\r\n\t}", "public static Region newModifiedRegion(Region region, int changedStart, int changedEnd) {\n return new Region(region.chr, changedStart, changedEnd, region.gene, region.insertStart, region.insertEnd);\n }", "public void addSelectionToNewBlockingRegion() {\r\n \t\tObject[] cells = graph.getSelectionCells();\r\n \t\t// Data structure to hold all selected stations and their search's key\r\n \t\tHashMap<Object, Object> stations = new HashMap<Object, Object>();\r\n \t\tboolean canBeAdded = true;\r\n \t\tObject regionKey = model.addBlockingRegion();\r\n \t\tfor (Object cell : cells) {\r\n \t\t\tif (cell instanceof JmtCell) {\r\n \t\t\t\tObject stationKey = ((CellComponent) ((JmtCell) cell).getUserObject()).getKey();\r\n \t\t\t\tif (!model.canRegionStationBeAdded(regionKey, stationKey)) {\r\n \t\t\t\t\tcanBeAdded = false;\r\n \t\t\t\t\tbreak;\r\n \t\t\t\t} else {\r\n \t\t\t\t\tstations.put(cell, stationKey);\r\n \t\t\t\t}\r\n \t\t\t} else if (cell instanceof BlockingRegion) {\r\n \t\t\t\t// A blocking region cannot overlap another one\r\n \t\t\t\tcanBeAdded = false;\r\n \t\t\t\tbreak;\r\n \t\t\t}\r\n \t\t}\r\n \t\t// If blocking region can be added, adds it to graph window, otherwise\r\n \t\t// deletes it\r\n \t\tif (canBeAdded && stations.size() > 0) {\r\n \t\t\tBlockingRegion bl = new BlockingRegion(this, regionKey);\r\n \t\t\tObject[] stationCells = stations.keySet().toArray();\r\n \t\t\tbl.addStations(stationCells);\r\n \t\t\t// Adds stations to blocking region into data structure\r\n \t\t\tfor (Object stationCell : stationCells) {\r\n \t\t\t\tmodel.addRegionStation(regionKey, stations.get(stationCell));\r\n \t\t\t}\r\n \t\t} else {\r\n \t\t\tmodel.deleteBlockingRegion(regionKey);\r\n \t\t}\r\n \t}", "void removeIsBoundaryNodeOf(Boundary oldIsBoundaryNodeOf);", "public void updateWorldRegion()\n\t{\n\t\tif(!isVisible)\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tL2WorldRegion newRegion = WorldManager.getInstance().getRegion(getWorldPosition());\n\t\tL2WorldRegion oldRegion = region;\n\t\tif(!newRegion.equals(oldRegion))\n\t\t{\n\t\t\tif(oldRegion != null)\n\t\t\t{\n\t\t\t\toldRegion.removeVisibleObject(object);\n\t\t\t}\n\n\t\t\tsetWorldRegion(newRegion);\n\n\t\t\t// Add the L2Object spawn to _visibleObjects and if necessary to all players of its L2WorldRegion\n\t\t\tnewRegion.addVisibleObject(object);\n\t\t}\n\t}", "void removeHasLatitude(Object oldHasLatitude);", "void clearShapeMap();", "private void update() {\n int curRegionX = client.getRegionBaseX();\n int curRegionY = client.getRegionBaseY();\n if(lastRegionX != curRegionX || lastRegionY != curRegionY) {\n //Search for Altars:\n altars.clear();\n Landscape.accept(new LandscapeVisitor() {\n @Override\n public void acceptObject(RSEntityMarker marker) {\n int id = UID.getEntityID(marker.getUid());\n RSObjectDefinition def = client.getObjectDef(id);\n if(def == null || def.getName() == null) return;\n if(def.getName().equals(\"Altar\")) {\n altars.add(marker);\n }\n }\n });\n }\n }", "void removeSameAs(Object oldSameAs);", "void restoreBefore() {\r\n\t\t\tsurface.basemap.clear();\r\n\t\t\tsurface.basemap.putAll(basemapBefore);\r\n\t\t\tsurface.buildingmap.clear();\r\n\t\t\tsurface.buildingmap.putAll(buildingmapBefore);\r\n\t\t\tsurface.features.clear();\r\n\t\t\tsurface.features.addAll(surfaceBefore);\r\n\t\t\tsurface.buildings.clear();\r\n\t\t\tsurface.buildings.addAll(buildingsBefore);\r\n\t\t}", "static void wipeLocations(){\n\t \tfor (int i= 0; i < places.length; i++){\n\t\t\t\tfor (int j = 0; j < places[i].items.size(); j++)\n\t\t\t\t\tplaces[i].items.clear();\n\t\t\t\tfor (int k = 0; k < places[i].receptacle.size(); k++)\n\t\t\t\t\tplaces[i].receptacle.clear();\n\t \t}\n\t \tContainer.emptyContainer();\n\t }", "@Override\r\n public boolean equals(Object object) {\n if (!(object instanceof CamRegion)) {\r\n return false;\r\n }\r\n CamRegion other = (CamRegion) object;\r\n if ((this.vertex == null && other.vertex != null) || (this.vertex != null && !this.vertex.equals(other.vertex))) {\r\n return false;\r\n }\r\n return true;\r\n }", "private void DeleteBurnInsOnPreviousSamples() {\n\t\tif (gibbs_sample_num <= num_gibbs_burn_in + 1 && gibbs_sample_num >= 2){\n\t\t\tgibbs_samples_of_bart_trees[gibbs_sample_num - 2] = null;\n\t\t}\n\t}", "public void setRegionname(java.lang.String newRegionname) {\n\tregionname = newRegionname;\n}", "void removeContains(WrappedIndividual oldContains);", "public void dissociateShape() {\n\t\tif(currentShape != null && (groupedShapes.contains(currentShape))) {\n\t\t\tgroupedShapes.remove(currentShape);\n\t\t\tnotifyObservers();\n\t\t}\n\t}", "void restoreAfter() {\r\n\t\t\tsurface.basemap.clear();\r\n\t\t\tsurface.basemap.putAll(basemapAfter);\r\n\t\t\tsurface.buildingmap.clear();\r\n\t\t\tsurface.buildingmap.putAll(buildingmapAfter);\r\n\t\t\tsurface.features.clear();\r\n\t\t\tsurface.features.addAll(surfaceAfter);\r\n\t\t\tsurface.buildings.clear();\r\n\t\t\tsurface.buildings.addAll(buildingsAfter);\r\n\t\t}", "public void purgeQueue() {\r\n\t\tfDirtyRegions.clear();\r\n\t}", "public ProtectedCuboidRegion saveRegion() {\n\t\t\n\t\tcom.sk89q.worldedit.BlockVector pos1 = \n\t\t\t\tnew com.sk89q.worldedit.BlockVector(position1.getBlockX(), position1.getBlockY(), position1.getBlockZ());\n\t\tcom.sk89q.worldedit.BlockVector pos2 =\n\t\t\t\tnew com.sk89q.worldedit.BlockVector(position2.getBlockX(), position2.getBlockY(), position2.getBlockZ());\n\t\t\n\t\tplayer.sendMessage(\"\" + name + position1.toString() + position2.toString());\n\t\t\n\t\tProtectedCuboidRegion newPlotRegion = new ProtectedCuboidRegion(name, pos1, pos2);\n\t\t\n\t\tRegionManager regionManager = Mcc.worldGuard.getRegionManager(player.getWorld());\n\t\tregionManager.addRegion(newPlotRegion);\n\t\tnewPlotRegion = (ProtectedCuboidRegion) regionManager.getRegion(name);\n\t\t\n\t\tnewPlotRegion.setPriority(2);\n\t\ttry {\n\t\t\tregionManager.save();\n\t\t} catch (ProtectionDatabaseException e) {\n\t\t\tplayer.sendMessage(ChatColor.RED + \"Critical World Guard error! Notify Funonly\");\n\t\t}\n\t\t\n\t\treturn newPlotRegion;\n\t}", "@Override\r\n public void onRegionClickSelected(ProteinRegionSelectionEvent event) {\r\n StateChanger changer = new StateChanger();\r\n List<Region> region = new ArrayList<>();\r\n List<PeptideMatch> peptides;\r\n List<String> modifications;\r\n\r\n try {\r\n region.add(new Region(event.getStart(), event.getStart() + event\r\n .getLength() - 1));\r\n changer.addRegionChange(region);\r\n\r\n peptides = PeptideUtils.filterPeptideMatchesNotIn(peptideMatchSelection,\r\n event.getStart(), event.getStart() + event.getLength() - 1);\r\n\r\n if(peptides.size() != peptideMatchSelection.size()) {\r\n changer.addPeptideChange(peptides);\r\n }\r\n\r\n modifications = filterModificationsNotIn(currentModifications,\r\n event.getStart(), event.getStart() + event.getLength() - 1);\r\n\r\n if (modifications.size() != currentModifications.size()) {\r\n changer.addModificationChange(modifications);\r\n }\r\n\r\n UserAction action = new UserAction(UserAction.Type.region,\r\n \"Click Set\");\r\n StateChangingActionEvent.fire(this, changer, action);\r\n } catch (IllegalRegionValueException e) {\r\n // This is probably because of an empty selection,\r\n // we don't send any event\r\n }\r\n }", "private void removeNoMoreExistingOriginalEdges() {\n for (MirrorEdge mirrorEdge : directEdgeMap.values()) {\n if (!originalGraph.has(mirrorEdge.original)) {\n for (Edge segment : mirrorEdge.segments) {\n mirrorGraph.forcedRemove(segment);\n reverseEdgeMap.remove(segment);\n }\n for (Node bend : mirrorEdge.bends) {\n mirrorGraph.forcedRemove(bend);\n reverseEdgeMap.remove(bend);\n }\n directEdgeMap.remove(mirrorEdge.original);\n }\n }\n }", "public void removeDuplicates()\n\t{\n\t\tComparator<Point> comp = new Comparator<Point>() \n\t\t{\n @Override\n public int compare(Point p, Point q) \n {\n \t return p.compareTo(q);\n }\n };\n\t\tquicksorter.quickSort(comp);\n\t\tquicksorter.getSortedPoints(points);\n\t\t\n\t\tArrayList<Point> pts = new ArrayList<Point>();\n\t\tfor(int a = 0; a < points.length; a++) //copy points into temp array\n\t\t{\n\t\t\tif(!pts.contains(points[a]))\n\t\t\t{\n\t\t\t\tpts.add(points[a]);\n\t\t\t}\n\t\t}\n\t\tpointsNoDuplicate = new Point[pts.size()]; //insert into pointsNoDuplicate\n\t\tfor(int i = 0; i < pts.size(); i++)\n\t\t{\n\t\t\tpointsNoDuplicate[i] = pts.get(i);\n\t\t}\n\t}", "@Override\n protected Rectangle getSelectedRegion()\n {\n // Go through all widgets and union their bounds.\n Iterator<FrameEltSelnFig<?>> selectedFigs =\n selection.getSelectedFigures();\n\n return computeUnion(selectedFigs);\n }", "public void removeAllInterpretedBy() {\r\n\t\tBase.removeAll(this.model, this.getResource(), INTERPRETEDBY);\r\n\t}", "protected void deselectAllCurves() {\n\t\tfor (int i = 0; i < selectedCurves.size(); ++i) {\n\t\t\tcurves.add(selectedCurves.get(i));\n\t\t}\n\n\t\tselectedCurves.clear();\n\t}", "private List<Region> experimentFullRegions() {\n\t\tList<Region> rs = new ArrayList<Region>();\n\t\tRegion r;\n\n\t\t// Vassar St\n\t\tr = new Region(\"Vassar-1\");\n\t\tr.addVertex(42.36255147026933, -71.09034599930573);\n\t\tr.addVertex(42.36240877523236, -71.08975591332245);\n\t\tr.addVertex(42.36013353836458, -71.09434785515595);\n\t\tr.addVertex(42.360442721730834, -71.0948091951065);\n\t\trs.add(r);\n\n\t\t// Windsor-1\n\t\tr = new Region(\"Windsor-1\");\n\t\tr.addVertex(42.36302711805193, -71.09707297951508);\n\t\tr.addVertex(42.36297955343571, -71.09641852051544);\n\t\tr.addVertex(42.3615288153431, -71.09657945305634);\n\t\tr.addVertex(42.36186970216797, -71.09723391205597);\n\t\trs.add(r);\n\n\t\t// Mass-1\n\t\tr = new Region(\"Mass-1\");\n\t\tr.addVertex(42.362678310030105, -71.0995620694809);\n\t\tr.addVertex(42.3629954083118, -71.09918656021881);\n\t\tr.addVertex(42.36179042632724, -71.09720172554779);\n\t\tr.addVertex(42.361322696830854, -71.09736265808868);\n\t\trs.add(r);\n\n\t\t// Mass-2\n\t\tr = new Region(\"Mass-2\");\n\t\tr.addVertex(42.36114036066024, -71.09588207871246);\n\t\tr.addVertex(42.360791542163774, -71.09660091072845);\n\t\tr.addVertex(42.36106901157985, -71.0969335046463);\n\t\tr.addVertex(42.36156052582344, -71.09657945305634);\n\t\trs.add(r);\n\n\t\t// Mass-3\n\t\tr = new Region(\"Mass-3\");\n\t\tr.addVertex(42.36035551632001, -71.09489502579498);\n\t\tr.addVertex(42.3601731773427, -71.09523834854889);\n\t\tr.addVertex(42.360577493491306, -71.095978638237);\n\t\tr.addVertex(42.36077568673155, -71.0955816713028);\n\t\trs.add(r);\n\n\t\t/*\n\t\t * Albany-1-full r = new Region(\"Albany-1\");\n\t\t * r.addVertex(42.36087874696942, -71.09530272156525);\n\t\t * r.addVertex(42.361227564981775, -71.0956353154831);\n\t\t * r.addVertex(42.362678310030105, -71.092556139534);\n\t\t * r.addVertex(42.362527687785665, -71.09185876519012); rs.add(r);\n\t\t */\n\n\t\t// Albany-1\n\t\tr = new Region(\"Albany-1\");\n\t\tr.addVertex(42.36172700558263, -71.09442295700836);\n\t\tr.addVertex(42.3614891772202, -71.09410109192658);\n\t\tr.addVertex(42.360823253016186, -71.09553875595856);\n\t\tr.addVertex(42.361084866938036, -71.09590353638458);\n\t\trs.add(r);\n\n\t\t// Albany-2\n\t\tr = new Region(\"Albany-2\");\n\t\tr.addVertex(42.362678310030105, -71.09243812233734);\n\t\tr.addVertex(42.36253561528121, -71.09191240937042);\n\t\tr.addVertex(42.36180628150339, -71.09342517525482);\n\t\tr.addVertex(42.36223436974708, -71.09344663292694);\n\t\trs.add(r);\n\n\t\t// Portland-1\n\t\tr = new Region(\"Portland-1\");\n\t\tr.addVertex(42.362757584750575, -71.09386505753326);\n\t\tr.addVertex(42.36273380234492, -71.09342517525482);\n\t\tr.addVertex(42.36217887699113, -71.09354319245148);\n\t\tr.addVertex(42.36198861574153, -71.09409036309052);\n\t\trs.add(r);\n\n\t\t// Main-2\n\t\tr = new Region(\"Main-1\");\n\t\tr.addVertex(42.36321737615673, -71.09918656021881);\n\t\tr.addVertex(42.36356618118581, -71.09917583138275);\n\t\tr.addVertex(42.36342348845344, -71.0969335046463);\n\t\tr.addVertex(42.363042972916034, -71.09699787766266);\n\t\trs.add(r);\n\n\t\t// Main-2\n\t\tr = new Region(\"Main-2\");\n\t\tr.addVertex(42.36318566651262, -71.09384359986115);\n\t\tr.addVertex(42.36278929461076, -71.09392943054962);\n\t\tr.addVertex(42.36297162599619, -71.09643997818756);\n\t\tr.addVertex(42.36336799674776, -71.09641852051544);\n\t\trs.add(r);\n\n\t\t// Main-3\n\t\tr = new Region(\"Main-3\");\n\t\tr.addVertex(42.36300333574834, -71.09216990143585);\n\t\tr.addVertex(42.36271794740286, -71.09249176651764);\n\t\tr.addVertex(42.36277343968266, -71.09333934456635);\n\t\tr.addVertex(42.363106392332284, -71.09324278504181);\n\t\trs.add(r);\n\n\t\t// Main-4\n\t\tr = new Region(\"Main-4\");\n\t\tr.addVertex(42.36289235154579, -71.09035672814178);\n\t\tr.addVertex(42.36259110772208, -71.09038891464996);\n\t\tr.addVertex(42.36264660011392, -71.09166564614105);\n\t\tr.addVertex(42.36303504548448, -71.09157981545258);\n\t\trs.add(r);\n\n\t\tLocation l;\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.36035940296916);\n\t\tl.setLongitude(-71.0944926738739);\n\t\tlog(String.format(\"Test point on Vassar is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.36081921192526);\n\t\tl.setLongitude(-71.09338760375977);\n\t\tlog(String.format(\"Test point on Vassar is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.36160405047349);\n\t\tl.setLongitude(-71.0919177532196);\n\t\tlog(String.format(\"Test point on Vassar is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.3619370093201);\n\t\tl.setLongitude(-71.09123110771179);\n\t\tlog(String.format(\"Test point on Vassar is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.36234924163794);\n\t\tl.setLongitude(-71.09039425849915);\n\t\tlog(String.format(\"Test point on Vassar is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.3631736981596);\n\t\tl.setLongitude(-71.09626293182373);\n\t\tlog(String.format(\"Test point on Main-1 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.36303893196785);\n\t\tl.setLongitude(-71.09436392784119);\n\t\tlog(String.format(\"Test point on Main-1 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.362935875273244);\n\t\tl.setLongitude(-71.09288334846497);\n\t\tlog(String.format(\"Test point on Main-2 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.362785253646265);\n\t\tl.setLongitude(-71.09100580215454);\n\t\tlog(String.format(\"Test point on Main-3 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.362476081807);\n\t\tl.setLongitude(-71.0936987400055);\n\t\tlog(String.format(\"Test point on Portland-1 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.36099362133876);\n\t\tl.setLongitude(-71.09561920166016);\n\t\tlog(String.format(\"Test point on Albany-1 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.36154855716084);\n\t\tl.setLongitude(-71.0943853855133);\n\t\tlog(String.format(\"Test point on Albany-1 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.362008357414815);\n\t\tl.setLongitude(-71.093430519104);\n\t\tlog(String.format(\"Test point on Albany-2 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.362610849206014);\n\t\tl.setLongitude(-71.09221816062927);\n\t\tlog(String.format(\"Test point on Albany-2 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.3611521749309);\n\t\tl.setLongitude(-71.09653115272522);\n\t\tlog(String.format(\"Test point on Mass-1 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.3604862471552);\n\t\tl.setLongitude(-71.09537243843079);\n\t\tlog(String.format(\"Test point on Mass-2 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.36238887921827);\n\t\tl.setLongitude(-71.09683156013489);\n\t\tlog(String.format(\"Test point on Windsor-1 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\treturn rs;\n\t}", "public ChameleonDirtyRegion removeNextDirtyRegion() {\r\n\t\tif (fDirtyRegions.size() == 0)\r\n\t\t\treturn null;\r\n\t\tChameleonDirtyRegion dr= fDirtyRegions.get(0);\r\n\t\tfDirtyRegions.remove(0);\r\n\t\treturn dr;\r\n\t}", "@Override\n protected void updateEliminations() {\n\n }", "@Override\r\n void removeStarMap(StarMapComponent starMap) {\n\r\n }", "@Override\r\n\tpublic void undo() {\n\t\tfor(IShape shape : tempList)\r\n\t\t\tshapeList.remove(shape);\r\n\t}", "private List<Region> experimentSuperDenseRegions() {\n\t\tList<Region> rs = new ArrayList<Region>();\n\t\tRegion r;\n\n\t\t// Region 1\n\t\tr = new Region(\"Stata-1\");\n\t\tr.addVertex(42.36199654330529, -71.09211625725555);\n\t\tr.addVertex(42.362892351545966, -71.09046401650238);\n\t\tr.addVertex(42.362234369747256, -71.08898343712616);\n\t\tr.addVertex(42.36113243298882, -71.09136523873138);\n\t\trs.add(r);\n\n\t\tlog(\"Testing regions and getRegion logic...\");\n\t\tLocation l;\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.361921154176926);\n\t\tl.setLongitude(-71.09134912490845);\n\t\tlog(String.format(\"Test point Stata-1 is in region %s\",\n\t\t\t\tgetRegion(rs, l)));\n\n\t\treturn rs;\n\t}", "private List<Region> stataRegions() {\n\t\tList<Region> rs = new ArrayList<Region>();\n\t\tRegion r;\n\n\t\t// Region 1\n\t\tr = new Region(\"Stata-1\");\n\t\tr.addVertex(42.36218276352746, -71.08994364738464);\n\t\tr.addVertex(42.36207970542849, -71.08879566192627);\n\t\tr.addVertex(42.36181809564884, -71.08882784843445);\n\t\tr.addVertex(42.36184980598321, -71.08983635902405);\n\t\trs.add(r);\n\n\t\t// Region 2\n\t\tr = new Region(\"Stata-2\");\n\t\tr.addVertex(42.36184980598321, -71.08983635902405);\n\t\tr.addVertex(42.36181809564884, -71.08882784843445);\n\t\tr.addVertex(42.361556484779946, -71.08887076377869);\n\t\tr.addVertex(42.36158819524629, -71.08986854553223);\n\t\trs.add(r);\n\n\t\t// Region 3\n\t\tr = new Region(\"Stata-3\");\n\t\tr.addVertex(42.36158819524629, -71.08986854553223);\n\t\tr.addVertex(42.361556484779946, -71.08887076377869);\n\t\tr.addVertex(42.36131865577206, -71.08895659446716);\n\t\tr.addVertex(42.361366221645646, -71.08989000320435);\n\t\trs.add(r);\n\n\t\tlog(\"Testing regions and getRegion logic...\");\n\t\tLocation l;\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.36196871959442);\n\t\tl.setLongitude(-71.0893964767456);\n\t\tlog(String.format(\"Test point 1 is in region %s\", getRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.361659543737126);\n\t\tl.setLongitude(-71.0893964767456);\n\t\tlog(String.format(\"Test point 2 is in region %s\", getRegion(rs, l)));\n\n\t\tl = new Location(\"\");\n\t\tl.setLatitude(42.36140585984613);\n\t\tl.setLongitude(-71.0893964767456);\n\t\tlog(String.format(\"Test point 3 is in region %s\", getRegion(rs, l)));\n\n\t\treturn rs;\n\t}", "private void clearRegionSelection(final Nation nation) {\n view.getRegions().get(nation).getSelectionModel().clearSelection();\n }", "public void retract(){\n\t\tsolenoid1.set(false);\n\t\tsolenoid2.set(false);\n\t}", "@Override\n public void undo(){\n this.parent.getSelectedArea().clear();\n }", "public void startRegionGrowMode() {\n regionGrowMode = true;\n }", "public void doRemove() throws VisADException, RemoteException {\n rangeRings = null;\n super.doRemove();\n }", "public void adjustRegionsInRowsCols(int noOfRegions){\t\t\n\t\t\t\n\t\t\t\n\t\t\t/*if(noOfRegions==4){\n\t\t\t\trCols= rRows = 2;\n\t\t\t}\n\t\t\t\n\t\t\telse if(noOfRegions==6){\n\t\t\t\trCols = 3;\n\t\t\t\trRows = 2;\n\t\t\t}\n\t\t\t\n\t\t\telse if(noOfRegions==9){\n\t\t\t\trRows = 3;\n\t\t\t\trCols = 3;\n\t\t\t}\n\t\t\telse if(noOfRegions==12){\n\t\t\t\trRows = 4;\n\t\t\t\trCols = 3;\n\t\t\t}\n\t\t\telse if(noOfRegions==16){\n\t\t\t\trRows = 4;\n\t\t\t\trCols = 4;\n\t\t\t}*/\n\t\t logger.info(\"\"+(int)Math.sqrt(noOfRegions));\n\t\t\trRows = (int)Math.sqrt(noOfRegions);\n\t\t\trCols = rRows;\n\t\t\n\t\t \t\t\t\t\t\t\n\t\t\tfor(int i=0;i<noOfRegions-rCols;i++){\n\t\t\t\tarrUpRegions.add(i+1);\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\tfor(int i=rCols*(rRows-1);i<noOfRegions;i++){\n\t\t\t\tarrDownRegions.add(i+1);\n\t\t\t\t//logger.info(\"Down region=\" + (i+1));\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\tint count1 = 0;\n\t\t\tfor(int i=0;i<rCols*rRows;i++){\n\t\t\t\t\n\t\t\t\tif(++count1==rCols){\n\t\t\t\t\tcount1=0;\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t//logger.info(\"Left Region======\" + (i+1));\n\t\t\t\tarrLeftRegions.add(i+1);\n\t\t\t}\n\t\t\t\n\t\t\tfor(int i=rCols-1;i<noOfRegions;i=i+rCols){\n\t\t\t\tarrRightRegions.add(i+1);\n\t\t\t\t//logger.info(\"Right region=\" + (i+1));\n\t\t\t}\t\t\t\n\t\t\t\n\t}", "private void processUnprocessed()\n {\n List<Geometry> unprocAdds;\n myUnprocessedGeometryLock.lock();\n try\n {\n // Processing the unprocessed geometries may result in them being\n // added back to one of the unprocessed maps, so create a clean set\n // of maps for them to be added to.\n if (myUnprocessedAdds.isEmpty())\n {\n unprocAdds = null;\n }\n else\n {\n unprocAdds = myUnprocessedAdds;\n myUnprocessedAdds = New.list();\n }\n }\n finally\n {\n myUnprocessedGeometryLock.unlock();\n }\n\n if (unprocAdds != null)\n {\n distributeGeometries(unprocAdds, Collections.<Geometry>emptyList());\n }\n }", "public void refreshGeometry(){\n\t\tfor (int i = 0; i < getSegmentCount(); i++) {\n\t\t\tsegments.get(i).refreshGeometry();\n\t\t}\n\t}", "public final synchronized void clearGeometry() {\n synchronized (this) {\n this.f718B8WBXPBCF2jGfUDZZU2zV5EYdqbUBu0lAZ0THCEqYyuE8VACR9dY7rDnwBIqh64T = null;\n this.f719hxYOFxFjLpN1maJuWNxUV40nExCGxsxkDPOTgtzMu4zlZCQb3bPlKsXo1SYJg6ME = null;\n }\n }", "protected SourceInterestMap updateEntity(SourceInterestMap entity, SourceInterestMap newEntity) {\n EntityManager em = PersistenceService.getInstance().getEntityManager();\n InterestArea interestAreaId = entity.getInterestAreaId();\n InterestArea interestAreaIdNew = newEntity.getInterestAreaId();\n Source sourceId = entity.getSourceId();\n Source sourceIdNew = newEntity.getSourceId();\n entity = em.merge(newEntity);\n if (interestAreaId != null && !interestAreaId.equals(interestAreaIdNew)) {\n interestAreaId.getSourceInterestMapCollection().remove(entity);\n }\n if (interestAreaIdNew != null && !interestAreaIdNew.equals(interestAreaId)) {\n interestAreaIdNew.getSourceInterestMapCollection().add(entity);\n }\n if (sourceId != null && !sourceId.equals(sourceIdNew)) {\n sourceId.getSourceInterestMapCollection().remove(entity);\n }\n if (sourceIdNew != null && !sourceIdNew.equals(sourceId)) {\n sourceIdNew.getSourceInterestMapCollection().add(entity);\n }\n return entity;\n }", "public RegionGroup(AreaShop plugin, String name) {\n\t\tthis.plugin = plugin;\n\t\tthis.name = name;\n\t\tsetSetting(\"name\", name);\n\t\t// Delete duplicates\n\t\tList<String> members = getMembers();\n\t\tint previousCount = members.size();\n\t\tList<String> newMembers = new ArrayList<>();\n\t\twhile(!members.isEmpty()) {\n\t\t\tString member = members.remove(0);\n\t\t\t// If the region has been deleted also clean it from the group\n\t\t\tif(plugin.getFileManager().getRegion(member) != null) {\n\t\t\t\tnewMembers.add(member);\n\t\t\t}\n\t\t\twhile(members.contains(member)) {\n\t\t\t\tmembers.remove(member);\n\t\t\t}\n\t\t}\n\t\tif(newMembers.size() != previousCount) {\n\t\t\tsetSetting(\"regions\", newMembers);\n\t\t\tAreaShop.debug(\"group save required because of changed member size\", newMembers);\n\t\t\tsaveRequired();\n\t\t}\n\t}", "private void handleStepChange()\n {\n boolean processorsChanged = false;\n myProcessorsLock.writeLock().lock();\n try\n {\n final Iterator<Entry<ProcessorDistributionKey, GeometryProcessor<? extends Geometry>>> procIter = myGeometryProcessorsMap\n .entrySet().iterator();\n final ActiveTimeSpans activeTimeSpans = myActiveTimeSpans;\n while (procIter.hasNext())\n {\n final Entry<ProcessorDistributionKey, GeometryProcessor<? extends Geometry>> entry = procIter.next();\n if (!inProcessRange(entry.getKey(), activeTimeSpans))\n {\n processorsChanged = true;\n procIter.remove();\n myInactiveGeometries.put(entry.getKey(), New.set(entry.getValue().getGeometries()));\n entry.getValue().close();\n }\n }\n\n final Iterator<Entry<ProcessorDistributionKey, Set<Geometry>>> inactiveIter = myInactiveGeometries.entrySet()\n .iterator();\n while (inactiveIter.hasNext())\n {\n final Entry<ProcessorDistributionKey, Set<Geometry>> entry = inactiveIter.next();\n if (inProcessRange(entry.getKey(), activeTimeSpans) && !entry.getValue().isEmpty())\n {\n processorsChanged = true;\n inactiveIter.remove();\n setProcessorConstraints(entry.getKey());\n final GeometryProcessor<? extends Geometry> processor = myProcessorBuilder\n .createProcessorForClass(entry.getKey().getGeometryType());\n processor.receiveObjects(this, entry.getValue(), Collections.<Geometry>emptyList());\n myGeometryProcessorsMap.put(entry.getKey(), processor);\n }\n }\n }\n finally\n {\n myProcessorsLock.writeLock().unlock();\n }\n\n if (processorsChanged)\n {\n populateRenderableProcessors();\n }\n }", "void removeIsVertexOf(Subdomain_group oldIsVertexOf);", "public void removeAllOverlayObj()\n/* 91: */ {\n/* 92:146 */ this.mapPanel.removeAllOverlayObj();\n/* 93: */ }", "void removeHasXCoordinate(Object oldHasXCoordinate);", "Region region();", "Region region();", "Region region();", "Region region();", "public void removeRepresentations()\r\n\t{\n\t}", "private void paintDirtyRectanglesImmediately() {\n if ( rectangles.size() > 0 ) {\n Rectangle unionRectangle = RectangleUtils.union( rectangles );\n this.repaintArea = transformManager.transform( unionRectangle );\n paintImmediately( repaintArea );\n rectangles.clear();\n }\n }", "private void cleanup() {\n\t\tTreeSet<CacheEntry> entries = new TreeSet<CacheEntry>(map.values());\n\t\tint i = region.getItemsToEvict();\n\t\tIterator<CacheEntry> it = entries.iterator();\n\t\twhile (it.hasNext() && i > 0) {\n\t\t\tremoveEntry(it.next());\n\t\t\ti--;\n\t\t}\n\t}", "public synchronized void removeForServer(ServerName serverName) {\n for (Map.Entry<byte[], RegionLocations> entry : cache.entrySet()) {\n byte[] regionName = entry.getKey();\n RegionLocations locs = entry.getValue();\n RegionLocations newLocs = locs.removeByServer(serverName);\n if (locs == newLocs) {\n continue;\n }\n if (newLocs.isEmpty()) {\n cache.remove(regionName, locs);\n } else {\n cache.put(regionName, newLocs);\n }\n }\n }", "static void deleteLastRectangle(){\n System.out.println(coloredRectangles.size());\n coloredRectangles.remove(coloredRectangles.size() - 1);\n //revalidate();\n }", "public void removeOverlay() {\n MimsPlus[] openImages = ui.getAllOpenImages();\n for (MimsPlus image : openImages) {\n for (Roi roi : rois) {\n Overlay overlay = image.getGraphOverlay();\n int index = overlay.getIndex(roi.getName() + graphID);\n if (index > -1) {\n overlay.remove(index);\n }\n image.setOverlay(overlay);\n }\n }\n }", "private void removeNoMoreExistingOriginalNodes() {\n for (Node mirrorNode : mirrorGraph.nodes()) {\n if (!isPartOfMirrorEdge(mirrorNode) && !originalGraph.has(mirrorNode)) {\n mirrorGraph.remove(mirrorNode);\n }\n }\n }", "private void undoLastPoint() {\n \t\tif ( this.markers.isEmpty() ) {\n \t\t\treturn;\n \t\t}\n \n \t\tthis.markers.remove( this.markers.size() - 1 ).remove();\n \t\tthis.commitPolygon();\n \n \t\tif ( this.markers.size() > 1 ) {\n \t\t\tthis.moveCameraToPolygon( true );\n \t\t}\n \n \t\tthis.disableIfDissatisfied();\n \t}", "public void freeGeometries(){\n\t\tfinal int size = this.geometries.size();\n\t\tfor(int index=0; index < size; index++){\n\t\t\tfinal int key = this.geometries.keyAt(index);\n\t\t\tthis.geometries.get(key).free();\n\t\t\tthis.geometries.delete(key);\n\t\t}\n\t}", "public void clearAreaReset() {\n for(int x = 0; x < buildSize; x++) {\n for(int y = 4; y < 7; y++) {\n for(int z = 0; z < buildSize; z++) {\n myIal.removeBlock(x, y, z);\n }\n }\n }\n\n myIal.locx = 0; myIal.locy = 0; myIal.locz = 0;\n my2Ial.locx = 0; my2Ial.locy = 0; my2Ial.locz = 0;\n }", "@Test\r\n public void testClosure() {\r\n // Remove node\r\n backend.toggleIntersection(\"Observatory & Babcock\");\r\n map = backend.getMap(); // Update map to newly created map\r\n if(map.getVertexCount() != intersections.size()-1)\r\n fail(\"Failed to remove intersection\");\r\n // Reinsert node\r\n backend.toggleIntersection(\"Observatory & Babcock\");\r\n map = backend.getMap(); // Update map to newly created map\r\n if(map.getVertexCount() != intersections.size())\r\n fail(\"Failed to reinsert intersection\");\r\n // Remove multiple nodes\r\n backend.toggleIntersection(\"Mills & University\");\r\n backend.toggleIntersection(\"Johnson & Randall\");\r\n map = backend.getMap(); // Update map to newly created map\r\n if(map.getVertexCount() != intersections.size()-2)\r\n fail(\"Failed to remove intersection\");\r\n }", "HRegion removeFromOnlineRegions(HRegionInfo hri) {\n this.lock.writeLock().lock();\n HRegion toReturn = null;\n try {\n toReturn = onlineRegions.remove(Bytes.mapKey(hri.getRegionName()));\n } finally {\n this.lock.writeLock().unlock();\n }\n return toReturn;\n }", "public void removePlaces(){\n List<Place> copies = new ArrayList<>(places);\n for(Place p : copies){\n p.reset();\n }\n }", "private void removeMine(int i, int j) {\n current[i][j] = new Empty();\n for (int k = -1; k <= 1; k++) {\n for (int l = -1; l <= 1; l++) {\n //pas de omliggende vlaggetjes aan\n if ((k != 0 || l != 0) && inField(i + k, j + l) && current[i + k][j + l].isBound()) {\n current[i + k][j + l].increment();\n }\n }\n }\n }", "@Override\n public void remove(Shape[] shapes) {\n\n }", "@Override\n public void reloadWorkspace() {\n\tDataManager data = (DataManager)app.getDataComponent();\n mapName.setText(data.getMapName());\n bgColorPicker.setValue(Color.web(data.getBackgroundColor()));\n borderColorPicker.setValue(Color.web(data.getBorderColor()));\n //map.setMinSize(data.getMapWidth(), data.getMapHeight());\n //map.setMaxSize(data.getMapWidth(), data.getMapHeight());\n map.setBackground(new Background(new BackgroundFill(Color.web(data.getBackgroundColor()), null, null)));\n \n //map.setBorder(new Border(new BorderStroke(Color.web(data.getBorderColor()), BorderStrokeStyle.SOLID, null, new BorderWidths(data.getBorderWidth()))));\n mapZoomingSlider.setValue(data.getX());\n borderThicknessSlider.setValue(data.getBorderWidth());\n \n for (int p = 0; p<data.getPolygon().size();p++){\n Polygon changePolygon = new Polygon();\n changePolygon = (Polygon) data.getPolygon().get(p);\n changePolygon.setStrokeWidth(data.getBorderWidth());\n changePolygon.setStroke(Color.web(data.getBorderColor()));\n changePolygon.setFill(Color.rgb(data.getSubRegion().get(p).getRed(), data.getSubRegion().get(p).getGreen(), data.getSubRegion().get(p).getBlue()));\n }\n \n imagePane.getChildren().clear();\n for(int i=0;i<data.getImageDetail().size();i++){\n newImage = new Image(\"file:\"+data.getImageDetail().get(i).getPath());\n ImageView iv1 = new ImageView();\n iv1.setImage(newImage);\n iv1.setTranslateX(data.getImageDetail().get(i).getX());\n iv1.setTranslateY(data.getImageDetail().get(i).getY());\n imagePane.getChildren().add(iv1);\n }\n \n group.getChildren().clear();\n for (int k = 0; k<data.getSubRegion().size();k++){\n Polygon polygon = (Polygon) data.getPolygon().get(k);\n group.getChildren().add(polygon);\n }\n subRegionTable.setItems(data.getSubRegion());\n //group.resize(802, 536);\n group.setScaleX(data.getMapZoom());\n group.setScaleY(data.getMapZoom());\n }", "public synchronized void regionOffline(final HRegionInfo hri) {\n String regionName = hri.getEncodedName();\n RegionState oldState = regionStates.get(regionName);\n if (oldState == null) {\n LOG.warn(\"Offline a region not in RegionStates: \" + hri);\n } else {\n State state = oldState.getState();\n ServerName sn = oldState.getServerName();\n if (state != State.OFFLINE || sn != null) {\n LOG.debug(\"Offline a region with current state=\" + state + \", expected state=OFFLINE\"\n + \", assigned to server: \" + sn + \", expected null\");\n }\n }\n updateRegionState(hri, State.OFFLINE);\n regionsInTransition.remove(regionName);\n\n ServerName oldServerName = regionAssignments.remove(hri);\n if (oldServerName != null) {\n LOG.info(\"Offlined region \" + hri + \" from \" + oldServerName);\n serverHoldings.get(oldServerName).remove(hri);\n }\n }", "void removeHasSCF(SCF oldHasSCF);", "@Override\n\tpublic void undo() throws PGenException {\n\n\t\tif ( parent != null ){\n\t\t\tif ( newElements != null ) {\n\t\t\t\tfor ( AbstractDrawableComponent ade : newElements ) {\n\t\t\t\t\tparent.removeElement( ade );\n\t\t\t\t}\t \t\n\t\t\t}\n\n\t\t\tif ( oldElements != null ) {\n\t\t\t\tparent.add( oldElements );\n\t\t\t}\n\t\t}\n\t\telse if ( oldElements.size() == newElements.size() ){\n\t\t\tfor ( int ii = 0; ii < newElements.size(); ii++ ) {\n\t\t\t\tAbstractDrawableComponent ade = newElements.get(ii);\n\t\t\t\tif ( ade.getParent() != null && ade.getParent() instanceof DECollection ){\n\t\t\t\t\tDECollection dec = (DECollection) ade.getParent();\n\t\t\t\t\tdec.removeElement( ade );\n\t\t\t\t\tdec.add( oldElements.get( ii ));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public void save() {\n RegionOwn.saveRegionOwner(this);\n }", "@Override\n public void redo(){\n this.parent.getSelectedArea().clear();\n \n //And add the point to the list again\n this.parent.getSelectedArea().add(this.selected);\n }", "public final void clearTexture() {\n finalSkeleton = null;\n\n\n// for (Slot slot:emptySkeleton.getSlots()){\n// PolygonRegionAttachment attach=((PolygonRegionAttachment)slot.getAttachment()).se\n// }\n// emptySkeleton = null;\n// PolygonRegionAttachmentLoader attachmentLoader = new PolygonRegionAttachmentLoader(this, phase, assetProvider.getTextureAtlas(SpineToolFullEditorOverlay.getSelectedSkeleton()));\n// emptySkeleton = createSkeleton(attachmentLoader);\n// finalize(emptySkeleton);\n }", "public void deselectAll()\n {\n map.deselectAll();\n mapComponent.repaint();\n mapper.resetMenus();\n }", "@Override\n public void updateSlots() {\n super.updateSlots();\n purgeAllOverflowEM_EM();\n }" ]
[ "0.62719613", "0.6026009", "0.5949832", "0.561415", "0.5595789", "0.5545753", "0.5478906", "0.54565245", "0.5445351", "0.5422233", "0.540234", "0.53997105", "0.5370877", "0.5365994", "0.5355961", "0.53426015", "0.53425616", "0.5337974", "0.5331463", "0.5286888", "0.52816105", "0.52354985", "0.52058285", "0.5178263", "0.5173611", "0.5153319", "0.51421505", "0.513371", "0.5101687", "0.50940484", "0.50820976", "0.5079899", "0.5078831", "0.50654376", "0.50614387", "0.5054315", "0.5048089", "0.5046088", "0.50374895", "0.5035896", "0.500158", "0.4988098", "0.49795184", "0.49789476", "0.49776226", "0.49718365", "0.49643585", "0.4952544", "0.4948303", "0.49296087", "0.4926439", "0.4908838", "0.4907309", "0.49053487", "0.48849177", "0.488431", "0.48818296", "0.48687485", "0.4856701", "0.48453805", "0.4845229", "0.48435923", "0.48270047", "0.48229653", "0.48100698", "0.48023498", "0.48010764", "0.47974023", "0.47973022", "0.4794242", "0.47941035", "0.47806573", "0.47782674", "0.47782674", "0.47782674", "0.47782674", "0.47761166", "0.47749716", "0.47683984", "0.47679275", "0.47626963", "0.4752308", "0.47517496", "0.47507024", "0.47412986", "0.4738178", "0.47349057", "0.47346923", "0.47275794", "0.4725199", "0.47232822", "0.47213328", "0.4717726", "0.4710306", "0.47020045", "0.46986657", "0.46920127", "0.46886662", "0.46783248", "0.4672334" ]
0.48153585
64
Get the type keys for the data types that can be queried.
public Collection<? extends String> getQueryableDataTypeKeys() { return MantleToolboxUtils.getMantleToolbox(myToolbox).getDataGroupController().getQueryableDataTypeKeys(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Class<?> getKeyType();", "public com.guidewire.datamodel.TypekeyDocument.Typekey[] getTypekeyArray()\r\n {\r\n synchronized (monitor())\r\n {\r\n check_orphaned();\r\n java.util.List targetList = new java.util.ArrayList();\r\n get_store().find_all_element_users(TYPEKEY$16, targetList);\r\n com.guidewire.datamodel.TypekeyDocument.Typekey[] result = new com.guidewire.datamodel.TypekeyDocument.Typekey[targetList.size()];\r\n targetList.toArray(result);\r\n return result;\r\n }\r\n }", "@Override\n public <T> Set<Key<T>> typedKeySet(final Class<T> clazz) {\n Set<Key<T>> keys = new HashSet<>();\n for (Key k : this.keySet()) {\n if (k.valueType.equals(clazz)) {\n keys.add(k);\n }\n }\n return keys;\n }", "public String getKeyType() \n {\n return DBFactory.getKeyTypeName(this.keyType);\n }", "public static synchronized Set<Class<?>> keySet() {\n\t\treturn ClassRegistry.dictionary.keySet();\n\t}", "synchronized public Map<String, Set<String>> getTypes() {\n return Collections.unmodifiableMap(\n new HashSet<>(types.entrySet()).stream()\n .collect(Collectors.toMap(\n Map.Entry::getKey,\n e -> Collections.unmodifiableSet(new HashSet<>(e.getValue()))\n ))\n );\n }", "public List<String> getDataPointTypes() {\n Object[] dpTypes = (Object[])configMap.get(DATA_POINT_TYPES);\n List<String> types = Utility.downcast( dpTypes );\n return types;\n }", "List<QueryKey> listQueryKeys();", "ArrayList<String> getAllDatatypeIds();", "public String[] getTypes() {\n/* 388 */ return getStringArray(\"type\");\n/* */ }", "static String[] getAllTypeNames()\n\t{\n\t\treturn new String[] {\"String\", \"int\", \"double\", \"long\", \"boolean\", \"String[]\", \"int[]\", \"double[]\", \"long[]\"};\n\t}", "public Hashtable getDataTypeDefinitions() {\n return ComponentHelper.getComponentHelper(this).getDataTypeDefinitions();\n }", "public String[] getKeyNames() \n {\n DBField f[] = this.getKeyFields();\n String kn[] = new String[f.length];\n for (int i = 0; i < f.length; i++) {\n kn[i] = f[i].getName();\n }\n return kn;\n }", "public String[] getNodeTypes()\r\n {\r\n\treturn ntMap.keySet().toArray(new String[ntMap.size()]);\r\n }", "public List<K> keys();", "public Set<String> getDataKeys() {\r\n\t\treturn data.keySet();\r\n\t}", "@Override\r\n\tpublic List<Type> getTypes() {\n\t\treturn (List<Type>)BaseDao.select(\"select * from type\", Type.class);\r\n\t}", "public final static ArrayList<BasicKeyedField> getRecordTypes() {\n \tArrayList<BasicKeyedField> ret = new ArrayList<BasicKeyedField>();\n \tBasicKeyedField fld;\n\n \tfor (int i = 0; i < names.length && ! \"\".equals(names[i]); i++) {\n \t\t\tfld = new BasicKeyedField();\n\t\t\tfld.key = keys[i];\n\t\t\tfld.name = names[i];\n\t\t\tret.add(fld);\n \t}\n\n \treturn ret;\n }", "public synchronized static Set<String> getAvailableTypes() {\n populateCache();\n return Collections.unmodifiableSet(cache.keySet());\n }", "public List<__Type> getTypes() {\n return (List<__Type>) get(\"types\");\n }", "@Override\r\n\t\tpublic Map<String, Class<?>> getTypeMap() throws SQLException {\n\t\t\treturn null;\r\n\t\t}", "public List<String> getAvailableDataTypes() {\n Set<String> typeSet = new TreeSet<String>();\n\n ITimer timer = TimeUtil.getTimer();\n timer.start();\n\n try {\n for (Provider provider : DataDeliveryHandlers.getProviderHandler()\n .getAll()) {\n\n for (ProviderType type : provider.getProviderType()) {\n typeSet.add(type.getDataType().toString());\n }\n }\n } catch (RegistryHandlerException e) {\n statusHandler.handle(Priority.PROBLEM,\n \"Unable to retrieve the provider list.\", e);\n }\n\n List<String> typeList = new ArrayList<String>(typeSet);\n timer.stop();\n\n return typeList;\n }", "public void logAllPossibleKeysWithType() {\n log.info(\"Log all possible keys with type:\");\n Map<String, Class> keysWithType = context.entrySet().stream()\n .collect(toMap(Entry::getKey, entry -> entry.getValue().getClass()));\n log.info(mapToString(keysWithType));\n }", "public Field[] getKeyFields();", "public java.lang.String getKeyType() {\n return keyType;\n }", "UsedTypes getTypes();", "private static AbstractType<?> keyType(CollectionType<?> type)\n {\n return type.nameComparator();\n }", "public interface TypeKey {\n}", "public Iterable<K> keys();", "public HashMap<String, Integer> getId_types() {\n return id_types;\n }", "public java.lang.String getKeyType() {\n return keyType;\n }", "public static String getKeyTypeName(KeyType type)\n {\n // TODO: should be moved to DBProvider ...\n // MySQL : key identifier\n // SQLServer : key identifier\n // Derby : key identifier\n // PostgreSQL: key identifier\n switch (type) {\n // MySQL: key types ...\n case PRIMARY : return \"PRIMARY KEY\"; // table\n case UNIQUE : return \"UNIQUE\"; // table\n case INDEX : return \"INDEX\"; // table/index\n case UNIQUE_INDEX : return \"UNIQUE INDEX\"; // table/index\n default : return \"UNKNOWN\";\n }\n }", "public Set getTypeSet()\n {\n Set set = new HashSet();\n\n Iterator it = attTypeList.keySet().iterator();\n while (it.hasNext())\n {\n // Get key\n Object attrName = it.next();\n Object type = attTypeList.get(attrName);\n set.add(type);\n }\n return set;\n }", "public Iterable<Key> keys();", "public Iterable<Key> keys();", "public static byte[] genAllTypes(){\n byte[] types = { DataType.BAG, DataType.BIGCHARARRAY, DataType.BOOLEAN, DataType.BYTE, DataType.BYTEARRAY,\n DataType.CHARARRAY, DataType.DOUBLE, DataType.FLOAT, DataType.DATETIME,\n DataType.GENERIC_WRITABLECOMPARABLE,\n DataType.INTEGER, DataType.INTERNALMAP,\n DataType.LONG, DataType.MAP, DataType.TUPLE, DataType.BIGINTEGER, DataType.BIGDECIMAL};\n return types;\n }", "@Override\n List<String> keys();", "public Type[] types();", "public List<String> getCrossWalkDataType() {\n\t\treturn stateEqualMasterDao.getElementValueList(\"CROSSWALK_DATA_TYPE\");\n\t}", "@Override\n\tpublic Map<String, Class<?>> getKeysMap(String entitySetName) {\n\t\treturn null;\n\t}", "public static Set<String> getMetricDataTypes() throws SQLException \n\t{\n\t\tSet<String> dataTypes = new HashSet<String>();\n\t\t\n\t\tConnection conn = DBConnector.getInstance().getConn();\n\t\t\n\t\tString sql = \"SELECT \\\"DataType\\\" FROM mhtc_sch.metrics\";\n\t\tPreparedStatement pstatement = conn.prepareStatement(sql);\n\t\tResultSet rs = pstatement.executeQuery();\n\n\t\twhile (rs.next()) {\n\t\t\tdataTypes.add(rs.getString(\"DataType\"));\n\t\t}\n\t\t\n\t\treturn dataTypes;\n\t}", "Set<String> getMetadataKeys();", "public Set<String> getClassKeys();", "public abstract Map<String, Integer> getColumnTypes(String tableName);", "public Set<String> getKeyList() throws IOException {\n if (dataCollector.getCollectorType().equals(DataCollector.COLLECTOR_TYPE_LIST)) {\n return dataCollector.getResult().getComparatorList().keySet();\n } else {\n throw new IOException(\"only allowed for \" + DataCollector.COLLECTOR_TYPE_LIST);\n }\n }", "@RequestMapping(value=\"/datatypes\",method=RequestMethod.GET)\n public DataFieldType[] getAllDataTypes(){\n return DataFieldType.values();\n }", "public List<String> getCrosswalkDataType() {\n\t\treturn stateEqualMasterDao.getElementValueList(\"CROSSWALK_DATA_TYPE\");\n\t}", "public Enumeration getKeys() {\n // Not yet implemented -sorta\n return m_sql_bundle.getKeys();\n }", "public String[] getKeyColumns()\n {\n return KEY_COLUMNS;\n }", "public Collection<DasType> getTypes() throws DataSourceException {\n Collection<DasType> types = new ArrayList<DasType>(5);\n types.add(new DasType(\"gene\", \"gene\", \"Gene description\"));\n types.add(new DasType(\"efv\", \"efv\", \"Experiment factor value\"));\n types.add(new DasType(\"exp\", \"exp\", \"Experiment\"));\n return types;\n }", "public String[] getTypes() {\n return impl.getTypes();\n }", "private Map<String, Integer> getUserTableTypeMetaData(Connection conn, String name) throws SQLException{\n\t\t\n\t\tMap<String, Integer> colNameType = new HashMap<String, Integer>();\n\t\tPreparedStatement preparedStatement = conn.prepareStatement(TestCDTAnyDB.USER_TABLE_TYPE_QUERY);\n\t\tpreparedStatement.setString(1, name);\n\t\tResultSet rs = preparedStatement.executeQuery();\n\n\t while (rs.next()) {\n\t String colName = rs.getString(\"name\");\n\t String colType = rs.getString(\"type\");\n\t if (TYPE_MAPPING.get(colType) == null ) {\n\t \tLOG.error(\"SQL Server type \" + colType + \" hasn't been mapped in JDBC types \");\n\t \t//throw new Exception(\"wsef\");\n\t }\n\t colNameType.put(colName, TYPE_MAPPING.get(colType));\n\t }\n\t \n\t return colNameType;\t \n\t}", "public List<SecTyp> getAllTypes();", "public List<KeyType> getPrimaryKeyCollection(String condition) {\r\n Session session = getSession();\r\n List<KeyType> lst = null;\r\n try {\r\n if (condition == null || \"null\".equals(condition)) {\r\n condition = \" \";\r\n }\r\n ClassMetadata cm = sessionFactory.getClassMetadata(getPersistentClass().getName());\r\n String type = cm.getIdentifierPropertyName();\r\n lst = session.createQuery(\"select t.\" + type + \" from \" + getPersistentClass().getName() + \" t\" + \" \" + condition).list();\r\n } catch (HibernateException e) {\r\n LOG.error(MODULE + \"Exception in getPrimaryKeyCollection Method:\" + e, e);\r\n } finally {\r\n// if (session.isOpen()) {\r\n// session.close();\r\n// }\r\n }\r\n return lst;\r\n }", "public Enumeration<Object> keys ();", "public List<TypeMetadata> getTypeMetadata() {\n return types;\n }", "private String[] buildTypeRegistrations(String[] baseKeys, boolean noSQLrecurse) {\n\t\tClassLoaderService cls = registry.getService(ClassLoaderService.class);\n\t\tArrayList<String> keys = new ArrayList<>( baseKeys.length << 1 );\n\t\tfor ( String bk : baseKeys ) {\n\t\t\tString className;\n\t\t\tboolean addSQL = true;\n\t\t\ttry {\n\t\t\t\tClass c;\n\t\t\t\tswitch ( bk ) {\n\t\t\t\t\tcase \"boolean\":\n\t\t\t\t\t\tc = boolean.class;\n\t\t\t\t\t\tclassName = \"Z\";\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase \"byte\":\n\t\t\t\t\t\tc = byte.class;\n\t\t\t\t\t\tclassName = \"B\";\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase \"char\":\n\t\t\t\t\t\tc = char.class;\n\t\t\t\t\t\tclassName = \"C\";\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase \"double\":\n\t\t\t\t\t\tc = double.class;\n\t\t\t\t\t\tclassName = \"D\";\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase \"float\":\n\t\t\t\t\t\tc = float.class;\n\t\t\t\t\t\tclassName = \"F\";\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase \"int\":\n\t\t\t\t\t\tc = int.class;\n\t\t\t\t\t\tclassName = \"I\";\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase \"long\":\n\t\t\t\t\t\tc = long.class;\n\t\t\t\t\t\tclassName = \"J\";\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase \"short\":\n\t\t\t\t\t\tc = short.class;\n\t\t\t\t\t\tclassName = \"S\";\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tdefault:\n\t\t\t\t\t\t// load to make sure it exists\n\t\t\t\t\t\tc = cls.classForName( bk );\n\t\t\t\t\t\tclassName = c.getName();\n\t\t\t\t\t\taddSQL = false;\n\t\t\t\t}\n\t\t\t\tif ( c.isPrimitive() ) {\n\t\t\t\t\t// disallow. \n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tif ( c.isArray() ) {\n\t\t\t\t\tkeys.add( \"[\" + className );\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tkeys.add( \"[L\" + className + \";\" );\n\t\t\t\t}\n\t\t\t}\n\t\t\tcatch ( ClassLoadingException ex ) {\n\t\t\t\t// just ignore. It means we won't be adding that key\n\t\t\t}\n\t\t\tif ( addSQL ) {\n\t\t\t\t// Not all type names given are Java classes, so assume the others are Database types\n\t\t\t\tif ( noSQLrecurse ) {\n\t\t\t\t\t// type is just \"basetype ARRAY\", never \"basetype ARRAY ARRAY ARRAY\"\n\t\t\t\t\tkeys.add( bk );\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t// PostgreSQL type names\n\t\t\t\t\tkeys.add( bk + \"[]\" );\n\t\t\t\t\t// standard SQL\n\t\t\t\t\tkeys.add( bk + \" ARRAY\" );\n\t\t\t\t\t// also possible\n\t\t\t\t\tkeys.add( bk + \" array\" );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn keys.toArray( new String[keys.size()] );\n\t}", "public List getColumnKeys() {\n/* 204 */ List result = new ArrayList();\n/* 205 */ int last = lastCategoryIndex();\n/* 206 */ for (int i = this.firstCategoryIndex; i <= last; i++) {\n/* 207 */ result.add(this.underlying.getColumnKey(i));\n/* */ }\n/* 209 */ return Collections.unmodifiableList(result);\n/* */ }", "private Map getKeyFields ()\n\t\t\t{\n\t\t\t\tModel model = getModel();\n\t\t\t\tString pcClassName = getClassName();\n\t\t\t\tPersistenceClassElement pce = \n\t\t\t\t\tmodel.getPersistenceClass(pcClassName);\n\t\t\t\tPersistenceFieldElement[] fields = pce.getFields();\n\t\t\t\tMap keyFields = new HashMap();\n\n\t\t\t\tif (fields != null)\n\t\t\t\t{\n\t\t\t\t\tfor (int i = 0; i < fields.length; i++)\n\t\t\t\t\t{\n\t\t\t\t\t\tPersistenceFieldElement pfe = fields[i];\n\t\t\t\t\t\tif (pfe.isKey())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tString name = pfe.getName();\n\t\t\t\t\t\t\tkeyFields.put(name, \n\t\t\t\t\t\t\t\tmodel.getField(pcClassName, name));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\treturn keyFields;\n\t\t\t}", "public KeyType keyType() {\n return this.keyType;\n }", "public void getAllAttributeTypesKeys(Set<String> all, ItemFilter<IAttributeType<?>> filter);", "private JSObject getTableColumnNamesTypes(SQLiteDatabase db, String tableName) throws JSONException {\n JSObject ret = new JSObject();\n ArrayList<String> names = new ArrayList<String>();\n ArrayList<String> types = new ArrayList<String>();\n String query = new StringBuilder(\"PRAGMA table_info(\").append(tableName).append(\");\").toString();\n JSArray resQuery = this.selectSQL(db, query, new ArrayList<String>());\n List<JSObject> lQuery = resQuery.toList();\n if (resQuery.length() > 0) {\n for (JSObject obj : lQuery) {\n names.add(obj.getString(\"name\"));\n types.add(obj.getString(\"type\"));\n }\n ret.put(\"names\", names);\n ret.put(\"types\", types);\n }\n return ret;\n }", "public List<String> getResourceTypes(){\n\t\treturn jtemp.queryForList(\"SELECT resource_type_id||' '||resource_type_name FROM resource_type\", String.class);\n\t}", "public Iterator getTypes() {\r\n\t\treturn types == null ? EmptyStructures.EMPTY_ITERATOR : new ReadOnlyIterator(types.values());\r\n\t}", "Set<String> getBaseTypes();", "public Collection<TapKeyColumn> findAllKeyColumns();", "java.util.List<com.icare.eai.schema.om.evSORequest.EvSORequestDocument.EvSORequest.Key> getKeyList();", "List<String> getKeys();", "public Set<String> getKeys() {\n return Collections.unmodifiableSet(data.keySet());\n }", "public int[] getTypes(){\n int[] types={TYPE_STRING,TYPE_STRING,TYPE_STRING,TYPE_INT};\n return types;\n }", "public Set<Class<? extends RealmModel>> getDBTableTypes(){\n try {\n if (this.realmConfiguration == null) {\n this.realmConfiguration = DatabaseUtilities\n .buildRealmConfig(context, null, null, null);\n }\n } catch (Exception e){\n e.printStackTrace();\n }\n\n if(realmConfiguration == null){\n return null;\n }\n return realmConfiguration.getRealmObjectClasses();\n }", "public Class<?>[] getColumnTypes();", "public Set<Key<?>> keysForTest() {\n return Collections.unmodifiableSet(this.data.keySet());\n }", "public Set<String> persistentFieldNames() {\n return entityMetaData.typeMap.keySet();\n }", "public LogicalType[] getPkTypes(int[] pkOffsets) {\n final LogicalType[] requiredTypes = requiredRowType.getFields().stream()\n .map(RowType.RowField::getType).toArray(LogicalType[]::new);\n return Arrays.stream(pkOffsets).mapToObj(offset -> requiredTypes[offset])\n .toArray(LogicalType[]::new);\n }", "List<Type> getTypeParameters();", "public List<String> getAllDocumentTypes() {\n\t\tList<String> toReturn = new ArrayList<String>();\n\n\t\tint size = combBoxDocumentTypes.getItemCount();\n\n\t\tfor (int i = 0; i < size; i++) {\n\t\t\ttoReturn.add((String) combBoxDocumentTypes.getItemAt(i));\n\t\t}\n\n\t\treturn toReturn;\n\t}", "public String[] getKeys() {\n Set keySet;\n if( defaultValues != null ) {\n keySet = defaultValues.keySet();\n } else {\n keySet = values.keySet();\n }\n return ( String[] )keySet.toArray( new String[ keySet.size() ] );\n }", "public Iterator<K> keys();", "public Iterator<K> keys();", "public String[] fetchAllKeys();", "public Map<String, SkylarkModuleDoc> getTypes() {\n return types;\n }", "public Collection<TapKey> findAllKeys();", "Set<ValueType> get(KeyType key);", "Set<String> getKeys();", "Set<K> keys();", "public Set<Integer> getAllKeys(ObjectDataOptionsEnum... options) throws PersistenceException {\n return (super.getAllKeysInMap(options));\n }", "String getRetrieveKeysQuery();", "public List<String> getTableTypes()\r\n throws Exception\r\n {\r\n List<String> list = new ArrayList<String>();\r\n \r\n list.add(TYPE_TABLES);\r\n \r\n return list;\r\n }", "public List<Pair<ResolvedTypeParameterDeclaration, ResolvedType>> getTypeParametersMap() {\n List<Pair<ResolvedTypeParameterDeclaration, ResolvedType>> typeParametersMap = new ArrayList<>();\n if (!isRawType()) {\n for (int i = 0; i < typeDeclaration.getTypeParameters().size(); i++) {\n typeParametersMap.add(new Pair<>(typeDeclaration.getTypeParameters().get(i), typeParametersValues().get(i)));\n }\n }\n return typeParametersMap;\n }", "public List<K> keys()\r\n\t{\r\n\t\tList<K> keys = new ArrayList<K>();\r\n\t\t\r\n\t\tfor(Entry element : data)\r\n\t\t{\r\n\t\t\tkeys.add(element.key);\r\n\t\t}\r\n\t\t\r\n\t\t//keys.sort(new keyComparator()); //not necessarily needed since I know my BST iterator\r\n\t\t\t\t\t\t\t\t\t\t //iterates through in an inOrder fashion.\r\n\t\t\r\n\t\treturn keys;\r\n\t}", "public abstract List<String> getAllKeys();", "public List<Ref<? extends Type>> typeVariables();", "public static Collection<DataType> values() {\n return values(DataType.class);\n }", "public Set<String> keysOfMap() {\n Map<String, String> tempMap = createSimpleMap(\"Elevensies\",\"Grapes\");\n\t\tSet<String> keys = hashMap.keySet();\n\t\treturn tempMap.keySet();\n\t}", "public List<DataType> listDataTypes() throws IOException,\n\t\t\tClassNotFoundException {\n\t\treturn list(DataType.class);\n\t}", "public Set<Class<?>> getTypes() {\n\t\treturn dataTypes;\n\t}", "public Set<Class<?>> getTypes() {\n\t\treturn dataTypes;\n\t}", "Collection<RecordType> getRecordTypes() throws TypeException, InterruptedException;", "public static Set<Type> getBiomeTypes() {\n\t\ttry {\n\t\t\tfinal Field accessor = ReflectionHelper.findField(BiomeDictionary.Type.class, \"byName\");\n\t\t\tif (accessor != null) {\n\t\t\t\t@SuppressWarnings(\"unchecked\")\n\t\t\t\tfinal Map<String, BiomeDictionary.Type> stuff = (Map<String, BiomeDictionary.Type>) accessor.get(null);\n\t\t\t\treturn new ReferenceOpenHashSet<>(stuff.values());\n\t\t\t}\n\n\t\t\treturn ImmutableSet.of();\n\n\t\t} catch (final Throwable t) {\n\t\t\tthrow new RuntimeException(\"Cannot locate BiomeDictionary.Type table!\");\n\t\t}\n\n\t}" ]
[ "0.6462536", "0.6358651", "0.61686283", "0.6145499", "0.61411226", "0.6000622", "0.59737635", "0.5967963", "0.5958322", "0.5920974", "0.59096944", "0.58852214", "0.5880665", "0.5868013", "0.58670557", "0.5860214", "0.58336365", "0.58206975", "0.58021116", "0.5800267", "0.5794507", "0.5785375", "0.57793856", "0.57793266", "0.5770306", "0.57670355", "0.5765715", "0.5747665", "0.5741708", "0.57416624", "0.57278883", "0.57211065", "0.57167566", "0.57114816", "0.57114816", "0.56966865", "0.5685012", "0.56669176", "0.5665184", "0.5661472", "0.5657896", "0.5657275", "0.5646887", "0.56288654", "0.56282485", "0.5624836", "0.5621957", "0.5614509", "0.5607848", "0.5600927", "0.5600156", "0.55784076", "0.5578078", "0.5568926", "0.55512285", "0.5546229", "0.5543207", "0.55391777", "0.55375654", "0.55375266", "0.55334795", "0.55223477", "0.5517831", "0.5512553", "0.5510676", "0.5493081", "0.548465", "0.54770726", "0.5474736", "0.5474376", "0.54607296", "0.5435524", "0.5433102", "0.54267925", "0.54220796", "0.54014295", "0.5400753", "0.5394456", "0.5383673", "0.5383673", "0.53803724", "0.5378518", "0.5374929", "0.53740513", "0.53725785", "0.53542", "0.53525734", "0.53448164", "0.5337615", "0.5336752", "0.5326662", "0.532477", "0.53231084", "0.53222245", "0.53197503", "0.53125656", "0.5312", "0.5312", "0.53118664", "0.5309787" ]
0.7644806
0
Get a map of data type keys to the data filters associated with them.
protected Map<String, DataFilter> getFilterMap() { return getFilterMap(getQueryableDataTypeKeys()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "Map<String, String> getFilters();", "protected Map<String, DataFilter> getFilterMap(Collection<? extends String> keys)\r\n {\r\n Map<String, DataFilter> filterMap = New.map();\r\n for (String key : keys)\r\n {\r\n filterMap.put(key, myToolbox.getDataFilterRegistry().getLoadFilter(key));\r\n }\r\n return filterMap;\r\n }", "public Map<String, Object> getFilters() {\n if (filters == null) {\n filters = new HashMap<String, Object>();\n }\n \n return filters;\n }", "public Hashtable getFilters() {\n // we need to build the hashtable dynamically\n return globalFilterSet.getFilterHash();\n }", "public Collection<? extends String> getQueryableDataTypeKeys()\r\n {\r\n return MantleToolboxUtils.getMantleToolbox(myToolbox).getDataGroupController().getQueryableDataTypeKeys();\r\n }", "protected Map<String, String> getFilter() {\n\t\tMap<String, String> filterMap = new HashMap<String, String>();\n\t\tfilterMap.clear();\n\t\tString filterGrade = \"\";\n\t\tString elemGrade=\"\";\n\t\t\n\t\tString eleGrade = getSelectedFilter(eleGradePanelUc);\n\t\tif (!eleGrade.isEmpty()) {\n\t\t\tfilterGrade+=eleGrade;\n\t\t}\n\t\tString midGrade = getSelectedFilter(middleGradePanelUc);\n\t\tif (!midGrade.isEmpty()) {\n\t\t\tif(filterGrade.equals(\"\")){\n\t\t\t\tif(elemGrade.isEmpty()){\n\t\t\t\t\tfilterGrade+=midGrade;\n\t\t\t\t}\n\t\t\t}else {\n\t\t\t\tfilterGrade+=\",\"+midGrade;\n\t\t\t}\n\t\t}\n\t\tString highGrade = getSelectedFilter(highrGradePanelUc);\n\t\tif (!highGrade.isEmpty()) {\n\t\t\tif(filterGrade.equals(\"\")){\n\t\t\t\tfilterGrade+=highGrade;\n\t\t\t}else{\n\t\t\t\tfilterGrade+=\",\"+highGrade;\n\t\t\t}\n\t\t}\n\t\tif(filterGrade!=null && !filterGrade.equals(\"\")){\n\t\t\tfilterMap.put(IsSearchView.GRADE_FLT, filterGrade);\n\t\t}\n\t\tString selectedSubject = getSelectedFilter(subjectPanelUc, \"~~\");\n\t\tif (!selectedSubject.isEmpty()) {\n\t\t\tfilterMap.put(IsSearchView.SUBJECT_FLT, selectedSubject);\n\t\t}\n\t\treturn filterMap;\n\t}", "Map<String, Object> getFilterScratchpad();", "public Map<String, Integer> getDataMap() {\n\t\tMap<String, Integer> dataMap = new HashMap<>();\n\t\tdataMap.putAll(temperature.getDataMap());\n\t\tdataMap.putAll(wind.getDataMap());\n\t\tdataMap.putAll(precipitation.getDataMap());\n\t\tdataMap.putAll(condition.getDataMap());\n\t\tdataMap.putAll(hazard.getDataMap());\n\t\tdataMap.putAll(wave.getDataMap());\n\t\t\n\t\treturn dataMap;\n\t}", "public Map<String, Filter> getFilters() {\n return filters;\n }", "private void cargarFiltros(Map<String, String> filters)\r\n/* 81: */ {\r\n/* 82:107 */ filters.put(\"numero\", String.valueOf(getDimension()));\r\n/* 83: */ }", "public static WFJFilterMap[] findFilterMaps() {\n return filterMaps.asArray();\n }", "private Map<String, PermissionType> getPermissionTypeMapForLabelToMaskChange() {\n\t\tMap<String, PermissionType> permissionTypeMap = new LinkedHashMap<String, PermissionType>();\n\n\t\tList<PermissionType> permissionTypes = permissionTypeRepo.findAll();\n\t\tfor (int i = 0; i < permissionTypes.size(); i++) {\n\t\t\tpermissionTypeMap.put(permissionTypes.get(i).getName(), permissionTypes.get(i));\n\t\t}\n\t\treturn permissionTypeMap;\n\t}", "synchronized public Map<String, Set<String>> getTypes() {\n return Collections.unmodifiableMap(\n new HashSet<>(types.entrySet()).stream()\n .collect(Collectors.toMap(\n Map.Entry::getKey,\n e -> Collections.unmodifiableSet(new HashSet<>(e.getValue()))\n ))\n );\n }", "public Map<FruitType, List<Fruit>> groupByType_lambda() {\n\t\treturn fruits.stream().collect(Collectors.groupingBy(f -> f.getType()));\n\t}", "private static HashMap<String, String> initMapping()\n {\n HashMap<String, String> typeMapping = new HashMap<String, String>();\n\n typeMapping.put(\"boolean\", \"boolean\");\n typeMapping.put(\"float\", \"float\");\n typeMapping.put(\"double\", \"double\");\n typeMapping.put(\"byte\", \"byte\");\n typeMapping.put(\"unsignedByte\", \"short\");\n typeMapping.put(\"short\", \"short\");\n typeMapping.put(\"unsignedShort\", \"int\");\n typeMapping.put(\"int\", \"int\");\n typeMapping.put(\"integer\", \"java.math.BigDecimal\");\n typeMapping.put(\"positiveInteger\", \"java.math.BigInteger\");\n typeMapping.put(\"unsignedInt\", \"java.math.BigInteger\");\n typeMapping.put(\"long\", \"java.math.BigInteger\");\n typeMapping.put(\"unsignedLong\", \"java.math.BigDecimal\");\n typeMapping.put(\"decimal\", \"java.math.BigDecimal\");\n typeMapping.put(\"string\", \"String\");\n typeMapping.put(\"hexBinary\", \"byte[]\");\n typeMapping.put(\"base64Binary\", \"byte[]\");\n typeMapping.put(\"dateTime\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"time\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"date\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"gDay\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"gMonth\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"gMonthDay\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"gYear\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"gYearMonth\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"duration\", \"javax.xml.datatype.Duration\");\n typeMapping.put(\"NOTATION\", \"javax.xml.namespace.QName\");\n typeMapping.put(\"QName\", \"javax.xml.namespace.QName\");\n typeMapping.put(\"anyURI\", \"String\");\n typeMapping.put(\"Name\", \"String\");\n typeMapping.put(\"NCName\", \"String\");\n typeMapping.put(\"negativeInteger\", \"java.math.BigDecimal\");\n typeMapping.put(\"NMTOKEN\", \"String\");\n typeMapping.put(\"nonNegativeInteger\", \"java.math.BigDecimal\");\n typeMapping.put(\"nonPositiveInteger\", \"java.math.BigDecimal\");\n typeMapping.put(\"normalizedString\", \"String\");\n typeMapping.put(\"token\", \"String\");\n typeMapping.put(\"any\", \"Object\");\n\n return typeMapping;\n }", "java.lang.String getDataItemFilter();", "com.google.protobuf.ByteString getDataItemFilterBytes();", "public static Map<String, Byte> genNameToTypeMap(){\n byte[] types = genAllTypes();\n String[] names = genAllTypeNames();\n Map<String, Byte> ret = new HashMap<String, Byte>();\n for(int i=0;i<types.length;i++){\n ret.put(names[i], types[i]);\n }\n return ret;\n }", "public static BookFilter getDictionaries()\n {\n return new BookCategoryFilter(BookCategory.DICTIONARY);\n }", "public static Map<String, String> filterFieldParametersTypes(final String packageName,\n final Imports imports,\n final Map<String, String> projectFieldParametersTypes) {\n final Map<String, String> scopedFieldParametersType = new HashMap<String, String>();\n for (Map.Entry<String, String> e : projectFieldParametersTypes.entrySet()) {\n String fieldName = e.getKey();\n String fieldType = e.getValue();\n final String fFieldName = getFieldNameFromEnumeration(fieldName);\n\n final String fFieldName_QualifiedType = getQualifiedTypeFromEnumeration(fieldName);\n final String fFieldName_PackageName = getPackageName(fFieldName_QualifiedType);\n final String fFieldName_TypeName = getTypeName(fFieldName_QualifiedType);\n if (fFieldName_PackageName.equals(packageName) || isImported(fFieldName_QualifiedType,\n imports)) {\n fieldName = fFieldName_TypeName;\n }\n\n final String fFieldType_QualifiedType = getQualifiedTypeFromEnumeration(fieldType);\n final String fFieldType_PackageName = getPackageName(fFieldType_QualifiedType);\n final String fFieldType_TypeName = getTypeName(fFieldType_QualifiedType);\n if (fFieldType_PackageName.equals(packageName) || isImported(fFieldType_QualifiedType,\n imports)) {\n fieldType = fFieldType_TypeName;\n }\n\n scopedFieldParametersType.put(fieldName + \"#\" + fFieldName,\n fieldType);\n }\n return scopedFieldParametersType;\n }", "public Map<FruitType, List<Fruit>> groupByType() {\n\t\treturn fruits.stream().collect(Collectors.groupingBy(Fruit::getType));\n\t}", "public <T> Map<MDSKey, T> listKV(MDSKey startId, @Nullable MDSKey stopId, Type typeOfT, int limit,\n Predicate<T> filter) {\n return listKV(startId, stopId, typeOfT, limit, null, filter);\n }", "Hashtable createTypeMapping()\n {\n Hashtable mapping = new Hashtable();\n \n mapping.put(TypeFactory.getType(\"Double\"), \n new ParameterFactory() \n {\n public Parameter getParameter(Object o) \n {\n StratmasDecimal sObj = (StratmasDecimal) o;\n if (isBadDecimal(sObj)) {\n return null;\n } else {\n return new StratmasDecimalParameter((StratmasDecimal) o);\n }\n }\n });\n mapping.put(TypeFactory.getType(\"double\", \"http://www.w3.org/2001/XMLSchema\"), \n new ParameterFactory() \n {\n public Parameter getParameter(Object o) \n {\n StratmasDecimal sObj = (StratmasDecimal) o;\n if (isBadDecimal(sObj)) {\n return null;\n } else {\n return new StratmasDecimalParameter((StratmasDecimal) o);\n }\n }\n });\n mapping.put(TypeFactory.getType(\"NonNegativeInteger\"), \n new ParameterFactory() \n {\n public Parameter getParameter(Object o) \n {\n return new StratmasIntegerParameter((StratmasInteger) o);\n }\n });\n // Ground type type hiearchy.\n mapping.put(TypeFactory.getType(\"anyType\", \"http://www.w3.org/2001/XMLSchema\"), \n new ParameterFactory() \n {\n public Parameter getParameter(Object o) \n {\n return null;\n }\n });\n\n return mapping;\n }", "public Map<String, Boolean> getIsTypeOptionValidMap() {\n if (typeOptionValidMap == null) {\n typeOptionValidMap = new HashMap<String, Boolean>() {\n @Override\n public Boolean get(Object key) {\n return !(key == null || \"\".equals(key.toString().trim()) || countKeyOccurence(typeOptions, (String) key) > 1);\n }\n };\n }\n return typeOptionValidMap;\n }", "Map<ParameterInstance, SetType> getInstanceSetTypes();", "public Map<FruitType, List<Fruit>> groupByTypeConcrrently() {\n\t\treturn fruits.parallelStream().collect(Collectors.groupingByConcurrent(Fruit::getType));\n\t}", "public static interface KeyValueFilter {\r\n\t}", "public static Map<Byte, String> genTypeToNameMap(){\n byte[] types = genAllTypes();\n String[] names = genAllTypeNames();\n Map<Byte,String> ret = new HashMap<Byte, String>();\n for(int i=0;i<types.length;i++){\n ret.put(types[i], names[i]);\n }\n return ret;\n }", "public <T> Map<MDSKey, T> listKV(MDSKey startId, @Nullable MDSKey stopId, Type typeOfT, int limit,\n Predicate<MDSKey> keyFilter, Predicate<T> valueFilter) {\n byte[] startKey = startId.getKey();\n byte[] stopKey = stopId == null ? Bytes.stopKeyForPrefix(startKey) : stopId.getKey();\n\n Scan scan = new Scan(startKey, stopKey);\n return listKV(scan, typeOfT, limit, keyFilter, valueFilter);\n }", "public void getAllAttributeTypesKeys(Set<String> all, ItemFilter<IAttributeType<?>> filter);", "public Map<String, String> getDocFieldsVsDataTypeMap() {\n\t\treturn docFieldsVsDataTypeMap;\n\t}", "private Map<String, Object> analysisMap(ArrayList<String> data) {\n Map<String, Object> map = new HashMap<>();\n map.put(DAILY, data);\n return map;\n }", "public Map<TypeQuantity, List<Fruit>> groupByTypeQuantity(){\n\t\treturn fruits.stream().collect(Collectors.groupingBy( fruit -> new TypeQuantity(fruit.getType(), fruit.getQuantity())));\n\t}", "public Map<String, Boolean> getFilteringResults() {\n return filteringResults;\n }", "private Map getKeyFields ()\n\t\t\t{\n\t\t\t\tModel model = getModel();\n\t\t\t\tString pcClassName = getClassName();\n\t\t\t\tPersistenceClassElement pce = \n\t\t\t\t\tmodel.getPersistenceClass(pcClassName);\n\t\t\t\tPersistenceFieldElement[] fields = pce.getFields();\n\t\t\t\tMap keyFields = new HashMap();\n\n\t\t\t\tif (fields != null)\n\t\t\t\t{\n\t\t\t\t\tfor (int i = 0; i < fields.length; i++)\n\t\t\t\t\t{\n\t\t\t\t\t\tPersistenceFieldElement pfe = fields[i];\n\t\t\t\t\t\tif (pfe.isKey())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tString name = pfe.getName();\n\t\t\t\t\t\t\tkeyFields.put(name, \n\t\t\t\t\t\t\t\tmodel.getField(pcClassName, name));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\treturn keyFields;\n\t\t\t}", "public Map<String, Integer> getMappings() {\n return mappingPredicateToInt;\n }", "public Map<String, String> getColumnsMap() {\n\t\treturn columnsVsDataTypeMap;\n\t}", "public HashMap<String, Object> convert() {\n HashMap<String, Object> condMap = new HashMap<String, Object>();\n condMap.put(CommonSpecification.PARAMETERS, paramList);\n condMap.put(CommonSpecification.FETCH_TABLES, fetchTables);\n condMap.put(CommonSpecification.JOIN_TABLES, joinTables);\n condMap.put(CommonSpecification.SORT, sort);\n return condMap;\n }", "public Map<FruitType, Long> groupByTypeWithCounts() {\n\t\treturn fruits.stream().collect(Collectors.groupingBy(Fruit::getType, Collectors.counting()));\n\t}", "Map<String, PrimitiveTypeProvider> convert(T data);", "public Map<FruitType, Map<Integer, List<Fruit>>> groupByTypeAndLike_2() {\n\t\treturn fruits.stream()\n\t\t\t\t.collect(Collectors.groupingBy(Fruit::getType, Collectors.groupingBy(Fruit::getLikes)));\n\t}", "public Map<String, Set<Object>> getPrimaryFilters() {\n return primaryFilters;\n }", "public Map<String, FieldType> flatten() {\n if (fields == null || fields.length == 0) {\n return Collections.<String, FieldType> emptyMap();\n }\n\n Map<String, FieldType> map = new LinkedHashMap<String, FieldType>();\n\n for (Field nestedField : fields) {\n addSubFieldToMap(map, nestedField, null);\n }\n\n return map;\n }", "List<String> getFilters();", "HashMap<Value, HashSet<Value>> getLayerDatasetDescriptions();", "@Override\n public HashMap<String, String> getFilterTerms() {\n HashMap<String, String> filterTerms = new HashMap<>();\n if (countryCheckBox.isSelected()) {\n filterTerms.put(\"Country\", countryField.getText());\n }\n if (cityCheckBox.isSelected()) {\n filterTerms.put(\"City\", cityField.getText());\n }\n return filterTerms;\n }", "public List<String> getDataPointTypes() {\n Object[] dpTypes = (Object[])configMap.get(DATA_POINT_TYPES);\n List<String> types = Utility.downcast( dpTypes );\n return types;\n }", "private ListMap<String, String> slurpFilters(final File vcf) {\n final ListMap<String, String> map = new ListMap<>();\n final VCFFileReader in = new VCFFileReader(vcf, false);\n for (final VariantContext ctx : in) {\n if (ctx.isNotFiltered()) continue;\n for (final String filter : ctx.getFilters()) {\n map.add(ctx.getID(), filter);\n }\n }\n in.close();\n return map;\n }", "@ZenCodeType.Caster\n @ZenCodeType.Method\n default Map<String, IData> asMap() {\n \n return notSupportedCast(\"IData[string]\");\n }", "Map<String, Field> extensionFieldsMap() {\n Map<String, Field> extensionsForType = new LinkedHashMap<>();\n for (Field field : extensionFields) {\n extensionsForType.put(field.qualifiedName(), field);\n }\n return extensionsForType;\n }", "public Map<String, List<Fruit>> groupByTypeAndLike() {\n\t\treturn fruits.stream().collect(Collectors.groupingBy(Fruit::getTypeLikes));\n\t}", "ColumnInfoFilter getColumnInfoFilter();", "java.util.Map<java.lang.String, java.lang.String>\n getFieldMap();", "private Map<String, DataContainer> getDataContainerMap() {\r\n\r\n if (this.dataContainerMap == null) {\r\n if (this.dataContainerList == null) {\r\n parse();\r\n }\r\n\r\n this.dataContainerMap = new HashMap<>();\r\n for (DataContainer dataContainer : this.dataContainerList) {\r\n this.dataContainerMap.put(dataContainer.getVariableName(), dataContainer);\r\n }\r\n }\r\n return this.dataContainerMap;\r\n }", "public List<Pair<ResolvedTypeParameterDeclaration, ResolvedType>> getTypeParametersMap() {\n List<Pair<ResolvedTypeParameterDeclaration, ResolvedType>> typeParametersMap = new ArrayList<>();\n if (!isRawType()) {\n for (int i = 0; i < typeDeclaration.getTypeParameters().size(); i++) {\n typeParametersMap.add(new Pair<>(typeDeclaration.getTypeParameters().get(i), typeParametersValues().get(i)));\n }\n }\n return typeParametersMap;\n }", "public abstract Map<String, Integer> getColumnTypes(String tableName);", "public Set<String> getDataKeys() {\r\n\t\treturn data.keySet();\r\n\t}", "protected static Map<String, Object> prepareQueryForSelection(JsonObject parameters) {\n Map<String, Object> queryFilters = new HashMap<String, Object>();\n\n // Date fields\n processDateFilter(Entity.CREATION_DATE, parameters, queryFilters);\n processDateFilter(Entity.MODIFICATION_DATE, parameters, queryFilters);\n\n // String fields\n processStringFilter(Consumer.EMAIL, parameters, queryFilters);\n processStringFilter(Consumer.JABBER_ID, parameters, queryFilters);\n processStringFilter(Consumer.NAME, parameters, queryFilters);\n processStringFilter(Consumer.TWITTER_ID, parameters, queryFilters);\n\n // Long fields\n processLongFilter(Consumer.FACEBOOK_ID, parameters, queryFilters);\n\n return queryFilters;\n }", "@RequestMapping(value=\"/datatypes\",method=RequestMethod.GET)\n public DataFieldType[] getAllDataTypes(){\n return DataFieldType.values();\n }", "String getTypeFilter(String column, Collection<FxType> types);", "public static Map<String, Object> mapData(Object data) {\n\t\tMap<String, Object> modelMap = new HashMap<String,Object>(2);\n\t\tmodelMap.put(\"data\", data);\n\t\tmodelMap.put(\"success\", true);\n\t\t\n\t\treturn modelMap;\n\t}", "public static interface GetFilter extends KeyValueFilter {\r\n\t\tObject get(String name);\r\n\t}", "public Map<Integer, Data> getDataMap() {\n Map<Integer, Data> result = new HashMap<Integer, Data>();\n for (Integer varIndex : _dataMap.keySet()) {\n List<Data> dataList = _dataMap.get(varIndex);\n result.put(varIndex, dataList.get(dataList.size() - 1));\n }\n return result;\n }", "public void filterByDataType(HashMap<String, String> filterTerms) {\n filterer.filterAirports(filterTerms, storage.getAirports());\n }", "private static Map<String, String> getColumnsToFieldsMap() {\n final Map<String, String> columnsToFieldsMap = new HashMap<>();\n\n columnsToFieldsMap.put(TABLET_SESSION_TABLE_WETTKAMPF_ID, TABLET_SESSION_BE_WETTKAMPF_ID);\n columnsToFieldsMap.put(TABLET_SESSION_TABLE_SCHEIBENNUMMER, TABLET_SESSION_BE_SCHEIBENNUMMER);\n columnsToFieldsMap.put(TABLET_SESSION_TABLE_MATCH_ID, TABLET_SESSION_BE_MATCH_ID);\n columnsToFieldsMap.put(TABLET_SESSION_TABLE_SATZNUMMER, TABLET_SESSION_BE_SATZNUMMER);\n columnsToFieldsMap.put(TABLET_SESSION_TABLE_IS_ACTIVE, TABLET_SESSION_BE_IS_ACTIVE);\n columnsToFieldsMap.put(TABLET_SESSION_TABLE_ACCESS_TOKEN, TABLET_SESSION_BE_ACCESS_TOKEN);\n\n // add technical columns\n columnsToFieldsMap.putAll(BasicDAO.getTechnicalColumnsToFieldsMap());\n\n return columnsToFieldsMap;\n }", "protected abstract Map<String, Serializable> getEventKeyAndIdMap();", "public Map<Integer, Boolean> getFilter(Geometry geom) throws SQLException {\n return retrieveExpected(createNativeFilterStatement(geom), BOOLEAN);\n }", "public List<SysDictData> selectDictDataByType(String dictType);", "private VariableMap getParamMappingAsVariableMap() {\n paramValueEncodings.put(fileNameToIndex.keySet().toString(), \" FileNames\");\n paramValueEncodings.put(functionNameToIndex.keySet().toString(), \" FunctionNames\");\n paramValueEncodings.put(typeToIndex.keySet().toString(), \" Types\");\n\n VariableMap preInversedMap = new VariableMap(paramValueEncodings);\n ImmutableMap<String, String> inversedMap = preInversedMap.getNewNameToOriginalNameMap();\n return new VariableMap(inversedMap);\n }", "public DataTableFilterType getFilterType( )\n {\n return _filterType;\n }", "public DDataFilter() {\n filters = new ArrayList<>();\n operator = null;\n value = null;\n externalData = false;\n valueTo = null;\n attribute = ROOT_FILTER;\n }", "protected abstract Map<String, Map<String, Object>> getData(String columnFamilyName);", "@Override\n public Map<String, ? extends FilterRegistration> getFilterRegistrations() {\n return null;\n }", "private HashMap<String,String> createQueryMap() {\n\t\t\n\t\tHashMap<String, String> map = new HashMap<String, String>();\n\t\t\n\t\t// Only include Pages with the CenterNet Event template\n\t\tmap.put(\"type\",\"cq:Page\");\n\t\tmap.put(\"path\", Constants.EVENTS);\n\t\tmap.put(\"property\",\"jcr:content/cq:template\");\n\t map.put(\"property.value\", Constants.EVENT_TEMPLATE);\n\n\t if (tags != null) {\n\t \tmap = addTagFilter(map);\n\t }\n\n\t // Only include Events whose start time is in the future\n\t map.put(\"relativedaterange.property\", PN_QUERY_START_TIME);\n\t map.put(\"relativedaterange.lowerBound\", \"-0d\");\n\t \n\t // Include all hits\n\t //map.put(\"p.limit\", maxNum.toString());\n\t map.put(\"p.limit\", maxNum);\n\t map.put(\"p.guessTotal\", \"true\");\n\t \n\t // Order by Start Time\n\t map.put(\"orderby\", PN_QUERY_START_TIME);\n\t map.put(\"orderby.sort\", \"asc\");\n\t \n\t\treturn map;\n\t\t\n\t}", "@Override\r\n\t\tpublic Map<String, Class<?>> getTypeMap() throws SQLException {\n\t\t\treturn null;\r\n\t\t}", "public Map<String, String> addFilterValue(String filterCriteria, String filterValue);", "public static Map<String, Boolean> filterEventTypes(final String packageName,\n final Imports imports,\n final Map<String, Boolean> projectEventTypes) {\n final Map<String, Boolean> scopedEventTypes = new HashMap<String, Boolean>();\n for (Map.Entry<String, Boolean> e : projectEventTypes.entrySet()) {\n final String eventQualifiedType = e.getKey();\n final String eventPackageName = getPackageName(eventQualifiedType);\n final String eventTypeName = getTypeName(eventQualifiedType);\n\n if (eventPackageName.equals(packageName) || isImported(eventQualifiedType,\n imports)) {\n scopedEventTypes.put(eventTypeName,\n e.getValue());\n }\n }\n return scopedEventTypes;\n }", "public HashMap<String,String> filterDataForVerification(HashMap<String, String> data)\n {\n\n HashMap<String, String> fillter = new HashMap<String, String>();\n\n //add medical condition description\n String medicalConditionDescription =\n getMedicalConditionDescription(data.get(\"medical_condition_id\"));\n fillter.put(\"medical_condition_description\", medicalConditionDescription);\n\n\n //add medication name\n String medicationName = getMedicationName( data.get(\"medication_num\"));\n\n fillter.put(\"medication_name\", medicationName);\n\n for (String key : data.keySet()) {\n if (key.equals(\"first_name\") || key.equals(\"last_name\") || key.equals(\"street\") ||\n key.equals(\"home_phone_number\") || key.equals(\"email_address\")\n || key.equals(\"house_number\") || key.equals(\"contact_phone\") ||\n key.equals(\"zip_code\") || key.equals(\"birth_date\") || key.equals(\"city\") ||\n key.equals(\"mobile_phone_number\") || key.equals(\"state\")\n || key == \"dosage\")\n fillter.put(key,data.get(key));\n\n if (key.equals(\"gender\"))\n fillter.put(key,convertCodeToGender(data.get(key)));\n }\n return fillter;\n }", "public Map<EventKey, EventMethod> createEventMap() {\n\t\tfinal Map<EventKey, EventMethod> eventMap = new EnumMap<>(EventKey.class);\n\t\tfinal Pair<Map<String, Object>, Set<Class<?>>> eventPair = prepareEventPair();\n\n\t\tfor (Class<?> eventClass : eventPair.getSecond()) {\n\t\t\tfor (Method eventMethod : prepareEventMethods(eventClass)) {\n\t\t\t\teventMap.put(eventMethod.getAnnotation(EventMapping.class).key(),\n\t\t\t\t\t\tnew EventMethod(eventPair.getFirst().get(eventClass.getName()), eventMethod));\n\t\t\t}\n\t\t}\n\t\treturn eventMap;\n\t}", "protected Map<String, String> getFeatureAttrs(Map<String, Object> data) {\n\t\treturn null;\n\t}", "public Hashtable getDataTypeDefinitions() {\n return ComponentHelper.getComponentHelper(this).getDataTypeDefinitions();\n }", "public List<COSName> getFilters() {\n/* 312 */ List<COSName> retval = null;\n/* 313 */ COSBase filters = this.stream.getFilters();\n/* 314 */ if (filters instanceof COSName) {\n/* */ \n/* 316 */ COSName name = (COSName)filters;\n/* 317 */ retval = new COSArrayList<COSName>(name, (COSBase)name, (COSDictionary)this.stream, COSName.FILTER);\n/* */ }\n/* 319 */ else if (filters instanceof COSArray) {\n/* */ \n/* 321 */ retval = ((COSArray)filters).toList();\n/* */ } \n/* 323 */ return retval;\n/* */ }", "public Map<FruitType, Set<Fruit>> groupByTypeToSet() {\n\t\treturn fruits.stream().collect(Collectors.groupingBy(Fruit::getType, Collectors.toSet()));\n\t}", "public Map<String, Object> allFields() {\n Map<String, Object> map = new HashMap<>();\n properties.forEach((key, value) -> map.put(key, value.value()));\n return map;\n }", "@Override\n\tpublic Map<String, Class<?>> getKeysMap(String entitySetName) {\n\t\treturn null;\n\t}", "public String getTypeFilter()\r\n\t{\r\n\t\treturn this.typeFilter;\r\n\t}", "public String getCutypeMapping();", "protected List<Tuple<Operator, Property>> getPropertyFilters() {\n if (properties == null) {\n EntityDescriptor ed = getDescriptor();\n properties = filters.stream()\n .map(filter -> Tuple.create(filter.getFirst(), ed.getProperty(filter.getSecond())))\n .toList();\n }\n\n return Collections.unmodifiableList(properties);\n }", "public HashMap<CellID, Set<MetadataID> > searchMetadata(MetadataSearchFilters filters){\n // pass in a listener to notify, rather than sending directly to a connection\n logger.log(Level.INFO, \"[META SERVICE] global search with \" + filters.filterCount() + \" filters\");\n return db.searchMetadata(filters);\n }", "public Map<String, StatisticsEventConfig> getTypeView() {\n return classToEventMap;\n }", "protected Set<String> filterColumns() {\n return columnSelectionMap.keySet();\n }", "protected Map getKeyMethodMap() {\n\t\tHashMap<String, String> map = new HashMap<String, String>();\n\t\tmap.put(\"cmd.planilla.lista\", \"lista\");\n\t\tmap.put(\"cmd.planilla.buscar\", \"buscar\");\n\t\tmap.put(\"cmd.planilla.verificar\", \"verificar\");\n\t\tmap.put(\"cmd.planilla.cargar\", \"cargar\");\n\t\tmap.put(\"cmd.planilla.actualizar\", \"actualizar\");\n\t\tmap.put(\"cmd.planilla.generar\", \"generar\");\n\t\tmap.put(\"cmd.planilla.cargaFin\", \"cargaFin\");\n\t\tmap.put(\"cmd.planilla.descEmpleadoFiador\", \"descEmpleadoFiador\");\n\t\tmap.put(\"cmd.planilla.verReporte\", \"verReporte\");\n\t\treturn map;\n\t}", "public Map<String, Set<String>> getBufferedDeviceNamesByType();", "public HashMap<String,HashSet<String>> loadTypes(String typeFromO1, String typeFromO2) throws Exception;", "public static Collection<DataType> values() {\n return values(DataType.class);\n }", "static Map<String, Set<IpAccessList>> getSpecifiedFilters(\n FilterLineReachabilityQuestion question, SpecifierContext ctxt) {\n Set<String> specifiedNodes = question.nodeSpecifier().resolve(ctxt);\n FilterSpecifier filterSpecifier = question.filterSpecifier();\n\n return CommonUtil.toImmutableMap(\n specifiedNodes,\n Function.identity(),\n node ->\n filterSpecifier.resolve(node, ctxt).stream()\n .filter(f -> !(question.getIgnoreComposites() && f.isComposite()))\n .collect(ImmutableSet.toImmutableSet()));\n }", "public Collection findPartnerFunctionsKeys(IDataFilter filter)\n throws FindEntityException, SystemException, RemoteException;", "protected Map<Data, String> input() {\n Set<String> inputs = new HashSet<>();\n\n for (Importer importer : importers()) {\n inputs.add(importer.inputData().name());\n }\n\n return DynamicData.oneToOne(inputs.toArray(new String[inputs.size()]));\n }", "public Map<String, VisualizationStyleParameter> getChangedParameterKeyToParameterMap()\r\n {\r\n return myChangedParameterSet.stream().collect(Collectors.toUnmodifiableMap(v -> v.getKey(), v -> v));\r\n }", "public static Map<String, TypeSource> filterTypeSources(final String packageName,\n final Imports imports,\n final Map<String, TypeSource> projectTypeSources) {\n final Map<String, TypeSource> scopedTypeSources = new HashMap<String, TypeSource>();\n for (Map.Entry<String, TypeSource> e : projectTypeSources.entrySet()) {\n final String typeQualifiedType = e.getKey();\n final String typePackageName = getPackageName(typeQualifiedType);\n final String typeTypeName = getTypeName(typeQualifiedType);\n\n if (typePackageName.equals(packageName) || isImported(typeQualifiedType,\n imports)) {\n scopedTypeSources.put(typeTypeName,\n e.getValue());\n }\n }\n return scopedTypeSources;\n }" ]
[ "0.7025145", "0.67949545", "0.6472209", "0.59738547", "0.5935281", "0.5881559", "0.58093005", "0.57693726", "0.57544374", "0.5653748", "0.56493074", "0.5616884", "0.5564015", "0.5545251", "0.54784566", "0.5429808", "0.53597987", "0.5359502", "0.5308194", "0.5305316", "0.52949536", "0.5290967", "0.52904594", "0.52668893", "0.526396", "0.52583754", "0.5238626", "0.5206589", "0.5187013", "0.5178159", "0.5168724", "0.5150585", "0.515042", "0.51295125", "0.51186025", "0.5103154", "0.5099741", "0.50922084", "0.5063558", "0.5062987", "0.5049378", "0.50448203", "0.50406593", "0.50316405", "0.50243515", "0.50213057", "0.5021053", "0.50188893", "0.50183713", "0.5016403", "0.5003612", "0.49963441", "0.49940023", "0.49932346", "0.49803397", "0.49687374", "0.49672255", "0.4961629", "0.49550658", "0.495476", "0.49376196", "0.49354196", "0.49287045", "0.49281353", "0.4916257", "0.4909143", "0.49052048", "0.49044955", "0.48893592", "0.48843738", "0.48768517", "0.4876462", "0.4863751", "0.4858344", "0.48534948", "0.4846433", "0.4845561", "0.48360088", "0.4833101", "0.48207524", "0.48155665", "0.48001945", "0.4800059", "0.47955862", "0.47825468", "0.47784093", "0.4767264", "0.4764499", "0.47635904", "0.4763481", "0.47600392", "0.47519773", "0.47429094", "0.47402862", "0.47394302", "0.47371957", "0.47327968", "0.47316742", "0.47305652", "0.47267097" ]
0.7626232
0
Get a map of data type keys to the data filters associated with them.
protected Map<String, DataFilter> getFilterMap(Collection<? extends String> keys) { Map<String, DataFilter> filterMap = New.map(); for (String key : keys) { filterMap.put(key, myToolbox.getDataFilterRegistry().getLoadFilter(key)); } return filterMap; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected Map<String, DataFilter> getFilterMap()\r\n {\r\n return getFilterMap(getQueryableDataTypeKeys());\r\n }", "Map<String, String> getFilters();", "public Map<String, Object> getFilters() {\n if (filters == null) {\n filters = new HashMap<String, Object>();\n }\n \n return filters;\n }", "public Hashtable getFilters() {\n // we need to build the hashtable dynamically\n return globalFilterSet.getFilterHash();\n }", "public Collection<? extends String> getQueryableDataTypeKeys()\r\n {\r\n return MantleToolboxUtils.getMantleToolbox(myToolbox).getDataGroupController().getQueryableDataTypeKeys();\r\n }", "protected Map<String, String> getFilter() {\n\t\tMap<String, String> filterMap = new HashMap<String, String>();\n\t\tfilterMap.clear();\n\t\tString filterGrade = \"\";\n\t\tString elemGrade=\"\";\n\t\t\n\t\tString eleGrade = getSelectedFilter(eleGradePanelUc);\n\t\tif (!eleGrade.isEmpty()) {\n\t\t\tfilterGrade+=eleGrade;\n\t\t}\n\t\tString midGrade = getSelectedFilter(middleGradePanelUc);\n\t\tif (!midGrade.isEmpty()) {\n\t\t\tif(filterGrade.equals(\"\")){\n\t\t\t\tif(elemGrade.isEmpty()){\n\t\t\t\t\tfilterGrade+=midGrade;\n\t\t\t\t}\n\t\t\t}else {\n\t\t\t\tfilterGrade+=\",\"+midGrade;\n\t\t\t}\n\t\t}\n\t\tString highGrade = getSelectedFilter(highrGradePanelUc);\n\t\tif (!highGrade.isEmpty()) {\n\t\t\tif(filterGrade.equals(\"\")){\n\t\t\t\tfilterGrade+=highGrade;\n\t\t\t}else{\n\t\t\t\tfilterGrade+=\",\"+highGrade;\n\t\t\t}\n\t\t}\n\t\tif(filterGrade!=null && !filterGrade.equals(\"\")){\n\t\t\tfilterMap.put(IsSearchView.GRADE_FLT, filterGrade);\n\t\t}\n\t\tString selectedSubject = getSelectedFilter(subjectPanelUc, \"~~\");\n\t\tif (!selectedSubject.isEmpty()) {\n\t\t\tfilterMap.put(IsSearchView.SUBJECT_FLT, selectedSubject);\n\t\t}\n\t\treturn filterMap;\n\t}", "Map<String, Object> getFilterScratchpad();", "public Map<String, Integer> getDataMap() {\n\t\tMap<String, Integer> dataMap = new HashMap<>();\n\t\tdataMap.putAll(temperature.getDataMap());\n\t\tdataMap.putAll(wind.getDataMap());\n\t\tdataMap.putAll(precipitation.getDataMap());\n\t\tdataMap.putAll(condition.getDataMap());\n\t\tdataMap.putAll(hazard.getDataMap());\n\t\tdataMap.putAll(wave.getDataMap());\n\t\t\n\t\treturn dataMap;\n\t}", "public Map<String, Filter> getFilters() {\n return filters;\n }", "private void cargarFiltros(Map<String, String> filters)\r\n/* 81: */ {\r\n/* 82:107 */ filters.put(\"numero\", String.valueOf(getDimension()));\r\n/* 83: */ }", "public static WFJFilterMap[] findFilterMaps() {\n return filterMaps.asArray();\n }", "private Map<String, PermissionType> getPermissionTypeMapForLabelToMaskChange() {\n\t\tMap<String, PermissionType> permissionTypeMap = new LinkedHashMap<String, PermissionType>();\n\n\t\tList<PermissionType> permissionTypes = permissionTypeRepo.findAll();\n\t\tfor (int i = 0; i < permissionTypes.size(); i++) {\n\t\t\tpermissionTypeMap.put(permissionTypes.get(i).getName(), permissionTypes.get(i));\n\t\t}\n\t\treturn permissionTypeMap;\n\t}", "synchronized public Map<String, Set<String>> getTypes() {\n return Collections.unmodifiableMap(\n new HashSet<>(types.entrySet()).stream()\n .collect(Collectors.toMap(\n Map.Entry::getKey,\n e -> Collections.unmodifiableSet(new HashSet<>(e.getValue()))\n ))\n );\n }", "public Map<FruitType, List<Fruit>> groupByType_lambda() {\n\t\treturn fruits.stream().collect(Collectors.groupingBy(f -> f.getType()));\n\t}", "private static HashMap<String, String> initMapping()\n {\n HashMap<String, String> typeMapping = new HashMap<String, String>();\n\n typeMapping.put(\"boolean\", \"boolean\");\n typeMapping.put(\"float\", \"float\");\n typeMapping.put(\"double\", \"double\");\n typeMapping.put(\"byte\", \"byte\");\n typeMapping.put(\"unsignedByte\", \"short\");\n typeMapping.put(\"short\", \"short\");\n typeMapping.put(\"unsignedShort\", \"int\");\n typeMapping.put(\"int\", \"int\");\n typeMapping.put(\"integer\", \"java.math.BigDecimal\");\n typeMapping.put(\"positiveInteger\", \"java.math.BigInteger\");\n typeMapping.put(\"unsignedInt\", \"java.math.BigInteger\");\n typeMapping.put(\"long\", \"java.math.BigInteger\");\n typeMapping.put(\"unsignedLong\", \"java.math.BigDecimal\");\n typeMapping.put(\"decimal\", \"java.math.BigDecimal\");\n typeMapping.put(\"string\", \"String\");\n typeMapping.put(\"hexBinary\", \"byte[]\");\n typeMapping.put(\"base64Binary\", \"byte[]\");\n typeMapping.put(\"dateTime\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"time\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"date\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"gDay\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"gMonth\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"gMonthDay\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"gYear\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"gYearMonth\", \"javax.xml.datatype.XMLGregorianCalendar\");\n typeMapping.put(\"duration\", \"javax.xml.datatype.Duration\");\n typeMapping.put(\"NOTATION\", \"javax.xml.namespace.QName\");\n typeMapping.put(\"QName\", \"javax.xml.namespace.QName\");\n typeMapping.put(\"anyURI\", \"String\");\n typeMapping.put(\"Name\", \"String\");\n typeMapping.put(\"NCName\", \"String\");\n typeMapping.put(\"negativeInteger\", \"java.math.BigDecimal\");\n typeMapping.put(\"NMTOKEN\", \"String\");\n typeMapping.put(\"nonNegativeInteger\", \"java.math.BigDecimal\");\n typeMapping.put(\"nonPositiveInteger\", \"java.math.BigDecimal\");\n typeMapping.put(\"normalizedString\", \"String\");\n typeMapping.put(\"token\", \"String\");\n typeMapping.put(\"any\", \"Object\");\n\n return typeMapping;\n }", "java.lang.String getDataItemFilter();", "public static Map<String, Byte> genNameToTypeMap(){\n byte[] types = genAllTypes();\n String[] names = genAllTypeNames();\n Map<String, Byte> ret = new HashMap<String, Byte>();\n for(int i=0;i<types.length;i++){\n ret.put(names[i], types[i]);\n }\n return ret;\n }", "com.google.protobuf.ByteString getDataItemFilterBytes();", "public static BookFilter getDictionaries()\n {\n return new BookCategoryFilter(BookCategory.DICTIONARY);\n }", "public static Map<String, String> filterFieldParametersTypes(final String packageName,\n final Imports imports,\n final Map<String, String> projectFieldParametersTypes) {\n final Map<String, String> scopedFieldParametersType = new HashMap<String, String>();\n for (Map.Entry<String, String> e : projectFieldParametersTypes.entrySet()) {\n String fieldName = e.getKey();\n String fieldType = e.getValue();\n final String fFieldName = getFieldNameFromEnumeration(fieldName);\n\n final String fFieldName_QualifiedType = getQualifiedTypeFromEnumeration(fieldName);\n final String fFieldName_PackageName = getPackageName(fFieldName_QualifiedType);\n final String fFieldName_TypeName = getTypeName(fFieldName_QualifiedType);\n if (fFieldName_PackageName.equals(packageName) || isImported(fFieldName_QualifiedType,\n imports)) {\n fieldName = fFieldName_TypeName;\n }\n\n final String fFieldType_QualifiedType = getQualifiedTypeFromEnumeration(fieldType);\n final String fFieldType_PackageName = getPackageName(fFieldType_QualifiedType);\n final String fFieldType_TypeName = getTypeName(fFieldType_QualifiedType);\n if (fFieldType_PackageName.equals(packageName) || isImported(fFieldType_QualifiedType,\n imports)) {\n fieldType = fFieldType_TypeName;\n }\n\n scopedFieldParametersType.put(fieldName + \"#\" + fFieldName,\n fieldType);\n }\n return scopedFieldParametersType;\n }", "public Map<FruitType, List<Fruit>> groupByType() {\n\t\treturn fruits.stream().collect(Collectors.groupingBy(Fruit::getType));\n\t}", "Hashtable createTypeMapping()\n {\n Hashtable mapping = new Hashtable();\n \n mapping.put(TypeFactory.getType(\"Double\"), \n new ParameterFactory() \n {\n public Parameter getParameter(Object o) \n {\n StratmasDecimal sObj = (StratmasDecimal) o;\n if (isBadDecimal(sObj)) {\n return null;\n } else {\n return new StratmasDecimalParameter((StratmasDecimal) o);\n }\n }\n });\n mapping.put(TypeFactory.getType(\"double\", \"http://www.w3.org/2001/XMLSchema\"), \n new ParameterFactory() \n {\n public Parameter getParameter(Object o) \n {\n StratmasDecimal sObj = (StratmasDecimal) o;\n if (isBadDecimal(sObj)) {\n return null;\n } else {\n return new StratmasDecimalParameter((StratmasDecimal) o);\n }\n }\n });\n mapping.put(TypeFactory.getType(\"NonNegativeInteger\"), \n new ParameterFactory() \n {\n public Parameter getParameter(Object o) \n {\n return new StratmasIntegerParameter((StratmasInteger) o);\n }\n });\n // Ground type type hiearchy.\n mapping.put(TypeFactory.getType(\"anyType\", \"http://www.w3.org/2001/XMLSchema\"), \n new ParameterFactory() \n {\n public Parameter getParameter(Object o) \n {\n return null;\n }\n });\n\n return mapping;\n }", "public <T> Map<MDSKey, T> listKV(MDSKey startId, @Nullable MDSKey stopId, Type typeOfT, int limit,\n Predicate<T> filter) {\n return listKV(startId, stopId, typeOfT, limit, null, filter);\n }", "public Map<String, Boolean> getIsTypeOptionValidMap() {\n if (typeOptionValidMap == null) {\n typeOptionValidMap = new HashMap<String, Boolean>() {\n @Override\n public Boolean get(Object key) {\n return !(key == null || \"\".equals(key.toString().trim()) || countKeyOccurence(typeOptions, (String) key) > 1);\n }\n };\n }\n return typeOptionValidMap;\n }", "Map<ParameterInstance, SetType> getInstanceSetTypes();", "public Map<FruitType, List<Fruit>> groupByTypeConcrrently() {\n\t\treturn fruits.parallelStream().collect(Collectors.groupingByConcurrent(Fruit::getType));\n\t}", "public static interface KeyValueFilter {\r\n\t}", "public static Map<Byte, String> genTypeToNameMap(){\n byte[] types = genAllTypes();\n String[] names = genAllTypeNames();\n Map<Byte,String> ret = new HashMap<Byte, String>();\n for(int i=0;i<types.length;i++){\n ret.put(types[i], names[i]);\n }\n return ret;\n }", "public <T> Map<MDSKey, T> listKV(MDSKey startId, @Nullable MDSKey stopId, Type typeOfT, int limit,\n Predicate<MDSKey> keyFilter, Predicate<T> valueFilter) {\n byte[] startKey = startId.getKey();\n byte[] stopKey = stopId == null ? Bytes.stopKeyForPrefix(startKey) : stopId.getKey();\n\n Scan scan = new Scan(startKey, stopKey);\n return listKV(scan, typeOfT, limit, keyFilter, valueFilter);\n }", "public void getAllAttributeTypesKeys(Set<String> all, ItemFilter<IAttributeType<?>> filter);", "public Map<String, String> getDocFieldsVsDataTypeMap() {\n\t\treturn docFieldsVsDataTypeMap;\n\t}", "private Map<String, Object> analysisMap(ArrayList<String> data) {\n Map<String, Object> map = new HashMap<>();\n map.put(DAILY, data);\n return map;\n }", "public Map<TypeQuantity, List<Fruit>> groupByTypeQuantity(){\n\t\treturn fruits.stream().collect(Collectors.groupingBy( fruit -> new TypeQuantity(fruit.getType(), fruit.getQuantity())));\n\t}", "public Map<String, Boolean> getFilteringResults() {\n return filteringResults;\n }", "private Map getKeyFields ()\n\t\t\t{\n\t\t\t\tModel model = getModel();\n\t\t\t\tString pcClassName = getClassName();\n\t\t\t\tPersistenceClassElement pce = \n\t\t\t\t\tmodel.getPersistenceClass(pcClassName);\n\t\t\t\tPersistenceFieldElement[] fields = pce.getFields();\n\t\t\t\tMap keyFields = new HashMap();\n\n\t\t\t\tif (fields != null)\n\t\t\t\t{\n\t\t\t\t\tfor (int i = 0; i < fields.length; i++)\n\t\t\t\t\t{\n\t\t\t\t\t\tPersistenceFieldElement pfe = fields[i];\n\t\t\t\t\t\tif (pfe.isKey())\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tString name = pfe.getName();\n\t\t\t\t\t\t\tkeyFields.put(name, \n\t\t\t\t\t\t\t\tmodel.getField(pcClassName, name));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\treturn keyFields;\n\t\t\t}", "public Map<String, Integer> getMappings() {\n return mappingPredicateToInt;\n }", "public Map<String, String> getColumnsMap() {\n\t\treturn columnsVsDataTypeMap;\n\t}", "public HashMap<String, Object> convert() {\n HashMap<String, Object> condMap = new HashMap<String, Object>();\n condMap.put(CommonSpecification.PARAMETERS, paramList);\n condMap.put(CommonSpecification.FETCH_TABLES, fetchTables);\n condMap.put(CommonSpecification.JOIN_TABLES, joinTables);\n condMap.put(CommonSpecification.SORT, sort);\n return condMap;\n }", "Map<String, PrimitiveTypeProvider> convert(T data);", "public Map<FruitType, Long> groupByTypeWithCounts() {\n\t\treturn fruits.stream().collect(Collectors.groupingBy(Fruit::getType, Collectors.counting()));\n\t}", "public Map<FruitType, Map<Integer, List<Fruit>>> groupByTypeAndLike_2() {\n\t\treturn fruits.stream()\n\t\t\t\t.collect(Collectors.groupingBy(Fruit::getType, Collectors.groupingBy(Fruit::getLikes)));\n\t}", "public Map<String, Set<Object>> getPrimaryFilters() {\n return primaryFilters;\n }", "public Map<String, FieldType> flatten() {\n if (fields == null || fields.length == 0) {\n return Collections.<String, FieldType> emptyMap();\n }\n\n Map<String, FieldType> map = new LinkedHashMap<String, FieldType>();\n\n for (Field nestedField : fields) {\n addSubFieldToMap(map, nestedField, null);\n }\n\n return map;\n }", "List<String> getFilters();", "HashMap<Value, HashSet<Value>> getLayerDatasetDescriptions();", "public List<String> getDataPointTypes() {\n Object[] dpTypes = (Object[])configMap.get(DATA_POINT_TYPES);\n List<String> types = Utility.downcast( dpTypes );\n return types;\n }", "@ZenCodeType.Caster\n @ZenCodeType.Method\n default Map<String, IData> asMap() {\n \n return notSupportedCast(\"IData[string]\");\n }", "@Override\n public HashMap<String, String> getFilterTerms() {\n HashMap<String, String> filterTerms = new HashMap<>();\n if (countryCheckBox.isSelected()) {\n filterTerms.put(\"Country\", countryField.getText());\n }\n if (cityCheckBox.isSelected()) {\n filterTerms.put(\"City\", cityField.getText());\n }\n return filterTerms;\n }", "Map<String, Field> extensionFieldsMap() {\n Map<String, Field> extensionsForType = new LinkedHashMap<>();\n for (Field field : extensionFields) {\n extensionsForType.put(field.qualifiedName(), field);\n }\n return extensionsForType;\n }", "private ListMap<String, String> slurpFilters(final File vcf) {\n final ListMap<String, String> map = new ListMap<>();\n final VCFFileReader in = new VCFFileReader(vcf, false);\n for (final VariantContext ctx : in) {\n if (ctx.isNotFiltered()) continue;\n for (final String filter : ctx.getFilters()) {\n map.add(ctx.getID(), filter);\n }\n }\n in.close();\n return map;\n }", "public Map<String, List<Fruit>> groupByTypeAndLike() {\n\t\treturn fruits.stream().collect(Collectors.groupingBy(Fruit::getTypeLikes));\n\t}", "java.util.Map<java.lang.String, java.lang.String>\n getFieldMap();", "ColumnInfoFilter getColumnInfoFilter();", "private Map<String, DataContainer> getDataContainerMap() {\r\n\r\n if (this.dataContainerMap == null) {\r\n if (this.dataContainerList == null) {\r\n parse();\r\n }\r\n\r\n this.dataContainerMap = new HashMap<>();\r\n for (DataContainer dataContainer : this.dataContainerList) {\r\n this.dataContainerMap.put(dataContainer.getVariableName(), dataContainer);\r\n }\r\n }\r\n return this.dataContainerMap;\r\n }", "public List<Pair<ResolvedTypeParameterDeclaration, ResolvedType>> getTypeParametersMap() {\n List<Pair<ResolvedTypeParameterDeclaration, ResolvedType>> typeParametersMap = new ArrayList<>();\n if (!isRawType()) {\n for (int i = 0; i < typeDeclaration.getTypeParameters().size(); i++) {\n typeParametersMap.add(new Pair<>(typeDeclaration.getTypeParameters().get(i), typeParametersValues().get(i)));\n }\n }\n return typeParametersMap;\n }", "public abstract Map<String, Integer> getColumnTypes(String tableName);", "public Set<String> getDataKeys() {\r\n\t\treturn data.keySet();\r\n\t}", "protected static Map<String, Object> prepareQueryForSelection(JsonObject parameters) {\n Map<String, Object> queryFilters = new HashMap<String, Object>();\n\n // Date fields\n processDateFilter(Entity.CREATION_DATE, parameters, queryFilters);\n processDateFilter(Entity.MODIFICATION_DATE, parameters, queryFilters);\n\n // String fields\n processStringFilter(Consumer.EMAIL, parameters, queryFilters);\n processStringFilter(Consumer.JABBER_ID, parameters, queryFilters);\n processStringFilter(Consumer.NAME, parameters, queryFilters);\n processStringFilter(Consumer.TWITTER_ID, parameters, queryFilters);\n\n // Long fields\n processLongFilter(Consumer.FACEBOOK_ID, parameters, queryFilters);\n\n return queryFilters;\n }", "@RequestMapping(value=\"/datatypes\",method=RequestMethod.GET)\n public DataFieldType[] getAllDataTypes(){\n return DataFieldType.values();\n }", "String getTypeFilter(String column, Collection<FxType> types);", "public static Map<String, Object> mapData(Object data) {\n\t\tMap<String, Object> modelMap = new HashMap<String,Object>(2);\n\t\tmodelMap.put(\"data\", data);\n\t\tmodelMap.put(\"success\", true);\n\t\t\n\t\treturn modelMap;\n\t}", "public static interface GetFilter extends KeyValueFilter {\r\n\t\tObject get(String name);\r\n\t}", "public Map<Integer, Data> getDataMap() {\n Map<Integer, Data> result = new HashMap<Integer, Data>();\n for (Integer varIndex : _dataMap.keySet()) {\n List<Data> dataList = _dataMap.get(varIndex);\n result.put(varIndex, dataList.get(dataList.size() - 1));\n }\n return result;\n }", "public void filterByDataType(HashMap<String, String> filterTerms) {\n filterer.filterAirports(filterTerms, storage.getAirports());\n }", "private static Map<String, String> getColumnsToFieldsMap() {\n final Map<String, String> columnsToFieldsMap = new HashMap<>();\n\n columnsToFieldsMap.put(TABLET_SESSION_TABLE_WETTKAMPF_ID, TABLET_SESSION_BE_WETTKAMPF_ID);\n columnsToFieldsMap.put(TABLET_SESSION_TABLE_SCHEIBENNUMMER, TABLET_SESSION_BE_SCHEIBENNUMMER);\n columnsToFieldsMap.put(TABLET_SESSION_TABLE_MATCH_ID, TABLET_SESSION_BE_MATCH_ID);\n columnsToFieldsMap.put(TABLET_SESSION_TABLE_SATZNUMMER, TABLET_SESSION_BE_SATZNUMMER);\n columnsToFieldsMap.put(TABLET_SESSION_TABLE_IS_ACTIVE, TABLET_SESSION_BE_IS_ACTIVE);\n columnsToFieldsMap.put(TABLET_SESSION_TABLE_ACCESS_TOKEN, TABLET_SESSION_BE_ACCESS_TOKEN);\n\n // add technical columns\n columnsToFieldsMap.putAll(BasicDAO.getTechnicalColumnsToFieldsMap());\n\n return columnsToFieldsMap;\n }", "protected abstract Map<String, Serializable> getEventKeyAndIdMap();", "public List<SysDictData> selectDictDataByType(String dictType);", "public Map<Integer, Boolean> getFilter(Geometry geom) throws SQLException {\n return retrieveExpected(createNativeFilterStatement(geom), BOOLEAN);\n }", "private VariableMap getParamMappingAsVariableMap() {\n paramValueEncodings.put(fileNameToIndex.keySet().toString(), \" FileNames\");\n paramValueEncodings.put(functionNameToIndex.keySet().toString(), \" FunctionNames\");\n paramValueEncodings.put(typeToIndex.keySet().toString(), \" Types\");\n\n VariableMap preInversedMap = new VariableMap(paramValueEncodings);\n ImmutableMap<String, String> inversedMap = preInversedMap.getNewNameToOriginalNameMap();\n return new VariableMap(inversedMap);\n }", "public DataTableFilterType getFilterType( )\n {\n return _filterType;\n }", "protected abstract Map<String, Map<String, Object>> getData(String columnFamilyName);", "public DDataFilter() {\n filters = new ArrayList<>();\n operator = null;\n value = null;\n externalData = false;\n valueTo = null;\n attribute = ROOT_FILTER;\n }", "@Override\n public Map<String, ? extends FilterRegistration> getFilterRegistrations() {\n return null;\n }", "private HashMap<String,String> createQueryMap() {\n\t\t\n\t\tHashMap<String, String> map = new HashMap<String, String>();\n\t\t\n\t\t// Only include Pages with the CenterNet Event template\n\t\tmap.put(\"type\",\"cq:Page\");\n\t\tmap.put(\"path\", Constants.EVENTS);\n\t\tmap.put(\"property\",\"jcr:content/cq:template\");\n\t map.put(\"property.value\", Constants.EVENT_TEMPLATE);\n\n\t if (tags != null) {\n\t \tmap = addTagFilter(map);\n\t }\n\n\t // Only include Events whose start time is in the future\n\t map.put(\"relativedaterange.property\", PN_QUERY_START_TIME);\n\t map.put(\"relativedaterange.lowerBound\", \"-0d\");\n\t \n\t // Include all hits\n\t //map.put(\"p.limit\", maxNum.toString());\n\t map.put(\"p.limit\", maxNum);\n\t map.put(\"p.guessTotal\", \"true\");\n\t \n\t // Order by Start Time\n\t map.put(\"orderby\", PN_QUERY_START_TIME);\n\t map.put(\"orderby.sort\", \"asc\");\n\t \n\t\treturn map;\n\t\t\n\t}", "@Override\r\n\t\tpublic Map<String, Class<?>> getTypeMap() throws SQLException {\n\t\t\treturn null;\r\n\t\t}", "public Map<String, String> addFilterValue(String filterCriteria, String filterValue);", "public static Map<String, Boolean> filterEventTypes(final String packageName,\n final Imports imports,\n final Map<String, Boolean> projectEventTypes) {\n final Map<String, Boolean> scopedEventTypes = new HashMap<String, Boolean>();\n for (Map.Entry<String, Boolean> e : projectEventTypes.entrySet()) {\n final String eventQualifiedType = e.getKey();\n final String eventPackageName = getPackageName(eventQualifiedType);\n final String eventTypeName = getTypeName(eventQualifiedType);\n\n if (eventPackageName.equals(packageName) || isImported(eventQualifiedType,\n imports)) {\n scopedEventTypes.put(eventTypeName,\n e.getValue());\n }\n }\n return scopedEventTypes;\n }", "public Map<EventKey, EventMethod> createEventMap() {\n\t\tfinal Map<EventKey, EventMethod> eventMap = new EnumMap<>(EventKey.class);\n\t\tfinal Pair<Map<String, Object>, Set<Class<?>>> eventPair = prepareEventPair();\n\n\t\tfor (Class<?> eventClass : eventPair.getSecond()) {\n\t\t\tfor (Method eventMethod : prepareEventMethods(eventClass)) {\n\t\t\t\teventMap.put(eventMethod.getAnnotation(EventMapping.class).key(),\n\t\t\t\t\t\tnew EventMethod(eventPair.getFirst().get(eventClass.getName()), eventMethod));\n\t\t\t}\n\t\t}\n\t\treturn eventMap;\n\t}", "public HashMap<String,String> filterDataForVerification(HashMap<String, String> data)\n {\n\n HashMap<String, String> fillter = new HashMap<String, String>();\n\n //add medical condition description\n String medicalConditionDescription =\n getMedicalConditionDescription(data.get(\"medical_condition_id\"));\n fillter.put(\"medical_condition_description\", medicalConditionDescription);\n\n\n //add medication name\n String medicationName = getMedicationName( data.get(\"medication_num\"));\n\n fillter.put(\"medication_name\", medicationName);\n\n for (String key : data.keySet()) {\n if (key.equals(\"first_name\") || key.equals(\"last_name\") || key.equals(\"street\") ||\n key.equals(\"home_phone_number\") || key.equals(\"email_address\")\n || key.equals(\"house_number\") || key.equals(\"contact_phone\") ||\n key.equals(\"zip_code\") || key.equals(\"birth_date\") || key.equals(\"city\") ||\n key.equals(\"mobile_phone_number\") || key.equals(\"state\")\n || key == \"dosage\")\n fillter.put(key,data.get(key));\n\n if (key.equals(\"gender\"))\n fillter.put(key,convertCodeToGender(data.get(key)));\n }\n return fillter;\n }", "protected Map<String, String> getFeatureAttrs(Map<String, Object> data) {\n\t\treturn null;\n\t}", "public Hashtable getDataTypeDefinitions() {\n return ComponentHelper.getComponentHelper(this).getDataTypeDefinitions();\n }", "public Map<FruitType, Set<Fruit>> groupByTypeToSet() {\n\t\treturn fruits.stream().collect(Collectors.groupingBy(Fruit::getType, Collectors.toSet()));\n\t}", "public List<COSName> getFilters() {\n/* 312 */ List<COSName> retval = null;\n/* 313 */ COSBase filters = this.stream.getFilters();\n/* 314 */ if (filters instanceof COSName) {\n/* */ \n/* 316 */ COSName name = (COSName)filters;\n/* 317 */ retval = new COSArrayList<COSName>(name, (COSBase)name, (COSDictionary)this.stream, COSName.FILTER);\n/* */ }\n/* 319 */ else if (filters instanceof COSArray) {\n/* */ \n/* 321 */ retval = ((COSArray)filters).toList();\n/* */ } \n/* 323 */ return retval;\n/* */ }", "public Map<String, Object> allFields() {\n Map<String, Object> map = new HashMap<>();\n properties.forEach((key, value) -> map.put(key, value.value()));\n return map;\n }", "@Override\n\tpublic Map<String, Class<?>> getKeysMap(String entitySetName) {\n\t\treturn null;\n\t}", "public String getTypeFilter()\r\n\t{\r\n\t\treturn this.typeFilter;\r\n\t}", "public String getCutypeMapping();", "public Map<String, StatisticsEventConfig> getTypeView() {\n return classToEventMap;\n }", "public HashMap<CellID, Set<MetadataID> > searchMetadata(MetadataSearchFilters filters){\n // pass in a listener to notify, rather than sending directly to a connection\n logger.log(Level.INFO, \"[META SERVICE] global search with \" + filters.filterCount() + \" filters\");\n return db.searchMetadata(filters);\n }", "protected List<Tuple<Operator, Property>> getPropertyFilters() {\n if (properties == null) {\n EntityDescriptor ed = getDescriptor();\n properties = filters.stream()\n .map(filter -> Tuple.create(filter.getFirst(), ed.getProperty(filter.getSecond())))\n .toList();\n }\n\n return Collections.unmodifiableList(properties);\n }", "protected Set<String> filterColumns() {\n return columnSelectionMap.keySet();\n }", "protected Map getKeyMethodMap() {\n\t\tHashMap<String, String> map = new HashMap<String, String>();\n\t\tmap.put(\"cmd.planilla.lista\", \"lista\");\n\t\tmap.put(\"cmd.planilla.buscar\", \"buscar\");\n\t\tmap.put(\"cmd.planilla.verificar\", \"verificar\");\n\t\tmap.put(\"cmd.planilla.cargar\", \"cargar\");\n\t\tmap.put(\"cmd.planilla.actualizar\", \"actualizar\");\n\t\tmap.put(\"cmd.planilla.generar\", \"generar\");\n\t\tmap.put(\"cmd.planilla.cargaFin\", \"cargaFin\");\n\t\tmap.put(\"cmd.planilla.descEmpleadoFiador\", \"descEmpleadoFiador\");\n\t\tmap.put(\"cmd.planilla.verReporte\", \"verReporte\");\n\t\treturn map;\n\t}", "public Map<String, Set<String>> getBufferedDeviceNamesByType();", "public HashMap<String,HashSet<String>> loadTypes(String typeFromO1, String typeFromO2) throws Exception;", "public static Collection<DataType> values() {\n return values(DataType.class);\n }", "static Map<String, Set<IpAccessList>> getSpecifiedFilters(\n FilterLineReachabilityQuestion question, SpecifierContext ctxt) {\n Set<String> specifiedNodes = question.nodeSpecifier().resolve(ctxt);\n FilterSpecifier filterSpecifier = question.filterSpecifier();\n\n return CommonUtil.toImmutableMap(\n specifiedNodes,\n Function.identity(),\n node ->\n filterSpecifier.resolve(node, ctxt).stream()\n .filter(f -> !(question.getIgnoreComposites() && f.isComposite()))\n .collect(ImmutableSet.toImmutableSet()));\n }", "protected Map<Data, String> input() {\n Set<String> inputs = new HashSet<>();\n\n for (Importer importer : importers()) {\n inputs.add(importer.inputData().name());\n }\n\n return DynamicData.oneToOne(inputs.toArray(new String[inputs.size()]));\n }", "public Collection findPartnerFunctionsKeys(IDataFilter filter)\n throws FindEntityException, SystemException, RemoteException;", "public Map<String, VisualizationStyleParameter> getChangedParameterKeyToParameterMap()\r\n {\r\n return myChangedParameterSet.stream().collect(Collectors.toUnmodifiableMap(v -> v.getKey(), v -> v));\r\n }", "public static Map<String, TypeSource> filterTypeSources(final String packageName,\n final Imports imports,\n final Map<String, TypeSource> projectTypeSources) {\n final Map<String, TypeSource> scopedTypeSources = new HashMap<String, TypeSource>();\n for (Map.Entry<String, TypeSource> e : projectTypeSources.entrySet()) {\n final String typeQualifiedType = e.getKey();\n final String typePackageName = getPackageName(typeQualifiedType);\n final String typeTypeName = getTypeName(typeQualifiedType);\n\n if (typePackageName.equals(packageName) || isImported(typeQualifiedType,\n imports)) {\n scopedTypeSources.put(typeTypeName,\n e.getValue());\n }\n }\n return scopedTypeSources;\n }" ]
[ "0.76258355", "0.70229554", "0.6469499", "0.59711355", "0.5936576", "0.5879043", "0.5808969", "0.5771268", "0.57519364", "0.5653655", "0.56477433", "0.56206304", "0.556525", "0.55449355", "0.54803115", "0.54283553", "0.5361958", "0.5358234", "0.53071016", "0.5305817", "0.5294964", "0.529271", "0.5290902", "0.52679247", "0.52663934", "0.5258158", "0.5236942", "0.5209064", "0.51869595", "0.51781094", "0.5171486", "0.51511145", "0.51505524", "0.51269305", "0.5120441", "0.51054615", "0.51021135", "0.50939035", "0.5065514", "0.50643307", "0.5049508", "0.50439465", "0.5041938", "0.50283253", "0.5026535", "0.50230324", "0.50212586", "0.5020086", "0.50190467", "0.5017471", "0.5003768", "0.49973413", "0.4996045", "0.49957624", "0.4982522", "0.49716097", "0.4968035", "0.4960188", "0.49563235", "0.49542585", "0.49384934", "0.49343854", "0.493059", "0.49257874", "0.49177524", "0.491149", "0.4907098", "0.49042588", "0.48919383", "0.4882607", "0.48799613", "0.4874618", "0.4862429", "0.48591283", "0.48566946", "0.48459947", "0.48448303", "0.48343042", "0.48342347", "0.4822124", "0.481766", "0.47999248", "0.47977954", "0.47974262", "0.47843876", "0.47772506", "0.47696143", "0.4765491", "0.4764081", "0.47632372", "0.4758585", "0.47554383", "0.47445247", "0.47421739", "0.4740202", "0.4736796", "0.47339186", "0.4732462", "0.47319406", "0.47269866" ]
0.679472
2
Removes all my geometries from geometry registry.
private void removeAllQueryBoundsFromGeometryRegistry() { myToolbox.getGeometryRegistry().removeGeometriesForSource(this); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public void freeGeometries(){\n\t\tfinal int size = this.geometries.size();\n\t\tfor(int index=0; index < size; index++){\n\t\t\tfinal int key = this.geometries.keyAt(index);\n\t\t\tthis.geometries.get(key).free();\n\t\t\tthis.geometries.delete(key);\n\t\t}\n\t}", "public final synchronized void clearGeometry() {\n synchronized (this) {\n this.f718B8WBXPBCF2jGfUDZZU2zV5EYdqbUBu0lAZ0THCEqYyuE8VACR9dY7rDnwBIqh64T = null;\n this.f719hxYOFxFjLpN1maJuWNxUV40nExCGxsxkDPOTgtzMu4zlZCQb3bPlKsXo1SYJg6ME = null;\n }\n }", "public void clearAll()\n {\n textureMap.clear();\n componentMap.clear();\n }", "public void clearAll() {\n\n\t\t// Removing the graphics from the layer\n\t\trouteLayer.removeAll();\n\t\t// hiddenSegmentsLayer.removeAll();\n\t\tmMapViewHelper.removeAllGraphics();\n\t\tmResults = null;\n\n\t}", "public void clearAllGraphics()\r\n {\r\n graphics.clear();\r\n fullExtent = null;\r\n }", "public void clearFeatures() {\n localFeatureVector.clear();\n }", "public void close()\n {\n myListenerHelper.close();\n mySpecializedProcessorsLock.writeLock().lock();\n try\n {\n myRenderableGeometryProcessors.clear();\n myProjectionSensitiveProcessors.clear();\n }\n finally\n {\n mySpecializedProcessorsLock.writeLock().unlock();\n }\n myProcessorsLock.writeLock().lock();\n try\n {\n for (final GeometryProcessor<? extends Geometry> proc : myGeometryProcessorsMap.values())\n {\n myProcessorBuilder.getPickManager().removeGeometries(proc.getGeometries());\n proc.close();\n }\n myGeometryProcessorsMap.clear();\n myInactiveGeometries.clear();\n recalculateCoveredTimeSpans();\n myGeometryProcessorsSnapshot = Collections.emptyList();\n }\n finally\n {\n myProcessorsLock.writeLock().unlock();\n }\n\n myUnprocessedGeometryLock.lock();\n try\n {\n removeTimeListeners();\n }\n finally\n {\n myUnprocessedGeometryLock.unlock();\n }\n }", "public void clearShapes() {\n\t\tcollectionOfNodes.clear();\n\t}", "void clearShapeMap();", "public void clear(){\n this.entities.clear();\n /*for(QuadTree node: this.getNodes()){\n node.clear();\n this.getNodes().remove(node);\n }*/\n this.nodes.clear();\n }", "public void clear() {\n \tthis.listShapes.clear();\n }", "public static void clearAllMeshes (Application app) {\r\n \t\tmeshes.remove(app);\r\n \t}", "void clearFeatures();", "private void clearAll( )\n {\n for( Vertex v : vertexMap.values( ) )\n v.reset( );\n }", "public void destroy() {\n\t\tfor (ANodeAttributeRenderer attributeRenderer : attributeRenderers) {\n\t\t\tattributeRenderer.unregisterPickingListeners();\n\t\t}\n\t}", "public void destroyForAll() {\n super.destroyForAll();\n }", "private void clean() {\n nodesToRemove.clear();\n edgesToRemove.clear();\n }", "public synchronized void unRegisterAll()\r\n {\r\n clearNameObjectMaps();\r\n }", "public void clear() {\n\t\t//Kill all entities\n\t\tentities.parallelStream().forEach(e -> e.kill());\n\n\t\t//Clear the lists\n\t\tentities.clear();\n\t\tdrawables.clear();\n\t\tcollidables.clear();\n\t}", "public void cleanUp(){\n for(ShaderProgram sp : shaderlist){\n sp.cleanup();\n }\n }", "public void clearMapLayers() {\n if(internalNative != null) {\n internalNative.removeAllMarkers();\n markers.clear();\n } else {\n if(internalLightweightCmp != null) {\n internalLightweightCmp.removeAllLayers();\n points = null;\n } else {\n // TODO: Browser component \n }\n }\n }", "public void clear() {\n this.layers.clear();\n list.clear();\n }", "@Override\n\tpublic void clear() {\n\t\tsuper.clear();\n\t\tidIndex = new HashMap<String, SimpleFeature>();\n\t\ttypeNameIndex = new HashMap<Name, Set<SimpleFeature>>();\n\t\ttileIndex = new HashMap<OSMTile, Set<SimpleFeature>>();\n\t}", "public void clear() {\n\t\tthis._cooccurenceMatrix = null;\n\t\tthis._modules.clear();\n\t\tthis._vertices.clear();\n\t}", "static void wipeLocations(){\n\t \tfor (int i= 0; i < places.length; i++){\n\t\t\t\tfor (int j = 0; j < places[i].items.size(); j++)\n\t\t\t\t\tplaces[i].items.clear();\n\t\t\t\tfor (int k = 0; k < places[i].receptacle.size(); k++)\n\t\t\t\t\tplaces[i].receptacle.clear();\n\t \t}\n\t \tContainer.emptyContainer();\n\t }", "public void clearRegistry() {\r\n implementedDatabases.clear();\r\n }", "public void clear() {\n\t\tshapes.clear();\n\t\tgroupedShapes.clear();\n\t\tthis.repaint();\n\t\tcounter = 0;\n\t\tnotifyObservers();\n\t}", "public void cleanup() {\n\t\tref.removeEventListener(listener);\n\t\tmodels.clear();\n\t\tmodelNames.clear();\n\t\tmodelNamesMapping.clear();\n\t}", "public void resetWorld() {\n \t\tmyForces.clear();\n \t\t\n \t\tfor (CollidableObject obj : myObjects) {\n \t\t\tobj.detach();\n \t\t}\n \t\tmyObjects.clear();\n \t\t\n \t\taddHalfspaces();\n \t}", "@Override\n public void cleanup(GL2 gl)\n {\n for(int i = 0; i < 6; i++)\n {\n Integer t_id = (Integer)textureIdMap[i].remove(gl);\n if(t_id != null)\n {\n int tex_id_tmp[] = { t_id.intValue() };\n gl.glDeleteTextures(1, tex_id_tmp, 0);\n }\n }\n }", "public synchronized void clearResources()\r\n {\r\n // create a new root, making old tree eligible for GCing\r\n createRootNode();\r\n\r\n // clear all registered objects\r\n unRegisterAll();\r\n }", "public static void clearWorld() {\r\n \tbabies.clear();\r\n \tpopulation.clear();\r\n }", "public void clear() {\n\t\tthis.boundObjects.clear();\n\t}", "public void destroy() {\n for (ComponentBean component : this.componentMap.values()) {\n component.getObject().destroy();\n }\n\n flushRegistry();\n\n }", "public void freeGeometry(final int id){\n\t\t//android.util.Log.d(TAG,\"freeGeometry(\"+id+\")\");\n\t\tthis.geometries.get(id).free();\n\t}", "public void purgeQueue() {\r\n\t\tfDirtyRegions.clear();\r\n\t}", "public void clear()\r\n {\r\n this.boundObjects.clear();\r\n }", "public static void clearRegistry() {\r\n\t\tINTERPRETERS.clear();\r\n\t}", "protected void deleteSelectedCurves() {\n\t\tfor (int j = 0; j < selectedCurves.size(); ++j) {\n\t\t\tif (j == 0)\n\t\t\t\tpush();\n\n\t\t\tselectionTool.deleteCurve(selectedCurves.elementAt(j));\n\t\t}\n\n\t\tselectedCurves.clear();\n\t\tselectedPoints.clear();\n\t}", "public void clear() {\n\t\tsystems.clear();\n\t}", "public void clear(){\n\t\tfor (LinkedList<Line> list : lineLists){\n\t\t\tfor (Line l : list){\n\t\t\t\tpane.getChildren().remove(l);\n\t\t\t}\n\t\t\tlist.clear();\n\t\t}\n\t\tfor (Line l : bezierCurve){\n\t\t\tpane.getChildren().remove(l);\n\t\t}\n\t\tbezierCurve.clear();\n\t\t\n\t\tlineLists.clear();\n\t\tlineLists.add(new LinkedList<Line>());\n\t}", "public void cleanUp(){\n glDeleteTextures(ID);\n }", "public void deleteAll(){\n editor.clear();\n editor.apply();\n }", "void clearTypedFeatures();", "public void clearGame() {\n\t\tselectedObjects.clear();\n\t}", "public void free(){\n\t\t//android.util.Log.d(TAG,\"free()\");\n\t\tthis.freeGeometries();\n\t\tthis.freeLights();\n\t\tthis.freeCameras();\n\t\tthis.freeTextures();\n\t\tthis.freeMaterials();\n\t}", "private void removeAllObjects()\n {\n removeObjects (getObjects(Actor.class));\n }", "public void freeMaterials(){\n\t\t//android.util.Log.d(TAG,\"freeMaterials()\");\n\t\tfinal int size = this.materials.size();\n\t\tfor(int index=0; index < size; index++){\n\t\t\tthis.materials.delete(this.materials.keyAt(index));\n\t\t}\n\t}", "public void clearAll() {\n rangeMap.clear();\n }", "private void removeQueryBoundsFromGeometryRegistry(QueryRegion region)\r\n {\r\n myToolbox.getGeometryRegistry().removeGeometriesForSource(this, new HashSet<Geometry>(region.getGeometries()));\r\n }", "public void cleanup() {\r\n\t\tsuper.cleanup();\r\n\t\tfor (int i = 0; i < _composites.size(); i++) {\r\n\t\t\t_composites.get(i).cleanup();\t\r\n\t\t}\r\n\t}", "@Override\n public void clearAllRegistrations()\n {\n writeRegistryStoreProperties(null);\n }", "public static void clearWorld() {\n // TODO: Complete this method\n population.clear();\n babies.clear();\n }", "public static void dispose()\n {\n for (int texture:allTextures)\n {\n glDeleteTextures(texture);\n }\n }", "public void clear()\n {\n getMap().clear();\n }", "public void clear_strokes() {\n this.contours = new ArrayList<ContourClass>(); // Argument (if any) specifies initial capacity (default 10)\n }", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void clear()\n {\n normalImports.clear();\n wildcardImports.clear();\n }", "public void clear() {\r\n\t\tnameInGraph.clear();\r\n\t\tnameColor.clear();\r\n\t}", "public void clearAll();", "public void clearAll();", "public void clearCentroids();", "public static void removeAll() {\n\t\tgetPersistence().removeAll();\n\t}", "public static void removeAll() {\n\t\tgetPersistence().removeAll();\n\t}", "public static void removeAll() {\n\t\tgetPersistence().removeAll();\n\t}", "public static void removeAll() {\n\t\tgetPersistence().removeAll();\n\t}", "public static void removeAll() {\n\t\tgetPersistence().removeAll();\n\t}", "public static void removeAll() {\n\t\tgetPersistence().removeAll();\n\t}", "public static void removeAll() {\n\t\tgetPersistence().removeAll();\n\t}", "public static void removeAll() {\n\t\tgetPersistence().removeAll();\n\t}", "public static void removeAll() {\n\t\tgetPersistence().removeAll();\n\t}", "public static void removeAll() {\n\t\tgetPersistence().removeAll();\n\t}", "public synchronized void clear() {\n synchronized (this.factories) {\n for (Map.Entry<String, CachedAnnotator> entry : new HashSet<>(this.factories.entrySet())) {\n // Unmount the annotator\n Optional.ofNullable(entry.getValue()).flatMap(ann -> Optional.ofNullable(ann.annotator.getIfDefined())).ifPresent(Annotator::unmount);\n // Remove the annotator\n this.factories.remove(entry.getKey());\n }\n }\n }", "public void destroy() {\n\t\ttermMap = null;\n\t\tdoc = null;\n\t}", "public static void clearLayers(){\n\t\tfor(int i=0;i<ChangeLayer.Layers.length;i++){\n\t\t\tChangeLayer.Layers[i].clear();\n\t\t\t}\n\t}", "public void deleteAllOptset() {\n this.optionSet = new ArrayList<OptionSet>();\n }", "public void clear() {\n\t\tlocation.clear();\n\t\theap.clear();\n\t}", "@Override\n\tpublic void removeAll() {\n\t\tfor (Paper paper : findAll()) {\n\t\t\tremove(paper);\n\t\t}\n\t}", "public void RemoveAllGraphs() {\n EquationCardLayout.removeAll();\n lineGraphs.clear();\n CurrentEQ = \"\";\n EQNum = 0;\n AddNewGraph();\n Canvas.removeAll();\n Canvas.repaint();\n }", "public void freeScenes(){\n\t\t//android.util.Log.d(TAG,\"freeScenes()\");\n\t\tfinal int size = this.scenes.size();\n\t\tfor(int index=0; index < size; index++){\n\t\t\tthis.scenes.delete(this.scenes.keyAt(index));\n\t\t}\n\t}", "protected void deselectAllCurves() {\n\t\tfor (int i = 0; i < selectedCurves.size(); ++i) {\n\t\t\tcurves.add(selectedCurves.get(i));\n\t\t}\n\n\t\tselectedCurves.clear();\n\t}", "@Override\n\tprotected void onDestroy()\n\t{\n\t\tif (mAnnotatedGeometriesGroup != null)\n\t\t{\n\t\t\tmAnnotatedGeometriesGroup.registerCallback(null);\n\t\t}\n\t\t\n\t\tif (mAnnotatedGeometriesGroupCallback != null)\n\t\t{\n\t\t\tmAnnotatedGeometriesGroupCallback.delete();\n\t\t\tmAnnotatedGeometriesGroupCallback = null;\n\t\t}\n\n\t\tsuper.onDestroy();\n\t\tSystem.gc();\n\t}", "@SuppressWarnings(\"unchecked\")\r\n private Void removeGeometriesAnswer()\r\n {\r\n List<Geometry> adds = (List<Geometry>)EasyMock.getCurrentArguments()[1];\r\n List<Geometry> removes = (List<Geometry>)EasyMock.getCurrentArguments()[2];\r\n\r\n assertTrue(adds.isEmpty());\r\n\n // 121\r\n assertEquals(140, removes.size());\r\n boolean hasLines = false;\r\n boolean hasMeshes = false;\r\n boolean hasFootprint = false;\r\n boolean hasImage = false;\r\n\r\n for (Geometry geom : removes)\r\n {\r\n if (geom instanceof PolygonGeometry)\r\n {\r\n hasFootprint = true;\r\n }\r\n else if (geom instanceof PolylineGeometry)\r\n {\r\n hasLines = true;\r\n }\r\n else if (geom instanceof PolygonMeshGeometry)\r\n {\r\n hasMeshes = true;\r\n }\r\n else if (geom instanceof TileGeometry)\r\n {\r\n hasImage = true;\r\n }\r\n }\r\n\r\n assertTrue(hasLines);\r\n assertTrue(hasMeshes);\r\n assertTrue(hasFootprint);\r\n assertTrue(hasImage);\r\n\r\n return null;\r\n }", "@Override\n\tpublic void removeAll() {\n\t\tfor (LocalRichInfo localRichInfo : findAll()) {\n\t\t\tremove(localRichInfo);\n\t\t}\n\t}", "public void refreshGeometry(){\n\t\tfor (int i = 0; i < getSegmentCount(); i++) {\n\t\t\tsegments.get(i).refreshGeometry();\n\t\t}\n\t}", "public static void clearWorld() {\n\t\t// Complete this method.\n\t\tfor(Critter i: population){\n\t\t\tpopulation.remove(i);\n\t\t}\n\t\tfor(Critter j: babies){\n\t\t\tbabies.remove(j);\n\t\t}\n\t\tpopulation.clear();\n\t\tbabies.clear();\n\n\n\t}", "public void clearAll() {\n infectionsQueue.clear();\n populationQueue.clear();\n deathsQueue.clear();\n healsQueue.clear();\n }", "public void clear() {\r\n for (Edge edge : edges)\r\n edge.disconnect();\r\n for (Vertex vertex : vertices)\r\n vertex.disconnect();\r\n edges.clear();\r\n vertices.clear();\r\n getChildren().remove(1, getChildren().size());\r\n }", "public static void clearRegistry() {\n \t\tLIBRARIES.clear();\n \t}" ]
[ "0.7427323", "0.67435443", "0.6567681", "0.6430941", "0.6378631", "0.6354687", "0.62501836", "0.62166667", "0.6194681", "0.615437", "0.61380786", "0.6078813", "0.6045482", "0.6044074", "0.6043316", "0.60312283", "0.6015952", "0.6010321", "0.59786755", "0.5967146", "0.5954416", "0.5948729", "0.5946474", "0.5935703", "0.5922298", "0.59208167", "0.5909628", "0.5895401", "0.58849293", "0.58667773", "0.5842831", "0.58378613", "0.5837244", "0.58334637", "0.5828911", "0.58062345", "0.5791976", "0.576421", "0.5762855", "0.5750139", "0.5740827", "0.57376254", "0.57342297", "0.57161593", "0.5704982", "0.5703322", "0.56994265", "0.5698439", "0.5695616", "0.56920546", "0.5686213", "0.56847364", "0.5682321", "0.5680298", "0.5649985", "0.5646239", "0.5628674", "0.5628674", "0.5628674", "0.5628674", "0.5628674", "0.5628674", "0.5628674", "0.5628674", "0.5628674", "0.5628674", "0.5628674", "0.5628674", "0.5627974", "0.56067544", "0.559766", "0.559766", "0.5596358", "0.5596146", "0.5596146", "0.5596146", "0.5596146", "0.5596146", "0.5596146", "0.5596146", "0.5596146", "0.5596146", "0.5596146", "0.55916095", "0.55909157", "0.558787", "0.55817425", "0.5581601", "0.5581476", "0.5578644", "0.55738485", "0.55645", "0.5563442", "0.5562754", "0.5559484", "0.555831", "0.5556033", "0.5539026", "0.5536733", "0.5532328" ]
0.71140784
1
Removes the geometries for the given region from geometry registry.
private void removeQueryBoundsFromGeometryRegistry(QueryRegion region) { myToolbox.getGeometryRegistry().removeGeometriesForSource(this, new HashSet<Geometry>(region.getGeometries())); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "void removeRegion(Region region);", "private void removeAllQueryBoundsFromGeometryRegistry()\r\n {\r\n myToolbox.getGeometryRegistry().removeGeometriesForSource(this);\r\n }", "public void freeGeometries(){\n\t\tfinal int size = this.geometries.size();\n\t\tfor(int index=0; index < size; index++){\n\t\t\tfinal int key = this.geometries.keyAt(index);\n\t\t\tthis.geometries.get(key).free();\n\t\t\tthis.geometries.delete(key);\n\t\t}\n\t}", "public void purgeQueue() {\r\n\t\tfDirtyRegions.clear();\r\n\t}", "public Gel_BioInf_Models.VirtualPanel.Builder clearRelevantRegions() {\n relevantRegions = null;\n fieldSetFlags()[6] = false;\n return this;\n }", "public final synchronized void clearGeometry() {\n synchronized (this) {\n this.f718B8WBXPBCF2jGfUDZZU2zV5EYdqbUBu0lAZ0THCEqYyuE8VACR9dY7rDnwBIqh64T = null;\n this.f719hxYOFxFjLpN1maJuWNxUV40nExCGxsxkDPOTgtzMu4zlZCQb3bPlKsXo1SYJg6ME = null;\n }\n }", "void removeCoordinateSystem(CoordinateSystem cs);", "@Override\n \tpublic void regionsRemoved(RegionEvent evt) {\n \t\t\n \t}", "public void removeFromWorld(World world);", "public void delete()\n\t{\n\t\tif(object.onDelete())\n\t\t{\n\t\t\tremoveFromRegion();\n\t\t}\n\t}", "public void remove(GeometricalObject object);", "public void secondaryRemoveRegion(com.hps.july.persistence.Region arg0) throws java.rmi.RemoteException, javax.ejb.FinderException, javax.naming.NamingException {\n\n instantiateEJB();\n ejbRef().secondaryRemoveRegion(arg0);\n }", "private void removeArea() {\n \t\tthis.set.remove( this.area );\n \t\tthis.finish();\n \t}", "public void removeByRegionId(long regionId)\n\t\tthrows com.liferay.portal.kernel.exception.SystemException;", "public void doRemove() throws VisADException, RemoteException {\n rangeRings = null;\n super.doRemove();\n }", "public void removeTiles(Renderer r) {\n\n\t\t// Return if the room has not been rendered\n\t\tif (shadowMap == null) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Delete the shadow map\n\t\t// r.deleteMap(shadowMap);\n\n\t\t// Delete the tiles\n\t\tfor (int i = 0; i < tiles.length; i++) {\n\t\t\tfor (int j = 0; j < tiles[0].length; j++) {\n\n\t\t\t\tTile tile = tiles[i][j];\n\n\t\t\t\t// Delete model of the tile\n\t\t\t\tif (tile.getModel() != null) {\n\t\t\t\t\tr.deleteModel(tile.getModel().getName());\n\t\t\t\t}\n\n\t\t\t\t// If there are any items delete them too\n\t\t\t\tif (tile instanceof BasicFloor) {\n\n\t\t\t\t\tBasicFloor floor = (BasicFloor) tile;\n\n\t\t\t\t\tfor (Item item : floor.getItems())\n\t\t\t\t\t\tr.deleteModel(item.getModel().getName());\n\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public void remove(){\n Api.worldRemover(getWorld().getWorldFolder());\n }", "public void deleteSelected() {\r\n \t\tObject cells[] = graph.getSelectionCells();\r\n \t\tGraphModel graphmodel = graph.getModel();\r\n \r\n \t\t// If a cell is a blocking region avoid removing its edges and\r\n \t\t// select its element at the end of the removal process\r\n \t\tSet edges = new HashSet();\r\n \t\tSet<Object> select = new HashSet<Object>();\r\n \r\n \t\t// Set with all regions that can be deleted as its child were removed\r\n \t\tSet<Object> regions = new HashSet<Object>();\r\n \t\t// Set with all JmtCells that we are removing\r\n \t\tSet<Object> jmtCells = new HashSet<Object>();\r\n \r\n \t\t// Giuseppe De Cicco & Fabio Granara\r\n \t\t// for(int k=0; k<cells.length; k++){\r\n \t\t// if(cells[k] instanceof JmtEdge){\r\n \t\t// ((JmtCell)(graphmodel.getParent(graphmodel.getSource((JmtEdge)cells[k])))).SubOut();\r\n \t\t// ((JmtCell)(graphmodel.getParent(graphmodel.getTarget((JmtEdge)cells[k])))).SubIn();\r\n \t\t// }\r\n \t\t//\r\n \t\t// }\r\n \t\tfor (int i = 0; i < cells.length; i++) {\r\n \t\t\tif (!(cells[i] instanceof BlockingRegion)) {\r\n \t\t\t\t// Adds edge for removal\r\n \t\t\t\tedges.addAll(DefaultGraphModel.getEdges(graphmodel, new Object[] { cells[i] }));\r\n \t\t\t\t// Giuseppe De Cicco & Fabio Granara\r\n \t\t\t\t// quando vado a eliminare un nodo, a cui collegato un arco,\r\n \t\t\t\t// vado ad incrementare o diminuire il contatore per il\r\n \t\t\t\t// pulsanteAGGIUSTATUTTO\r\n \t\t\t\t// Iterator iter = edges.iterator();\r\n \t\t\t\t// while (iter.hasNext()) {\r\n \t\t\t\t// Object next = iter.next();\r\n \t\t\t\t// if (next instanceof JmtEdge){\r\n \t\t\t\t// ((JmtCell)(graphmodel.getParent(graphmodel.getSource((JmtEdge)next)))).SubOut();\r\n \t\t\t\t// ((JmtCell)(graphmodel.getParent(graphmodel.getTarget((JmtEdge)next)))).SubIn();\r\n \t\t\t\t// }\r\n \t\t\t\t//\r\n \t\t\t\t// }\r\n \t\t\t\t// Stores parents information and cell\r\n \t\t\t\tif (cells[i] instanceof JmtCell) {\r\n \t\t\t\t\tif (((JmtCell) cells[i]).getParent() instanceof BlockingRegion) {\r\n \t\t\t\t\t\tregions.add(((JmtCell) cells[i]).getParent());\r\n \t\t\t\t\t}\r\n \t\t\t\t\tjmtCells.add(cells[i]);\r\n \t\t\t\t}\r\n \t\t\t} else {\r\n \t\t\t\t// Adds node for selection\r\n \t\t\t\tObject[] nodes = graph.getDescendants(new Object[] { cells[i] });\r\n \t\t\t\tfor (Object node : nodes) {\r\n \t\t\t\t\tif (node instanceof JmtCell || node instanceof JmtEdge) {\r\n \t\t\t\t\t\tselect.add(node);\r\n \t\t\t\t\t}\r\n \t\t\t\t}\r\n \t\t\t\t// Removes blocking region from data structure\r\n \t\t\t\tmodel.deleteBlockingRegion(((BlockingRegion) cells[i]).getKey());\r\n \t\t\t}\r\n \t\t}\r\n \r\n \t\tif (!edges.isEmpty()) {\r\n \t\t\tgraphmodel.remove(edges.toArray());\r\n \t\t}\r\n \t\t// removes cells from graph\r\n \t\tgraphmodel.remove(cells);\r\n \r\n \t\t// Checks if all children of a blocking region have been removed\r\n \t\tIterator<Object> it = regions.iterator();\r\n \t\twhile (it.hasNext()) {\r\n \t\t\tjmtCells.add(null);\r\n \t\t\tBlockingRegion region = (BlockingRegion) it.next();\r\n \t\t\tList child = region.getChildren();\r\n \t\t\tboolean empty = true;\r\n \t\t\tfor (int i = 0; i < child.size(); i++) {\r\n \t\t\t\tif (child.get(i) instanceof JmtCell && !jmtCells.contains(child.get(i))) {\r\n \t\t\t\t\tempty = false;\r\n \t\t\t\t\tbreak;\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t\tif (empty) {\r\n \t\t\t\tmodel.deleteBlockingRegion(region.getKey());\r\n \t\t\t\tgraphmodel.remove(new Object[] { region });\r\n \t\t\t}\r\n \t\t}\r\n \r\n \t\t// Removes cells from data structure\r\n \t\tfor (Object cell : cells) {\r\n \t\t\tif (cell instanceof JmtCell) {\r\n \t\t\t\tmodel.deleteStation(((CellComponent) ((JmtCell) cell).getUserObject()).getKey());\r\n \t\t\t} else if (cell instanceof JmtEdge) {\r\n \t\t\t\tJmtEdge link = (JmtEdge) cell;\r\n \t\t\t\tmodel.setConnected(link.getSourceKey(), link.getTargetKey(), false);\r\n \t\t\t}\r\n \t\t}\r\n \r\n \t\t// If no stations remains gray select and link buttons\r\n \t\tif (graph.getModel().getRootCount() == 0) {\r\n \t\t\tcomponentBar.clearButtonGroupSelection(0);\r\n \t\t\tsetConnect.setEnabled(false);\r\n \t\t\tsetSelect.setEnabled(false);\r\n \t\t}\r\n \r\n \t\t// Selects components from removed blocking regions\r\n \t\tif (select.size() > 0) {\r\n \t\t\tgraph.setSelectionCells(select.toArray());\r\n \t\t\t// Resets parent information of cells that changed parent\r\n \t\t\tit = select.iterator();\r\n \t\t\twhile (it.hasNext()) {\r\n \t\t\t\tObject next = it.next();\r\n \t\t\t\tif (next instanceof JmtCell) {\r\n \t\t\t\t\t((JmtCell) next).resetParent();\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t}\r\n \t}", "void clearFeatures();", "void remove(GeometricalObject object);", "public void removeFeatures(Feature[] features) {\n //TODO: remove the features\n }", "public void close()\n {\n myListenerHelper.close();\n mySpecializedProcessorsLock.writeLock().lock();\n try\n {\n myRenderableGeometryProcessors.clear();\n myProjectionSensitiveProcessors.clear();\n }\n finally\n {\n mySpecializedProcessorsLock.writeLock().unlock();\n }\n myProcessorsLock.writeLock().lock();\n try\n {\n for (final GeometryProcessor<? extends Geometry> proc : myGeometryProcessorsMap.values())\n {\n myProcessorBuilder.getPickManager().removeGeometries(proc.getGeometries());\n proc.close();\n }\n myGeometryProcessorsMap.clear();\n myInactiveGeometries.clear();\n recalculateCoveredTimeSpans();\n myGeometryProcessorsSnapshot = Collections.emptyList();\n }\n finally\n {\n myProcessorsLock.writeLock().unlock();\n }\n\n myUnprocessedGeometryLock.lock();\n try\n {\n removeTimeListeners();\n }\n finally\n {\n myUnprocessedGeometryLock.unlock();\n }\n }", "private void clearRegionSelection(final Nation nation) {\n view.getRegions().get(nation).getSelectionModel().clearSelection();\n }", "public static void clearRegistry() {\r\n\t\tINTERPRETERS.clear();\r\n\t}", "public static de.fraunhofer.fokus.movepla.model.Region remove(long regionId)\n throws com.liferay.portal.kernel.exception.SystemException,\n de.fraunhofer.fokus.movepla.NoSuchRegionException {\n return getPersistence().remove(regionId);\n }", "public void clearRegistry() {\r\n implementedDatabases.clear();\r\n }", "private void cleanWorldsAndRegions() {\n Set<PermissionRegion> usedRegions = new HashSet<>();\n Set<PermissionWorld> usedWorlds = new HashSet<>();\n\n List<PermissionEntity> entities = new ArrayList<>();\n entities.addAll(getGroups().values());\n entities.addAll(getPlayers().values());\n\n for (PermissionEntity entity : entities) {\n for (Entry entry : entity.getPermissions()) {\n if (entry.getRegion() != null)\n usedRegions.add(entry.getRegion());\n if (entry.getWorld() != null)\n usedWorlds.add(entry.getWorld());\n }\n }\n\n // Determine what needs to be deleted\n Set<PermissionRegion> regionsToDelete = new HashSet<>(getRegions().values());\n regionsToDelete.removeAll(usedRegions);\n Set<PermissionWorld> worldsToDelete = new HashSet<>(getWorlds().values());\n worldsToDelete.removeAll(usedWorlds);\n\n // Re-build lists\n getRegions().clear();\n for (PermissionRegion region : usedRegions) {\n getRegions().put(region.getName(), region);\n }\n getWorlds().clear();\n for (PermissionWorld world : usedWorlds) {\n getWorlds().put(world.getName(), world);\n }\n\n // Tell underlying DAO about deleted regions/worlds\n if (!regionsToDelete.isEmpty())\n deleteRegions(regionsToDelete);\n if (!worldsToDelete.isEmpty())\n deleteWorlds(worldsToDelete);\n }", "public void removeFromfeatures (org.unitime.timetable.model.RoomFeature roomFeature) {\n \t\tif (null == getFeatures()) \n \t\t\tsetFeatures(new java.util.HashSet());\n \t\tgetFeatures().remove(roomFeature);\n \t}", "public Builder clearRegion() {\n \n region_ = 0;\n onChanged();\n return this;\n }", "@Delete\n public void removeRepresentations() throws ResourceException {\n try {\n dataService.destroyStudent(student);\n } catch (Exception ex) {\n logger.log(Level.SEVERE, null, ex);\n throw new ResourceException(Status.CLIENT_ERROR_BAD_REQUEST, ex);\n }\n }", "public void unregisterGeofences(List<String> geofenceIDs) {\n LocationServices.GeofencingApi.removeGeofences(\n mGoogleApiClient,\n geofenceIDs\n ).setResultCallback(this); // Result processed in onResult().\n }", "void clearShapeMap();", "public void removeFeatures(Extent ex) {\n //TODO: remove the features\n }", "void removeExistingGlue() {\r\n\t\tfor (int i = outputStream.size() - 1; i >= 0; i--) {\r\n\t\t\tRTObject c = outputStream.get(i);\r\n\t\t\tif (c instanceof Glue) {\r\n\t\t\t\toutputStream.remove(i);\r\n\t\t\t} else if (c instanceof ControlCommand) { // e.g.\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t// BeginString\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\toutputStreamDirty();\r\n\t}", "boolean removeObject(RectangleLatLng rectangle, String id);", "public static de.fraunhofer.fokus.movepla.model.Region removeByregionName(\n java.lang.String name)\n throws com.liferay.portal.kernel.exception.SystemException,\n de.fraunhofer.fokus.movepla.NoSuchRegionException {\n return getPersistence().removeByregionName(name);\n }", "public synchronized void unRegisterAll()\r\n {\r\n clearNameObjectMaps();\r\n }", "public void removeFeature(Feature feature) {\n rows.removeElement(feature);\n }", "public void removeAllLicensee() {\r\n\t\tBase.removeAll(this.model, this.getResource(), LICENSEE);\r\n\t}", "public void removeRepresentations()\r\n\t{\n\t}", "public void unregister() {\n\t\tworkbenchWindow.getPartService().removePartListener(this);\n\t}", "@Override\n public void cleanup(GL2 gl)\n {\n for(int i = 0; i < 6; i++)\n {\n Integer t_id = (Integer)textureIdMap[i].remove(gl);\n if(t_id != null)\n {\n int tex_id_tmp[] = { t_id.intValue() };\n gl.glDeleteTextures(1, tex_id_tmp, 0);\n }\n }\n }", "public void deleteUnitFromMinimap(Unit unit) {\n for (int k = 0; k < minimapUnits.size(); ++k) {\n if (minimapUnits.get(k).getMyUnit().equals(unit)) {\n drawPane.getChildren().remove(minimapUnits.get(k));\n minimapUnits.remove(minimapUnits.get(k));\n break;\n }\n }\n }", "public void freeGeometry(final int id){\n\t\t//android.util.Log.d(TAG,\"freeGeometry(\"+id+\")\");\n\t\tthis.geometries.get(id).free();\n\t}", "public abstract void removedFromWidgetTree();", "public static void clearRegistry() {\n \t\tLIBRARIES.clear();\n \t}", "void unsetRoadTerrain();", "void remove(Coordinates coords) throws IOException;", "public void removeAllComponents();", "private void cleanup() {\n\t\tTreeSet<CacheEntry> entries = new TreeSet<CacheEntry>(map.values());\n\t\tint i = region.getItemsToEvict();\n\t\tIterator<CacheEntry> it = entries.iterator();\n\t\twhile (it.hasNext() && i > 0) {\n\t\t\tremoveEntry(it.next());\n\t\t\ti--;\n\t\t}\n\t}", "void removeFeature(int i);", "void removeFeature(int i);", "public void deselectAll()\n {\n map.deselectAll();\n mapComponent.repaint();\n mapper.resetMenus();\n }", "@Override\r\n public void addQueryRegion(QueryRegion region)\r\n {\n removeQueryRegion(region.getGeometries());\r\n\r\n synchronized (myQueryRegions)\r\n {\r\n myQueryRegions.add(region);\r\n }\r\n\r\n Collection<PolygonGeometry> geometries = New.collection(region.getGeometries().size());\r\n for (PolygonGeometry polygon : region.getGeometries())\r\n {\r\n if (polygon.getRenderProperties().isDrawable() || polygon.getRenderProperties().isPickable())\r\n {\r\n geometries.add(polygon);\r\n }\r\n }\r\n myToolbox.getGeometryRegistry().addGeometriesForSource(this, geometries);\r\n\r\n myChangeSupport.notifyListeners(listener -> listener.queryRegionAdded(region), myDispatchExecutor);\r\n }", "public void removeAllPartOfSet() {\r\n\t\tBase.removeAll(this.model, this.getResource(), PARTOFSET);\r\n\t}", "public void removeAllAgents(String layer)\n/* 180: */ {\n/* 181:254 */ this.mapPanel.removeAllAgents(layer);\n/* 182: */ }", "private void deleteRegion(Configuration conf, final HTableDescriptor htd,\n byte[] startKey, byte[] endKey, boolean unassign, boolean metaRow,\n boolean hdfs) throws IOException, InterruptedException {\n deleteRegion(conf, htd, startKey, endKey, unassign, metaRow, hdfs, false, HRegionInfo.DEFAULT_REPLICA_ID);\n }", "Feature removeFeature(int index);", "public static void clearWorld() {\n\t\tpopulation.clear();\n\t}", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public void removeAll();", "public final void clearTexture() {\n finalSkeleton = null;\n\n\n// for (Slot slot:emptySkeleton.getSlots()){\n// PolygonRegionAttachment attach=((PolygonRegionAttachment)slot.getAttachment()).se\n// }\n// emptySkeleton = null;\n// PolygonRegionAttachmentLoader attachmentLoader = new PolygonRegionAttachmentLoader(this, phase, assetProvider.getTextureAtlas(SpineToolFullEditorOverlay.getSelectedSkeleton()));\n// emptySkeleton = createSkeleton(attachmentLoader);\n// finalize(emptySkeleton);\n }", "void unsetRegisteredOfficeCity();", "public void destroy() {\n for (ComponentBean component : this.componentMap.values()) {\n component.getObject().destroy();\n }\n\n flushRegistry();\n\n }", "static void wipeLocations(){\n\t \tfor (int i= 0; i < places.length; i++){\n\t\t\t\tfor (int j = 0; j < places[i].items.size(); j++)\n\t\t\t\t\tplaces[i].items.clear();\n\t\t\t\tfor (int k = 0; k < places[i].receptacle.size(); k++)\n\t\t\t\t\tplaces[i].receptacle.clear();\n\t \t}\n\t \tContainer.emptyContainer();\n\t }", "HRegion removeFromOnlineRegions(HRegionInfo hri) {\n this.lock.writeLock().lock();\n HRegion toReturn = null;\n try {\n toReturn = onlineRegions.remove(Bytes.mapKey(hri.getRegionName()));\n } finally {\n this.lock.writeLock().unlock();\n }\n return toReturn;\n }", "public void removeResourceCollection()\r\n {\r\n getSemanticObject().removeProperty(swb_resourceCollectionInv);\r\n }", "public void removeGeofencesButtonHandler() {\n if (!mGoogleApiClient.isConnected()) {\n Toast.makeText(mActivity, getString(R.string.not_connected), Toast.LENGTH_SHORT).show();\n return;\n }\n try {\n // Remove geofences.\n LocationServices.GeofencingApi.removeGeofences(\n mGoogleApiClient,\n // This is the same pending intent that was used in addGeofences().\n getGeofencePendingIntent()\n ).setResultCallback(this); // Result processed in onResult().\n } catch (SecurityException securityException) {\n // Catch exception generated if the app does not use ACCESS_FINE_LOCATION permission.\n logSecurityException(securityException);\n }\n }", "public void destroy() {\n\t\ttermMap = null;\n\t\tdoc = null;\n\t}", "void removeAllEntries();", "public synchronized void removeForServer(ServerName serverName) {\n for (Map.Entry<byte[], RegionLocations> entry : cache.entrySet()) {\n byte[] regionName = entry.getKey();\n RegionLocations locs = entry.getValue();\n RegionLocations newLocs = locs.removeByServer(serverName);\n if (locs == newLocs) {\n continue;\n }\n if (newLocs.isEmpty()) {\n cache.remove(regionName, locs);\n } else {\n cache.put(regionName, newLocs);\n }\n }\n }", "public void clear(){\n this.entities.clear();\n /*for(QuadTree node: this.getNodes()){\n node.clear();\n this.getNodes().remove(node);\n }*/\n this.nodes.clear();\n }", "public void clearFeatures() {\n localFeatureVector.clear();\n }", "void removeRowsLock();", "public static void clearWorld() {\n\t\t// Complete this method.\n\t\tfor(Critter i: population){\n\t\t\tpopulation.remove(i);\n\t\t}\n\t\tfor(Critter j: babies){\n\t\t\tbabies.remove(j);\n\t\t}\n\t\tpopulation.clear();\n\t\tbabies.clear();\n\n\n\t}", "public void removeProjectEntries(String serviceName);", "public static void clearWorld() {\r\n \tbabies.clear();\r\n \tpopulation.clear();\r\n }", "@Override\n public void formClearRegistry() {\n throw new UnsupportedOperationException(\"Not supported yet.\");\n }", "@Override\n public void formClearRegistry() {\n throw new UnsupportedOperationException(\"Not supported yet.\");\n }", "public void cleanup(Entity e)\n {\n\t\tif(my_mesh != null)\n\t\t{\n\t\t\tRenderManagerCallback rc = new RenderManagerCallback()\n\t\t\t{\n\t\t\t\tpublic void onSuccess()\n\t\t\t\t{\n\t\t\t\t\t//System.err.println(\"Removing from world\");\n\t\t\t\t\tmy_geom.removeFromParent();\n\t\t\t\t}\n\t\t\t};\n\t\t\t\n\t\t\tRenderManager.addCallback(rc);\n\t\t}\n }", "public void destroy() {\n\t\tfor (ANodeAttributeRenderer attributeRenderer : attributeRenderers) {\n\t\t\tattributeRenderer.unregisterPickingListeners();\n\t\t}\n\t}", "@Override\r\n void removeStarMap(StarMapComponent starMap) {\n\r\n }", "public void removeWorld(String name){\n worlds.remove(getWorld(name));\n }", "public void removeAllInterpretedBy() {\r\n\t\tBase.removeAll(this.model, this.getResource(), INTERPRETEDBY);\r\n\t}", "private void destroyBounds() {\n size -= 4;\n this.setBounds(bounds.left, bounds.top);\n if (size <= 0) models.remove(this);\n }", "void removeTiles(Map<Location, SurfaceEntity> map, int x, int y, int width, int height) {\r\n\t\tfor (int i = x; i < x + width; i++) {\r\n\t\t\tfor (int j = y; j > y - height; j--) {\r\n\t\t\t\tmap.remove(Location.of(x, y));\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public static void worldLocsRemove(UUID uuid) {\n\n\t\ttry {\n\n\t\t\tStatement st = conn.createStatement();\n\n\t\t\tst.executeUpdate(\"DELETE FROM worldlocs WHERE uuid='\" + uuid + \"';\");\n\n\t\t} catch (Exception e) {\n\t\t\tPvPTeleport.instance.getLogger().info(e.getMessage());\n\t\t}\n\n\t}", "void unsetGradeModelRefs();", "public void\t\tremoveAll();", "public void remove(GObject object);" ]
[ "0.7078356", "0.62728345", "0.5512804", "0.53577536", "0.53572226", "0.52302635", "0.5229597", "0.5209555", "0.5165433", "0.5164685", "0.51459783", "0.51314515", "0.512648", "0.50819373", "0.50739425", "0.5060211", "0.5059581", "0.5046756", "0.5022683", "0.5007806", "0.5006348", "0.50032526", "0.5002366", "0.49755433", "0.49509892", "0.4945013", "0.49279657", "0.49154073", "0.48749453", "0.4871675", "0.48647985", "0.48384407", "0.47966605", "0.4746413", "0.47451538", "0.4737914", "0.4714167", "0.469988", "0.46983522", "0.46920624", "0.46675962", "0.46644607", "0.46640578", "0.46549556", "0.46469077", "0.46393293", "0.4635916", "0.46351737", "0.46343324", "0.46288592", "0.4623399", "0.4623399", "0.462268", "0.46226427", "0.4614982", "0.46129", "0.4610799", "0.46021557", "0.4592065", "0.45898408", "0.45898408", "0.45898408", "0.45898408", "0.45898408", "0.45898408", "0.45898408", "0.45898408", "0.45898408", "0.45898408", "0.45898408", "0.45898408", "0.45839477", "0.45805532", "0.45804507", "0.45800567", "0.45788518", "0.45777684", "0.45656613", "0.45599332", "0.45598537", "0.45552763", "0.45532325", "0.45519313", "0.4549662", "0.45465598", "0.45412078", "0.4540195", "0.45389363", "0.45389363", "0.4538251", "0.45256388", "0.45233384", "0.4519617", "0.45161942", "0.4508497", "0.45012578", "0.44928715", "0.44908354", "0.44901028", "0.44852367" ]
0.7395118
0