generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: Script help

Previous Thread :: Next Thread 
caca50 is not online. caca50
Joined: 10 Jul 2011
Total Posts: 2037
25 Sep 2016 07:24 PM
pastebin link: 3KzXqDr5

This line: print('bleh '..torso.Parent.Name)

For some reason will print 'bleh Zombie'

Even though I ensure that the humanoid object can only be named 'Humanoid' or 'AI'?

The models named 'Zombie' have a 'Zombie' named humanoid.

This causes the zombie to "chase itself" and therefore he doesn't actually move.

Please help
Report Abuse
lululukas is not online. lululukas
Joined: 23 Aug 2010
Total Posts: 1043
25 Sep 2016 07:33 PM
####################################################################################
Report Abuse
lululukas is not online. lululukas
Joined: 23 Aug 2010
Total Posts: 1043
25 Sep 2016 07:34 PM
####################################################
Report Abuse
lululukas is not online. lululukas
Joined: 23 Aug 2010
Total Posts: 1043
25 Sep 2016 07:35 PM
Wow, props to whoever made the filter. Not even gonna say anything anymore.


R$10,495
Report Abuse
caca50 is not online. caca50
Joined: 10 Jul 2011
Total Posts: 2037
25 Sep 2016 07:40 PM
You could always make a pastebin because of these stupid filters
Report Abuse
caca50 is not online. caca50
Joined: 10 Jul 2011
Total Posts: 2037
25 Sep 2016 07:51 PM
plz
Report Abuse
CodeBreadpudding is not online. CodeBreadpudding
Joined: 24 Aug 2016
Total Posts: 1286
25 Sep 2016 07:52 PM
Did you mean torso.Parent.Humanoid.Name?
Report Abuse
caca50 is not online. caca50
Joined: 10 Jul 2011
Total Posts: 2037
25 Sep 2016 07:55 PM
For the printing part?

No, I was testing to see which model it was detecting as target.

I also did one that printed the 'human' variable's name, and that returned 'Humanoid'

Which is weird since it'll print 'Humanoid' for the humanoid and 'Zombie' for the model, considering that the zombie's humanoid part is named 'Zombie'
Report Abuse
Wunder_Wulfe is online. Wunder_Wulfe
Joined: 13 Sep 2016
Total Posts: 8356
25 Sep 2016 08:05 PM
Lol

torso.Parent.Name

that is the name of the parent of the torso

AKA Zombie
Report Abuse
caca50 is not online. caca50
Joined: 10 Jul 2011
Total Posts: 2037
25 Sep 2016 08:08 PM
I know that the torso.Parent.Name is zombie.

It shouldn't be though.

Because all the models in my game that are named 'Zombie' do not have an object named "Humanoid" in them.

So it should either print my name, or an AI in my game that has a Humanoid value.

For some reason it detects itself, and decides to chase itself
Report Abuse
caca50 is not online. caca50
Joined: 10 Jul 2011
Total Posts: 2037
25 Sep 2016 08:29 PM
Please help?

In case I wasn't clear.

This script is in a zombie, the zombie for some reason decides to chase zombies (inlcuding itself)
Report Abuse
caca50 is not online. caca50
Joined: 10 Jul 2011
Total Posts: 2037
25 Sep 2016 08:40 PM
Plz help

No matter what I try the zombie still chases other zombies
Report Abuse
lululukas is not online. lululukas
Joined: 23 Aug 2010
Total Posts: 1043
26 Sep 2016 04:41 PM
Doesn't matter if there is a humanoid or not. Torsos parent is always The Character (Or the name of the model)


R$10,495
Report Abuse
iIikeyou is not online. iIikeyou
Joined: 07 Mar 2012
Total Posts: 1659
26 Sep 2016 04:51 PM
that is very odd
you'll have to use something other than the name of humanoid to differentiate then, must be some kind of stupid roblox glitchiness
id suggest using getplayerfromcharacter, but it seems like some AIs should be targetted
Report Abuse
caca50 is not online. caca50
Joined: 10 Jul 2011
Total Posts: 2037
26 Sep 2016 05:32 PM
@lul
It does matter if there is a humanoid or not. because my script will only return the torso if there is a humanoid class in the torso's parent.

I fixed the issue though.

All I did was set 'TempHum' to nil every time the for loop runs.
Report Abuse
lululukas is not online. lululukas
Joined: 23 Aug 2010
Total Posts: 1043
26 Sep 2016 06:48 PM
*facepalm*

Not even gonna try anymore. Someone else help him understand.


R$10,495
Report Abuse
PurpleTaffyTess is not online. PurpleTaffyTess
Joined: 12 Jan 2016
Total Posts: 7
26 Sep 2016 06:51 PM
ive opened the script thingy out but how to spawn humanoid
Report Abuse
imtellingmommy is not online. imtellingmommy
Joined: 10 Mar 2013
Total Posts: 817
26 Sep 2016 06:54 PM
lulu is new blarg k
Report Abuse
lululukas is not online. lululukas
Joined: 23 Aug 2010
Total Posts: 1043
26 Sep 2016 07:52 PM
tf is blarg


R$10,495
Report Abuse
caca50 is not online. caca50
Joined: 10 Jul 2011
Total Posts: 2037
26 Sep 2016 10:05 PM
"Not even gonna try anymore. Someone else help him understand."

How do I not understand?

You do not understand what I am saying.

You were going on about how it doesn't matter if there is a humanoid or not. And I was saying that it does. What am I not understanding?
Report Abuse
TGazza is not online. TGazza
Joined: 16 Jan 2008
Total Posts: 242
27 Sep 2016 12:40 AM
in that function i would change this bit:

for i,v in pairs(area)do
if v:IsA'Model' and v:FindFirstChild('Torso')then
for _,a in pairs(HUM)do
local t = v:FindFirstChild(a)
if t~=nil and t:IsA'Humanoid'then
TempHum = t
end
end

to check to see if v equal its self, if it is then dont count it in your varable
EX:

for i,v in pairs(area)do
if v:IsA'Model' and v ~= script.Parent and v:FindFirstChild('Torso')then
for _,a in pairs(HUM)do
local t = v:FindFirstChild(a)
if t~=nil and t:IsA'Humanoid'then
TempHum = t
end
end



tell me if that fixes your problem if not then i could re-write the function to do what your looking for
Report Abuse
caca50 is not online. caca50
Joined: 10 Jul 2011
Total Posts: 2037
27 Sep 2016 07:46 PM
I ensured v is not itself, and I also set 'TempHum' to nil every time the for loop ran. I fixed it.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image