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: Killfeed Help

Previous Thread :: Next Thread 
xSoulSpectrumx is not online. xSoulSpectrumx
Joined: 30 Nov 2011
Total Posts: 2976
18 Aug 2016 01:07 AM
local WorldService = game:GetService('Workspace')
local PlayerService = game:GetService('Players')

function PerformLog(client,instance)
print(instance.Value,'is the killer of',client.Name)
local m = Instance.new("Hint",WorldService)
m.Text = tostring(instance.Value.Name)..' is the killer of '..client.Name
wait(3)
m:Destroy()
end

PlayerService.PlayerAdded:connect(function(client)
client.CharacterAdded:connect(function(character)
character:WaitForChild('Humanoid').ChildAdded:connect(function(instance)
character.Humanoid.HealthChanged:connect(function()
if instance.Name == "creator" and character.Humanoid.Health <= 0 then
PerformLog(client,instance)
end
end)
end)
end)
end)

It spams the message.
Report Abuse
xSoulSpectrumx is not online. xSoulSpectrumx
Joined: 30 Nov 2011
Total Posts: 2976
18 Aug 2016 01:45 PM
Help.
Report Abuse
TimeTicks is not online. TimeTicks
Joined: 27 Apr 2011
Total Posts: 27115
18 Aug 2016 01:48 PM
'instance.Value.Name'

df is that

instance.Value *


Report Abuse
Isosta is not online. Isosta
Joined: 10 May 2015
Total Posts: 14729
18 Aug 2016 02:20 PM
"WorldService"


lul
Report Abuse
xSoulSpectrumx is not online. xSoulSpectrumx
Joined: 30 Nov 2011
Total Posts: 2976
18 Aug 2016 07:45 PM
Look if you don't know how to help or read don't say anything. I name my service how I want and if you don't understand that instance is a returning variable from the event you obviously don't know how they work.
Report Abuse
TimeTicks is not online. TimeTicks
Joined: 27 Apr 2011
Total Posts: 27115
18 Aug 2016 07:48 PM
https://forum.roblox.com/Forum/ShowPost.aspx?PostID=196472605


Report Abuse
thedailyblarg is not online. thedailyblarg
Joined: 26 Feb 2012
Total Posts: 5506
18 Aug 2016 08:06 PM
workspace >> "world service"
Report Abuse
xSoulSpectrumx is not online. xSoulSpectrumx
Joined: 30 Nov 2011
Total Posts: 2976
18 Aug 2016 08:07 PM
Thank you I appreciate it.
Report Abuse
Skellobit is not online. Skellobit
Joined: 13 Apr 2016
Total Posts: 12758
18 Aug 2016 08:07 PM
DayService = game:GetService("Lighting")

Formerly ToxicDominator - add 17,509 posts
Report Abuse
xSoulSpectrumx is not online. xSoulSpectrumx
Joined: 30 Nov 2011
Total Posts: 2976
18 Aug 2016 08:07 PM
Why do people care what I call workspace...
Report Abuse
Skellobit is not online. Skellobit
Joined: 13 Apr 2016
Total Posts: 12758
18 Aug 2016 08:08 PM
well it's not like there's a built-in reference for it

Formerly ToxicDominator - add 17,509 posts
Report Abuse
thedailyblarg is not online. thedailyblarg
Joined: 26 Feb 2012
Total Posts: 5506
18 Aug 2016 08:31 PM
because you can literally just type

workspace

to get the workspace
Report Abuse
TimeTicks is not online. TimeTicks
Joined: 27 Apr 2011
Total Posts: 27115
18 Aug 2016 08:35 PM
people who use GetService for EVERYTHING. kms


Report Abuse
Isosta is not online. Isosta
Joined: 10 May 2015
Total Posts: 14729
18 Aug 2016 09:36 PM
"Look if you don't know how to help or read don't say anything. I name my service how I want and if you don't understand that instance is a returning variable from the event you obviously don't know how they work."


getService is only necessary for the services not default loaded into the game, such as the Teams service.
Report Abuse
unwarranted is not online. unwarranted
Joined: 05 Jun 2009
Total Posts: 1087
18 Aug 2016 10:05 PM
game:GetService'Workspace' gives you a constant reference to workspace, because if an exploiter changes the name of workspace to something different, game.workspace will error. so game:GetService'Workspace' would be the best thing to do


Report Abuse
Lua_Basics is not online. Lua_Basics
Joined: 04 Jun 2012
Total Posts: 9977
18 Aug 2016 10:06 PM
@Time I have a habit of that, forgive me. Also you can literally just type workspace. [2]
Report Abuse
Lua_Basics is not online. Lua_Basics
Joined: 04 Jun 2012
Total Posts: 9977
18 Aug 2016 10:07 PM
If a exploiter changes the name of workspace... this killed me...
Report Abuse
Flux_Capacitor is not online. Flux_Capacitor
Joined: 07 Apr 2008
Total Posts: 45720
18 Aug 2016 10:07 PM
I do it out of consistency.

local WorkspaceService = game:GetService("Workspace")
local PlayersService = game:GetService("Players")
local HTTPService = game:GetService("HttpService")
etc
Report Abuse
unwarranted is not online. unwarranted
Joined: 05 Jun 2009
Total Posts: 1087
18 Aug 2016 10:13 PM
local workplace = game:GetService'Workspace'

game.Workspace.Name = 'not workspace'

print(workplace.Name)

print(game.Workspace.Name)

>'not workspace'
>'not workspace'
turns out game.Workspace references to workspace no matter the name anyways, oh well


Report Abuse
Skellobit is not online. Skellobit
Joined: 13 Apr 2016
Total Posts: 12758
18 Aug 2016 10:13 PM
is the workspace keyword equivalent to game.Workspace or game:GetService("Workspace")

Formerly ToxicDominator - add 17,509 posts
Report Abuse
unwarranted is not online. unwarranted
Joined: 05 Jun 2009
Total Posts: 1087
18 Aug 2016 10:14 PM
workspace == game.Workspace == game:GetService'Workspace'
they all function the same


Report Abuse
thedailyblarg is not online. thedailyblarg
Joined: 26 Feb 2012
Total Posts: 5506
18 Aug 2016 10:14 PM
workspace is a variable defined by roblox to set to the workspace in all scripts
Report Abuse
Lua_Basics is not online. Lua_Basics
Joined: 04 Jun 2012
Total Posts: 9977
18 Aug 2016 10:15 PM
Yep, its for lazy people like me.
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