Overview
| Comment: | Make some improvements to compile script, and start edit.c (just a stub so far) |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA1: |
3f12058d2de1220ca1410f418781f611 |
| User & Date: | user on 2018-10-07 04:25:13.171 |
| Other Links: | manifest | tags |
Context
|
2018-10-20
| ||
| 18:09 | Begin implementing the editor; also start to implement execution of key binding commands check-in: 4d0fdefe0c user: user tags: trunk | |
|
2018-10-07
| ||
| 04:25 | Make some improvements to compile script, and start edit.c (just a stub so far) check-in: 3f12058d2d user: user tags: trunk | |
|
2018-09-10
| ||
| 01:16 | Implement INSERT/UPDATE/DELETE for OBJECTS virtual table (untested) check-in: ec1c70d3d1 user: user tags: trunk | |
Changes
Modified compile
from [5fc19466c4]
to [076c585a54].
1 2 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | + - + - - - - + + + + + + | #!/bin/bash -- set -e test -f CFLAGS || echo xxx > CFLAGS |
Added edit.c version [240eb74098].
Modified exec.c
from [b18753cc8b]
to [c5ee33d3db].
| ︙ | |||
107 108 109 110 111 112 113 114 115 116 117 118 119 120 | 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 | + |
objects[n]=o;
return n;
bad:
free(o);
return VOIDLINK;
}
// Here is where the execution of a Free Hero Mesh bytecode subroutine is executed.
static void execute_program(Uint16*code,int ptr,Uint32 obj) {
Object*o=objects[obj];
if(StackProtection()) Throw("Call stack overflow");
for(;;) switch(code[ptr++]) {
case OP_GOTO: ptr=code[ptr]; break;
case OP_CALLSUB: execute_program(code,code[ptr++],obj); break;
case OP_RET: return;
|
| ︙ |
Modified heromesh.h
from [bef1fa2bb9]
to [6365c4e997].
| ︙ | |||
188 189 190 191 192 193 194 | 188 189 190 191 192 193 194 195 196 197 198 199 | + + + + + | extern Uint8 pfwidth,pfheight; void pfunlink(Uint32 n); void pflink(Uint32 n); Uint32 objalloc(Uint16 c); void annihilate(void); const char*execute_turn(int key); // == edit == void run_editor(void); |
Modified main.c
from [3f8604fa56]
to [281782dbc2].
1 | 1 2 3 4 5 6 7 8 9 | - + | #if 0 |
| ︙ | |||
724 725 726 727 728 729 730 731 732 733 734 735 736 737 | 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 | + |
v=malloc(strtoll(v+1,0,0));
fatal("%p %p :: %lld\n",v,stack_protect_mark,(long long)(((char*)stack_protect_mark)-v));
}
if(v[1]) stack_protect_mark=((char*)stack_protect_mark)+strtoll(v+1,0,0);
}
#endif
#define run_game() fatal("[Not implemented yet]\n")
int main(int argc,char**argv) {
int optind=1;
while(argc>optind && argv[optind][0]=='-') {
int i;
const char*s=argv[optind++];
if(s[1]=='-' && !s[2]) break;
for(i=1;s[i];i++) main_options[s[i]&127]=1;
|
| ︙ | |||
774 775 776 777 778 779 780 | 775 776 777 778 779 780 781 782 783 | - + |
max_objects=strtoll(xrm_get_resource(resourcedb,optionquery,optionquery,2)?:"",0,0)?:0xFFFF0000L;
annihilate();
if(main_options['x']) {
fprintf(stderr,"Ready for executing SQL statements.\n");
do_sql_mode();
return 0;
}
|