New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Video Pre-roll #51
Comments
Hello, on line 14653 is the code for the adUrl embedding. You might be able to put it in there. To make it to where the user can only click it after the video ends, you can probably edit the setTimeout feature or edit the setTimeout to show the |
Hi @ethanaobrien , thanks for your reply. I will make a few tests and let you know ;-) |
Hi @ethanaobrien , I tried to implement the Ad URL straight into the emulator.js like below: Line 14653:
and Line 14656:
But it didn't work :-( It only works if I add this line:
Like the code below:
Is it possible to add the Ad URL straight into the emulator.js file? Thank you! |
To specify it in the emulator.js file, search for the code |
Thanks for your quick reply @ethanaobrien ! It's not working for me as you can see in the test page below :-( Test page - https://coolstuffblast.com/games/test.html Emulator.js file was modified as per your instructions above. |
Hi @ethanaobrien , that's really strange ... I have cleared my Google Chrome cache, Cloudflare cache, I even tried anonymous browser and it was not working lol ... I had to flush my DNS via CMD to see it was working :-) Thank you for your help! The banner ads was an easy implementation via emulator.js , just trying to figure it out how to implement the video pre-roll now. Is there any easy way to call an ad url from emulator.js to load before the emulator loads using the whole game frame 640x480 pixels? Thanks in advance for all your help and support! |
No, this isn't possible in javascript to check if the ad is loaded. Sorry |
Hi @ethanaobrien , thanks for your reply. It doesn´t need to check if the ad is loaded, just need to call and load the ad url in the whole game iframe as soon as it loads the emulator. The video pre-roll script will have the close button and the time set up to work it by itself. The result would be similar to this one - https://neptunjs.xyz/snes.html But it would load the video pre-roll ad before ;-) |
Sorry for the late reply, got busy then I just kept forgetting to respond.
This is what it does, the moment the emulator loads the iframe is created and starts loading |
Hi @ethanaobrien , thanks for your reply. In the new emulator, I couldn't find the code: How to implement the Ad URL inside the new emulator.js file? Thanks in advance for all your help and support! |
Bottom of the |
@xxxnewbiexxx Did you ever get this working? Can I close this or? |
Hi @ethanaobrien, just the banner is working at the moment, still working on the video pre-roll implementation ... |
Im going to assume you've got this under control I'm closing since this isn't technically an issue, but a question |
Hi @ethanaobrien , have you done any change to the code that skip modifications on emu-main.js ? I tried to implement the ad URL inside emu-main. js file changing this line: this.adUrl = null; to this: this.adUrl = 'https://mysite.com/adurl.html'; but it's not working :-( Thanks in advance for all your help and support! |
It’s defined twice in the file (as shown). It sets the value as null at first than sets it to the value in the config argument. You could define it in the loader.js file
|
Thanks for your reply @ethanaobrien ! How can I define it in the loader.js file? I tried this: 'undefined' != typeof EJS_AdUrl && (config.adUrl = 'https://mysite.com/adurl.html'); but it didn't work ... |
Set the config ad url to your site instead of the window variable
|
How to set this @ethanaobrien ? Could you please help ? |
Hi all, any idea how to implement the video pre-roll ad tag code below inside emulator.js file?
Ad Tag Code:
Thanks in advance for your usual support!
The text was updated successfully, but these errors were encountered: