• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • New resources must be posted under Resources tab. A discussion thread will be created automatically, you can't open threads manually anymore.

Fixed Guild War System for Website [include all]-[will not count frags] (TFS 0.3+)

Status
Not open for further replies.
Also if you got redskull and goes into war (gets yellow skull) after battle pz is lost u loose redskull also.
 
I have a problem, when ever I try to enter the subtopic=wars I get:

Invalid subtopic. Can't load page.

I double checked and everything seems fine, Please help

Rep++

Fixed, ty for the release =)
 
Last edited:
positions

any suggestions where I should put these positions?

Code:
Maps = {
	["map 1"] = 
		{
			Guild1Pos = {x=998, y=1006, z=7},
			Guild2Pos = {x=1002, y=1006, z=7}
		},
	["map 2"] =
		{
			Guild1Pos = {x=994, y=1004, z=6},
			Guild2Pos = {x=1000, y=1003, z=6}			
		}
	}
in a town like thais or what? :p
 
:eek: something happened..it gives me error when i do a character how i fix this
 
tfs 0,3,5

Code:
[05/09/2009 20:30:26] Lua Script Error: [GlobalEvent Interface] 
[05/09/2009 20:30:26] data/globalevents/scripts/wars.lua:onThink

[05/09/2009 20:30:26] data/lib/database.lua:60: [Result:getDataInt] Result not set!
[05/09/2009 20:30:26] stack traceback:
[05/09/2009 20:30:26] 	[C]: in function 'error'
[05/09/2009 20:30:26] 	data/lib/database.lua:60: in function 'getDataInt'
[05/09/2009 20:30:26] 	./GuildWar.lua:212: in function 'getGuildsWithWar'
[05/09/2009 20:30:26] 	data/globalevents/scripts/wars.lua:4: in function <data/globalevents/scripts/wars.lua:3>
[05/09/2009 20:30:26] [Error - GlobalEvents::think] Couldn't execute event: wars
 
@Dalale
change on GuildWar.lua
if res:getID() ~= LUA_ERROR then
to
if res:getID() ~= -1 then
 
Last edited:
Doesn't this count frags ?, how do i fix so it does ?
 
@Kiman:
Yes, it count frags (on website I mean).

@freaked1:
Those positions will be the positions that the 2 teams will be teleported after say /war-challenge.

@Elaney:
I'll check it then.

@Arlaxis:
It works on 0.3.5, at least for me...

@espi:
You are using the wrong PHP file. Use the another one, there are two PHP files at main post.

@alper99:
hey i got this error pls Help ^^

Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[42S22]: Column not found: 1054 Unknown column 'g.war_time' in 'field list'' in C:\xampp\htdocs\wars.php:58 Stack trace: #0 C:\xampp\htdocs\wars.php(58): PDO->query('?? SELECT g....') #1 C:\xampp\htdocs\index.php(239): include('C:\xampp\htdocs...') #2 {main} thrown in C:\xampp\htdocs\wars.php on line 58
You didn't do the step 5.0.

@Al Massiva:
The step 5.0 must be done by http://localhost/phpmyadmin
After enter, you must put your user/password; after that select your database and then click on SQL at the top-center of the web, then write there into the text-box this:
ALTER TABLE `guilds`
ADD `invited_to` INT( 11 ) NOT NULL ,
ADD `invited_by` INT( 11 ) NOT NULL ,
ADD `in_war_with` INT( 11 ) NOT NULL ,
ADD `kills` INT( 11 ) NOT NULL ,
ADD `show` SMALLINT( 1 ) NOT NULL ,
ADD `war_time` INT( 11 ) NOT NULL ;

CREATE TABLE `deaths_in_wars` (
`guild_id` INT( 11 ) NOT NULL ,
`player_id` INT( 11 ) NOT NULL ,
`killer_guild` INT( 11 ) NOT NULL ,
`killer` INT( 11 ) NOT NULL ,
`date` INT( 11 ) NOT NULL
) ENGINE = MYISAM ;
 
funny ... someone got yellow skull and someone without guild kill him and dont get frags, its sux.
 
For me it wont count frags, you got any clue why ?

Let me check my PHP file.

funny ... someone got yellow skull and someone without guild kill him and dont get frags, its sux.

It's obviously that if the target is yellow skull, you won't get any frag.
 
Do i have to /war-challenge for it to count the frags? Can't the players just run and kill every single one of the opposite guild for it to count?

Doesnt seem to work.
 
@up
if u wanna count frags just remove
data\creaturescripts\scripts\war_attack.lua
and
registerCreatureEvent(cid, "WarAttack")
...
 
Status
Not open for further replies.
Back
Top