slushpuppy
2012-12-09 03:01:56
I was going to use this as my entry for the SRL+ member competition, but I decided against it, as the ending date was too far away and I couldn't be arsed to make an AIO banking function.
Anyway, I present to you another walking library to complement other existing walking methods.
[YOUTUBE]fc1pA-tQTfI[/YOUTUBE]
This demonstration walks from ozaich's house to crucible.
Code used in that demonstration:
The inspiration for this walking library came from radial walk, but i expanded on that idea.
This walking library essentially follows the road in a given direction as specified by the user.
Brief description of some of the methods:
RW_Point - Creates a RoadWalk point object that stores the road color and the direction(n,s,e,w) the user should be walking. The last parameter allows the script to stop walking once a certain event has been trigger. In this example, once the script is to stop walking once the dungeon symbol is
RW_Traverse - Walks the array of roadwalk point objects.
Key advantages using this method:
Debug image:

Essentially those dots are like checkpoints where the script can stop, then decide whether it should change direction as specified by user, etc
I will be releasing this library on my github page soon
Anyway, I present to you another walking library to complement other existing walking methods.
[YOUTUBE]fc1pA-tQTfI[/YOUTUBE]
This demonstration walks from ozaich's house to crucible.
Code used in that demonstration:
function foundDungeon : Boolean;
var x : Integer;
begin
Result := FindSymbol(x,x,Symbol_Dungeon);
end;
var walkPath : Array of RW_TPoint;
begin
{$IFDEF SMART}
{$IFDEF SIMBAMAJOR980}
Smart_Server := 72;
Smart_Members := True;
Smart_Signed := True;
Smart_SuperDetail := False;
{$ELSE}
SRL_SixHourFix := True;
Smart_FixSpeed := True;
{$ENDIF}
{$ENDIF}
ClearDebug;
SetupSRL;
RW_setup;
walkPath := [
RW_Point('s', RW_Color_LightGrey,RW_Tol_LightGrey,@RW_noop),
RW_Point('e', RW_Color_LightGrey,RW_Tol_LightGrey,@foundDungeon)
];
if RW_Traverse(walkPath) then
begin
writeln('Walked to Crucible successfully');
end;
end. The inspiration for this walking library came from radial walk, but i expanded on that idea.
This walking library essentially follows the road in a given direction as specified by the user.
Brief description of some of the methods:
RW_Point - Creates a RoadWalk point object that stores the road color and the direction(n,s,e,w) the user should be walking. The last parameter allows the script to stop walking once a certain event has been trigger. In this example, once the script is to stop walking once the dungeon symbol is
RW_Traverse - Walks the array of roadwalk point objects.
Key advantages using this method:
- instinctive coding. If you want to walk south, just indicate as such.
- you can get very accurate walking as roads do not disappear or shift as much as minimap icons.
- Script is independent of compass direction
- Faster as no bitmap/dtm objects are loaded when using this library
Debug image:

Essentially those dots are like checkpoints where the script can stop, then decide whether it should change direction as specified by user, etc
I will be releasing this library on my github page soon