![]() |
|
|
|
|
#1 |
|
Guest
Posts: n/a
|
Probably some of you know that one of the changes in Interlude was that Prime Hours thing, whats that ? During some hours of the day (the hours when servers has more players connected) the price of GKs are reduced, so, if we want to implement this first we need to modify teleport AI TELEPORT_REQUESTED handler and here is the needed code and compiled ofc.
You will need to add to each single teleporter a new telposlist called PositionPH, that telposlist will have the reduced prices. Be carefull addin this because if you forgot to add that new telposlist to all GKs when Prime Hours come that GK isnt going to work, is going to show only the default parameters, in this case, Talking Island only Roll Eyes (Sarcastic) Thanks to Sauron because he give me a hint when i was trying to code this and inspire this job. Compiled by hand and brain, as always, there is no better compiler than your own mind Cool This is the NASC code of the addon (not the entire AI), requested by smeli... this is free, not DCs Smile Code: Code:
if( PrimeHours )
{
i0 = gg->GetDateTime(0,3);
i1 = gg->GetDateTime(0,6);
if ( (i0 >= PHfromHour) && (i0 <= PHtoHour) && (i1 >= PHfromDay) && (i1 <= PHtoDay) )
{
myself->Teleport(talker,PositionPH,ShopName,"","","",57,myself->MakeFString(1000308,"","","","",""));
return;
}
}
Восстановлено из публичного снимка Wayback Machine. Тема могла сохраниться частично. Дата оценена по относительному времени в снимке (2 Days Ago); точное время не сохранилось. Открыть источник. |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|