Jump to content
  • 0

pc.give_item all in map


Minion

Question

  • Answers 3
  • Created
  • Last Reply

Top Posters For This Question

Popular Days

3 answers to this question

Recommended Posts

  • 0

This should work:

when x.chat."Test" with pc.is_gm() begin
	local map = input()
	server_timer('give_items', 1, tonumber(map))
end

when give_items.server_timer begin
	local vnum,count = 27003,200
	pc.give_item2(vnum,count)
	clear_server_timer('give_items', get_server_timer_arg())
end
Link to comment
Share on other sites

  • 0

 

This should work:

when x.chat."Test" with pc.is_gm() begin
	local map = input()
	server_timer('give_items', 1, tonumber(map))
end

when give_items.server_timer begin
	local vnum,count = 27003,200
	pc.give_item2(vnum,count)
	clear_server_timer('give_items', get_server_timer_arg())
end

= crash server. pc.give_item2 is not global function

  • Love 1
Link to comment
Share on other sites

  • 0
  • Honorable Member

This should work:

when x.chat."Test" with pc.is_gm() begin
	local map = input()
	server_timer('give_items', 1, tonumber(map))
end

when give_items.server_timer begin
	local vnum,count = 27003,200
	pc.give_item2(vnum,count)
	clear_server_timer('give_items', get_server_timer_arg())
end

You can't use "pc" inside a server_time "scope".

Maybe an "enter" event could make a difference, otherwise it's simple to create such a thing via source.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Activity

    1. 8

      When Uninstalling Gaya System

    2. 8

      When Uninstalling Gaya System

    3. 8

      When Uninstalling Gaya System

    4. 8

      When Uninstalling Gaya System

    5. 8

      When Uninstalling Gaya System

    6. 8

      Use Items with the Effect of Use

    7. 8

      When Uninstalling Gaya System

    8. 8

      When Uninstalling Gaya System

    9. 8

      When Uninstalling Gaya System

  • Recently Browsing

    • No registered users viewing this page.
×
×
  • 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.