-
Posts
22 -
Joined
-
Last visited
-
Feedback
0%
Content Type
Forums
Store
Third Party - Providers Directory
Feature Plan
Release Notes
Docs
Events
Posts posted by MadTiago
-
-
You need to create a IPN script on your website to process the payment notifications. There should be many samples of those around. When it's ready, set up IPN in your Paypal account.
You don't need to setup IPN on paypal, the return url can be configured on the form.
You just need the form and the listener (IPN).
-
You could improve your coding even more.
- Try using PDO/MySQLi instead of php's native mysql lib
- Use some sort of config options instead of harcoding databases/tables names
- If you declare every function as "public" even if they don't need to be public, it will make no sense to specify it's visibility
- Try using | as a separator instead of :::
- When you write player's cache, you can use a foreach to iterate through player data, no need to write all those lines
-
To attack you need to change your binary.
On InstanceBase.cpp, add your mount vnum to the switch on:
UINT CInstanceBase::SHORSE::GetLevel()
And to allow damage with that mount, you need to edit your game's pvp.cpp, adding your mount vnum to the switch on:bool CPVPManager::CanAttack(LPCHARACTER pkChr, LPCHARACTER pkVictim)
- 5
-
Loading
-
You're running game file on share directory, when you're not supposed to.
The share directory is used to "share" (hence the name) the files with game channels/cores using symbolic links. Think of it as a "common" directory.
This method allows you to replace the game/db file on a single directory (in this case it's share) affecting every directory that has a symbolic link poiting to game/db files.
When you run the game file, it tries to load the CONFIG file, but that doesn't exist on share dir since each channel/core has a unique CONFIG file (that's why you don't "share" it).
- 1
-
World
-
-
Legacy
-
Royal
-
With this modifications to the original make.sh you can comment your locale_list.
Prerequisites
- bash
How to use?
bash make.sh
Source code
#!/usr/local/bin/bash LIST_FILE='locale_list' BIN="./qc" if [ -r $LIST_FILE ]; then rm -rdf object mkdir object while read line; do firstChar="${line:0:1}" if [ "$firstChar" != "#" ] && [ -n "$firstChar" ]; then quest=${line%#*} $BIN $quest fi done < $LIST_FILE else echo $LIST_FILE' is missing' fi
Example locale_list
# First quest quest1.quest quest2.quest # Second quest quest3.quest quest4.quest
Hope you like it.
- 7
- 1
- 4
- 11
-
search
-
You should read this as well: http://www.freebsd.org/doc/handbook/users.htmlif you dont want just delete in .sh files root check..
like this :
if [ `id -u` = "0" ]; then echo "This script must not be run as root" 1>&2 exit 1 fi
delete lines and save. -
Use crontab -l to check if the cron has been added.
And you can also check /var/log/cron.
Is "/Backups/auto_back.sh" the full path?
- 1
-
Rename "vanilla_core_x_x" to "game" and "vanilla_dbcache" to "db".
- 1
-
I know the scripts, I was just explaining why you shouldn't use rootThose files use tim's scripts which don't let themselves be run as root. It's the same we have in WoM.
Btw, songoku, you should read this: http://www.freebsd.org/doc/handbook/users.html
-
Go to share/bin and replace the game and db files with vanilla's or any other revision you want.
-
You don't need to create it, but it is recommended since root should only be used for server management and not to run services.
-
That's the vi editor.
Click "a" to append text then write the cron line.
To save and quit press Esc, then type :wq and hit Return.
The cronjob will be automatically installed upon exiting.
- 1
-
Hi, good afternoon.
This is a very nice script but I have a little problem with the cron part and I would like to know if you also happens and if you could solve.
I put in the crontab this to test it
* * * * * root sh /Cron/auto_back.sh all
It do the auto_back.sh every min, but not dump the tables and not upload the files, it generates a empty empyfiles.gz, to test if the cron works I put in the script header
echo "test" >> /log_auto
And It works, every mins. insert test in the /log_auto.
If I do manually it works.
Does anyone know how can be solved?
Kind regards.
You should leave /etc/crontab alone.
Use crontab -e instead (no need to specify the user).
-
Does this work with 40k, too?
I've heard they have some new bonuses in 40k
Gesendet von meinem Nexus 5 mit Tapatalk
Yes, it does.
-
Hey.
I'm releasing my mysql backup script.
Prerequisites
- mysqldump
- gzip
- ncftp
- ftp server properly set up
- Dumps and compresses the desired mysql databases
- Transfers compressed files to remote host
- Removes local compressed files
This script takes only one argument (mode).
Mode defines which databases should be dumped.
Run it as:
sh backupmysql.sh <mode>
Check the source comments for available modes.Running automatically
You can also define it to run automatically with a cronjob, and even run different modes on different times.
To add a new cronjob, run:
crontab -e
Example cronjob (once a day):
0 0 * * * sh /usr/home/someuser/backupmysql.sh all
Script source:
#!/bin/sh # Get mode from user input # Allowed modes: # all: backups account, common, log, player, webserver # game: backups account, common, player # gameLog: backups log # web: backups webserver # exceptLog: backups account, common, player, webserver MODE=$1 if [ "$MODE" == "" ]; then MODE="exceptLog" fi # Bins MYSQLDUMP=`which mysqldump` GZIP=`which gzip` NCFTP=`which ncftp` # Date for folders and filenames DAY=$(date +"%Y-%m-%d") FILETIME=$(date +"%Y-%m-%d.%T") # Local backup folder (no trailing slash) LOCAL_FOLDER="/tmp/backup" # FTP Configuration REMOTE_HOST="x.x.x.x" REMOTE_USER="ftp_user" REMOTE_PASS="ftp_pass" REMOTE_FOLDER="/" # With trailing slash # MySQL Configuration MYSQL_USER="mysql_user" MYSQL_PASS="mysql_pass" # Which databases shall we backup? # Databases should be separated with a space DATABASES="" if [ "$MODE" == "all" ]; then DATABASES="account common log player webserver" elif [ "$MODE" == "game" ]; then DATABASES="account common player" elif [ "$MODE" == "gameLog" ]; then DATABASES="log" elif [ "$MODE" == "web" ]; then DATABASES="webserver" elif [ "$MODE" == "exceptLog" ]; then DATABASES="account common player webserver" fi # Check if DATABASES var is set... if [ "$DATABASES" == "" ]; then echo -e "033[31mThe specified mode doesn't exist...033[0m" exit 1 fi # Dump and compress for db in $DATABASES do FILE=$db.$FILETIME.gz echo -e "033[32mDumping $db!033[0m" $MYSQLDUMP -u $MYSQL_USER -p$MYSQL_PASS $db | $GZIP -9 > $LOCAL_FOLDER/$FILE done # Transfer all backup files to remote host echo -e "033[32mnTransfering files!033[0m" $NCFTP -u$REMOTE_USER -p$REMOTE_PASS $REMOTE_HOST<<EOF mkdir $REMOTE_FOLDER$DAY cd $REMOTE_FOLDER$DAY lcd $LOCAL_FOLDER mput * quit EOF # Delete local dump files rm -f $LOCAL_FOLDER/*
- 14
SSH: Network error: Connection refused
in Community Support - Questions & Answers
Posted · Edited by Metin2 Dev
Core X - External 2 Internal
You're probably using a different port on sshd_config.
To use a ssh tunnel to connect to mysql, you just need to create a local mysql user on your server and then configure navicat to use local user + ssh tunnel like this:
https://metin2.download/picture/r3F9504x09DVmF8K988YXgTtGTP6KMUj/.gif
https://metin2.download/picture/r3F9504x09DVmF8K988YXgTtGTP6KMUj/.gif
If you changed ssh port, you need to reload/restart ssh daemon: