-- TM LEVEL ??
CREATE procedure uspt_char_status_update_tm_level
@char_uid int
, @tm_level_p smallint
, @tm_level_m smallint
, @tm_level_s smallint
, @tm_level_c smallint
as
set nocount on
set lock_timeout 10000
declare @error_pl int
, @error_ml int
, @error_sl int
, @error_cl int
declare @error_pe int
, @error_me int
, @error_se int
, @error_ce int
, @error int
set @error_pl = 0
set @error_ml = 0
set @error_sl = 0
set @error_cl = 0
set @error_pe = 0
set @error_me = 0
set @error_se = 0
set @error_ce = 0
set @error = 0
begin tran -------------------------->
if (@tm_level_p > -1)
begin
update char_status
set tm_level_p = @tm_level_p
where uid = @char_uid
set @error_pl = @@error
update char_state
set tm_exp_p = 0
where uid = @char_uid
set @error_pe = @@error
end
----------------------------------
if (@tm_level_m > -1)
begin
update char_status
set tm_level_m = @tm_level_m
where uid = @char_uid
set @error_ml = @@error
update char_state
set tm_exp_m = 0
where uid = @char_uid
set @error_me = @@error
end
----------------------------------
if (@tm_level_s > -1)
begin
update char_status
set tm_level_s = @tm_level_s
where uid = @char_uid
set @error_sl = @@error
update char_state
set tm_exp_s = 0
where uid = @char_uid
set @error_se = @@error
end
----------------------------------
if (@tm_level_c > -1)
begin
update char_status
set tm_level_c = @tm_level_c
where uid = @char_uid
set @error_cl = @@error
update char_state
set tm_exp_c = 0
where uid = @char_uid
set @error_ce = @@error
end
----------------------------------
set @error = @error_pl + @error_pe
+ @error_ml + @error_me
+ @error_sl + @error_se
+ @error_cl + @error_ce
if (@error = 0)
begin
commit tran
return 0
end
else
begin
if (@@trancount > 0)
rollback tran
return @error
end
GO
- ??? LEVEL ??
CREATE PROCEDURE uspt_char_status_update_char_level
@char_uid int
, @new_level smallint
as
set nocount on
set lock_timeout 10000
declare @error int
set @error = 0
BEGIN TRAN ----------------------------->
update char_status
set ap_pts = (@new_level-1) * C.pts_p,
ac_pts = (@new_level-1) * C.pts_p,
dx_pts = (@new_level-1) * C.pts_p,
max_mp_pts = (@new_level-1) * C.pts_m,
ma_pts = (@new_level-1) * C.pts_m,
md_pts = (@new_level-1) * C.pts_m,
max_wt_pts = (@new_level-1) * C.pts_s,
da_pts = (@new_level-1) * C.pts_s,
lk_pts = (@new_level-1) * C.pts_s,
max_hp_pts = (@new_level-1) * C.pts_c,
dp_pts = (@new_level-1) * C.pts_c,
hv_pts = (@new_level-1) * C.pts_c,
attr_pts = (@new_level-1) * 4,
[level] = @new_level
from char_status as CS
inner join char_attr as C on C.uid = CS.uid
where CS.uid = @char_uid
if (@@error = 0 and @@rowcount = 1)
begin
update char_state
set [exp] = 0
where uid = @char_uid
if (@@error <> 0 or @@rowcount = 0)
set @error = 1003
end
else
set @error = 1004
if (@error = 0)
set @error = dbo.fn_GetCharStatusCheck (@char_uid)
if (@error = 0)
begin
commit tran
return 0
end
else
begin
if (@@trancount > 0)
rollback tran
return @error
end
GO
These is commands darkco mentioned earlier as his thoughts for the "EXP/TM" rate...
I don't know much about Stored Procedures.... I never even looked at them really till I started fooling with this server... I have the backup's fully decrypted save one SP ... Which I don't know WHY it won't decrypt but I think it has to do with 'permission' to that command.
Now i'm curious about the GM Commands I saw a post earlier asking about them... I'll try to update this post however with what I find....
And would someone mind posting ONE thing to this thread so that I know it's being read? I mean I see the views go up... but no one says anything! I don't care what language you use.... Google does most translations half-assed so I can get the 'gist' of what you're saying!
Thanks for reading though!!
Also I need to do further studies and see if I can make this to go across the net... Right now I just have it set up 'locally'... I'd also appreciate an experienced admins... so as to perhaps guide me in setting up a mini-web page... I'm unsure about the whole net sharing though... I'm really sure that ADSL (3 mbps down / 256kb Up) is REALLY insufficient for a host... But my line of works get's me access to Free PC's/Laptops so I could have the spare HW to host :c ...
Kind regards
Tinkle