I was just playing around with the idea of creating a fork() function and I came up with this:...
Code: Select all
Global _ForkRet.l
EnableASM
Procedure _fork(RetAddy.l)
MOV eax,#True
CALL RetAddy
ProcedureReturn #False
EndProcedure
Procedure fork()
!MOV eax,[esp+20]
!MOV [v__ForkRet],eax
CreateThread(@_fork(),_ForkRet)
ProcedureReturn #False
EndProcedure
;/Example:
If fork()
Debug "FORKED"
MessageRequester("Fork()","Forked :)")
!RET
EndIf
MessageRequester("","We're Done...")
