Post Pacific  

Go Back   Post Pacific > Lineage 2 > Lineage 2 Help

Notices

 
 
Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old 05.07.2006, 10:44   #3
FidoW
Архивный участник
 
Join Date: Sep 2005
Posts: 1,014
Default

I know is possible to do with SQL language but i dont know a lot about it... i can do it very easy with PHP.

When server is offline... you can execute a script to add a item to all users.

something like this...
this is very basic script... i wrote that in 1 minute right now.

[php:1:1baf63400d]
<?

$item_id = 57;
$amount = 10000;

$query = "SELECT TOP 1 char_id FROM user_data ORDER by char_id DESC";
$result = mssql_query($query);
$last_char_id = mssql_result($result, 0, 0);

for($i=0;$i<=$last_char_id;$i++)
{
$query2 = "INSERT INTO user_item (char_id,item_type,amount,enchant,eroded,bless,ide nt,wished,warehouse) VALUES ($i,$item_id,$amount,0,0,0,0,0,0)";
mssql_query($query2);
}

?>[/php:1:1baf63400d]

I dont test that but it must work i think.
FidoW is offline  
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07:51.