Here are EOS tutorials

All about the past, current and future webteases and the art of webteasing in general.
---
User avatar
Pseudonym
Explorer At Heart
Explorer At Heart
Posts: 372
Joined: Sat Sep 22, 2012 12:03 pm

Re: Here are EOS tutorials

Post by Pseudonym »

Is there a way to log value of a function in EoS?

Example:

Code: Select all

var object = {
  key: function() {return someVariable === true},
};

console.log(object.key); // doesn't work
console.log(object.key.toString()); // doesn't work
console.dir(object.key); // doesn't work
My Discord server: https://discord.gg/tbQxJ22
My latest release: Cock Hero - Replay viewtopic.php?t=24640
All my work so far: https://mega.nz/folder/sdcHmQzT#PZ4ctIZsoGp4N7zuDmIh_Q
User avatar
PlayfulGuy
Experimentor
Experimentor
Posts: 1068
Joined: Sat Jul 07, 2012 10:08 pm
Gender: Male
Sexual Orientation: Bisexual/Bi-Curious
I am a: Switch
Dom/me(s): No domme
Sub/Slave(s): No sub
Location: British Columbia, Canada

Re: Here are EOS tutorials

Post by PlayfulGuy »

Pseudonym wrote: Sat Dec 07, 2024 8:26 pm Is there a way to log value of a function in EoS?

Example:

Code: Select all

var object = {
  key: function() {return someVariable === true},
};

console.log(object.key); // doesn't work
console.log(object.key.toString()); // doesn't work
console.dir(object.key); // doesn't work
I don't understand why you would code something like you show in that example,
but in your example object.key is a function, not the result (value) of that function.
You would need

Code: Select all

console.log( object.key() )
to execute the function and get the result.

PG
User avatar
Pseudonym
Explorer At Heart
Explorer At Heart
Posts: 372
Joined: Sat Sep 22, 2012 12:03 pm

Re: Here are EOS tutorials

Post by Pseudonym »

I see, thank you.
PlayfulGuy wrote: Sat Dec 07, 2024 10:15 pm I don't understand why you would code something like you show in that example...
Probably because I'm not that great at programming. :lol:
I'm in a proces of implementing parsing and evaluating taunts that I write in Excel. The object keys of the taunt that I get from the Excel are then compared with the game state in order to choose taunts that make sense in the context of the game.

There is probably a correct way to do it but this is the best I can do with my skills. :blush: Luckily I was now able to fix a bug I've struggled for a while even without logging the functions...

Parsing the taunts and preparing functions that check conditions:
Spoiler: show
Image
Then comparing it with "query" which is the game state:
Spoiler: show
Image
My Discord server: https://discord.gg/tbQxJ22
My latest release: Cock Hero - Replay viewtopic.php?t=24640
All my work so far: https://mega.nz/folder/sdcHmQzT#PZ4ctIZsoGp4N7zuDmIh_Q
User avatar
ccgssdtttew
Explorer At Heart
Explorer At Heart
Posts: 239
Joined: Wed Sep 11, 2024 11:05 am
Gender: Male
Sexual Orientation: Straight
I am a: Submissive
Dom/me(s): None
Sub/Slave(s): None

Re: Here are EOS tutorials

Post by ccgssdtttew »

Anyone here has a link for the metronome mp3 sound that sounds like a heart beat? I dont really like the sounds from metronomer.

Also is the scripts in the same as java? I was trying to google java scripts and copy paste them in, but couldnt get them to work.
For example, i wanted to display what Day it was (i.e. Monday, Tuesday, etc.). But I cant seem to get it to work, only having the "new Date().getDay" gets me a numerical value. I tried to copy this from internet:
Spoiler: show
from datetime import datetime

# Get the current day of the week (e.g., "Monday", "Tuesday", etc.)
current_day = datetime.now().strftime("%A")

# Initialize a dictionary with all days set to False
days_of_week = {
"Monday": False,
"Tuesday": False,
"Wednesday": False,
"Thursday": False,
"Friday": False,
"Saturday": False,
"Sunday": False,
}

# Set the current day to True
days_of_week[current_day] = True

print(days_of_week)
How far can JOIs wreck oneself? Yes pls, pm me and Ill be a good boy (to be broken)
༺ 𓆩 Secret Profile Page 𓆪 ༻
Currently playing these:
Help Me Cum Please! - My rules - Active, but slow
Challenge Arena
User avatar
PlayfulGuy
Experimentor
Experimentor
Posts: 1068
Joined: Sat Jul 07, 2012 10:08 pm
Gender: Male
Sexual Orientation: Bisexual/Bi-Curious
I am a: Switch
Dom/me(s): No domme
Sub/Slave(s): No sub
Location: British Columbia, Canada

Re: Here are EOS tutorials

Post by PlayfulGuy »

ccgssdtttew wrote: Sun Dec 08, 2024 5:28 am Anyone here has a link for the metronome mp3 sound that sounds like a heart beat? I dont really like the sounds from metronomer.

Also is the scripts in the same as java? I was trying to google java scripts and copy paste them in, but couldnt get them to work.
For example, i wanted to display what Day it was (i.e. Monday, Tuesday, etc.). But I cant seem to get it to work, only having the "new Date().getDay" gets me a numerical value. I tried to copy this from internet:
Spoiler: show
from datetime import datetime

# Get the current day of the week (e.g., "Monday", "Tuesday", etc.)
current_day = datetime.now().strftime("%A")

# Initialize a dictionary with all days set to False
days_of_week = {
"Monday": False,
"Tuesday": False,
"Wednesday": False,
"Thursday": False,
"Friday": False,
"Saturday": False,
"Sunday": False,
}

# Set the current day to True
days_of_week[current_day] = True

print(days_of_week)
The sample code you posted appears to be python, not javascript.
The following function will return the current weekday as a string:

Code: Select all

      //-------------------------------------------------------------------
      function weekday() {
        // Returns the current weekday name
        var weekdays = ["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]
        var name = "invalid day";
        var n = new Date().getDay();
        if ( n >= 0 && n < 7 ) name = weekdays[n];
        return name;
      }
As for the mp3 sound, you could download a tease that uses that metronome sound and grab the mp3 file(s).
Those will each play at a certain bpm, for a certain length of time. You may not get all the combinations you want that way, but it's a start.

If you want more help with the mp3 stuff it's probably best to start a new thread specific to that request, and if you can link to a tease that uses the sound you want even better. That's kind of off topic for this thread and might not get noticed by the people with better answers.

PG
User avatar
ccgssdtttew
Explorer At Heart
Explorer At Heart
Posts: 239
Joined: Wed Sep 11, 2024 11:05 am
Gender: Male
Sexual Orientation: Straight
I am a: Submissive
Dom/me(s): None
Sub/Slave(s): None

Re: Here are EOS tutorials

Post by ccgssdtttew »

PlayfulGuy wrote: Mon Dec 09, 2024 3:26 pm PG
Thank you! Ill try that out later. And oops, I mixed that up then. Got it and thanks for noticing xd
How far can JOIs wreck oneself? Yes pls, pm me and Ill be a good boy (to be broken)
༺ 𓆩 Secret Profile Page 𓆪 ༻
Currently playing these:
Help Me Cum Please! - My rules - Active, but slow
Challenge Arena
Kaleb
Curious Newbie
Curious Newbie
Posts: 1
Joined: Thu Apr 11, 2024 9:36 pm
Gender: Male
Sexual Orientation: Straight
I am a: Dom (Male)

Re: Here are EOS tutorials

Post by Kaleb »

I need help asap

How do I do "what's your name" then ones I add my name in the "promt", my name should be in the "say" like asking the user their name, how do i do that?
sorry for my bad english
User avatar
PlayfulGuy
Experimentor
Experimentor
Posts: 1068
Joined: Sat Jul 07, 2012 10:08 pm
Gender: Male
Sexual Orientation: Bisexual/Bi-Curious
I am a: Switch
Dom/me(s): No domme
Sub/Slave(s): No sub
Location: British Columbia, Canada

Re: Here are EOS tutorials

Post by PlayfulGuy »

Kaleb wrote: Thu Jan 09, 2025 2:59 pm I need help asap

How do I do "what's your name" then ones I add my name in the "promt", my name should be in the "say" like asking the user their name, how do i do that?
sorry for my bad english
You use a say action to say what you want the user to enter (name etc.), then a prompt action to get the information. In the prompt action you specify a name for the variable. You can then refer to that variable in say actions using an "eval" in the say text.

Sample tease here: https://milovana.com/webteases/showteas ... fe8db66ea6

Screen shot of editing the say action that uses the name below.

Hope that helps,

PG
2025-01-11 18_12_55-Eos Editor — Mozilla Firefox Private Browsing.jpg
2025-01-11 18_12_55-Eos Editor — Mozilla Firefox Private Browsing.jpg (142 KiB) Viewed 7802 times
User avatar
Pseudonym
Explorer At Heart
Explorer At Heart
Posts: 372
Joined: Sat Sep 22, 2012 12:03 pm

Re: Here are EOS tutorials

Post by Pseudonym »

CorruptedSigil wrote: Sat Feb 15, 2025 12:34 am Hey everyone,

I’m looking for some help understanding the storage module. How exactly does it work? Could someone give me a brief explanation along with a simple example of how to use it? Also, what kind of data can it store, and are there any capacity or limit restrictions I should be aware of?

Thanks in advance!
Here is API reference:
https://milovana.com/eos/editor/help/ap ... aseStorage
You use the getItem to load stuff from storage.
And setItem is for saving to storage.

And here is explanation of the teaseStorage limit:
viewtopic.php?t=22556
My Discord server: https://discord.gg/tbQxJ22
My latest release: Cock Hero - Replay viewtopic.php?t=24640
All my work so far: https://mega.nz/folder/sdcHmQzT#PZ4ctIZsoGp4N7zuDmIh_Q
User avatar
Pseudonym
Explorer At Heart
Explorer At Heart
Posts: 372
Joined: Sat Sep 22, 2012 12:03 pm

Re: Here are EOS tutorials

Post by Pseudonym »

I'm very close to releasing alpha version of my new tease. I was able to code the teaseStorage saving and loading in a way that should be backward-compatible with updates so that players don't lose their progress when new version is released.

The issue is that I don't exactly know how publishing a tease in EoS works.

- Does publishing creates a separate "copy" of the tease that is unaffected by changes made after publishing? Can then be the published tease updated by publishing it again? In other words, is publishing a tease update-friendly in a way that doesn't destroy player's progress after update?

- Or does publishing work the same way as sharing the tease via link? Meaning no copy + any changes made to the tease are visible to players the next time they load the tease.

I would love to test publishing, but I'm reluctant to create, test, delete... teases and mess with this site and annoy people. :blush:
My Discord server: https://discord.gg/tbQxJ22
My latest release: Cock Hero - Replay viewtopic.php?t=24640
All my work so far: https://mega.nz/folder/sdcHmQzT#PZ4ctIZsoGp4N7zuDmIh_Q
User avatar
PlayfulGuy
Experimentor
Experimentor
Posts: 1068
Joined: Sat Jul 07, 2012 10:08 pm
Gender: Male
Sexual Orientation: Bisexual/Bi-Curious
I am a: Switch
Dom/me(s): No domme
Sub/Slave(s): No sub
Location: British Columbia, Canada

Re: Here are EOS tutorials

Post by PlayfulGuy »

Pseudonym wrote: Fri Feb 21, 2025 7:30 pm I'm very close to releasing alpha version of my new tease. I was able to code the teaseStorage saving and loading in a way that should be backward-compatible with updates so that players don't lose their progress when new version is released.

The issue is that I don't exactly know how publishing a tease in EoS works.

- Does publishing creates a separate "copy" of the tease that is unaffected by changes made after publishing? Can then be the published tease updated by publishing it again? In other words, is publishing a tease update-friendly in a way that doesn't destroy player's progress after update?

- Or does publishing work the same way as sharing the tease via link? Meaning no copy + any changes made to the tease are visible to players the next time they load the tease.

I would love to test publishing, but I'm reluctant to create, test, delete... teases and mess with this site and annoy people. :blush:
I've not tested it myself, but I have seen several authors update teases after publication to correct errors etc, so that's certainly possible, and I'm pretty certain that publishing is update friendly. Unless another author who has tested this chimes in, the only way to know for sure is to test it.

If you create a short test tease and publish it, just make it clear in the description that it's a test that will be deleted so people know to ignore it. Then you can do your testing, delete the tease, and share your results here so we all know :-D .

PG
User avatar
ccgssdtttew
Explorer At Heart
Explorer At Heart
Posts: 239
Joined: Wed Sep 11, 2024 11:05 am
Gender: Male
Sexual Orientation: Straight
I am a: Submissive
Dom/me(s): None
Sub/Slave(s): None

Re: Here are EOS tutorials

Post by ccgssdtttew »

Can someone share a simple code for me to expand/adapt? Im trying to work with storage function, if you've played Dreamer by MetalLife, I want to make it so that an ending with "girlA" will leave a record in a gallery (i.e. 1 out of 10 girls).
- Whats the code in initial script? So if I have 100 girls... do i need 100 separate storage lines to keep track?

Code: Select all

// Initial Script
var girlA_completed = false // For first time playthrough, not completed yet
var girlA_completed = teaseStorage.getItem("girlA_completed") // Checking if player has actually completed her
- Whats the end code, for example of page 1 after finishing with her,

Code: Select all

// Page 1 finish with girl A and storing it
var girlA_completed = true
teaseStorage.setItem("girlA_completed", girlA_completed)

I guess you could say the tease im working on is similar to a "maze x collect em all" kind with rng, pokemon i guess LOL. I still have not confirmed all the mechanics / direction of the tease other than a replayability function of different girls teasing you. Im also trying to set up a loose story (i.e. trivia/funfacts as you explore). Main focus is stroking and edging, but feel free to share your ideas of what you think may go well with this "genre". I've seen some feedbacks on other teases, and a nice thing to include would be "no. of edges" for current playthrough and total record.

My first attempt idea can be seen here.
How far can JOIs wreck oneself? Yes pls, pm me and Ill be a good boy (to be broken)
༺ 𓆩 Secret Profile Page 𓆪 ༻
Currently playing these:
Help Me Cum Please! - My rules - Active, but slow
Challenge Arena
User avatar
PlayfulGuy
Experimentor
Experimentor
Posts: 1068
Joined: Sat Jul 07, 2012 10:08 pm
Gender: Male
Sexual Orientation: Bisexual/Bi-Curious
I am a: Switch
Dom/me(s): No domme
Sub/Slave(s): No sub
Location: British Columbia, Canada

Re: Here are EOS tutorials

Post by PlayfulGuy »

ccgssdtttew wrote: Sun Mar 09, 2025 5:48 pm Can someone share a simple code for me to expand/adapt? Im trying to work with storage function, if you've played Dreamer by MetalLife, I want to make it so that an ending with "girlA" will leave a record in a gallery (i.e. 1 out of 10 girls).
- Whats the code in initial script? So if I have 100 girls... do i need 100 separate storage lines to keep track?

Code: Select all

// Initial Script
var girlA_completed = false // For first time playthrough, not completed yet
var girlA_completed = teaseStorage.getItem("girlA_completed") // Checking if player has actually completed her
- Whats the end code, for example of page 1 after finishing with her,

Code: Select all

// Page 1 finish with girl A and storing it
var girlA_completed = true
teaseStorage.setItem("girlA_completed", girlA_completed)
I'm no expert on the teaseStorage feature, but I know it's fairly limited in how much you can store, and other authors have developed methods for increasing that (fapnip maybe?).

There are different methods you can look into depending how you want to identify the girls in your code.

Example 1
Using an array to record if a girl has been visited, you would assign each girl a number from 1 to n....

Code: Select all

// Initial script
girlsVisited = teaseStorage.getItem("girlsVisited") || []; // Load last saved state, or start with empty list if no previous save
As you visit each girl

Code: Select all

// Assuming Page 1 is girl 1. When finished
girlsVisited[1] = true; 	// You need to manually set and track the girl number for each girl.
teaseStorage.setItem("girlsVisited", girlsVisited)
And to test whether or not a girl has been visited

Code: Select all

// Has girl 5 been visited?
if ( girlsVisited[5] === true ) {
	// Girl has been visited
}
else {
	// Girl has NOT been visited
}

Example 2
Using an object and letters (or even names) to record if a girl has been visited.
**Using a full name uses up the available teaseStorage more quickly**
You assign each girl a letter (or name), then

Code: Select all

// Initial script
girlsVisited = teaseStorage.getItem("girlsVisited") || {}; // Load last saved state, or start with empty list if no previous save
// Note the curly brackets instead of square brackets!!
As you visit each girl

Code: Select all

// Assuming Page 1 is girl A,  when finished you do
girlsVisited["A"] = true; 	// You need to manually set and track the girl letter/name for each girl.
teaseStorage.setItem("girlsVisited", girlsVisited)

// Using a full name would just look like
girlsVisited["Amanda"] = true; 
And to test whether or not a girl has been visited

Code: Select all

// Has girl A been visited?
if ( girlsVisited.hasOwnProperty("A") and girlsVisited["A"] === true ) {
	// Girl has been visited
}
else {
	// Girl has NOT been visited
}

// Using a full name (uses up the available teaseStorage more quickly)
if ( girlsVisited.hasOwnProperty("Amanada") and girlsVisited["Amanada"] === true ) {
	// Girl has been visited
}
else {
	// Girl has NOT been visited
}

And for bonus points, to make the name/letter version easier to code, include a function in your initial code

Code: Select all

// Initial script
function girlWasVisited(name) {
	// Has girl name been visited?
	if ( girlsVisited.hasOwnProperty(name) and girlsVisited[name] === true ) return true
	return false
}

// And in your pages or wherever
if ( girlWasVisited("Amanada") ) {
	// Girl has been visited
}
else {
	// Girl has NOT been visited
}

There are plenty of other ways, but in the interest of keeping it simple and understandable, this should work well enough.

Hope that helps!

PG
User avatar
ccgssdtttew
Explorer At Heart
Explorer At Heart
Posts: 239
Joined: Wed Sep 11, 2024 11:05 am
Gender: Male
Sexual Orientation: Straight
I am a: Submissive
Dom/me(s): None
Sub/Slave(s): None

Re: Here are EOS tutorials

Post by ccgssdtttew »

PlayfulGuy wrote: Wed Mar 12, 2025 8:54 pm There are plenty of other ways, but in the interest of keeping it simple and understandable, this should work well enough.

Hope that helps!

PG
Wew. ima try it out. thank you!
How far can JOIs wreck oneself? Yes pls, pm me and Ill be a good boy (to be broken)
༺ 𓆩 Secret Profile Page 𓆪 ༻
Currently playing these:
Help Me Cum Please! - My rules - Active, but slow
Challenge Arena
PrincessBrooke
Explorer
Explorer
Posts: 17
Joined: Fri Jan 10, 2025 5:46 am
I am a: Submissive

Re: Here are EOS tutorials

Post by PrincessBrooke »

Any reason I can only upload phots on Microsoft Edge?
Post Reply