-.Paradox.- Posted November 15, 2013 Posted November 15, 2013 Hello, is there a tutorial about how to create bots and set to follow a specified player? thanks
Castillo Posted November 15, 2013 Posted November 15, 2013 https://wiki.multitheftauto.com/wiki/Slothman/Slothbot
-.Paradox.- Posted November 15, 2013 Author Posted November 15, 2013 I read it but i didnt understand how to work with
Castillo Posted November 15, 2013 Posted November 15, 2013 Slothbots work with teams, so in order to make a bot follow you, you must be in the same team as he is ( as far as I know ).
-.Paradox.- Posted November 15, 2013 Author Posted November 15, 2013 (edited) Okay EDIT I made this but i wanted to set to follow the player who spawned the bot and dont kill him, function Spawnbot1 (source) local x,y,z = getElementPosition (source) local rot = 90 local skin = 284 local interior = 0 local dimension = 0 local weapon =22 local team = getTeamFromName("Admin") local mode = "following" local modesubject = getLocalPlayer() call (getResourceFromName("slothbot"), "spawnBot", x+2, y, z+1, rot, skin, interior, dimension, team, weapon, mode, modesubject) end addCommandHandler("spawnbot", Spawnbot1) Edited November 17, 2013 by Guest
WASSIm. Posted November 18, 2013 Posted November 18, 2013 and what about ( local modesubject = getLocalPlayer() ) ?
-.Paradox.- Posted November 18, 2013 Author Posted November 18, 2013 It's a nil value Neither if you use getPlayerName(getLocalPlayer())
Castillo Posted November 18, 2013 Posted November 18, 2013 If you leave that getLocalPlayer there, the script won't work.
-.Paradox.- Posted November 18, 2013 Author Posted November 18, 2013 Yes so I used only local modesubject = source It spawn the bot and he follow but if another player spawned the bot and he isn't in the team the bot kill him so i don't want to check the team
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