Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Handwritten assembler
#16
Smile

btw, my commands are numbers, that's just to make it all easier and faster.
to create scripts, there'd be a special program that generates those numbers for you.

don't be afraid, you wouldn't have to learn them Wink
this script system was something I'd really like to work on, so that might be my contribution to 1.09 then.

@cncVK:
lgdt fword ptr whatever Tongue
my funny assembler assembles everything I need atm (ok, a better floating point instructions support would be cool, I'm still planning to implement that).
it even assembles mnemonics that don't actually exist Tongue
like
Code:
fjle <point to jump>
instead of
Code:
fnstsw    ax
test    ah, #41
jnz    <point to jump>
easier for me Wink
I can easily add new mnemonic support, so if you need your global thing loader that bad, I can add it Tongue
[Image: jsfml.png]
#17
@PD
Better, add normal script like mySmile
It's not very difficult (My version need only parse ONE line each time)
Better, add normal script like my
Or not add script at all:
(Add Next=, Delay= and another tags)
It's not very difficult (My version need only parse ONE line each time)
also we can use C++ pre-processor (#define, #ifdef) for INI macro.

[APOC]
#ifdef RULES_FIRST
Speed=5
#else
Speed=4
#endif
ARM forever - x86 sucks!


#18
er my version also just parses one line each frame... =S

delays could be done with a "wait" command, next= would be the "jump to script" one.

your script would have to add hundreds of strings to the exe while mine doesn't need any Tongue (except for the tags)
this results in MUCH more speed, too, cause your scripts would need many string compares (err.. comparasations?) while mine doesn't need any.

just an example how my script would spawn 3 units next to each other:
[SW gets launched to a specific cell, that is the "target cell"]
1=262,MTNK //CreateUnit "MTNK" at targetcell
2=513,1,0 //move target cell x+1, targetcell is now the cell next to the old one
3=262,MTNK //create mtnk at the new target cell

all the parameters and commands would be loaded once and could be used without any string comparing but just numbers, which speeds the stuff up extremely.
as said, you don't have to know those numbers 513 or 262 by heart but a special tool will spit these out (similar to the AI script editors) and also be able to read them

one script line would be executed per frame
if you need delays, there'll be a Wait command, which waits for a specific amount of frames.

I don't think there's a much better (concerning performance) system for this.
the scripts don't have to be tied to SWs only but could be used globablly (e.g. for "events")
[Image: jsfml.png]
#19
Major bump. Big Grin

Worth playing: 1 | 2 | 3
#20
Subtile.
Forum Rules

(01.06.2011, 05:43:25)kenosis Wrote: Oh damn don't be disgraced again!

(25.06.2011, 20:42:59)Nighthawk Wrote: The proverbial bearded omni-bug may be dead, but the containment campaign is still being waged in the desert.
#21
I don't see any reasons to open this old thread again Tongue
ARM forever - x86 sucks!






Users browsing this thread: 1 Guest(s)