Droidy365 Posted October 14, 2017 Share Posted October 14, 2017 Hey guys, I need help with something - I want to make an NPC like what the title says. I want this because I want to make an NPC that holds @@Langerd's flashlight while the player walks around - empty handed. Thanks guys. Link to comment
Langerd Posted October 14, 2017 Share Posted October 14, 2017 Hey guys, I need help with something - I want to make an NPC like what the title says. I want this because I want to make an NPC that holds @@Langerd's flashlight while the player walks around - empty handed. Thanks guys. + i purpose to make him walk instead of run. If player walk with the flashlight the torso is static and lightning is not jiggling around.I will get up soon and try make script like that Link to comment
Fuse294 Posted October 14, 2017 Share Posted October 14, 2017 flashlight_guy{ playerModel jedi weapon WP_SABER saber flashlight FP_SABER_OFFENSE 1 aggression 1 aim 1 evasion 5 intelligence 5 move 2 reactions 2 playerTeam TEAM_NEUTRAL enemyTeam TEAM_NEUTRAL class CLASS_PRISONER runSpeed 120 acceleration 20 movetype walk snd humanmerc1 sndcombat humanmerc1 sndextra humanmerc1} Just an example of what you could do, of course because he's TEAM_NEUTRALl he won't follow you around like he would if he was TEAM_PLAYER for the playerteam, setting it to TEAM_PLAYER would result in npcs like reborn/cultist/merc/etc attacking him too, but that's for you to decide, the enemyteam TEAM_NEUTRAL is to ensure he is docile and won't attack anyone. I've set the class to CLASS_PRISONER to ensure there is no resistance to force powers. I suggest using the https://jkhub.org/files/file/2420-npctool/ to help with the stats. MB2 Beta Tester / MB2 FA Assistant Dev Link to comment
Droidy365 Posted October 14, 2017 Author Share Posted October 14, 2017 Okay. If I recall correctly, there's a follow script in this mod.I'll probably combine this with my current NPC - steve_spoopy. EDIT: Okay, I can't seem to get the spawnscript to work, and he's not turning his flashlight on by default. Link to comment
GamingPrince83 Posted October 24, 2017 Share Posted October 24, 2017 I don't know if this will help, but if you give the force-only cultists or the Kothos brothers lightsabers, they turn on the sabers against enemies but don't attack. Link to comment
Droidy365 Posted October 24, 2017 Author Share Posted October 24, 2017 Hmm, he seems to be CLASS_REBORN, so it's probably hard coded... I might have to change his name to "DKothos" or something. Link to comment
Droidy365 Posted October 24, 2017 Author Share Posted October 24, 2017 Okay, here's my NPC so far: dkothos{playerModel jedicustomSkin stevesaber flashlightsaberColor orangeweapon WP_SABERFP_HEAL 3 FP_SABER_OFFENSE 1 aggression 1 aim 1 evasion 5 intelligence 5 move 2 reactions 2 playerTeam TEAM_ENEMY enemyTeam TEAM_PLAYER class CLASS_PRISONER runSpeed 120 acceleration 20 movetype walk snd prisoner2 sndcombat prisoner2 sndextra prisoner2} It works great! Only problem I'm having now, is the script - I want it to basically use the command "runscript steve follow_player" when I start up the map. How would I do this in Radiant? Thank you very much for your help, by the way Link to comment
Droidy365 Posted October 25, 2017 Author Share Posted October 25, 2017 Okay, so I haven't made any progress with this thing whatsoever. Nothing I tried has worked... That being said, I don't know anything about scripting XDI already have the script - it's running it when the map starts that's the problem :/ Link to comment
SomaZ Posted October 25, 2017 Share Posted October 25, 2017 Okay, so I haven't made any progress with this thing whatsoever. Nothing I tried has worked... That being said, I don't know anything about scripting XDI already have the script - it's running it when the map starts that's the problem :/If I remember correctly you can target the scriptrunner from worldspawn.So the scriptrunner gets the "targetname" "follow_player" and the worldspawn "target" "follow_player". The script should be automatically executed at level load then. (IF I remember correctly)Is it running at map start or not?Else, give the npcspawner the "follow_player" script as spawnscript? Link to comment
IrocJeff Posted October 25, 2017 Share Posted October 25, 2017 Okay, so I haven't made any progress with this thing whatsoever. Nothing I tried has worked... That being said, I don't know anything about scripting XDI already have the script - it's running it when the map starts that's the problem :/If you want it to happen later you'll need to have it triggered somehow. Like the player touches a trigger which spawns the npc which runs the script. Otherwise, your going to need to add to the script more instructions. Say add a wait task for 30 seconds then after that run the main task. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now