Jump to content

Recommended Posts

Posted

...
if Map:Load(mapfile)==false then return end

zombiesleft= 0
zombieskilled = 0
roundssurvived = 0
zombiesextrahealth = 0
...

this is in the main.lua script

function Script:NewRound()
roundssurvived= roundssurvived +1
local a = (roundssurvived*.1) + roundssurvived
self.maxEnemies= self.maxEnemies + Math:Round(a)
end

this is in an script attached to a pivot in the scene.

The title is misleading in parts, i havent tried local variables yet but it would be nosense.

 

"...: 41 : attempt to perform arithmetic on field 'currentround' (a nil value)"

I get this error, am very confused since the calculation below this line that I implemented today worked.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...