Author Topic: Climb Script bysqudy error  (Read 1049 times)

0 Members and 1 Guest are viewing this topic.

Offline MrHamsTR

  • Soldier
  • **
  • Posts: 209
  • One day, everything will end..
Climb Script bysqudy error
« on: July 17, 2014, 11:17:08 pm »
Pastebin code climb: http://pastebin.com/22k5YfHT
pastebin code antibravo: http://pastebin.com/EHrCF6sT

  • Preparing scripts to be launched
  • Compiling climb -> script.pas...
  • climb compiled
  • Compiling default -> Core.pas...
  • Compiling default -> NetworkCore.pas...
  • Compiling default -> AdminCore.pas...
  • default compiled
  • Done

x
  • [Error] climb -> AppOnIdle(68:1) Exception: File not found



Where is my wrong?


EDİT: I solved, I created first starting map "!arenaclimbbattl" --> into scripts/climb/stats/maps
But one more question, for every maps, should I create new mapname.txt?
.. and that "[Error] climb -> OnMapChange(68:1) Exception: File not found"
.. and that "157_Anti-Bravo-Script -> [Hint] (120:10): Variable 'Result' never used"


SOLVED
« Last Edit: July 18, 2014, 03:20:13 pm by MrHamsTR »
Is there anybody can write script?
Good, go and play soldat ^^

Offline kicikici

  • Soldier
  • **
  • Posts: 180
Re: Climb Script bysqudy error
« Reply #1 on: July 18, 2014, 02:37:38 am »
File detection should be scipted using fileexists function, not readfile. Fixed code below, at least it works now somehow (I have capped one map and checked !hi and !rank).

http://pastebin.com/8teZZi1F

To second script u must add Result:=FALSE; at the end of OnCommand function, but it's not necessarily, this message is warning only.
Classic banana

Offline MrHamsTR

  • Soldier
  • **
  • Posts: 209
  • One day, everything will end..
Re: Climb Script bysqudy error
« Reply #2 on: July 18, 2014, 03:15:54 am »
Hmm, okay im gonna add.
By the way, what is that (68.1) (120.10)
68. line 1. column?

EDIT: Is x normal in anti-bravo script?
You told me add result:FALSE; does x mean = FALSE? if not; so, server had crash? Should I change x to FALSE?
And can I add any cmd with result?
For example;
Code: [Select]
begin
    if Text = '/hey' then begin
       WriteLn('Hey to you too!');
    end;
    Result := false;
end;
« Last Edit: July 18, 2014, 03:23:29 am by MrHamsTR »
Is there anybody can write script?
Good, go and play soldat ^^

Offline kicikici

  • Soldier
  • **
  • Posts: 180
Re: Climb Script bysqudy error
« Reply #3 on: July 18, 2014, 09:45:47 am »
68. is line
1. is something in this row, imo line number is enough to detect what is wrong with script

What the hell is x?
Returning false value is standard matter, command will be executed. If u set TRUE, command will be ignored. Example:
Code: [Select]
function OnPlayerCommand(ID: Byte; Text: string):boolean;
begin
   Result := FALSE;
   if Text = '/kill' then begin
      Result := TRUE;
      WriteLn('You can''t kill yourself!');
   end;
end;
Classic banana

Offline MrHamsTR

  • Soldier
  • **
  • Posts: 209
  • One day, everything will end..
Re: Climb Script bysqudy error
« Reply #4 on: July 18, 2014, 10:11:23 am »
x is a thing in anti bravo script with "result" command. There is just 1 result with x in all script.
Hmm okay, Im gonna add.
Is there anybody can write script?
Good, go and play soldat ^^