Jump to content

Recommended Posts

  • Replies 17
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

  • Active Member

Hi, how can i do that: 

local name = pc.get_name()
server_timer(name)


when name.server_time begin

Because this: when name.server_time begin dont working. Thanks anyway

It needs to be triggered by something :) a npc or a player via when login or when kill or something like that :)

 

local name = pc.get_name()

server_timer("name",5)

 

when name.server_timer begin

Link to comment
Share on other sites

  • Premium

I trew:

 

function name()
    local jmeno = mysql_query("SELECT name from player_test.player WHERE name='"..pc.get_name().."' LIMIT 1")
end
when [test_quest.name(jmeno[1])].server_timer begin

and that:

		when (mysql_query("SELECT name from player_test.player WHERE name='"..pc.get_name().."' LIMIT 1")).server_timer begin

but result is the same: name must be give :/

Link to comment
Share on other sites

  • Premium

 

Why you need the player name to be the name for your server timer? Do you want to use it? Or what?

 

I need timer for every player izolate and my first idea was do like that but if you know better solution?

 

 

Timer for every player? Not server timer, but timer. Simple timer.

Or you may work around with server timer arguments, but I don't think it will work for you.

 

You set argument like that:

server_timer("timer_name", time, numeric code)

And you get the argument like that:

when timer_name.server_timer begin
   local arg = get_server_timer_arg()
end

And because it's only numeric code you can use account id (pc.get_account_id())

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.