Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Short question about Gold, how to give it ?
#1
Can someone tell me how to add gold for player ?
I didn't find any function for giving money for player on wiki.
If gold is item with specific value, can you give me instance of it?

Ps. Sorry for a lot of new threads with problems, but I really want to start server and only you can help me :/
[Image: pjDBIfE.gif]
Reply
#2
http://gothic-online.com.pl/new_wiki/ind...e=GiveItem

Example code:
Squirrel Script
  1. addEventHandler("onPlayerConnect",function(pid)
  2. {
  3. giveItem(pid, Items.id("ITMI_GOLD"), 1000)
  4. })



@Edit
Rembember to register item that you want to give in Items.xml file.
Reply
#3
Thank you, I found instance ITMI_GOLD and I tried giveItem function, but I didn't know that I must register this item in Items.xml manually.
Thank you so much !
[Image: pjDBIfE.gif]
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Give- / Removeitems on Focus ItschiAtschiUtschi 3 2,420 10.06.2020, 16:04
Last Post: Patrix
  Give random item for Player liegav 6 6,355 14.02.2018, 18:30
Last Post: Patrix
  Database and other Question (new team) Kemi 18 12,204 09.02.2016, 22:23
Last Post: Kemi
  Question for programmer's [GO] Kladvey 9 6,906 27.12.2015, 03:12
Last Post: Bimbol

Forum Jump:


Users browsing this thread: 1 Guest(s)