-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
118 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,118 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
|
||
<head> | ||
<meta charset="UTF-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<title>BindService Documentation</title> | ||
<style> | ||
body { | ||
font-family: Arial, sans-serif; | ||
margin: 0; | ||
padding: 0; | ||
} | ||
|
||
.header { | ||
background-color: #333; | ||
color: #fff; | ||
padding: 10px; | ||
text-align: center; | ||
} | ||
|
||
.tab { | ||
overflow: hidden; | ||
border: 1px solid #ccc; | ||
background-color: #f1f1f1; | ||
} | ||
|
||
.tab button { | ||
background-color: inherit; | ||
float: left; | ||
border: none; | ||
outline: none; | ||
cursor: pointer; | ||
padding: 14px 16px; | ||
transition: 0.3s; | ||
} | ||
|
||
.tab button:hover { | ||
background-color: #ddd; | ||
} | ||
|
||
.tab button.active { | ||
background-color: #ccc; | ||
} | ||
|
||
.tabcontent { | ||
display: none; | ||
padding: 20px; | ||
border-top: none; | ||
} | ||
</style> | ||
</head> | ||
|
||
<body> | ||
|
||
<div class="header"> | ||
<h1>BindService Documentation</h1> | ||
</div> | ||
|
||
<div class="tab"> | ||
<button class="tablinks" onclick="openTab(event, 'Welcome')">Welcome</button> | ||
<button class="tablinks" onclick="openTab(event, 'Installation')">Installation</button> | ||
<button class="tablinks" onclick="openTab(event, 'Usage')">Usage Example</button> | ||
<!-- Add more tabs here --> | ||
</div> | ||
|
||
<div id="Welcome" class="tabcontent"> | ||
<h3>Welcome to BindService Documentation</h3> | ||
<p>This documentation provides information on how to use the BindService module in your Roblox games.</p> | ||
</div> | ||
|
||
<div id="Installation" class="tabcontent"> | ||
<h3>Installation</h3> | ||
<p>To use BindService in your Roblox game, follow these steps:</p> | ||
<ol> | ||
<li>Insert the BindService module script into your game's hierarchy.</li> | ||
<li>Require the BindService module in your scripts using `require(script.Parent.BindService)`.</li> | ||
</ol> | ||
</div> | ||
|
||
<div id="Usage" class="tabcontent"> | ||
<h3>Usage Example</h3> | ||
<pre><code> | ||
local BindService = require(game:GetService("ServerScriptService").BindService) | ||
|
||
-- Define a callback function | ||
local function MoveForward() | ||
-- Move the player forward | ||
end | ||
|
||
-- Bind the "W" key to the MoveForward function | ||
BindService.BindKeyPresses("MoveForward", MoveForward, 0.5, Enum.KeyCode.W) | ||
</code></pre> | ||
</div> | ||
|
||
<!-- Add more tab content here --> | ||
|
||
<script> | ||
function openTab(evt, tabName) { | ||
var i, tabcontent, tablinks; | ||
tabcontent = document.getElementsByClassName("tabcontent"); | ||
for (i = 0; i < tabcontent.length; i++) { | ||
tabcontent[i].style.display = "none"; | ||
} | ||
tablinks = document.getElementsByClassName("tablinks"); | ||
for (i = 0; i < tablinks.length; i++) { | ||
tablinks[i].className = tablinks[i].className.replace(" active", ""); | ||
} | ||
document.getElementById(tabName).style.display = "block"; | ||
evt.currentTarget.className += " active"; | ||
} | ||
|
||
document.getElementsByClassName("tablinks")[0].click(); // Open the first tab by default | ||
</script> | ||
|
||
</body> | ||
|
||
</html> |