1 /******************************************************************************
2 *
3 * Copyright (C) 2006, The Gentee Group. All rights reserved.
4 * This file is part of the Gentee open source project - http://www.gentee.com.
5 *
6 * THIS FILE IS PROVIDED UNDER THE TERMS OF THE GENTEE LICENSE ("AGREEMENT").
7 * ANY USE, REPRODUCTION OR DISTRIBUTION OF THIS FILE CONSTITUTES RECIPIENTS
8 * ACCEPTANCE OF THE AGREEMENT.
9 *
10 * ID: vmres 26.12.06 0.0.A.
11 *
12 * Author: Alexey Krivonogov ( gentee )
13 *
14 * Summary:
15 *
16 ******************************************************************************/
17
18 #include "vmres.h"
19
20 /*-----------------------------------------------------------------------------
21 *
22 * ID: vmres_addstr 26.12.06 0.0.A.
23 *
24 * Summary: Append a string to resource
25 *
26 -----------------------------------------------------------------------------*/
27
28 uint STDCALL vmres_addstr( pubyte ptr )
29 {
30 collect_addptr( &_vm.resource, ptr );
31
32 return collect_count( &_vm.resource ) - 1;
33 }
34
35 /*-----------------------------------------------------------------------------
36 *
37 * ID: vmres_get 26.12.06 0.0.A.
38 *
39 * Summary: Get a string from resource
40 *
41 -----------------------------------------------------------------------------*/
42
43 pstr STDCALL vmres_getstr( uint index )
44 {
45 return *( pstr* )collect_index( &_vm.resource, index );
46 }
47
Редактировать