From a646c10a086120b3d0b3ef9cbe043df899fd8e34 Mon Sep 17 00:00:00 2001 From: UndeadZeratul Date: Mon, 29 Jun 2026 19:35:55 -0500 Subject: [PATCH 1/3] Sync Micro-Cells with HDBattery Looks like the help text did get consolidated, if we want to split them back out we can always come back to these. Also added an empty dummy spawner --- zscript/HDBulletLib/Ammunition/MicroCells.zsc | 42 +++++++++++++------ 1 file changed, 30 insertions(+), 12 deletions(-) diff --git a/zscript/HDBulletLib/Ammunition/MicroCells.zsc b/zscript/HDBulletLib/Ammunition/MicroCells.zsc index 347b7b8..280a6c3 100644 --- a/zscript/HDBulletLib/Ammunition/MicroCells.zsc +++ b/zscript/HDBulletLib/Ammunition/MicroCells.zsc @@ -13,6 +13,7 @@ class HDMicroCell:HDMagAmmo{ hdpickup.bulk ENC_BATTERY/2; hdmagammo.magbulk ENC_BATTERY/2; hdmagammo.mustshowinmagmanager true; + inventory.pickupmessage "$PICKUP_MICROCELL"; inventory.icon "MCLLA0"; scale 0.4; } @@ -26,9 +27,6 @@ class HDMicroCell:HDMagAmmo{ int ticker; int lastamount; int chargemode; - override string pickupmessage(){ - return Stringtable.Localize("$PICKUP_MICROCELL"); - } override void doeffect(){ //testingdoeffect();return; if(chargemode==BATT_UNDEFINED)chargemode=BATT_CHARGEDEFAULT; @@ -57,7 +55,7 @@ class HDMicroCell:HDMagAmmo{ ChargeMicroCell(usetop:true); ChargeMicroCell(); } - + void ChargeMicroCell(int chargestodo=-1,bool usetop=false){ SyncAmount(); if(amount<1)return; @@ -135,7 +133,7 @@ class HDMicroCell:HDMagAmmo{ } override string,string,name,double getmagsprite(int thismagamt){ - string magsprite="MCLLA0"; + string magsprite; if(thismagamt>6)magsprite="MCLLA0"; else if(thismagamt>3)magsprite="MCLLB0"; else if(thismagamt>0)magsprite="MCLLC0"; @@ -147,13 +145,20 @@ class HDMicroCell:HDMagAmmo{ offx+=40; scl=1; let battt=chargemode; - string batts="uNone"; - if(battt==hdbattery.BATT_CHARGEMAX)batts="eAuto"; - else if(battt==hdbattery.BATT_CHARGESELECTED)batts="ySelected"; + string batts="$BATTERYCHARGE_NONE"; + if(battt==hdbattery.BATT_CHARGEMAX)batts="$BATTERYCHARGE_AUTO"; + else if(battt==hdbattery.BATT_CHARGESELECTED)batts="$BATTERYCHARGE_SELECTED"; sb.DrawString( - sb.psmallfont,string.format(Stringtable.Localize("$MBAT_HELPTEXT_1"),helptext?Stringtable.Localize("$MBAT_HELPTEXT_2"):"",batts,helptext?Stringtable.Localize("$MBAT_HELPTEXT_3"):""),(offx+2,offy), - sb.DI_SCREEN_CENTER|sb.DI_TEXT_ALIGN_LEFT, - wrapwidth:smallfont.StringWidth("m")*80 + sb.psmallfont, + (helptext?StringTable.Localize("$BATTERYCHARGE_CHARGING"):"") + .."\c".. + StringTable.Localize(batts).. + (helptext?StringTable.Localize("$BATTERYCHARGE_RELOAD"):"") + , + + (offx+2,offy), + sb.DI_SCREEN_CENTER|sb.DI_TEXT_ALIGN_LEFT, + wrapwidth:smallfont.StringWidth("m")*80 ); sb.drawimage("MCLLA0",(offx,offy), @@ -165,7 +170,7 @@ class HDMicroCell:HDMagAmmo{ itemsthatusethis.push("PhazerPistol"); itemsthatusethis.push("HDStunGun"); } - + states(actor){ spawn: MCLL CAB -1 nodelay{ @@ -179,3 +184,16 @@ class HDMicroCell:HDMagAmmo{ stop; } } +class HDMicroCellEmpty:IdleDummy{ + default{ + //$Category "Ammo/Hideous Destructor/" + //$Title "Micro-Cell (Spent)" + //$Sprite "MCLLD0" + } + override void postbeginplay(){ + super.postbeginplay(); + angle=frandom(0,360); + HDMagAmmo.SpawnMag(self,"HDMicroCell",0); + destroy(); + } +} From 0ab82a7d976567703dd9e6a398d90574daa96a82 Mon Sep 17 00:00:00 2001 From: UndeadZeratul Date: Tue, 4 Aug 2026 12:06:33 -0500 Subject: [PATCH 2/3] Fix .50 OMG Merchant Class Reference --- HDCINFO | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/HDCINFO b/HDCINFO index 7388f44..495a6ef 100644 --- a/HDCINFO +++ b/HDCINFO @@ -294,7 +294,7 @@ newMerchantStoreItem => { "enabled": "#hdb_enable_4gslug", "type": "ammo", "cate newMerchantStoreItem => { "enabled": "#hdb_enable_500sw", "type": "ammo", "category": "$MERCH_CAT_500SWH", "item": "HD500SWHeavyAmmo", "amount": "20", "icon": "5HBXA0", "displayName": "$MERCH_TAG_500SWH", "basePrice": "40", "flavorText": "$MERCH_FLAVOR_500SWH" } newMerchantStoreItem => { "enabled": "#hdb_enable_500sw", "type": "ammo", "category": "$MERCH_CAT_500SWL", "item": "HD500SWLightAmmo", "amount": "40", "icon": "5LBXA0", "displayName": "$MERCH_TAG_500SWL", "basePrice": "50", "flavorText": "$MERCH_FLAVOR_500SWL" } newMerchantStoreItem => { "enabled": "#hdb_enable_50am", "type": "ammo", "category": "$MERCH_CAT_50AM", "item": "HD50AM_Ammo", "amount": "60", "icon": "50AMX0", "displayName": "$MERCH_TAG_50AM", "basePrice": "50", "flavorText": "$MERCH_FLAVOR_50AM" } -newMerchantStoreItem => { "enabled": "#hdb_enable_50omg", "type": "ammo", "category": "$MERCH_CAT_50OMG", "item": "HD50OMG50OMGAmmo", "amount": "20", "icon": "OGBXA0", "displayName": "$MERCH_TAG_50OMG", "basePrice": "70", "flavorText": "$MERCH_FLAVOR_50OMG" } +newMerchantStoreItem => { "enabled": "#hdb_enable_50omg", "type": "ammo", "category": "$MERCH_CAT_50OMG", "item": "HD50OMGAmmo", "amount": "20", "icon": "OGBXA0", "displayName": "$MERCH_TAG_50OMG", "basePrice": "70", "flavorText": "$MERCH_FLAVOR_50OMG" } newMerchantStoreItem => { "enabled": "#hdb_enable_5mmbr", "type": "ammo", "category": "$MERCH_CAT_5MMBR", "item": "HD5mm_Ammo", "amount": "160", "icon": "5MBXA0", "displayName": "$MERCH_TAG_5MMBR", "basePrice": "45", "flavorText": "$MERCH_FLAVOR_5MMBR" } newMerchantStoreItem => { "enabled": "#hdb_enable_6mmflechette", "type": "ammo", "category": "$MERCH_CAT_6MMFLECHETTE", "item": "HD6mmFlechetteAmmo", "amount": "42", "icon": "ACRPK0", "displayName": "$MERCH_TAG_6MMFLECHETTE", "basePrice": "60", "flavorText": "$MERCH_FLAVOR_6MMFLECHETTE" } newMerchantStoreItem => { "enabled": "#hdb_enable_762tokarev", "type": "ammo", "category": "$MERCH_CAT_762TOKAREV", "item": "HD762TokarevAmmo", "amount": "50", "icon": "T7BXA0", "displayName": "$MERCH_TAG_762TOKAREV", "basePrice": "50", "flavorText": "$MERCH_FLAVOR_762TOKAREV" } @@ -306,4 +306,4 @@ newMerchantStoreItem => { "enabled": "#hdb_enable_ndm", "type": "ammo", "categor newMerchantStoreItem => { "enabled": "#hdb_enable_thunderrocket", "type": "ammo", "category": "$MERCH_CAT_THUNDERROCKET", "item": "WAN_ThuRKTAmmo", "amount": "1", "icon": "THRKB0", "displayName": "$MERCH_TAG_THUNDERROCKET", "basePrice": "10", "flavorText": "$MERCH_FLAVOR_THUNDERROCKET" } newMerchantStoreItem => { "enabled": "#hdb_enable_tortoiserocket", "type": "ammo", "category": "$MERCH_CAT_TORTOISEROCKET", "item": "WAN_TortRKTAmmo", "amount": "1", "icon": "TRTRB0", "displayName": "$MERCH_TAG_TORTOISEROCKET", "basePrice": "10", "flavorText": "$MERCH_FLAVOR_TORTOISEROCKET" } newMerchantStoreItem => { "enabled": "#hdb_enable_xshell", "type": "ammo", "category": "$MERCH_CAT_XSHELL", "item": "HDExplosiveShellAmmo", "amount": "20", "icon": "XLBXA0", "displayName": "$MERCH_TAG_XSHELL", "basePrice": "45", "flavorText": "$MERCH_FLAVOR_XSHELL" } -newMerchantStoreItem => { "enabled": "#hdb_enable_microcell", "type": "ammo", "category": "$MERCH_CAT_MICROCELL", "item": "HDMicroCell", "icon": "MCLLA0", "displayName": "$MERCH_TAG_MICROCELL", "basePrice": "15", "flavorText": "$MERCH_FLAVOR_MICROCELL" } \ No newline at end of file +newMerchantStoreItem => { "enabled": "#hdb_enable_microcell", "type": "ammo", "category": "$MERCH_CAT_MICROCELL", "item": "HDMicroCell", "icon": "MCLLA0", "displayName": "$MERCH_TAG_MICROCELL", "basePrice": "15", "flavorText": "$MERCH_FLAVOR_MICROCELL" } From 2d695ac071be059215a27475d75b1ddba59e0ad7 Mon Sep 17 00:00:00 2001 From: UndeadZeratul Date: Tue, 4 Aug 2026 12:09:15 -0500 Subject: [PATCH 3/3] Use new HDCoreLib getMicroCellIcon() helper function --- zscript/HDBulletLib/Ammunition/MicroCells.zsc | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/zscript/HDBulletLib/Ammunition/MicroCells.zsc b/zscript/HDBulletLib/Ammunition/MicroCells.zsc index 280a6c3..92da31c 100644 --- a/zscript/HDBulletLib/Ammunition/MicroCells.zsc +++ b/zscript/HDBulletLib/Ammunition/MicroCells.zsc @@ -132,14 +132,10 @@ class HDMicroCell:HDMagAmmo{ if(hd_debug)LogAmounts(); } - override string,string,name,double getmagsprite(int thismagamt){ - string magsprite; - if(thismagamt>6)magsprite="MCLLA0"; - else if(thismagamt>3)magsprite="MCLLB0"; - else if(thismagamt>0)magsprite="MCLLC0"; - else magsprite="MCLLD0"; - return magsprite,"MCLPA0","HDMicroCell",0.8; + override string,string,name,double getmagsprite(int thismagamt) { + return HDCore.getMicroCellIcon(thismagamt),"MCLPA0","HDMicroCell",0.8; } + override void DrawRoundCount(HDStatusBar sb,HDPlayerPawn hpl,name roundsprite,double scl,int offx,int offy){ bool helptext=hpl.hd_helptext.getbool(); offx+=40;