~sladen/openbve/openbve2

« back to all changes in this revision

Viewing changes to OpenBveApi/HostInterface.cs

  • Committer: Paul Sladen
  • Author(s): Michelle Boucquemont
  • Date: 2010-03-17 04:04:44 UTC
  • Revision ID: git-v1:c9050dde4c55fe2b9c257080653cee1a07c91303
import openbve2.zip (2010-03-14)

You will find a settings.cfg file where you can configure a series of
options and also which route or object to load. The options are
explained briefly via the comments in the settings.cfg file itself.
Select any route or object you want, but mind the following limitations:

* Background images and fog are not yet supported. Only a background
  color will be shown.
* Animated objects are not yet supported. This includes signals. These
  objects are not shown at all.
* Glow is not yet supported. All objects using glow will always show at
  full intensity instead of fading in.
* The legacy visibility system (where objects are disposed of as soon as
  the CSV/RW block the object was placed in has been passed by the camera)
  is not yet supported, only the new 2D grid is.

In-game, you can use the arrow, the WASD and the PageUp and PageDown keys to move and rotate around. Hold down the shift, control or alt key for faster movement. There is no way for you to jump to specific "track positions" as the new program does not have something like them internally. Also, you cannot jump to stations in any way at the moment. The initial position of the camera is the first stop point, though.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
using System;
2
 
using System.Text;
3
 
 
4
 
namespace OpenBveApi {
5
 
        
6
 
        
7
 
        /// <summary>Exposes the interface to be implemented by the host application.</summary>
8
 
        public interface IHost {
9
 
        
10
 
                // --- general ---
11
 
                
12
 
                /// <summary>Reports a problem to the host application.</summary>
13
 
                /// <param name="type">The type of problem to be reported.</param>
14
 
                /// <param name="keyValuePairs">A list of key-value pairs containing information about the problem.</param>
15
 
                void Report(General.ReportType type, params General.ReportKeyValuePair[] keyValuePairs);
16
 
                
17
 
                
18
 
                // --- path ---
19
 
                
20
 
                /// <summary>Resolves a file or folder reference into a platform-specific absolute path.</summary>
21
 
                /// <param name="reference">The file or folder reference to resolve.</param>
22
 
                /// <returns>The platform-specific absolute path.</returns>
23
 
                string Resolve(Path.PathReference reference);
24
 
        
25
 
        }
26
 
        
27
 
        
28
 
        /// <summary>Exposes version 1.0 of the interface to be implemented by the host application.</summary>
29
 
        public interface IHost10 : IHost {
30
 
 
31
 
                // --- textures ---
32
 
                
33
 
                /// <summary>Loads a texture suitable for post-processing.</summary>
34
 
                /// <param name="origin">The origin of the texture which includes a valid path.</param>
35
 
                /// <param name="texture">Receives the texture.</param>
36
 
                /// <returns>The success of the operation.</returns>
37
 
                General.Result LoadTexture(General.Origin origin, out Texture.TextureData texture);
38
 
                
39
 
                /// <summary>Registers a texture with the host application.</summary>
40
 
                /// <param name="origin">The origin of the texture which includes a valid path.</param>
41
 
                /// <param name="parameters">The parameters for the texture.</param>
42
 
                /// <param name="handle">Receives a handle to the texture.</param>
43
 
                /// <returns>The success of the operation.</returns>
44
 
                General.Result RegisterTexture(General.Origin origin, Texture.TextureParameters parameters, out Texture.TextureHandle handle);
45
 
                
46
 
                /// <summary>Registers a texture with the host application.</summary>
47
 
                /// <param name="texture">The texture to register.</param>
48
 
                /// <param name="parameters">The parameters for the texture.</param>
49
 
                /// <param name="handle">Receives a handle to the texture.</param>
50
 
                /// <returns>The success of the operation.</returns>
51
 
                General.Result RegisterTexture(Texture.TextureData texture, Texture.TextureParameters parameters, out Texture.TextureHandle handle);
52
 
                
53
 
                
54
 
                // --- objects ---
55
 
                
56
 
                /// <summary>Loads an object from a file, suitable for post-processing.</summary>
57
 
                /// <param name="origin">The origin of the object which includes a valid path.</param>
58
 
                /// <param name="obj">Receives the object.</param>
59
 
                /// <returns>The success of the operation.</returns>
60
 
                General.Result LoadObject(General.Origin origin, out Geometry.GenericObject obj);
61
 
                
62
 
                
63
 
                // --- sound ---
64
 
                
65
 
                /// <summary>Loads a sound from a file, suitable for post-processing.</summary>
66
 
                /// <param name="origin">The origin of the sound which includes a valid path.</param>
67
 
                /// <param name="sound">Receives the sound data.</param>
68
 
                /// <returns>The success of the operation.</returns>
69
 
                General.Result LoadSound(General.Origin origin, out Sound.SoundData sound);
70
 
                
71
 
                /// <summary>Registers a sound with the host application.</summary>
72
 
                /// <param name="origin">The origin of the sound which includes a valid path.</param>
73
 
                /// <param name="handle">Receives a handle to the sound.</param>
74
 
                /// <returns>The success of the operation.</returns>
75
 
                General.Result RegisterSound(General.Origin origin, out Sound.SoundHandle handle);
76
 
                
77
 
                /// <summary>Registers a sound with the host application.</summary>
78
 
                /// <param name="sound">The sound data to register.</param>
79
 
                /// <param name="handle">Receives a handle to the sound.</param>
80
 
                /// <returns>The success of the operation.</returns>
81
 
                General.Result RegisterSound(Sound.SoundData sound, out Sound.SoundHandle handle);
82
 
                
83
 
        }
84
 
}
 
 
b'\\ No newline at end of file'