L2J Revision 6291:
L2JDP Revision 9641:
Hello,
I have to create a npc vote with rewards, I thought the base directly inject the item in the player's inventory but I saw on the forum that it was not recommended because it could be duplication.
So I'd like to know if it is possible to make a SQL query from a NPC, if so, how?
thank you very much (and sorry for my english...)
NPC vote
Forum rules
READ NOW: L2j Forums Rules of Conduct
READ NOW: L2j Forums Rules of Conduct
- Zoey76
- L2j Inner Circle
- Posts: 7008
- Joined: Tue Aug 11, 2009 3:36 am
Re: NPC vote
I'd use (and used in the past) Premium Items service, you add the items to the table and run a task ever 5 min to check if there are items there and then send those items, player gets a notification ingame if it's logged, otherwise next time player logs.
Powered by Eclipse 4.34
| Eclipse Temurin 21
| MariaDB 11.3.2
| L2J Server 2.6.3.0 - High Five 
Join our Discord! 

-
- Posts: 15
- Joined: Thu Dec 05, 2013 9:11 pm
Re: NPC vote
Thanks you very much for your help !
But i don't find where is the "Premium Items service" table, can say where it is ?
Thanks
EDIT: I found the table, thanks ^^
But i don't find where is the "Premium Items service" table, can say where it is ?
Thanks
EDIT: I found the table, thanks ^^
-
- Posts: 15
- Joined: Thu Dec 05, 2013 9:11 pm
Re: NPC vote
What is the column difference between "itemNum" and "itemId" column ?
I don't understand..
Thank you very much !

I don't understand..
Thank you very much !
- St3eT
- Posts: 961
- Joined: Sun Mar 07, 2010 6:50 pm
Re: NPC vote
itemId == ID for the item
itemNum == count of items
itemNum == count of items
-
- Posts: 15
- Joined: Thu Dec 05, 2013 9:11 pm
Re: NPC vote
no, because there are a "itemCount" column 

-
- Posts: 15
- Joined: Thu Dec 05, 2013 9:11 pm
Re: NPC vote
someone can help me for add premium item in the database ? it's not working 
i tried this :
character_premium_items structure
1 charId int(11) => 268484003
2 itemNum int(11) => ?????
3 itemId int(11) => 17 (wooden arrow)
4 itemCount bigint(20) => 1
5 itemSender varchar(50) => "Test"
I see the notification IG but i can't withdraw the item...

i tried this :
character_premium_items structure
1 charId int(11) => 268484003
2 itemNum int(11) => ?????
3 itemId int(11) => 17 (wooden arrow)
4 itemCount bigint(20) => 1
5 itemSender varchar(50) => "Test"
I see the notification IG but i can't withdraw the item...