Daily Lucky Numbers:

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Chen Zhen

SMF Arcade Support + Plugins / HTML5 Save Code V3
January 09, 2022, 10:58:00 PM
function saveHTML52score(score, gamename) {
let pathArray = window.location.pathname.split('/');
let newpath = '';
if (pathArray[1] && pathArray[1] != 'arcade' && pathArray[1] != 'games') {
newpath = '/' + pathArray[1];
scorepost(window.location.protocol + '//' + window.location.hostname + newpath + '/index.php?act=Arcade&do=newscore', {
gname : gamename,
gscore: score
function scorepost(href, inputs) {
var gform = document.createElement('form');
gform.method = 'post';
gform.action = href;
gform.target = '_parent';
for (var k in inputs) {
var input = document.createElement('input');
input.setAttribute('name', k);
input.setAttribute('value', inputs[k]);

An example of usage:
var score = parseInt(localStorage.getItem("energizerScore")), gamename = 'energizerCZ';
saveHTML52score(score, gamename);
SMF Arcade Support + Plugins / Re: Game error reporting
January 09, 2022, 02:33:12 PM
Reporting a game issue already allows the user to state the reason. This information is available on the list by clicking or tapping the appropriate column will display a small popup window containing what was reported.
I can implement a PM option to all admin and arcade moderators.
EhPortal Support / EhPortal v1.33 Released!
January 01, 2022, 04:28:53 PM
Eh Portal v1.33

You must uninstall any previous version of Eh Portal prior to commencing this installation.

EhPortal 1.33
! Fixed: escape/backslash filter for PHP/HTML block/page code output
! Changed: escape/backslash filter applied to actual block edit

EhPortal 1.32
+ Added: option to disable PHP eval() function in favor of temporary PHP file creation.
+ Added: option to enable an escape/backslash filter for PHP/HTML block/page code output.
+ Added: option to purge PHP block temp folder
! Fixed: admin block settings multi-check
! Changed: moved some block options to block settings

EhPortal 1.31
! Fixed: sp_blocks compatibility for migration from SimplePotal 2.0.18
! Fixed: theme thumbnails for sp_theme_select block
! Fixed: dynamically load datepicker & datepair scripts if not already available

Eh Portal is fully HTML5 compliant.
It uses mobile detection and a bootstrap to adjust any of SMF's or a modification's HTML5 to be mobile friendly.

If you come across a popular mod, theme or SMF itself that still causes any mobile display issues please report it in this board.
SMF Arcade Support + Plugins / Re: Game Posting
December 30, 2021, 05:12:59 PM
Game posting is just for announcing newly installed games.
In the arcade admin you set a user id and a board to post the new games.
For example you can create a new user named "Arcade Bot", give it an arcade themed avatar and use that as the user id.
The endpoint is supposed to be the web address for the Azure translator service.
The API path is supposed to be the expected path on that website.

When you applied for the subscription, it should have given you those specific values.
Try to use the defaults for those 2 top settings by checking the [Auto-Fill Default API Endpoint & Path Settings] option and then save it. Remember these have to be V3 code(s). They give you 2 of them when you subscribe.
You have to use the region code name that contains no spaces.
I don't see uksouth on the first list but you can try it else try uk or ukwest.


I'll look at the second report.
The translation script was adjusted for the upcoming version & may fix your problem.
Check your PM
SMF Arcade Support + Plugins / Re: Ruffle update
December 17, 2021, 06:50:23 PM

It was working fine when I tested it last week.
I'll take a look at it to fix any problems.

Thanks for the report.
SMF Arcade Support + Plugins / Re: Mobile compatibility
December 13, 2021, 10:24:52 PM
@Skhilled; re. arcade mobile skin/list

You can always change style to class and then include a custom css file.
Sometimes JavaScript is used to change the style directly though.
You can edit it so the class is changed instead for that scenario and provide the alternate classes.
ie. for orientation changes, etc.
This is fixed in the upcoming release (if I understand your report correctly). We're working on some other things so I'm not able to give an approx. release date.

That upload script uses JavaScript and if there are any errors on the page in JavaScript from something else then it will fail.
It is up to every forum admin/owner to ensure their website is running error free.
A simple way to check for JavaScript errors is to use: right click -> inspect -> console ... if you do this then you will see the errors and can fix them.
The errors should be fixed starting from the top & then recheck the page/container. Usually one or more errors (shown at the top of the console list) will have a cascade effect causing errors that follow.

Aside from that tidbit of info, you can disable your blocks in the admin section.
Other than testing stuff, there's no point showing blocks in admin.

I disabled them in admin for you: Admin -> Simple Portal -> Configuration -> Block Settings -> Hide Blocks in Forum Areas -> Admin (checked & saved)
... that should fix your upload problem but you should still fix your JavaScript errors.
SMF Arcade Block Codes / Re: Drop-Down Category Block
November 21, 2021, 02:17:08 PM

It changes the champ block & the list.
The arcade keeps track of multiple list criteria (game type & category).
If you want to reset the list then use the ARCADE button in the toolbar located on the left side of the arcade template.


I found this game on your Arcade and looked at the scores.
It is Yeti Sports Albatross Overload.

The scores are not duplicates, they are different scores with different score times.

If you want to set it up so that a user can only have one score per game or a specific number of scores per game then you need to go to Arcade settings and set the number of allowed scores per game from the setting: "Maximum Scores (per player per game)".
A setting of 0 makes it unlimited and this is the default setting until you change it.

I can see 2 entries with the same name but do they both show the exact time & score?
Some games are incorrectly coded for saving the score but the Arcade is designed to detect & thwart such an occurrence.

Can you upload the game here in this thread for testing?
SMF Arcade Block Codes / Re: Drop-Down Category Block
November 21, 2021, 12:57:14 AM

This block code has been updated.