Skip to content

Commit

Permalink
Merge branch 'develop' into cooking-skill-bug-fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Xoduz authored Jan 26, 2025
2 parents 7b553d8 + 8a95894 commit 4ca6e77
Show file tree
Hide file tree
Showing 55 changed files with 1,406 additions and 102 deletions.
1 change: 1 addition & 0 deletions data/dfndata/items/gmmenu/spawners.dfn
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ interval=1 5
visible=1
decay=0
movable=2
script=2205
}

[orcspawn]
Expand Down
49 changes: 49 additions & 0 deletions data/dfndata/items/lootlists.dfn
Original file line number Diff line number Diff line change
Expand Up @@ -962,4 +962,53 @@
100|PaintedPlagueMask
100|PaintedDaemonMask
100|PaintedEvilClownMask
}

// Treasure Map Level 0
[LOOTLIST TreasureMapLvl0Loot]
{//approximately 1%
990|blank
10|treasuremaplvl0
}

// Treasure Map Level 1
[LOOTLIST TreasureMapLvl1Loot]
{//approximately 1%
990|blank
10|treasuremaplvl1
}

// Treasure Map Level 2
[LOOTLIST TreasureMapLvl2Loot]
{//approximately 1%
990|blank
10|treasuremaplvl2
}

// Treasure Map Level 3
[LOOTLIST TreasureMapLvl3Loot]
{//approximately 1%
990|blank
10|treasuremaplvl3
}

// Treasure Map Level 4
[LOOTLIST TreasureMapLvl4Loot]
{//approximately 1%
990|blank
10|treasuremaplvl4
}

// Treasure Map Level 5
[LOOTLIST TreasureMapLvl5Loot]
{//approximately 1%
990|blank
10|treasuremaplvl5
}

// Treasure Map Level 6
[LOOTLIST TreasureMapLvl6Loot]
{//approximately 1%
990|blank
10|treasuremaplvl6
}
8 changes: 4 additions & 4 deletions data/dfndata/skills/skills.dfn
Original file line number Diff line number Diff line change
Expand Up @@ -1206,10 +1206,10 @@ SKILLPOINT=990,5,0
SKILLPOINT=1000,0,0
}

// Imbuing
// Mysticism
[SKILL 55]
{
NAME=IMBUING
NAME=MYSTICISM
STR=0
DEX=0
INT=0
Expand All @@ -1227,10 +1227,10 @@ SKILLPOINT=990,5,0
SKILLPOINT=1000,0,0
}

