Now, you're able to launch a web browser directly in the Rgss Player.
Features
Esc key quits the browser
The Maximize Window button is activated. You can resize your rgss player
Screenshots
Is it really usefull ?
Demo
None
Script
The dll: copy it into the root of your project: there
CODE
#=============================================================================== # RM Web Browser 4/8/09 #------------------------------------------------------------------------------- # par Berka v 1.0 rgss 1 & 2 #------------------------------------------------------------------------------- # Display a web browser in the rgss player. # - NEED the cwebpage.dll. It HAS TO be placed on the root of the project. # - Esc to close the browser, F5, Back keys # - Clic on the maximize button to resize the window # call: Net.browser("http://rpgmakervx.1fr1.net") #===============================================================================
def dimensions GCR.call(handle,rect=[0,0,0,0].pack('l4')) rect.unpack('l4')[2..3] end module Net def self.browser(url) EBO.call(handle) DHP.call(handle,url) RB.call(handle,*dimensions) loop do break if GAKS.call(0x1b)&0x01==1 DPA.call(handle,0)if GAKS.call(0x08)&0x01==1 DPA.call(handle,4)if GAKS.call(0x74)&0x01==1 RB.call(handle,*dimensions) end UEBO.call(handle) end end Net.browser("http://rpgmakervx.1fr1.net")
Instructions
See comments in the script, please.
Compatibility
Does not work for RMXP: hangup bugs.
Credits and Thanks
Notepad++, for his hexadecimal browser. The Dll's creator.
Terms and Conditions
Free for use... but DO NOT post my script everywhere whithout permission. Thanks !
best regards,
berka
This post has been edited by berka: Aug 4 2009, 09:02 AM
A little buggy (for example, if I call the script from an event the map I called it from reappears for a few seconds while I'm browsing sometimes) but otherwise it works surprisingly well! Could be useful!
__________________________
Stay tuned for more information about Fairytale. To stay updated on all my project videos, visit my YouTube page!
Well, the last line of the script is a sample call. You have to remove it before using that. And you can replace the url by your own.
berka
this is what my script looks like:
CODE
#================================================================= ============== # RM Web Browser 4/8/09 #------------------------------------------------------------------------------- # par Berka v 1.0 rgss 1 & 2 #------------------------------------------------------------------------------- # Display a web browser in the rgss player. # - NEED the cwebpage.dll. It HAS TO be placed on the root of the project. # - Esc to close the browser, F5, Back keys # - Clic on the maximize button to resize the window # call: Net.browser("http://rpgmakervx.1fr1.net") #===============================================================================
def dimensions GCR.call(handle,rect=[0,0,0,0].pack('l4')) rect.unpack('l4')[2..3] end module Net def self.browser(url) EBO.call(handle) DHP.call(handle,url) RB.call(handle,*dimensions) loop do break if GAKS.call(0x1b)&0x01==1 DPA.call(handle,0)if GAKS.call(0x08)&0x01==1 DPA.call(handle,4)if GAKS.call(0x74)&0x01==1 RB.call(handle,*dimensions) end UEBO.call(handle) end end
Hey berka, you should tweak the update method more, while you click on something or write, it either shows a black screen, if launching directly, or if from a map, it shows the map you launched it from for a few seconds.
Group: Member
Posts: 3
Type: None
RM Skill: Undisclosed
Oh yes, this is very useful! I looked for a way to show mein Handbook ingame and and with this here I can call it as a PDF by Script! I love it!
Edit: Oh man, there is a major bug: If I resize the Window by clicking the button, the window isn´t really 544*416 px! In addition I can pull the window bigger when I pull at the corners.... Pls fix this....
This post has been edited by Herendil: Aug 5 2009, 03:38 AM
Oh, and the dll's creator is called Jeff Glatt. I will add though, that there are some security issues with this (using IE as a base is not the brightest idea ever; almost no security), and there are some possible memory leaks, etc.
So guys, be carefull what url you throw at your users!
$LOAD_PATH << Dir.getwd #You only need to call this once Kernel.require("includable.rb") #replace includable.rb with the name of the file you want to load
#=============================================================================# # # # ANTI DASH HACK # # # # # # By AmIMeYet # # # # # # please credit me # # # #=============================================================================# class Game_Player < Game_Character def dash? return false if @move_route_forcing return false if in_vehicle? return true if Input.press?(Input::A) and $game_map.disable_dash? end end
This snippet basically inverts the dashing.. allowing you to dash only when 'disable dashing' is checked. This way, normal maps disable dashing, but the ones you set to disable actually allow dashing..
It should be placed where you normally place the scripts ('above main', in the materials section of the scripts window)..
As far as I can tell, no, there's no way to make it into an HUD. It put the WHOLE browser into the game, it doesn't turn it into a little hud. Even if you can turn it into a HUD, you'll have to make it center exactly onto the chat window and lock it there, otherwise the player can just move about the window and exit the chat altogether, and I'm pretty sure you don't want that.
A saying that I DID NOT STEAL FROM KUNG FU PANDA! Today is a Gift. That's why they call it the Present. You never know what's inside, Because the Present is always changing. ~Made it up with my cuz 7 Years Ago, without the help of anybody else~
wrong number of arguments (0 of 1) popup... idk why it does that but could someone help????
EDIT: now i get the Syntax error thing... anyone know a fix for that/
Nobody yet got this error, so you must have been trying to do something yourself. And as we cannot see what you did (script code) we cannot help. Also for the Syntax error, that's usually the easiest error to fix, if you look at the script. But we cannot see the code so = no help.