Home › Forums › JinGames Forums › Questions and Answers › Custom Npcs Scripting
Tagged: Custom NPC, Projectile, scripting
- This topic has 21 replies, 1 voice, and was last updated 1 month, 2 weeks ago by
Peeko15.
-
AuthorPosts
-
-
October 14, 2017 at 12:36 #36233
TheLeinhart
ParticipantSo…I’m very new to the whole scripting aspect of custom npcs and have been trying to figure this out for a while now so any help would be appreciated. Do know I have seen the scripting pages for the Custom Npcs and just can’t make heads or tails of it nor can I find a decent tutorial on how to script custom damage modifiers as well as custom Hp modifiers.
Essentially what I’m after is how do I script the NPC to set it’s melee higher than the cap. For this I am at a total loss and have been trying for hours on end. Once again, any and all help is much appreciated.
-
October 14, 2017 at 15:44 #36235
Aegous
ParticipantWell if you’re on java 7 then it’ll have the option to set the language to EMCAScript by default but if you have java 8 then you’ll need to go to C:\Program Files (x86)\Java\(jre1.8.0 or something like that)\lib\ext\ and find the nashorn.jar and put that into your mods folder on the server. Once you’ve got that done you’ll need to boot up your server and select EMCAScript. Once that is done you can you’ll need to go to the “Init” tab and enter this into the text box.
npc.setMeleeStrength(10000)
npc.setRangedStrength(10000)npc.setMaxHealth(10000)
npc.setHealth(10000)-
October 15, 2017 at 01:55 #36242
TheLeinhart
ParticipantThank you so much!
-
-
October 15, 2017 at 04:32 #36247
Airswift101
ParticipantHow do I do it on single player worlds? ?
-
October 15, 2017 at 04:35 #36248
TheLeinhart
ParticipantI reckon you follow the same steps as was mentioned to me above, but instead, place it in your mods folder for single player use. Try that and see if it works.
-
-
October 15, 2017 at 09:42 #36250
Aegous
ParticipantYeah it’ll work exactly the same if you just follow the steps but instead put it into your mods folder on the singleplayer world.
-
October 15, 2017 at 17:02 #36256
Gabriel Santos Botelho Meles
ParticipantGood I did this when I went to look before putting the mod, I already had the Script folder … What do I do now?
-
October 15, 2017 at 17:06 #36257
Gabriel Santos Botelho Meles
ParticipantIs there a Script Folder out of the npcs customs folder What do I do with this folder?
-
October 15, 2017 at 17:24 #36258
Gabriel Santos Botelho Meles
ParticipantI found it, I have to put in the same way that you send this script there in the damaged folder?
-
October 15, 2017 at 17:50 #36260
Airswift101
ParticipantWhat do you mean by “boot up your server”
-
October 16, 2017 at 09:13 #36273
TheLeinhart
ParticipantBy restarting your server for it to take affect.
-
-
October 16, 2017 at 05:45 #36270
Airswift101
Participant??
-
October 16, 2017 at 12:56 #36275
Airswift101
ParticipantWHAT DO YOU MEAN BY OPEN EMCA SCRIPT?!?! PLEASE HELP!!!!!
-
October 16, 2017 at 16:04 #36277
Aegous
ParticipantAirswift EMCAScript is another name for javascript and if you can’t follow that tutorial I wrote up then I’d say you might aswell give up because the scripting side of customnpcs is not for beginners.
-
October 16, 2017 at 16:12 #36279
Airswift101
ParticipantNah… I figured it out
I guess…
Thanks? -
October 16, 2017 at 23:06 #36283
Gabriel Santos Botelho Meles
ParticipantI’m talking to the creator of custom NPCs how to make the correct “scripts”
-
April 2, 2018 at 19:58 #40163
James
ParticipantDoes anyone know how to make an npc Teleport to An enemy And fly in 1.7.10
-
April 2, 2018 at 20:38 #40164
James
ParticipantI have EMCAScript
-
January 17, 2021 at 22:44 #49499
Peeko15
Participantwhat do I script if I want the projectile that my npc shoots cause a potion effect from another mod?
I’m using EMCAScript
-
-
AuthorPosts
- You must be logged in to reply to this topic.