// Mysticism
// Imbuing
[SKILL 56]
{
NAME=MYSTICISM
NAME=IMBUING
STR=0
DEX=0
INT=0
Expand Down
1 change: 1 addition & 0 deletions data/dictionaries/dictionary.CSY
Original file line number Diff line number Diff line change
Expand Up @@ -3431,6 +3431,7 @@
6301=Z této knihy se může učit pouze velmistr alchymista.
6302=Tyto informace jste se již dozvěděli.
6303=Naučili jste se vyrábět předměty ze skla. K výrobě těchto předmětů budete muset najít horníky, kteří budou těžit jemný písek.
6304=Musíte mít volnou ruku, abyste mohli pít lektvar.
// [7000-7499] AI Scripts
7000=Jsi zločinec a nemáš přístup ke své bankovní schránce.
7001=Který předmět si přeješ uložit do své bankovní schránky?
Expand Down
1 change: 1 addition & 0 deletions data/dictionaries/dictionary.ENG
Original file line number Diff line number Diff line change
Expand Up @@ -3431,6 +3431,7 @@
6301=Only a Grandmaster Alchemist can learn from this book.
6302=You have already learned this information.
6303=You have learned to make items from glass. You will need to find miners to mine fine sand for you to make these items.
6304=You must have a free hand to drink a potion.
// [7000-7499] AI Scripts
7000=Thou art a criminal and cannot access thy bank box.
7001=Which item do you wish to deposit in your bank box?
Expand Down
1 change: 1 addition & 0 deletions data/dictionaries/dictionary.FRE
Original file line number Diff line number Diff line change
Expand Up @@ -3595,6 +3595,7 @@
6301=Seul un grand maître alchimiste peut apprendre de ce livre.
6302=Vous avez déjà appris cette information.
6303=Vous avez appris à fabriquer des objets en verre. Vous devrez trouver des mineurs pour extraire du sable fin pour fabriquer ces objets.
6304=Vous devez avoir les mains libres pour boire une potion.
// [7000-7499] AI Scripts
7000=Tu es un criminel et tu ne peux pas accéder à ton coffre de banque.
7001=Quel objet souhaitez-vous déposer dans votre coffret bancaire ?
Expand Down
1 change: 1 addition & 0 deletions data/dictionaries/dictionary.GER
Original file line number Diff line number Diff line change
Expand Up @@ -3431,6 +3431,7 @@
6301=Nur ein Großmeister-Alchemist kann aus diesem Buch lernen.
6302=Sie haben diese Informationen bereits erfahren.
6303=Du hast gelernt, Gegenstände aus Glas herzustellen. Sie müssen Bergleute finden, die feinen Sand abbauen, damit Sie diese Gegenstände herstellen können.
6304=Sie müssen freie Hand haben, um einen Trank zu trinken.
// [7000-7499] AI Scripts
7000=Du bist ein Verbrecher und kannst nicht auf dein Bankschließfach zugreifen.
7001=Welchen Gegenstand möchten Sie in Ihr Bankschließfach einzahlen?
Expand Down
1 change: 1 addition & 0 deletions data/dictionaries/dictionary.ITA
Original file line number Diff line number Diff line change
Expand Up @@ -3431,6 +3431,7 @@
6301=Solo un Grande Maestro Alchimista può imparare da questo libro.
6302=Hai già appreso questa informazione.
6303=Hai imparato a creare oggetti in vetro. Dovrai trovare minatori che estraggano sabbia fine per poter realizzare questi oggetti.
6304=Devi avere una mano libera per bere una pozione.
// [7000-7499] AI Scripts
7000=Tu sei un criminale e non puoi accedere alla tua cassaforte.
7001=Quale oggetto desidera depositare nella sua cassetta di sicurezza?
Expand Down
1 change: 1 addition & 0 deletions data/dictionaries/dictionary.POL
Original file line number Diff line number Diff line change
Expand Up @@ -3431,6 +3431,7 @@
6301=Tylko Wielki Mistrz Alchemik może uczyć się z tej książki.
6302=Te informacje już znasz.
6303=Nauczyłeś się robić przedmioty ze szkła. Będziesz musiał znaleźć górników, którzy wydobędą drobny piasek, aby móc wyprodukować te przedmioty.
6304=Musisz mieć wolną rękę, żeby wypić miksturę.
// [7000-7499] AI Scripts
7000=Jesteś przestępcą i nie masz dostępu do swojej skrytki bankowej.
7001=Którą pozycję chcesz umieścić w swojej skrytce bankowej?
Expand Down
1 change: 1 addition & 0 deletions data/dictionaries/dictionary.PTG
Original file line number Diff line number Diff line change
Expand Up @@ -3431,6 +3431,7 @@
6301=Apenas um Grão-Mestre Alquimista pode aprender com este livro.
6302=Você já aprendeu esta informação.
6303=Você aprendeu a fazer itens de vidro. Você precisará encontrar mineiros para extrair areia fina para fazer esses itens.
6304=Você deve ter a mão livre para beber uma poção.
// [7000-7499] AI Scripts
7000=Tu és um criminoso e não podes aceder à tua caixa bancária.
7001=Que artigo deseja depositar na sua caixa bancária?
Expand Down
1 change: 1 addition & 0 deletions data/dictionaries/dictionary.SPA
Original file line number Diff line number Diff line change
Expand Up @@ -3431,6 +3431,7 @@
6301=Sólo un Gran Maestro Alquimista puede aprender de este libro.
6302=Ya has aprendido esta información.
6303=Has aprendido a fabricar objetos de vidrio. Necesitará encontrar mineros que extraigan arena fina para poder fabricar estos artículos.
6304=Debes tener las manos libres para beber una poción.
// [7000-7499] Guiones de IA
7000=Eres un delincuente y no puedes acceder a tu caja bancaria.
7001=¿Qué artículo desea depositar en su caja?
Expand Down
1 change: 1 addition & 0 deletions data/dictionaries/dictionary.ZRO
Original file line number Diff line number Diff line change
Expand Up @@ -3426,6 +3426,7 @@
6301=Only a Grandmaster Alchemist can learn from this book.
6302=You have already learned this information.
6303=You have learned to make items from glass. You will need to find miners to mine fine sand for you to make these items.
6304=You must have a free hand to drink a potion.
// [7000-7499] AI Scripts
7000=Thou art a criminal and cannot access thy bank box.
7001=Which item do you wish to deposit in your bank box?
Expand Down
56 changes: 56 additions & 0 deletions data/js/combat/leechstats.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
function onEquip( pEquipper, iEquipped )
{
pEquipper.AddScriptTrigger( 7003 );
}

// Remove script trigger on unequip
function onUnequip( pUnequipper, iUnequipped )
{
pUnequipper.RemoveScriptTrigger( 7003 );
}

function onDamageDeal( attacker, damaged, damageValue, damageType )
{
// Fetch weapon in main hand or secondary hand
var iWeapon = attacker.FindItemLayer( 0x01 );
if( !ValidateObject( iWeapon ))
{
iWeapon = attacker.FindItemLayer( 0x02 );
}

if( ValidateObject( iWeapon ))
{ // Apply leech effects based on weapon properties
ApplyLeech( attacker, damaged, damageValue, iWeapon, 'healthLeech', 30 );
ApplyLeech( attacker, damaged, damageValue, iWeapon, 'staminaLeech', 100 );
ApplyLeech( attacker, damaged, damageValue, iWeapon, 'manaLeech', 40 );
}

return true;
}

function ApplyLeech( attacker, damaged, damageValue, weapon, leechType, multiplier )
{
// Get the leech amount for the specified leech type from the weapon
var leechPercentVal = weapon[ leechType ];
if( leechPercentVal > 0 )
{
// Calculate the percent of health restored to the attacker
var leechAmt = Math.round( damageValue * ( leechPercentVal / 100 ) * ( multiplier/100 ));

// Apply the leech effect based on the leech type
switch( leechType )
{
case 'healthLeech':
attacker.Heal( leechAmt );
break;
case 'staminaLeech':
attacker.stamina += leechAmt;
break;
case 'manaLeech':
attacker.mana += leechAmt;
break;
}

attacker.SoundEffect( 0x44D, true );
}
}
42 changes: 32 additions & 10 deletions data/js/commands/targeting/get.js
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,9 @@ function onCallback0( socket, ourObj )
case "SECTIONID":
socket.SysMessage( ourObj.sectionID );
break;
case "SWINGSPEEDINC":
socket.SysMessage( swingSpeedIncrease );
break;
case "SHOULDSAVE":
socket.SysMessage( ourObj.shouldSave );
break;
Expand Down Expand Up @@ -294,30 +297,30 @@ function HandleGetItem( socket, ourItem, uKey )
case "DESC":
socket.SysMessage( ourItem.desc );
break;
case "DEF":
socket.SysMessage( ourItem.Resist( 1 ));
break;
case "DEF":
case "RESISTARMOR":
socket.SysMessage( ourObj.Resist( 1 ));
socket.SysMessage( ourItem.Resist( 1 ));
break;
case "RESISTLIGHT":
socket.SysMessage( ourObj.Resist( 2 ));
socket.SysMessage( ourItem.Resist( 2 ));
break;
case "RESISTWATER":
socket.SysMessage( ourObj.Resist( 3 ));
socket.SysMessage( ourItem.Resist( 3 ));
break;
case "RESISTCOLD":
socket.SysMessage( ourObj.Resist( 4 ));
socket.SysMessage( ourItem.Resist( 4 ));
break;
case "RESISTFIRE":
socket.SysMessage( ourObj.Resist( 5 ));
socket.SysMessage( ourItem.Resist( 5 ));
break;
case "RESISTENERGY":
socket.SysMessage( ourObj.Resist( 6 ));
socket.SysMessage( ourItem.Resist( 6 ));
break;
case "RESISTPOISON":
socket.SysMessage( ourObj.Resist( 7 ));
socket.SysMessage( ourItem.Resist( 7 ));
break;
case "LOWERSTATREQ":
socket.SysMessage( ourObj.lowerStatReq );
break;
case "ARMORCLASS":
case "ARMOURCLASS":
Expand Down Expand Up @@ -598,8 +601,27 @@ function HandleGetChar( socket, ourChar, uKey )
break;
case "ARMOUR":
case "ARMOR":
case "RESISTARMOR":
socket.SysMessage( ourChar.Resist( 1 ));
break;
case "RESISTLIGHT":
socket.SysMessage( ourChar.Resist( 2 ));
break;
case "RESISTWATER":
socket.SysMessage( ourChar.Resist( 3 ));
break;
case "RESISTCOLD":
socket.SysMessage( ourChar.Resist( 4 ));
break;
case "RESISTFIRE":
socket.SysMessage( ourChar.Resist( 5 ));
break;
case "RESISTENERGY":
socket.SysMessage( ourChar.Resist( 6 ));
break;
case "RESISTPOISON":
socket.SysMessage( ourChar.Resist( 7 ));
break;
case "MAXHP":
socket.SysMessage( ourChar.maxhp );
break;
Expand Down
8 changes: 8 additions & 0 deletions data/js/commands/targeting/set.js
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,10 @@ function onCallback0( socket, ourObj )
ourObj.Resist( 7, nVal );
okMsg( socket );
break;
case "LOWERSTATREQ":
ourItem.lowerStatReq = nVal;
okMsg( socket );
break;
case "HP":
case "HEALTH":
ourObj.health = nVal;
Expand Down Expand Up @@ -169,6 +173,10 @@ function onCallback0( socket, ourObj )
ourObj.tempdex = nVal;
okMsg( socket );
break;
case "SWINGSPEEDINC":
ourObj.swingSpeedIncrease = nVal;
okMsg( socket );
break;
case "WIPABLE":
case "WIPEABLE":
ourObj.wipable = ( nVal == 1 );
Expand Down
2 changes: 1 addition & 1 deletion data/js/item/holidays/addondeedgump.js
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ function CheckForNearbyDoors( myTarget, itemToCheck, pSocket )
}
}

if( myTarget.DistanceTo(itemToCheck) <= 2 )
if( myTarget.DistanceTo( itemToCheck ) <= 2 )
{
return true;
}
Expand Down
2 changes: 0 additions & 2 deletions data/js/item/holidays/candy.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,13 @@ function onUseChecked(pUser, iUsed)
}
else
{
socket.SysMessage("test 1");
if( Acidity <= 30 )
{
pUser.SetTempTag( "Acidity", Acidity += 5 );
}

if ( Toothach == 0)
{
socket.SysMessage("test 2");
pUser.SetTempTag( "toothach", 1 );
pUser.StartTimer( 1000, 0, true );
}
Expand Down
2 changes: 1 addition & 1 deletion data/js/item/holidays/halloweenmasks.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ function onCreateDFN( objMade, objType )
if( objType == 0 )
{
var maskname = "";
switch(objMade.GetTag( "paintedmask" ))
switch( objMade.GetTag( "paintedmask" ))
{
case 1: maskname = "A Evil Clown Mask"; break;
case 2: maskname = "A Daemon Mask"; break;
Expand Down
6 changes: 3 additions & 3 deletions data/js/item/holidays/headonaspike.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ function onUseChecked( pUser, iUsed )
var headspike = new Gump;
var head = 0;

switch (iUsed.sectionID)
switch( iUsed.sectionID )
{
case "MrsTroubleMakersHeadOnASpike": head = 30522; break;
case "BrutrinsHeadOnASpike": head = 30522; break;
Expand All @@ -20,7 +20,7 @@ function onUseChecked( pUser, iUsed )
default: head = 30522;
}

headspike.AddGump(100, 100, head);
headspike.Send(pUser);
headspike.AddGump( 100, 100, head );
headspike.Send( pUser );
headspike.Free();
}
Loading

0 comments on commit 4ca6e77

Please sign in to comment.