Page 81 of 121
Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Mon Oct 08, 2018 1:14 pm
by Ambossli
tigrotto wrote: Mon Oct 08, 2018 11:21 am
Any idea about why I can't play the script? I checked the XML you attached and they're identical.
Thanks!
I tried to mark the changes I made so it would load
- Spoiler: show
- <Title>Lottery of Abstinence</Title> <-- you forgot the /
<Url>https://milovana.com/webteases/showteas ... 37610</Url>
<Author id="101186">
<Name>SpiritualMigrant</Name>
<Url></Url> <--delete the url that is in here
tigrotto wrote: Mon Oct 08, 2018 11:21 am
I have another question: is it possible to create a button that randomly chooses between three(or more) non-consecutive pages like
page2,
page15 and
page32 or pages with different names like
Red,
Green door and
Blue portal?(fake names just to give you an example)
Yes that should be possible with javascript. The first solution that comes to my mind would be an array with the possible pages from which one would be randomly chosen than given back the page as an variable to the target of the button.
I pu an example .js file in the zip
The page in the main xml would look more like this
- Spoiler: show
Code: Select all
<Page id="ambossli1">
<Text>
</Text>
<Image id="_error.jpg" />
<javascript>
<![CDATA[
function pageLoad() {
fambossli1Initiate();
fambossli1ChooseHost();
var vambossli1Host = scriptVars.get("vambossli1Host");
overRide.addButton(vambossli1Host, "Start","", "", "", "");
}
]]>
</javascript>
</Page>
you could look at pilgtrimquest it uses quite a bit of javascript
Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Mon Oct 08, 2018 1:29 pm
by tigrotto
It works now! Thanks!
Ambossli wrote: Mon Oct 08, 2018 1:14 pm
Yes that should be possible with javascript. The first solution that comes to my mind would be an array with the possible pages from which one would be randomly chosen than given back the page as an variable to the target of the button.
Thanks. It was more curiosity rather than something I really need at the moment, but who knows...
Ambossli wrote: Mon Oct 08, 2018 1:14 pm
you could look at pilgtrimquest it uses quite a bit of javascript
I will, although I'm pretty sure I won't understand much...

Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Mon Oct 08, 2018 1:47 pm
by tigrotto
Ambossli wrote: Mon Oct 08, 2018 1:14 pm
I pu an example .js file in the zip
tigrotto wrote: Mon Oct 08, 2018 1:29 pm
Ambossli wrote: Mon Oct 08, 2018 1:14 pm
you could look at pilgtrimquest it uses quite a bit of javascript
I will, although I'm pretty sure I won't understand much...
Confirmed. I haven't understood much.
Scripting for GuideMe is really complicated...
I will probably need to work with variables and it's hard to know where to start...
Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Fri Oct 12, 2018 5:20 pm
by bobhill
Not sure if it's ok to ask here, but PG has been gone and I really could use some help. Also apologies for the cross post.
I've been reading the prior posts regarding 0.3.3, 0.3.4, 0.3.6 and 0.3.7, trying to determine which version is ok to use with Script Engine 1.5 (or 1.53). With Script Engine 1.5 and GM 0.3.6 or 0.3.7, when I exit a script back to GM, the page ShowScriptPage text block displays (Something went wrong), but then GM proceeds to the correct GM page (so the text display is extraneous, but does not crash the program). This does not occur in 0.3.3 or 0.3.4. But I think that there are saving problems with 0.3.3 and 0.3.4 that were fixed in 0.3.6? Also, I read a memory/image loading issue exists in 0.3.4? My head hurts just typing all this!
I could go back to earlier GM versions, but I hate to give up the javascript debugging in GM. I also need certain features added in Script Engine 1.5, so can't revert with it.
Thanks for any help! BH

Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Sat Oct 13, 2018 2:34 am
by lawman5297
philo wrote: Thu Oct 04, 2018 6:18 pm
lawman5297 wrote: Wed Oct 03, 2018 7:23 pm
philo, Could you use the onclick property of a XML button to call a global JS that would load the current page (into a variable?) and then reload that page when the button is clicked? This way I could just insert the button on each page without the need to edit each one. What would the code for this be if it is possible?
The easiest way is to go to a dummy page and the use the page load on that page to go back to the previous one.
(the count stuff is just so you can see it is working)
So a page with overRide.setPage(guide.getPrevPage()); in the page load will bounce you back to the page you came from
Code: Select all
<Page id="start">
<Text>
<div>
<div>Page 1</div>
<span>count</span>
</div>
</Text>
<Button target="Reload">Reload</Button>
<Button target="Page2">Continue</Button>
<javascript><![CDATA[
function pageLoad() {
var count = 0 + scriptVars.get("count");
scriptVars.put("count", count);
}
]]></javascript>
</Page>
<Page id="Page2">
<Text>
<div>
<div>Page 2</div>
<span>count</span>
</div>
</Text>
<Button target="Reload">Reload</Button>
<Button target="Page3">Continue</Button>
</Page>
<Page id="Page3">
<Text>
<div>
<div>Page 3</div>
<span>count</span>
</div>
</Text>
<Button target="Reload">Reload</Button>
<Button target="start">Continue</Button>
</Page>
<Page id="Reload">
<Text>
</Text>
<javascript><![CDATA[
function pageLoad() {
var count = scriptVars.get("count") + 1;
scriptVars.put("count", count);
overRide.setPage(guide.getPrevPage());
}
]]></javascript>
</Page>
I am back on this or perhaps this is different. I want wait until the page changes then return to the previous. How can I do that? The reload feature works great but after using it what I really need to be able to do is return to previous. THX
Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Sat Oct 13, 2018 10:11 am
by lolol2
You could use a var and get on every page the "guide.getPrevPage", so when you click on the reload button and redirect to an other page the var has still the page you want to return?
Page 1
This page you want to return
Page 2
var lastpage = guide.getPrevPage
Button reload
Page relaoad
Using the var lastpage for next page -> jump to Page 1.
Just an idea, not sure if this will work.

