Can't access custom module
BlitzMax Forums/BlitzMax Beginners Area/Can't access custom module
| ||
Hi, I've made a module in BlitzMAX and I've successfully built it using "BMK" but I can't work out how to use it in other BlitzMax programs. When I type in a function that was in the module, it doesn't recognise it (it doesn't turn yellow) and when I compile it, it says that the function wasn't found. The module is also not appearing in Module list??? Here is my directory structure: BlitzMax\mod\seb.mod\id3tag.mod\id3tag.bmx I've written in the file Module Seb.ID3Tag, used the following command to compile the mods (bmk makemods seb) and it return successful but it still doesn't work. What am I doing wrong? Thanks Seb |
| ||
change everything in the module path (and module declaration) to lowercase to rule that out. |
| ||
Pertubatio: Thanks - I've changed everything to lower-case and have ammended the Module Declaration but it still isn't recognised. Anyother ideas? |
| ||
Aha! I managed to get it to detect the module by using "Framework seb.id3tag" in the new source file. I thought though that all modules should be loaded by default if you don't use Framework. Also, how come it still doesn't turn the module's functions yellow? Seb |
| ||
ahh, yes, you need to implicitly import custom modules. all BRL modules are loaded by default since a few versions ago, this helps cut down on bloat. you can simply do Import <yourmodule> at the top of your code |
| ||
You have to do a docmods from the bin folder so that it adds the functions to the command list. |
| ||
Thanks everyone. I've tried to add DocMod comments to my module using:Rem bbdoc: Function action description about: Details about function End RemBut when I "DocMod", it makes a Doc folder in the module directory (BlitzMax\mod\seb.com\id3tag.mod\doc) but it doesn't put any files in it. It also doesn't list anything in the IDE. Can anyone figure out what I've done wrong now? I want Blitz to list my module's commands in the IDE's treeview! Thanks in advance Seb |
| ||
I've managed to get it to work!!! I put Rem bbdoc: My Module End Remat the top of the source file and it seems to have done the job. Please could anyone tell me what other "DocMod" keywords there are other than "bbdoc" and "about". |
| ||
This is the top of my AppFuncs module, you can compare it to yours to get it working.Strict Rem bbdoc: Pert.AppFuncs End Rem Module Pert.AppFuncs ModuleInfo "Module: Perturbatio's AppFuncs Mod" ModuleInfo "Version: 1.01" ModuleInfo "Author: Kris Kelly (Perturbatio) Portions by Daniel Lurie (LeisureSuitLurie)" ModuleInfo "License: Public Domain" ModuleInfo "DocGroup: Pert" |
| ||
Thanks Pertubatio! |