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: Anti Damaging Without FF

Previous Thread :: Next Thread 
Crazy010517 is not online. Crazy010517
Joined: 17 Sep 2011
Total Posts: 1161
07 Dec 2015 10:29 PM
Is there a way to make a player invincible without FFs and without changing a player's health to math.huge?
Report Abuse
JarodOfOrbiter is not online. JarodOfOrbiter
Joined: 17 Feb 2011
Total Posts: 20029
07 Dec 2015 10:36 PM
Yeah, you could modify the scripts that are doing damage.
Report Abuse
ForeverDev is not online. ForeverDev
Joined: 04 Oct 2008
Total Posts: 13300
07 Dec 2015 10:40 PM
^
Report Abuse
DrHaximus is not online. DrHaximus
Joined: 22 Nov 2011
Total Posts: 8410
07 Dec 2015 10:45 PM
tURN THE PLlAYER INTO A BLOCK
Report Abuse
JarodOfOrbiter is not online. JarodOfOrbiter
Joined: 17 Feb 2011
Total Posts: 20029
07 Dec 2015 10:47 PM
The player can't be damaged if he is kicked! Kick him!
Report Abuse
BlueKeyblades is not online. BlueKeyblades
Joined: 11 Oct 2014
Total Posts: 220
07 Dec 2015 10:49 PM
1. Have a BoolValue in the player.
2. Make the Damage script check if its true, if so, then do the damage, else, don't do the damage.
3. Then changed the Bool's value to meet your needs.

[Work not tested, not bested.]
Report Abuse
Crazy010517 is not online. Crazy010517
Joined: 17 Sep 2011
Total Posts: 1161
07 Dec 2015 10:52 PM
But you see, my game is like almost done and it would take FOREVER to change all the scripts that damage .-.
Report Abuse
JarodOfOrbiter is not online. JarodOfOrbiter
Joined: 17 Feb 2011
Total Posts: 20029
07 Dec 2015 10:53 PM
This is why ModuleScripts are awesome.
Report Abuse
ForeverDev is not online. ForeverDev
Joined: 04 Oct 2008
Total Posts: 13300
07 Dec 2015 10:56 PM
^^^^^^^^^^^

If you had a module script, you could define a function such as:

function module.DealDamage(player, amount)
player.Character.Humanoid:TakeDamage(amount)
end

and if you wanted to make the player invincible, you could have some sort of bool value in their player that marks invincibility:

function module.DealDamage(player, amount)
if player.IsInvincible.Value then
return
end
player.Character.Humanoid:TakeDamage(amount)
end

and now in all the gun scripts, you could call

module.DealDamage(some_player, 50)

and you can edit the DealDamage function and have it apply to all guns
Report Abuse
BlueKeyblades is not online. BlueKeyblades
Joined: 11 Oct 2014
Total Posts: 220
07 Dec 2015 11:08 PM
In SAOR (Game I'm in charge of developing) I have a central script with all the health related stuff, and 1 script to control the damage output of all weapons equipped (Given as I made my own tool system) and that 1 script will always check for the Invulnerability bool within the Player's model. Easy as that.

[Work not tested, not bested.]
Report Abuse
benthanh123 is not online. benthanh123
Joined: 27 May 2010
Total Posts: 567
07 Dec 2015 11:09 PM
Change the humanoid name
Report Abuse
Belleq is not online. Belleq
Joined: 05 Jun 2014
Total Posts: 21703
07 Dec 2015 11:12 PM
@ben that also disables reset tho ..
Report Abuse
Belleq is not online. Belleq
Joined: 05 Jun 2014
Total Posts: 21703
07 Dec 2015 11:13 PM
and will also most likely result in a lot of errors in the damage scripts
Report Abuse
benthanh123 is not online. benthanh123
Joined: 27 May 2010
Total Posts: 567
07 Dec 2015 11:15 PM
Then if he doesn't want that then he is going to have to do what everyone else said, edit the script
Report Abuse
Belleq is not online. Belleq
Joined: 05 Jun 2014
Total Posts: 21703
07 Dec 2015 11:16 PM
I still don't understand why he wouldn't want math.huge lol
Report Abuse
Crazy010517 is not online. Crazy010517
Joined: 17 Sep 2011
Total Posts: 1161
07 Dec 2015 11:36 PM
First of all, Hi Belleq.
Second, I don't want math.huge because it doesn't look as cool Lmfao.
But anyways, I was planning on making a damage module script but I guess I forgot to. Now that you reminded me, i guess I will. That will probably be the best way.
Report Abuse
Crazy010517 is not online. Crazy010517
Joined: 17 Sep 2011
Total Posts: 1161
07 Dec 2015 11:37 PM
Also, should i be using remote functions or module scripts?
Report Abuse
hkep is not online. hkep
Joined: 19 Jul 2014
Total Posts: 550
07 Dec 2015 11:54 PM
Honestly module scripts are for keeping scripts shorter, because you could technically define everything in a module script in all the scripts that require it. But if multiple scripts require it, it is a lot of writing.
Plus, module scripts can be used to create settings for other scripts to use.

RemoteFunctions take tuple arguements and return an output value. I don't believe that returning a function works well. But returning simple things is safe.

If you wanted to, you could make a local script use a remote function to get the damage to deal to another player. But the ping would cause a large delay in timing.
Report Abuse
BlueKeyblades is not online. BlueKeyblades
Joined: 11 Oct 2014
Total Posts: 220
08 Dec 2015 04:08 PM
I made an anti haxor module script that, when called with 2 arguments (The player and the damage.) it applies the damage and compares it to the server max damage, if it exceeds it, it kicks the player carried with the argument, and returns their UserId to be later added to a table. So yes, Module Scripts can return values from functions rather easily.

[Work not tested, not bested.]
Report Abuse
Crazy010517 is not online. Crazy010517
Joined: 17 Sep 2011
Total Posts: 1161
08 Dec 2015 08:58 PM
Why would you need an anti haxor script if your game is FilteringEnabled?
Report Abuse
wonderful72pike is not online. wonderful72pike
Joined: 13 Jul 2010
Total Posts: 7009
08 Dec 2015 08:59 PM
@Crazy

Change the name of their Humanoid, then all the scripts won't be able to find it. Problem solved.
Report Abuse
Crazy010517 is not online. Crazy010517
Joined: 17 Sep 2011
Total Posts: 1161
08 Dec 2015 09:45 PM
And every single script will break and be unable to continue...
Report Abuse
BlueKeyblades is not online. BlueKeyblades
Joined: 11 Oct 2014
Total Posts: 220
09 Dec 2015 12:50 AM
Whether or not you use FE you can still change values in a game and there are other exploits that are possible.
So it wouldn't matter.
Plus its fun to kick exploiters OuO

[Work not tested, not bested.]
Report Abuse
vlekje513 is not online. vlekje513
Joined: 28 Dec 2010
Total Posts: 9057
09 Dec 2015 08:02 AM
I'm still with Dr or Jarod.
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