You are just changing the point where you set the var for the previous page and do this on every page again even if the button will not hit on the next page.
Download fix for non flash teases
Posted: Sat Oct 13, 2018 11:16 am
by philo
Have put a fix in so html teases down load again.
Just over write your current download.jar with this one
https://mega.nz/#!JdIlASwR!uqUnuWoduJqO ... P3JMC1RAjs
Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Sat Oct 13, 2018 11:33 am
by lawman5297
lolol2 wrote: Sat Oct 13, 2018 10:11 am
You could use a var and get on every page the "guide.getPrevPage", so when you click on the reload button and redirect to an other page the var has still the page you want to return?
Page 1
This page you want to return
Page 2
var lastpage = guide.getPrevPage
Button reload
Page relaoad
Using the var lastpage for next page -> jump to Page 1.
Just an idea, not sure if this will work.

You are just changing the point where you set the var for the previous page and do this on every page again even if the button will not hit on the next page.
Would rather not add to every page if possible. As in the reload philo helped me with I would like to just be able to add a button, much easier. Philo, lolo2, ideas? THX
Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Sat Oct 13, 2018 11:50 am
by philo
lawman5297 wrote: Sat Oct 13, 2018 2:34 am
I am back on this or perhaps this is different. I want wait until the page changes then return to the previous. How can I do that? The reload feature works great but after using it what I really need to be able to do is return to previous. THX
Try something like this.
It saves the previous page when you click reload
Then goes back one page.
This is a problem if you come from the reload page and then click the reload button again
(It then just starts looping back to reload over and over)
If you click reload twice in a row it will keep you on the same page.
If you want to go back multiple pages, it is possible but gets more complex, you have to maintain a list of pages and then look up the page you came to reload from, to work put where it needs to go back to.
Code: Select all
<?xml version="1.0"?>
<Tease scriptVersion="v0.1" id="">
<Title />
<Url />
<Author id="">
<Name />
<Url />
</Author>
<MediaDirectory>x</MediaDirectory>
<Settings>
<AutoSetPageWhenSeen>false</AutoSetPageWhenSeen>
</Settings>
<GlobalJavascript>
<![CDATA[
function reload() {
if (guide.getPrevPage() != "Reload")
{
scriptVars.put("reloadPage", guide.getPrevPage());
}
}
]]>
</GlobalJavascript>
<Pages>
<Page id="start">
<Text>
<div>
<div>Page 1</div>
<span>count</span>
</div>
</Text>
<Button target="Reload" onclick="reload()">Reload</Button>
<Button target="Page2">Continue</Button>
<javascript><![CDATA[
function pageLoad() {
var count = 0 + scriptVars.get("count");
scriptVars.put("count", count);
}
]]></javascript>
</Page>
<Page id="Page2">
<Text>
<div>
<div>Page 2</div>
<span>count</span>
</div>
</Text>
<Button target="Reload" onclick="reload()">Reload</Button>
<Button target="Page3">Continue</Button>
</Page>
<Page id="Page3">
<Text>
<div>
<div>Page 3</div>
<span>count</span>
</div>
</Text>
<Button target="Reload" onclick="reload()">Reload</Button>
<Button target="start">Continue</Button>
</Page>
<Page id="Reload">
<Text>
</Text>
<javascript><![CDATA[
function pageLoad() {
var count = scriptVars.get("count") + 1;
scriptVars.put("count", count);
overRide.setPage(scriptVars.get("reloadPage"));
}
]]></javascript>
</Page>
</Pages>
</Tease>
Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Sat Oct 13, 2018 12:01 pm
by lawman5297
THX Philo, I will give this a shot.
Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Sat Oct 13, 2018 12:40 pm
by lawman5297
Philo, I have the variable audio mod variables under the start page like this
Code: Select all
<Page id="start"
<Delay seconds="0" style="hidden" target="startp1"/>
<javascript>
<![CDATA[
function pageLoad() {
scriptVars.put("easyLevel", "70");
var easyLevel = scriptVars.get("easyLevel");
scriptVars.put("hardLevel", "75");
var hardLevel = scriptVars.get("hardLevel");
scriptVars.put("extremeLevel", "80");
var extremeLevel = scriptVars.get("extremeLevel");
scriptVars.put("insaneLevel", "90");
var insaneLevel = scriptVars.get("insaneLevel");
scriptVars.put("redLevel", "100");
var redLevel = scriptVars.get("redLevel");
]]>
</javascript>
</Page>
And I added this under Settings
Code: Select all
<Settings>
<AutoSetPageWhenSeen>true</AutoSetPageWhenSeen>
</Settings>
<GlobalJavascript>
<![CDATA[
function reload() {
if (guide.getPrevPage() != "Reload")
{
scriptVars.put("reloadPage", guide.getPrevPage());
}
}
]]>
</GlobalJavascript>
<Pages>
This is the reload page
Code: Select all
<Page id="Reload">
<javascript><![CDATA[
function pageLoad() {
var count = scriptVars.get("count") + 1;
scriptVars.put("count", count);
overRide.setPage(scriptVars.get("reloadPage"));
}
]]></javascript>
</Page>
And the button
Code: Select all
<Button target="Reload" onclick="reload()">Reload</Button>
And I would guess since it broke the variable audio and does not reload the previous page I have made some errors. Assist? THX!
Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Mon Oct 15, 2018 7:35 pm
by philo
lawman5297 wrote: Sat Oct 13, 2018 12:40 pm
And I would guess since it broke the variable audio and does not reload the previous page I have made some errors. Assist? THX!
If you want to send me a copy of the tease xml I can have a look what is going on.
It is easier to do if I debug it.
Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Wed Oct 17, 2018 4:26 pm
by lawman5297
philo wrote: Mon Oct 15, 2018 7:35 pm
lawman5297 wrote: Sat Oct 13, 2018 12:40 pm
And I would guess since it broke the variable audio and does not reload the previous page I have made some errors. Assist? THX!
If you want to send me a copy of the tease xml I can have a look what is going on.
It is easier to do if I debug it.
Philo, Sent this info to you in a PM. Thx!
Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Wed Oct 17, 2018 11:37 pm
by lawman5297
Philo, PERFECT!!!! THX SO MUCH!!!
Re: GuideMe (TeaseMe v2.0) - Current Build 0.3.4
Posted: Thu Oct 18, 2018 12:25 am
by Trusfrated
Do the current builds of GuideMe support a way to have more than one image displayed on a page? Or a way to move the location of the buttons? I thought I remember some discussion that this was possible via javascript.
The reason i ask is this: there is an advanced technique in Nyx that allows creating a menu of sorts (with buttons and optional pictures) in the left pane.
- Spoiler: show

Examples:
Tip #1:
viewtopic.php?f=2&t=4355
Tease example (first two pages):
https://milovana.com/webteases/showflash.php?id=2909
Alternate code:
viewtopic.php?f=2&t=5926&p=98223&hilit=nyx+trick#p98223
Would it be possible (or practical) at all for the Milo Downloader to convert pages like this? Lovecraft recently created a tease that has several pages using this technique. Example:
- Spoiler: show
Code: Select all
<!--#page(text:'',media:vert(e0:text(text:'<p><FONT SIZE="30"><u>What will you do ?</u></FONT></p><TEXTFORMAT LEADING="2"><P ALIGN="CENTER"><FONT SIZE="28" COLOR="#E89E9E" LETTERSPACING="-6" KERNING="- 55">IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII</FONT></P></TEXTFORMAT>go home and call the police<p></p>try to enter to the Sirens by calling Gigi or Teagan<p></p>try to find the right code'),e1:horiz(e0:text(text:<FONT COLOR="#f000000">- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -</FONT>),e1:vert(e0:pic(id:"phone.jpg"),e1:buttons(target0:page8140#,cap0:"<FONT COLOR="#B30033" SIZE="17"><b>go home</b></FONT>")),e2:vert(e0:pic(id:"tg23*.jpg"),e1:buttons(target0:page1157#,cap0:"<FONT COLOR="#B30033" SIZE="14"><b>phone call</b></FONT>")),e3:vert(e0:pic(id:"passdoor.jpg"),e1:buttons(target0:page2010#,cap0:"<FONT COLOR="#B30033" SIZE="14"><b>passcode</b></FONT>")),e4:text(text:<FONT COLOR="#000000">- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -</FONT>))))-->
The Downloader doesn't convert them properly, so GuideMe just displays a blank page with no buttons.