RockGodDev
(RockGodDev)
August 17, 2024, 3:46pm
#1
I have a table called “playerData.ActiveBoosts”. In that table, there are boosts that are added into the table once a player uses said boost, and I want to add in a countdown (1800 seconds) into the boost. And this does not work.
Code that inserts boost/error/the table itself:
you could try having the key value pairs in the ActiveBoosts table being the boost/cooldown, which you could do like this:
playerData.ActiveBoosts[boost] = 1800
This would make the structure of the ActiveBoosts table look like:
{
["KeybugToken"] = 1800,
...
}
1 Like
TestyLike3
(TestyLike3)
August 17, 2024, 3:58pm
#4
You’re trying to index the table with the value you just inserted into it. Try doing:
table.insert(table.find(playerData.ActiveBoosts[boost]), 1800)
I would recommend the above method however.
system
(system)
Closed
August 31, 2024, 3:58pm
#5
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.