Skip to content

Instantly share code, notes, and snippets.

View vankk's full-sized avatar
💫
it is just about elevation

vankk

💫
it is just about elevation
  • Brazil
View GitHub Profile
@vankk
vankk / bau.lua
Created March 22, 2020 13:56
Script do Tata com Storage para o Vinicius.
function onModalWindow(cid, modalWindowId, buttonId, choiceId)
cid:unregisterEvent("potions_lever")
local id_Potions = {23589, 32069, 34699, 21403, 34587, 34628, 34641} -- id das potions
local price = {80000000, 100000000, 60000000, 30000000, 40000000, 50000000, 20000000} -- price 1x
local cap = {2.70, 2.70, 2.90, 2.90, 3.10, 3.10, 3.10, 3.10, 3.10, 3.10, 3.50} -- capacity
if cid:getStorageValue(33333) == 1 then
cid:sendTextMessage(MESSAGE_STATUS_CONSOLE_ORANGE, "Você já pegou a sua recompensa.")
@vankk
vankk / script_doido.lua
Created March 9, 2020 21:42
Script doido do Lucas
local config = {
monster = "Boss Reward",
levelIncrease = 50, -- A quantidade de level que vai dar
storage = 11577,
delayTime = 4, -- Tempo em segundos para poder usar de novo a action
maxLevel = 100000,
}
local function getExpForLevel(level)
level = level - 1
@vankk
vankk / bug_paladin_atk.diff
Created February 28, 2020 13:11
Fixar bug de paladin atacar e se potar.
commit 5cb1a9d9afc1a4a27a1123ff5f9ad8ec1ebe95f9
Author: vankk <nwtr.otland@hotmail.com>
Date: Sun Jan 26 06:23:02 2020 -0300
Tryfix bug paladin atacar & se potar
diff --git a/sources/src/player.cpp b/sources/src/player.cpp
index a6adabd5..528c0c4a 100644
--- a/sources/src/player.cpp
+++ b/sources/src/player.cpp
Author: vankk
Date: Tue Sep 10 13:34:04 2019 -0300
NPC Idle Fix
diff --git a/sources/src/npc.cpp b/sources/src/npc.cpp
index 60e225d..83fee35 100644
--- a/sources/src/npc.cpp
+++ b/sources/src/npc.cpp
@@ -58,7 +58,8 @@ Npc::Npc(const std::string& name) :
@vankk
vankk / penis.diff
Last active March 2, 2019 18:49
Stamina Regeneration PZ 0.4 C++
diff --git a/a/configmanager.cpp b/b/configmanager.cpp
index 3578a89..3a6d7dd 100644
--- a/a/configmanager.cpp
+++ b/b/configmanager.cpp
@@ -317,6 +317,9 @@ bool ConfigManager::load()
m_confNumber[EXHAUST_ONBUY] = getGlobalNumber("onBuy", 500);
m_confNumber[EXHAUST_ONSELL] = getGlobalNumber("onSell", 500);
m_confNumber[EXHAUST_CHANGEOUFIT] = getGlobalNumber("changeOutfit", 500);
+ m_confBool[STAMINA_REGEN_PZ] = getGlobalBool("staminaRegenPz", true);
+ m_confNumber[STAMINA_SECONDS_TO_REGEN] = getGlobalNumber("staminaSecondsToRegen", 30);
@vankk
vankk / diff.diff
Last active November 30, 2019 11:30
Add playerOnChangeZone TFS 1.3
diff --git a/data/events/events.xml b/data/events/events.xml
index febdc6e5..b930a368 100644
--- a/data/events/events.xml
+++ b/data/events/events.xml
@@ -19,6 +19,7 @@
<event class="Player" method="onLookInShop" enabled="0" />
<event class="Player" method="onMoveItem" enabled="1" />
<event class="Player" method="onItemMoved" enabled="0" />
+ <event class="Player" method="onChangeZone" enabled="0" />
<event class="Player" method="onMoveCreature" enabled="0" />
1 - 100000
2 - 50000
3 - 33333
4 - 25000
5 - 20000
6 - 16666
7 - 14285
8 - 12500
9 - 11111
10 - 10000
@vankk
vankk / gist:26d86b501371306daff2b309ae7d4df0
Created July 7, 2018 15:46
Lua functions for The Forgotten Server for VSC
{
"ACCOUNT_TYPE_GAMEMASTER": {
"prefix": "ACCOUNT_TYPE_GAMEMASTER",
"body": [
"ACCOUNT_TYPE_GAMEMASTER"
]
},
"ACCOUNT_TYPE_GOD": {
"prefix": "ACCOUNT_TYPE_GOD",
"body": [