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 » Scripting Helpers
Home Search
 

Re: Help me decipher this please

Previous Thread :: Next Thread 
jd678 is not online. jd678
Joined: 18 Apr 2008
Total Posts: 11529
04 Sep 2013 11:05 PM
playerPositions = {}
local p = game.Players:GetChlidren()
for i, p in pairs (p) do
if p.Character then
local current = #playerPositions
if (playerPositions[current-1].X < playerPositions[current].X) then
playerMovement = North


gahhh



--Jd678, got 1 dayer cause forum moderation system can't read.
Report Abuse
YEGGOR is not online. YEGGOR
Joined: 02 Apr 2013
Total Posts: 1150
04 Sep 2013 11:08 PM
did you write this script?
Report Abuse
noah is not online. noah
Joined: 11 Sep 2006
Total Posts: 18977
04 Sep 2013 11:12 PM
local p = game.Players:GetChlidren()
for i, p in pairs (p) do

You have 2 different things with the same variable.
Report Abuse
jd678 is not online. jd678
Joined: 18 Apr 2008
Total Posts: 11529
04 Sep 2013 11:22 PM
@Yeggor

my friend is helping me write it yes

but I don't quite understand the last part

@noah

it still works that way, because I've done that in the past lol



--Jd678, got 1 dayer cause forum moderation system can't read.
Report Abuse
jd678 is not online. jd678
Joined: 18 Apr 2008
Total Posts: 11529
04 Sep 2013 11:25 PM
playerPositions = {}
dist = 20
while true do
wait(0.2)
local p = game.Players:GetChildren()
for i,p in pairs (p) do
if p.Character then
if ((p.Character.Torso.Position - script.Parent.Position).magnitude < dist) then
local current = #playerPositions
p.Character.Torso.Position.X current
if (playerPositions[current-1].X < playerPositions[current].X) then
playerMovement = North


ignore lack of ends please

help me gather like, a structure to what I am attempting to do



--Jd678, got 1 dayer cause forum moderation system can't read.
Report Abuse
blocco is not online. blocco
Joined: 14 Aug 2008
Total Posts: 29474
04 Sep 2013 11:27 PM
This code is incomplete. What's the full code?
Report Abuse
noah is not online. noah
Joined: 11 Sep 2006
Total Posts: 18977
04 Sep 2013 11:27 PM
Well dat is weird, but what is your question? I dun understand.
Report Abuse
YEGGOR is not online. YEGGOR
Joined: 02 Apr 2013
Total Posts: 1150
04 Sep 2013 11:45 PM
why dont you ask your friend what it means :p
Report Abuse
jd678 is not online. jd678
Joined: 18 Apr 2008
Total Posts: 11529
05 Sep 2013 12:02 AM
he wen't to sleep qq

and I don't have the full code, i guess I'll wait lol



--Jd678, got 1 dayer cause forum moderation system can't read.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • 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