initial spfn commit

This commit is contained in:
Maple Nebel 2026-05-16 22:18:39 +02:00
commit 00a75e94cb
17 changed files with 140 additions and 80 deletions

View file

@ -19,7 +19,7 @@ WUT_ROOT := $(DEVKITPRO)/wut
# DATA is a list of directories containing data files
# INCLUDES is a list of directories containing header files
#-------------------------------------------------------------------------------
TARGET := Inkay-pretendo
TARGET := Inkay-spfn
BUILD := build
SOURCES := src src/patches src/utils src/ext/inih common
DATA := data

View file

@ -15,7 +15,7 @@
#endif
#ifndef NETWORK_BASEURL
#define NETWORK_BASEURL "pretendo.cc"
#define NETWORK_BASEURL "spfn.cc"
#endif
#endif //INKAY_INKAY_CONFIG_H

View file

@ -19,7 +19,7 @@ WUMS_ROOT := $(DEVKITPRO)/wums
# DATA is a list of directories containing data files
# INCLUDES is a list of directories containing header files
#-------------------------------------------------------------------------------
TARGET := Inkay-pretendo
TARGET := Inkay-spfn
BUILD := build
SOURCES := src src/utils ../common
DATA := data

View file

@ -21,6 +21,9 @@
#include <notifications/notifications.h>
#include <utils/logger.h>
#include "config.h"
#include<coreinit/title.h>
#include<coreinit/dynload.h>
#include<vector>
#include "module.h"
#define INKAY_VERSION "v3.0.0"
@ -29,16 +32,72 @@
Mandatory plugin information.
If not set correctly, the loader will refuse to use the plugin.
**/
WUPS_PLUGIN_NAME("Inkay");
WUPS_PLUGIN_DESCRIPTION("Pretendo Network Patcher");
WUPS_PLUGIN_NAME("Inkay(SPFN)");
WUPS_PLUGIN_DESCRIPTION("SPFN Network Patcher");
WUPS_PLUGIN_VERSION(INKAY_VERSION);
WUPS_PLUGIN_AUTHOR("Pretendo contributors");
WUPS_PLUGIN_AUTHOR("Pretendo contributors and RusticMaple");
WUPS_PLUGIN_LICENSE("GPLv3");
WUPS_USE_STORAGE("inkay");
WUPS_USE_WUT_DEVOPTAB();
bool is_current_game_splatoon(){
auto current_game = OSGetTitleID();
if(
current_game == 0x0005000010162B00 ||
current_game == 0x0005000010176900 ||
current_game == 0x0005000010176A00
){
return true;
}
return false;
}
void splatoon_patcher(){
if(is_current_game_splatoon()){
NotificationModule_AddInfoNotification("Splatoon Detected, applying patch");
auto rpl_count = OSDynLoad_GetNumberOfRPLs();
std::vector<OSDynLoad_NotifyData> rpls(rpl_count);
if(!OSDynLoad_GetRPLInfo(0, rpl_count, rpls.data())){
NotificationModule_AddInfoNotification("failed to get rpls");
}
for(auto rpl: rpls){
if(rpl.name != 0){
if(strstr(rpl.name, "Gambit") != NULL){
NotificationModule_AddInfoNotification(rpl.name);
auto text_color = NMColor();
text_color.r = 255;
text_color.g = 255;
text_color.b = 255;
text_color.a = 255;
auto bg_color = NMColor();
bg_color.r = 0;
bg_color.g = 0;
bg_color.b = 0;
bg_color.a = 0;
NotificationModule_AddInfoNotificationEx(rpl.name, 30.0f, text_color, bg_color, nullptr, nullptr, true);
NotificationModule_AddInfoNotification("applying patches!!!!");
void* game_data_region = (void*)rpl.dataAddr;
auto str_loc = (char*)(0x000009ac + (uint32_t)game_data_region);
strcpy(str_loc, "https://s-res.spfn.net/post");
}
}
}
}
}
INITIALIZE_PLUGIN() {
WHBLogCafeInit();
WHBLogUdpInit();
@ -63,6 +122,7 @@ DEINITIALIZE_PLUGIN() {
ON_APPLICATION_START() {
// Tell the module the plugin is running!
splatoon_patcher();
Inkay_SetPluginRunning();
}

View file

@ -8,35 +8,35 @@ typedef struct URL_Patch {
static const URL_Patch url_patches[] = {
//nim-boss .rodata
{0xE2282550, "http://pushmore.wup.shop.pretendo.cc/pushmore/r/%s"},
{0xE229A0A0, "http://npns-dev.c.app.pretendo.cc/bst.dat"},
{0xE229A0D0, "http://npns-dev.c.app.pretendo.cc/bst2.dat"},
{0xE2281964, "https://tagaya.wup.shop.pretendo.cc/tagaya/versionlist/%s/%s/%s"},
{0xE22819B4, "https://tagaya.wup.shop.pretendo.cc/tagaya/versionlist/%s/%s/latest_version"},
{0xE2282584, "http://pushmo.wup.shop.pretendo.cc/pushmo/d/%s/%u"},
{0xE22825B8, "http://pushmo.wup.shop.pretendo.cc/pushmo/c/%u/%u"},
{0xE2282DB4, "https://ecs.wup.shop.pretendo.cc/ecs/services/ECommerceSOAP"},
{0xE22830A0, "https://ecs.wup.shop.pretendo.cc/ecs/services/ECommerceSOAP"},
{0xE22830E0, "https://nus.wup.shop.pretendo.cc/nus/services/NetUpdateSOAP"},
{0xE2299990, "nppl.app.pretendo.cc"},
{0xE229A600, "https://pls.wup.shop.pretendo.cc/pls/upload"},
{0xE229A6AC, "https://npvk-dev.app.pretendo.cc/reports"},
{0xE229A6D8, "https://npvk.app.pretendo.cc/reports"},
{0xE229B1F4, "https://npts.app.pretendo.cc/p01/tasksheet/%s/%s/%s/%s?c=%s&l=%s"},
{0xE229B238, "https://npts.app.pretendo.cc/p01/tasksheet/%s/%s/%s?c=%s&l=%s"},
{0xE22AB2D8, "https://idbe-wup.cdn.pretendo.cc/icondata/%02X/%016llX.idbe"},
{0xE22AB318, "https://idbe-ctr.cdn.pretendo.cc/icondata/%02X/%016llX.idbe"},
{0xE22AB358, "https://idbe-wup.cdn.pretendo.cc/icondata/%02X/%016llX-%d.idbe"},
{0xE22AB398, "https://idbe-ctr.cdn.pretendo.cc/icondata/%02X/%016llX-%d.idbe"},
{0xE22B3EF8, "https://ecs.c.shop.pretendo.cc"},
{0xE22B3F30, "https://ecs.c.shop.pretendo.cc/ecs/services/ECommerceSOAP"},
{0xE22B3F70, "https://ias.c.shop.pretendo.cc/ias/services/IdentityAuthenticationSOAP"},
{0xE22B3FBC, "https://cas.c.shop.pretendo.cc/cas/services/CatalogingSOAP"},
{0xE22B3FFC, "https://nus.c.shop.pretendo.cc/nus/services/NetUpdateSOAP"},
{0xE229DE0C, "n.app.pretendo.cc"},
{0xE2282550, "http://pushmorewupshop.spfn.net/pushmore/r/%s"},
{0xE229A0A0, "http://npns-devcapp.spfn.net/bst.dat"},
{0xE229A0D0, "http://npns-devcapp.spfn.net/bst2.dat"},
{0xE2281964, "https://tagayawupshop.spfn.net/tagaya/versionlist/%s/%s/%s"},
{0xE22819B4, "https://tagayawupshop.spfn.net/tagaya/versionlist/%s/%s/latest_version"},
{0xE2282584, "http://pushmowupshop.spfn.net/pushmo/d/%s/%u"},
{0xE22825B8, "http://pushmowupshop.spfn.net/pushmo/c/%u/%u"},
{0xE2282DB4, "https://ecswupshop.spfn.net/ecs/services/ECommerceSOAP"},
{0xE22830A0, "https://ecswupshop.spfn.net/ecs/services/ECommerceSOAP"},
{0xE22830E0, "https://nuswupshop.spfn.net/nus/services/NetUpdateSOAP"},
{0xE2299990, "npplapp.spfn.net"},
{0xE229A600, "https://plswupshop.spfn.net/pls/upload"},
{0xE229A6AC, "https://npvk-devapp.spfn.net/reports"},
{0xE229A6D8, "https://npvkapp.spfn.net/reports"},
{0xE229B1F4, "https://nptsapp.spfn.net/p01/tasksheet/%s/%s/%s/%s?c=%s&l=%s"},
{0xE229B238, "https://nptsapp.spfn.net/p01/tasksheet/%s/%s/%s?c=%s&l=%s"},
{0xE22AB2D8, "https://idbe-wupcdn.spfn.net/icondata/%02X/%016llX.idbe"},
{0xE22AB318, "https://idbe-ctrcdn.spfn.net/icondata/%02X/%016llX.idbe"},
{0xE22AB358, "https://idbe-wupcdn.spfn.net/icondata/%02X/%016llX-%d.idbe"},
{0xE22AB398, "https://idbe-ctrcdn.spfn.net/icondata/%02X/%016llX-%d.idbe"},
{0xE22B3EF8, "https://ecscshop.spfn.net"},
{0xE22B3F30, "https://ecscshop.spfn.net/ecs/services/ECommerceSOAP"},
{0xE22B3F70, "https://iascshop.spfn.net/ias/services/IdentityAuthenticationSOAP"},
{0xE22B3FBC, "https://cascshop.spfn.net/cas/services/CatalogingSOAP"},
{0xE22B3FFC, "https://nuscshop.spfn.net/nus/services/NetUpdateSOAP"},
{0xE229DE0C, "n.app.spfn.net"},
//nim-boss .bss
{0xE24B8A24, "https://nppl.app.pretendo.cc/p01/policylist/1/1/UNK"},
{0xE31930D4, "https://%s%saccount.pretendo.cc/v%u/api/"}
{0xE24B8A24, "https://npplapp.spfn.net/p01/policylist/1/1/UNK"},
{0xE31930D4, "https://%s%saccount.spfn.net/v%u/api/"}
};

View file

@ -1,13 +1,13 @@
.plugin_name="Inkay"
,.network_category="Netzwerkauswahl"
,.connect_to_network_setting="Verbinde zum Pretendo Network"
,.connect_to_network_setting="Verbinde zum SPFN"
,.other_category="Andere Einstellungen"
,.reset_wwp_setting="Wara Wara Plaza zurücksetzen"
,.press_a_action="Drücke A"
,.restart_to_apply_action="Neustarten zum Anwenden"
,.need_menu_action="Nur vom Wii U-Menü aus"
,.using_nintendo_network="Nutze Nintendo Network"
,.using_pretendo_network="Nutze Pretendo Network"
,.using_pretendo_network="Nutze SPFN"
,.multiplayer_port_display="Nutze UDP Port %hu für Mehrspieler"
,.module_not_found="Pretendo Patch fehlgeschlagen - nutze Aroma Updater zum Reparieren (686-1001 Module missing)"
,.module_init_not_found="Pretendo Patch fehlgeschlagen - nutze Aroma Updater zum Reparieren (686-1002 Module init)"
,.module_not_found="SPFN Patch fehlgeschlagen - nutze Aroma Updater zum Reparieren (686-1001 Module missing)"
,.module_init_not_found="SPFN Patch fehlgeschlagen - nutze Aroma Updater zum Reparieren (686-1002 Module init)"

View file

@ -1,13 +1,13 @@
.plugin_name="Inkay"
,.network_category="Network selection"
,.connect_to_network_setting="Connect to Pretendo Network"
,.connect_to_network_setting="Connect to SPFN"
,.other_category="Other settings"
,.reset_wwp_setting="Reset Wara Wara Plaza"
,.press_a_action="Press A"
,.restart_to_apply_action="Restart to apply"
,.need_menu_action="From WiiU menu only"
,.using_nintendo_network="Using Nintendo Network"
,.using_pretendo_network="Using Pretendo Network"
,.using_pretendo_network="Using SPFN"
,.multiplayer_port_display="Using UDP port %hu for multiplayer"
,.module_not_found="Pretendo Network patch failed - use Aroma Updater to repair (686-1001 Module missing)"
,.module_init_not_found="Pretendo Network patch failed - use Aroma Updater to repair (686-1002 Module init)"
,.module_not_found="SPFN patch failed - use Aroma Updater to repair (686-1001 Module missing)"
,.module_init_not_found="SPFN patch failed - use Aroma Updater to repair (686-1002 Module init)"

View file

@ -1,13 +1,13 @@
.plugin_name="Inkay"
,.network_category="Seleccionar red"
,.connect_to_network_setting="Conectar a Pretendo Network"
,.connect_to_network_setting="Conectar a SPFN"
,.other_category="Otros ajustes"
,.reset_wwp_setting="Restablecer Plaza Wara Wara"
,.press_a_action="Pulsa A"
,.restart_to_apply_action="Reiniciar para aplicar"
,.need_menu_action="Solo desde el Menú de Wii U"
,.using_nintendo_network="Usando Nintendo Network"
,.using_pretendo_network="Usando Pretendo Network"
,.using_pretendo_network="Usando SPFN"
,.multiplayer_port_display="Usando puerto UDP %hu para multijugador"
,.module_not_found="Ha fallado el parche Pretendo Network - usa Aroma Updater para repararlo (686-1001 Falta un módulo)"
,.module_init_not_found="Ha fallado el parche Pretendo Network - usa Aroma Updater para repararlo (686-1002 Inicialización del módulo)"
,.module_not_found="Ha fallado el parche SPFN - usa Aroma Updater para repararlo (686-1001 Falta un módulo)"
,.module_init_not_found="Ha fallado el parche SPFN - usa Aroma Updater para repararlo (686-1002 Inicialización del módulo)"

View file

@ -1,13 +1,13 @@
.plugin_name="Inkay"
,.network_category="Sélection du réseau"
,.connect_to_network_setting="Connexion au Pretendo Network"
,.connect_to_network_setting="Connexion au SPFN"
,.other_category="Autres paramètres"
,.reset_wwp_setting="Réinitialiser la place WaraWara"
,.press_a_action="Appuyez sur A"
,.restart_to_apply_action="Redémarrer pour appliquer"
,.need_menu_action="(retournez d'abord au menu Wii U)"
,.using_nintendo_network="Réseau sélectionné : Nintendo Network"
,.using_pretendo_network="Réseau sélectionné : Pretendo Network"
,.using_pretendo_network="Réseau sélectionné : SPFN"
,.multiplayer_port_display="Le port UDP %hu sera utilisé pour le multijoueur"
,.module_not_found="Le patch Pretendo Network a rencontré un problème, veuillez le réparer avec Aroma Updater (686-1001 Module missing)"
,.module_init_not_found="Le patch Pretendo Network a rencontré un problème, veuillez le réparer avec Aroma Updater (686-1002 Module init)"
,.module_not_found="Le patch SPFN a rencontré un problème, veuillez le réparer avec Aroma Updater (686-1001 Module missing)"
,.module_init_not_found="Le patch SPFN a rencontré un problème, veuillez le réparer avec Aroma Updater (686-1002 Module init)"

View file

@ -1,13 +1,13 @@
.plugin_name="Inkay"
,.network_category="Seleziona la rete"
,.connect_to_network_setting="Connettiti a Pretendo Network"
,.connect_to_network_setting="Connettiti a SPFN"
,.other_category="Altre impostazioni"
,.reset_wwp_setting="Ripristina Wara Wara Plaza"
,.press_a_action="Premi A"
,.restart_to_apply_action="Riavvia per applicare"
,.need_menu_action="Solo dal menu WiiU"
,.using_nintendo_network="In uso Nintendo Network"
,.using_pretendo_network="In uso Pretendo Network"
,.using_pretendo_network="In uso SPFN"
,.multiplayer_port_display="È in uso la porta UDP %hu per il multigiocatore"
,.module_not_found="Patch di Pretendo fallita - usa Aroma Updater per correggere (686-1001 Modulo mancante)"
,.module_init_not_found="Patch di Pretendo fallita - usa Aroma Updater per correggere (686-1002 Module init)"
,.module_not_found="Patch di SPFN fallita - usa Aroma Updater per correggere (686-1001 Modulo mancante)"
,.module_init_not_found="Patch di SPFN fallita - usa Aroma Updater per correggere (686-1002 Module init)"

View file

@ -1,13 +1,13 @@
.plugin_name="Inkay"
,.network_category="ネットワークの選択"
,.connect_to_network_setting="Pretendoネットワークに接続する"
,.connect_to_network_setting="SPFNネットワークに接続する"
,.other_category="その他の設定"
,.reset_wwp_setting="わらわら広場をリセット"
,.press_a_action="Aボタンを押そう"
,.restart_to_apply_action="再起動後に反映されます"
,.need_menu_action="Wii Uメニューからのみ実行可能"
,.using_nintendo_network="選択済み:ニンテンドーネットワーク"
,.using_pretendo_network="選択済み:Pretendo ネットワーク"
,.using_pretendo_network="選択済み:SPFN ネットワーク"
,.multiplayer_port_display="マルチプレイに UDPポート %hu を使用します"
,.module_not_found="Pretendo パッチに失敗しました。Aroma Updaterを使用して解決してみてください。(686-1001 Module missing)"
,.module_init_not_found="Pretendo パッチに失敗しました。Aroma Updaterを使用して解決してみてください。(686-1002 Module init)"
,.module_not_found="SPFN パッチに失敗しました。Aroma Updaterを使用して解決してみてください。(686-1001 Module missing)"
,.module_init_not_found="SPFN パッチに失敗しました。Aroma Updaterを使用して解決してみてください。(686-1002 Module init)"

View file

@ -1,13 +1,13 @@
.plugin_name="Inkay"
,.network_category="Netwerkselectie"
,.connect_to_network_setting="Verbind met het Pretendo-netwerk"
,.connect_to_network_setting="Verbind met het SPFN-netwerk"
,.other_category="Overige instellingen"
,.reset_wwp_setting="Reset het Wara Wara Plaza"
,.press_a_action="Druk A"
,.restart_to_apply_action="Herstart om toe te passen"
,.need_menu_action="Alleen vanuit het WiiU-menu"
,.using_nintendo_network="Nintendo Network wordt gebruikt"
,.using_pretendo_network="Pretendo Network wordt gebruikt"
,.using_pretendo_network="SPFN wordt gebruikt"
,.multiplayer_port_display="Gebruikt UDP port %hu voor multiplayer"
,.module_not_found="Pretendo patch mislukt - gebruik Aroma Updater om het te herstellen (686-1001 Module ontbreekt)"
,.module_init_not_found="Pretendo patch mislukt - gebruik Aroma Updater om het te herstellen (686-1002 Module init)"
,.module_not_found="SPFN patch mislukt - gebruik Aroma Updater om het te herstellen (686-1001 Module ontbreekt)"
,.module_init_not_found="SPFN patch mislukt - gebruik Aroma Updater om het te herstellen (686-1002 Module init)"

View file

@ -1,13 +1,13 @@
.plugin_name="Inkay"
,.network_category="Selecionar rede"
,.connect_to_network_setting="Conecta-se à Pretendo Network"
,.connect_to_network_setting="Conecta-se à SPFN"
,.other_category="Outras configurações"
,.reset_wwp_setting="Resetar Wara Wara Plaza"
,.press_a_action="Aperte A"
,.restart_to_apply_action="Reinicie para aplicar"
,.need_menu_action="Apenas no menu do Wii U"
,.using_nintendo_network="Usando Nintendo Network"
,.using_pretendo_network="Usando Pretendo Network"
,.using_pretendo_network="Usando SPFN"
,.multiplayer_port_display="Usando UDP port %hu para a jogatina multiplayer"
,.module_not_found="Atualização do Pretendo falhou - use o Aroma Updater para corrigir (686-1001 Módulo faltando)"
,.module_init_not_found="Atualização do Pretendo falhou - use o Aroma Updater para corrigir (686-1002 Módulo de início)"
,.module_not_found="Atualização do SPFN falhou - use o Aroma Updater para corrigir (686-1001 Módulo faltando)"
,.module_init_not_found="Atualização do SPFN falhou - use o Aroma Updater para corrigir (686-1002 Módulo de início)"

View file

@ -1,13 +1,13 @@
.plugin_name="Inkay"
,.network_category="Выбор сети"
,.connect_to_network_setting="Подключиться к Pretendo Network"
,.connect_to_network_setting="Подключиться к SPFN"
,.other_category="Другие настройки"
,.reset_wwp_setting="Сбросить Wara Wara Plaza"
,.press_a_action="Нажмите A"
,.restart_to_apply_action="Перезагрузите для применения изменений"
,.need_menu_action="Только из меню Wii U"
,.using_nintendo_network="Используется Nintendo Network"
,.using_pretendo_network="Используется Pretendo Network"
,.using_pretendo_network="Используется SPFN"
,.multiplayer_port_display="Используем UDP-порт %hu для сетевой игры"
,.module_not_found="Ошибка установки патча Pretendo - для восстановления, запустите Aroma Updater (686-1001 Модуль отсутствует)"
,.module_init_not_found="Ошибка установки патча Pretendo - для восстановления, запустите Aroma Updater (686-1002 Инициализация модуля)"
,.module_not_found="Ошибка установки патча SPFN - для восстановления, запустите Aroma Updater (686-1001 Модуль отсутствует)"
,.module_init_not_found="Ошибка установки патча SPFN - для восстановления, запустите Aroma Updater (686-1002 Инициализация модуля)"

View file

@ -1,13 +1,13 @@
.plugin_name="Inkay"
,.network_category="选择网络"
,.connect_to_network_setting="连接到Pretendo Network"
,.connect_to_network_setting="连接到SPFN"
,.other_category="其他设置"
,.reset_wwp_setting="重置Wara Wara Plaza"
,.press_a_action="请按 A"
,.restart_to_apply_action="重启以应用设置"
,.need_menu_action="仅来自WiiU Menu"
,.using_nintendo_network="使用 Nintendo Network"
,.using_pretendo_network="使用 Pretendo Network"
,.using_pretendo_network="使用 SPFN"
,.multiplayer_port_display="多人游戏使用 UDP 端口 %hu"
,.module_not_found="Pretendo Network 补丁失败 - 使用 Aroma Updater 修复686-1001 模块丢失)"
,.module_init_not_found="Pretendo Network 补丁失败 - 使用 Aroma Updater 修复686-1002 模块初始化)"
,.module_not_found="SPFN 补丁失败 - 使用 Aroma Updater 修复686-1001 模块丢失)"
,.module_init_not_found="SPFN 补丁失败 - 使用 Aroma Updater 修复686-1002 模块初始化)"

View file

@ -1,13 +1,13 @@
.plugin_name="Inkay"
,.network_category="選擇網路"
,.connect_to_network_setting="連接到Pretendo Network"
,.connect_to_network_setting="連接到SPFN"
,.other_category="其他設定"
,.reset_wwp_setting="重置Wara Wara Plaza"
,.press_a_action="請按 A"
,.restart_to_apply_action="重啓以套用設定"
,.need_menu_action="僅來自WiiU Menu"
,.using_nintendo_network="使用 Nintendo Network"
,.using_pretendo_network="使用 Pretendo Network"
,.using_pretendo_network="使用 SPFN"
,.multiplayer_port_display="Using UDP port %hu for multiplayer"
,.module_not_found="Pretendo Network patch failed - use Aroma Updater to repair (686-1001 Module missing)"
,.module_init_not_found="Pretendo Network patch failed - use Aroma Updater to repair (686-1002 Module init)"
,.module_not_found="SPFN patch failed - use Aroma Updater to repair (686-1001 Module missing)"
,.module_init_not_found="SPFN patch failed - use Aroma Updater to repair (686-1002 Module init)"

View file

@ -46,9 +46,9 @@
If not set correctly, the loader will refuse to use the plugin.
**/
WUMS_MODULE_EXPORT_NAME("inkay");
WUMS_MODULE_DESCRIPTION("Pretendo Network Patcher");
WUMS_MODULE_DESCRIPTION("SPFN Network Patcher");
WUMS_MODULE_VERSION(INKAY_VERSION);
WUMS_MODULE_AUTHOR("Pretendo contributors");
WUMS_MODULE_AUTHOR("Pretendo contributors and RusticMaple");
WUMS_MODULE_LICENSE("GPLv3");
WUMS_DEPENDS_ON(homebrew_functionpatcher);