• 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!
  • 2026 staff recruitment is open! Check it out and consider applying!

Guild war script needs fixing.

Lucenzo

The Way You Move :)
Joined
Jan 29, 2011
Messages
363
Reaction score
14
Location
UK
Hey :) Me again! :L


Aeron - Wars


The problem is that when someone disbands a guild it still shows on that page, also when a war ends it still shows. But i would like the wars to be removed when guild goes disband or war ended, so it doesn't spam the page.

Not sure if this is only .php or lua also, it would be really amazing if someone could help.
Can pm all scripts by private x
 
Well i have restarted the server previously many times and they are still there? :L
But i use different php script and other sql querries for it , as you can see on the website it's a bit different than Elfs.

PHP:
db.executeQuery("DELETE FROM `guild_wars` WHERE `status` = 0 AND `begin` < " .. (os.time() - 2 * 86400) .. ";")
db.executeQuery("UPDATE `guild_wars` SET `status` = 5, `end` = " .. os.time() .. " WHERE `status` = 1 AND `end` > 0 AND `end` < " .. os.time() .. ";")


http://www14.speedy*****malware.localhost/files/27973172/download/phpadmin.png
 
Last edited:

Similar threads

Replies
8
Views
3K
Back
Top