[Feature]: Add eraseTokenVBL, eraseTokenMBL, etc. Functions

Open
#6,043 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
Half a day
Newbie friendliness
64/100
Issue type
Feature
Clarity
Clearly specified
Activity status
Quiet
Tech stack
java
Domain
desktop, game-dev

Research direction

Find how eraseVBL/eraseMBL and setTokenVBL are implemented and registered as MapTool script functions, then add matching eraseTokenVBL, eraseTokenMBL (and related) wrappers that clear a token’s VBL/MBL the same way setTokenVBL with shape none does. Mirror existing function names, docs, and tests so callers get a dedicated erase API instead of the JSON workaround.

Written by the indexing model from the issue text.

Description

feature
Describe the Problem

It's frustrating that there aren't eraseTokenVBL(), eraseTokenMBL(), etc. functions that would work similar to other "eraseVBL()..." functions.

The Solution you'd like

I would like to see eraseTokenVBL() (et al.) functions that would clear a token's VBL/MBL data, similar to how eraseVBL() and eraseMBL() remove it from the map.

I realize you can achieve this with: setTokenVBL("{'shape':'none'}"), but that feels wonky versus having a specific function for it.

Alternatives that you've considered.

The only alternative I know of is using setTokenVBL("{'shape':'none'}").

I suppose if I wanted to really nuke it I could just write a script to delete the token and replace it with a copy of the token with no VBL/MBL/etc. attached.

Additional Context

No response

Dominant language
Java
Stars
927
Forks
286
Avg merge
3d 17h
Merged PRs (30d)
94

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from RPTools/maptool

All issues in RPTools/maptool

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.